Skip to content
On this page

Push Message

Functionality

API for pushing messages, supports both text and image messages.

Interface Address

/message/{chatToken}

Parameter Description

ParameterTypeRequiredDescription
textStringYesText content (can be empty when photo exists)
photoStringNoImage file or image link
parseModeStringNoStyle of the text content, can be Markdown or HTML

Usage Example

bash
# using get
# Push text message
curl -X GET https://pushbot.dev/message/{chatToken}?text=HelloWorld
# Push image
curl -X GET https://pushbot.dev/message/{chtToken}?photo=https://xxx.com/xxxxx.jpg

# using post
# Push text message
curl -d '{"text":"HelloWorld"}' -X POST https://pushbot.dev/message/{chatToken}
# Push image
curl -d '{"photo":"https://xxx.com/xxxxx.jpg"}' -X POST https://pushbot.dev/message/{chatToken}