Brick API

Brick API as documented publicly: 6 operations. Contract generated from the documentation by API Evangelist (2026-10-21); not the provider's own document.

Operations 6

GET /v2/payments/auth/token GET /v2/payments/auth/token #
POST /v2/payments/gs/acceptance/ewallet POST /v2/payments/gs/acceptance/ewallet #
GET /v2/payments/gs/balance GET /v2/payments/gs/balance #
GET /v2/payments/gs/get-top-up-history Get Topup History #
GET /v2/payments/gs/ledger GET /v2/payments/gs/ledger #
GET /v2/payments/gs/top-up/bank/list GET /v2/payments/gs/top-up/bank/list #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/onebrick:onebrick-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

onebrick-openapi-generated.yml Raw ↑
openapi: 3.1.0
info:
  title: Brick API
  version: '2026-10-21'
  description: 'GENERATED FROM DOCUMENTATION by API Evangelist on 2026-10-21: 6 operation(s) read from 10 public documentation page(s) (each operation
    names its page in x-source). This is not the provider''s published contract; Brick has published no machine-readable contract that the pipeline
    could find. Engine: local.'
  x-evidence-tiers:
    code-example: 5
    documentation: 1
    pages-with-code: 10
    pages-read: 10
  x-generated-from: documentation
  x-provenance: generated
  x-authored-by: API Evangelist
  x-generated: '2026-10-21'
  x-generator: generate-contract-from-docs.py
  x-engine: local
  x-sources:
  - https://docs.onebrick.io/th/api
  - https://docs.onebrick.io/api/topup
  - https://docs.onebrick.io/api/ledger
  - https://docs.onebrick.io/api/balance
  - https://docs.onebrick.io/api/ewallet
  - https://docs.onebrick.io/id/api/topup
  - https://docs.onebrick.io/th/api/topup
  - https://docs.onebrick.io/id/api/ledger
  - https://docs.onebrick.io/th/api/ledger
  - https://docs.onebrick.io/id/api/balance
