仓库和仓库组列表
方法适用于模式:FBS, Express 和 DBS.
如果您使用API-Key令牌,调用该方法时需要具备列表中可用权限之一
我应该使用哪种方法而不是过时的方法?
返回仓库列表,如果合并了仓库,则返回仓库组列表。 什么是仓库组,为什么需要它们?
除其他外,该请求允许您确定在为一组仓库转移余额时要使用的标识符。
| ⚙️ 限制: 每分钟100个请求 |
|---|
Request
GET
https://api.partner.market.yandex.ru/v2/businesses/{businessId}/warehouses
Path parameters
|
Name |
Description |
|
businessId* |
Type: integer<int64> 内阁ID。 要找到答案,请使用请求 GET v2/campaigns. Min value: |
Responses
200 OK
仓库和仓库组的列表。
Body
application/json
{
"status": "OK",
"result": {
"warehouses": [
{
"id": 0,
"name": "string",
"campaignId": 0,
"express": false,
"address": {
"city": "string",
"street": "string",
"number": "string",
"building": "string",
"block": "string",
"gps": {
"latitude": 0,
"longitude": 0
}
}
}
],
"warehouseGroups": [
{
"name": "string",
"mainWarehouse": {
"id": 0,
"name": "string",
"campaignId": 0,
"express": false,
"address": {
"city": "string",
"street": "string",
"number": "string",
"building": "string",
"block": "string",
"gps": {
"latitude": 0,
"longitude": 0
}
}
},
"warehouses": [
{
"id": 0,
"name": "string",
"campaignId": 0,
"express": false,
"address": {
"city": "string",
"street": "string",
"number": "string",
"building": "string",
"block": "string",
"gps": {
"latitude": 0,
"longitude": 0
}
}
}
]
}
]
}
}
|
Name |
Description |
||||
|
status* |
Type: string 响应的类型。 可能的值:
Enum: |
||||
|
result |
Type: object
有关仓库和仓库组的信息。 |
400 Bad Request
请求包含不正确的数据。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
401 Unauthorized
请求中未指定授权数据。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
403 Forbidden
授权数据不正确或禁止访问资源。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
404 Not Found
找不到请求的资源。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
420 Method Failure
已超出资源访问限制。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
500 Internal Server Error
市场的内部错误。 有关错误的更多信息
Body
application/json
{
"status": "OK",
"errors": [
{
"code": "string",
"message": "string"
}
]
}
|
Name |
Description |
|
errors |
Type: object[] 错误列表。 Min items: |
|
status |
Type: string 响应的类型。 可能的值:
Enum: |
No longer supported, please use an alternative and newer version.