{"openapi":"3.1.0","info":{"title":"InBrief public REST API","version":"1.0.0","description":"Implemented public status reads, incident automation, and application event reporting."},"paths":{"/api/public/{slug}/summary":{"get":{"operationId":"readPublicSummary","summary":"Read current public service status","description":"Returns the public summary. Add include=response-time for daily response times, or include=response-time,coverage for observed uptime coverage and current measurement freshness. Uptime is N/A when no time was observed; the legacy binary status field remains the last known state.","tags":["Public status"],"servers":[{"url":"https://status.example.com","description":"Example status page host. Replace it with the hostname of the page you are reading."}],"security":[],"parameters":[{"name":"slug","in":"path","required":true,"description":"Status page slug that belongs to the requested hostname.","schema":{"type":"string"}},{"name":"include","in":"query","required":false,"description":"Optional response-time and coverage representations.","schema":{"type":"string","enum":["response-time","coverage","response-time,coverage"]}}],"responses":{"200":{"description":"The current public summary.","content":{"application/json":{"examples":{"default":{"summary":"Default summary","value":{"slug":"acme","lastChecked":"2026-08-20T21:02:09.028Z","monitoringPaused":false,"services":[{"name":"Checkout API","names":{"en":"Checkout API","ar":"واجهة الدفع"},"url":"","icon":"https://status.example.com/icons/checkout.svg","slug":"checkout-api","status":"up","uptime":"99.98%","uptimeDay":"100.00%","uptimeWeek":"99.95%","uptimeMonth":"99.98%","uptimeYear":"99.98%","time":142,"timeDay":138,"timeWeek":141,"timeMonth":142,"timeYear":142,"dailyMinutesDown":{"2026-08-14":7},"dailyHealth":{"2026-08-14":{"rate":0.486}}}]},"x-inbrief-runtime-contract":"publicStatusSummaryResponse"},"withResponseTime":{"summary":"Summary with response time","value":{"slug":"acme","lastChecked":"2026-08-20T21:02:09.028Z","monitoringPaused":false,"services":[{"name":"Checkout API","names":{"en":"Checkout API","ar":"واجهة الدفع"},"url":"","icon":"https://status.example.com/icons/checkout.svg","slug":"checkout-api","status":"up","uptime":"99.98%","uptimeDay":"100.00%","uptimeWeek":"99.95%","uptimeMonth":"99.98%","uptimeYear":"99.98%","time":142,"timeDay":138,"timeWeek":141,"timeMonth":142,"timeYear":142,"dailyMinutesDown":{"2026-08-14":7},"dailyHealth":{"2026-08-14":{"rate":0.486}},"responseTime":{"windowDays":30,"averageMs":142,"points":[{"day":"2026-08-18","averageMs":138},{"day":"2026-08-19","averageMs":151}]}}]},"x-inbrief-runtime-contract":"publicStatusSummaryWithResponseTime"}}}}},"304":{"description":"The response-time representation has not changed."},"400":{"description":"The include value is unsupported."},"404":{"description":"The public page was not found.","content":{"application/json":{"examples":{"error":{"summary":"The hostname and slug do not identify the same public page.","value":{"error":"Not found"},"x-inbrief-runtime-contract":"errorResponse"}}}}}}}},"/api/public/{slug}/incidents":{"get":{"operationId":"readPublicIncidents","summary":"Read the public incident ledger","tags":["Public status"],"servers":[{"url":"https://status.example.com","description":"Example status page host. Replace it with the hostname of the page you are reading."}],"security":[],"parameters":[{"name":"slug","in":"path","required":true,"description":"Status page slug that belongs to the requested hostname.","schema":{"type":"string"}}],"responses":{"200":{"description":"Published incidents and scheduled maintenance.","content":{"application/json":{"examples":{"ledger":{"summary":"Incident ledger","value":{"slug":"acme","incidents":[{"id":"inc_example_01","type":"incident","services":["checkout-api"],"startedAt":"2026-08-14T09:00:00.000Z","resolvedAt":"2026-08-14T09:41:00.000Z","publishedAt":"2026-08-14T09:00:10.000Z","scheduledEndAt":null,"maintenanceState":null,"title":{"en":"Elevated error rates"},"summary":{"en":"We are investigating elevated error rates."},"updates":[{"id":"update_example_01","status":"identified","body":{"en":"A failover has been triggered."},"createdAt":"2026-08-14T09:12:00.000Z"}]}]},"x-inbrief-runtime-contract":"publicStatusIncidentsResponse"}}}}},"404":{"description":"The public page was not found.","content":{"application/json":{"examples":{"error":{"summary":"The hostname and slug do not identify the same public page.","value":{"error":"Not found"},"x-inbrief-runtime-contract":"errorResponse"}}}}}}}},"/api/v1/incidents":{"post":{"operationId":"createIncident","summary":"Create an incident or scheduled maintenance entry","tags":["Incident automation"],"servers":[{"url":"https://inbrief.example","description":"Example InBrief product host. Replace it with the host where the account is managed."}],"security":[{"incidentApiKey":[]}],"requestBody":{"required":true,"content":{"application/json":{"examples":{"incident":{"summary":"Incident create request","value":{"title":"Elevated error rates","summary":"We are investigating reports of elevated error rates on the API.","monitorSlugs":["api"],"startedAt":"2026-08-15T09:00:00Z"},"x-inbrief-runtime-contract":"createIncidentRequest"}}}}},"responses":{"201":{"description":"The incident was created.","content":{"application/json":{"examples":{"created":{"summary":"Created incident","value":{"id":"inc_example_02","type":"incident","title":"Elevated error rates","summary":"We are investigating reports of elevated error rates on the API.","monitorSlugs":["api"],"startedAt":"2026-08-15T09:00:00.000Z","resolvedAt":null},"x-inbrief-runtime-contract":"createIncidentResponse"}}}}},"400":{"description":"The request body is invalid."},"401":{"description":"The incident API key is missing or invalid.","content":{"application/json":{"examples":{"error":{"summary":"The request was refused before a write was made.","value":{"error":"Invalid or revoked API key."},"x-inbrief-runtime-contract":"errorResponse"}}}}},"403":{"description":"The key scope or account capability does not allow this write."},"429":{"description":"The key exceeded its request limit."}}}},"/api/v1/incidents/{id}":{"patch":{"operationId":"updateIncident","summary":"Update, resolve, or reopen an incident","tags":["Incident automation"],"servers":[{"url":"https://inbrief.example","description":"Example InBrief product host. Replace it with the host where the account is managed."}],"security":[{"incidentApiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Incident identifier returned by the create operation.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"examples":{"update":{"summary":"Partial incident update","value":{"resolvedAt":"2026-08-15T10:30:00Z"},"x-inbrief-runtime-contract":"updateIncidentRequest"}}}}},"responses":{"200":{"description":"The current incident state after the update.","content":{"application/json":{"examples":{"updated":{"summary":"Updated incident","value":{"id":"inc_example_02","type":"incident","title":"Elevated error rates","summary":"We are investigating reports of elevated error rates on the API.","monitorSlugs":["api"],"startedAt":"2026-08-15T09:00:00.000Z","resolvedAt":"2026-08-15T10:30:00.000Z","notify":true},"x-inbrief-runtime-contract":"updateIncidentResponse"}}}}},"400":{"description":"The request body is invalid."},"401":{"description":"The incident API key is missing or invalid.","content":{"application/json":{"examples":{"error":{"summary":"The request was refused before a write was made.","value":{"error":"Invalid or revoked API key."},"x-inbrief-runtime-contract":"errorResponse"}}}}},"403":{"description":"The key scope or account capability does not allow this write."},"404":{"description":"The incident was not found in this status page."},"429":{"description":"The key exceeded its request limit."}}}},"/api/v1/incidents/{id}/updates":{"post":{"operationId":"appendIncidentUpdate","summary":"Append an incident timeline update","tags":["Incident automation"],"servers":[{"url":"https://inbrief.example","description":"Example InBrief product host. Replace it with the host where the account is managed."}],"security":[{"incidentApiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"Incident identifier returned by the create operation.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"examples":{"update":{"summary":"Timeline update","value":{"status":"identified","body":"A configuration change at our payment provider was the cause. We are rolling it back."},"x-inbrief-runtime-contract":"appendIncidentUpdateRequest"}}}}},"responses":{"201":{"description":"The timeline update was appended.","content":{"application/json":{"examples":{"appended":{"summary":"Appended timeline update","value":{"id":"update_example_02","incidentId":"inc_example_02","status":"identified","body":"A configuration change at our payment provider was the cause. We are rolling it back.","notify":true,"resolvedIncident":false},"x-inbrief-runtime-contract":"appendIncidentUpdateResponse"}}}}},"400":{"description":"The request body is invalid."},"401":{"description":"The incident API key is missing or invalid.","content":{"application/json":{"examples":{"error":{"summary":"The request was refused before a write was made.","value":{"error":"Invalid or revoked API key."},"x-inbrief-runtime-contract":"errorResponse"}}}}},"403":{"description":"The key scope or account capability does not allow this write."},"404":{"description":"The incident was not found in this status page."},"429":{"description":"The key exceeded its request limit."}}}},"/api/v1/events":{"post":{"operationId":"reportEvents","summary":"Report a batch of application request outcomes","tags":["Application events"],"servers":[{"url":"https://inbrief.example","description":"Example InBrief product host. Replace it with the host where the account is managed."}],"security":[{"eventIngestKey":[]}],"requestBody":{"required":true,"content":{"application/json":{"examples":{"batch":{"summary":"Event batch","value":{"events":[{"service":"orders","endpoint":"/v1/orders/:id","method":"GET","status":200,"ms":31},{"service":"orders","endpoint":"/v1/orders/:id","method":"GET","status":503,"ms":2140},{"service":"payments","endpoint":"/v1/charge","method":"POST","status":500}]},"x-inbrief-runtime-contract":"eventBatchRequest"}}}}},"responses":{"202":{"description":"The event batch was accepted and counted.","content":{"application/json":{"examples":{"accepted":{"summary":"Accepted event batch","value":{"accepted":3,"rejected":0,"rows":3,"statements":3},"x-inbrief-runtime-contract":"eventBatchResponse"}}}}},"400":{"description":"The request does not contain an event array."},"401":{"description":"The event ingest key is missing or invalid.","content":{"application/json":{"examples":{"error":{"summary":"The ingest credential is missing, unknown, or revoked.","value":{"error":"Invalid or revoked ingest key."},"x-inbrief-runtime-contract":"errorResponse"}}}}},"403":{"description":"The key scope or account capability does not allow event reporting."},"405":{"description":"This endpoint accepts POST only."},"413":{"description":"The batch contains too many events."}}}},"/api/v2/events":{"post":{"operationId":"reportEventsV2","summary":"Report a reporter batch, or a heartbeat with no events","tags":["Application events"],"servers":[{"url":"https://inbrief.example","description":"Example InBrief product host. Replace it with the host where the account is managed."}],"security":[{"eventIngestKey":[]}],"requestBody":{"required":true,"content":{"application/json":{"examples":{"batch":{"summary":"Reporter batch","value":{"reporter":{"reporterId":"orders-api-eu-1","englishName":"Orders API (Frankfurt)","region":"eu-central","team":"payments","expectedEverySeconds":30},"events":[{"endpoint":"/v1/orders/:id","method":"GET","status":200,"ms":31},{"endpoint":"/v1/orders/:id","method":"GET","status":503,"ms":2140}]},"x-inbrief-runtime-contract":"eventReporterBatchRequest"},"heartbeat":{"summary":"Heartbeat with no events","value":{"reporter":{"reporterId":"orders-api-eu-1","englishName":"Orders API (Frankfurt)","region":"eu-central","team":"payments","expectedEverySeconds":30},"events":[]},"x-inbrief-runtime-contract":"eventReporterBatchRequest"}}}}},"responses":{"202":{"description":"The reporter batch was accepted and the heartbeat recorded.","content":{"application/json":{"examples":{"accepted":{"summary":"Accepted reporter batch","value":{"accepted":2,"rejected":0,"rows":2,"statements":2,"heartbeat":true,"reporterId":"orders-api-eu-1"},"x-inbrief-runtime-contract":"eventReporterBatchResponse"}}}}},"400":{"description":"The body does not carry reporter metadata and an event array."},"401":{"description":"The event ingest key is missing or invalid.","content":{"application/json":{"examples":{"error":{"summary":"The ingest credential is missing, unknown, or revoked.","value":{"error":"Invalid or revoked ingest key."},"x-inbrief-runtime-contract":"errorResponse"}}}}},"403":{"description":"The key scope or account capability does not allow event reporting."},"405":{"description":"This endpoint accepts POST only."},"413":{"description":"The batch contains too many events."}}}}},"components":{"securitySchemes":{"incidentApiKey":{"type":"http","scheme":"bearer","bearerFormat":"ibk_live_...","description":"Incident API key scoped to one status page."},"eventIngestKey":{"type":"http","scheme":"bearer","bearerFormat":"ibk_ingest_...","description":"Event ingest key scoped to one status page."}}}}