API Reference
POST /report
Analyze an entire menu and get a comprehensive quality report: duplicates, noise detection, cuisine breakdown, non-food items, and an overall quality score. Useful for onboarding new restaurants or auditing existing catalog data.
Request
| Parameter | Type | Required | Description |
|---|
items | string[] | Yes | Full menu item list to analyze. 1-2000 items, max 500 chars each. |
restaurant_name | string | No | Restaurant name for the report header. Default: empty string. |
{
"items": [
"Chicken Biryani",
"**NEW** Murgh Biryani Serves 2",
"Paneer Tikka",
"Panner Tika",
"Masala Dosa",
"Paper Napkins",
"Cigarette Lighter"
],
"restaurant_name": "Sample Restaurant"
}
Response
| Field | Type | Description |
|---|
restaurant_name | string | Restaurant name (if provided) |
total_items | int | Total menu items analyzed |
noise_analysis | object | Promotional text and formatting noise analysis |
dedup_summary | object | Duplicate item detection summary |
cuisine_breakdown | object or null | Cuisine distribution (null if classifier not loaded) |
non_food_items | object[] | Items detected as non-food |
quality_score | int | Overall menu quality score (0-100, higher is better) |
processing_time_ms | float | Processing time in milliseconds |
noise_analysis
| Field | Type | Description |
|---|
items_with_noise | int | Count of items with promotional or formatting noise |
noise_percentage | float | Percentage of menu items with noise |
examples | object[] | Up to 5 examples showing original and cleaned text |
dedup_summary
| Field | Type | Description |
|---|
total_clusters | int | Number of duplicate groups found |
total_duplicate_items | int | Total excess duplicates across all clusters |
top_clusters | object[] | Largest duplicate clusters (up to 10) |
cuisine_breakdown
| Field | Type | Description |
|---|
distribution | object | Cuisine label to item count mapping, e.g. {"North Indian": 12, "Chinese": 5} |
non_food_items
| Field | Type | Description |
|---|
item | string | Item text flagged as non-food |
category | string | Non-food category: pharmacy, grocery, or merchandise |
Example
import requests
response = requests.post("https://embed.statode.com/report",
headers={"X-API-Key": "YOUR_KEY", "Content-Type": "application/json"},
json={
"items": menu_items,
"restaurant_name": "Biryani House"
}
)
report = response.json()
print(f"Quality Score: {report['quality_score']}/100")
print(f"Duplicates: {report['dedup_summary']['total_duplicate_items']} excess items")
print(f"Noise: {report['noise_analysis']['noise_percentage']:.0f}% of items have noise")
print(f"Non-food: {len(report['non_food_items'])} items flagged")
Cost
3.0 credits per item.
Notes
- This endpoint runs the full analysis pipeline (embed + dedup + classify + noise detection + non-food detection), which is why it costs more than individual endpoints.
- The quality score penalizes: high duplicate percentage, noise, non-food items, and low cuisine diversity.
- Non-food detection catches items like paper napkins, cigarettes, phone chargers, and other merchandise that sometimes appears in delivery platform catalogs.
- For menus over 2000 items, split into batches.