Loader

Which parameter in the update status callback payload matches to the apiMessageId in the send message response?

When a customer sends a message from their system via One API, they receive the following response:

 

{

  “messages”: [

    {

      “apiMessageId”: “77fb29998253415fa5d66971d519d362”,

      “accepted”: true,

      “to”: “2799900001”,

      “error”: null

    }

  ],

  “error”: null

}

 

 

apiMessageId in the send message response is returned in messageId in the message status update callback:

 

{

  “integrationId”: “fa8090815f05d5ed015f0b5b56080cd2”,

  “integrationName”: “My integration”,

  “event”: {

    “messageStatusUpdate”: [

      {

        “channel”: “whatsapp/sms”,

        “timestamp”: 1506607698860,

        “statusCode”: 4,

        “status”: “DEVICE_ACK”,

        “messageId”: “77fb29998253415fa5d66971d519d362”,

        “clientMessageId”: “2993b6b548000a80989a20549e7558a5”

      }

    ]

  }

}

 

When sending a message, the customer can also specify their own ID in the request

 

{

    “messages”: [

        {

            “channel”: “whatsapp”,

            “to”: “2799900001”,

            “content”: “Here is my message”,

            “clientMessageId”: “2993b6b548000a80989a20549e7558a5”

        }

    ]

}

 

which will then be returned with the status update callback:

{

  “integrationId”: “fa8090815f05d5ed015f0b5b56080cd2”,

  “integrationName”: “My integration”,

  “event”: {

    “messageStatusUpdate”: [

      {

        “channel”: “whatsapp/sms”,

        “timestamp”: 1506607698860,

        “statusCode”: 4,

        “status”: “DEVICE_ACK”,

        “messageId”: “77fb29998253415fa5d66971d519d362”,

        “clientMessageId”: “2993b6b548000a80989a20549e7558a5”

      }

    ]

  }

}

 

 

Did you find this information informative?

Other Resources

Ask the Community

Visit Stack Overflow to join our community of developers and find the answer you need

Contact Support

Contact our support team and one of our agents will be in touch with you to answer any questions you have