Skip to content

Applications and configuration API Since v0.1 ​

These routes read and change the versioned configuration. Changes create a new version; the body of a change carries base_version, and a stale value is refused with 409. For the keys, see Configuration file.

For the base URL, sign-in, roles and error format, see Management API. Except sign-in, a route answers 401 without credentials and 403 when the role is too low.

Routes ​

Configuration versions ​

MethodPathMinimum roleWhat it doesMain fields
GET/v1/config/versionsviewer, all applicationsLists stored versions (query limit) and their activations.Response: versions, activations.
GET/v1/config/versions/{n}viewer, all applicationsReturns one version with its YAML document.Response: version fields and document.
GET/v1/config/diffviewer, all applicationsShows the changes between two versions (query from, to).Response: changes.
POST/v1/config/applyoperatorValidates a whole document and activates it as a new version.Body: document, comment, source (apply, import, except), base_version, dry_run. Callers limited to some applications may change only those.
POST/v1/config/rollbackoperator, all applicationsActivates an earlier version as a new version.Body: number, comment.
GET/v1/config/exportadmin, all applicationsExports the configuration of this node for another node.none
POST/v1/config/pulladmin, all applicationsPulls applications from another node's management API.Body: from, token, fingerprint, apps, comment, dry_run.
GET/v1/overview Since v0.2viewerReturns the dashboard overview: applications, modes and counts.none
GET/v1/warnings Since v0.2viewerLists configuration warnings.none

Applications ​

MethodPathMinimum roleWhat it doesMain fields
GET/v1/appsviewerLists applications in the caller's scope.none
GET/v1/apps/{name}viewerReturns one application's YAML section and base_version.none
PUT/v1/apps/{name}operatorReplaces one application's YAML section.Body: document, base_version (required), comment, dry_run.
POST/v1/appsoperator, all applicationsCreates an application, with an optional certificate.Body: name, settings, copy_from, certificate (cert, key), base_version, comment, dry_run.
DELETE/v1/apps/{name}operator, all applicationsRemoves an application.Query: base_version (required).
GET/v1/apps/{name}/settingsviewerReturns the application's core settings as form fields.none
PUT/v1/apps/{name}/settingsoperatorChanges the application's core settings.Body: set (key to value; empty string resets the key), base_version (required), comment, dry_run.
PUT/v1/apps/{name}/certificateoperatorUploads or removes the application's TLS certificate and key (PEM).Body: cert, key, base_version, comment, dry_run.
PUT/v1/apps/{name}/upstream-caoperatorSets the CA certificate that verifies the application's upstream servers.Body: ca (PEM), base_version, comment, dry_run.
POST/v1/certificates/checkoperatorChecks a certificate and key pair without saving it.Body: cert, key, hostnames. Response: ok, problems.
GET/v1/apps/{name}/picture Since v0.2viewerReturns the application's one-page summary (listeners, pool, modules).none
GET/v1/apps/{name}/path Since v0.2viewerReturns the request path through the application's active version.none
POST/v1/apps/{name}/trace Since v0.2operatorRuns one described request through the application's configuration.Body: method, url, host, scheme, headers, body, body_base64, or record (a traffic record to replay), and version.
GET/v1/apps/{name}/pages/{kind}viewerPreviews a block, error or challenge page.none
PUT/v1/apps/{name}/pages/{kind}operatorSets the custom body of a page (empty restores the built-in page).Body: set (key to value; empty string resets the key), base_version (required), comment, dry_run.

Server pools and virtual IPs ​

MethodPathMinimum roleWhat it doesMain fields
GET/v1/pools Since v0.2viewerLists server pools.none
GET/v1/pools/health Since v0.2viewerReturns member health of every pool.none
GET/v1/pools/{name} Since v0.2viewerReturns one pool.none
GET/v1/pools/{name}/settings Since v0.2viewerReturns one pool as form fields (same handler as the route above).none
POST/v1/pools Since v0.2operator, all applicationsCreates a pool.Body: name, servers (the whole list), set, base_version, comment, dry_run.
PUT/v1/pools/{name} Since v0.2operator, all applicationsChanges a pool.Body: servers, set, base_version, comment, dry_run.
DELETE/v1/pools/{name} Since v0.2operator, all applicationsRemoves a pool.none
POST/v1/pools/{name}/rename Since v0.2operator, all applicationsRenames a pool and updates references.Body: name (the new name), base_version, comment, dry_run.
POST/v1/pools/merge Since v0.2operator, all applicationsMerges pools into one.Body: into, from (pool names), base_version, comment, dry_run.
PUT/v1/pools/{name}/ca Since v0.2operator, all applicationsSets the CA certificate that verifies the pool's members.Body: ca (PEM), base_version, comment, dry_run.
GET/v1/vips Since v0.2viewerLists virtual IPs.none
GET/v1/vips/{name} Since v0.2viewerReturns one virtual IP.none
POST/v1/vips Since v0.2operator, all applicationsCreates a virtual IP.Body: name, set (address, description, floating), base_version, comment, dry_run.
PUT/v1/vips/{name} Since v0.2operator, all applicationsChanges a virtual IP.Body: set, base_version, comment, dry_run.
DELETE/v1/vips/{name} Since v0.2operator, all applicationsRemoves a virtual IP.none

Global settings ​

MethodPathMinimum roleWhat it doesMain fields
GET/v1/config/settings/{section}viewer, all applicationsReturns one global section (for example events, traffic, geoip).Returns the current values with base_version.
PUT/v1/config/settings/{section}operator, all applicationsChanges one global section. The management, ha, analyst, assess and scan_targets sections need the admin role even though the route needs operator.Body: set (key to value; empty string resets the key), base_version (required), comment, dry_run.

Example ​

sh
curl -sk -H "Authorization: Bearer waap_EXAMPLE" https://127.0.0.1:9443/v1/apps