Getting the order information with API request

To get the information about an order you should send a JSON request to https://www.certoconnect.com/orders/ORDER_ID - replace ORDER_ID to the order_id param your customer was redirected with to Success or Fail URL.

You should verify your identity with HTTP Basic Authentication using your login name and password. The requests must come over SSL/HTTPS.

The response should look like as follows:

{
  "order": {
    "completed_at":null,
    "created_at":"2011-02-17T15:38:54Z",
    "currency":"USD",
    "email":null,
    "fail_url":null,
    "success_url":null,
    "gateway_id":1,
    "id":1,
    "number":"",
    "ref_id":"a5383b8b-db15-47d0-adaf-2f2d1e557cbf",
    "response":null,
    "state":"pending",
    "total_amount":1,
    "updated_at":"2011-02-17T15:39:04Z",
    "user_id":1
  }
}

where:

  • completed_at - time when the order was completed (applicable to completed orders only)
  • created_at - time when the order was created
  • updated_at - time of the latest update of the order
  • currency - currency of the order
  • total_amount - total amount paid/to be paid for the order, in smallest units (1000 means $10.00 for USD)
  • email - e-mail of the payee
  • fail_url - URL that you specified for failure notifications
  • success_url - URL that you specified for success notifications
  • state - status of the order, can be "pending", "completed", "error", "failed" or "cancelled"
  • user_id - unique ID of the merchant in CertoConnect system