question

CodebyRay avatar image
CodebyRay asked

Help Needed! I can receive sms message but they are not unique to the message they are replying too.

Hello,

I hope I can find some help here. I have an SMS app that sends bulk messages to subscribed members. Everything works as expected, messages get sent to each contact.

I have setup a webhook to handle incoming replies to messages. Here is my issue:

When I send a bulk message to a contact and they reply, I get the reply and store in a DB table. All good thus far. I have managed to connect it to the message sent.

Issue: If I send another bulk message to the same contact and they reply to that message, the reply still sends back the reply as a reply to the first message sent. The payload sent back from the second message will still have the 'messaging_profile_id' from the first SMS sent.

Anyone else have this issue or no a work around?

Thanks in advance for your hlpe.

Regards, RJ

messagingsms
10 |600

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

klane@telnyx.com avatar image
klane@telnyx.com answered

Hi CodebyRay! Interesting question. We certainly want you to be able to keep messages organized. One idea to try is to use the "Unique Mdr ID" field which is unique to each message instead of the "Message Profile Id" which will be the same for all messages in a conversation. Can you see if that helps you attribute messages correctly?

1 comment
10 |600

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

CodebyRay avatar image CodebyRay commented ·

Is there a way to pass custom variables through? Like our own internal ID?

0 Likes 0 ·
CodebyRay avatar image
CodebyRay answered

Thank you for your reply. @klane@telnyx.com

I have checked each possible combination of ID's passed back from both the initial message sent and the reply sent back form the person messaged. Only two of them match, the organization_id and the messaging_profile_id.

Problem here is the messaging_profile_id is ALWAYS the same no matter where and whom the message was sent too. Even when I send another message later these are always the same.

The ID for the message and each reply are different and do not match in anyway to make sure what message they are replying too.

Example: I send an SMS with: "Are you going to make it to the meeting today?" at 8:00AM Immediate Reply: "Yes, I will be there."

Following day: I send an SMS with: "How was the meeting yesterday?" Immediate Reply: "It went well, good to go."

The reply from day two SHOULD be matched to the question from DAY TWO, however it is NOT and is continued from the initial message DAY ONE.

How can I distinguish which message they are actually replying to?

Regards, RJ

1 comment
10 |600

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

klane@telnyx.com avatar image klane@telnyx.com ♦♦ commented ·

Let me see if the messaging team has any ideas for us, I looked through the params and payload and one didn't jump out at me.

0 Likes 0 ·
klane@telnyx.com avatar image
klane@telnyx.com answered

Could you possibly use the timestamp field to order them chronologically as well?

10 |600

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Manage Your Content