LogoLogo
No-code docsResources
  • 🖥️Welcome to the Bird API Docs
  • API Access
    • Access Policies
    • Access Roles
    • API Authorization
    • Common API usage
  • Conversations API
    • API reference
      • Channel configuration
        • Get conversations configuration
        • Update conversations configuration
      • Conversations messaging
        • Create conversation message
        • List conversation messages
        • Get conversation message
        • Update conversation message
        • Delete conversation message
        • Create pre-signed upload
      • Conversations management
        • Create conversation
        • List conversations
        • Get conversation
        • Update conversation
        • Delete conversation
      • Conversation Participants
        • Add participant to conversation
        • List participants
        • Get participant by ID
        • Get participant by identifier key and value
        • Update participant by ID
        • Update participant by identifier key and value
        • Delete participant
        • List participant conversations by ID
        • List participant conversations by identifier key and value
      • Workspace settings
        • Get antispam setting
        • Update antispam setting
        • Create allow/block rule
        • Get allow/block rule
        • List allow/block rules
        • Update allow/block rule
        • Delete allow/block rule
        • Add allow/block rules in bulk
        • Get allow/block bulk upload status
      • Events
  • Collaborations API
    • API reference
      • Agent Management
      • Team Management
      • Feeds
      • Feed item activity
      • Tags
      • Automation Rules
      • Business Hours
      • Capacity Rules
      • Routing Queues
      • Skills
      • SLA Policies
      • Macros
      • Sender Profiles
      • Ticket fields
  • Channels API
    • Supported channels
      • Programmable WhatsApp
        • Sending WhatsApp messages
        • Customer service window
        • Receiving messages
        • Message interactions
        • WhatsApp ISV integration
          • Setting up your customer workspaces
            • API Access
            • Associating your Facebook solution ID and business ID with your Bird CRM Organization
            • Creating a workspace for your customer
            • Buying a number through Bird
            • Subscribing to channel created webhooks
          • WhatsApp channel onboarding
            • Setting up the WhatsApp Embedded flow
            • Install WhatsApp phone number in Bird CRM
            • Subscribe to channel webhooks
      • Programmable SMS
        • Installing an SMS channel
          • US 10DLC API Installation
          • Toll-Free Numbers Verification API
        • Sending SMS messages
        • Receiving messages
        • Twilio Exit API
          • Using Twilio PHP SDK
          • Using Twilio Go SDK
          • Using Twilio Ruby SDK
        • Sinch Exit API
      • Programmable RCS
        • Sending messages
        • Receiving messages
        • Message interactions
      • Programmable Email
        • Sending Emails
        • Receiving messages
        • Message status
        • Message interactions
      • Programmable Line
        • Sending messages
        • Receiving messages
        • Message interactions
      • Programmable Telegram
        • Sending messages
        • Receiving messages
        • Message interactions
    • Message types
      • Text
      • Images
      • Files
      • List
      • Carousel
      • Template
    • Message status and interactions
      • Message Failure Codes
      • Message Failure Sources
        • SMS Platform Extended Error Codes
    • Send batch messages
    • API reference
      • Channel Groups
      • Messaging
      • Channels management
      • Channel connectors
      • Navigators
      • Compliance Keywords Messages
      • Conversions Sharing
      • Events
    • Rate Limit
  • Voice API
    • Installing a Voice channel
    • Voice Calls API
      • Initiate an outbound call
      • List calls from a channel
      • Get a call
      • Update a call
      • Answer a call
      • Ring a call
      • Hangup a call
      • Play a message in a call
      • Say Text-To-Speech (TTS)
      • Gather DTMF from a call
      • Forward a call
      • Record a Call
      • Record a call session
      • Update a call recording
      • List call recordings of a call
      • Get a call recording
      • Get a call insights
      • Get calls log
    • Recordings API
      • List Recordings
      • Get a Recording
      • Delete a Recording
      • List recording storage metrics
    • Transcriptions API
      • Initiate a Transcription
      • List Transcriptions
      • Get a Transcription
      • Delete a Transcription
    • Voice webhooks
    • Flash Calling API
  • Verify API
    • Verify API: Quick Start
  • Contacts API
    • Tracking Contact Events
      • API Reference
        • Get configuration
        • Track events
    • API reference
      • Manage workspace contacts
        • Create a contact
        • Get a contact
        • List contacts
        • Search contact by identifier
        • Update a contact
        • Create or update a contact by identifier
        • Delete a contact
      • Manage contact identifiers
        • Create contact identifier
        • List contact identifiers
        • Delete contact identifier
      • Manage contact attribute definition
        • Create attribute definition
        • Get attribute definition
        • List attribute definitions
      • Manage contact lists
        • Create a list
        • Get a list
        • List lists
        • Update a list
        • Delete a list
        • Add contacts to a list
        • Get contact list memberships
        • List contacts in a list
        • Remove contacts from a list
      • Lookup
        • Network/Country information for a phone number
  • Numbers API
    • API reference
      • Search Available Numbers
      • Buy a Number
      • List your Numbers
      • Get Long Code Number Details
      • Manage Endpoint Subscriptions
        • Cancel Number Subscription
      • Manage Endpoint Compliance Requirements
        • List Workspace compliace Requirements
        • Get Workspace Compliace Requirements
        • Update Workspace Compliace Requirements
      • 10DLC Compliance
        • Brands - Organization
          • Create a brand
          • List all brands
          • Get a brand
          • Update a brand
          • Delete a brand
          • Create a brand vetting
        • Brands - workspace
          • Create a brand
          • List all brands
          • Get a brand
          • Update a brand
          • Delete a brand
          • Create a brand vetting
          • List brand vettings
        • Campaigns
          • Optional: acting as Reseller
          • Create a campaign
          • List all campaigns
          • Get a campaign
          • Update a campaign
          • Delete a campaign
        • TCR Enums
        • Events
      • Toll-Free Numbers Verification API
      • Long Code Numbers
      • Short Code Numbers
      • Alphanumeric Senders
      • Events
  • Know-Your-Customer (KYC) API
    • List KYC forms
    • Get KYC form
    • Create KYC form entry
    • Update KYC form entry
    • List KYC form entries
    • Get a KYC form entry details
  • Reporting API
    • API reference
      • Channel Metrics
      • Flow Run Metrics
      • Wallet Metrics
      • Campaign Metrics
      • Message Metrics
  • Accounts API
    • API reference
      • Current user
        • Change password
        • Presigned upload
        • Memberships
        • Sessions
        • Configurations
          • Groups
            • Keys
      • IAM policies
      • Organizations
        • Upload media
        • Profile
        • Workspaces
        • Users
        • Access keys
        • Organization roles
        • Organization policies
        • Teams
          • Members
        • Approvals
          • Runs
            • Reviews
        • Configurations
          • Groups
            • Keys
      • Region groups
  • Touchpoints API
    • Supported Projects
      • Whatsapp Approved Message Templates
        • Creating WhatsApp Message templates
          • Text template blocks
          • Blocks Documentation
    • API reference
      • Projects
      • Message Templates
  • Notifications API
    • API Reference
      • Webhook subscriptions
        • Create a webhook subscription
        • List available webhook events
        • Get a webhook subscription
        • List webhook subscriptions
        • Update a webhook subscription
        • Delete a webhook subscription
        • Verifying a webhook subscription
        • Webhook subscription logs
  • Knowledge Base (KB) API
    • API reference
      • Documents
      • Folders
        • Import
      • Search
      • Presigned upload
  • Email API
    • Transmissions
  • Connectivity platform migration guide
    • Channels API and Conversations API
    • Migrating conversations API actions
    • Migrating WhatsApp channels
  • Client SDKs
    • Applications
    • Contact Profiles
      • Signed Identity
    • Push notifications
      • Quick Start
      • Subscribe contacts to push notification campaigns
      • Notification Display Priority
    • Event Tracking
      • Quick Start
      • Track Events
        • App
        • Audiences
        • Conference
        • Ecommerce
        • Hospitality
        • Lists
        • Messaging
        • Payments
        • Subscription
        • Suppressions
        • Survey
        • Web
    • App Inbox
      • Quick Start
      • Usage
      • Subscribe contacts to app inbox campaigns
    • SDK Integration
      • Android SDK
        • Notification Interactions
      • Swift SDK
        • Notification Interactions
      • Web SDK
        • Quick Start
        • Usage
        • API Reference
          • IdentityManager
          • BirdSdkApi
          • BirdTracker
            • Ecommerce
            • Conference
            • Messaging
            • Suppressions
            • Subscription
            • Survey
            • Web
            • Audiences
        • Web Push Notifications
          • Notification Interactions
  • Quickstarts
    • Conversations
    • Send an SMS message
    • Send an Email message
    • Send a WhatsApp message
