Bank list
Sandbox https://test.lintaspay.xyz/data/bank-list · Production https://lintaspay.xyz/data/bank-list
Lists the banks / virtual accounts (type = 1) or e-wallets (type = 2) you can pay out to. Use bank_id as bankId.
Request
Headers
| Header | Required | Value |
|---|---|---|
Content-Type | required | application/json |
Authorization | required | LINTASPAY-SHA256withRSA app_id=…,nonce=…,timestamp=…,sign=… — see Signing requests |
lintaspay-request-id | required | Unique request id, [A-Za-z0-9_-], max 64 |
Body parameters
| Name | Type | Required | Description |
|---|---|---|---|
type | integer | required | 1 banks & virtual accounts, 2 e-wallets.Example: 1 |
Example
{
"type": 1
}Response
HTTP 200 with the envelope {"code", "message", "data"}. code = 0 means success; otherwise data is null and code is an error code. Authentication failures return HTTP 401 (403 for a blocked IP, 429 when rate-limited). Always verify the response signature.
data fields
| Name | Type | Description |
|---|---|---|
total | integer | Example: 1 |
list | array[object] | |
bank_id | integer | Use as bankId.Example: 1 |
bank_name | string | Example: BANK BCA |
type | integer | 1 bank/VA, 2 e-wallet.Example: 1 |
Examples
{
"code": 0,
"message": "success",
"data": {
"total": 1,
"list": [
{
"bank_id": 1,
"bank_name": "BANK BCA",
"type": 1
}
]
}
}{
"code": 10011304,
"message": "Signature verification failed",
"data": null
}Code samples
URL_PATH=/data/bank-list
BODY='{"type":1}'
AUTH="app_id=$APP_ID,nonce=$(openssl rand -hex 16),timestamp=$(date +%s)000"
SIGN=$(printf '%s\nPOST\n%s\n%s\n' "$AUTH" "$URL_PATH" "$BODY" \
| openssl dgst -sha256 -sign merchant_private_key.pem | base64 | tr -d '\n')
curl -sS -X POST "https://test.lintaspay.xyz$URL_PATH" \
-H 'Content-Type: application/json' \
-H "Authorization: LINTASPAY-SHA256withRSA $AUTH,sign=$SIGN" \
-H "lintaspay-request-id: $(openssl rand -hex 16)" \
-d "$BODY"// call() is defined on the Signing requests page
const res = await call('/data/bank-list', {
"type": 1
});
if (res.code !== 0) throw new Error(`${res.code} ${res.message}`);
console.log(res.data);# call() is defined on the Signing requests page
res = call("/data/bank-list", {
"type": 1
})
if res["code"] != 0:
raise RuntimeError(f"{res['code']} {res['message']}")
print(res["data"])<?php
// api_call() is defined on the Signing requests page
$res = api_call('/data/bank-list', json_decode('{"type":1}', true));
if ($res['code'] !== 0) {
throw new RuntimeException($res['code'] . ' ' . $res['message']);
}
print_r($res['data']);// ApiClient is defined on the Signing requests page
ApiClient client = new ApiClient();
String body = "{\"type\":1}";
String res = client.call("/data/bank-list", body);
System.out.println(res);