0

I'm trying to have a cloud page retrieve the same info thats in the email.

The journey is pulling from a DE, so I used the same amp on the page as I do in the email.

When the CloudPageURL is click on from the email the content will show correctly, but when the CloudPageURL is clicked from an SMS no information is being populated.

Here is the CloudPageURL: %%=RedirectTo(CloudPagesURL(1396, 'Name', @LeadName, 'Appointment_Date_Time__c', @Appdate, 'Premium_Name__c', @primaryPrem, 'Description', @premDesc, 'Premium_Code__c', @Arrcode))=%%

The AMP on the page is as followed:

%%[ /* Initialize Variables */ VAR @ID, @row, @Appdate, @LeadId, @Arrcode SET @ID = IIF(EMPTY(AttributeValue('Appointment__c:Id')), AttributeValue('Lead:Current_Appointment__r:Id'), AttributeValue('Appointment__c:Id')) 

/* Get appointment from RecordId value */ 
VAR @apptResult 
SET @apptResult = RetrieveSalesforceObjects('Appointment__c', 'Appointment_Date_Time__c,Lead__c,Name', 'Id', '=', @ID) 
IF rowcount(@apptResult) > 0 THEN 
SET @row = row(@apptResult, 1) 
SET @Appdate = SystemDateToLocalDate(field(@row, 'Appointment_Date_Time__c')) 
SET @LeadId = field(@row, 'Lead__c') ENDIF 

VAR @primaryLeadPremiumResult, @leadResult, @Leadname IF not Empty(@LeadId) THEN 
/* Get primary premiums */ 
SET @primaryLeadPremiumResult = RetrieveSalesforceObjects('Lead_Premium__c', 'Premium_Name__c,Premium_Code__c,Premium__c', 'Lead__c', '=', @LeadId, 'Is_Primary__c', '=', 'true', 'Status__c', '=', 'Promised') 
IF rowcount(@primaryLeadPremiumResult) > 0 THEN 
SET @Arrcode = field(row(@primaryLeadPremiumResult, 1), 'Premium_Code__c') 
ENDIF 
ENDIF
]%%

Further down on the email/page:

VAR @i, @primaryPrem, @premRes, @premDesc FOR @i = 1 TO rowcount(@primaryLeadPremiumResult) 
DO SET @primaryPrem = row(@primaryLeadPremiumResult, @i) 
SET @premRes = RetrieveSalesforceObjects('Product2', 'Description', 'Id', '=', field(@primaryPrem, 'Premium__c')) 
IF RowCount(@premRes) > 0 THEN SET @premDesc = field(row(@premRes, 1), 'Description') ELSE SET @premDesc = "" ENDIF ]%%
 
%%=field(@primaryPrem, 'Premium_Name__c')=%%
%%=v(@premDesc)=%%```
4
  • 1
    does the SMS subscriber exists on All Subs? if not does adding them resolve the issue?
    – EazyE
    Commented Mar 8, 2022 at 19:44
  • 1
    Does this answer your question? CloudPageURL via SMS broken link
    – Niko
    Commented Mar 9, 2022 at 13:56
  • the subscriber does exist on All subs with the same SubscriberKey/ContactKey. I have the CloudPagesURL in an email and sms in the same journey. It populates when clicked on from the email, but not the sms
    – Rob
    Commented Mar 9, 2022 at 15:35
  • The thing is, CloudPageURL is generally not supposed to work with the SMS channel. Adding records to the All Subscribers list - is only a workaround, since that is how CloudPageURL works. So that it is better to just prepare a link with parameters, encrypt it and then shorten it with Bitly.
    – Niko
    Commented Mar 10, 2022 at 9:49

0

You must log in to answer this question.

Browse other questions tagged .