Powered by GitBook
On this page

Was this helpful?

  1. Channels API
  2. Supported channels
  3. Programmable SMS

Sinch Exit API

Last updated 1 year ago

Was this helpful?

If you already have an integration using the Sinch SMS API to send and receive SMS messages (basic send and receive only), you can use this guide to start sending your SMS messages through Bird without having to rewrite your API integration.

The Bird Sinch Exit API allows you to send SMS messages through the Bird Engagement Platform, using your existing Sinch Integration. It acts as an adapter that translates the requests and responses from the Sinch format to Bird format and vice versa.

How does it work?

Your Sinch integration will send the request using the Sinch API format to the Bird Sinch Exit API. Our API will accept the Sinch formatted request, translate it to Bird's format, process the message, and then translate our response to the Sinch API response format you're expecting, ta-da! You don't have to rewrite all of your integration to start sending messages via Bird.

Setup the integration

  1. Setup your Bird Engagement Platform account

  2. Install an SMS channel

  3. Copy your main keys

  4. Update your Sinch integration URL and keys

  5. Setup your Webhook to receive events and incoming messages

Setup your Bird account

Login to your Bird Engagement Platform account or for a new account if you don't have one.

Install an SMS channel

You will need to install an SMS channel on a working phone number. Follow this guide on how to .

