Onerway
POST

Query payments

Use this endpoint to retrieve transaction results at the Payment level, including multiple transaction attempts under the same paymentId.

Request

merchantNo
Merchant number assigned by Onerway. See Setup for how to obtain it.
Example:
merchantTxnIds
Condition: Provide this field as one query condition. At least one of merchantTxnIds, transactionIds, startTime + endTime, or paymentId is required.
Comma-separated merchant transaction numbers used to query Payment records in batch.
Example:
Constraints
Range
10IDsA single request can include up to 10 comma-separated IDs.
transactionIds
Condition: Provide this field as one query condition. At least one of merchantTxnIds, transactionIds, startTime + endTime, or paymentId is required.
Comma-separated Onerway transaction numbers used to query Payment records in batch.
Example:
Constraints
Range
10IDsA single request can include up to 10 comma-separated IDs.
paymentId
Condition: Provide this field as one query condition. At least one of merchantTxnIds, transactionIds, startTime + endTime, or paymentId is required.
Payment intent ID, transmitted as a JSON string. Use it to retrieve associated transactions and refund records at the Payment level.
Example:
txnTypes
Comma-separated transaction types used to filter associated transactions under the Payment. This endpoint supports SALE and REFUND.
Example:
Allowed values
SALE
Payment transaction.
REFUND
Refund transaction.
Constraints
Values
This endpoint supports only the SALE and REFUND subset of the shared TxnTypeEnum.
startTime
Condition: Required together with endTime when querying by time range. At least one of merchantTxnIds, transactionIds, startTime + endTime, or paymentId is required.
Start of the query time range, in yyyy-MM-dd HH:mm:ss format.
Example:
Constraints
Rule
The maximum range between startTime and endTime is 90 days.
endTime
Condition: Required together with startTime when querying by time range.
End of the query time range, in yyyy-MM-dd HH:mm:ss format.
Example:
Constraints
Consistency
endTime must be later than startTime.
Rule
The maximum range between startTime and endTime is 90 days.
current
Payment query page number. 0 and 1 both mean the first page; the response current value is always returned as a 1-based page number.
Example:
size
Page size. A single paginated query returns up to 10 records.
Example:
sign
Request signature string. See Request signing for how to generate it.

Request example

curl -X POST 'https://sandbox-acq.onerway.com/v1/txn/queryPayments' \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "merchantNo": "replace_with_merchant_no",
  "paymentId": "replace_with_payment_id",
  "current": "0",
  "size": "10",
  "sign": "{{SIGN}}"
}'

Response

respCode
20000 means the query request was processed successfully. This is request acceptance, not the business result of each transaction. Other values are error codes. See Response codes.
respMsg
Human-readable message for the response code.
Business data object containing the Payment record list and pagination information.

Response example

{
  "respCode": "20000",
  "respMsg": "Success",
  "data": {
    "content": [
      {
        "paymentId": "replace_with_payment_id",
        "paymentStatus": "S",
        "lastTransactionId": "replace_with_transaction_id",
        "lastPaymentAttempt": null,
        "merchantTxnId": "example_merchant_transaction_id",
        "merchantTxnOriginalId": null,
        "txnTime": "2026-01-15 10:30:00",
        "txnCompletionTime": "2026-01-15 10:30:30",
        "productType": "CARD",
        "subProductType": "DIRECT",
        "cardType": "AE",
        "orderAmount": "100.00",
        "orderCurrency": "USD",
        "txnAmount": "100.00",
        "txnCurrency": "USD",
        "arn": null,
        "appId": "replace_with_app_id",
        "website": "https://merchant.example.com",
        "cardNumber": "370000******0002",
        "holderName": "Example Cardholder",
        "eci": null,
        "email": "customer@example.com",
        "channelRequestId": "replace_with_channel_request_id",
        "paymentMethodDetails": {
          "card": {
            "checks": {
              "addressCheck": "fail",
              "postalCodeCheck": "fail",
              "cardholderNameCheck": "fail",
              "avsResultRawCode": "W",
              "threeDSecureResult": null
            },
            "holderName": "Example Cardholder",
            "year": "2029",
            "month": "11",
            "cardType": "AE",
            "productCategory": null,
            "issuer": "Example American Express Issuer",
            "cardBinCountry": "US",
            "authorizationCode": "replace_with_authorization_code",
            "cardNumber": "370000******0002"
          }
        }
      }
    ],
    "current": "1",
    "size": 10,
    "totalPages": 1,
    "totalElements": 1
  }
}
No error responses are documented for this endpoint.