Singapay Home Page
Logo Icon
  1. Accounts
  2. List

Information

MethodPathFormatAuthentication
GET/api/v1.0/accountsjsonOAuth 2.0 with Access Token

Request Details

This API endpoint is used to retrieve detailed information about a list of virtual accounts associated with the main account. It allows users to query for virtual account details based on specified criteria. The endpoint supports HTTP GET method and requires OAuth 2.0 authentication with an Access Token.

Headers Structure

FieldValueTypeMandatoryLengthDescriptionExample
X-PARTNER-IDapi_keyAlphanumericMandatoryAPI key obtained from the merchant dashboard.b3ed7d4b-a96c-6c08-b3c7-12c3124242d9
Acceptapplication/jsonAlphabeticMandatorySpecifies JSON as the expected response format.application/json
AuthorizationBearer {bearerToken}AlphanumericMandatoryBearer token obtained from the get access token endpoint.Bearer eyJ0eXAiOiJKV1{…}

Response Details

Response Structure

FieldTypeMandatoryLengthDescriptionExample
statusNumericMandatory3HTTP Status Code200
successBooleanMandatory1Indicates success statustrue
dataArray ObjectConditionalArray of sub account objects
> idAlphanumericMandatorySub account ID01K946KF851RK7FX075GJHBVKF
> nameAlphanumericMandatoryFull name of the account holderJohn
> emailAlphanumericMandatoryEmail address of the accountjohn.doe@gmail.com
> phoneAlphanumericMandatoryPhone number associated081234567890
> statusEnumMandatoryAccount status values: active, inactive, pending, rejectedactive
paginationObjectConditionalPagination information
> countNumericMandatoryNumber of items in response5
> totalNumericMandatoryTotal number of items available5
> perPageNumericMandatoryItems per page25
> currentPageNumericMandatoryCurrent page number1
> totalPagesNumericMandatoryTotal number of pages1
> linksObjectMandatoryLinks for navigation

Response Example

Success: Here’s an example of a successful response.

{
    "status": 200,
    "success": true,
    "data": [
        {
            "id": "01K946KF851RK7FX075GJHBVKF",
            "name": "rwa",
            "email": "admin@gmail.com",
            "phone": "081234567890",
            "status": "active"
        },
        {
            "id": "01K7ZTFRF7TC0XB1PFHC9CM80N",
            "name": "pentest 1",
            "email": "pentest1@gmail.com",
            "phone": "082125202019",
            "status": "active"
        },
        {
            "id": "01K7E5DGZCT5E225QGF4P2EE0P",
            "name": "Testing",
            "email": "julianpratam02@gmail.com",
            "phone": "082125202019",
            "status": "active"
        },
        {
            "id": "01K73TA9R0FWBG6B60Q916QMHD",
            "name": "Julian Pratama",
            "email": "julian.pratama@singapay.id",
            "phone": "082125202019",
            "status": "active"
        },
        {
            "id": "01K5ZT4NH8AZFFB3A52W4DN8MY",
            "name": "Adnan",
            "email": "adnan@singapay.id",
            "phone": "082199722404",
            "status": "active"
        }
    ],
    "pagination": {
        "count": 5,
        "total": 5,
        "perPage": 25,
        "currentPage": 1,
        "totalPages": 1,
        "links": {}
    }
}