Skip to main content

REST 4.0 Reference

Last updated: 14-Apr-2022
Rate this article:

Overview

Use the attached blueprints to integrate with the 2Checkout API via REST 4.0. 

Authentication

To authenticate to the 2Checkout REST API include a header with the following structure into your requests:

X-Avangate-Authentication: code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"

Alternativelly, use:

X-Avangate-Authentication: code='{VENDOR_CODE}' date='{REQUEST_DATE_TIME}' hash='{HASH}'

  • VENDOR_CODE: Your unique 2Checkout supplied merchant code.
  • REQUEST_DATE_TIME: The UTC date-time of the request. Format: YYYY-MM-DD HH:MM:SS. You must provide the time of the request in the GMT timezone.
  • HASH: The hash mac digest with an md5 hashing algorithm of the following: LEN(VENDOR_CODE) + VENDOR_CODE + LEN(REQUEST_DATE_TIME) + REQUEST_DATE_TIME. Use the secret key associated with your account for the hashing.

You must authenticate for all requests.

JSON encoded requests

The 2Checkout REST API supports only JSON encoded requests and responses. You need to include the following headers in your requests:

  • Content-Type: application/json
  • Accept: application/json

Responses follow HTTP specifications regarding response headers. Successful responses are composed of:

  • An HTTP Success header.
  • A JSON encoded string.

REST API 4.0 Blueprints for Download

 

REST 4.0 Blueprints (.zip) LegacyRESTAPI4Blueprints.zip

 

Rate this article:

Need help?

Do you have a question? If you didn’t find the answer you are looking for in our documentation, you can contact our Support teams for more information. If you have a technical issue or question, please contact us. We are happy to help.

Not yet a Verifone customer?

We’ll help you choose the right payment solution for your business, wherever you want to sell, in-person or online. Our team of experts will happily discuss your needs.

Verifone logo