POST
Create a Global Account
Use this endpoint to initialize a Global Account for a customer, including the bank country or region and supported collection currencies.
Request
apikeyAccount service API key request header assigned by Onerway. Use the value for the same environment as the request base URL.
Example:
replace_with_account_service_apikeyrequestIdRequest ID used for idempotency control and request tracing.
Example:
REQ-GA-20260423-0001customerIdCustomer identifier for which the Global Account is opened. For direct merchant calls, use the customer identifier associated with the
apikey. For platform calls, use the child customer identifier that the caller is authorized to operate.Example:
801172onBehalfOfChild customer identifier when a platform merchant calls on behalf of a child customer. When provided, it must match
customerId and the caller must be authorized for that customer.Example:
456bankCountryCountry or region code of the bank where the Global Account is opened. Use the two-letter ISO 3166-1 alpha-2 format.
Example:
USsupportCurrenciesSupported currency entry for this Global Account. Use three-letter ISO 4217 currency codes.
Example:
["USD","EUR"]webhookUrlAsynchronous notification URL for account-service events related to the Global Account.
Example:
https://developers.onerway.com/example-account-webhookConstraints
- Rule
- Must be a valid URL when provided.
globalAccountNameDisplay name of the Global Account, used for account information display and merchant-side identification.
Example:
Acme USD CollectionConstraints
- Rule
- Use letters, numbers, spaces, Chinese characters, underscores, dots, or hyphens.
curl -X POST 'https://sandbox-api.onerway.com/account-server/api/v1/account/global/create' \
-H 'Content-Type: application/json' \
--data-raw '{
"requestId": "REQ-GA-20260423-0001",
"customerId": "801172",
"bankCountry": "US",
"supportCurrencies": [
"USD",
"EUR"
],
"webhookUrl": "https://merchant.example.com/hooks/account",
"globalAccountName": "Acme USD Collection"
}'Response
successWhether the Global Account creation request was processed successfully. When this value is
false, read respCode and respMsg for the failure reason and do not rely on data as a created account result.respCodeBusiness response code for Global Account APIs. The success response code is
20000.respMsgHuman-readable prompt or error message for the response code.
data{ globalAccountId, onBehalfOf }Created Global Account information.
error{ type, code, ... }Structured error details returned by the Account service.
{
"success": true,
"respCode": "20000",
"respMsg": "Success",
"data": {
"globalAccountId": "2002"
}
}No error responses are documented for this endpoint.