用戶推播
用戶推播有兩種方式可以使用,依據使用環境來選擇適用的推播
Send broadcast messages to customers
Authorizations
Query parameters
botIdstringRequired
The bot ID for the API request
Body
Additional validation rules:
- Either intentId or message must be provided (cannot both be empty)
- fbTag is required when platform is 'facebook'
secretstringRequiredExample:
Secret key for API authentication
your_secret_key_here
intentIdstringOptionalExample:
Intent identifier for the broadcast (required if message is empty)
VolejRejN
messagestringOptionalExample:
Message content to broadcast (required if intentId is empty)
Hello, this is a broadcast message
clientIdsstring[]OptionalExample:
Array of platform UUIDs to send the broadcast to
["client_1","client_2","client_3"]
platformstring · enumRequiredExample:
Platform to send the broadcast on (required)
line
Possible values: fbTagstringOptionalExample:
Facebook tag for the broadcast (required when platform is 'facebook')
ACCOUNT_UPDATE
Responses
200
Broadcast sent successfully
application/json
401
JWT token is invalid or expired
application/json
403
Permission or broadcast creation failed
application/json
404
Resource not found
application/json
429
Rate limit exceeded
application/json
500
Internal server error
application/json
post
POST /api/openapi/broadcast HTTP/1.1
Host: mantago.cc
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 193
{
"secret": "your_secret_key_here",
"intentId": "VolejRejN",
"message": "Hello, this is a broadcast message",
"clientIds": [
"client_1",
"client_2",
"client_3"
],
"platform": "line",
"fbTag": "ACCOUNT_UPDATE"
}
{
"success": true,
"message": "Send customer broadcast successfully"
}
Last updated