Copy your main keys

You will need:

  • The phone number of the SMS channel you're sending messages from

Update your Sinch Integration

Now that you have all the keys you need, you will need to do minimal change to your existing Sinch integration.

  1. Update the domain name from https://[us|eu|au|br|ca].sms.api.sinch.com to one of the following domains:

    • EU (for Europe region): https://eu-west-1.sinch.to.api.bird.com

    • US (for US region): https://us-west-1.sinch.to.api.bird.com

  2. Update your service_plan_id to use your Bird WorkspaceID

  3. Update your Token to use your Bird AccessKey

  4. Update the “From” number to the phone number you used to setup the SMS channel on our end

That's it! You're ready to start sending SMS messages via Bird.

Setup a Webhook subscription

Setting up a webhook subscription can currently be done via the API using the following endpoint:

Here is an example of such a request

{
    "service": "channels",
    "event": "sms.inbound",
    "eventFilters": [{
        "key": "channelId",
        "value": "{{channel_id}}"
    }],
    "template": "sinch",
    "url": "https://your.site/webhook/url",
    "signingKey": "your-secret-signing-key"
}

Bird webhooks are signed using the SigningKey specified when creating your webhook subscription.

Make sure you keep your SigningKey safe, as it's used to verify the authenticity of the webhook requests.

Setup a Webhook subscription to receive incoming messages

Setting up a webhook subscription is an optional step and is only needed if you need to receive inbound messages (2-way messaging use case). Much like Sinch, Bird's webhooks are set up by channel instance. So, for SMS, webhooks are set up by number.

To receive webhooks for incoming SMS messages on your SMS channel, you need to set up a webhook subscription by using the above request. For incoming messages, set the event to sms.inbound. You can choose to receive this webhook in the Sinch format by setting the template parameter to sinch.

Setup webhook subscription for status reports for outbound messages

You can also set up webhooks for status reports for outbound messages by using the sms.outbound event. This is required to make webhooks work for outbound messages since we need a signing key to sign the request.

When you use callback_url to subscribe to webhooks for outgoing messages, this URL overwrites the default URL set in the above request and sets the template to use the sinch template, regardless of the subscription settings.

Bird also employs a secure way of signing requests. When using the sinch template, we will sign our requests the Bird way, with the Bird header.

Sinch Exit API Explained

