{"info":{"_postman_id":"eae8d08b-d3d0-453e-ac42-f225a542573d","name":"FanPass API","description":"<html><head></head><body><p><strong>CONFIDENTIAL NOTICE. The information contained in this document is strictly confidential<br>and contains proprietary information. It may only be used by the intended parties and is<br>subject to the terms of any other confidentiality or nondisclosure agreement between parties.</strong>&nbsp;</p>\n<h1 id=\"overview\">Overview</h1>\n<p>FanPass is a secure, flexible API that enables clients to manage and enrich user data for personalized engagement. It supports two primary functions:</p>\n<ul>\n<li><p><strong>Segment Management</strong>: Import and update lists of users to create dynamic \"Imported Segments\" that can drive targeting across Push Notifications, In-App Messages, Marketing Card Campaigns, and Personalization Rules.</p>\n</li>\n<li><p><strong>User Attribute Enrichment</strong>: Update individual user records with key-value pairs for both platform and custom user attributes. These updates feed directly into the personalization engine and reporting tools, such as GA4 User Properties.</p>\n</li>\n</ul>\n<p>This collection helps teams activate their customer data with real-time updates and high precision, enabling richer, more relevant user experiences across your digital ecosystem.</p>\n<h1 id=\"getting-started-with-this-postman-collection\">Getting Started with this Postman Collection</h1>\n<p>This collection can be imported into any Postman workspace. It allows you to explore the FanPass API, validate your integration, and reproduce issues for support. It uses variables to manage the API host and your authentication token.</p>\n<p>To get started:</p>\n<p><strong>1. Import this collection into your postman workspace:</strong></p>\n<ul>\n<li><p>In the top right bar of this webpage, click on the <strong>Run in Postman</strong>.</p>\n</li>\n<li><p>Select the <strong>Workspace</strong> you'd like to import this collection into.</p>\n</li>\n</ul>\n<p><strong>2. Select the Collection and Go to Variables:</strong></p>\n<ul>\n<li><p>In the sidebar, click on the <strong>FanPass API</strong> collection.</p>\n</li>\n<li><p>Select the <strong>Variables</strong> tab.</p>\n</li>\n</ul>\n<p><strong>3. Set Your API Token:</strong></p>\n<ul>\n<li><p>You will see a variable named <code>api_access_token</code>.</p>\n</li>\n<li><p>In the <strong>Current Value</strong> column for that variable, <strong>paste your JWT Token</strong>.</p>\n</li>\n<li><p>This <strong>JWT Token</strong> is generated in the Fanreach Portal. It is unique to your user for auditing purposes. Ensure your JWT remains secure and do not share it externally. If your token is compromised, contact FanReach support immediately to issue a new one.</p>\n</li>\n</ul>\n<blockquote>\n<p><strong>Security Best Practice:</strong> Using the <strong>Current Value</strong> field ensures your secret token remains on your local machine and will not be synced with Postman's servers or exposed if you share the collection. </p>\n</blockquote>\n<p>The <code>domain</code> variable is already set to the production host. Once your token is set, you can run any request.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"Overview","slug":"overview"},{"content":"Getting Started with this Postman Collection","slug":"getting-started-with-this-postman-collection"}],"owner":"1065403","collectionId":"eae8d08b-d3d0-453e-ac42-f225a542573d","publishedId":"2sB2x6kC5M","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2025-06-12T18:11:07.000Z"},"item":[{"name":"Create/Update Segment","id":"d1a159af-2be7-4f9e-b7c6-07a3391fe83c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n  \"title\": \"User Group 1\",\n  \"tag\": \"userGroup1\",\n  \"sourceType\": 0,\n  \"userIds\": [\"12345\",\"54321\",\"56435\"],\n  \"notes\": \"Refresh of User Group 1\"\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/segments","description":"<h3 id=\"endpoint-post-apiv1segments\">Endpoint: <code>POST /api/v1/segments</code></h3>\n<p>Create or update Imported Segments by uploading lists of user IDs. These segments are typically based on behavioral or transactional data and are used to power campaign targeting and personalization.</p>\n<h4 id=\"common-segment-examples\">Common Segment Examples</h4>\n<ul>\n<li><p>Users who renewed season tickets</p>\n</li>\n<li><p>Users interested in tickets</p>\n</li>\n<li><p>Single-game ticket holders</p>\n</li>\n<li><p>Merchandise purchasers</p>\n</li>\n<li><p>CRM-based cohorts</p>\n</li>\n<li><p>Sponsors and VIPs</p>\n</li>\n</ul>\n<h4 id=\"important-notes\">Important Notes</h4>\n<ul>\n<li><p>If a segment <code>tag</code> does not exist, it will be created.</p>\n</li>\n<li><p>If a segment <code>tag</code> already exists, its list of <code>userIds</code> will be fully replaced (\"rinse and replace\").</p>\n</li>\n<li><p>Imported Segments are immediately available for the Personalization Engine. It may take up to 12 hours for changes to reflect in Push Notifications and In-App Messages.</p>\n</li>\n</ul>\n<hr />\n<h4 id=\"request-body-parameters\">Request Body Parameters</h4>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Required</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><code>title</code></td>\n<td><code>String</code></td>\n<td>Yes</td>\n<td>A descriptive, friendly name for the segment.</td>\n</tr>\n<tr>\n<td><code>tag</code></td>\n<td><code>String</code></td>\n<td>Yes</td>\n<td>Unique alphanumeric identifier used as the primary key. No spaces allowed.</td>\n</tr>\n<tr>\n<td><code>userIds</code></td>\n<td><code>Array</code></td>\n<td>Yes</td>\n<td>An array of user identifiers (e.g., Ticketing IDs). The array must not be empty.</td>\n</tr>\n<tr>\n<td><code>sourceType</code></td>\n<td><code>Integer</code></td>\n<td>No</td>\n<td>Integer indicating the source of the user IDs. Defaults to <code>0</code>.  <br /><code>0</code> - Ticketing ID  <br /><code>1</code> - Push Notification ID (coming soon)  <br /><code>2</code> - Loyalty ID (coming soon)  <br /><code>3</code> - Ad ID (coming soon)  <br /><code>4</code> - Subscriber ID (coming soon)</td>\n</tr>\n<tr>\n<td><code>notes</code></td>\n<td><code>String</code></td>\n<td>No</td>\n<td>Optional string for import logs (e.g., batch ID). This is visible in the portal.</td>\n</tr>\n</tbody>\n</table>\n</div>","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":""}]},"isInherited":true,"source":{"_postman_id":"eae8d08b-d3d0-453e-ac42-f225a542573d","id":"eae8d08b-d3d0-453e-ac42-f225a542573d","name":"FanPass API","type":"collection"}},"urlObject":{"protocol":"https","path":["api","v1","segments"],"host":["fanpass-api.fanreachdata.io"],"query":[],"variable":[]}},"response":[{"id":"0f71b1e6-77d0-4d59-87a6-9e5531ac5896","name":"Success Response (200)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n  \"title\": \"User Group 1\",\n  \"tag\": \"userGroup1\",\n  \"sourceType\": 0,\n  \"userIds\": [\"12345\",\"54321\",\"56435\"],\n  \"notes\": \"Refresh of User Group 1\"\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/segments"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 200,\n    \"correlationId\": \"95e0bd4c-35e4-4cd4-9e4c-46e06f7b58a1\",\n    \"messages\": [\n        \"Segment User Group 1 queued 3 for import\"\n    ],\n    \"errors\": []\n}"},{"id":"75b0f565-47d4-48fc-95e6-1a17c5ca3170","name":"Error: Missing Fields (400)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n  \"notes\": \"Trying to create a segment with missing fields.\"\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/segments"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 400,\n    \"correlationId\": \"b2c3d4e5-f6a7-8901-2345-67890abcdef1\",\n    \"messages\": [],\n    \"errors\": [\n        \"Missing required fields: title, tag, userIds\"\n    ]\n}"},{"id":"69b0f380-c8ed-4d89-bce1-43e4aa26a50f","name":"Error: Unauthorized (401)","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"Bearer an-invalid-token"}],"body":{"mode":"raw","raw":"{\n  \"title\": \"User Group 1\",\n  \"tag\": \"userGroup1\",\n  \"sourceType\": 0,\n  \"userIds\": [\"12345\",\"54321\",\"56435\"],\n  \"notes\": \"Refresh of User Group 1\"\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/segments"},"status":"Unauthorized","code":401,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 401,\n    \"correlationId\": \"d2e1f3a0-c4b5-6789-0123-456789abcdef\",\n    \"messages\": [],\n    \"errors\": [\n        \"The API access token is missing or invalid. Please verify that you are using the correct FanPass API token, which is available in the Fanreach Portal.\"\n    ]\n}"}],"_postman_id":"d1a159af-2be7-4f9e-b7c6-07a3391fe83c"},{"name":"Update User Properties","id":"6888ce1a-4f97-4a28-8026-e36f2d610b0e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"userIds\": [\"12345\"],\n    \"userProperties\": {\n        \"example_property_1\": \"example_value_1\",\n        \"example_property_2\": \"example_value_2\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/update_user","description":"<h3 id=\"endpoint-post-apiv1update_user\">Endpoint: <code>POST /api/v1/update_user</code></h3>\n<p>This endpoint allows for real-time enrichment of user records through individual or batch updates of user properties. These updates enable fine-tuned personalization and audience targeting.</p>\n<h4 id=\"update-rules\">Update Rules</h4>\n<ul>\n<li><p>Users are identified by their unique string-based ID.</p>\n</li>\n<li><p><strong>Custom property keys must be registered in the FanReach Portal</strong> as custom attributes before use.</p>\n</li>\n<li><p>Reserved properties (e.g., <code>user_id</code>) are not allowed and will be ignored. A warning will be returned in the response.</p>\n</li>\n<li><p>All valid custom property updates are appended to the GA4 User Property model.</p>\n</li>\n<li><p>GA4 propagation may take 4–8 hours to reflect changes across targeting tools.</p>\n</li>\n<li><p>Tags are pushed to the <code>fr_user_tags</code> event stream for audience creation.</p>\n</li>\n</ul>\n<hr />\n<h4 id=\"request-body-fields\">Request Body Fields</h4>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Required</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><code>userIds</code></td>\n<td><code>Array</code></td>\n<td>Yes</td>\n<td>An array of user IDs to update.</td>\n</tr>\n<tr>\n<td><code>userProperties</code></td>\n<td><code>Object</code></td>\n<td>Yes</td>\n<td>A key-value object of properties to update for the specified users. See notes for constraints.</td>\n</tr>\n</tbody>\n</table>\n</div><h4 id=\"userproperties-constraints\"><code>userProperties</code> Constraints</h4>\n<ul>\n<li><p><strong>Reserved Keys:</strong> Please visit the Fanpass section of the Fanreach portal to view reserved user attributes/properties.</p>\n</li>\n<li><p><strong>Custom Keys:</strong> Please visit the Fanpass section of the Fanreach portal to add custom user attributes/properties.</p>\n</li>\n<li><p><strong>Key Length:</strong> Custom property keys have a maximum length. Keys exceeding this limit will be ignored.</p>\n</li>\n<li><p><strong>Value Length:</strong> Property values have a maximum length of 36 characters. Values exceeding this limit will be automatically truncated.</p>\n</li>\n</ul>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":""}]},"isInherited":true,"source":{"_postman_id":"eae8d08b-d3d0-453e-ac42-f225a542573d","id":"eae8d08b-d3d0-453e-ac42-f225a542573d","name":"FanPass API","type":"collection"}},"urlObject":{"protocol":"https","path":["api","v1","update_user"],"host":["fanpass-api.fanreachdata.io"],"query":[],"variable":[]}},"response":[{"id":"4bfd8f67-119a-45e3-899c-941fda5ed52f","name":"Success Response (200)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"userIds\": [\"12345\"],\n    \"userProperties\": {\n        \"example_property_1\": \"example_value_1\",\n        \"example_property_2\": \"example_value_2\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/update_user"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 200,\n    \"correlationId\": \"d8c4e0a2-3b1f-4d9a-8c1e-2a3b4c5d6e7f\",\n    \"messages\": [\n        \"Successfully updated user properties for 1 users\"\n    ],\n    \"errors\": []\n}"},{"id":"8098543f-1af9-40d1-88f9-59d5ea021897","name":"Error: Missing Fields (400)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"userProperties\": {}\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/update_user"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 400,\n    \"correlationId\": \"c7b3d9f1-2a0e-4c89-7b0d-1a2b3c4d5e6f\",\n    \"messages\": [],\n    \"errors\": [\n        \"Missing required fields: userIds, userProperties\"\n    ]\n}"},{"id":"7dcdf6e6-5a28-4aa4-b577-5f6f6ce82c1b","name":"Error: Unauthorized (401)","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"Bearer an-invalid-token"}],"body":{"mode":"raw","raw":"{\n    \"userIds\": [\"12345\"],\n    \"userProperties\": {\n        \"example_property_1\": \"example_value_1\",\n        \"example_property_2\": \"example_value_2\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://fanpass-api.fanreachdata.io/api/v1/update_user"},"status":"Unauthorized","code":401,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": 401,\n    \"correlationId\": \"e3f2g4b1-d5c6-7890-1234-567890abcdef\",\n    \"messages\": [],\n    \"errors\": [\n        \"The API access token is missing or invalid. Please verify that you are using the correct FanPass API token, which is available in the Fanreach Portal.\"\n    ]\n}"}],"_postman_id":"6888ce1a-4f97-4a28-8026-e36f2d610b0e"}],"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":""}]}},"event":[{"listen":"prerequest","script":{"id":"f7c1081a-c8c5-4022-afb5-bde4b77fb6d7","type":"text/javascript","requests":{},"exec":[""]}},{"listen":"test","script":{"id":"e2a12c35-ae83-4e76-84c8-4023e8bd1d34","type":"text/javascript","requests":{},"exec":[""]}}],"variable":[{"key":"domain","value":"fanpass-api.fanreachdata.io"},{"key":"api_access_token","value":""}]}