A few API Questions


I started using the API to explore a custom-invoice solution for a client but have a few questions that I trust you can help with:

1. The endpoint "booking/[booking_id]/invoice" returns a response which contains an HTML representation of an invoice. But it also contains the following "request" object:
"request": {
  "status": "ERROR",
  "resource": "booking",
  "scope": "invoice",
  "id": "5",
  "method": "get",
  "records": 0,
  "error": {
    "id": "internal",
    "title": "Unknown error",
    "details": "Cannot complete request.",
    "data": ""
  "limit": 0,
  "page": 1,
  "pages": 1,
  "time": 0.0056
I may not ultimately use this endpoint but it would be good to know why I see this error or if it can be safely ignored.

2. The "booking/index" endpoint returns an array of bookings with minimal attributes. So if I want to construct a list of bookings with all attributes then is it required to loop on "booking/[booking_id]" for every booking returned by "booking/index" or is there a better way?

3. I note invoices generated within Checkfront include data related to tax (such as rate and inclusive/exclusive etc) but these items do not appear to be available via the documented API. How can I access these items and, for that matter, any others that may be relevant to constructing a custom invoice?

Many thanks for your help.


  • edited March 2016
    The error isn't anything to be worried about in this case; the internal error is unrelated to the data returned here, and doesn't affect the output beyond that notice.

    The only way to get the complete booking response is requesting a single booking, and while you could go through all of them, I would strongly advise against it except as a one-time occurrence.  If you need to store complete information on bookings, a more advisable option would be to retrieve this data upon receipt of a webhook sent to your server by the system.

    The only information the v3 booking API currently returns about the included taxes is the amounts in the tax_total and tax_inc_total, and the details in the taxes object -- which are associated with their internal tax ID, and could be matched against a local static map in a pinch.  If these aren't sufficient for your needs, we do track feature requests and would be happy to hear what you're interested in seeing.
Sign In or Register to comment.