POST set-web-hook - Set Tracking Webhook

URL: /api/vendor/set-web-hook · Description: Set the tracking webhook callback URL of the current vendor; pass an empty string to clear / disable it.

Note: The tracking webhook URL is used to receive tracking callbacks. Once set, the system pushes tracking updates to this URL. Leaving it empty (passing an empty string) disables the push. This endpoint applies to the vendor identified by the current vendor-token.

Parameters

Parameter Required Type Description
tracking_hook Optional string Tracking webhook callback URL, max 255 characters; pass an empty string to clear / disable the push

Request Example

POST /api/vendor/set-web-hook
Header: vendor-token: xxxxx
Content-Type: application/json
{
    "tracking_hook": "https://www.example.com/api/tracking/callback"
}
Disable push: pass tracking_hook as an empty string "" to clear the configured URL.

Response Example

{
    "success": true,
    "message": "tracking_hook updated",
    "code": 200,
    "data": {
        "vendor_id": 1024,
        "tracking_hook": "https://www.example.com/api/tracking/callback"
    }
}
data field Type Description
vendor_id int Current vendor ID
tracking_hook string The tracking webhook URL after update (empty string means cleared / not set)