API - Pay with Token
Request: execute a payment using a stored token
POST {BASE_URL}/wipay-payment-admin/payment/token/{tokenId}
This endpoint processes a payment using a previously stored card token. The system validates the merchant, retrieves the associated token, builds the Payment entity, executes the transaction with the configured processor, and updates the payment status accordingly.
Headers
Content-Type
application/json
X-Api-Key
API Key <xxx>
Path Parameters
tokenId
string
Unique identifier of the token
Required
Body
string
userId
Unique user identifier associated with the token
Required
string
merchantId
Unique merchant identifier
Required
string
chargeId
Unique charge identifier for recurring charges; used to distinguish between charges
Optional
number
amount
Total transaction amount
Required
string
currency
ISO currency code (default = 978)
Required
string
terminalId
Unique merchant terminal identifier. If your merchant account has multiple terminals, you must specify the terminal ID to indicate which one to use. If you have only one terminal, you may omit this field—it will default to the only available terminal.
Optional
string
subMerchantId
Sub-merchant identifier if the merchant uses multiple merchant structures
Optional
string
merchantOperationId
Optional field to identify operations in your system (returned in WebHook notifications)
Optional
Example request
Response
Last updated