Skip to main content

Sending Messages

The core of WazzAPI is the ability to send various types of messages to your users.

Text Messages

Simple text messages are the most common way to communicate.
curl -X POST https://api.wazzapi.io/api/v1/messages \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "to": "+1234567890",
    "type": "text",
    "text": { "body": "Hello, world!" }
  }'

Media Messages

You can send images, videos, documents, and audio files by providing a public URL.
curl -X POST https://api.wazzapi.io/api/v1/messages \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "to": "+1234567890",
    "type": "image",
    "image": { "link": "https://example.com/image.png" }
  }'

Location Messages

Share a specific location with your users.
curl -X POST https://api.wazzapi.io/api/v1/messages \
  -d '{
    "to": "+1234567890",
    "type": "location",
    "location": {
      "longitude": -122.4194,
      "latitude": 37.7749,
      "name": "San Francisco",
      "address": "San Francisco, CA"
    }
  }'