POSThttps://seller-api.playerauctions.com/api/v1/offers/item
为道具商品创建报价单。
i. 请求示例
{
"gameId": 3637,
"title": "Offer Title",
"offerDesc": "<p>Offer Description</p>",
"offerDuration": 30,
"agreeCheck": true,
"price": 5,
"serverId": 3638,
"categoryId": 3638,
"instruction": "this is an instruction.",
"deliveryGuarantee": 4,
"totalUnit": 2000,
"minUnitPerOrder": 1,
"discounts": [
{
"startPrice": 10,
"discountRate": 1
},
{
"startPrice": 50,
"discountRate": 2
},
{
"startPrice": 100,
"discountRate": 5
}
],
"rootItem": 290,
"itemId": 1243,
"otherItem": "",
"itemsPerUnit": 10,
"screenShot": "https://cdn-image.azureedge.net/title-image/liutest6/202606090117171717.png",
"itemPath": "290|1243"
}
ii. 请求参数
请求体参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
| gameId | int | 是 | 游戏ID。 |
| title | string | 是 | 商品标题。 |
| offerDesc | string | 否 | 商品描述。 |
| offerDuration | int | 是 | 商品有效期天数。可选值: 3, 7, 14, 或30。 |
| agreeCheck | bool | 是 | 同意 [Secure Seller Delivery Agreement] (用户发货安全协议)。必须为true(真)。 |
| price | decimal | 是 | 每份单价。 |
| serverId | int | 是 | 一级服务器ID。 |
| categoryId | int | 是 | 二级服务器ID。 |
| instruction | string | 否 | 发货说明。 |
| deliveryGuarantee | int | 是 | 发货期限。通过customId设置赋值。选项列表可通过(api/v1/games/{id}/{type}/deliveryTimes)接口获取。 |
| totalUnit | int | 是 | 总份数。 |
| minUnitPerOrder | decimal | 是 | 每单最少购买份数。 |
| discounts | array | 否 | 折扣规则。 |
| discounts[].startPrice | decimal | 是 | 折扣起始价格。 |
| discounts[].discountRate | decimal | 是 | 折扣率。 |
| rootItem | int | 是 | 一级道具ID。 |
| itemId | int | 是 | 二级道具ID。 |
| otherItem | string | 否 | 自定义道具名称。 |
| itemsPerUnit | decimal | 是 | 每份道具数量。 |
| screenShot | string | 否 | 商品图片链接。 |
| itemPath | string | 是 | 商品路径。格式: rootItemId|itemId。 |
iii. 响应示例
成功响应
{
"code": 10000,
"message": "",
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"data": {
"offerId": 71394134,
"navigateURL": "https://www.playerauctions.com/lol-items/71394134i!offer-title/",
"title": "Offer Title",
"productType": "item",
"gameName": "League of Legends",
"productName": "Items",
"screenShot": "https://cdn-image.azureedge.net/title-image/liutest6/202606090117171717.png",
"imageBlacklist": ""
}
}
响应参数
| 参数 | 类型 | 描述 |
|---|---|---|
| code | int | 响应状态码。 10000表示成功,其他值表示发生错误。 |
| message | string | 响应消息。 当请求失败时,该字段会包含具体的错误详情。 |
| requestId | string | 请求标识号,用以追溯。 |
| data.offerId | int | 新创建的商品 ID。 |
| data.navigateURL | string | 新创建的商品链接。 |
| data.title | string | 商品标题。 |
| data.productType | string | 商品类型。 |
| data.gameName | string | 游戏名称。 |
| data.productName | string | 商品名称。 |
| data.screenShot | string | 商品截图链接。 |
| data.imageBlacklist | string | 商品图片黑名单标识。该字段为空表示未加入黑名单。 |
iv. 报错示例
响应报错
{
"code": 10002,
"message": "Invalid parameter.",
"requestId": "550e8400-e29b-41d4-a716-446655440000"
}常见报错代码
| 参数 | 类型 | 描述 |
|---|---|---|
| code | int | 报错代码。 常见值: 10002 (无效参数), 50001 (服务器内部错误)。 |
| message | string | 报错详情。 |
| requestId | string | 请求标识号,用以追溯。 |