Pipedash
Deployment

REST API

Reference for the pipedash-web REST API and WebSocket. Covers auth, the cross-origin check, every route by group and curl examples.

The pipedash-web server exposes every Pipedash operation under /api/v1 and streams events on /api/v1/ws. The web UI calls the same routes. This page lists all of them.

All paths below are relative to /api/v1. Request and response bodies use JSON unless noted otherwise. Some successful actions return no body. Log downloads return plain text. Behind a sub-path proxy, the proxy strips the prefix, so the paths stay the same. The Reverse proxy page covers it.

Authentication

The server holds an API token in memory. At startup it copies the value of PIPEDASH_VAULT_PASSWORD into the token. A successful vault open, a first setup with a vault password and a migration with a token password set it as well. The Token storage page covers the rules.

A protected route accepts the vault API token or a paired-device token:

Authorization: Bearer <vault-password-or-device-token>

A web server with no API token permits anonymous requests. A sharing desktop requires authentication even without a vault API token.

The comparison with the vault token runs in constant time. A missing or wrong header returns status 401 with no body. Locking the vault or a failed open attempt does not change the token, so the rule stays in force.

Routes for the current device's push registration require a device token. Host-managed routes reject a paired device with 409 and HOST_MANAGED.

These paths skip the check:

  • Outside the API: any path that does not start with /api/v1/, such as the embedded frontend.
  • Prefixes: /api/v1/health and /api/v1/setup.
  • Exact paths: /api/v1/vault/status, /api/v1/ws and /api/v1/plugins.
  • Downloads: GET /api/v1/downloads/{ticket}. The single-use ticket replaces the token. Other methods on this path need the header.

Access levels

The Auth column of each table uses these levels:

  • Public: skips the bearer check.
  • Protected: accepts the vault API token or a paired-device token. A web server without an API token permits anonymous requests. A desktop host still requires authentication.
  • Operator: a protected host-managed route. A recognized paired device gets 409 with HOST_MANAGED. Desktop sharing also blocks these routes, except the open status routes.
  • Device: requires a recognized paired-device identity. The vault token gets 403 with DEVICE_ONLY.
  • Patch: protected, with the preference fallback described under Device notification preferences.
  • Ticket: no bearer check. A valid single-use ticket is required.
  • Socket: no HTTP bearer check. Authentication happens in WebSocket frames.

All write methods and WebSocket upgrades also pass the cross-origin check below unless CORS allows all origins. Demo-mode restrictions apply after authentication.

Cross-origin requests

The server rejects a POST, PUT, PATCH or DELETE request that a browser sends from another origin. It also rejects a WebSocket upgrade from another origin. The answer is status 403. This keeps other websites from changing an instance through the browser of a user.

A request with Sec-Fetch-Site is allowed when the value is same-origin or none. A request without that header is allowed when Origin matches Host and the scheme from X-Forwarded-Proto. A request without an Origin header, such as curl or a script, passes. GET, HEAD and OPTIONS requests pass the check.

PIPEDASH_CORS_ALLOW_ALL=true or server.cors_allow_all = true turns the check off and allows any origin, method and header. The Reverse proxy page covers the setup.

Errors

Handled errors return a JSON body with code, message and an optional details.

StatuscodeCause
400BAD_REQUESTInvalid config, provider type or request field
401UNAUTHORIZEDVault authentication failed
403PROVIDER_AUTH_FAILEDThe provider rejected the credentials
403FORBIDDENThe token lacks a permission
404NOT_FOUNDUnknown provider, pipeline, subscription, job or log revision
409CONFLICTSetup already done
404DEVICE_NOT_FOUNDNo paired device has this id
422PUSH_RELAY_NOT_CONFIGUREDThe server has no push relay
422INVALID_SERVER_URLThe server_url of a pairing request is not a valid address
429RATE_LIMITEDThe push relay refused a test notification
429TOO_MANY_DOWNLOADS32 log downloads are already pending
429TOO_MANY_PAIRING_CODES8 pairing codes are already open
409HOST_MANAGEDA paired device tried to change the vault, setup, storage, push or the factory reset of its host
503HOST_LOCKEDA sharing desktop is locked. Devices reconnect after the vault opens
503SERVER_NOT_READYThe server cannot resolve the paired-device identity yet
403DEMO_READ_ONLYA change on a server in demo mode
501NOT_SUPPORTEDThe provider does not support the action
502PUSH_RELAY_ERRORThe push relay did not accept the notification
403DEVICE_ONLYA route that needs a device identity got the vault token instead of a device token
404ALERT_NOT_FOUNDThe alert expired or never existed
409PUSH_NOT_REGISTEREDA test push came from a device with no push registration
409PUSH_RELAY_FROM_ENVPIPEDASH_PUSH_RELAY_URL sets the relay, so the switch can't change it
410PUSH_SUBSCRIPTION_GONEThe relay no longer knows the device. Pipedash deleted its registration
422INVALID_SUBSCRIPTIONThe subscription_id is empty, longer than 128 characters or has other characters than letters, digits, - and _
503NOT_INITIALIZEDSetup is still required
500INTERNAL_ERRORAny other failure

