Token Payload Structure

Table of contents

  1. Example Full Payload
  2. Minimum Viable Payload
    1. Password Users

As part of authenticating user sessions, we require distributors to provide a signed token on access the Plugin.

💡 We encourage our distributors to provide ALL available matching data. This will reduce friction in onboarding and keep user data in sync on subsequent logins.

Depending on the desired user experience and the user data available to the distributor, different data may be required or beneficial to user experience. The following page breaks down the accepted payload fields and how different scenarios may affect their usage.

Example Full Payload

{
  "userId": "abc123",
  "distributorId": "my-company",
  "title": "mr",
  "firstName": "Christopher",
  "lastName": "Robin",
  "email": "christopher.robin@sync-savings.com",
  "dateOfBirth": "1969-12-31",
  "mobileNumber": "+447123456789",
  "address": {
    "property": "145",
    "street": "London Street",
    "city": "London",
    "country": "GB",
    "postCode": "EC3N 4AB"
  },
  "sourceAccountDetails": {
    "accountNumber": "11223344",
    "sortCode": "608371",
    "accountOwner": "Christopher Robin"
  },
  "institution": "Winslow Luggages",
  "employment": {
    "industry": "marketing-advertising-and-pr",
    "status": "employed",
    "income": {
      "currency": "GBP",
      "value": 54321.09
    }
  },
  "sourceOfFunds": "salary-or-bonus",
  "taxResidency": "GB"
}

Field Descriptions:

All fields are required unless agreed otherwise.

  • userId: A unique identifier for the Saver.
  • firstName: The given name of the Saver.
  • lastName: The family name of the Saver.
  • distributorId: The ID unique to your platform (Provided by Sync Savings)
  • email: The email address of the Saver.
  • dateOfBirth: The date of birth of the Saver in ISO 8601 format.
  • mobileNumber: The mobile phone number of the Saver in international format (e.g. “+447123456789”).
  • address: The Saver’s UK address details:
    • property: How the Saver’s residence is identified.
    • street: The street name of the Saver’s address.
    • city: The city name of the Saver’s address.
    • country: A 2-character country code in ISO 3166 format (e.g. “GB”).
    • postCode: The postal code for the Saver’s address.
  • sourceAccountDetails: This is the bank account where Withdrawal Transactions will be paid to:
    • accountNumber: The bank account number.
    • sortCode: The sort code of the bank account.
    • accountOwner: The name of the account owner.
  • institution: (optional) If applicable, this can identify the Saver’s employer or the source of aggregated data.
  • employment: The Saver’s employment details:
    • industry: The industry in which the Saver works. Allowed values include:
      • “marketing-advertising-and-pr”
      • “sales”
      • “law”
      • “hospitality-and-events-management”
      • “personal-care-and-lifestyle”
      • “creative-arts-and-design”
      • “information-technology”
      • “environment-and-agriculture”
      • “media-and-internet”
      • “healthcare”
      • “property-and-construction”
      • “public-services-and-administration”
      • “law-enforcement-and-security”
      • “engineering-and-manufacturing”
      • “energy-and-utilities”
      • “recruitment-and-hr”
      • “teacher-training-and-education”
      • “leisure-sport-and-tourism”
      • “business-consulting-and-management”
      • “charity-and-not-for-profit-organizations”
      • “transport-and-logistics”
      • “science-and-pharmaceuticals”
      • “social-care”
      • “accountancy-banking-and-finance”
      • “retail-and-wholesale”
      • “social-and-humanities-scientists”
    • status: The Saver’s employment status. Allowed values:
      • “employed”
      • “retired”
      • “self-employed”
      • “unemployed”
    • income: Details of the Saver’s income:
      • currency: The currency of the Saver’s income in ISO 4217 format (e.g. “GBP”).
      • value: The monetary value of the Saver’s income.
  • sourceOfFunds: The nature of the money being used to fund the bank account. Allowed values include:
    • “gambling-or-lottery”
    • “investments”
    • “property-or-asset-sale”
    • “business-income”
    • “savings”
    • “salary-or-bonus”
    • “student-loans-or-bursary”
    • “retirement-or-pension”
    • “legal-settlement”
    • “family-or-gifted”
    • “loan”
    • “inheritance”
  • taxResidency: The country where the Saver is a tax resident in ISO 3166 format . Currently limited to “GB”.

Ensure data accuracy to prevent account creation issues.

Minimum Viable Payload

Minimum viable payload requires some distributor-related properties that validate the session and allow fetching of necessary settings. The email property acts as the primary identifier for a user and must be provided.

{
  "distributorId": "my-company",
  "institution": "Winslow Luggages",
  "email": "christopher.robin@sync-savings.com",
  "sourceOfFunds": "salary-or-bonus",
  "taxResidency": "GB"
}

Password Users

Password users are anonymous at the point of loading the plugin and it is understood that user data may be limited. As such, email is expected to be provided by the user as part of logging in or signing up and may be omitted from the token payload. The minimum data points required are the following:

{
  "distributorId": "my-company",
  "institution": "Winslow Luggages",
  "sourceOfFunds": "salary-or-bonus",
  "taxResidency": "GB"
}