---
title: "Register a new Daemon"
method: POST
path: "/api/daemons/register"
tags: ["Daemons", "internal"]
---

# Register a new Daemon

`POST /api/daemons/register`

Internal endpoint for daemon self-registration. Creates a host entry
and sets up default discovery jobs for the daemon.

## Request body

- DaemonRegistrationRequest — Daemon registration request from daemon to server
  - `capabilities` DaemonCapabilities, required — Daemon capabilities
    - `has_docker_socket` boolean
    - `interfaced_subnet_ids` string[], required
  - `credential_ids` string[] — Credential IDs to assign to daemon's host during registration.
  - `daemon_id` string, uuid, required
  - `mode` 'server_poll' | 'daemon_poll', required — Daemon operating mode that determines the communication pattern. - **DaemonPoll** (formerly "Pull"): Daemon makes outbound connections to the server. The daemon registers itself and polls for work. Best for daemons behind NAT/firewall. - **ServerPoll** (formerly "Push"): Server makes connections to the daemon. Server polls daemon for status and discovery results. Best for DMZ deployments where daemon cannot make outbound connections.
  - `name` string, required
  - `network_id` string, uuid, required
  - `url` string, nullable — URL is ignored by server - kept for backwards compat with old daemons. URL is only set via admin provisioning for ServerPoll daemons.
  - `user_id` string, uuid — User responsible for maintaining this daemon (from frontend install command) Optional for backwards compat with old daemons - defaults to nil UUID
  - `version` string, nullable — Daemon software version (optional for backwards compat with old daemons)

## Response `200`

Daemon registered successfully

- ApiResponseDaemonRegistrationResponse
  - `data` object — Daemon registration response from server to daemon
    - `daemon` Daemon, required
      - `api_key_id` string, uuid, nullable — Foreign key to API key used for ServerPoll authentication. NULL for DaemonPoll daemons or those not yet linked to a key.
      - `capabilities` DaemonCapabilities, required — Daemon capabilities
        - `has_docker_socket` boolean
        - `interfaced_subnet_ids` string[], required
      - `host_id` string, uuid, required
      - `is_unreachable` boolean — Whether the daemon is unreachable (for ServerPoll circuit breaker). Set to true after repeated polling failures, reset via retry-connection endpoint.
      - `last_seen` string, date-time, nullable — Timestamp of last successful contact with daemon. NULL for provisioned ServerPoll daemons that haven't been contacted yet.
      - `mode` 'server_poll' | 'daemon_poll', required — Daemon operating mode that determines the communication pattern. - **DaemonPoll** (formerly "Pull"): Daemon makes outbound connections to the server. The daemon registers itself and polls for work. Best for daemons behind NAT/firewall. - **ServerPoll** (formerly "Push"): Server makes connections to the daemon. Server polls daemon for status and discovery results. Best for DMZ deployments where daemon cannot make outbound connections.
      - `name` string, required
      - `network_id` string, uuid, required
      - `standby` boolean — Whether the daemon is on standby due to inactivity (no discovery in 30 days).
      - `standby_cleared_at` string, date-time, nullable — Timestamp of the most recent standby → active transition. Set by `process_startup` when a restarted daemon is un-standby'd, and by the discovery auto-wake path. The nightly inactivity check skips daemons within the grace window (see `STANDBY_GRACE_PERIOD_DAYS`) to prevent the "restart → cleared → re-standby'd before discovery runs" race.
      - `tags` string[], required
      - `url` string, required
      - `user_id` string, uuid, required — User responsible for maintaining this daemon
      - `version` string, nullable — Daemon software version (semver format)
      - `created_at` string, date-time, required
      - `id` string, uuid, required
      - `updated_at` string, date-time, required
    - `host_id` string, uuid, required
    - `server_capabilities` ServerCapabilities — Server capabilities returned on startup/registration
      - `deprecation_warnings` DeprecationWarning[] — Deprecation warnings for the daemon
        - `message` string, required
        - `severity` 'Info' | 'Warning' | 'Critical', required — Severity level for deprecation warnings
        - `sunset_date` string, nullable
      - `minimum_daemon_version` string, required — Minimum daemon version supported by this server
      - `server_version` string, required — Server software version
  - `error` string, nullable
  - `meta` ApiMeta, required — API metadata included in all responses
    - `api_version` integer, required — API version (integer, increments on breaking changes)
    - `server_version` string, required — Server version (semver)
  - `success` boolean, required

## Other responses

- `403` — Daemon registration disabled in demo mode

## Changes

- **2026-04-20** `f04499e2280f` — 1 breaking, 1 warning, 4 info
  - the request property `capabilities` became required
  - removed the request property `integration_targets`
  - added the new optional request property `capabilities/has_docker_socket`
  - added the new optional request property `credential_ids`
  - …2 more

[Change history](https://skmtc.dev/scanopy/apis/scanopy-api/changes/api/daemons/register/post.md)

---

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