inquiryTransfer

POST: /aps/api/business/transfer/inquiryTransfer

Signature required

The Partner can use the inquiryTransfer API to query the result of a transfer.

  • For transfer requests, if the Partner is unable to retrieve the transfer result or does not receive any result in 10 seconds, the Partner can use the inquiryTransfer to make active inquiries. The recommended polling frequency is 2-3 seconds per request 10 to 20 times.
  • If the Partner receives no notification from the notifyTransferResult API for 2 hours, while the inquiryTransfer API returns transferResult.resultCode as UNKONWN, contact WorldFirst(Alipay) Technical Support Team for help.

Structure

A message consists of a header and body. The following sections are focused on the body structure. For the header structure, see:

Request parameters

Field

Data type

Required

Description

transferRequestId

String

Yes

The unique ID assigned by the Partner to identify a transfer request.

Note:

  • This field is an API idempotency field. For details about API idempotency, see the Idempotency chapter.

More information:

  • Maximum length: 64 characters

Response parameters

Field

Data type

Required

Description

result

Result object

Yes

Indicates whether this API is called successfully.

transferFactor

TransferFactor object

Yes

Indicates different scenarios for the transfer, such as: remitting to China in CNY, or remitting to countries/regions other than China.

transferFromDetail

TransferFromDetail object

Yes

The transfer amount submitted by the payer.

transferToDetail

TransferToDetail object

Yes

The transfer details for the beneficiary, such as the transfer amount collected by the beneficiary.

transferRequestId

String

Yes

The unique ID assigned by the Partner to identify a transfer request.

Note:

  • This field is an API idempotency field. For details about API idempotency, see the Idempotency chapter.

More information:

  • Maximum length: 64 characters

transferId

String

Yes

The unique ID assigned by WorldFirst(Alipay) to identify the status of a transfer.

More information:

  • Maximum length: 64 characters

transferResult

Result object

Yes

Indicates the status of the transfer made by the transfer API.

transferFinishTime

DateTime object

No

Indicates the finishing time of a transfer.

Note:

  • This field is not returned to the Partner unless the Partner makes duplicated inquiries about a transfer. On that condition, WorldFirst(Alipay) returns this field indicating the actual finishing time of the transfer.
  • The value of this field follows the ISO 8601 standard format. For example, 2019-01-01T01:01:01+08:00.

Result processing logic

After calling the API, a response is returned with two result codes, result.resultStatus and transferResult.resultStatus.

  • result.resultStatus indicates the result of the inquiry.
  • transferResult.resultStatus indicates the result of the transfer.

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 specific reasons, see result.resultCode.

  • For example, if the value of resultCode is ORDER_NOT_EXIST, it means that the transfer is not yet accepted and can be treated as a transfer failure.
  • For other values, refer to the result codes section. If the issue is not resolved, contact WorldFirst Support.

U

This indicates the API call result is unknown.

  • If result.resultCode is TRANSFER_IN_PROCESS, the transfer is being processed. Please wait for the transfer result notification from the notifyTransferResult API.
  • If result.resultCode is COMPLIANCE_PENDING the transfer is pending due to compliance issues. WorldFirst Technical Support will contact the Partner soon.

The Partner can make another API call with the following query strategy:

  • A Partner can make 7 queries at maximum.
  • Intervals between queries: 5m, 10m, 20m, 40m, 80m, 160m, and 320m.

If none of the queries is successful, contact WorldFirst(Alipay) Technical Support.

The possible responses for transferResult.resultStatus are:

Result status

Description

S

This indicates the transfer is successful.

F

This indicates the transfer failed. For more information on why the call failed, see transferResult.resultCode.

U

This indicates the transfer result is unknown.

  • If result.resultStatus is S, and transferResult.resultCode is TRANSFER_IN_PROCESS, the transfer is being processed. Please wait for the transfer result notification from the notifyTransferResult API.
  • If result.resultStatus is S, and transferResult.resultCode is COMPLIANCE_PENDING the transfer is pending due to compliance issues. WorldFirst(Alipay) Technical Support will contact the Partner soon.

The Partner can make another API call with the following query strategy:

  • A Partner can make 7 queries at maximum.
  • Intervals between queries: 5m, 10m, 20m, 40m, 80m, 160m, and 320m.

If none of the queries is successful, contact WorldFirst(Alipay) Technical Support.

Result codes

result.resultCode

resultCode

resultStatus

resultMessage

Further action

SUCCESS

S

Success

PROCESS_FAIL

F

A general business failure occurred. Do not retry.

Human intervention is usually needed. It is recommended that you contact WorldFirst Technical Support to resolve the issue.

PARAM_ILLEGAL

