Skip to main content

Get All User Threshold Master API

Overview

Retrieve a list of all user threshold master records in the system. This API allows you to fetch user threshold configurations and metadata, with optional filtering by user ID, currency ID, user type, and other parameters.

API Details

Endpoint

GET https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master

Headers

companyid: 59388167894b4d10a04fe5da3b8a2104
requestid: 5bb30135-1815-41d5-827f-baed3daba4af
authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJlNDk0Njg3N2YxODk0NmIyOTlmZGRmMGYyMTMzZGNiYSIsInJvbGVzIjpbIlJPTEVfQURNSU4iXSwiZXhwIjoxNzU4OTY2OTAzfQ.4e8MwJFrhoh2-vSvyR-s828TmEbgpYp-ocHlfo3Fnu4

Query Parameters

  • user_id (string, optional): Filter threshold masters by user ID
    • Example: ?user_id=e72810252c034a278a433eb0535b7ead
  • currency_id (string, optional): Filter threshold masters by currency ID
    • Example: ?currency_id=1f1519903ed240578f071aa45cb479f2
  • user_type (integer, optional): Filter threshold masters by user type
    • 2 = USER (Regular customer user)
    • 3 = MERCHANT (Business merchant user)
    • Example: ?user_type=2
  • threshold_id (string, optional): Filter threshold masters by threshold ID
    • Example: ?threshold_id=1dfec6e7b51c4dc1b4204ec3c09589f5
  • is_modified (boolean, optional): Filter by modification status
    • Example: ?is_modified=false
  • is_active (boolean, optional): Filter by active status
    • Example: ?is_active=true
  • search_keyword (string, optional): Search by name field
    • Example: ?search_keyword=Customer
  • start_date (long, optional): Filter by creation date (Unix timestamp in seconds)
    • Example: ?start_date=1704067200
  • end_date (long, optional): Filter by creation date (Unix timestamp in seconds)
    • Example: ?end_date=1735689599
  • skip (integer, optional): Number of records to skip for pagination
    • Example: ?skip=0
  • limit (integer, optional): Maximum number of records to return
    • Example: ?limit=10
  • sorting (string, optional): Sort order (asc/desc)
    • Example: ?sorting=desc

Response

{
"success": 1,
"error": [],
"data": {
"user_threshold_master": [
{
"is_active": true,
"created_by": "e72810252c034a278a433eb0535b7ead",
"created_date": 1758944507,
"updated_by": null,
"updated_date": 1758944507,
"id": "41ebd05c2e614c22ba0e73ad330d2bd6",
"threshold_id": "1dfec6e7b51c4dc1b4204ec3c09589f5",
"user_id": "e72810252c034a278a433eb0535b7ead",
"user_type": 2,
"name": "Customer",
"currency_id": "1f1519903ed240578f071aa45cb479f2",
"min_balance": 0.0,
"max_balance": 800000000.0,
"is_modified": false
}
]
}
}

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_threshold_master (array): Array of user threshold master objects
      • id (string): Unique threshold master identifier
      • threshold_id (string): Associated threshold configuration ID
      • user_id (string): User identifier
      • user_type (integer): Type of user (2=USER, 3=MERCHANT)
      • name (string): Name of the threshold configuration
      • currency_id (string): Currency identifier
      • min_balance (number): Minimum balance allowed for the user
      • max_balance (number): Maximum balance allowed for the user
      • is_modified (boolean): Whether the threshold has been modified
      • is_active (boolean): Whether the threshold is active
      • created_by (string): User who created the threshold
      • created_date (number): Unix timestamp when threshold was created
      • updated_by (string): User who last updated the threshold
      • updated_date (number): Unix timestamp when threshold was last updated

Example Usage

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?user_id=e72810252c034a278a433eb0535b7ead&currency_id=1f1519903ed240578f071aa45cb479f2' \
--header 'accept: application/json' \
--header 'authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJlNDk0Njg3N2YxODk0NmIyOTlmZGRmMGYyMTMzZGNiYSIsInJvbGVzIjpbIlJPTEVfQURNSU4iXSwiZXhwIjoxNzU4OTY2OTAzfQ.4e8MwJFrhoh2-vSvyR-s828TmEbgpYp-ocHlfo3Fnu4' \
--header 'companyid: 59388167894b4d10a04fe5da3b8a2104' \
--header 'requestid: 5bb30135-1815-41d5-827f-baed3daba4af'

Additional Examples

Get All Threshold Masters for a User

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?user_id=e72810252c034a278a433eb0535b7ead' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Get Threshold Masters by Currency

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?currency_id=1f1519903ed240578f071aa45cb479f2' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Get Active Threshold Masters Only

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?is_active=true' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Get Threshold Masters by Date Range (Epoch Format)

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?start_date=1704067200&end_date=1735689599' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Get Threshold Masters by User Type

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?user_type=2' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Search Threshold Masters by Name

curl --location 'https://api.gafapay.com:8443/gafapay/v3/transaction/user_threshold_master?search_keyword=Customer' \
--header 'authorization: Token YOUR_TOKEN' \
--header 'companyid: YOUR_COMPANY_ID' \
--header 'requestid: YOUR_REQUEST_ID'

Notes

  • The API returns all threshold masters that match the specified criteria
  • If no query parameters are provided, all threshold masters for the company are returned
  • Only USER (type 2) and MERCHANT (type 3) user types use threshold configuration
  • The min_balance and max_balance define the wallet balance limits for the user
  • Only threshold masters belonging to the authenticated user's company are returned
  • The API supports multiple filter combinations for precise threshold master retrieval
  • Pagination is supported through skip and limit parameters
  • Date Format: start_date and end_date parameters use Unix timestamps in seconds (epoch format)
    • Example: 1704067200 = January 1, 2024 00:00:00 UTC
    • Example: 1735689599 = December 31, 2024 23:59:59 UTC