---
title: "Register a component"
method: POST
path: "/components"
tags: ["Components"]
---

# Register a component

`POST /components`

Register a status page component in a project, or refresh an existing active component with the same name.

## Request body

- object
  - `projectId` string, uuid — Project to register the component in. Auto-filled from CLI and SDK context when omitted.
  - `name` string, required — Evidence-backed component name to register.
  - `description` string — Optional component description.
  - `requestId` string, uuid — Project-scoped idempotency key. Reuse only for an identical registration request.
  - `origin` 'code_detected' | 'log_observed' — Machine provenance of this registration: 'code_detected' when the component was inferred from repository or code analysis, 'log_observed' (the default) when inferred from telemetry. Only applies to machine (secret-key) callers; human registrations are always recorded as 'user_declared' and ignore this field.

## Response `200`

OK

- object
  - `component` object, required
    - `id` string, uuid, required
    - `projectId` string, uuid, required
    - `name` string, required
    - `description` string, nullable, required
    - `origin` 'user_declared' | 'code_detected' | 'log_observed', required
    - `lifecycle` 'active' | 'inactive' | 'merged', required
    - `observationState` 'observed' | 'stale' | 'unobserved', required
    - `registryRevision` integer, required
    - `canonicalComponentId` string, uuid, required
    - `mergedIntoComponentId` string, uuid, nullable, required
    - `currentStatus` 'operational' | 'degraded' | 'outage', required — Current health status of this component.
    - `firstSeenAt` string, date-time, required
    - `lastSeenAt` string, date-time, required
    - `deletedAt` string, date-time, nullable, required — Timestamp when this component became inactive or was deleted, if any.
    - `inactiveAt` string, date-time, nullable, required — Timestamp when this component became inactive, if any.
    - `inactiveReason` string, nullable, required — Reason recorded when this component became inactive.
    - `legacyStateUnknown` boolean, required — True only for migration-era inactive rows whose deactivation authority is unknown.

---

[API](https://skmtc.dev/sazabi/apis/sazabi-public-api.md) · [All operations](https://skmtc.dev/sazabi/apis/sazabi-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/sazabi/sazabi-public-api/revisions/1d12b71c735a/schema)
