WiPay
WAPIsv2.0.0User

Bank Accounts

Create, retrieve, update, and delete the authenticated user's bank accounts

Manage the authenticated user's local and foreign bank account details. The \{type\} path parameter is local or foreign.

Create and update operations require a verified account.


Retrieve Bank Accounts

Retrieve one or both bank account configurations.

Endpoint

GET /user/banks/{type?}
AccessRequirement
AuthenticatedYes
Required Scopewapi-user-retrieve, or wapi-user-all
Rate Limit15 requests per minute

Request

Headers

HeaderValue
Acceptapplication/json
AuthorizationBearer <access_token>
X-WAPI-Keywapi_live_<kid>_<secret> or wapi_test_<kid>_<secret>

Send exactly one of Authorization or X-WAPI-Key.

Path Parameters

ParameterTypeRequiredDescription
typestringNolocal or foreign. Omit to retrieve both.

Responses

200 OK

When type is omitted, both keys are returned. When type is specified, only the matching key is returned.

{
  "message": "OK",
  "data": {
    "local": {
      "bank_account": "123456789012",
      "bank_account_type": null,
      "bank_branch": null,
      "bank_name": "Republic Bank LTD",
      "currency": "TTD",
      "has_all_details": true,
      "name_in_bank": "John Smith"
    },
    "foreign": {
      "bank_address": null,
      "beneficiary_account_number": null,
      "beneficiary_address": null,
      "beneficiary_bank": null,
      "beneficiary_bank_swift_or_routing_code": null,
      "beneficiary_name": null,
      "currency": "USD",
      "has_all_details": false,
      "intermediary_bank": null,
      "intermediary_bank_address": null,
      "intermediary_bank_routing_number_or_aba": null,
      "intermediary_bank_swift_code": null
    }
  }
}
Local Bank Fields
FieldTypeDescription
bank_accountstring | nullBank account number
bank_account_typestring | null"chequing" or "saving" (Jamaica only)
bank_branchstring | nullBank branch (Jamaica only)
bank_namestring | nullBank name
currencystringLocal currency code
has_all_detailsbooleanWhether all required bank details are configured
name_in_bankstring | nullName on the bank account
Foreign Bank Fields
FieldTypeDescription
bank_addressstring | nullBank address
beneficiary_account_numberstring | nullBeneficiary account number
beneficiary_addressstring | nullBeneficiary address
beneficiary_bankstring | nullBeneficiary bank name
beneficiary_bank_swift_or_routing_codestring | nullSWIFT or routing code
beneficiary_namestring | nullBeneficiary name
currencystringForeign currency code
has_all_detailsbooleanWhether all required bank details are configured
intermediary_bankstring | nullIntermediary bank name
intermediary_bank_addressstring | nullIntermediary bank address
intermediary_bank_routing_number_or_abastring | nullIntermediary routing number or ABA
intermediary_bank_swift_codestring | nullIntermediary SWIFT code

Example

curl -X GET "https://ttsb.wipayfinancial.com/wapi/user/banks" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer <access_token>"
curl -X GET "https://ttsb.wipayfinancial.com/wapi/user/banks/local" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer <access_token>"

Create Bank Account

Configure a local or foreign bank account. Fails if a bank account of that type is already configured — use Update instead.

Endpoint

POST /user/banks/{type}
AccessRequirement
AuthenticatedYes (verified account)
Required Scopewapi-user-create, or wapi-user-all
Rate Limit5 requests per minute

Request

Headers

HeaderValue
Acceptapplication/json
AuthorizationBearer <access_token>
X-WAPI-Keywapi_live_<kid>_<secret> or wapi_test_<kid>_<secret>

Send exactly one of Authorization or X-WAPI-Key.

Body — Local Bank (form-data)

