API

Get a list of delivery districts with polygons

GET/api/crm/v2/districtsv2
operationId: districts.default

Authorization

api-token + language + role

Query parameters

branch_idinteger

Example: 1

Responses

OK

object
statusstringrequired

Values:successerror

Example: success

dataobject
filtersobject
branch_idobject (FilterSelectInteger)
valueinteger

Example: 8920

typestringrequired

Example: select

optionarray of object
valueintegerrequired

Example: 8920

namestringrequired

Example: Green Basket | Kaliningrad

modestring (FilterMode)

How the interface handles the filter; a regular filter does not have mode.
force_shown — always displayed, cannot be hidden.
value_required — entry point to the section: always displayed, cannot have an empty value (until a value is selected, the list is empty; there is no "all" option), global reset does not clear it.

Values:force_shownvalue_required

Example: value_required

settingsobject (SettingsDistricts)
branch_idinteger

Example: 1

operator_idinteger

Example: 1

delivery_timeintegerrequired

Example: 60

other_delivery_timeinteger

Example: 90

other_delivery_time_periodsarray of string
other_delivery_time_enabledboolean

Example: false

cost_of_deliverynumber

Example: 100

minimum_order_amountnumber

Example: 200

free_delivery_fromnumber

Example: 400

paid_delivery_enabledboolean

Example: false

other_minimum_order_amountnumber

Example: 300

other_minimum_order_amount_daysarray of integer
other_minimum_order_amount_periodsarray of string
other_minimum_order_amount_enabledboolean

Example: false

work_timearray of object (WorkTimePrepared) required
dayintegerrequired

Values:1234567

Example: 1

parameterinteger

Values:123

Example: 1

timesarray of string
redirect_district_idinteger

Example: 1

timeworkstring

Example: 00:00 - 23:59

cityobject
idintegerrequired

Example: 1

namestringrequired

Example: Kaliningrad

timezonestringrequired

Example: Europe/Kaliningrad

latitudenumberrequired

Example: 54.710426

longitudenumberrequired

Example: 20.452214

listarray of object
idintegerrequired

Example: 1

old_idinteger

Example: 1

namestringrequired

Example: Central

publishedbooleanrequired

Example: true

sortintegerrequired

Example: -1715765994

polygonsobject
colorstringrequired

Color in HEX format without the leading "#" symbol. The district color is stored here; if a district has no shapes, it has no color, and the interface selects it.

Example: 3949AB

coordinatesarray of array of array of numberrequired
operator_idinteger

Example: 1

work_timearray of object (WorkTimePrepared)
dayintegerrequired

Values:1234567

Example: 1

parameterinteger

Values:123

Example: 1

timesarray of string
delivery_timeinteger

Example: 60

other_delivery_timeinteger

Example: 90

other_delivery_time_periodsarray of string
other_delivery_time_enabledboolean

Example: true

cost_of_deliverynumber

Example: 200

minimum_order_amountnumber

Example: 400

free_delivery_fromnumber

Example: 400

paid_delivery_enabledboolean

Example: true

other_minimum_order_amountnumber

Example: 300

other_minimum_order_amount_daysarray of integer
other_minimum_order_amount_periodsarray of string
other_minimum_order_amount_enabledboolean

Example: true

redirect_district_idinteger

Example: 55315

pickup_address_idinteger

Example: 4947

timeworkstring

Example: 00:00 - 23:59

districts_read_onlyarray of object
idintegerrequired

Example: 1

namestringrequired

Example: Central

polygonsobject
colorstringrequired

Color in HEX format without the leading "#" symbol. The district color is stored here; if a district has no polygons, it has no color, and the interface selects it.

Example: 3949AB

coordinatesarray of array of array of numberrequired
descriptionobject
countrystringrequired

Example: Russia

chainstringrequired

Example: Green Basket

citystringrequired

Example: Kaliningrad

entity_namestring

Example: LLC Green Basket