1

We're using AMPScript to create a send log for all email and SMS sends. In MobileConnect, I can include the AMPScript and the SMS text fine and it's reported as one send however, when using Journey Builder to create SMS content and adding the AMPScript, it reads it as SMS message text and so is being sent as 5 or 6 messages instead of one. My example SMS was recorded as three sends in the Send Log. Is this normal for Journey Builder and SMS functionality?

5
  • Are you including the ampscript directly in your message? Or are you storing it in a code snippet content block, and referencing it using e.g. contentblockbykey ampscript function? Commented Mar 11 at 19:00
  • Hi @LukasLunow Yes in this instance the AMPScript is being added directly to the SMS content. Can code snippets and reference blocks be used in SMS?
    – James Lunn
    Commented Mar 12 at 9:10
  • You can use the ContentBlockbykey function in a SMS message but need to be sure that you call only Code Snippets with AMPscript and/or text in them. The other content block types utilize HTML which will not render in a SMS message. This should reduce the overall number of characters in your message. Commented Mar 12 at 9:43
  • Thanks @LukasLunow this seems to have resolved the issue. It's taken the character count down from over 500 (all AMPScript) to 31 and is then tracked in the send log as one send instead of 4
    – James Lunn
    Commented Mar 12 at 11:37
  • Great! So I thought. I have added this as an answer to your question. Please click on the checkmark on the left side, to mark the answer as accepted. Thank you Commented Mar 12 at 11:40

1 Answer 1

0

You should place your Ampscript in a code snippet content block, and reference it in your SMS message using %%=ContentBlockByKey()=%% function. This will greatly reduce the character count, as the Ampscript placed in the content block will not count towards your limit.

You need to be sure that you call only Code Snippets with AMPscript and/or text in them. The other content block types utilize HTML which will not render in a SMS message.

This should resolve your issue and allow you to log it as a single message and not as multiple.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .