Skip to content

Sample code to connect respond.io with ClickSend.com

Notifications You must be signed in to change notification settings

respond-io/custom-channel-integration-example

Repository files navigation

Custom Channel Integration Server (Example)

This is a sample project to help you get started with integrating the respond.io platform with any third-party messaging service provider, as a "custom channel" within respond.io.

This example implements an SMS provider called ClickSend.com. The code can be used as a general reference.

API Routes

Method Path Type Description
POST /message Outbound Receive messages from respond.io and pass them to ClickSend using API
POST /clicksend/push_message Inbound Receive messages from ClickSend and pass them to respond.io via the custom channel webhook

Port: 3030.

Follow the steps here to get the custom channel API token.

Setup

Run the following commands:

  • npm install
  • npm start

How it works?

Outbound Messages

sequenceDiagram
    participant respond.io
    participant Custom Integration Server
    participant ClickSend.com
    respond.io ->> Custom Integration Server: Send outbound message. Route: /message
    Custom Integration Server->> ClickSend.com: Calls SMS send API with the outbound message
    ClickSend.com ->> Custom Integration Server: Send response: 200 OK or 4xx
    Custom Integration Server ->> respond.io: Send response: 200 OK or 4xx (with error message)
    
Loading

Inbound Messages

sequenceDiagram
    participant respond.io
    participant Custom Integration Server
    participant ClickSend.com
    
    ClickSend.com ->> Custom Integration Server: Receive inbound message. Route: /clicksend/push_message
    Custom Integration Server ->> respond.io: Calls custom channel webhook with the inbound message
    
    respond.io ->> Custom Integration Server: Send response: 200 OK or 4xx
    Custom Integration Server ->> ClickSend.com: Send response: 200 OK or 4xx
Loading

See the visual diagram on Whimsical

References

About

Sample code to connect respond.io with ClickSend.com

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Contributors 3

  •  
  •  
  •