servers:
- url: https://sandbox.onebrick.io
paths:
  /v2/payments/auth/token:
    get:
      operationId: get_v2_payments_auth_token
      tags:
      - Payments
      summary: GET /v2/payments/auth/token
      x-source: https://docs.onebrick.io/th/api
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV2PaymentsAuthTokenResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl https://sandbox.onebrick.io/v2/payments/auth/token  --header 'Authorization: Basic <credentials>' cURL JavaScript Python\
          \ Example Responses 200 401 { \n \"status\" : 200 , \n \"error\" : null , \n \"metaData\" : { \n \"source\" : \"API\" , \n \"entity\"\
          \ : \"Payment\" \n }, \n \"data\" : { \n \"message\" : \"Access token is valid for 5 minutes and can use one time only\" , \n \"accessToken\"\
          \ : \"YOUR_ACCESS_TOKEN\" , \n \"issued"
  /v2/payments/gs/acceptance/ewallet:
    post:
      operationId: post_v2_payments_gs_acceptance_ewallet
      tags:
      - Payments
      summary: POST /v2/payments/gs/acceptance/ewallet
      x-source: https://docs.onebrick.io/api/ewallet
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostV2PaymentsGsAcceptanceEwalletRequest'
      responses:
        '201':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostV2PaymentsGsAcceptanceEwalletResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl https://sandbox.onebrick.io/v2/payments/gs/acceptance/ewallet  --request POST  --header 'Content-Type: application/json'\
          \  --header 'publicAccessToken: <api-key>'  --data '{ \n \"amount\": 10000, \n \"referenceId\": \"Test-Sandbox-01\", \n \"ewalletCode\"\
          : \"DANA\", \n \"returnUrl\": \"https://staging-app.onebrick.io\" \n }' cURL JavaScript Python Example Request Body { \n \"amount\"\
          \ : 10000 , \n \"referenceId\" : \"Te"
  /v2/payments/gs/balance:
    get:
      operationId: get_v2_payments_gs_balance
      tags:
      - Payments
      summary: GET /v2/payments/gs/balance
      x-source: https://docs.onebrick.io/api/balance
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV2PaymentsGsBalanceResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl https://sandbox.onebrick.io/v2/payments/gs/balance  --header 'publicAccessToken: <api-key>' cURL JavaScript Python Example\
          \ Responses 200 401 { \n \"status\" : 200 , \n \"data\" : { \n \"balance\" : { \n \"usableBalance\" : 10099380255 , \n \"pendingBalance\"\
          \ : 1000000 , \n \"totalBalance\" : 10100380255 \n }, \n \"sameDaySettlement\" : { \n \"isActive\" : true , \n \"earlySettlementBalanceQuota\"\
          \ : 500000 \n } \n }, \n \"me"
  /v2/payments/gs/get-top-up-history:
    get:
      operationId: get_v2_payments_gs_get_top_up_history
      tags:
      - Payments
      summary: Get Topup History
      description: Retrieve historical top-up records for a selected period so your team can reconcile balance funding activity.
      x-source: https://docs.onebrick.io/api/topup
      parameters:
      - name: type
        in: query
        required: false
        schema:
          type: string
        description: If type set as topup will filter only topup transactions
      - name: publicAccessToken
        in: header
        required: true
        schema:
          type: string
        description: publicAccessToken
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV2PaymentsGsGetTopUpHistoryResponse'
      x-evidence:
        kind: documentation
  /v2/payments/gs/ledger:
    get:
      operationId: get_v2_payments_gs_ledger
      tags:
      - Payments
      summary: GET /v2/payments/gs/ledger
      x-source: https://docs.onebrick.io/api/ledger
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV2PaymentsGsLedgerResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl https://sandbox.onebrick.io/v2/payments/gs/ledger  --header 'publicAccessToken: <api-key>' cURL JavaScript Python Example\
          \ Responses 200 401 { \n \"status\" : 200 , \n \"data\" : { \n \"message\" : \"We are successfully able to get the data\" , \n \"transactions\"\
          \ : [ \n { \n \"refId\" : \"ref-1\" , \n \"date\" : \"2022-10-03T15:17:44.000+07:00\" , \n \"accountHolderName\" : \"test-123\" , \n\
          \ \"accountNumber\" : \"12345678\" , "
  /v2/payments/gs/top-up/bank/list:
    get:
      operationId: get_v2_payments_gs_top_up_bank_list
      tags:
      - Payments
      summary: GET /v2/payments/gs/top-up/bank/list
      x-source: https://docs.onebrick.io/api/topup
      parameters:
      - name: email
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV2PaymentsGsTopUpBankListResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl 'https://sandbox.onebrick.io/v2/payments/gs/top-up/bank/list?email=<string>'  --header 'publicAccessToken: <api-key>' cURL\
          \ JavaScript Python Example Responses 200 400 { \n \"status\" : 200 , \n \"data\" : { \n \"vaListData\" : [ \n { \n \"bankName\" : \"\
          Bank BNI\" , \n \"bankShortCode\" : \"BNI\" , \n \"vaNumber\" : \"98819xxxxx\" \n }, \n { \n \"bankName\" : \"Bank BRI\" , \n \"bankShortCode\"\
          \ : \"BRI\" , \n \"vaNumber\" : \"1005xx"
components:
  schemas:
    GetV2PaymentsAuthTokenResponse:
      type: object
      properties:
        status:
          type: integer
        error:
          type:
          - string
          - 'null'
        metaData:
          type: object
          properties:
            source:
              type: string
            entity:
              type: string
        data:
          type: object
          properties:
            message:
              type: string
            accessToken:
              type: string
            issuedAt:
              type: string
              format: date-time
            expiresAt:
              type: string
              format: date-time
    PostV2PaymentsGsAcceptanceEwalletRequest:
      type: object
      properties:
        amount:
          type: integer
        referenceId:
          type: string
        ewalletCode:
          type: string
        returnUrl:
          type: string
    PostV2PaymentsGsAcceptanceEwalletResponse:
      type: object
      properties:
        amount:
          type: integer
        referenceId:
          type: string
        ewalletCode:
          type: string
        returnUrl:
          type: string
    GetV2PaymentsGsBalanceResponse:
      type: object
      properties:
        status:
          type: integer
        data:
          type: object
          properties:
            balance:
              type: object
              properties:
                usableBalance:
                  type: integer
                pendingBalance:
                  type: integer
                totalBalance:
                  type: integer
            sameDaySettlement:
              type: object
              properties:
                isActive:
                  type: boolean
                earlySettlementBalanceQuota:
                  type: integer
        metaData:
          type: object
          properties:
            source:
              type: string
            entity:
              type: string
        error:
          type:
          - string
          - 'null'
    GetV2PaymentsGsGetTopUpHistoryResponse:
      type: object
      properties:
        status:
          type: integer
          description: status code
        data:
          type: object
          description: response data
        data.content:
          type: array
          description: list of top‑up records
        data.content[].topUpId:
          type: string
          description: Top‑up identifier
        data.content[].refNumber:
          type: string
          description: Reference number
        data.content[].bank:
          type: string
          description: Bank name
        data.content[].date:
          type: string
          description: Date of transaction
        data.content[].amount:
          type: number
          description: Amount topped up
        data.content[].transactionType:
          type: string
          description: Transaction type
        data.content[].accountNo:
          type: string
          description: Account number
        data.content[].accountDisplayName:
          type: string
          description: Account display name
        data.pageCount:
          type: integer
          description: Total pages
        data.pageIndex:
          type: integer
          description: Current page index
        data.pageSize:
          type: integer
          description: Page size
        data.perPage:
          type: integer
          description: Items per page
        data.totalElements:
          type: integer
          description: Total number of elements
        metaData:
          type: object
          description: metadata
        metaData.source:
          type: string
          description: source
        metaData.entity:
          type: string
          description: entity
        error:
          type: string
          description: error object
    GetV2PaymentsGsLedgerResponse:
      type: object
      properties:
        status:
          type: integer
        data:
          type: object
          properties:
            message:
              type: string
            transactions:
              type: array
              items:
                type: object
                properties:
                  refId:
                    type: string
                  date:
                    type: string
                    format: date-time
                  accountHolderName:
                    type: string
                  accountNumber:
                    type: string
                  bankName:
                    type: string
                  description:
                    type: string
                  amount:
                    type: integer
                  fees:
                    type: integer
                  status:
                    type: string
        metaData:
          type: object
          properties:
            source:
              type: string
            entity:
              type: string
        error:
          type:
          - string
          - 'null'
    GetV2PaymentsGsTopUpBankListResponse:
      type: object
      properties:
        status:
          type: integer
        data:
          type: object
          properties:
            vaListData:
              type: array
              items:
                type: object
                properties:
                  bankName:
                    type: string
                  bankShortCode:
                    type: string
                  vaNumber:
                    type: string
        metaData:
          type: object
          properties:
            source:
              type: string
            entity:
              type: string
        error:
          type:
          - string
          - 'null'
  securitySchemes:
    basic:
      type: http
      scheme: basic
security:
- basic: []
tags:
- name: Payments