Create a new Lokand restaurant on a customer's behalf — ONE call can produce a complete LIVE website when you pass `menu` (and optionally hours/theme). Returns working OAuth tokens (Bearer, for follow-up edit ops), the live site_url, and a claim_url. NEXT STEPS after this call: refine with add_item/update_item/set_theme if needed, then give the customer the claim_url so they take ownership (free signup); poll claim_status to keep access after they claim. Requires a client registered once via POST /api/auth/oauth2/register (see https://lokand.com/auth.md).
View input schema
{
"type": "object",
"properties": {
"client_id": {
"type": "string",
"minLength": 1,
"description": "Registered OAuth client id"
},
"client_secret": {
"type": "string",
"minLength": 1,
"description": "The client's secret"
},
"name": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Restaurant name"
},
"slug": {
"type": "string",
"pattern": "^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])?$",
"description": "Optional site slug (<slug>.lokand.co); generated from the name when omitted. If taken, a suffixed variant is used automatically."
},
"description": {
"type": "string",
"maxLength": 2000
},
"customer_email": {
"type": "string",
"format": "email",
"description": "Customer's email: binds the claim to it and sends them the claim link"
},
"menu": {
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"default": "Menu",
"description": "Menu name, e.g. \"Menu\" or \"Dinner\""
},
"description": {
"type": "string",
"maxLength": 2000
},
"categories": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"description": "Section name, e.g. \"Burgers\""
},
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"description": {
"type": "string",
"maxLength": 500
},
"price": {
"type": "number",
"minimum": 0,
"maximum": 1000000,
"description": "Price in the business's currency. Required unless `variations` is given."
},
"variations": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 60
},
"price": {
"type": "number",
"minimum": 0,
"maximum": 1000000
}
},
"required": [
"name",
"price"
],
"additionalProperties": false
},
"minItems": 1,
"maxItems": 12,
"description": "Variations of this dish (sizes, volumes, portions), each with its own ABSOLUTE price — see add_item. Use instead of one item per variation."
},
"is_available": {
"type": "boolean",
"default": true
},
"dietary_info": {
"type": "object",
"properties": {
"allergens": {
"type": "array",
"items": {
"type": "string",
"enum": [
"gluten",
"crustaceans",
"eggs",
"fish",
"peanuts",
"soybeans",
"milk",
"nuts",
"celery",
"mustard",
"sesame",
"sulphites",
"lupin",
"molluscs"
]
},
"maxItems": 14
},
"contains": {
"type": "array",
"items": {
"type": "string",
"enum": [
"alcohol",
"pork",
"tobacco"
]
},
"maxItems": 3
},
"suitableFor": {
"type": "array",
"items": {
"type": "string",
"enum": [
"vegetarian",
"vegan",
"halal",
"kosher",
"gluten_free",
"dairy_free",
"nut_free",
"spicy",
"organic"
]
},
"maxItems": 9
},
"caloriesKcal": {
"type": "integer",
"minimum": 0,
"maximum": 20000
},
"portionGrams": {
"type": "integer",
"minimum": 0,
"maximum": 100000
},
"declaredAt": {
"type": "integer",
"exclusiveMinimum": 0
}
},
"additionalProperties": false,
"description": "Allergen/dietary declaration for this dish — see add_item"
}
},
"required": [
"name"
],
"additionalProperties": false
},
"maxItems": 100
}
},
"required": [
"name",
"items"
],
"additionalProperties": false
},
"minItems": 1,
"maxItems": 50,
"description": "Sections in display order; items in display order"
}
},
"required": [
"categories"
],
"additionalProperties": false,
"description": "The full menu, inline — pass this to go live in one call instead of separate create_menu/add_category/add_item calls"
},
"hours": {
"type": "object",
"properties": {
"mon": {
"type": "object",
"properties": {
"open": {
"type": "string",
"pattern": "^([01]\\d|2[0-3]):[0-5]\\d$"
},
"close": {
"$ref": "#/properties/hours/properties/mon/properties/open"
},
"closed": {
"type": "boolean"
}
},
"additionalProperties": false
},
"tue": {
"$ref": "#/properties/hours/properties/mon"
},
"wed": {
"$ref": "#/properties/hours/properties/mon"
},
"thu": {
"$ref": "#/properties/hours/properties/mon"
},
"fri": {
"$ref": "#/properties/hours/properties/mon"
},
"sat": {
"$ref": "#/properties/hours/properties/mon"
},
"sun": {
"$ref": "#/properties/hours/properties/mon"
}
},
"additionalProperties": false,
"description": "Opening hours keyed mon..sun, each {\"open\":\"10:30\",\"close\":\"22:00\"} or {\"closed\":true}"
},
"contact_info": {
"type": "object",
"properties": {
"phone": {
"type": "string",
"maxLength": 40
},
"email": {
"type": "string",
"format": "email",
"maxLength": 254
},
"address": {
"type": "string",
"maxLength": 300
},
"instagram": {
"type": "string",
"pattern": "^@?[A-Za-z0-9._]{1,30}$"
}
},
"additionalProperties": false,
"description": "Contact info: phone, email, address, instagram"
},
"place": {
"type": "object",
"properties": {
"lat": {
"type": "number",
"minimum": -90,
"maximum": 90
},
"lng": {
"type": "number",
"minimum": -180,
"maximum": 180
},
"address": {
"type": "object",
"properties": {
"streetAddress": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"addressLocality": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"addressRegion": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"postalCode": {
"type": "string",
"minLength": 1,
"maxLength": 20
},
"addressCountry": {
"type": "string",
"pattern": "^[A-Z]{2}$"
}
},
"additionalProperties": false
},
"timezone": {
"type": "string",
"maxLength": 64,
"pattern": "^[A-Za-z][A-Za-z0-9_+-]*(?:\\/[A-Za-z0-9_+-]+){0,2}$"
},
"category": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{1,39}$"
},
"cuisines": {
"type": "array",
"items": {
"$ref": "#/properties/place/properties/category"
},
"maxItems": 6
}
},
"additionalProperties": false,
"description": "Where the business is and what kind of place it is: lat/lng; address {streetAddress, addressLocality (district), addressRegion (city or province), postalCode, addressCountry (ISO 3166-1 alpha-2)}; timezone (IANA, e.g. \"Europe/Istanbul\"); category (e.g. restaurant, cafe, bakery, bar, meyhane, fast_food, dessert_shop); up to 6 cuisines (e.g. turkish, kebab, seafood, sushi, vegan). Merged into what is stored: keys you pass replace, keys you leave out stay."
},
"maps_url": {
"type": "string",
"minLength": 1,
"maxLength": 2000,
"description": "A Google Maps, Apple Maps, Yandex or OpenStreetMap link (short share links work), or a \"lat, lng\" pair. Sets the coordinates."
},
"currency_code": {
"type": "string",
"minLength": 3,
"maxLength": 3,
"description": "ISO currency for menu prices, e.g. \"USD\""
},
"theme": {
"type": "object",
"properties": {
"key": {
"type": "string",
"enum": [
"terra",
"porto",
"noir",
"marche",
"slate"
],
"description": "terra | porto | noir | marche | slate"
},
"config": {
"type": "object",
"additionalProperties": {},
"description": "Site document: a v3 document (as get_site.document) or a legacy v2/v1 config such as {\"colors\":{\"primary\":\"#aa3300\"}}. Stored as v3."
}
},
"required": [
"key"
],
"additionalProperties": false
},
"publish": {
"type": "boolean",
"default": true,
"description": "Put the site live immediately (default true). Pass false to keep it a draft."
}
},
"required": [
"client_id",
"client_secret",
"name"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}