Mendloop Docs Request access

API overview

Base URLs, the two parts of the API, versioning, request and response conventions, ids, times and modes.

Mendloop has two HTTP surfaces:

  • Ingest receives errors and events. It sits outside /api/v1 so a Sentry DSN works unchanged, and it takes a publishable key that is safe to ship in an app.
  • The REST API under /api/v1 reads and changes issues, projects, releases, workflows and the rest. It takes a secret key or a signed-in session.

Everything is JSON over HTTPS.

Base URLs#

Surface Mendloop Cloud Self-host
REST API https://app.getmendloop.com/api/v1 MENDLOOP_API_URL + /api/v1 (default http://localhost:8000/api/v1)
Ingest https://ingest.getmendloop.com MENDLOOP_INGEST_URL, which defaults to the API URL
Webhooks from connected tools https://ingest.getmendloop.com/hooks/… the ingest URL + /hooks/…

On a self-hosted install, mendloop serve answers both the REST API and ingest on one port (:8000). If you run mendloop ingest as its own process it listens on :8001; point MENDLOOP_INGEST_URL at it so DSNs and webhook URLs use it.

Tip:

You don't build ingest URLs by hand. A project's dsn field and a connection's webhook_url field already contain the right host.

Ingest or REST?#

You want to Use Key
Send errors from a browser, mobile app or server Ingest (/api/{ingest_id}/envelope/, /v1/events) Publishable pk_live_… / pk_test_…
Upload source maps from CI Source maps Secret key with sourcemaps:write
Read issues, root causes and runs from a script REST API Secret key with issues:read
Change issues (resolve, assign, ignore, merge) REST API Secret key with issues:write
Manage members, keys, connections, approvals REST API A signed-in session (secret keys are refused)

See Authentication for which endpoints accept secret keys.

Versioning#

The REST API is versioned in the path: /api/v1. Changes inside v1 are additive: new endpoints, new optional parameters and new response fields. Write clients that ignore fields they don't know.

The running server describes itself: GET /api/v1/openapi.json is the OpenAPI document and /api/v1/docs is an interactive explorer. Ingest and webhook routes are not in the OpenAPI document.

Requests#

  • Send JSON bodies with Content-Type: application/json. Unknown body fields are rejected with 422 invalid_input, and string values are trimmed.
  • The one exception is the source map upload, which takes multipart/form-data.
  • Org-scoped endpoints are under /api/v1/orgs/{org_id}/…. Copy the organization id from the app; a secret key only works for the organization it was created in.
  • You may send X-Request-ID (8 to 64 characters from A-Z a-z 0-9 . _ -). Mendloop uses it as the request id; otherwise it generates one like req_0193…. Every response, including errors, carries X-Request-ID.

Responses#

  • 200 for reads and updates, 201 when something was created, 202 when work was accepted and continues in the background (a verify run, an RCA, a fix), and 204 with an empty body for deletes.
  • A single object is returned as is. Most lists are {"items": [...], "next_cursor": "…" | null}; see Pagination and limits.
  • Errors always use one shape: {"error": {"code", "message", "hint", "request_id"}}. See Errors.

Ids and times#

  • Ids are UUIDv7 strings, for example 0193b7e2-0a4c-7f19-b8d2-51c3e9a7f604. They sort by creation time.
  • Exceptions: a project's ingest_id is a positive integer (the number at the end of the DSN), an event's event_id is 32 hex characters, and an issue's short_id is the project slug and a number, like RIDER-12.
  • Times are ISO 8601 in UTC, for example 2026-11-05T09:14:03.512Z. Query parameters that take a time read a value without a zone as UTC.

Live and test mode#

Every organization has two separate data planes, live and test. Projects, issues, events, keys, connections and runs exist in one mode only, and an id from one mode is 404 in the other. In test mode, writes to your repos, trackers and chat go to test targets or are simulated.

Caller How the mode is chosen
Secret key The key's prefix: sk_live_… is live, sk_test_… is test. The Mendloop-Mode header is ignored.
Publishable key (ingest) The key's prefix: pk_live_… or pk_test_….
Session The Mendloop-Mode: live or Mendloop-Mode: test header. Default live. Test mode needs a role with mode.switch_test (Admin or Developer).
Note:

Workflows are shared by both modes; their runs belong to the mode they ran in.

Health checks (self-host)#

Two probes sit outside /api/v1 and need no auth:

Endpoint Returns
GET /healthz {"status": "ok"} while the process is up
GET /readyz {"status": "ok" | "degraded" | "down", "checks": {...}} for Postgres, Redis, migrations and storage. 503 when the status is down