{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/lastping-dev/json-schema/lastping-dev-check-create-schema.json",
  "title": "CheckCreate",
  "description": "Body for creating a check (POST /api/v1/checks).  The update body is a\nseparate schema — see `CheckPatch` for PATCH /api/v1/checks/{id}.\n\n**Monitor types:**\n- `heartbeat` (default) — expects your service to ping the `ping_url` on schedule.\n- `ci` — like heartbeat but semantically used for CI/CD pipeline pings.\n- `http` — LastPing actively probes the `probe_url` on the given interval.\n  When `monitor_type` is `http` the `probe_*` fields configure the probe\n  and the schedule is driven by `probe_interval_s`.\n\n**Every field is validated against the monitor's SHAPE.**  A field the\nchosen `monitor_type` (and `schedule_kind`) has no place for is rejected\nwith 400 (`FIELD_NOT_IN_SHAPE`) instead of being accepted and silently\ndiscarded.  Examples: `schedule_kind`/`period_s`/`cron_expr`/`tz` or any\n`ci_*` field on an `http` monitor; any `probe_*` field on a `heartbeat`;\n`ci_workflow`/`ci_branch` with no `ci_provider`; `period_s`/`cron_expr`/`tz`\non an `on_demand` schedule.\n\n`null`, `\"\"`, `0`, `false` and empty collections are treated as \"no\nvalue\" and never trigger this rejection, so a client that serialises a\nfull document with zero values for the fields it does not use is\nunaffected.\n\nAn unrecognised `monitor_type` is rejected with 400\n(`UNKNOWN_MONITOR_TYPE`); it used to create a `heartbeat`.\n\n**Upsert:** if `slug` is non-empty and a check with that slug already\nexists in the project, the config is updated and 200 is returned instead of 201.\nThat branch does **not** write `ci_workflow`/`ci_branch` — see those two\nproperties for the full statement, and use `PATCH /api/v1/checks/{id}`\nto set them.\n",
  "x-generated": "2026-11-15",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/lastping-dev-openapi.yaml#/components/schemas/CheckCreate",
  "type": "object",
  "required": [
    "name"
  ],
  "properties": {
    "name": {
      "type": "string",
      "maxLength": 200,
      "description": "Human-readable name for the check: at most 200 characters (not\nbytes) and no control or invisible characters (a tab, newline,\nzero-width character or non-ASCII space is rejected with 400\n`INVALID_NAME`; an ordinary space is fine). Bytes that are not valid UTF-8 are\nreplaced with U+FFFD when the request is decoded, and accepted.\n"
    },
    "slug": {
      "type": "string",
      "description": "Optional stable identifier.  If provided and a check with this slug\nalready exists in the project, the request performs an upsert (config\nupdate) and returns 200 instead of 201.\n\nInput is trimmed and lowercased before validation and before the\nuniqueness lookup, so `\"  Nightly-Backup  \"` and `\"nightly-backup\"`\nare the same slug. Must then match\n`^[a-z0-9][a-z0-9-]{1,48}[a-z0-9]$` (3-50 chars, lowercase\nalphanumeric and hyphens, starting and ending alphanumeric); a 400\nis returned otherwise. A UUID-shaped slug is rejected — the\nTerraform provider resolves an import ID by trying to read it as a\nUUID first, so a UUID-shaped slug could never be imported by slug and\ncould collide with another monitor's real id.\n\nAn empty slug means \"no slug\" — it is exempt from the uniqueness\ncheck, is not validated, and multiple unslugged monitors are\nallowed in the same project.\n"
    },
    "monitor_type": {
      "type": "string",
      "enum": [
        "heartbeat",
        "ci",
        "http"
      ],
      "description": "Monitor mode.  Defaults to `heartbeat` when omitted.  Any other\nvalue is rejected with 400 (`UNKNOWN_MONITOR_TYPE`).\nUse `http` to have LastPing actively probe a URL instead of waiting\nfor an inbound ping.\n\n`ci` is a label, not a binding.  A CI monitor is stored as a\n`heartbeat` row with a CI binding attached, so it is `ci_provider`\nthat makes a monitor a CI monitor — `monitor_type: ci` on its own\ncreates an ordinary heartbeat, and its `ci_workflow`/`ci_branch`\nare then rejected with 400 (`FIELD_NOT_IN_SHAPE`).\n"
    },
    "schedule_kind": {
      "type": "string",
      "enum": [
        "simple",
        "cron",
        "on_demand"
      ],
      "description": "`simple` uses a fixed period; `cron` uses a cron expression;\n`on_demand` means the check has no cadence at all — it is driven\nentirely by run events (`start`/`success`/`fail`/…), never arms an\nabsence deadline, and silence between runs never alerts. Run-scoped\ndetection (`max_runtime_s`, `step_timeout_s`) still applies once a\nrun starts, and `expect_every_s` — the silence floor — is the only\nway to detect absence between runs.\nRequired for `heartbeat` and `ci` monitor types.\n\n**Rejected with 400 (`FIELD_NOT_IN_SHAPE`) when `monitor_type` is\n`http`**, together with `period_s`, `cron_expr` and `tz`: an http\nmonitor's schedule is derived from `probe_interval_s`, so all four\nwere previously accepted and discarded.\n"
    },
    "period_s": {
      "type": "integer",
      "format": "int64",
      "description": "Expected ping interval in seconds.  Required when schedule_kind is `simple`.\n\n**Must be absent when schedule_kind is `on_demand`** — supplying it\nalongside `on_demand` is rejected with 400 (`ON_DEMAND_SCHEDULE_CONFLICT`).\n"
    },
    "cron_expr": {
      "type": "string",
      "description": "Cron expression (5-field).  Required when schedule_kind is `cron`.\n\n**Must be absent when schedule_kind is `on_demand`** — supplying it\nalongside `on_demand` is rejected with 400 (`ON_DEMAND_SCHEDULE_CONFLICT`).\n"
    },
    "tz": {
      "type": "string",
      "description": "IANA timezone for cron evaluation.  Defaults to `UTC`."
    },
    "grace_s": {
      "type": "integer",
      "format": "int64",
      "description": "Grace period in seconds after a ping is due before the check is\nconsidered late.  This is the **silence** tolerance and the\nfirst-run (`monitor_from`) deadline.  It is also the fallback\nrun-duration budget when `max_runtime_s` is not set.\n"
    },
    "max_runtime_s": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "minimum": 60,
      "maximum": 31536000,
      "description": "Run-duration budget in seconds, measured from an unmatched\n`/start` ping.  It replaces `grace_s` for the **overrun deadline\nonly** — the silence rule (`alert_after = due_at + grace_s`) and\nthe first-run seed (`alert_after = monitor_from + grace_s`) keep\nusing `grace_s`.  This is what makes \"alert if silent for more\nthan 10 minutes, but allow a 4-hour run\" expressible.\n\nTime a run spends `blocked` (waiting on a person) does not count\ntoward this budget: the run's clocks pause at the `blocked` ping,\nand when the next ping or step ends the wait, the waited time is\nadded to the run's budget and the `step_timeout_s` clock starts\nagain from that moment.  Each single wait is bounded by\n`blocked_timeout_s`, but the total a run can add this way has no\ncap: a run that keeps alternating waits shorter than\n`blocked_timeout_s` with progress never overruns.  On a `simple`\nor `cron` monitor the added time never postpones a missed\nscheduled run: when the next run's silence deadline comes sooner,\nthat deadline still pages.\n\nNull or omitted falls back to `grace_s`, so a monitor that never\nsets it behaves exactly as before this field existed.\n\n**Rejected with 400 (`MAX_RUNTIME_NOT_SUPPORTED`) when\n`monitor_type` is `http`.**  An HTTP probe has no start/success\npair — the prober mints a fresh run id for every probe — so no\nstart is ever outstanding and the overrun rule can never fire.\nUse `probe_timeout_s` to bound a single probe.\n"
    },
    "step_timeout_s": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "minimum": 10,
      "maximum": 86400,
      "description": "Progress budget in seconds: how long an armed run may go without\nposting a `/step` before a `stalled` incident opens.  The anchor is\nthe LATER of the run's `/start` and its most recent `/step`, so a\nrun that wedges before its first step is caught too.\n\nNull or omitted disables stall detection entirely, which is how\nevery monitor behaved before this field existed.\n\nStall detection needs your job to call /step: the Claude Code hook\nand the reporting prompt do not send steps, so leave step_timeout_s\nunset for them.\n\nA step resets the stall clock ONLY — it never extends\n`max_runtime_s`, so an agent that reports progress forever still\noverruns.\n\n**Must be strictly less than the effective run budget,\n`COALESCE(max_runtime_s, grace_s)`**, or the request is rejected\nwith 400 (`STEP_TIMEOUT_EXCEEDS_BUDGET`).  The stall rule fires only\ninside that budget — past it the run is an overrun and `overrun` is\nthe truer cause — so a step timeout at or above the budget leaves an\nempty window and the rule could never fire.\n\n**Rejected with 400 (`STEP_TIMEOUT_NOT_SUPPORTED`) when\n`monitor_type` is `http`.**  An HTTP probe never arms a run, so\nthere is nothing for a step to report progress within.  Use\n`probe_timeout_s` to bound a single probe.\n"
    },
    "expect_every_s": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "minimum": 60,
      "maximum": 31536000,
      "description": "**Silence floor**: open a `silence` incident if **no ping of any\nkind** — `success`, `start`, `fail`, `step` — has arrived within\nthis many seconds, regardless of the schedule.  It is anchored on\nthe monitor's last activity (`last_ping_at`), never on the\nschedule: it is a floor on silence, not a cadence.\n\nNull or omitted turns it off, which is exactly how every monitor\nbehaved before this field existed.\n\n**This is the only absence rule an `on_demand` monitor can have.**\nThat schedule kind arms no deadlines between runs by design, so\nwithout `expect_every_s` an `on_demand` monitor reads `up`\nindefinitely however long its agent stays dark.\n\nIt never fires mid-run: while a `/start` is outstanding the floor\nstands down entirely and the run clock owns detection\n(`max_runtime_s`, `step_timeout_s`).  A `blocked` ping also\nsuppresses it, bounded by `blocked_timeout_s`.\n\nOn `simple`/`cron` monitors it is a **backstop**: it joins the\nschedule's own deadline as whichever is *sooner*, so it can tighten\ndetection under a long cadence but can never loosen it.\n\nAccepted on every `monitor_type` and every `schedule_kind` — unlike\n`max_runtime_s`/`step_timeout_s` it has no run-scoped precondition\nthat would make it a provable no-op on an HTTP monitor.\n"
    },
    "notify_min_run_s": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "minimum": 60,
      "maximum": 31536000,
      "description": "**Notification duration floor**: a run **shorter** than this many\nseconds does not produce an INFO-CLASS notification (`success`,\n`started`, `every-run`, `note`). This is what stops a trivial,\nfast agent run — \"what's 2+2\" — from paging a destination routed\nto `success` exactly like a real, hours-long job would.\n\n**It never suppresses `down`, `fail`, `recovery` or `blocked`** —\nthose are alert-class and are never affected by this field,\nhowever short the run.  A run that failed in two seconds is\nexactly what a user needs to hear about.\n\nIt never suppresses `started` (a run's duration does not exist\nyet the moment it begins), and it never suppresses an event whose\nduration could not be measured at all — an unknown duration\nalways means \"notify\", never \"suppress\".\n\nNull or omitted turns it off, which is exactly how every monitor\nbehaved before this field existed.\n\n**Rejected with 400 (`NOTIFY_MIN_RUN_NOT_SUPPORTED`) when\n`monitor_type` is `http`.**  The floor only ever suppresses a\nnotification once a run's duration is measured, and that\nmeasurement comes exclusively from a matched `/start` +\n`/success` pair — which an HTTP probe never produces (the prober\nmints a fresh run id per probe).\n"
    },
    "blocked_timeout_s": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "description": "How long (in seconds) a check may sit `blocked` — reported via a\n`blocked` ping, meaning the run is waiting on a human — before a\n`blocked` incident opens.\n\n**Null or omitted does NOT mean \"wait forever\".** It falls back to\nthe default, which is **24 hours**, after which\nthe `blocked` incident opens regardless. There is no way to\ndisable the blocked timeout entirely.\n\nAccepted on every `monitor_type`, including `http` — unlike\n`max_runtime_s`/`step_timeout_s` it has no run-scoped precondition\nthat would make it a provable no-op on an HTTP monitor.\n"
    },
    "failure_threshold": {
      "type": "integer",
      "format": "int64",
      "minimum": 1,
      "maximum": 100,
      "default": 1,
      "description": "Number of **consecutive explicit failures** required before an\nincident opens — retry-before-alert.  Applies to the `fail` cause\nONLY: `silence`, `overrun`, `never_started`, `runaway`, `stalled`\nand `blocked` are time- or rate-based, so a consecutive-failure\ncount is meaningless for them and never gates them.  A run that\nends on the model provider's API error (`upstream`) neither\ncounts toward it nor resets it: those page on their own count of\nruns in a row, which is 3 or this threshold, whichever is higher.\n\nBelow the threshold nothing alerts and the status does not change,\nbut the ping is still recorded, an outstanding run is still ended,\nand deadlines are still recomputed — the failed run did happen,\nonly the alert is deferred.  Any success resets the counter to\nzero; a cancel does not.\n\nDefaults to `1` (open on the first failure) when omitted, which is\nthe pre-existing behaviour.  Applies to `http` monitors too: a\nfailed probe is a real `fail` signal.\n"
    },
    "success_threshold": {
      "type": "integer",
      "format": "int64",
      "minimum": 1,
      "maximum": 10,
      "default": 1,
      "description": "Recover after N successes: how many **successes in a row** a\nmonitor that is down on a failure needs before its incident\ncloses and the recovery alert is sent.  It gates the incidents\nfailures open: an explicit fail (a failed http probe included),\na failed output check and runs ending on the model provider's\nAPI error.  Each success while down counts; any failure starts\nthe count again.  While the monitor is up it changes nothing.\nEvery other incident (a missed run or silence, an overrun, a\nstall, a run blocked on a person) closes on the first success,\nwhatever this is set to.  Applies to every monitor type.\n\nDefaults to `1` (close on the first success) when omitted, which\nis the pre-existing behaviour.  An out-of-range value is a 400\nwith code `INVALID_SUCCESS_THRESHOLD`.  On the slug-upsert branch\nan omitted field leaves the stored value unchanged.\n"
    },
    "remind_every": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "minimum": 900,
      "maximum": 604800,
      "description": "Reminders while an incident stays open: re-send the incident's\nalert every this many seconds until it closes, to the same\ndestinations and with the same message template as the alert that\nopened it.  Each reminder says how long the incident has been open\nand its number (\"Still down for 2 h 15 min (reminder 3)\"); a\ncustom template can use `{reminder}` and `{open_for}`.  A paused\nor snoozed monitor sends none.  The recovery alert is unchanged.\n\nOmitted or `null` is off, the default.  A value outside 900 (15\nminutes) to 604800 (7 days), or one that is not a whole number,\nis a 400 with code `INVALID_REMIND_EVERY`.  On the slug-upsert\nbranch an omitted field leaves the stored value unchanged and an\nexplicit `null` turns reminders off.\n"
    },
    "max_reminders": {
      "type": "integer",
      "format": "int64",
      "minimum": 1,
      "maximum": 100,
      "default": 24,
      "description": "The most reminders one incident sends.  Defaults to `24`.  An\nout-of-range value is a 400 with code `INVALID_MAX_REMINDERS`.\nOn the slug-upsert branch an omitted field, or `null`, leaves the\nstored value unchanged.\n"
    },
    "cert_expiry_days": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "integer",
        "minimum": 1,
        "maximum": 90
      },
      "maxItems": 4,
      "uniqueItems": true,
      "default": [
        14,
        3
      ],
      "description": "Certificate expiry warnings, for `http` monitors only, and only\nwhen the URL is `https`: warn this many days before the TLS\ncertificate expires.  Ignored on every other kind of monitor.\nEach threshold warns once per certificate, so a renewed\ncertificate is warned afresh; when several thresholds are crossed\nat once (a certificate first seen with 2 days left) one warning\nis sent, for the smallest.  A warning is an `expiring` alert, not\nan incident.  Up to 4 different whole numbers from 1 to 90,\nstored in descending order; `[]` turns the warnings off.\n\nOmitted or `null` takes the default, `[14, 3]`.  Any other value\nis a 400 with code `INVALID_CERT_EXPIRY_DAYS`.  On the slug-upsert\nbranch an omitted field, or `null`, leaves the stored list\nunchanged.\n"
    },
    "domain_expiry_days": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "integer",
        "minimum": 1,
        "maximum": 90
      },
      "maxItems": 4,
      "uniqueItems": true,
      "default": [
        30,
        7
      ],
      "description": "Domain expiry warnings, for `http` monitors only: warn this many\ndays before the registration of the domain the URL is under\nexpires, as the domain's registry publishes it.  Ignored on every\nother kind of monitor.  Each threshold warns once\nper expiry date, so a renewal is warned afresh.  The same rules as\n`cert_expiry_days`; `[]` turns the warnings off.\n\nOmitted or `null` takes the default, `[30, 7]`.  Any other value\nis a 400 with code `INVALID_DOMAIN_EXPIRY_DAYS`.  On the\nslug-upsert branch an omitted field, or `null`, leaves the stored\nlist unchanged.\n"
    },
    "monitor_from": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "RFC 3339 timestamp.  Deadlines are not computed before this time,\nuseful for checks that should start alerting only from a future date.\n"
    },
    "probe_url": {
      "type": "string",
      "format": "uri",
      "description": "Absolute `http` or `https` URL for LastPing to probe.\nRequired when `monitor_type` is `http`.\n\n**Must not carry a username or password** (`https://user:pass@host`):\nsending one is rejected with 400 (`PROBE_URL_HAS_CREDENTIALS`), since\nit would be stored and shown in the clear. A monitor stored with one\nbefore this rule keeps it until `probe_url` is sent again.\n"
    },
    "probe_method": {
      "type": "string",
      "enum": [
        "GET",
        "HEAD",
        "POST"
      ],
      "description": "HTTP method for the probe request.  Defaults to `GET` when omitted.\nValid values: `GET`, `HEAD`, `POST`.\n"
    },
    "probe_expected_body": {
      "type": "string",
      "description": "Substring that must appear in the response body for the probe to be\nconsidered successful.  Leave empty to skip body matching.\n"
    },
    "probe_interval_s": {
      "type": "integer",
      "format": "int64",
      "description": "How often (in seconds) LastPing should probe the URL.\nMust be between 30 and 86400.  Required when `monitor_type` is `http`.\n"
    },
    "probe_expected_status": {
      "type": "integer",
      "format": "int64",
      "description": "HTTP status code the probe must receive to count as success.\nNo default is applied on create: an omitted (or `0`) value means\n\"any 2xx response counts as success\". Set it explicitly to require\none exact status. On PATCH, an omitted field retains the stored\nvalue.\n"
    },
    "probe_timeout_s": {
      "type": "integer",
      "format": "int64",
      "description": "Probe HTTP request timeout in seconds.  Must be between 1 and 30.\nDefaults to 10 when omitted.\n"
    },
    "probe_follow_redirects": {
      "type": "boolean",
      "description": "Whether the probe should follow HTTP redirects.  Defaults to `false`\nwhen omitted on create. On PATCH, an omitted field retains the\nstored value.\n"
    },
    "ci_provider": {
      "type": "string",
      "enum": [
        "github",
        "gitlab",
        "jenkins"
      ],
      "description": "CI provider to bind on create.  When supplied (and valid), LastPing generates\na webhook secret and binds it.  The secret is returned ONCE in the `201`\nresponse (`ci_secret`) and is NEVER returned again — use the\n`POST /api/v1/checks/{id}/ci/regenerate` endpoint to rotate it.\n\n**Rejected with 400 (`FIELD_NOT_IN_SHAPE`) when `monitor_type` is\n`http`.**  An http monitor is never bound to CI; the request used\nto be accepted, create no binding, and report success.\n\nFixed at creation.  On the slug upsert of a monitor that already\nhas a binding, the stored provider is accepted as a no-op (the\nprovider and secret stay) and a different one is rejected with\n400 (`CI_PROVIDER_IMMUTABLE`); on one created without a binding\nit is rejected with 400 (`FIELD_NOT_IN_SHAPE`), because a binding\ncannot be added to an existing monitor.\n"
    },
    "ci_workflow": {
      "type": "string",
      "description": "Optional CI workflow name to filter inbound webhooks by (provider-specific).\n\n**Requires `ci_provider`, and this is enforced:** with no CI\nbinding the filter is stored nowhere and matches nothing, so the\nrequest is rejected with 400 (`FIELD_NOT_IN_SHAPE`).  It was\npreviously accepted and discarded — a Terraform configuration\nsetting `ci_workflow` without `ci_provider` applied clean and\nfiltered nothing.\n\n**On the slug upsert** (when `slug` names a check that already\nexists, this POST updates it and returns 200) the CI binding is\nthe stored one: a CI-bound monitor accepts `ci_workflow` and\n`ci_branch` without `ci_provider` being repeated, and a monitor\ncreated without a binding still refuses them.  A filter is\nwritten only when it is sent with a non-empty value; omitted or\n`\"\"` keeps the stored value, so an upsert can set a filter but\nnever clear one.  Clear a filter with\n`PATCH /api/v1/checks/{id}` and `null`.\n"
    },
    "ci_branch": {
      "type": "string",
      "description": "Optional branch name to filter inbound webhooks by.\n\n**Requires `ci_provider`, and this is enforced** — see\n`ci_workflow`.  Rejected with 400 (`FIELD_NOT_IN_SHAPE`) when the\nmonitor has no CI binding, and follows the same slug-upsert rule:\nset when sent, kept when omitted or empty, cleared only by PATCH.\n"
    },
    "runaway_ceiling": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int64",
      "description": "Maximum pings allowed in a rolling 1-hour window. Exceeding it opens a\n`runaway`-cause incident, which detects a looping agent or job pinging\nabnormally fast. Null or omitted disables the check.\n"
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "maxItems": 20,
      "description": "Optional labels for namespace scoping and auditing.\nMax 20 tags; each tag max 50 characters. Duplicate tags are silently\ndeduplicated. The `agent:` prefix is a convention for AI-provisioned monitors.\n"
    },
    "agent_id": {
      "type": "string",
      "description": "Optionally attaches this monitor to an agent at creation time, by\neither the agent's `id` or its `slug`. Omitted or empty means \"no\nattachment\" — it never creates an agent implicitly.\n\n**An unknown or foreign agent reference is rejected with 400\n(`UNKNOWN_AGENT`)** — this is what keeps Terraform (or any IaC\nclient) authoritative over the agents it owns: naming an agent\nthat does not exist can never conjure one into being. Create the\nagent first with `POST /api/v1/agents`.\n"
    },
    "source_kind": {
      "type": "string",
      "maxLength": 64,
      "pattern": "^[a-z0-9]+(-[a-z0-9]+)*$",
      "description": "**Discovery source identity, part 1 of 2.** The scanner that found\nthis thing: `crontab`, `github-actions`, `k8s-cronjob`,\n`systemd-timer`. Lowercase, dash-separated — it is compared\nbyte-for-byte, so `GitHub Actions` and `github-actions` would be\ntwo different identities for one scanner.\n\nTogether with `source_ref` and the project, this is the\n**reconcile key** that makes a discovery scan safe to re-run: the\nsecond run diffs against what already exists instead of creating\nevery monitor a second time.\n\nOmit both fields for a hand-made monitor. Monitors with no source\nare never reconciled, so discovery can never adopt, modify or\ndelete something a human created.\n"
    },
    "source_ref": {
      "type": "string",
      "maxLength": 512,
      "description": "**Discovery source identity, part 2 of 2.** A stable path within\n`source_kind` — `.github/workflows/nightly.yml#build`,\n`/etc/cron.d/backup#0 3 * * *`. Must be valid UTF-8 with no control\ncharacters.\n\n**Must be sent together with `source_kind`** — exactly one of the\ntwo is rejected with 400 (`SOURCE_INCOMPLETE`). Half an identity\nreconciles against nothing.\n\n**A pair this project already monitors is rejected with 409\n(`SOURCE_ALREADY_MONITORED`).** That rejection is the feature: it\nis what stops a re-run of discovery from duplicating every\nmonitor.\n\n**On a slug upsert these two fields are read-only.** `POST\n/api/v1/checks` with a `slug` that already exists never rewrites a\nmonitor's source — that would let a slug collision silently adopt a\nhand-made monitor into discovery — and returns 409\n(`SOURCE_IMMUTABLE_ON_UPSERT`) if the body offers a different pair.\nChange a source deliberately with `PATCH /api/v1/checks/{id}`.\n"
    },
    "trace_content": {
      "type": "string",
      "enum": [
        "redacted",
        "dropped"
      ],
      "default": "dropped",
      "description": "What this monitor's traces keep of prompt, command and tool\ncontent. `dropped` (the default) removes the content attributes\n(prompts, completions, commands, tool arguments, results and\ndefinitions, retrieved documents, working directories) of every\nrecognised vocabulary entirely; lengths such as\n`user_prompt_length`, token counts and cost are kept. Error text\n(`error`, `error.message`, `exception.message`,\n`exception.stacktrace` and the span's status message) is kept at\n`dropped`, redacted and then cut to 512 characters, and a cut\nmarks the span or log event truncated. `redacted`\nopts in to storing that content, with every secret-shaped value\nreplaced by `[REDACTED:<class>]` at ingest, before anything is\nqueued or stored: API keys (LastPing, Anthropic, OpenAI, GitHub,\nGitLab, npm, AWS access key ids, Slack, Stripe, Google, Hugging\nFace, Perplexity, Fireworks, Supabase, New Relic, Airtable,\nTerraform Cloud, Firebase), HashiCorp Vault tokens, age secret\nkeys, Discord bot tokens, Slack, Discord and Teams webhook URLs,\n`Authorization` header values, JWTs, private key blocks,\n`password=`/`token=`/`api_key=` style assignments (subscripted\nones such as `os.environ[\"API_KEY\"] = ...` and Dockerfile\n`ENV`/`ARG` lines included), SQL `PASSWORD '...'` and\n`IDENTIFIED BY` clauses, the Redis `AUTH` command, `.netrc`\npasswords, command-line password flags and the argument after\nthem (any secret-named `--flag`, `-p` after a login subcommand,\n`redis-cli -a`), cookies, credentials in URLs, the value of any\nattribute or JSON field whose name is secret-named (password,\ntoken, api_key, secret, the same word in several other\nlanguages, an `Authorization` or `X-Api-Key` header and the\nlike; `Idempotency-Key` and request, correlation and trace ids\nare not secrets), including JSON carried inside another JSON\nstring such as tool-call arguments, and long high-entropy\ntokens. A bytes attribute that is valid UTF-8 is scanned and\nstored as its text. A span that had a value redacted carries\n`lastping.redacted_values`. A request whose\nredaction work exceeds a fixed budget stores\n`[REDACTED:over_budget]` for the values it could not scan, never\nthe values themselves. In both modes every remaining value is\nredacted the same way. There is no setting that stores content\nunredacted. A change reaches ingest within 60 seconds: ingest\ncaches each monitor's setting for up to a minute, so an export\nsent just after the change may still be handled the old way.\n\nOmitted means `dropped` on create. On a slug upsert an omitted\nvalue leaves the stored setting alone, so an upsert can never undo\na choice made earlier; any other value is rejected with 400\n(`INVALID_TRACE_CONTENT`).\n"
    }
  }
}