Documentation

HTTP API Documentation


https://api.waapi.me

Send message


This request allows you to send a simple text message through WaAPI instance. Use this method when you need to send a basic text message through the bot to specific contact.


Request


This section provides an example HTTP request for sending a text message. Ensure that the correct instance ID, recipient’s phone number, and message content are specified in the request body to ensure the message is delivered properly.


POSThttps://api.waapi.me/message/send

Headers


When making this request, it`s important to include Authorization HTTP header


Authorization: <YOUR_API_KEY>

Body


Here, you’ll find an example JSON request data and a detailed table that describes each field.


Field
Required
Default
Type
Description
instanceIdyes-string|uuid(4)Instance(bot) id
phoneyes-string|phoneRecipient phone number
bodyyes-string|min:4|max:60Message body

{
    "instanceId": "407b5752-1e57-40cc-a803-a49ecf650266",
    "phone": "78005553535",
    "body": "Hello from WaAPI."
}

Response


Here, you’ll find an example JSON response and a detailed table that describes each field. The JSON response confirms the successful creation of the bot instance and includes key details, like the instance ID and initial configuration settings. Refer to the table to understand each field’s meaning and format.


Field
Type
Description
idstringMessage id
instanceIdstring|uuidInstance(bot) id
fromstringFrom phone number
tostringTo phone number
bodystringMessage body
statusstring|enumMessage status
typestring|enumMessage direction type, from instance or to instance
errorstring|nullError message
readbooleanIf true message was read by recipient

{
    "id": "6724f988204191f30af53473",
    "instanceId": "c3996092-b982-4af7-8cf1-0cfafea5143c",
    "from": "78005553535",
    "to": "78005553636",
    "body": "Hello form WaAPI!",
    "status": "sent",
    "type": "outcome",
    "error": null,
    "read": true
}