2.2. Get classes available at the point
In the response, the supported_requirements field returns possible additional requirements.
Acceptable values for requirements:
- cargo_type, possible size options
- cargo_loaders, possible options for loaders
- cargo_options, possible additional options: courier with a car - auto_courier, thermal bag — thermobag
Each requirement has the "options" field that defines a list of possible values.
Only one value can be selected for cargo_type/cargo_loaders,
but for cargo_options there can be multiple values.
These requirements can be passed when creating a claim in the field client_requirements.name,
where "name" passes the name of the additional requirement,
"value" passes an option for cargo_type or cargo_loaders,
or an array of options for cargo_options.
HTTP Request
POST b2b.taxi.yandex.net/b2b/cargo/integration/v2/tariffs
Header Parameters
Accept-Language * | string Preferred language of response |
Accept-Language * | string Preferred language of response |
* Required parameter
Request Body
{ "fullname": string, "start_point": [ "number" ] }
Copied to clipboard
Representation
Fields
fullname | string Full name indicating the city (Moscow, Sadovnicheskaya Naberezhnaya, 82 bld. 2). |
start_point[] | array Array of two real numbers [longitude, latitude]. The order is important! |
fullname | string Full name indicating the city (Moscow, Sadovnicheskaya Naberezhnaya, 82 bld. 2). |
start_point[] | array Array of two real numbers [longitude, latitude]. The order is important! |
* Required parameter
Responses
Code 200
OK
{ "available_tariffs": [ { "minimal_price": number, "name": string, "supported_requirements": [ { "default": boolean, "name": string, "options": [ { "text": string, "title": string } ], "required": boolean, "text": string, "title": string, "type": string } ], "text": string, "title": string } ] }
Copied to clipboard
Representation
Fields
available_tariffs[] * | array | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | number | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Service class | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | array | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One Of:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | array Possible choices | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | object Value passed to enable the option | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Required field | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Type of choice Allowed values
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Default value | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Required field | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Type of choice Allowed values
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string |
available_tariffs[] * | array | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | number | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Service class | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | array | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One Of:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | array Possible choices | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | object Value passed to enable the option | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Required field | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Type of choice Allowed values
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Default value | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | boolean Required field | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized description of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Localized name of the requirement type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string Type of choice Allowed values
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
available_tariffs[]. | string |
* Required parameter
Code 400
Invalid claim
{ "code": string, "message": string }
Copied to clipboard
Representation
Fields
* Required parameter
Example
Request:
curl -X POST "b2b.taxi.yandex.net/b2b/cargo/integration/v2/tariffs" \ -H "Accept-Language: {string}" \ -d '{ "fullname": "St. Petersburg, Bolshaya Monetnaya Ulitsa, 1 bld. 1A", "start_point": [ 0.1, 0.1 ] }'
Copied to clipboard
Responses:
{ "available_tariffs": [ { "minimal_price": 213, "name": "cargo", "supported_requirements": [ { "name": "cargo_type", "options": [ { "text": "170 cm in length, 100 cm in width, 90 cm in height", "title": "Small body" } ], "required": false, "text": "Requirement for transportation vehicle dimensions", "title": "Body type", "type": "select" } ], "text": "Express tariff", "title": "Express" } ] }
Copied to clipboard
{ "code": "validation_error", "message": "Validation error" }
Copied to clipboard