Ouvrir dans Magpie

A menu can be written as one JSON document and pasted into Magpie. On Menu, choose Import JSON… and Magpie adds every menu, category, item and option in the document to your team's menu.

An import only adds. A menu, category or option group whose name your team already has is used as it is, and gets the new categories and items. An item whose name its category already has is skipped, and Magpie lists what it skipped. Nothing you have is changed or removed.

Use Copy the prompt in the import box to copy these instructions for an assistant you use. The assistant will ask you for a photo, a PDF or the text of your menu, the currency of your prices, and the options people choose for an item, then write the document. Magpie writes no text itself.

Importing is all or nothing. Magpie checks the whole document before it saves anything, and names a mistake by its place in the document, such as "menus[0].categories[1].items[3].price" must be a price. A field that is not in the format is refused.

The document

{
  "currency": "CAD",
  "optionGroups": [
    {
      "name": "Size",
      "prompt": "Choose a size",
      "min": 1,
      "max": 1,
      "options": [
        { "name": "Small", "price": 0 },
        { "name": "Large", "price": 4 }
      ]
    },
    {
      "name": "Extras",
      "prompt": "Add up to 3",
      "min": 0,
      "max": 3,
      "options": [
        { "name": "Olives", "price": 1.5 },
        { "name": "Chilli", "price": 1 },
        { "name": "Extra cheese", "price": 2 }
      ]
    }
  ],
  "menus": [
    {
      "name": "All day",
      "categories": [
        {
          "name": "Pizzas",
          "items": [
            {
              "name": "Margherita",
              "description": "Tomato, mozzarella and basil.",
              "price": 14,
              "tags": ["Vegetarian"],
              "contains": "Wheat, milk",
              "optionGroups": ["Size", "Extras"]
            },
            {
              "name": "Diavola",
              "price": "16.50",
              "tags": ["Spicy"],
              "optionGroups": ["Size", "Extras"]
            }
          ]
        },
        {
          "name": "Drinks",
          "items": [
            { "name": "Lemonade", "price": 3.5, "instructions": false }
          ]
        }
      ]
    },
    {
      "name": "Breakfast",
      "hours": { "sat": "08:00-11:00", "sun": "08:00-11:00" },
      "categories": [
        { "name": "Eggs", "items": [ { "name": "Shakshuka", "price": 12 } ] }
      ]
    }
  ]
}

Fields

The document is an object with menus, a list of 1 to 10 menus, and optionally optionGroups and currency.

  • currency: optional, the three-letter code of the prices, such as CAD, USD or EUR. When it is given and is not your team's currency for Online Ordering, the import is refused, so no price is read in the wrong currency.

A menu has:

  • name: up to 80 characters, such as "All day", "Lunch" or "Breakfast".
  • hours: optional, when the menu can be ordered from, by weekday: mon, tue, wed, thu, fri, sat and sun, each with one or more ranges such as "07:00-11:00" or "11:00-14:30, 17:00-22:00". A range can run past midnight, such as "18:00-02:00". A weekday left out is a day the menu is not offered. Without hours, the menu is offered whenever the location is open.
  • categories: 1 to 60 headings, such as Starters, Pizzas or Drinks.

A category has:

  • name: up to 80 characters.
  • description: optional, one line of up to 500 characters.
  • items: its items, in the order the order page shows them. The whole document holds up to 500 items.

An item has:

  • name: up to 120 characters. Two items of one category cannot share a name.
  • price: the price as a number, such as 14 or 16.5, or as text, such as "16.50". It can be 0.
  • description: optional, up to 5,000 characters.
  • tags: optional, words such as "Vegetarian", "Vegan", "Gluten-free" or "Spicy", each up to 40 characters. A tag your team does not have yet is added to your team's list.
  • contains: optional, one line of up to 255 characters naming what the item contains, such as allergens. Magpie shows it as written and makes no claim about it.
  • optionGroups: optional, the names of the option groups asked about this item, in order, from this document or already your team's.
  • instructions: optional, false when people cannot add special instructions to this item. It is true when left out.
  • maxPerOrder: optional, the most of this item one order can have, from 1 to 99.

An option group is something asked about an item, such as Size or Extras. Each group is your team's and can be asked about any number of items. A group has:

  • name: up to 80 characters. Two groups cannot share a name.
  • prompt: optional, what the customer reads, such as "Choose a size", up to 120 characters.
  • min and max: how many answers are needed, from 0 to 20. 1 and 1 means choose exactly one; 0 and 3 means choose up to three. When left out, min is 0 and max is 1.
  • options: 1 to 40 answers, each with a name of up to 80 characters and an optional price that the answer adds, such as 4 for a large size. A price left out is 0.

Writing a menu from a photo

An assistant writing this document from a photo or a PDF of a menu works this way:

  1. Ask for the menu, the currency, and the options people choose for items, such as sizes, extras or how a steak is cooked.
  2. Keep every name and price exactly as the menu writes them.
  3. Make one option group for each kind of option and name it on every item it applies to, rather than writing the same options again.
  4. Leave a field out rather than guessing it.

If an import is refused for a reason this page does not explain, Contacter l’assistance.

Demander à l’assistance Magpie

Envoyez à l’équipe Magpie une question sur tout ce que cet article n’explique pas.