Service Cost Calculator
The method is available for all models.
If you are using an API Key token, one of the accesses in the list is required to call the method
- pricing — Manage prices
- pricing:read-only — View prices
- finance-and-accounting — View financial data and reports
- all-methods — Full account management
- all-methods:read-only — View all data
Calculates the cost of Market services for products with the specified parameters. The order of the items in the request and response is saved to determine, for which product the cost of the service is calculated.
Please note: the calculator performs approximate calculations. The final cost for each order depends on the services provided.
In the request, you can specify either the parameter campaignId, or sellingProgram. Sharing the parameters will result in an error.
| ⚙️ Limit: 100 requests per minute |
|---|
Request
POST
https://api.partner.market.yandex.ru/v2/tariffs/calculate
Body
application/json
{
"parameters": {
"campaignId": 1,
"sellingProgram": "FBY",
"frequency": "DAILY",
"currency": "RUR"
},
"offers": [
{
"categoryId": 0,
"price": 0,
"length": 0,
"width": 0,
"height": 0,
"weight": 0,
"quantity": 1
}
]
}
|
Name |
Description |
||||||||||||||
|
offers |
Type: object[]
Products for which you need to calculate the cost of services. Min items: Max items: Example
|
||||||||||||||
|
parameters |
Type: object
Parameters for calculating the cost of services. You must specify the parameter Example
|
Responses
200 OK
The cost of services.
Body
application/json
{
"status": "OK",
"result": {
"offers": [
{
"offer": {},
"tariffs": [
null
]
}
]
}
}
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
result
Type: object
offers
Type: object[]
offer
Type: object
categoryId
Type: integer
The identifier of the product category on the Market.
To calculate the cost of services, you must specify the ID of the leaf category the product.
To find out the ID of the category to which the product belongs, use the request POST v2/categories/tree.
Min value:
0Exclusive min:
trueheight
Type: number
The height of the product in centimeters.
Min value:
0Exclusive min:
truelength
Type: number
The length of the product in centimeters.
Min value:
0Exclusive min:
trueprice
Type: number
The price of the product in rubles.
Min value:
0Exclusive min:
trueweight
Type: number
The weight of the product in kilograms.
Min value:
0Exclusive min:
truewidth
Type: number
The width of the product in centimeters.
Min value:
0Exclusive min:
truequantity
Type: integer
Quantum of sale — the number of product units in one product offer.
Default:
1Min value:
1The parameters of the product for which you need to calculate the cost of services.
Example
{ "categoryId": 0, "price": 0, "length": 0, "width": 0, "height": 0, "weight": 0, "quantity": 1 }tariffs
Type: object[]
parameters
Type: object[]
name
Type: string
The name of the parameter.
Example:
examplevalue
Type: string
The value of the parameter.
Example:
exampleTariff calculation parameters.
Example
[ { "name": "example", "value": "example" } ]type
Type: string
The Market service:
-
AGENCY_COMMISSION— acceptance of the buyer's payment. -
PAYMENT_TRANSFER— transfer of the buyer's payment. -
FEE— product placement on the Market. -
DELIVERY_TO_CUSTOMER— delivery to the buyer. -
CROSSREGIONAL_DELIVERY— delivery to the federal district, city or locality. -
EXPRESS_DELIVERY— express delivery to the buyer. -
SORTING— order processing. -
MIDDLE_MILE— the average mile.
Read more about Yandex.Market services in the Help of the Market for sellers.
Enum:
AGENCY_COMMISSION,PAYMENT_TRANSFER,FEE,DELIVERY_TO_CUSTOMER,CROSSREGIONAL_DELIVERY,EXPRESS_DELIVERY,SORTING,MIDDLE_MILEamount
Type: number
The cost of the service is in rubles.
currency
Type: string
Currency codes:
RUR— the Russian ruble.UAH— the Ukrainian hryvnia.BYR— the Belarusian ruble.KZT— Kazakhstani tenge.UZS— Uzbek sum.
Enum:
RUR,USD,EUR,UAH,AUD,GBP,BYR,BYN,DKK,ISK,KZT,CAD,CNY,NOK,XDR,SGD,TRY,SEK,CHF,JPY,AZN,ALL,DZD,AOA,ARS,AMD,AFN,BHD,BGN,BOB,BWP,BND,BRL,BIF,HUF,VEF,KPW,VND,GMD,GHS,GNF,HKD,GEL,AED,EGP,ZMK,ILS,INR,IDR,JOD,IQD,IRR,YER,QAR,KES,KGS,COP,CDF,CRC,KWD,CUP,LAK,LVL,SLL,LBP,LYD,SZL,LTL,MUR,MRO,MKD,MWK,MGA,MYR,MAD,MXN,MZN,MDL,MNT,NPR,NGN,NIO,NZD,OMR,PKR,PYG,PEN,PLN,KHR,SAR,RON,SCR,SYP,SKK,SOS,SDG,SRD,TJS,THB,TWD,BDT,TZS,TND,TMM,UGX,UZS,UYU,PHP,DJF,XAF,XOF,HRK,CZK,CLP,LKR,EEK,ETB,RSD,ZAR,KRW,NAD,TL,UEThe list of services and their cost.
For some services, several different values may be returned. For example, in the model FBS the cost of the service
SORTING(order processing) depends on the shipping method and the number of orders in the shipment. Read more about the tariffs for services in the Help of the Market for sellers.Example
[ { "type": "AGENCY_COMMISSION", "amount": 0.5, "currency": "RUR", "parameters": [ { "name": "example", "value": "example" } ] } ]The cost of services.
Example
[ { "offer": { "categoryId": 0, "price": 0, "length": 0, "width": 0, "height": 0, "weight": 0, "quantity": 1 }, "tariffs": [ { "type": "AGENCY_COMMISSION", "amount": 0.5, "currency": "RUR", "parameters": [ {} ] } ] } ]Calculation of the cost of services.
Example
{ "offers": [ { "offer": { "categoryId": 0, "price": 0, "length": 0, "width": 0, "height": 0, "weight": 0, "quantity": 1 }, "tariffs": [ { "type": "AGENCY_COMMISSION", "amount": 0.5, "currency": "RUR", "parameters": [ null ] } ] } ] }Example
{ "result": { "offers": [ { "offer": { "categoryId": 0, "price": 0, "length": 0, "width": 0, "height": 0, "weight": 0, "quantity": 1 }, "tariffs": [ {} ] } ] } } -
400 Bad Request
The request contains incorrect data. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
401 Unauthorized
The authorization data is not specified in the request. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
403 Forbidden
The authorization data is incorrect or access to the resource is prohibited. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
404 Not Found
The requested resource was not found. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
420 Method Failure
The resource access limit has been exceeded. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
500 Internal Server Error
Internal error of the Market. More information about the error
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "example",
"message": "example"
}
]
}
Type: object
All of 1 type
-
Type: object
All of 2 types
-
Type: object
status
Type: string
The type of response. Possible values:
OK— There are no errors.ERROR— an error occurred while processing the request.
Enum:
OK,ERRORThe standard wrapper for server responses.
Example
{ "status": "OK" } -
Type: object
errors
Type: object[]
code
Type: string
The error code.
Example:
examplemessage
Type: string
Description of the error.
Example:
exampleA list of errors.
Min items:
1Example
[ { "code": "example", "message": "example" } ]Example
{ "errors": [ { "code": "example", "message": "example" } ] }
A standard wrapper for server errors.
Example
{ "status": "OK", "errors": [ { "code": "example", "message": "example" } ] } -
No longer supported, please use an alternative and newer version.
A category that has no children.