Detailed information on orders

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

Returns information about orders on the Market that contain your products.

You can use it to collect statistics on your orders and find out, for example, which of the products are most often returned by customers, which, on the contrary, are in high demand, etc.

Information on created or updated orders may appear with a delay of up to 40 minutes.

To get the data without delay, use the method GET v2/campaigns/{campaignId}/orders or POST v1/businesses/{businessId}/orders.

You can get information on up to 200 orders in one request.

⚙️ Limit: 1,000,000 orders per hour

Request

POST

https://api.partner.market.yandex.ru/v2/campaigns/{campaignId}/stats/orders

Path parameters

Name

Description

campaignId*

Type: integer<int64>

The campaign ID.

You can find it using a query GET v2/campaigns or find it in the seller's office on the Market — click on your account icon → Settings and in the menu on the left, select APIs and modules:

  • block Campaign ID;
  • tab Query log → drop-down list in the block Show logs.

⚠️ Do not send the store ID instead, which is indicated in the seller's account on the Market next to the store name and in some reports.

Min value: 1

Query parameters

Name

Description

limit

Type: integer<int32>

The number of values per page.

Min value: 1
Example: 20

page_token

Type: string

ID of the results page.

If the parameter is omitted, the first page is returned.

We recommend transmitting the value of the output parameter nextPageToken, received during the last request.

If set page_token and the request has parameters page and pageSize they are ignored.
Example: eyBuZXh0SWQ6IDIzNDIgfQ==

Body

application/json
{
    "dateFrom": "string",
    "dateTo": "string",
    "updateFrom": "string",
    "updateTo": "string",
    "orders": [
        0
    ],
    "statuses": [
        "CANCELLED_BEFORE_PROCESSING"
    ],
    "hasCis": false
}

Name

Description

dateFrom

Type: string<date>

The initial date when the order was generated.

Date format: YYYY‑MM‑DD.

Cannot be used together with parameters updateFrom and updateTo.

dateTo

Type: string<date>

The end date when the order was generated.

Date format: YYYY‑MM‑DD.

Cannot be used together with parameters updateFrom and updateTo.

hasCis

Type: boolean

A filter for receiving orders that contain at least one product with an identification code in the system. «Честный ЗНАК» or «ASL BELGISI» (for sellers Market Yandex Go):

  • true — Yes.
  • false — No. Such codes are assigned to products that are subject to labeling and belong to certain categories.

orders

Type: integer[]

List of order IDs.
The list of products in the order after possible changes.

During order processing, the Market can delete items from it. — in case of problems in the warehouse or at the initiative of the user.

  • If all items are deleted from the order, it will not be in the list. items — only in the list initialItems.

  • If there is at least one item left in the order, it will be in the list. items (with a reduced number of units count), and in the list initialItems (with the initial number of units initialCount).

Min items: 1

Unique items  

statuses

Type: string[]

List of order statuses.
Current order status:

  • CANCELLED_BEFORE_PROCESSING — the order was cancelled before it was processed.

  • CANCELLED_IN_DELIVERY — the order is cancelled during its delivery.

  • CANCELLED_IN_PROCESSING — the order was cancelled during its processing.

  • DELIVERY — the order has been transferred to the delivery service.

  • DELIVERED — the order has been delivered.

  • PARTIALLY_DELIVERED — the order is partially delivered.

    The order status can change to PARTIALLY_DELIVERED Not immediately

    If there was a non-purchase in the delivered order, the status will change only after the order is received at the Market warehouse.

  • PARTIALLY_RETURNED — the order was partially refunded by the buyer.

  • PENDING — the order is awaiting confirmation.

  • PICKUP — The order has been delivered to the pick-up point.

  • PROCESSING — the order is in processing.

  • RESERVED — the product is reserved in the warehouse.

  • RETURNED — The order has been fully refunded by the buyer.

  • UNKNOWN — unknown order status.

  • UNPAID — An order from a legal entity is awaiting payment.

  • LOST — the order is lost.

Enum: CANCELLED_BEFORE_PROCESSING, CANCELLED_IN_DELIVERY, CANCELLED_IN_PROCESSING, DELIVERY, DELIVERED, PARTIALLY_DELIVERED, PARTIALLY_RETURNED, PENDING, PICKUP, PROCESSING, RESERVED, RETURNED, UNKNOWN, UNPAID, LOST

Min items: 1

Unique items  

