Basic Information
-
SERVICE_NAME: linkbest.service.links.post
-
Request Method: POST
Request Header
| Header Parameter | Required | Value | Description |
|---|---|---|---|
| Content-Type | Yes | application/json |
Common Parameters
| Parameter Name | Required | Example | Description |
|---|---|---|---|
| AppKey | Yes | 2312521 | App Key |
| Timestamp | Yes | 1596592757 | Second-level timestamp |
| Service | Yes | linkbest.service.links.post | Interface service name |
| Sign | Yes | 5D17CCCD5B29F98171D6D0D43136B366 | Signature |
Interface Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Url | string | Optional | URL to be converted, either ProgramId, ItemId, or Url must be provided |
| ProgramId | string | Optional | Program ID, either Url, ProgramId, or ProductId must be provided |
| ItemId | string | Optional | Product ID |
| WebsiteId | string | Yes | Promotion position ID |
| Original | string | Optional | Whether the original merchant link is needed |
| Ext | object | Optional | Extended parameters |
| └─ Coupon | string | Optional | Coupon |
| └─ SubId | string | Optional | Your sub-channel identifier |
| └─ Js | number | Optional | Whether JS redirection is needed. 1: JS redirection, 0: 302 redirection. Default is 1 if not provided |
Request Example
{
"Url": "string",
"ProgramId": "string",
"ItemId": "string",
"WebsiteId": "string",
"Original": "string",
"Ext": {
"Coupon": "string",
"SubId": "string",
"Js": 0
}
}Response Parameters
| Name | Type | Required | Default | Description | Other Information |
|---|---|---|---|---|---|
| Status | int | Optional | Status code | ||
| Data | object | Optional | Data object | ||
| └─ Wap | object | Optional | WAP-related information | ||
| ├─ Url | string | Optional | WAP long URL | ||
| ├─ Code | string | Optional | Taokouling (part of the links may have) | ||
| ├─ ShopCoupon | string | Optional | Shop coupon | ||
| ├─ OriginalLink | string | Optional | Merchant original link | ||
| └─ ShortUrl | string | Optional | Built-in short URL | ||
| └─ Pc | object | Optional | PC-related information | ||
| ├─ Url | string | Optional | PC long URL | ||
| ├─ Code | string | Optional | Taokouling (part of the links may have) | ||
| ├─ ShopCoupon | string | Optional | Shop coupon | ||
| ├─ OriginalLink | string | Optional | Merchant original link | ||
| └─ ShortUrl | string | Optional | Built-in short URL | ||
| └─ Wxapp | object | Optional | WeChat Mini Program-related information | ||
| ├─ WxPath | string | Optional | WeChat Mini Program page path | ||
| ├─ WxQrcode | string | Optional | WeChat QR code | ||
| ├─ WxGhid | string | Optional | WeChat account original ID | ||
| └─ WxAppid | string | Optional | WeChat Mini Program App ID | ||
| └─ LiveRoom | object | Optional | Live room-related information | ||
| └─ Code | string | Optional | Live room code | ||
| Message | string | Optional | Error message |
Response Example
{
"Status": "int",
"Data": {
"Wap": {
"Url": "string",
"Code": "string",
"ShopCoupon": "string",
"OriginalLink": "string",
"ShortUrl": "string"
},
"Pc": {
"Url": "string",
"Code": "string",
"ShopCoupon": "string",
"OriginalLink": "string",
"ShortUrl": "string"
},
"Wxapp": {
"WxPath": "string",
"WxQrcode": "string",
"WxGhid": "string",
"WxAppid": "string"
},
"LiveRoom": {
"Code": "string"
}
},
"Message": "string"
}