Skip to main content

Get Reward Point API

Overview

Retrieve user reward points information for a specific user and currency.

API Details

Endpoint

GET https://api.gafapay.com:8443/gafapay/v3/reward_promotion/user_points

Headers

authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJmYjhmMDkyMTBlMGY0NmI3YjQyNjJkNzdmNWI2YzI3MyIsInJvbGVzIjpbIlJPTEVfQ1VTVE9NRVIiXSwiZXhwIjoxNzU3NzY5NDU0fQ.QMvK_JLnYBE6XYaFdyg16aVupTONBO7eMGDmzAGVhVg
companyid: 59388167894b4d10a04fe5da3b8a2104
requestid: b35d332f-131e-44c1-892f-8322e022da74

Query Parameters

Required Parameters

  • user_id (string, required): Unique identifier of the user

    • Format: UUID string
    • Example: "fb8f09210e0f46b7b4262d77f5b6c273"
  • currency_id (string, required): Unique identifier of the currency

    • Format: UUID string
    • Example: "1f1519903ed240578f071aa45cb479f2"

Response

{
"success": 1,
"error": [],
"data": {
"user_points": {
"id": "fd5fd822caa8418d9c0bbbbfc54e0b21",
"user_id": "fb8f09210e0f46b7b4262d77f5b6c273",
"user_type": 2,
"points": 250.0,
"currency_id": "1f1519903ed240578f071aa45cb479f2"
}
}
}

Response Fields

  • success (integer): Response status indicator
    • 1 = Success
    • 0 = Failure
  • error (array): Array of error messages (empty on success)
  • data (object): Response data object
    • user_points (object): User points information
      • id (string): Unique identifier for the user points record
      • user_id (string): User's unique identifier
      • user_type (integer): Type of user account
        • 2 = Customer
        • 3 = Merchant
        • 5 = Agent
      • points (number): Current reward points balance
      • currency_id (string): Currency identifier for the points

Example Usage

curl --location 'https://api.gafapay.com:8443/gafapay/v3/reward_promotion/user_points?user_id=fb8f09210e0f46b7b4262d77f5b6c273&currency_id=1f1519903ed240578f071aa45cb479f2' \
--header 'authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJmYjhmMDkyMTBlMGY0NmI3YjQyNjJkNzdmNWI2YzI3MyIsInJvbGVzIjpbIlJPTEVfQ1VTVE9NRVIiXSwiZXhwIjoxNzU3NzY5NDU0fQ.QMvK_JLnYBE6XYaFdyg16aVupTONBO7eMGDmzAGVhVg' \
--header 'companyid: 59388167894b4d10a04fe5da3b8a2104' \
--header 'requestid: b35d332f-131e-44c1-892f-8322e022da74'

Notes

  • This API retrieves the current reward points balance for a specific user and currency
  • Both user_id and currency_id are required parameters
  • The response includes the user's current points balance and associated metadata
  • Points are returned as decimal numbers to support fractional point values