A 401 from the auth check has no body. A 403 from the cross-origin check has no body either.

Health and setup

The health and setup routes skip authentication.

MethodPathAuthPurpose
GET/healthPublicServer status, version and provider count
GET/setup/statusPublicConfig and setup state
POST/setup/draftPublicValidates a first-setup draft and returns the proposed config
POST/setup/applyPublicSaves first setup and starts services

GET /health answers 503 with status set to database_error when the provider query fails. The Docker page lists the other states.

Both POST routes take the same body:

{
  "backend": "sqlite",
  "data_dir": "/data",
  "postgres_url": "",
  "vault_password": "<vault-password>",
  "vault_password_confirm": "<vault-password>",
  "transfer_data": true
}

All six fields are required. backend accepts sqlite, postgres or postgresql. A PostgreSQL backend needs a valid postgres:// or postgresql:// URL.

Without PIPEDASH_VAULT_PASSWORD, server setup requires a matching vault password and confirmation, with at least 8 characters.

The draft response holds config, errors, password_warnings and needs_migration. The apply response holds saved, migration_stats and restart_required.

Both routes return 409 once setup is complete. They skip bearer authentication, so this guard also applies without a token.

Providers

All routes in this group are protected.

MethodPathAuthPurpose
GET/providersProtectedLists providers
GET/providers/exportProtectedExports providers as TOML text without tokens
POST/providers/importProtectedImports providers from TOML text
GET/providers/{id}ProtectedReads a provider for editing
DELETE/providers/{id}ProtectedDeletes a provider
POST/providers/{id}/refreshProtectedRefreshes the pipelines of one provider now
PUT/providers/{id}/refresh-intervalProtectedChanges the stored refresh interval
GET/providers/{id}/table-schemaProtectedReads the table schema
POST/providers/{id}/sign-inProtectedStarts sign-in for a saved provider
POST/providers/{id}/sign-in/completeProtectedSaves a completed sign-in for that provider
POST/providers/organizationsProtectedDiscovers organizations
POST/providers/permissions/checkProtectedChecks supplied credentials and feature availability
POST/providers/previewProtectedPreviews discoverable pipelines
POST/providers/preview/idsProtectedLists matching pipeline IDs
POST/providers/field-optionsProtectedLoads dynamic config choices
POST/providers/draft/validateProtectedValidates a provider draft
POST/providers/draftProtectedCreates or updates a provider from a draft

The draft routes take provider_type, name, auth_mode, values, optional selected_pipeline_ids and optional provider_id. auth_mode is none, token, sign_in or kubeconfig. A mode that the provider does not offer gets the error "Choose one of this provider's connection methods" under the auth_mode key. values maps config keys to strings.

Omit provider_id, or set it to null, to create a provider. Set it to a saved provider ID to update one. The save response is the numeric provider ID.

The validation response holds errors, active_field_keys, missing_field_labels, credentials_complete, selection_required and selection_needs_refresh.

curl -X POST http://localhost:8080/api/v1/providers/draft \
  -H "Authorization: Bearer <vault-password>" \
  -H "Content-Type: application/json" \
  -d '{
    "provider_type": "github",
    "name": "GitHub OSS",
    "auth_mode": "token",
    "values": {
      "token": "<github-token>",
      "base_url": "https://github.com"
    },
    "selected_pipeline_ids": ["hcavarsan/pipedash"],
    "provider_id": null
  }'

POST /providers/{id}/sign-in takes no body. POST /providers/{id}/sign-in/complete takes { "flow_id": "<completed-flow-id>" }.

Organization discovery and permission checks take provider_type and config. Preview also takes optional org, search, page and page_size. Matching IDs takes provider_type, optional config, organization and search. Field options takes provider_type, field_key and optional config. Each provider page lists its config keys.

PUT /providers/{id}/refresh-interval takes { "refresh_interval": 30 } and answers 400 for a value below 5.

GET /providers/export returns the TOML text as a JSON string. POST /providers/import takes { "content": "<toml>" } and returns { "added": [], "skipped": [] }. The Import and export page covers both.

Pipelines

All routes in this group are protected.

MethodPathAuthPurpose
GET/pipelines/cachedProtectedLists pipelines from the cache
GET/pipelines/cctray.xmlProtectedEvery cached pipeline as a CCTray XML feed for build monitors
POST/pipelines/cancellation-targetsProtectedFinds cancellable runs for selected pipelines
POST/pipelines/cancel-runsProtectedCancels a batch of runs
POST/pipelines/{id}/runs/queryProtectedQueries run history with filters and sorting
GET/pipelines/{id}/runs/{run_number}ProtectedOne run in detail
POST/pipelines/{id}/triggerProtectedStarts a run
POST/pipelines/{id}/trigger/prepareProtectedPrepares trigger parameters, values and validation
POST/pipelines/{id}/runs/{run_number}/cancelProtectedCancels a run
POST/pipelines/{id}/runs/{run_number}/force-cancelProtectedForce cancels a GitHub run after normal cancellation fails to stop it
POST/pipelines/{id}/runs/{run_number}/reviewProtectedApproves or rejects a run that waits for a review
POST/pipelines/{id}/runs/{run_number}/rerunProtectedReruns a run
POST/pipelines/{id}/runs/{run_number}/rerun-failed-jobsProtectedReruns only the failed jobs of a run
POST/pipelines/{id}/runs/{run_number}/jobs/{job_id}/rerunProtectedReruns one job of a run. A job_id that is not a job of that run gets 404.
POST/pipelines/{id}/enableProtectedEnables a disabled GitHub workflow without starting a run

