订单中货位数量的转移

Deprecated

方法适用于模式DBS.

如果您使用API-Key令牌,调用该方法时需要具备列表中可用权限之一

我应该使用哪种方法而不是过时的方法?

运往市场的订单可能不适合装在一个盒子或包裹中。 — 在这种情况下,事实证明它占用了几个货物空间。

货位数不等于1则必须转让给市场。 这是在将其转移到状态之前完成的 准备装运. 有关在什么点需要传输的内容的更多信息,请参阅 分步说明.

该方法有点非标准:数量由空对象数组的长度设置。

以前,该方法需要传输更多数据。 基于旧模式的查询可以工作,但最好以新的方式进行。

以前怎么样

车身结构 PUT-请求:

{
  "boxes":
  [
    {
      "fulfilmentId": "{string}",
      "weight": {int64},
      "width": {int64},
      "height": {int64},
      "depth": {int64},
      "items":
      [
        {
          "id": {int64},
          "count": {int32}
        },
        ...
      ]
    },
    ...
  ]
}
参数 类型 意义
boxes 货物位置列表。

参数嵌套在 boxes

参数 类型 意义
fulfilmentId String 商店系统中货位的ID。 基于模板创建标识符: 市场上的订单号是货地的编号。. 例如, 7206821‑1, 7206821‑2 等等。
weight Int64 货物区域的总重量(包装和内容物的总重量)以克为单位。
width Int64 以厘米为单位的货物区域的宽度。
height Int64 以厘米为单位的货物区域的高度。
depth Int64 厘米为单位的货物区域的深度。
items Int64 货物区的货物清单。

参数嵌套在 items

参数 类型 意义
id Int64 订单内产品的标识符。
count Int32 货区的物品数量。
⚙️ 限制: 每小时100,000次请求

Request

PUT

https://api.partner.market.yandex.ru/v2/campaigns/{campaignId}/orders/{orderId}/delivery/shipments/{shipmentId}/boxes

Path parameters

Name

Description

campaignId

Type: integer

广告系列(商店)的ID — 通过API工作时,代表您在Yandex市场系统中的商店的技术标识符。 它与您的商店唯一链接,但仅用于自动交互。

您可以使用查询找到它 GET v2/campaigns 或者在市场上的卖家办公室找到它。 点击您的帐户图标→ 设置 在左边的菜单中,选择 Api和模块:

  • 运动ID;
  • 标签 查询日志 →块中的下拉列表 显示日志.

⚠️ 不要把它与:

  • 商店的标识符,显示在商家的个人帐户中。
  • 广告活动。

Min value: 1

orderId

Type: integer

的订单ID。

shipmentId

Type: integer

传递任何数字以获得正确的数字。 URL.

货物区的ID。

Body

application/json
{
  "boxes": [
    {
      "fulfilmentId": "example"
    }
  ]
}

Name

Description

boxes

Type: object[]

fulfilmentId

Type: string

请勿使用此选项。

Pattern: ^[[a-zA-Z0-9]- ]*$

Example: example

货物位置列表。 市场根据它的长度来决定地点的数量。

Min items: 1

Example
[
  {
    "fulfilmentId": "example"
  }
]

Responses

200 OK

只有回应的类型才重要。 如果答案是 好的,货物量没有记录。

Body

application/json
{
  "status": "OK",
  "result": {
    "boxes": [
      {
        "id": 0,
        "fulfilmentId": "example"
      }
    ]
  }
}

Type: object

All of 2 types
  • Type: object

    status

    Type: string

    响应的类型。 可能的值:

    • OK — 没有错误。
    • ERROR — 处理请求时出错。

    Enum: OK, ERROR

    服务器响应的标准包装器。

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

    result

    Type: object

    boxes

    Type: object[]

    fulfilmentId

    Type: string

    请勿使用此选项。

    Pattern: ^[[a-zA-Z0-9]- ]*$

    Example: example

    id

    Type: integer

    顺序中的框的ID。

    货物位置列表。 市场根据其长度确定座位数量。

    Example
    [
      {
        "id": 0,
        "fulfilmentId": "example"
      }
    ]
    

    在响应中,市场返回您提供的货物位置列表。 不要关注这个领域。

    Example
    {
      "boxes": [
        {
          "id": 0,
          "fulfilmentId": "example"
        }
      ]
    }
    
    Example
    {
      "result": {
        "boxes": [
          {
            "id": 0,
            "fulfilmentId": "example"
          }
        ]
      }
    }
    

400 Bad Request

请求包含不正确的数据。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

401 Unauthorized

请求中未指定授权数据。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

403 Forbidden

授权数据不正确或禁止访问资源。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

404 Not Found

找不到请求的资源。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

420 Method Failure

已超出资源访问限制。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

500 Internal Server Error

Yandex中的内部错误。 市场。 有关错误的更多信息

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

      响应的类型。 可能的值:

      • OK — 没有错误。
      • ERROR — 处理请求时出错。

      Enum: OK, ERROR

      服务器响应的标准包装器。

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

      errors

      Type: object[]

      code

      Type: string

      的错误代码。

      Example: example

      message

      Type: string

      错误的描述。

      Example: example

      错误列表。

      Min items: 1

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

    服务器错误的标准包装器。

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

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