updateFrom

Type: string<date>

The start date of the period for which changes were made to the order (for example, status or payment information).

Date format: YYYY‑MM‑DD.

Cannot be used together with parameters dateFrom and dateTo.

updateTo

Type: string<date>

The end date of the period for which the order was changed (for example, the status or payment information).

Date format: YYYY‑MM‑DD.

Cannot be used together with parameters dateFrom and dateTo.

Responses

200 OK

Information about orders.

Body

application/json
{
    "status": "OK",
    "result": {
        "orders": [
            {
                "id": 0,
                "creationDate": "string",
                "statusUpdateDate": "2022-12-29T18:02:01Z",
                "status": "CANCELLED_BEFORE_PROCESSING",
                "partnerOrderId": "string",
                "paymentType": "POSTPAID",
                "fake": false,
                "deliveryRegion": {
                    "id": 0,
                    "name": "string"
                },
                "items": [
                    {
                        "offerName": "string",
                        "marketSku": 0,
                        "shopSku": "string",
                        "count": 0,
                        "prices": [
                            {
                                "type": "BUYER",
                                "costPerItem": 0,
                                "total": 0
                            }
                        ],
                        "warehouse": {
                            "id": 0,
                            "name": "string"
                        },
                        "details": [
                            {
                                "itemStatus": "REJECTED",
                                "itemCount": 0,
                                "updateDate": "string",
                                "stockType": "FIT"
                            }
                        ],
                        "cisList": [
                            "string"
                        ],
                        "initialCount": 0,
                        "bidFee": 570,
                        "cofinanceThreshold": 0,
                        "cofinanceValue": 0
                    }
                ],
                "initialItems": [
                    {
                        "offerName": "string",
                        "marketSku": 0,
                        "shopSku": "string",
                        "count": 0,
                        "prices": [
                            {
                                "type": "BUYER",
                                "costPerItem": 0,
                                "total": 0
                            }
                        ],
                        "warehouse": {
                            "id": 0,
                            "name": "string"
                        },
                        "details": [
                            {
                                "itemStatus": "REJECTED",
                                "itemCount": 0,
                                "updateDate": "string",
                                "stockType": "FIT"
                            }
                        ],
                        "cisList": [
                            "string"
                        ],
                        "initialCount": 0,
                        "bidFee": 570,
                        "cofinanceThreshold": 0,
                        "cofinanceValue": 0
                    }
                ],
                "payments": [
                    {
                        "id": "string",
                        "date": "string",
                        "type": "PAYMENT",
                        "source": "BUYER",
                        "total": 0,
                        "paymentOrder": {
                            "id": "string",
                            "date": "string"
                        }
                    }
                ],
                "commissions": [
                    {
                        "type": "FEE",
                        "actual": 0
                    }
                ],
                "subsidies": [
                    {
                        "operationType": "ACCRUAL",
                        "type": "YANDEX_CASHBACK",
                        "amount": 0
                    }
                ],
                "buyerType": "PERSON",
                "currency": "RUR"
            }
        ],
        "paging": {
            "nextPageToken": "string"
        }
    }
}

Name

Description

status*

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

result

Type: object

orders*

Type: object[]

The list of orders.
Order information.

paging

Type: object

nextPageToken

Type: string

ID of the next results page.

The ID of the next page.

Information about orders.

400 Bad Request

The request contains incorrect data. More information about the error

Body

application/json
{
    "status": "OK",
    "errors": [
        {
            "code": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

401 Unauthorized

The authorization data is not specified in the request. More information about the error

Body

application/json
{
    "status": "OK",
    "errors": [
        {
            "code": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

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": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

404 Not Found

The requested resource was not found. More information about the error

Body

application/json
{
    "status": "OK",
    "errors": [
        {
            "code": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

420 Method Failure

The resource access limit has been exceeded. More information about the error

Body

application/json
{
    "status": "OK",
    "errors": [
        {
            "code": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

500 Internal Server Error

Internal error of the Market. More information about the error

Body

application/json
{
    "status": "OK",
    "errors": [
        {
            "code": "string",
            "message": "string"
        }
    ]
}

Name

Description

errors

Type: object[]

A list of errors.
The general error format.

Min items: 1

status

Type: string

The type of response. Possible values:

  • OK — There are no errors.
  • ERROR — an error occurred while processing the request.

Enum: OK, ERROR

No longer supported, please use an alternative and newer version.