BIND
2

Combine channels

List more than one channel and we send on the first, moving to the next only when the previous one did not deliver. There is no failover switch: the number of entries decides it. An sms entry must be the last one.

failover_after sets how many seconds to wait for a DELIVERED report before trying the next channel, and each channel can have its own wait. Each entry has its own content, so the SMS can be written for SMS, with the link spelled out instead of a button.

Request

curl -X POST "https://channels.bind.hr/v1/messages" \
  -H "Authorization: Bearer $BIND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "channels": [
      {
        "channel": "whatsapp",
        "profile_number_id": "7d3c1b0e-9a51-4c1b-8f7e-2f6a9d0c4b11",
        "to": "447123456789",
        "failover_after": 60,
        "content": {
          "type": "template",
          "template": {
            "name": "order_shipped",
            "language": {
              "code": "en_US"
            },
            "components": [
              {
                "type": "body",
                "parameters": [
                  {
                    "type": "text",
                    "text": "Alex"
                  },
                  {
                    "type": "text",
                    "text": "ORD-58213"
                  }
                ]
              },
              {
                "type": "button",
                "sub_type": "url",
                "index": 1,
                "parameters": [
                  {
                    "type": "text",
                    "text": "ORD-58213"
                  }
                ]
              }
            ]
          }
        }
      },
      {
        "channel": "sms",
        "profile_id": "b3d9e7a1-5c24-4f38-8e6b-9a0c1d2e3f45",
        "to": "447123456789",
        "content": "Your order #4182 has shipped. Track it: https://example.com/t/4182"
      }
    ]
  }'

Ready to send your first message?

We set up your account, sender profiles and API key with you, and help you through the first integration.

Bind console showing an SMS profile going live