GET /pipelines/cached takes optional provider_id in the query.

POST /pipelines/{id}/runs/query takes a JSON object. Its fields are page (default 1), page_size (default 20), search, statuses (default []), branch, actor, date_range, utc_offset_minutes (default 0), sort_column (default run_number), direction (default desc) and scan_depth (default 1).

The history response holds runs, total_count, has_more, can_scan_deeper, is_complete, scan_notice, page, page_size, total_pages, branches and actors.

POST /pipelines/{id}/trigger takes workflow_id (required) and inputs (optional JSON). The server reads the target from workflow_id and ignores the {id} in the path, so the pipeline ID goes in both places. The response is a TriggerResult with run_id (string or null) and run_number (integer or null).

curl -X POST "http://localhost:8080/api/v1/pipelines/<pipeline-id>/trigger" \
  -H "Authorization: Bearer <vault-password>" \
  -H "Content-Type: application/json" \
  -d '{ "workflow_id": "<pipeline-id>", "inputs": { "ref": "main" } }'
{ "run_id": "<run-id>", "run_number": 42 }

Both fields can be null. run_id is a string and run_number is an integer. A provider that cannot report the new run at once returns null.

POST /pipelines/{id}/trigger/prepare takes {} or an object with optional rerun_of and inputs. rerun_of is a run number. inputs is an object. The response holds parameters, values, fields, errors, availability and copy.

POST /pipelines/cancellation-targets takes { "pipeline_ids": ["<pipeline-id>"] }. It returns groups, batches, failed_pipeline_ids, skipped and run_count. batches holds the same runs as groups as lists of { "pipeline_id", "run_number" } targets, at most 1000 per list.

POST /pipelines/cancel-runs takes { "targets": [{ "pipeline_id": "<pipeline-id>", "run_number": 42 }] }. It returns results, requested_count and failed_count. More than 1000 targets returns an error with the message "Cancel at most 1000 runs at a time". Send each list from batches as its own request.

POST .../review takes { "decision": "approve" } or { "decision": "reject" }. Trigger preparation returns the parameters and current values for the trigger form. The trigger and cancel page covers the UI flow.

POST .../force-cancel takes no body and targets one GitHub run. GitHub bypasses conditions such as always(). It needs the same permissions as normal cancellation. The Force cancel guide covers when to use it.

POST /pipelines/{id}/enable takes no body and turns a disabled GitHub workflow's triggers back on. The GitHub Actions guide covers the Disabled label and its reasons.

Build monitor feed

GET /pipelines/cctray.xml returns every cached pipeline in the CCTray format, the cc.xml feed that build monitors such as CCMenu and Nevergreen read. The answer has the content type application/xml, with one <Project> per pipeline inside <Projects>. The feed reads the cache and does not call the providers.

AttributeValue
name<repository> · <pipeline>, or the pipeline name when it has no repository. When two pipelines get the same name, each one adds · and its workflow file, or its pipeline ID when it has none.
activityBuilding while the pipeline is running, or pending with a previous run. Sleeping otherwise.
lastBuildStatusSuccess for success. Failure for failed and degraded. Unknown for running, pending, cancelled and skipped.
lastBuildTimeThe time of the last run in RFC 3339, or the time of the last update when the pipeline has never run.
webUrlThe pipeline page in Pipedash, <scheme>://<host><base path>/pipelines/<pipeline-id>.

The server builds webUrl from the Host header of the request and the first value of X-Forwarded-Proto, with http when that header is missing. It keeps the base path of the web UI. Behind a proxy that passes both headers, as the Forwarded headers section asks, the links point at the public address.

The route follows the same bearer rule as the other protected routes. On a server with an API token, a request without the header gets 401. In the build monitor, add the feed URL https://<host>/api/v1/pipelines/cctray.xml and set the header Authorization: Bearer <token> with the vault password or a paired device token.

curl "http://localhost:8080/api/v1/pipelines/cctray.xml" \
  -H "Authorization: Bearer <vault-password>"
<?xml version="1.0" encoding="UTF-8"?>
<Projects>
  <Project name="acme/api · CI" activity="Sleeping" lastBuildStatus="Success" lastBuildTime="2026-11-16T21:04:12+00:00" webUrl="http://localhost:8080/pipelines/<pipeline-id>"/>
</Projects>

Run logs

These routes serve the Run logs viewer. They exist for providers with the logs capability, which every built-in provider declares. A plugin without it answers 501 with NOT_SUPPORTED. The server compresses the answers of the /logs routes with gzip when the client accepts it.

