---
title: "Issue a single-use SSE connection ticket"
method: POST
path: "/api/v1/events/ticket"
tags: ["Events"]
---

# Issue a single-use SSE connection ticket

`POST /api/v1/events/ticket`

## Request

- Base URL: `https://api.uptimemonitoring.com`
- URL: `https://api.uptimemonitoring.com/api/v1/events/ticket`
- Auth: HTTP bearer

Mints a short-lived ticket that the dashboard exchanges for an SSE
connection at `GET /api/v1/events/stream`. Requires Bearer auth.
Ticket TTL is 30 seconds; tickets are single-use.
Rate limited to 20 ticket mints per minute per credential (issue
#339 — an API key is one credential shared by every caller who
presents it; a session/OAuth-JWT caller is bucketed per user, not
per account).

## Response `200`

Ticket issued.

- object
  - `ticket` string, required: Opaque single-use token, base64url encoded.
  - `expires_in` integer, required: Seconds until the ticket expires.

## Other responses

- `401`: Missing or invalid credentials.
- `403`: Account is currently suspended. On `POST /api/v1/monitors`, and on a `PUT /api/v1/monitors/{monitorID}` that changes `url` or `type` (issue #335), this can also be returned by the per-account port-scan heuristic when the triggering request crossed the port-fan threshold inside the sliding window (10 minutes by default; `SCAN_WINDOW`). A host-fan trip does NOT suspend the account — see the 429 response instead.
- `429`: Per-credential ticket-mint rate limit exceeded (20 requests/minute, fixed window, keyed the same way as the connection cap above — not per account). Distinct from the dispatcher-wide 200/min limit (`components.responses.RateLimited`) — this limiter only counts ticket mints. The `Retry-After` header gives the integer seconds until the oldest mint slides out of the window.

---

[API](https://skmtc.dev/uptimemonitoring/apis/uptimemonitoring-com-api.md) · [All operations](https://skmtc.dev/uptimemonitoring/apis/uptimemonitoring-com-api/llms.txt) · [OpenAPI document](https://skmtc.dev/uptimemonitoring/apis/uptimemonitoring-com-api/revisions/ddcb2a8bc70f?raw)
