Skip to Content
Cloud One
  • Products

    Business Communication Suite & Phone System


      By Edition

      ​Cloud

      Software

      Appliance

    By Deployment

    ​On-premise

    Hosted by Cloud One

    Self-hosted

    By Management

    ​Managed By Cloud One

    Semi-Managed by Cloud One

    Self-Managed


    Simu Connect UC Clients


    Simu Connect Web Client Simu Connect Mobile Client Simu Connect Desktop ClientSimu Connect Chrome ExtensionSimu Connect TAPI Integration

    SIP Trunks


    Business SIPPay As You Go SIP Country Presence SIPVirtual Phone NumbersGolden Phone NumbersToll Free NumbersBring Your Own Carrier (BYOC)Calling RatesTalktime Top-up

    Get a Proof of Concept Now!


    Simu Connect POC Application Managed Business Communication Suite Self Managed Business Communication SuiteSIP Trunk POCOdoo Phone POC
  • Solutions

    Business Needs


    Work from Anywhere Hosted UCaaS Self hosted UCaaSVideo ConferencingAppliance PBXAI-powered Cloud PBXWhite-label Solution

    Industry


    Call Center Healthcare HospitalityFinanceEducationLogisticsRetail BusinessGovernment Agency

    Ecosystem


    IP Phones SIP Trunks IntegrationHeadsetsVirtual Phone Numbers

    By Integration


    Odoo Phone System Zoho Phone System Salesforce Phone SystemMicrosoft Dynamics Phone SystemZendesk Phone SystemFreshdesk Phone SystemBitrix24 Phone SystemHubSpot Phone System
  • Resources

    Downloads

    Download user guides and more documents

    Book a Meeting

    Schedule a meeting at your convenience

    Developer Guide

    Read API Documentation for Cloud One BCS API

    Business Communication Suite

    Experience our user-friendly business communication suite today. Explore robust telephony features that enhance your client connections efficiently.  

    See More Details
  • Devices

    Yealink IP Phones


    Yealink T3 Series IP Phones Yealink T4 Series IP Phones Yealink T5 Series IP PhonesYealink T7 Series IP PhonesYealink T8 Series IP Phones Yealink DECT IP Phones

    Voice Conferencing Solutions


    VC Room Systems BYOD Solutions Video Phone Video Conferencing Accessories

    Microsoft Solutions


    MS Teams Rooms Systems Microsoft Phones Conference Phones HeadsetsYealink MeetingBoardYealink MeetingBoard Pro

    Zoom Rooms


    Zoom Rooms Systems Zoom Phones Zoom Cameras BYOD Solutions
  • Help

    Ticketing System


    Submit a Helpdesk TicketReport an Issue

    Training


    User TrainingOperator TrainingCall Center Agent TrainingSupervisor Training

    Frequently Asked Questions


    General FAQBCS FAQSIP Trunks FAQLocal Phone Numbers FAQ

    Contact Us


    WhatsApp Icon


  • Support Helpdesk Contact
  • +254 20 790 0100
  • support@cloudone.co

  • Accounts Helpdesk Contact
  • +254 20 790 0000
  • finance@cloudone.co
  • Visit our Office


    Cloud One Ltd

    Saachi Plaza - Unit A3, Argwings Kodhek Road, Nairobi, Kenya
    P.O.Box 76484-00508 Yaya Centre

    +254 20 790 0000

    hello@cloudone.co


    Kindly do not email multiple contacts as it creates multiple tickets on our CRM


  • Contact Us
  • Blog
    ​​
  • Sign in
  • 0
  • 0
  • Deploy in hours Certified Experts Zero Setup / License Fees*
  • Follow us
    Click here to setup your social networks
    Click here to setup your social networks
Cloud One
  • 0
  • 0
    • Products
    • Solutions
    • Resources
    • Devices
    • Help
    • Contact Us
    • Blog
  • Deploy in hours Certified Experts Zero Setup / License Fees*
  • Follow us
    Click here to setup your social networks
    Click here to setup your social networks
  • Sign in
  • ​​

Add a Message Channel

Add and configure a message channel.

Note:This API endpoint can be used to create an SMS channel, WhatsApp channel, or Facebook channel. To create a Live Chat channel, see Add a Live Chat Channel.

Request URL