MethodPathAuthPurpose
GET/pipelines/{id}/runs/{run_number}/logsProtectedJobs and steps of the run
GET/pipelines/{id}/runs/{run_number}/logs/{node_id}ProtectedOpens a job log and starts its download when needed
GET/pipelines/{id}/runs/{run_number}/logs/{node_id}/linesProtectedA page of lines
POST/pipelines/{id}/runs/{run_number}/logs/{node_id}/searchProtectedSearches the whole log
POST/pipelines/{id}/runs/{run_number}/logs/{node_id}/download-ticketProtectedCreates a download link
GET/downloads/{ticket}TicketStreams the log as a text file
  • Jobs: the response holds nodes, default_node_id, complete, groups and step_ids_by_node. Each group has stage, node_ids and failed_first_node_ids. step_ids_by_node maps a node id to the ids of its steps. Each node has an id, a parent_id, a kind (stage, job or step), a name and a status. Its log value is ready, partial, pending or null. It also has started_at, finished_at, duration_seconds, web_url, depth and navigable when they apply.
  • Open: returns { "state": "ready", ... } with the line count, styles, sections and error lines, or loading with received_bytes, pending, or unavailable with a message. A ready answer for a log that is still running holds complete: false, updated_at_ms, stable_lines and previous_revision. Lines below stable_lines stay the same in the next revision. ?retry=true skips the 5 minute wait after a failed download.
  • Events: the run-log-progress event reports a download. run-log-ready fires for each new revision of a running log, with the revision, and run-log-failed reports a failure. run-log-tree-changed (pipelineId, runNumber) says the job list or the state of a job changed. run-updated (pipelineId, runNumber, run) carries the changed run, at most every 5 seconds. The server sends the last two only while a client has the log or the job list of that run open. Opening them renews the watch for 45 seconds.
  • Lines: takes revision, start, count (up to 2000) and max_line_units. Each line has text, and kind, ts, spans and omitted when they apply. A revision that no longer exists returns 404.
  • Search: takes revision and session in the query and { "text": "...", "regex": false, "case_sensitive": false } as the body. A newer search with the same session cancels the older one. The response holds matches as [line, start, end], total and capped. An invalid pattern returns 400.
  • Download: the ticket route takes { "revision": 1, "file_name": "build.log" } and returns { "ticket": "..." }. The ticket works once and expires after 60 seconds. The download sends Cache-Control: no-store and Referrer-Policy: no-referrer. Server logs replace the ticket with [redacted].

Pipeline views

The routes behind Views, pins and hidden pipelines. The {id} of a view is a number, all, pinned or config:<key>, URL-encoded. All routes are protected.

MethodPathAuthPurpose
GET/pipeline-viewsProtectedLists the views
POST/pipeline-viewsProtectedCreates a custom view. Answers 201.
GET/pipeline-views/pageProtectedBuilds the page of a view
PUT/pipeline-views/orderProtectedSets the order of the movable views
PUT/pipeline-views/hiddenProtectedHides or shows a pipeline
GET/pipeline-views/pinsProtectedLists the pins of views and repositories
PUT/pipeline-views/pinsProtectedPins or unpins a view or a repository
GET/pipeline-views/menuProtectedPipeline-menu snapshot
POST/pipeline-views/selectionProtectedView membership summary for selected pipelines
GET/pipeline-views/editor-optionsProtectedEligible parents and sub-view availability
GET/pipeline-views/navigationProtectedViews, pins and providers for navigation
POST/pipeline-views/legacy-importProtectedImports the pins and hidden pipelines that older versions kept in the browser
PUT/pipeline-views/{id}ProtectedUpdates a custom view
DELETE/pipeline-views/{id}ProtectedDeletes a custom view
GET/pipeline-views/{id}/membersProtectedLists the pipelines added by hand
PUT/pipeline-views/{id}/membershipProtectedAdds or removes a pipeline
PUT/pipeline-views/{id}/membershipsProtectedChanges membership for several pipelines
  • Create and update: the body takes name, rules, display, members (pipeline ids) and parent (a view id, or null for the top level). The rules fields are provider_ids, repositories, name_contains and statuses. The display fields are sort, direction, sections and layout. An update leaves out the fields it keeps. A request for a config view returns 400 with "Views from config.toml can't be changed here. Edit config.toml instead."
  • Page: the query takes view (default all), provider_id, search, statuses, organization, date_range (today, 24h, 7d, 30d, 60d or 90d), show_hidden and utc_offset_minutes. statuses is a comma list such as running,pending, and an unknown status returns 400. An unknown view returns 404. The response holds view, pinned, pinned_blocks, sections, total, hidden_count, filters_active, section_count, facets and presentation.
  • Order: PUT /pipeline-views/order takes { "order": ["pinned", 1] }.
  • Hidden: PUT /pipeline-views/hidden takes pipeline_id and hidden.
  • Pins: the body takes kind (view or repository), ref and pinned. A pipeline pin is a membership of the pinned view.
  • Legacy import: POST /pipeline-views/legacy-import takes optional pinned and hidden pipeline-ID lists.
  • Menu: no body or query. The response holds pipelines and shortcuts.
  • Selection: POST /pipeline-views/selection takes { "pipeline_ids": ["<pipeline-id>"] }. Each result holds view, depth, selected_count, direct_count, included_by_rule and included_by_sub_view.
  • Editor options: optional query field view. The response holds eligible_parents and can_add_sub_view.
  • Navigation: optional query field search. The response holds views, pins, providers and total_pipelines.
  • Membership: the body takes pipeline_id and member.
  • Batch membership: PUT .../memberships takes pipeline_ids and member. It returns the updated selection entries.
  • Event: every change sends pipeline-views-changed over the WebSocket.

