Standalone Transactions API

Using the Transactions API, you can access current and historical transaction statuses for any payment sent by any of our supported processing providers with a simple GET request - no accounts required.

  If you're already integrated with QorCommerce to process payments, track your transactions, and/or get webhook updates this new API will not affect your existing setup.
Tracking a payment

To track a payment simply send a GET request to https://api.qorcommerce.io/v2/transactions/<processor>/<transactions-number>/ with your payment's processor and transaction_number.

You can find a list of all supported processor tokens here.

You will get a response back that includes the latest transaction status via the corresponding transaction_status field, and the entire history via the transaction_history field.

Here's a sample Transaction response:

{
    "transactions_number":"9400110898680009697924",
    "processor": "tsys",
    "transaction_status": {  
        "object_created":"2014-11-29T16:31:19.511Z",
        "status":"SETTLED",
        "status_details":"Your payment has been settled.",
        "status_date":"2012-03-08T09:58:00Z"
        }
    },
    "transaction_history": [  
        {  
            "object_created":"2014-11-29T16:31:19.573Z",
            "status":"UNKNOWN",
            "status_details":"The payment data has been received.",
            "status_date":"2012-03-06T00:00:00Z",
        },
        {  
            "object_created":"2014-11-29T16:31:19.544Z",
            "status":"APPROVED",
            "status_details":"Your payment has approved.",
            "status_date":"2012-03-07T00:00:00Z",
        },
        {  
            "object_created":"2014-11-29T16:31:19.524Z",
            "status":"SETTLED",
            "status_details":"Your payment has been settled.",
            "status_date":"2012-03-08T09:58:00Z"
        }
    ]
}

The possible values for the status field are:

  • "UNKNOWN": The payment has not been found via the processor's system, or it has been found but not yet processed.
  • "APPROVED": The payment has approved by the processor.
  • "DECLINED": The payment has declined by the processor.
  • "SETTLED": The payment has been settled by the processor and the funds are in transit.
  • "VOIDED": The payment has been successfully voided.
  • "REFUNDED": The payment has been successfully refunded.
  • "FAILURE": The processor indicated that there has been an issue with the payment. This can happen for various reasons and depends on the processor. This status does not indicate a technical, but an authorization issue.

Webhooks

QorCommerce offers easy-to-use webhooks for transactions updates. Every time the transactions status has been updated, QorCommerce can POST to all active webhooks of your QorCommerce account. The POST request's body contains a JSON of the Transactions object (see the sample Transaction above).

Requesting webhook updates for a payment
To let QorCommerce know that you want to receive webhook updates for a payment, you need to POST to the Transactions endpoint at https://api.qorcommerce.io/v2/transactions/. The POST request's body needs to consist of your payments's transaction_number and processor:

{
    "transaction_number":"9400110898680009697924",
    "processor": "tsys"
}

You will get the same response as in the GET request outlined above.

QorCommerce will now automatically track your payment and send webhook notifications to all your registered webhooks whenever the payment's transaction status changes.

Creating and testing webhooks
You can set up your webhooks on the API settings page. This page also allows you to test webhooks with a sample payload.

Expected Webhook behavior
QorCommerce expects your webhook to return a response with a 2XX HTTP status code, indicating that the webhook has been received successfully. If QorCommerce doesn't receive a 2XX response status code, the webhook POST request will be re-tried 5 times with a 10 second delay between each try. Thus each webhook will receive max. 6 messages within 1 minute.