sso_account_balance

Fetch Account Balance of User

Returns account balance details of a guest, such as banked_rewards, membership_level, net_balance, net_debits, pending_points, points_balance, signup_anniversary_day, total_credits, total_debits, total_point_credits, total_redeemable_visits, etc.

User authentication required

This API requires authentication_token to be supplied as HTTP_AUTHORIZATION header or in the authentication_token parameter.

Headers
  • x-pch-digest
    Type: string
    required

    The signature for the API call

  • Accept-Language
    Type: string

    Set to the language you are using.

  • User-Agent
    Type: string
    required

    For details, see User Agent.

  • Content-Type
    Type: string
    required

    Set this header to application/json.

  • Accept
    Type: string
    required

    Advertises which content types the client is able to understand

  • Authorization
    Type: string
    required

    You may pass the access_token instead of the authentication_token in Online Ordering endpoints to authorize the request. It must be supplied as Bearer ACCESS_TOKEN_GOES_HERE. Note: When authentication is performed using Advanced Authentication, you must include the id_token in the id-token header and the access_token in the Authorization header. See Access Punchh APIs Using Access and ID tokens

  • id-token
    Type: string

    A token that contains identity information about the authenticated user. It is used to verify the user’s identity and is required only when authentication is performed using Advanced Authentication. This token alone does not grant access to Punchh APIs. To access the APIs, you must include the id_token in the id-token header and the access_token in the Authorization header. See Access Punchh APIs Using Access and ID tokens

Body
application/json
  • authentication_token
    Type: string

    The authentication token of the user. You can retrieve this from the response of a successful sign-in API call or through the SSO process.

  • client
    Type: string
    default: 
    "CLIENT_GOES_HERE"
    required

    Client key of the business

Responses
  • 200
    Type: object
    • balance
      Type: Account Balance Attributes (Object)
    • redeemables
      Type: array Redeemables Attributes (Object)[]
    • rewards
      Type: array Rewards Attributes (Object)[]
  • 401

    Sending invalid credentials

  • 412
    Type: array string[]

    Sending invalid Signature

  • 422

    Sending invalid Entity

get/api/auth/checkins/balance
{
  "balance": {
    "banked_rewards": 1,
    "membership_level": "string",
    "membership_level_id": 1,
    "net_balance": 1,
    "net_debits": 1,
    "pending_points": 1,
    "points_balance": 1,
    "signup_anniversary_day": "string",
    "total_credits": 1,
    "total_debits": 1,
    "total_point_credits": 1,
    "total_redeemable_visits": 1,
    "expired_membership_level": "string",
    "total_visits": 1,
    "initial_visits": 1,
    "unredeemed_cards": 1,
    "membership_qualification_points": 1
  },
  "rewards": [
    {
      "business_id": 1,
      "end_date": "YYYY-MM-DD",
      "end_date_tz": "YYYY-MM-DDThh:mm:ssZ",
      "gaming_level_id": "string",
      "gifted_for_type": "string",
      "gift_reason": "string",
      "id": 1,
      "location_ids": [
        1
      ],
      "read_at": "YYYY-MM-DDThh:mm:ssZ",
      "redeemable_id": 1,
      "reward_properties": null,
      "start_date": "YYYY-MM-DD",
      "start_date_tz": "YYYY-MM-DDThh:mm:ssZ",
      "external_store_numbers": [
        1
      ],
      "type": "string"
    }
  ],
  "redeemables": [
    {
      "applicable_as_loyalty_redemption": true,
      "redeemable_properties": "string",
      "discount_amount": 1,
      "discount_channel": "string",
      "expire_redemption_code_with_reward_end_date": null,
      "id": 1,
      "image": "string",
      "points": 1,
      "redeemable_id": 1,
      "redemption_expiry": 1,
      "thumb_image": "string",
      "name": "string",
      "description": "string"
    }
  ]
}