Skip to main content

Quickstart: Send Your First Message

This guide walks you through sending your first message with the SendSeven API. You'll be up and running in under 5 minutes.

Prerequisites

  • A SendSeven account (free trial includes 100 messages)
  • At least one channel connected (WhatsApp, Telegram, etc.)

Step 1: Create an API token

  1. Log in to SendSeven
  2. Go to Settings > API Tokens
  3. Click Create Token
  4. Name it (e.g., "My First Integration")
  5. Select scopes: messages:create, conversations:read, contacts:read
  6. Click Create and copy the token
warning

The token is only shown once. Copy it immediately and store it securely.

Step 2: Set up your credentials

Save the token as an environment variable:

export SENDSEVEN_TOKEN="s7_api_your_token_here"
info

API tokens have your tenant embedded - no separate Tenant ID is needed.

Step 3: List your conversations

Verify your credentials by listing conversations:

curl -s "https://api.sendseven.com/api/v1/conversations?page_size=5" \
-H "Authorization: Bearer $SENDSEVEN_TOKEN" | python3 -m json.tool

You should see a JSON response with your conversations.

Step 4: Send a message

Pick a conversation_id from the response above and send a message:

curl -X POST "https://api.sendseven.com/api/v1/messages" \
-H "Authorization: Bearer $SENDSEVEN_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"conversation_id": "PASTE_CONVERSATION_ID_HERE",
"text": "Hello from the API!",
"message_type": "text"
}'

Response

{
"id": "msg_abc123",
"conversation_id": "conv_xyz789",
"direction": "outbound",
"text": "Hello from the API!",
"message_type": "text",
"status": "queued",
"created_at": "2026-02-10T15:00:00Z"
}

The message status starts as queued and progresses to sent > delivered > read.

Step 5: Send to a contact directly

You can also message a contact without knowing the conversation ID. Pass the contact_id and channel_id in the request body:

curl -X POST "https://api.sendseven.com/api/v1/messages" \
-H "Authorization: Bearer $SENDSEVEN_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"contact_id": "CONTACT_ID",
"channel_id": "CHANNEL_ID",
"text": "Your order has shipped!",
"message_type": "text"
}'

SendSeven will automatically find or create a conversation for this contact on the specified channel.

What's next?

Now that you've sent your first message, explore these guides: