1. Prepare a beneficiary
- Query payout methods for the destination country, currency, and entity type.
- Query required fields with the same business parameters, then prepare identity, address, and account information.
- Create a beneficiary and save the returned
beneficiaryId. Update the beneficiary when its details change.
Before initiating a transfer, check payeeStatus. The beneficiary must be pass (review passed) or unnecessary (review not required). Successful creation alone does not confirm eligibility. Query beneficiary details to check the current status; do not use a beneficiary whose status is disable or deleted to initiate a transfer.
2. Initiate a transfer
If an existing beneficiary's details remain valid, reuse its beneficiaryId instead of creating a beneficiary for each transfer. When details change, update the record and check the result before initiating a transfer. If the update fails, do not proceed as though the new details had been saved.
Call Transfer by beneficiary ID with the beneficiaryId and transaction parameters. Save your request ID and the returned payout ID.
Check respCode in the synchronous response first. Acceptance does not confirm receipt of funds. For a business failure, record respCode and respMsg and handle the reported error.
3. Obtain the result
Receive Transfer result notifications, or query the transfer. Query and notification timestamps use Beijing time (UTC+08:00).
Handle the result according to the transfer status. Inspect the reason for failures and handle duplicate notifications idempotently. If a request times out or its result is unclear, query the original order before initiating another transfer.
Use notifications as the primary way to receive transfer results, while retaining the ability to query them:
| Situation | Recommended action |
|---|---|
| A result notification arrives | Verify the request, match the original order, process its status, and acknowledge it as specified by the notification reference; duplicate notifications must not repeat business actions |
| No notification arrives or a request result is unclear | Query the original order before deciding the next action; do not immediately initiate another payout |
| Reconciling or investigating a transfer | Compare the query result with saved order IDs, statuses, and failure reasons |
Associate your business order with its requestId, payoutId, and beneficiaryId so you can match notifications, query transfers, and investigate failures. See Transfer result notifications for verification and acknowledgement requirements.
4. Vouchers and returned transfers
After a successful payout, download its voucher.
A returned transfer means funds were returned after payout; it differs from a request rejected for invalid parameters. In a transfer result notification, a returned transfer has status = F and payoutStatusReason prefixed with Returned- fail reason:. Retain the payout ID and reason for reconciliation. The status alone does not confirm that funds have been credited to the available balance, and should not trigger an automatic new payout. Contact Onerway when the balance credit or next action is unclear.
What to verify next
Use Testing and go-live to verify success and failure, duplicate notifications, query recovery when notifications are missing, and voucher retrieval. Confirm that your system handles these results correctly before checking production configuration.