Ready‑made labels-stickers for all boxes in several orders

The method is available for models: FBS, Express and DBS.

If you are using an API Key token, one of the accesses in the list is required to call the method

Starts generation PDF-a file with labels for transferred orders. Details about why they are needed and what they look like are described in the Help of the Market for sellers.

To display the external order ID on the label, pass it in the method POST v2/campaigns/{campaignId}/orders/{orderId}/external-id.

You can find out the generation status and get a link to the finished file using a request. GET v2/reports/info/{reportId}.

⚙️ Limit: 1,000 requests per hour

Request

POST

https://api.partner.market.yandex.ru/v2/reports/documents/labels/generate

Query parameters

Name

Description

format

Type: string

Setting up the placement of shortcuts on the page. If there is no parameter, it is returned PDF with format labels A7. Placing labels on a page PDF-file:

  • A9_HORIZONTALLY — the label is 58 × 40 mm in size, without margins, close to the format A9.

    An example of a label for Market sellers

    Image of a horizontal format label A9 for Market sellers

    An example of a shortcut for Market Yandex Go sellers

    An image of a horizontal label in A9 format for Market Yandex Go sellers

  • A9 — the label is 40x58 mm in size without margins, close to the A9 format.

    An example of a label for Market sellers

    Image of the vertical label format A9 for Market sellers

    An example of a shortcut for Market Yandex Go sellers

    Image of a vertical label in the format A9 for sellers of the Yandex Go Market

  • A7 — the label is 75 × 120 mm (80.4 × 125.6 mm including margins), close to the format A7.

    An example of a label for Market sellers

    An image of an A7 format label for Market sellers

    An example of a shortcut for Market Yandex Go sellers

    Image of the format label A7 for sellers of the Yandex Go Market

  • A4 — on the A4 sheet there is a label of the format that is selected in the seller's office on the Market. — go to the page OrdersOrders and shipments → on the tab of the desired work model, click Label format.

Enum: A9_HORIZONTALLY, A9, A7, A4

Body

application/json
{
  "businessId": 1,
  "orderIds": [
    0
  ],
  "sortingType": "SORT_BY_GIVEN_ORDER"
}

Name

Description

businessId

Type: integer

Cabinet ID. To find out, use the request GET v2/campaigns.

ℹ️ What is a cabinet and a store on the Market?

Min value: 1

orderIds

Type: integer[]

List of order IDs.

Min items: 1

Max items: 1000

Unique items: true

Example
[
  0
]

sortingType

Type: string

Label sorting type:

  • SORT_BY_GIVEN_ORDER — The order labels will be arranged in the same order as the order IDs were passed in the request.
  • SORT_BY_ORDER_CREATED_AT — The labels will be arranged according to the date the order was created and grouped by stores.

If no parameter is specified, the labels are sorted by creation date.

Enum: SORT_BY_GIVEN_ORDER, SORT_BY_ORDER_CREATED_AT

Responses

200 OK

In response, you receive an identifier that allows you to find out the generation status and download the finished file.

If a part of the orders could not be found during the generation, the sub-status will be returned in response to the request to receive the finished file. RESOURCE_NOT_FOUND.

Body

application/json
{
  "status": "OK"
}

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, ERROR

    The standard wrapper for server responses.

    Example
    {
      "status": "OK"
    }
    
  • Type: object

    result

    Type: object

    estimatedGenerationTime

    Type: integer

    Expected generation time in milliseconds.

    reportId

    Type: string

    The ID that will be needed to track the generation status and receive the finished report or document.

    Example: example

    The ID that will be needed to track the generation status and receive the finished report or document.

    Example
    {
      "reportId": "example",
      "estimatedGenerationTime": 0
    }
    
    Example
    {
      "result": {
        "reportId": "example",
        "estimatedGenerationTime": 0
      }
    }
    

400 Bad Request

The request contains incorrect data. More information about the error

Body

application/json
{
  "status": "OK"
}

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, ERROR

      The standard wrapper for server responses.

      Example
      {
        "status": "OK"
      }
      
    • Type: object

      errors

      Type: object[]

      code

      Type: string

      The error code.

      Example: example

      message

      Type: string

      Description of the error.

      Example: example

      A list of errors.

      Min items: 1

      Example
      [
        {
          "code": "example",
          "message": "example"
        }
      ]
      
      Example
      {
        "errors": [
          {
            "code": "example",
            "message": "example"
          }
        ]
      }
      

    A standard wrapper for server errors.

    Example
    {
      "status": "OK"
    }
    

401 Unauthorized

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

Body

application/json
{
  "status": "OK"
}

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, ERROR

      The standard wrapper for server responses.

      Example
      {
        "status": "OK"
      }
      
    • Type: object

      errors

      Type: object[]

      code

      Type: string

      The error code.

      Example: example

      message

      Type: string

      Description of the error.

      Example: example

      A list of errors.

      Min items: 1

      Example
      [
        {
          "code": "example",
          "message": "example"
        }
      ]
      
      Example
      {
        "errors": [
          {
            "code": "example",
            "message": "example"
          }
        ]
      }
      

    A standard wrapper for server errors.

    Example
    {
      "status": "OK"
    }
    

403 Forbidden

The authorization data is incorrect or access to the resource is prohibited. More information about the error

Body

application/json
{
  "status": "OK"
}

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, ERROR

      The standard wrapper for server responses.

      Example
      {
        "status": "OK"
      }
      
    • Type: object

      errors

      Type: object[]

      code

      Type: string

      The error code.

      Example: example

      message

      Type: string

      Description of the error.

      Example: example

      A list of errors.

      Min items: 1

      Example
      [
        {
          "code": "example",
          "message": "example"
        }
      ]
      
      Example
      {
        "errors": [
          {
            "code": "example",
            "message": "example"
          }
        ]
      }
      

    A standard wrapper for server errors.

    Example
    {
      "status": "OK"
    }
    

420 Method Failure

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

Body

application/json
{
  "status": "OK"
}

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, ERROR

      The standard wrapper for server responses.

      Example
      {
        "status": "OK"
      }
      
    • Type: object

      errors

      Type: object[]

      code

      Type: string

      The error code.

      Example: example

      message

      Type: string

      Description of the error.

      Example: example

      A list of errors.

      Min items: 1

      Example
      [
        {
          "code": "example",
          "message": "example"
        }
      ]
      
      Example
      {
        "errors": [
          {
            "code": "example",
            "message": "example"
          }
        ]
      }
      

    A standard wrapper for server errors.

    Example
    {
      "status": "OK"
    }
    

500 Internal Server Error

Internal error of the Market. More information about the error

Body

application/json
{
  "status": "OK"
}

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, ERROR

      The standard wrapper for server responses.

      Example
      {
        "status": "OK"
      }
      
    • Type: object

      errors

      Type: object[]

      code

      Type: string

      The error code.

      Example: example

      message

      Type: string

      Description of the error.

      Example: example

      A list of errors.

      Min items: 1

      Example
      [
        {
          "code": "example",
          "message": "example"
        }
      ]
      
      Example
      {
        "errors": [
          {
            "code": "example",
            "message": "example"
          }
        ]
      }
      

    A standard wrapper for server errors.

    Example
    {
      "status": "OK"
    }
    

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