Notice

A recent update has seen the release of version 2 of our Direct Post API.

The changes are mostly backwards compatible, however for the Purchase method there are two new changes:

In order to use this functionality please ensure you specify v2 in the URL instead of v1.0.

Example Code

Example code for this form can be found on Github, including a standard purchase form, tokenization form and a token purchase form.

Test Card Numbers

A number of test card numbers can be found on our testing page.

Direct Post Purchase Example

Form Action: https://gateway.sandbox.fatzebra.com.au/v2/purchases/direct/[username]

/

Hidden Fields

Verification

About Verification

There are several hidden fields in this form which are submitted to Fat Zebra from the customers browser. These are:

  • reference - the purchase reference (e.g. invoice or order number)
  • amount - the purchase amount
  • currency - the currency for the transaction
  • return_path - the URL to return the customer to on completion

In order to ensure these values are not changed a verification value is also included, which is determined by the following:

hmac_md5(shared_secret, "[reference]:[amount]:[currency]:[return_path]")