Step 1: Create a New List

Now that we’ve covered the List data model, let’s try creating a List through the API. In this guide, we will walk through creating a Menu. If you want to practice creating another List, the calls below can be substituted with the corresponding endpoint for that List type and with the minor changes needed to the request body. As noted earlier, we highly recommend creating your desired List in the dashboard first and then retrieving it (see the ‘View an Existing List’s Data’ step later in this guide) so that you don’t have to construct the data model from scratch. Let’s begin!

To create a Menu, you must use the Menus: Create request. The request body will contain the Menu data.

Example Request:

Example Response:

{
  "id": "breakfast01",
  "name": "Breakfast",
  "title": "Breakfast Menu",
  "publish": true,
  "language": "en",
  "currency": "USD",
  "sections": [
    {
      "id": "breakfastSubsection01",
      "name": "Pancakes",
      "description": "Enjoy our delicious pancake offerings",
      "items": [
        {
          "id": "pancake01",
          "name": "Buttermilk Pancakes",
          "description": "Our delicious flaky, buttermilk pancakes",
          "photo": {
            "url": "https:\/\/image.shutterstock.com\/z\/stock-photo-high-stack-of-oatmeal-pancakes-the-rustic-style-with-copy-space-shallow-dof-540640885.jpg",
            "height": 150,
            "width": 150
          },
          "calories": {
            "type": "FIXED",
            "calorie": 200
          },
          "cost": {
            "type": "PRICE",
            "price": "3.00",
            "unit": "Each"
          }
        }
      ]
    }
  ]
}

If the request is successful, you will receive a 201 response, and the response field will contain the id of the created Menu:

{
  "id": "breakfast01"
}

Try creating another Menu and changing and adding some of the fields above.

Feedback