Create a recipe definition
Requires write. Until this existed, a key could EXECUTE a recipe and not write one, so every collection page a consumer wanted had to be added by a human in the admin UI first — on the one object in the model that is pure configuration and holds no content at all.
Slug is unique per directory; a clash returns 409 carrying the existing recipe, so you can switch to PATCHing it without a round trip to find out which it was.
Request
- Base URL: https://api.epicdirectories.com
- URL: https://api.epicdirectories.com/public/v1/directories/{directory}/recipes
- Auth: API key in header x-api-key
Path parameters
Headers
Optional. Send a unique key per logical operation to make retries safe. 1-256 characters, and only letters, digits, - and _ — colons and other separators are rejected with 400. A retry with the same key replays the original response (status + body) instead of re-executing. Cached for 24h. Reusing a key with a different request body returns 409 — note that a timestamp in the body (e.g. fetchedAt) turns an otherwise-stable key into a permanent 409, so either omit it (snapshots default it server-side) or fold a payload digest into the key. Skipped on 5xx responses (transient errors should be retried fresh).
API Key for authentication
Request body
Example request
{
"slug": "top-restaurants-nyc",
"scope": {
"listingType": "restaurant",
"taxonomyTerms": [
"cuisine:italian"
]
},
"constraints": {
"limit": 50,
"radius": "10mi"
},
"ranking": {
"sortBy": "rating",
"order": "desc"
},
"seo": {
"title": "Top Italian Restaurants in NYC",
"metaDescription": "..."
}
}Response
Recipe created
Changes
No recorded changes to this operation across all 1 revision of this API.