Our Sinch Exit API translates requests using the Sinch format to the Bird format, before sending it to the Bird API. And on receiving a response from our API, it translates it back into the Sinch format. This section explains which endpoints are supported and how we translate and map fields between both APIs.

Endpoints

Currently, the Sinch Exit API is limited to sending SMS messages exclusively through your Sinch Integration. The supported endpoints are:

Operation
Endpoint

Send message

POST /xms/v1/{{workspaceID}}/batches

Fetch message

GET /xms/v1/{{workspaceID}}/batches/{{messageID}}

List messages

GET /xms/v1/{{workspaceID}}/batches

Message response

The message object's response resembles Sinch's, though some fields may be empty. Below is an example of our responses:

JSON field
Status
Bird field
Example

id

id

"id":""

to

receiver.contacts[].

identifierValue

"to":["+31623456789"]

from

sender.connector.identifierValue

"from": "+1234567890"

body

body.text.text

"body": "Hello World!"

type

-

"type": "mt_text"

canceled

-

"canceled": false

delivery_report

-

"delivery_report": "none"

client_reference

reference

"client_reference": "abcdef"

created_at

createdAt

"created_at": "YYYY-MM-DDThh:mm:ss.SSSZ"

modified_at

updatedAt

"modified_at": "YYYY-MM-DDThh:mm:ss.SSSZ"

expire_at

-

"expired_at":""

Create message

Form field
Status

service_plan_id (Path)

to[] (Required)

from (Required)

body (Optional)

delivery_report (Optional)

callback_url (Optional)

client_reference (Optional)

parameters (Optional)

type (Optional)

sent_at (Optional)

expire_at (Optional)

feedback_enabled (Optional)

flash_message (Optional)

truncate_concat (Optional)

max_number_of_message_parts (Optional)

from_ton (Optional)

from_npi (Optional)

Response

List messages

Request

Filtering messages can be done using the following query string parameters:

Query parameter
Status

service_plan_id (Path)

page (Optional)

page_size (Optional)

from (Optional)

start_date (Optional)

end_date (Optional)

Response

JSON response
Channels field

page

page_size

count

batches

Your (click Edit workspace to see your ID)

Full webhooks API documentation can be found .

Supported

Supported

Supported

Supported

Always mt_text

Always false

Always none

Supported

Supported

Supported

Supported

Use your Bird WorkspaceID

Supported, only the first item will be used to send to

Supported. Must be the number of an active SMS channel in MessageBird.

Supported

Always per_recipient if used

Supported

Supported

Ignored if used

Always mt_text

Ignored if used, scheduling not supported

Ignored if used, validity not supported

Ignored if used

Ignored if used

Ignored if used

Ignored if used

Ignored if used

Ignored if used

See .

Use your Bird WorkspaceID

Not Supported

Supported, but with a maximum of 100

Supported

Supported

Supported

Supported

Supported

Supported

Supported: See message response

Sign up
install an SMS channel
workspace ID
Access key
here
message response
🟢
🟢
🟢
🟢
🟡
🟡
🟡
🟢
🟢
🟢
🟢
🟢
🟠
🟢
🟢
🟠
🟢
🟢
🟠
🟠
🟠
🟠
🟠
🟠
🟠
🟠
🟠
🟠
🟢
🔴
🟡
🟢
🟢
🟢
🟢
🟢
🟢
🟢
  • How does it work?
  • Setup the integration
  • Setup your Bird account
  • Install an SMS channel
  • Copy your main keys
  • Update your Sinch Integration
  • Setup a Webhook subscription
  • POSTSet up a webhook subscription
  • Sinch Exit API Explained
  • Endpoints
  • Message response
  • Create message
  • List messages

Set up a webhook subscription

post
Path parameters
organization_idstringRequired

The ID of the organization

workspace_idstringRequired

The ID of the workspace

Body
servicestringOptional
eventstringOptional
templatestringOptional
urlstringOptional
signingKeystringOptional
Responses
200
Successful response
400
Bad request
post
POST /organizations/{organization_id}/workspaces/{workspace_id}/webhook-subscription HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 131

{
  "service": "text",
  "event": "text",
  "eventFilters": [
    {
      "key": "text",
      "value": "text"
    }
  ],
  "template": "text",
  "url": "text",
  "signingKey": "text"
}

No content