POST {base_url}/{api_path}/message_channel/create?access_token={access_token}

Request parameters

Send different request parameters according to different types of message channel.

  • Add an SMS channel
  • Add a WhatsApp channel
  • Add a Facebook channel

Add an SMS channel

ParameterRequiredTypeDescription
nameYesStringMessage channel name.
Note: The length must not exceed 127 characters.
webhook_url_typeYesStringThe type of domain used in the Webhook URL.
Valid value:
  • fqdn
  • nat
channelYesStringThe service provider of the message channel.
Valid value:
  • general
  • alhambra
  • apidaze
  • aspsms
  • athena
  • bandwidth
  • flowroute
  • ixica
  • netplanet
  • siptrunk
  • skyetel
  • telnyx
  • twilio
  • vetta
  • voicemeup
  • voipms
  • voxtelesys
account_dataYesArray<Auth_Info>The data required by the service provider for message channel connection.
send_rateNoIntegerSpecify the number of messages that PBX can send per second via the message channel.
auto_close_sessionNoIntegerWhether to automatically close a message session after it has been inactive for a specified period of time.
session_expired_timeNoIntegerThe duration of inactivity (in days) after which a session is automatically closed.
enb_duplicate_active_sessionNoIntegerWhether to allow creating a new session when an active session with the same sender and receiver already exists.
Valid value:
  • 0: Disallow (default).
  • 1: Allow. A new session can be created even if an active session with the same sender and receiver already exists. After creation, the original session will be removed from the previous handler's session list and taken over by the new creator with the complete chat history.
accompanying_msgNoStringThe accompanying text content for chat file.
Note: This parameter is REQUIRED when creating an Apidaze SMS channel.
didsNoArray<Msg_Routing>Define the message routing rule by adding the DID number(s), setting message destination, and specifying members that are allowed to initiate message sessions via specified DID number.

Auth_Info

Note: Provide the required parameter values according to the requirements of different SMS service providers.

ParameterRequiredTypeDescription
kYesStringThe name of the key field required by the service provider.Valid value:
  • For General / Alhambra IT / Athenna / IXICA / NETPLANET / Vetta / VoIP.ms / Voxtelesys

    • api_key
    • api_secret (Optional)
    • api_verify_url (Optional): API endpoint for authentication verification.
    • api_send_url: API endpoint for sending messages.
  • For Apidaze

    • api_key
    • api_secret
  • For Aspsms

    • user_key
    • password
  • For Bandwidth

    • application_id
    • account_id
    • username
    • password
  • For Flowroute / SIPTRUNK

    • access_key
    • secret_key
  • For Skyetel

    • sid_key
    • secret_key
  • For Telnyx

    • api_key
    • public_key
  • For Twilio

    • account_sid
    • auth_token
  • For VoiceMeUp

    • username
    • auth_token
vYesStringThe value associated with the key field k.

Valid value:

  • If k is api_verify_url or api_send_url, enter the API endpoint as https://{{your-endpoint}}.
  • For all other key fields, enter the key value in Base64-encoded format.

Msg_Routing

ParameterRequiredTypeDescription
did_numberYesStringThe DID number associated with the message channel.
destination_typeYesStringThe type of the destination.

Valid value:

  • extension: Extension user.
  • queue: Message queue.
  • api: Third-party message analytics platform (via API).
destination_idNoStringThe unique ID of destination to which inbound messages are sent.
Note:
  • This parameter is REQUIRED when the destination_type is set to extension or queue.
  • You can query the extension ID using Search Specific Extensions, and query the message queue ID using Search Specific Message Queues.
membersNoArray<Members>The members that are allowed to initiate message sessions using the DID number.

Members

ParameterRequiredTypeDescription
typeYesStringMember type.

Valid value:

  • extension
  • ext_group
  • organization
valueYesStringThe unique ID of the member.
Note:You can query the member ID using Get Menu Options (menu=extension/ext_group/org_list).

Add a WhatsApp Channel

ParameterRequiredTypeDescription
nameYesStringMessage channel name.
Note: The length must not exceed 127 characters.
webhook_url_typeYesStringThe type of domain used in the Webhook URL.
Valid value:
  • fqdn
  • nat
channelYesStringThe service provider of the message channel.

Valid value: whatsapp