Provider sign-in

Providers with single sign-on, such as ArgoCD, use these routes. They are protected.

MethodPathAuthPurpose
POST/sign-inProtectedStarts a sign-in from provider_type and config
GET/sign-in/{id}ProtectedReads the state of a sign-in
POST/sign-in/{id}/completeProtectedFinishes it with the redirect_url of the page after the sign-in
DELETE/sign-in/{id}ProtectedCancels it

On the web server the browser can be on another machine, so the start response asks for manual completion. The user pastes the address of the page after sign-in. The ArgoCD page covers the flow.

Plugins

MethodPathAuthPurpose
GET/pluginsPublicFull plugin metadata, without authentication

Each plugin includes its config schema, table schema, capabilities, permissions, features, run-history policy, token prefixes and presentation data.

Cache

All routes in this group are protected.

MethodPathAuthPurpose
GET/cache/statsProtectedCache statistics
DELETE/cache/run-historyProtectedClears all history caches
DELETE/cache/pipelinesProtectedClears the pipeline cache
DELETE/cache/workflow-paramsProtectedClears the parameter cache
DELETE/cache/run-logsProtectedClears the run log cache
DELETE/cacheProtectedClears every cache

Metrics

All routes in this group are protected.

MethodPathAuthPurpose
GET/metrics/configProtectedReads the global metrics config
PUT/metrics/configProtectedUpdates it
GET/metrics/pipelines/{id}/configProtectedReads a pipeline metrics config
PUT/metrics/pipelines/{id}/configProtectedUpdates it
POST/metrics/dashboardProtectedQueries metrics, statistics and table ordering
GET/metrics/storage/statsProtectedMetric storage statistics
POST/metrics/flushProtectedDeletes metrics

PUT /metrics/config takes enabled and default_retention_days. The pipeline route takes enabled and retention_days. POST /metrics/flush takes an optional pipeline_id. The metrics page covers it.

POST /metrics/dashboard requires metric_type, aggregation_period and date_range. It also takes optional pipeline_id, aggregation_type, utc_offset_minutes (default 0), limit and table_sort.

metric_type is run_duration, success_rate or run_frequency. aggregation_period is hourly, daily, weekly or monthly. aggregation_type is avg, sum, min, max, p95 or p99.

date_range is today, 24h, 7d, 30d, 60d or 90d. table_sort holds field (timestamp, value, count, min or max) and direction (asc or desc).

The response holds data, observed, stats, table_indices, ranges, widest_range and aggregation_type.

Notification center

MethodPathAuthPurpose
POST/notifications/centerProtectedApplies a change to a supplied notification-center snapshot

The route takes snapshot and change and returns the updated snapshot.

snapshot holds revision, items and optional unread. It accepts at most 50 items. The server recalculates unread.

change.type is push, insert_missed, read or clear. push and insert_missed include notice. read includes key, or null to mark every item read.

{
  "snapshot": { "revision": 0, "items": [], "unread": 0 },
  "change": { "type": "clear" }
}

Preferences

All routes in this group are protected.

MethodPathAuthPurpose
GET/preferences/table/{provider_id}/{table_id}ProtectedReads table preferences
PUT/preferences/table/{provider_id}/{table_id}ProtectedSaves table preferences
GET/preferences/table/{provider_id}/{table_id}/defaultProtectedReads the defaults

PUT /preferences/table/{provider_id}/{table_id} takes { "preferences_json": "<serialized JSON>" }. The GET route returns the saved JSON string, or null when none is saved.

Refresh

MethodPathAuthPurpose
POST/refresh/allProtectedRefreshes all providers now and returns one result per provider

Each result holds provider_id, state, kind and message. The refresh page covers polling and intervals.

Settings

MethodPathAuthPurpose
PUT/settings/generalProtectedSaves the [general] settings

The body holds metrics_enabled, default_refresh_interval, status_pages_enabled and proxy_url. The route answers 204. It answers 400 when default_refresh_interval lies outside 5 to 300 or when proxy_url is not an http:// or https:// URL without credentials. A new proxy applies at once.

Storage

All routes in this group are host-managed. A paired device gets 409 with HOST_MANAGED.

