In this article, I'll be going over how you can use an Iterable Data Feed to populate a template with an up-to-date PassKit member record.

The first thing we need is a long-lived API token from PassKit. A long-lived API token will allow you to make authenticated requests to PassKit servers without needing to refresh the token every hour.

Navigate to the program where your members will be enrolled into. Once there, click on the Settings link in the header, and click the "Pass APIs" option. Provide your account password into the text box and click the "Generate API Token" button.

You should be served a token in a popup, copy this token for later.

Next, head over to Iterable and hover over the Content tab, and select the Data feeds option.

Click "CREATE NEW FEED" and fill out the form as follows:

Name: Give your data feed a meaningful name

Template handlebars alias: I recommend using something like pk_member

URL: Paste this URL into the text field https://api.pub1.passkit.io/members/member/externalId/{{programId}}/{{email}}

*** Note: If you have requested a USA data instance from us, change pub1 to pub2 ***

If you don't have the programId in your user record, you can get it from the PassKit portal.

Authorization token: Type in Bearer followed by the long-lived API token copied from PassKit earlier.

Click "Save feed". Now you can reference PassKit member record data in your templates. If you are unsure about how to create a template, please read through this template overview.

When referencing a PassKit member record, you can use the response object here for the values available. Some examples would be:

[[pk_member.id]]
[[pk_member.person.forename]]
[[pk_member.points]]
Did this answer your question?