account_dataYesArray<Auth_Info>The data required by the service provider for message channel connection.
phone_number_idYesStringThe ID of the WhatsApp phone number.
Note:The length must not exceed 31 characters.
business_account_idYesStringThe ID of the WhatsApp business account.
Note:
  • The value should be passed in Base64-encoded format.
  • The length must not exceed 500 characters.
didsNoArray<Msg_Routing>Define the message routing rule by adding the WhatsApp phone number, setting message destination, and specifying members that are allowed to initiate message sessions via the phone number.
auto_close_sessionNoIntegerWhether to automatically close a message session after it has been inactive for a specified period of time.
session_expired_timeNoIntegerThe duration of inactivity (in days) after which a session is automatically closed.
enb_duplicate_active_sessionNoIntegerWhether to allow creating a new session when an active session with the same sender and receiver already exists.
Valid value:
  • 0: Disallow (default).
  • 1: Allow. A new session can be created even if an active session with the same sender and receiver already exists. After creation, the original session will be removed from the previous handler's session list and taken over by the new creator with the complete chat history.

Auth_Info

ParameterRequiredTypeDescription
kYesStringThe name of the key field required by the service provider.
Valid value:
  • access_token
  • app_secret
vYesStringThe value associated with the key field k.
Note:The value should be passed in Base64-encoded format.

Msg_Routing

ParameterRequiredTypeDescription
did_numberYesStringThe WhatsApp phone number in E.164 format.
destination_typeYesStringThe type of the destination.

Valid value:

  • extension: Extension user.
  • queue: Message queue.
  • api: Third-party message analytics platform (via API).
destination_idNoStringThe unique ID of destination to which inbound messages are sent.
Note:
  • This parameter is REQUIRED when the destination_type is set to extension or queue.
  • You can query the extension ID using Search Specific Extensions, and query the message queue ID using Search Specific Message Queues.
membersNoArray<Members>The members that are allowed to initiate message sessions via the WhatsApp phone number.

Members

ParameterRequiredTypeDescription
typeYesStringMember type.

Valid value:

  • extension
  • ext_group
  • organization
valueYesStringThe unique ID of the member.
Note:You can query the member ID using Get Menu Options (menu=extension/ext_group/org_list).

Add a Facebook Channel

ParameterRequiredTypeDescription
nameYesStringMessage channel name.
Note:The length must not exceed 127 characters.
webhook_url_typeYesStringThe type of domain used in the Webhook URL.
Valid value:
  • fqdn
  • nat
channelYesStringThe service provider of the message channel.

Valid value: facebook

account_dataYesArray<Auth_Info>The data required by the service provider for message channel connection.
didsNoArray<Msg_Routing>Define the message routing rule by adding the Facebook page ID and setting message destination.
auto_close_sessionNoIntegerWhether to automatically close a message session after it has been inactive for a specified period of time.
session_expired_timeNoIntegerThe duration of inactivity (in days) after which a session is automatically closed.

Auth_Info

ParameterRequiredTypeDescription
kYesStringThe name of the key field required by the service provider.Valid value:
  • access_token
  • app_secret
  • page_name
vYesStringThe value associated with the key field k.
Note:For access_token and app_secret fields, enter the value in Base64-encoded format.

Msg_Routing

ParameterRequiredTypeDescription
did_numberYesStringFacebook page ID.
destination_typeYesStringThe type of the destination.

Valid value:

  • extension: Extension user.
  • queue: Message queue.
  • api: Third-party message analytics platform (via API).
destination_idNoStringThe unique ID of destination to which inbound messages are sent.
Note:
  • This parameter is REQUIRED when the destination_type is set to extension or queue.
  • You can query the extension ID using Search Specific Extensions, and query the message queue ID using Search Specific Message Queues.

Response parameters

ParameterTypeDescription
errcodeIntegerReturned error code.
  • 0: Succeed.
  • Non-zero value: Failed.
Note: You can check the error code and error message in Error Code and Error Message.
errmsgStringReturned message.
  • SUCCESS: Succeed.
  • FAILURE: Failed.
idIntegerThe unique ID of the message channel.

Examples