MethodPathAuthPurpose
POST/storage/draftOperatorValidates a storage draft
POST/storage/applyOperatorApplies the draft and reloads storage
GET/storage/configOperatorReads the storage config and summary
GET/storage/config/contentOperatorReads the TOML text
PUT/storage/config/contentOperatorSaves TOML and applies provider blocks
POST/storage/config/analyzeOperatorAnalyzes proposed TOML
GET/storage/pathsOperatorEffective file paths
GET/storage/default-data-dirOperatorDefault data directory
POST/storage/test-connectionOperatorTests the supplied config
GET/storage/vault-password-statusOperatorReports whether the password variable is set
POST/storage/migration/executeOperatorExecutes a supplied migration plan

The draft and apply routes take the same six fields as the setup draft: backend, data_dir, postgres_url, vault_password, vault_password_confirm and transfer_data.

Draft returns config, errors, password_warnings and needs_migration. Apply returns saved, migration_stats and restart_required. A successful web-server apply reloads storage and sets restart_required to false.

PUT /storage/config/content takes { "content": "<toml>" }. Analyze takes { "new_content": "<toml>" }.

Test connection takes a complete Pipedash config object. Migration execute takes plan and options. A successful migration reloads storage. If that reload fails, the server logs that a manual restart is required. The storage backends page covers what a migration moves.

Vault

GET /vault/status skips authentication. The two other routes are host-managed and need the bearer token whenever the server holds one.

MethodPathAuthPurpose
GET/vault/statusPublicLock state and password source
POST/vault/unlockOperatorOpens the vault with a password
POST/vault/lockOperatorCloses the session

GET /vault/status returns is_unlocked, password_source (env_var, session or none), backend, requires_password and is_first_time. In demo mode it adds demo_password, the password for the sign-in screen.

POST /vault/unlock takes password and returns success and message.

curl -X POST http://localhost:8080/api/v1/vault/unlock \
  -H "Authorization: Bearer <vault-password>" \
  -H "Content-Type: application/json" \
  -d '{ "password": "<vault-password>" }'
{ "success": true, "message": "Vault unlocked successfully" }

A failed attempt still returns status 200, with "success": false. The message is Incorrect vault password for a wrong password, or Invalid password or storage error: ... for another storage failure. If the vault is already open, the message is Vault is already unlocked.

A successful call sets PIPEDASH_VAULT_PASSWORD in the server process and sets the API token to that password. POST /vault/lock returns Vault locked, deletes the variable, shuts down the core and clears pending download tickets. It keeps the API token, so protected routes still need the bearer token. A restart is not needed.

Alerts

A host records alerts for pipeline failures, degraded pipelines, long runs, provider outages and provider recoveries. It records alerts only while at least one device is paired. Phones read them in the background and from the push notification service extension. Both the vault token and a device token can call these routes.

MethodPathAuthPurpose
GET/alertsProtectedLists alerts after a sequence number
GET/alerts/{id}ProtectedReads one alert

GET /alerts takes after (default 0) and limit (default 50, clamped to 1 to 100). It returns the alerts in ascending seq order and the newest sequence number, which counts alerts of every kind. Test alerts are not in the list.

A device token returns only alerts allowed by that device's saved notification preferences. The vault token returns the unfiltered list. latest_seq still counts all recorded alerts, including alerts filtered out for that device.

GET /alerts/{id} reads an alert directly and does not apply the list filter.

{
  "alerts": [
    {
      "id": "0f3a9c2e8b7d4a61b5c0d9e8f7a6b5c4",
      "seq": 42,
      "key": "pipeline:github__1__hcavarsan/pipedash/ci.yml",
      "kind": "failed",
      "tone": "danger",
      "title": "ci.yml failed",
      "body": "hcavarsan/pipedash · GitHub",
      "pipeline_id": "github__1__hcavarsan/pipedash/ci.yml",
      "provider_id": 1,
      "created_at": "2026-11-04T09:30:00Z"
    }
  ],
  "latest_seq": 42
}
  • kind: failed, degraded, long_run, outage, recovered, finished or test.
  • tone: danger for failed and degraded, warning for long_run and outage, and success for recovered, finished and test. The host supplies the tone.
  • key: the same key the in-app notification list uses, so a newer alert replaces an older one with the same key.
  • Retention: the host keeps alerts for 7 days and at most 500. A factory reset deletes them.
  • GET /alerts/{id}: returns one alert, including a test alert. It answers 404 with ALERT_NOT_FOUND once the alert is gone.
  • Event: each new alert sends alert-recorded (id, seq) over the WebSocket.

Push relay

Both routes are host-managed.

MethodPathAuthPurpose
GET/push/relayOperatorReads the relay switch of the server
PUT/push/relayOperatorTurns it on or off

Both answer { "enabled": true, "relay_url": "https://relay.pipedash.app", "from_env": false, "official_url": "https://relay.pipedash.app" }. enabled says the server has a relay URL. from_env is true while a non-empty PIPEDASH_PUSH_RELAY_URL sets it. PUT takes { "enabled": true }, writes or removes push.relay_url in config.toml, and answers 409 with PUSH_RELAY_FROM_ENV while from_env is true. A paired device gets 409 with HOST_MANAGED. Demo mode permits GET and refuses PUT.

