Activity Messenger Help Center

Booking packages

See API introduction for authentication, request conventions, pagination, rate limits, and errors.

These endpoints return JSON arrays; they do not support page or per_page.

Send the X-Activity-Messenger-Api-Key header on every request. Packages are the bookable offers managed under E-Commerce → Booking packages; package categories group them on the microsite. Archived (deleted) packages and categories are never returned; hidden and disabled ones are.

A package category object contains these fields:

  • id: numeric category ID; the stable key.
  • name: category name.
  • image_url: category image URL, or null.
  • short_description, description: category texts, or null. description can contain HTML.
  • order: integer display order.
  • visible: boolean; false when the category is hidden from the public microsite.
  • microsite_url: public microsite URL of the category.
  • iframe_url: URL of the same page in the embeddable iframe layout.

A package object contains these fields:

  • id: numeric package ID; the stable key.
  • package_category_id: ID of the category, or null when the package is not in a category.
  • name: in the current release this field returns the numeric package ID rather than the package name.
  • image_url, image_url2, image_ur3: image URLs, or null. The third key is spelled image_ur3.
  • short_description, description: package texts, or null. description can contain HTML.
  • order: integer display order.
  • visible: boolean; false when the package is hidden from the public microsite.
  • disabled: boolean; true when the package cannot be booked.
  • price: decimal string with two decimals, for example "100.00".
  • tax_info: null when the price is zero. Otherwise an object with display, after_tax, before_tax, inclusive_tax, exclusive_tax, tax (numbers), taxes (one amount per tax), names, inclusive_names, and exclusive_names (tax names).
  • microsite_url: public microsite URL of the package.
  • iframe_url: URL of the same page in the embeddable iframe layout.

GET /api/v1/organization/{organization}/package_categories

Retrieve the package categories defined to group packages. Only categories that contain at least one package are returned, ordered by order then newest first. The array is empty when no package is in a category.

GET /api/v1/organization/{organization}/packages

Retrieve all packages of the organization, in every category and outside categories. No filter or ordering parameter is supported.

[
  {
    "id": 5678,
    "package_category_id": 91,
    "name": 5678,
    "image_url": "https://activitymessenger.com/storage/example/package.jpg",
    "image_url2": null,
    "image_ur3": null,
    "short_description": "Private court, one hour",
    "description": "<p>Book a private court for one hour.</p>",
    "order": 1,
    "visible": true,
    "disabled": false,
    "price": "40.00",
    "tax_info": {
      "display": 40,
      "after_tax": 45.99,
      "before_tax": 40,
      "inclusive_tax": 0,
      "exclusive_tax": 5.99,
      "tax": 5.99,
      "taxes": [2, 3.99],
      "names": ["GST 5%", "QST 9.975%"],
      "inclusive_names": [],
      "exclusive_names": ["GST 5%", "QST 9.975%"]
    },
    "microsite_url": "https://activitymessenger.com/org/1234/package/5678",
    "iframe_url": "https://activitymessenger.com/iframe//org/1234/package/5678"
  }
]

GET /api/v1/organization/{organization}/package_categories/{package_category}/packages

Retrieve all packages contained in the package category, ordered by order then newest first. Replace {package_category} with a category id returned by GET package_categories. Each item is a package object as described above.