F

Illegal parameters exist. For example, a non-numeric input, or an invalid date.

Check and verify whether the request fields, including the header fields and body fields, are correct and valid.

For details on the fields of each API, see the specific API Structure section.

REQUEST_TRAFFIC_EXCEED_LIMIT

U

The request traffic exceeds the limit.

Call the API again to resolve the issue. If the issue persists, contact WorldFirst Technical Support.

INVALID_API

F

The called API is invalid or not active.

Check whether the correct API is being called.

INVALID_CLIENT

F

The client is invalid.

The Client ID does not exist or is invalid.

INVALID_SIGNATURE

F

The signature is invalid.

Make sure the request is properly signed with a valid signature. For more details, refer to the following chapter:

METHOD_NOT_SUPPORTED

F

The server does not implement the requested HTTP method.

Ensure the HTTP method is POST.

UNKNOWN_EXCEPTION

U

The API call is failed, which is caused by unknown reasons.

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

ORDER_NOT_EXIST

F

The order does not exist.

Retry with another transfer order.

ORDER_NEED_RETRY

U

Note: This result message explains the reason for the error. Retry the order to fix the issue.

Perform further actions according to the specific returned result message.

transferResult.resultCode

resultCode

resultStatus

resultMessage

Further action

SUCCESS

S

Success

PROCESS_FAIL

F

A general business failure occurred. Do not retry.

Human intervention is usually needed. It is recommended that you contact WorldFirst Technical Support to resolve the issue.

PARAM_ILLEGAL

F

Illegal parameters exist. For example, a non-numeric input, or an invalid date.

Check and verify whether the request fields, including the header fields and body fields, are correct and valid.

For details on the fields of each API, see the specific API Structure section.

USER_NOT_EXIST 

F

The user does not exist.

Retry with the correct user information.

USER_ACCOUNT_ABNORMAL

F

The user account status is abnormal.

Retry with a different user. If the issue persists, contact WorldFirst Technical Support for more details.

AMOUNT_EXCEED_LIMIT

F

The amount exceeds the limit.

Make sure the amount submitted is correct and retry.

RISK_REJECT

F

The transfer is rejected for risk control reasons.

Prompt the user that the request is rejected because the risk control failed.

TRANSFER_IN_PROCESS

U

The transfer is being processed.

Query the transfer result with the inquiryTransfer API.

ORDER_IS_CLOSED

F

The order is closed.

Retry with another transfer order.

ORDER_IS_REVERSED

F

The order is reversed.

Retry with another transfer order.

CARD_INFO_NOT_MATCH

F

The card information does not match.

Retry with the correct card information.

UN_SUPPORT_BUSINESS

F

Unsupported business.

Invalid parameters are used e.g. currency is incorrect. Retry with the correct information.

BALANCE_NOT_ENOUGH

F

Balance is not enough.

Make sure the balance is sufficient and retry.

Samples

Request

copy
{
  "transferRequestId": "106"
}

Response

copy
{
  "result": {
    "resultCode": "SUCCESS",
    "resultMessage": "success",
    "resultStatus": "S"
  },
  "transferFactor": {
    "delegationMode": "TRANSFER",
    "transferFundType": "GLOBAL_CNH_CN"
  },
  "transferFromDetail": {
    "transferFromAmount": {
      "currency": "USD",
      "value": "2135"
    }
  },
  "transferId": "2022******",
  "transferRequestId": "106",
  "transferResult": {
    "resultCode": "TRANSFER_IN_PROCESS",
    "resultMessage": "The transfer is being processed",
    "resultStatus": "U"
  },
  "transferToDetail": {
    "transferQuote": {
      "baseCurrency": "USD",
      "quoteCurrencyPair": "USD/CNY",
      "quoteId": "2022******",
      "quotePrice": "6.48118695",
      "quoteUnit": "1"
    },
    "transferToAmount": {
      "currency": "CNY",
      "value": "13837"
    },
    "transferToMethod": {
      "paymentMethodMetaData": "{\"bankAccount\":\"{\\\"bankAccountNo\\\":\\\"********0002\\\",\\\"bankAddress\\\":{\\\"region\\\":\\\"CN\\\"},\\\"bankBIC\\\":\\\"ICBKCNBJ***\\\",\\\"bankName\\\":\\\"工商银行\\\",\\\"holderAccountName\\\":{\\\"fullName\\\":\\\"**\\\"},\\\"holderAccountType\\\":\\\"INDIVIDUAL\\\"}\",\"paymentMethodDetailType\":\"bankAccount\"}",
      "paymentMethodType": "BANK_ACCOUNT"
    }
  }
}

@2024 WorldFirst