This is the "Background notifications" switch in Settings, Notifications on the web UI. It starts off on a new web server and on a computer that never shared. A computer that was already sharing before the upgrade keeps push on once, and later choices stick. A non-empty PIPEDASH_PUSH_RELAY_URL overrides push.relay_url and disables the switch ("Set by PIPEDASH_PUSH_RELAY_URL."). A blank value selects no relay and leaves the switch enabled.

Push registration of a device

These routes belong to the paired device that calls them. They answer 403 with DEVICE_ONLY for the vault token. A server with no relay URL answers 422 with PUSH_RELAY_NOT_CONFIGURED to PUT and to the test route.

MethodPathAuthPurpose
GET/devices/current/pushDeviceReads the relay URL and whether this device has a registration
PUT/devices/current/pushDeviceRegisters the relay subscription of this device. Answers 204.
DELETE/devices/current/pushDeviceRemoves the registration. Answers 204, also when none exists.
POST/devices/current/push/testDeviceRecords a test alert and pushes it to this device. Answers 202.
POST/devices/current/push/ackDeviceConfirms that the device showed the alerts it missed. Answers 204.

GET returns { "relay_url": "https://relay.pipedash.app", "enabled": true, "undelivered_after": null }, with relay_url set to null when the host has no relay. PUT takes { "subscription_id": "<id from the relay>" }. The test route has these errors:

  • 409 with PUSH_NOT_REGISTERED before a PUT.
  • 410 with PUSH_SUBSCRIPTION_GONE when the relay no longer knows the device.
  • 429 with RATE_LIMITED and 502 with PUSH_RELAY_ERROR.

For each alert, the host sends the relay POST /v1/notifications with { "subscription_id": "...", "alert_id": "..." } and nothing else. The relay answers Apple with a generic text, and the app fetches the real text from GET /alerts/{id}. The Security page covers the trust model.

When the relay fails or rate-limits a push, the host remembers the first and the last alert it could not push to that device. undelivered_after is then the seq immediately before the first one. The device fetches GET /alerts?after=<undelivered_after> in its next background check, shows up to 20 alerts, and sends POST /devices/current/push/ack with { "through": <last seq shown> }. The host clears the marker once the ack covers the last failed alert. Otherwise undelivered_after moves to the acked seq, and the next background check continues from there.

Device notification preferences

A paired device saves its alert choices on the host. GET and PUT require the device token. The vault token returns 403 with DEVICE_ONLY. PATCH also supports a supplied preference object for callers without a device identity.

MethodPathAuthPurpose
GET/devices/current/notification-preferencesDeviceReturns { "preferences": null } before the device saves choices, or its saved preference object
PUT/devices/current/notification-preferencesDeviceSaves the preference object and returns { "fired": [...] } with one-time watches that already fired
PATCH/devices/current/notification-preferencesPatchApplies one preference change and returns preferences and pipeline states

PUT takes the preference object directly:

{
  "failed": true,
  "degraded": true,
  "long_run": true,
  "outage": true,
  "recovered": true,
  "muted_providers": [],
  "muted_pipelines": [],
  "watched_pipelines": [],
  "watch_once": []
}

Provider lists contain numeric IDs. Pipeline lists contain pipeline ID strings. A watch_once entry holds pipeline_id, since and an optional fired_at, with RFC 3339 timestamps. Saving preserves a stored fired_at for the same request. The Notifications page explains mute and watch precedence.

PATCH takes a tagged change:

{ "type": "pipeline_muted", "pipeline_id": "<pipeline-id>", "muted": true }

Its change types are kind, provider_muted, pipeline_muted, pipeline_watched, watch_next_finish and cancel_next_finish.

  • kind takes kind and enabled.
  • provider_muted takes provider_id and muted.
  • pipeline_muted takes pipeline_id and muted.
  • pipeline_watched takes pipeline_id and watched.
  • watch_next_finish and cancel_next_finish take pipeline_id.

For a paired device, the server saves the change. Without a device identity, include preferences in the same body. The server changes that supplied object without saving it for a device. A caller with neither gets 403 with DEVICE_ONLY.

The response holds preferences and pipeline_states. A pipeline state is muted, watching, pending or default.

Push subscriptions

These host-managed routes list, remove and test push subscriptions saved by older app versions. New subscriptions use the current-device registration routes. The server no longer registers an older subscription through POST /push/subscriptions.

MethodPathAuthPurpose
GET/push/subscriptionsOperatorLists subscriptions and reports relay_configured
DELETE/push/subscriptions/{id}OperatorDeletes a device. Answers 204.
POST/push/subscriptions/{id}/testOperatorSends a test notification. Answers 202.

Devices

These routes pair other Pipedash apps with this server or desktop host. They need the bearer token like the rest. The Mobile and Desktop app pages cover the UI.

MethodPathAuthPurpose
GET/devicesProtectedLists the paired devices
POST/devices/pairingProtectedCreates a single-use pairing code
DELETE/devices/{id}ProtectedRemoves a device. Answers 204.

GET /devices returns { "devices": [...] }. Each device holds id, name, platform, created_at, last_seen_at, current, removable and push. current is true for the device that asks. removable says whether the caller may remove that device. push is true when the device has a push registration.