ParameterTypeRequiredDescription
bank_namestringYesMust be a valid bank name for the platform's country
name_in_bankstringYesAccount holder name (max 255 characters)
bank_accountstringYesDigits only. Length must match the bank's requirements.
bank_account_typestringJamaica only"chequing" or "saving"
bank_branchstringJamaica onlyBank branch name (max 255 characters)

Body — Foreign Bank (form-data)

ParameterTypeRequiredDescription
beneficiary_namestringYesBeneficiary name (max 255)
beneficiary_account_numberstringYesBeneficiary account number (max 255)
beneficiary_addressstringYesBeneficiary address (max 255)
beneficiary_bankstringYesBeneficiary bank name (max 255)
beneficiary_bank_swift_or_routing_codestringYesSWIFT or routing code (max 255)
bank_addressstringYesBank address (max 255)
intermediary_bankstringYesIntermediary bank name (max 255)
intermediary_bank_addressstringYesIntermediary bank address (max 255)
intermediary_bank_swift_codestringYesIntermediary SWIFT code (max 255)
intermediary_bank_routing_number_or_abastringYesIntermediary routing number or ABA (max 255)

Responses

201 Created

{
  "message": "Created"
}

409 Conflict

Returned if a bank account of that type is already configured.

{
  "message": "A local bank account is already configured."
}
{
  "message": "A foreign bank account is already configured."
}

403 Forbidden

Returned if the account is not verified.

{
  "message": "Please verify your account before proceeding."
}

Example

curl -X POST "https://ttsb.wipayfinancial.com/wapi/user/banks/local" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer <access_token>" \
  -F "bank_name=Republic Bank LTD" \
  -F "name_in_bank=John Smith" \
  -F "bank_account=123456789012"

Update Bank Account

Update fields on an existing bank account. Only supplied fields are changed. Fails if no bank account of that type is configured — use Create first.

Endpoint

PATCH /user/banks/{type}
AccessRequirement
AuthenticatedYes (verified account)
Required Scopewapi-user-update, or wapi-user-all
Rate Limit5 requests per minute

Request

Headers

HeaderValue
Acceptapplication/json
AuthorizationBearer <access_token>
X-WAPI-Keywapi_live_<kid>_<secret> or wapi_test_<kid>_<secret>

Send exactly one of Authorization or X-WAPI-Key.

Body (form-data)

Same fields as Create, but all fields are optional. At least one field must be provided.

Responses

200 OK

{
  "message": "OK"
}

400 Bad Request

{
  "message": "No fields provided to update."
}

Returned if no bank account of that type is configured:

{
  "message": "No local bank account is configured."
}
{
  "message": "No foreign bank account is configured."
}

403 Forbidden

Returned if the account is not verified.

{
  "message": "Please verify your account before proceeding."
}

Example

curl -X PATCH "https://ttsb.wipayfinancial.com/wapi/user/banks/local" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer <access_token>" \
  -F "name_in_bank=Jane Smith"

Delete Bank Account

Remove a local or foreign bank account configuration. Fails if no bank account of that type is configured.

Endpoint

DELETE /user/banks/{type}
AccessRequirement
AuthenticatedYes
Required Scopewapi-user-delete, or wapi-user-all
Rate Limit5 requests per minute

Request

Headers

HeaderValue
Acceptapplication/json
AuthorizationBearer <access_token>
X-WAPI-Keywapi_live_<kid>_<secret> or wapi_test_<kid>_<secret>

Send exactly one of Authorization or X-WAPI-Key.

No request body required.

Responses

200 OK

{
  "message": "OK"
}

400 Bad Request

Returned if no bank account of that type is configured:

{
  "message": "No local bank account is configured."
}
{
  "message": "No foreign bank account is configured."
}

Example

curl -X DELETE "https://ttsb.wipayfinancial.com/wapi/user/banks/local" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer <access_token>"

Common Responses

These apply to all bank account operations.

401 Unauthorized

{
  "message": "Unauthorized"
}

403 Forbidden

{
  "message": "Invalid scope(s) provided."
}