Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.mayar.id/llms.txt

Use this file to discover all available pages before exploring further.

curl --request GET 'https://api.mayar.id/credit/v1/credit/customer/paginate-credit-history/PQVS4KGY?productId=40f26fbe-f4d8-4693-975f-e6d105d291e6&membershipTierId=261acae0-d6ae-4d8c-adf5-6fb8c2361514&page=1&limit=5' \
--header 'Authorization: Bearer Paste-Your-API-Key-Here' \
--data ''
{
    "statusCode": 200,
    "message": "success",
    "total": 3,
    "page": 1,
    "limit": 10,
    "totalPages": 1,
    "data": [
        {
            "id": "6970b4bcdfcfcfbbd8d7b617",
            "createdAt": "2026-01-21T11:13:00.044Z",
            "credit": 0,
            "debit": 50,
            "productId": "10291a3d-c53f-426f-9987-f879b4b87c64",
            "status": "ACTIVE",
            "customerId": "210e5193-7d66-4345-a5c7-07fe7552f2f7",
            "merchantId": "8afa8430-9ccd-4d33-9c1b-e0999a319994",
            "expiredAt": null,
            "walletType": "ADD_ON",
            "type": "CREDIT_USAGE"
        },
        {
            "id": "6970b49fdfcfcfbbd8d7b616",
            "createdAt": "2026-01-21T11:12:31.325Z",
            "credit": 200,
            "debit": 0,
            "productId": "10291a3d-c53f-426f-9987-f879b4b87c64",
            "status": "ACTIVE",
            "customerId": "210e5193-7d66-4345-a5c7-07fe7552f2f7",
            "merchantId": "8afa8430-9ccd-4d33-9c1b-e0999a319994",
            "expiredAt": null,
            "walletType": "ADD_ON",
            "type": "MERCHANT_TOPUP"
        },
        {
            "id": "6970b416dfcfcfbbd8d7b612",
            "createdAt": "2026-01-21T11:10:14.827Z",
            "credit": 3000,
            "debit": 0,
            "productId": "10291a3d-c53f-426f-9987-f879b4b87c64",
            "status": "ACTIVE",
            "customerId": "210e5193-7d66-4345-a5c7-07fe7552f2f7",
            "merchantId": "8afa8430-9ccd-4d33-9c1b-e0999a319994",
            "expiredAt": null,
            "walletType": "ADD_ON",
            "type": "TRIAL_TOPUP"
        }
    ]
}
Endpoint:
https://api.mayar.id/credit/v1/credit/customer/paginate-credit-history/?productId={productId}

Authorization

Authorization
string
required
Example:Authorization | Bearer Paste-Your-API-Key-Here

Path Parameters

customerId
string
The unique identifier of the customer whose credit balance is being queried balance.

Query Parameters

page
integer
default:"1"
The page number for pagination.
limit
integer
default:"10"
The unique identifier of the membership tier associated with the credit balance.
sortField
string
default:"datetime"
The field name used to sort results.
sortOrder
string
default:"desc"
The order of sorting. Accepts "asc" or "desc".
startDate
string
The start date filter for the query range.
endDate
string
The end date filter for the query range.
walletType
string
The type of wallet to filter credit history (e.g., "MEMBERSHIP", "ADD_ON").
type
string
The transaction type filter (e.g., "TOPUP", "MERCHANT_TOPUP" , "TRIAL_TOPUP", "EXPIRE_VOID" , "CREDIT_USAGE").

Response

Successful Response

Main Structure (Root)

statusCode
integer
Status code form API.
messages
string
Status message that describes the status code.
total
string
Indicates the total data.
page
string
Indicates the current page.
limit
string
Indicates the current limit (page size).
totalPages
string
Indicates the total page.
data
array of object
Result list of requested data.