Menu

Bedful Extras

Extras represent bookable items on the bedful system - they correspond to firewood, hampers, charges for a dog etc. Extras are attached to one site, and a site may have many extras. Bookings may have several extras attached.

Get Extra

Use GET /extras/:id to fetch information on one extra.

curl https://devapi.bedful.com/extras/1 \
-u BEDFUL_KEY: 

Parameters available

  • id : specified in the url
  • expand: set to true to see subsidiary records

This will return JSON like this for the matched record, or a 404 error if no record is found for the given id.

 {
  "id": 32,
  "status": 100,
  "name": "Reflexology treatment",
  "summary": "",
  "site_id": 127,
  "kind": 1,
  "charge_kind": 1,
  "kind_parent": 0,
  "type": 0,
  "price": 3500,
  "number": 1,
  "minimum": 0,
  "maximum": 4,
  "consumable": 0,
  "stock": 9999999,
  "bookingUnits": "[]",
  "images": [],
  "count": 1
  }

Extra Fields

  • ID: The unique id of the extra
  • Status: The status of the extra (0 is draft, 11 Suspended, 100 Live)
  • Name: The name of the extra
  • Summary: A description of the extra (may contain html)
  • SiteID: The site this extra is associated with
  • Kind: The numeric kind of the extra (e.g. Firewood) - based on tag ids
  • KindParent: The numeric parent kind of the extra (e.g. Fees, Food) - based on tag ids
  • ChargeKind: Deprecated, internal use only
  • Type: Deprecated, internal use only
  • Price: The price in cents of this extra
  • Number: The number of the extra (used for ordering)
  • Minimum: The minimum number of an extra available
  • Maximum: The maximum number of an extra available
  • Consumable: Either 0 (default, non-consumable) or 1 (consumable)
  • Stock: The maximum stock of this extra (used if consumable)
  • Units: Deprecated, internal use only
  • Images: Image records associated with the extra
  • Count: Deprecated, internal use only

Get Extras

Use GET /extras to fetch information on more than one extra.

curl https://devapi.bedful.com/extras \
-u BEDFUL_KEY: 
Parameters available
  • site_id: extras available for a site
  • booking_id: extras purchased for a booking

This will return JSON like this for the matched records, or an empty list if no records are found.

 {
  "extras": [
  {
  "id": 29,
  "status": 100,
  "name": "Hire a boat for the duration of your stay",
  "summary": "Rowing boat for 2 people, comes with oars!",
  "site_id": 127,
  "kind": 3,
  "charge_kind": 3,
  "kind_parent": 0,
  "type": 0,
  "price": 1000,
  "number": 4,
  "minimum": 0,
  "maximum": 1,
  "consumable": 0,
  "stock": 9999999,
  "bookingUnits": "[172]",
  "images": [{
    "id": 294925,
    "name": "Hire a boat for the duration of your stay",
    "hash": "4c9b99d94b56ad22c5efd50e434decee6801384a",
    "sort": 0
    }],
  "count": 9999999
  }]
}