{"openapi":"3.0.3","info":{"title":"Mavel REST API","version":"v1","description":"REST API for Mavel. Authentication: pass `X-API-Key: <key>` header. Rate-limited at 200 req/min/project. Plan tier: Enterprise (or Scale+ on Agency tier)."},"servers":[{"url":"/api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-Key"}},"schemas":{"Brand":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"tracked_name":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"}},"domains":{"type":"array","items":{"type":"string"},"description":"Hostname-normalized (RFC-0032 stage 8): scheme/path/query/port stripped before storage — e.g. \"https://zoho.com/cliq?x=1\" is stored as \"zoho.com\". A domain with no extractable hostname is rejected at write time."},"color":{"type":"string"},"parent_brand_id":{"type":"string","nullable":true,"format":"uuid","description":"Set for sub-brand support (this brand rolls up under another tracked brand); null when this brand has no parent."},"is_own":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"}},"required":["brand_id","display_name","tracked_name","aliases","domains","color","parent_brand_id","is_own","created_at"]},"Prompt":{"type":"object","properties":{"prompt_id":{"type":"string","format":"uuid"},"text":{"type":"string"},"state":{"type":"string","enum":["ACTIVE","INACTIVE","SUGGESTED","DELETED"]},"source":{"type":"string"},"country_code":{"type":"string"},"created_at":{"type":"string","format":"date-time"}},"required":["prompt_id","text","state","source","country_code","created_at"]},"Topic":{"type":"object","properties":{"topic_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"country_code":{"type":"string","nullable":true},"created_at":{"type":"string","format":"date-time"}},"required":["topic_id","name","country_code","created_at"]},"Tag":{"type":"object","properties":{"tag_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"color":{"type":"string"},"is_system":{"type":"boolean"},"auto_assigned":{"type":"boolean"}},"required":["tag_id","name","color","is_system","auto_assigned"]},"ReportRow":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"visibility_count":{"type":"integer","description":"Successful-chat count in which this brand was mentioned, over the requested window (the numerator of the visibility ratio). Divide by `visibility_total` for a ratio; never sum/compare `visibility_count` across brands without dividing first — a brand with more tracked prompts naturally has a larger raw count."},"visibility_total":{"type":"integer","description":"Successful-chat count for the (prompt, channel, country, date) buckets this brand is tracked in — the denominator of the visibility ratio (`visibility_count / visibility_total`). Applied identically to every brand tracked in the same bucket, so it is NOT a per-brand-computed figure: summing it across MULTIPLE brands inflates the denominator. Always take the ratio within one brand's own row."},"mention_count":{"type":"integer","description":"Raw brand-name mention count across the window's chats — can exceed `visibility_count` when a chat mentions the brand more than once."}},"required":["brand_id","display_name","visibility_count","visibility_total","mention_count"]},"ErrorResponse":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}},"parameters":{}},"paths":{"/brands":{"get":{"tags":["Brands"],"summary":"List brands","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"tracked_name":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"}},"domains":{"type":"array","items":{"type":"string"},"description":"Hostname-normalized (RFC-0032 stage 8): scheme/path/query/port stripped before storage — e.g. \"https://zoho.com/cliq?x=1\" is stored as \"zoho.com\". A domain with no extractable hostname is rejected at write time."},"color":{"type":"string"},"parent_brand_id":{"type":"string","nullable":true,"format":"uuid","description":"Set for sub-brand support (this brand rolls up under another tracked brand); null when this brand has no parent."},"is_own":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"}},"required":["brand_id","display_name","tracked_name","aliases","domains","color","parent_brand_id","is_own","created_at"]}}},"required":["data"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}},"post":{"tags":["Brands"],"summary":"Create brand","security":[{"ApiKeyAuth":[]}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"tracked_name":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"}},"domains":{"type":"array","items":{"type":"string"},"description":"Hostname-normalized (RFC-0032 stage 8): scheme/path/query/port stripped before storage — e.g. \"https://zoho.com/cliq?x=1\" is stored as \"zoho.com\". A domain with no extractable hostname is rejected at write time."},"color":{"type":"string"},"parent_brand_id":{"type":"string","nullable":true,"format":"uuid","description":"Set for sub-brand support (this brand rolls up under another tracked brand); null when this brand has no parent."},"is_own":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"}},"required":["brand_id","display_name","tracked_name","aliases","domains","color","parent_brand_id","is_own","created_at"]}}}}}}},"/brands/{brand_id}":{"get":{"tags":["Brands"],"summary":"Get brand","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"brand_id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"tracked_name":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"}},"domains":{"type":"array","items":{"type":"string"},"description":"Hostname-normalized (RFC-0032 stage 8): scheme/path/query/port stripped before storage — e.g. \"https://zoho.com/cliq?x=1\" is stored as \"zoho.com\". A domain with no extractable hostname is rejected at write time."},"color":{"type":"string"},"parent_brand_id":{"type":"string","nullable":true,"format":"uuid","description":"Set for sub-brand support (this brand rolls up under another tracked brand); null when this brand has no parent."},"is_own":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"}},"required":["brand_id","display_name","tracked_name","aliases","domains","color","parent_brand_id","is_own","created_at"]}}}}}},"patch":{"tags":["Brands"],"summary":"Update brand","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"brand_id","in":"path"}],"responses":{"200":{"description":"OK"}}},"delete":{"tags":["Brands"],"summary":"Soft-delete brand","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"brand_id","in":"path"}],"responses":{"204":{"description":"Deleted"}}}},"/prompts":{"get":{"tags":["Prompts"],"summary":"List prompts","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"prompt_id":{"type":"string","format":"uuid"},"text":{"type":"string"},"state":{"type":"string","enum":["ACTIVE","INACTIVE","SUGGESTED","DELETED"]},"source":{"type":"string"},"country_code":{"type":"string"},"created_at":{"type":"string","format":"date-time"}},"required":["prompt_id","text","state","source","country_code","created_at"]}}},"required":["data"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}},"post":{"tags":["Prompts"],"summary":"Create prompt","security":[{"ApiKeyAuth":[]}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"prompt_id":{"type":"string","format":"uuid"},"text":{"type":"string"},"state":{"type":"string","enum":["ACTIVE","INACTIVE","SUGGESTED","DELETED"]},"source":{"type":"string"},"country_code":{"type":"string"},"created_at":{"type":"string","format":"date-time"}},"required":["prompt_id","text","state","source","country_code","created_at"]}}}}}}},"/prompts/{prompt_id}":{"get":{"tags":["Prompts"],"summary":"Get prompt","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"prompt_id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"prompt_id":{"type":"string","format":"uuid"},"text":{"type":"string"},"state":{"type":"string","enum":["ACTIVE","INACTIVE","SUGGESTED","DELETED"]},"source":{"type":"string"},"country_code":{"type":"string"},"created_at":{"type":"string","format":"date-time"}},"required":["prompt_id","text","state","source","country_code","created_at"]}}}}}},"patch":{"tags":["Prompts"],"summary":"Update prompt","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"prompt_id","in":"path"}],"responses":{"200":{"description":"OK"}}},"delete":{"tags":["Prompts"],"summary":"Soft-delete prompt","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"prompt_id","in":"path"}],"responses":{"204":{"description":"Deleted"}}}},"/topics":{"get":{"tags":["Topics"],"summary":"List topics","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"topic_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"country_code":{"type":"string","nullable":true},"created_at":{"type":"string","format":"date-time"}},"required":["topic_id","name","country_code","created_at"]}}},"required":["data"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}},"post":{"tags":["Topics"],"summary":"Create topic","security":[{"ApiKeyAuth":[]}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"topic_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"country_code":{"type":"string","nullable":true},"created_at":{"type":"string","format":"date-time"}},"required":["topic_id","name","country_code","created_at"]}}}}}}},"/topics/{topic_id}":{"get":{"tags":["Topics"],"summary":"Get topic","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"topic_id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"topic_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"country_code":{"type":"string","nullable":true},"created_at":{"type":"string","format":"date-time"}},"required":["topic_id","name","country_code","created_at"]}}}}}},"patch":{"tags":["Topics"],"summary":"Update topic","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"topic_id","in":"path"}],"responses":{"200":{"description":"OK"}}},"delete":{"tags":["Topics"],"summary":"Soft-delete topic","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"topic_id","in":"path"}],"responses":{"204":{"description":"Deleted"}}}},"/tags":{"get":{"tags":["Tags"],"summary":"List tags","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"tag_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"color":{"type":"string"},"is_system":{"type":"boolean"},"auto_assigned":{"type":"boolean"}},"required":["tag_id","name","color","is_system","auto_assigned"]}}},"required":["data"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}},"post":{"tags":["Tags"],"summary":"Create tag","security":[{"ApiKeyAuth":[]}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"tag_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"color":{"type":"string"},"is_system":{"type":"boolean"},"auto_assigned":{"type":"boolean"}},"required":["tag_id","name","color","is_system","auto_assigned"]}}}}}}},"/tags/{tag_id}":{"get":{"tags":["Tags"],"summary":"Get tag","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"tag_id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"tag_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"color":{"type":"string"},"is_system":{"type":"boolean"},"auto_assigned":{"type":"boolean"}},"required":["tag_id","name","color","is_system","auto_assigned"]}}}}}},"patch":{"tags":["Tags"],"summary":"Update tag","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"tag_id","in":"path"}],"responses":{"200":{"description":"OK"}}},"delete":{"tags":["Tags"],"summary":"Soft-delete tag","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"tag_id","in":"path"}],"responses":{"204":{"description":"Deleted"}}}},"/suggestions/brands":{"get":{"tags":["Suggestions"],"summary":"List pending brands suggestions","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/suggestions/brands/accept":{"post":{"tags":["Suggestions"],"summary":"Accept a brand suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Accepted"}}}},"/suggestions/brands/reject":{"post":{"tags":["Suggestions"],"summary":"Reject a brand suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Rejected"}}}},"/suggestions/prompts":{"get":{"tags":["Suggestions"],"summary":"List pending prompts suggestions","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/suggestions/prompts/accept":{"post":{"tags":["Suggestions"],"summary":"Accept a prompt suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Accepted"}}}},"/suggestions/prompts/reject":{"post":{"tags":["Suggestions"],"summary":"Reject a prompt suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Rejected"}}}},"/suggestions/topics":{"get":{"tags":["Suggestions"],"summary":"List pending topics suggestions","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/suggestions/topics/accept":{"post":{"tags":["Suggestions"],"summary":"Accept a topic suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Accepted"}}}},"/suggestions/topics/reject":{"post":{"tags":["Suggestions"],"summary":"Reject a topic suggestion","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"Rejected"}}}},"/chats":{"get":{"tags":["Chats"],"summary":"List recent chats","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/chats/{chat_id}":{"get":{"tags":["Chats"],"summary":"Get a chat","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"chat_id","in":"path"}],"responses":{"200":{"description":"OK"}}}},"/sources/urls":{"get":{"tags":["Sources"],"summary":"List source URLs","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/sources/domains":{"get":{"tags":["Sources"],"summary":"List source domains","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/profile":{"get":{"tags":["Profile"],"summary":"Get the project profile","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}},"put":{"tags":["Profile"],"summary":"Replace the project profile","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/models":{"get":{"tags":["Catalog"],"summary":"List models","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/channels":{"get":{"tags":["Catalog"],"summary":"List model channels","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/projects":{"get":{"tags":["Projects"],"summary":"List projects in the org","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/url-content":{"get":{"tags":["Sources"],"summary":"Fetch the cached Markdown for a URL","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/crawl-events":{"post":{"tags":["Crawl"],"summary":"Bulk-ingest crawl events from the customer's CF Worker","security":[{"ApiKeyAuth":[]}],"responses":{"200":{"description":"OK"}}}},"/reports/brands":{"post":{"tags":["Reports"],"summary":"Run a brand-metrics report (dimensions, filters, ordering)","security":[{"ApiKeyAuth":[]}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"project_id":{"type":"string","format":"uuid"},"start_date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"end_date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"dimensions":{"type":"array","items":{"type":"string"}},"filters":{"type":"array","items":{"type":"object","additionalProperties":{"nullable":true}}},"order_by":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string"},"direction":{"type":"string","enum":["asc","desc"]}},"required":["field","direction"]}},"limit":{"type":"integer","minimum":1,"maximum":1000},"offset":{"type":"integer","minimum":0}},"required":["project_id","start_date","end_date"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"brand_id":{"type":"string","format":"uuid"},"display_name":{"type":"string"},"visibility_count":{"type":"integer","description":"Successful-chat count in which this brand was mentioned, over the requested window (the numerator of the visibility ratio). Divide by `visibility_total` for a ratio; never sum/compare `visibility_count` across brands without dividing first — a brand with more tracked prompts naturally has a larger raw count."},"visibility_total":{"type":"integer","description":"Successful-chat count for the (prompt, channel, country, date) buckets this brand is tracked in — the denominator of the visibility ratio (`visibility_count / visibility_total`). Applied identically to every brand tracked in the same bucket, so it is NOT a per-brand-computed figure: summing it across MULTIPLE brands inflates the denominator. Always take the ratio within one brand's own row."},"mention_count":{"type":"integer","description":"Raw brand-name mention count across the window's chats — can exceed `visibility_count` when a chat mentions the brand more than once."}},"required":["brand_id","display_name","visibility_count","visibility_total","mention_count"]}}},"required":["rows"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}}},"/reports/actions":{"get":{"tags":["Reports"],"summary":"Actions report","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"start_date","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"end_date","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"},{"schema":{"type":"string","enum":["OWNED","EDITORIAL","UGC","REFERENCE"]},"required":false,"name":"group","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","additionalProperties":{"nullable":true}}}},"required":["rows"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}}},"/reports/crawl":{"get":{"tags":["Reports"],"summary":"Crawl-events report","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"start_date","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"end_date","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"},{"schema":{"type":"string","format":"uuid"},"required":false,"name":"bot_id","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","additionalProperties":{"nullable":true}}}},"required":["rows"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}}},"/reports/tags":{"get":{"tags":["Reports"],"summary":"Tag-metrics report","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid"},"required":true,"name":"project_id","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"start_date","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":false,"name":"end_date","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":1000},"required":false,"name":"limit","in":"query"},{"schema":{"type":"integer","nullable":true,"minimum":0},"required":false,"name":"offset","in":"query"},{"schema":{"type":"string","format":"uuid"},"required":false,"name":"tag_id","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","additionalProperties":{"nullable":true}}}},"required":["rows"]}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","pattern":"^[A-Z0-9]+(?:_[A-Z0-9]+)*$"},"message":{"type":"string"},"statusCode":{"type":"integer"},"meta":{"type":"object","additionalProperties":{"nullable":true}}},"required":["code","message","statusCode"]}}}}}}}}}