{"openapi":"3.1.0","info":{"title":"E.D.I.T.H API","description":"API for the E.D.I.T.H Discord Bot - Security, Moderation, and Music.","version":"1.0.0","contact":{"name":"EDITH Support","url":"https://edithbot.xyz/contact","email":"support@edithbot.xyz"}},"servers":[{"url":"https://edithbot.xyz","description":"Production Server"}],"paths":{"/api/v1/status":{"get":{"operationId":"getSystemStatusV1","summary":"Get System Status","description":"Returns the current operational status of the bot and its subsystems.","parameters":[{"name":"detailed","in":"query","description":"Whether to include detailed subsystem metrics","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","example":"operational"},"timestamp":{"type":"string","format":"date-time"}},"required":["status","timestamp"]}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"Internal server error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"security":[]}},"/api/v1/stats":{"get":{"operationId":"getBotStatsV1","summary":"Get Bot Statistics","description":"Returns public statistics about the bot's usage across Discord.","parameters":[{"name":"cluster_id","in":"query","description":"Optional cluster ID to filter statistics","required":false,"schema":{"type":"string","example":"cluster-1"}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"guilds":{"type":"integer","example":15000},"users":{"type":"integer","example":1200000},"timestamp":{"type":"string","format":"date-time"}},"required":["guilds","users","timestamp"]}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"Internal server error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"security":[]}},"/api/v1/sandbox":{"get":{"operationId":"getSandboxV1","summary":"Sandbox Environment Check","description":"An unauthenticated endpoint for testing API connectivity and schema compliance.","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"environment":{"type":"string","example":"sandbox"},"message":{"type":"string"},"features_enabled":{"type":"array","items":{"type":"string"}},"timestamp":{"type":"string","format":"date-time"}},"required":["environment","message","timestamp"]}}}}},"security":[]}}},"components":{"schemas":{"ProblemDetails":{"type":"object","description":"A machine-readable format for specifying errors in HTTP API responses based on RFC 9457.","properties":{"type":{"type":"string","format":"uri","description":"A URI reference that identifies the problem type.","example":"https://edithbot.xyz/docs/errors/rate-limit"},"title":{"type":"string","description":"A short, human-readable summary of the problem type.","example":"Too Many Requests"},"status":{"type":"integer","format":"int32","description":"The HTTP status code generated by the origin server for this occurrence of the problem.","example":429},"detail":{"type":"string","description":"A human-readable explanation specific to this occurrence of the problem.","example":"You have exceeded your rate limit of 1000 requests per hour."},"instance":{"type":"string","format":"uri","description":"A URI reference that identifies the specific occurrence of the problem.","example":"/api/v1/stats"}},"required":["type","title","status"]}},"securitySchemes":{"OAuth2":{"type":"oauth2","description":"OAuth2 authentication for E.D.I.T.H API","flows":{"authorizationCode":{"authorizationUrl":"https://edithbot.xyz/api/auth/authorize","tokenUrl":"https://edithbot.xyz/api/auth/token","scopes":{"read:status":"Read the system status","read:stats":"Read the bot statistics","guilds":"Access your Discord guilds"}}}}}}}