Prerequisites
Before receiving messages, you need:- A phone number assigned to your application
- A webhook configured for the
MESSAGE_CREATEDevent
How It Works
- User sends an SMS or MMS to your Chirp phone number
- Chirp receives the message from the carrier
- Chirp creates a
MESSAGE_CREATEDevent - Chirp sends the event to your configured webhook URL
- Your application processes the message and responds
Webhook Payload
When an incoming message is received, Chirp sends a POST request to your webhook URL:Payload Fields
event - The event type (MESSAGE_CREATED)
data.id - Unique message identifier
data.from - Phone number that sent the message
data.to - Your Chirp phone number that received the message
data.text - Message text content (null if MMS with no text)
data.subject - MMS subject line (null for SMS)
data.mediaUrls - Array of media URLs for MMS messages
data.type - Message type (SMS or MMS)
data.direction - Always INBOUND for received messages
data.status - Message status (RECEIVED)
data.createdAt - ISO 8601 timestamp
Handling MMS Messages
MMS messages may include media attachments:mediaUrls.
Responding to Your Webhook
Your webhook endpoint should:- Respond with a
200 OKstatus code - Respond within 5 seconds
- Process the message asynchronously if needed
Testing Incoming Messages
Use the Playground to test incoming messages without sending real SMS:- Open the Playground in your dashboard
- Use a “User Phone Number” to simulate sending to your application
- Your webhook will receive the message in real-time
Webhook Retries
If your webhook endpoint fails to respond or returns an error:- Chirp will retry delivery
- Retries use exponential backoff
- Failed webhooks are logged in your dashboard