Request example

  • Add an general SMS channel

    POST /openapi/v1.0/message_channel/create?access_token=JZvX9J8RddTcKb58WNQF2tXnLwPhrbUY HTTP/1.1
    Host: 192.168.5.150:8088
    Content-Type: application/json
    
    {
        "name":"Docs-General SMS Channel",
        "webhook_url_type":"nat",
        "channel":"general",
        "account_data": [
            {
                "k": "api_secret",
                "v": "bXlTdXBlclNlY3JldDEyMw=="
            },
            {
                "k": "api_key",
                "v": "bXlBUElLZXk0NTY="
            },
            {
                "k": "api_verify_url",
                "v": "https://api.example.com/auth/verify"   
            },{
                "k": "api_send_url",
                "v": "https://api.example.com/message/send"
            }
        ],
        "send_rate":2,  
        "auto_close_session":1,
        "session_expired_time": 5,  
          "dids": [
            {
                "did_number": "+1234567890",
                "destination_type": "extension",
                "destination_id": "137",
                "members": [
                    {
                        "type": "extension",
                        "value": "137"
                    }
                ]
            }
        ],
       "enb_duplicate_active_session":1
    }
  • Add a WhatsApp channel

    POST /openapi/v1.0/message_channel/create?access_token=EX8zZM5hdq3krlPcNmBbDSqfKF1ovibL HTTP/1.1
    Host: 192.168.5.150:8088
    Content-Type: application/json
    
    {
        "name":"Docs-WhatsApp Channel",
        "webhook_url_type":"fqdn",
        "channel":"whatsapp",
        "account_data": [
            {
                "k": "access_token",
                "v": "bXlTdXBlclNlY3JldDEyMw=="
            },
            {
                "k": "app_secret",
                "v": "bXlBUElLZXk0NTY="
            }
        ],
       
       "phone_number_id":"3546573434879",
       "business_account_id":"MzQ1Njc4Nzg5MA==",   
       "dids": [
            {
                "did_number": "+15567778888",
                "destination_type": "queue",
                "destination_id": "4"
             
            }
        ],
       "auto_close_session":1,
       "session_expired_time": 5,
       "enb_duplicate_active_session":1
    }
  • Add a Facebook channel

    POST /openapi/v1.0/message_channel/create?access_token=EX8zZM5hdq3krlPcNmBbDSqfKF1ovibL HTTP/1.1
    Host: 192.168.5.150:8088
    Content-Type: application/json
    
    {
        "name":"Docs-Facebook Channel",
        "webhook_url_type":"fqdn",
        "channel":"facebook",
        "account_data": [
            {
                "k": "access_token",
                "v": "bXlTdXBlclNlY3JldDEyMw=="
            },
            {
                "k": "app_secret",
                "v": "bXlBUElLZXk0NTY="
            },
            {
                "k": "page_name",
                "v": "test-facebook-page"
            }
        ],
       "dids": [
            {
                "did_number": "12345678901234", 
                "destination_type": "queue",
                "destination_id": "4" 
             
            }
        ],
       "auto_close_session":1,
       "session_expired_time": 5
    }

Response example

HTTP/1.1 200 OK
{
    "errcode": 0,
    "errmsg": "SUCCESS",
    "id": 19
}
Useful Links
  • Home
  • About us
  • Products
  • Services
  • Shipping
  • Return Policy
  • Warranty
  • Contact us
Legal
  • Terms
  • Privacy
  • Shared Responsibility
    Service Level Agreement
  • Certifications
About us

Cloud One Limited is a leading Kenyan local telephony service provider. Established in 2017, we offer reliable and secure cloud and on premise business communication solutions, including SIP trunks, Yealink IP phones, and VPS hosting in our Tier 3 data center.


Our mission is to revolutionize cloud communications by providing unparalleled reliability, cutting-edge innovation, and substantial cost savings. We deliver a stress-free, always-available service experience that empowers businesses to thrive in the digital age.

DUNS Registration Number: 561230946
Company Registration Number: PVT-5JUEYMA
Licensed & Regulated by the Communications Authority of Kenya


Follow us
Connect with us
  • Contact us
  • hello@cloudone.co
  • +254 20 7900000
  • Saachi Plaza, UNIT A3 - Argwings Kodhek Rd
Download Simu Connect

    Get the app on the playstore

    Download desktop app for Windows​

    Download app from the appstore

    Download MacOS app