POST /devices/pairing takes { "server_url": "<address the new device reaches>" }. It answers 422 with INVALID_SERVER_URL for a bad address and 429 with TOO_MANY_PAIRING_CODES while 8 codes are open.

{
  "code": "ABCD-EFGH",
  "link": "pipedash://pair?url=...&code=...",
  "server_url": "http://192.168.1.20:8080",
  "expires_at": "...",
  "loopback": false,
  "qr_svg": "<svg>...</svg>"
}

The code works once and expires after 5 minutes. loopback says whether the address only works on the host itself. DELETE /devices/{id} answers 404 with DEVICE_NOT_FOUND for an unknown id. The host closes the connection of a removed device at once.

In demo mode, creating a pairing code is allowed and the server stores a device under a generic name such as "Demo iPhone or iPad". A paired device can remove only its own entry and change only its own push registration and notification preferences, and every device has removable set to false.

System

MethodPathAuthPurpose
POST/factory-resetOperatorDeletes all providers, caches, tokens, views, pins, metrics, recorded alerts, push registrations and paired devices

Providers that config.toml defines leave the file too. The reset also deletes all custom views, their members and pins. The response holds providers_removed, caches_cleared, tokens_cleared and metrics_cleared.

WebSocket

MethodPathAuthPurpose
GET/wsSocketUpgrades to the event and request socket

Live events stream on /api/v1/ws. A cross-origin upgrade gets 403 unless CORS allows all origins. When the server holds an API token, the first message from the client must be:

{ "type": "auth", "token": "<vault-password>" }

Before authentication, the socket accepts only an auth frame or a claim frame (a pairing code, see below). The server closes the socket on any other first frame, on invalid JSON, or on invalid credentials. On success the server answers with an auth-ok frame. Without a token there is no handshake. After that, every event arrives as a text frame with this envelope:

{ "type": "pipeline-status-changed", "payload": {} }

type is the event name and payload is the event data. After the handshake, the server accepts request and notification-preferences frames. It also accepts later auth or claim frames. Unrecognized text frames after authentication are ignored.

The server keeps a buffer of 1024 events per socket. A client that falls behind the buffer gets a close frame, so it can reconnect and load the current state again. The event names are:

GroupEvents
Providersproviders-changed, provider-added, provider-updated, provider-removed, provider-status-updated, provider-health-alert
Pipelinespipelines-updated, pipeline-status-changed, pipelines-failed
Runsrun-triggered, run-cancelled, run-log-progress, run-log-ready, run-log-failed, run-log-tree-changed, run-updated
Viewspipeline-views-changed
Metricsmetrics-generated, metrics-global-config-changed, metrics-config-changed, metrics-flushed
Migrationmigration-progress, migration-complete
Cachepipeline-cache-invalidated, run-history-cache-invalidated
Vaultvault-unlocked, vault-locked
Devicesdevice-paired (id, name), device-revoked (id)
Alertsalert-recorded (id, seq)
Notificationsnotification

Notification preferences and replay

A browser or operator client can send its notification preferences for this socket:

{
  "type": "notification-preferences",
  "preferences": { "muted_pipelines": ["<pipeline-id>"] },
  "after": 42
}

after is optional. It asks the server to replay retained observed notifications after that ID. The server applies the supplied preferences and avoids sending the same notification twice on that connection.

Admitted notifications arrive as { "type": "notification", "payload": { ... } }. The payload holds the shown notification, including its ID and tone.

A paired-device connection ignores this preference frame. It uses the preferences saved for that device instead.

Device connection

A paired app uses this socket for everything. It follows a different handshake than the vault token above. Native apps send no Origin header. A sharing desktop rejects cross-origin browser requests.

The client sends one of these as its first frame within 10 seconds. auth carries the token of a paired device. claim trades a pairing code for a new token.

{ "type": "auth", "token": "<device-token>" }
{ "type": "claim", "code": "ABCD-EFGH", "name": "My iPhone", "platform": "ios" }

The server answers auth-ok with host (server or desktop), name and deviceId. After a claim it also sends token, which the client stores. Otherwise the server sends auth-error with a code and a message, then closes the socket.

codeMeaning
AUTH_FAILEDUnknown or wrong token
DEVICE_REMOVEDThe host removed this device
PAIRING_CODE_INVALIDThe code is wrong, used or expired
INVALID_DEVICE_NAMEThe trimmed device name is not 1 to 100 characters
INVALID_PLATFORMPlatform is not macos, windows, linux, ios or android
PAIRING_FAILEDThe server could not save the pairing
HOST_LOCKEDThe host is locked
SERVER_NOT_READYThe host has not finished starting
AUTH_TIMEOUTNo first frame arrived within 10 seconds

After auth-ok, the client sends API calls as request frames and the server answers each with a response frame that has the same id.

{ "type": "request", "id": 1, "method": "GET", "path": "/pipelines/cached" }
{ "type": "response", "id": 1, "status": 200, "body": "[]" }

A request may carry a body. A response carries body, or bodyBase64 for binary data, up to 64 MiB. The host runs 16 requests at once and accepts 64. Extra requests get status 429.