WorldFirst DocsWorldFirst Docs

Top up the budget accountSignature required

POST /amsin/api/v1/business/worldcard/transferToBudgetAccount

Call this API to top up the budget account.

Structure

A message consists of a header and body. For details, see the following sections.

Request header

Field

Required

Sample

Description

Client-Id

Yes

Client-Id: *****

For more information about these request header fields, see Request header.

Signature

Yes

Signature: algorithm=RSA256, keyVersion=2, signature=*****

Content-Type

Yes

Content-Type: application/json; charset=UTF-8

Request-Time

Yes

Request-Time: 2019-04-04T12:08:56+08:00

Connected-CustomerId

Conditional

Connected-CustomerId: *****

Attention

Required when a partner manages a customer's account.

Access-Token

Conditional

Access-Token: ******

Attention

Required for OAUTH authorization.


Request parameters

requestId String  REQUIRED

The unique ID that the Partner assigned to identify this balance recharge request.

More information:

  • Maximum length: 32 characters

toCurrency String  REQUIRED

3-character ISO 4217 currency code that represents the currency used.

Valid values: AUD​, ​CAD​, ​CHF​, ​CNY​, ​CZK​, ​EUR​, ​GBP​, ​HKD​, ​JPY​, ​MXN​, ​NZD​, ​PLN​, ​SEK​, ​SGD​, ​USD

toCurrency must be the same as fromCurrency.

toValue Long  REQUIRED

An integer. The value is in the smallest currency unit. For example, if the value is 100, the amount is $1.00 when the currency is USD, or ¥100 when the currency is JPY.

toValue must be equal to fromValue.

fromCurrency String  REQUIRED

3-character ISO 4217 currency code that represents the currency used.

Valid values: AUD, CAD, CHF, CNY, CZK, EUR, GBP, HKD, JPY, MXN, NZD, PLN, SEK, SGD, USD

toCurrency must be the same as fromCurrency.

fromValue Long  REQUIRED

An integer. The value is in the smallest currency unit. For example, if the value is 100, the amount is $1.00 when the currency is USD, or ¥100 when the currency is JPY.

toValue must be equal to fromValue.

payerBalanceType String  REQUIRED

The payer's account type. Valid values:

  • NORMAL_BALANCE: indicates the account balance (also known as the e-commerce balance).
  • SAME_NAME_TOP_UP_BALANCE: indicates the samename funds.  

payeeAccountNo String  REQUIRED

The payer's account ID.

Response parameters

result Result  REQUIRED

Indicates the result of the API call.

Show child parameters

requestId String  REQUIRED

The unique ID that the Partner assigned to identify this balance recharge request.

More information:

  • Maximum length: 32 characters

transactionStatus String  REQUIRED

The status of the balance recharge. Valid values:

  • PROCESSING​: Transaction is still being processed.
  • SUCCESS​: Transaction is successful.
  • FAIL​: Transaction has failed.

serviceFee Amount  REQUIRED

The service fee.

Show child parameters

transactionInfoList Array<TransactionInfo>  REQUIRED

The details of the transaction.

Show child parameters
API Explorer

Request

URL
Request Body

Response

Response Body

Result processing logic

After calling the API, a response is returned. The possible responses for result.resultStatus are:

Result status

Description

S

This indicates the API call succeeded.

F

This indicates the API call failed.

For more information on why the call failed, see result.resultCode tables.

U

This indicates the API call result is unknown. The partner can call this API again.

result.resultCode

CodeValueMessageFurther action
SUCCESSSSuccess
UNKNOWN_EXCEPTIONUAPI failed due to unknown reason.

The service might be down, retry later. If the issue persists, contact our Technical Support Team.

REPEAT_REQUESTFRepeated request

Change the requestId and retry.

ACCESS_TOKEN_EXPIREDFThe access token expired.

Refresh token to get a new access token or contact out Technical Support Team to address it.

AUTHORIZATION_NOT_EXISTFThe authorization does not exist.

Make sure that the input is correct. If the issue persists, contact our Technical Support Team to verify the authorization status.

ACCOUNT_NOT_EXISTFThe payer balance type does not exist.

Set up the correct balance type for this account or pay with another account.

BALANCE_INSUFFICIENTFBalance not enough

Recharge the current account or pay with another account that has sufficient balance.