webhook get webhook
Description
取得webhook設定檔。
Resource
GET /v1/basic/webhook
Authorization
採用 OAuth 2.0 Bearer Token,詳細使用流程請參考 Auth Login。
僅限益欣內部使用(company_id = '24436074'),由此Token取得驗證Webhook acckey。
Query Parameters
| Name | Type | Description |
|---|---|---|
| id | int | webhook 流水號 |
Response Body Parameters
| Name | Type | Description |
|---|---|---|
| id | int | webhook 流水號 |
| url | string | 目標url |
| client_secret | string | 客戶端密碼 |
| usable | boolean | 是否啟用(true/false) |
| events | string[] | 啟用事件 |
| available_companies | available_company[] | 啟用公司 |
Response Body Parameters - available_company
| Name | Type | Description |
|---|---|---|
| id | string | company_id |
| name | string | company |
Request Example
GET /v1/basic/webhook?id=53
Response Body Example
Status-Code: 200
{
"id": 53,
"url": "https://api.mobilecardspr/d=3_rododohotpot4",
"client_secret": "123",
"usable": true,
"events": [
"order.cancel",
"order.finish"
],
"available_companies": [
{
"id": "0123456789",
"name": "益欣掃碼前結demo公司"
},
{
"id": "0229088978",
"name": "崔舍麻辣棧"
}
]
}
{
"message": "查無設定"
}