Skip to Content
ReferenceAPI Access

API Access

Developer documentation for integrating with Atlee.

Overview

The Atlee API enables programmatic access to your restaurant’s menu data, allergen information, and analytics.

Base URL: https://api.atlee.app/v1

Authentication

API Keys

All requests require authentication via API key.

Getting an API Key:

  1. Navigate to Settings > API
  2. Click Generate API Key
  3. Copy and securely store the key
  4. Key shown only once

Using the Key:

Authorization: Bearer YOUR_API_KEY

Key Permissions

API keys inherit the permissions of the user who created them:

  • Owner keys: Full access
  • Member keys: Limited to their permissions

Key Management

  • View active keys in Settings
  • Revoke keys that are compromised
  • Rotate keys periodically (recommended)

Rate Limits

PlanRequests/MinuteRequests/Day
Basic601,000
Professional30010,000
EnterpriseCustomCustom

Rate Limit Headers:

X-RateLimit-Limit: 60 X-RateLimit-Remaining: 45 X-RateLimit-Reset: 1609459200

Endpoints

List Items

GET /restaurants/{restaurant_id}/items

Query Parameters:

ParameterTypeDescription
statusstringFilter by status (published, draft)
limitintMax items to return (default 100)
offsetintPagination offset

Response:

{ "items": [ { "id": "uuid", "name": "Signature Burger", "description": "Half-pound beef patty", "price_cents": 1299, "status": "published", "allergens": { "milk": "contains", "wheat": "contains", "peanuts": "safe" } } ], "total": 45, "limit": 100, "offset": 0 }

Get Item

GET /restaurants/{restaurant_id}/items/{item_id}

Create Item

POST /restaurants/{restaurant_id}/items

Request Body:

{ "name": "New Item", "description": "Description here", "price_cents": 999, "status": "draft" }

Update Item

PATCH /restaurants/{restaurant_id}/items/{item_id}

Delete Item

DELETE /restaurants/{restaurant_id}/items/{item_id}

Allergens

Get Item Allergens

GET /restaurants/{restaurant_id}/items/{item_id}/allergens

Response:

{ "allergens": { "milk": "contains", "eggs": "unconfirmed", "wheat": "safe" } }

Update Item Allergens

PATCH /restaurants/{restaurant_id}/items/{item_id}/allergens

Request Body:

{ "milk": "contains", "wheat": "safe" }

List Menus

GET /restaurants/{restaurant_id}/menus

Get Menu with Items

GET /restaurants/{restaurant_id}/menus/{menu_id}?include=items

Analytics

Get Overview

GET /restaurants/{restaurant_id}/analytics/overview

Query Parameters:

ParameterTypeDescription
start_datedateStart of period (YYYY-MM-DD)
end_datedateEnd of period (YYYY-MM-DD)

Response:

{ "period": { "start": "2024-01-01", "end": "2024-01-31" }, "metrics": { "menu_views": 1234, "unique_visitors": 890, "qr_scans": 567, "filter_usage_rate": 0.32 } }

Webhooks

Available Events

EventDescription
item.createdNew item created
item.updatedItem modified
item.deletedItem deleted
allergen.updatedAllergen status changed
flag.createdCommunity flag submitted
review.createdNew review submitted

Configuring Webhooks

  1. Navigate to Settings > API > Webhooks
  2. Click Add Webhook
  3. Enter endpoint URL
  4. Select events to receive
  5. Save

Webhook Payload

{ "event": "item.updated", "timestamp": "2024-01-15T12:00:00Z", "restaurant_id": "uuid", "data": { "item_id": "uuid", "changes": { "name": { "old": "Old Name", "new": "New Name" } } } }

Webhook Security

Verify webhook authenticity:

X-Atlee-Signature: sha256=abc123...

Compute HMAC-SHA256 of request body with your webhook secret.

Error Handling

Error Format

{ "error": { "code": "INVALID_REQUEST", "message": "Item name is required", "details": { "field": "name" } } }

Error Codes

CodeHTTP StatusDescription
UNAUTHORIZED401Invalid or missing API key
FORBIDDEN403Insufficient permissions
NOT_FOUND404Resource not found
RATE_LIMITED429Too many requests
INVALID_REQUEST400Malformed request
SERVER_ERROR500Internal error

SDKs

Official SDKs available:

  • JavaScript/Node.js: npm install @atlee/api
  • Python: pip install atlee-api
  • Ruby: gem install atlee

JavaScript Example

import { AtleeClient } from '@atlee/api'; const client = new AtleeClient({ apiKey: 'YOUR_API_KEY' }); const items = await client.items.list({ restaurantId: 'uuid', status: 'published' });

Support

For API support:

Last updated on