1

I am building a custom preference/unsubscribe center in Cloud Pages with SSJS.

I'll be using MicrositeURL('xxxxxx') within the footer of emails to get to the landing page. How can I retrieve the SubscriberKey, JobID, and BatchID from the passed subscriber info to use in my SSJS calls?

1 Answer 1

1

You should used the RequestParameter ampscript function

Eg.

%%[
SET @SusbcriberKey = RequestParameter('_subscriberKey')
SET @JobId = RequestParameter('jobID')
SET @BatchId = RequestParameter('batchId')
]%%

%%=v(@SusbcriberKey)=%%
%%=v(@JobId)=%%
%%=v(@BatchId)=%%

To do this via SSJS, you would need the GetAttributeValue function

eg.

<script runat=server>
  Platform.Load("Core","1");
  var subscriberKey = Platform.Variable.GetAttributeValue('_subcriberkey');
  Platform.Response.Write(subscriberKey);
</script>
5

You must log in to answer this question.

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