This content is associated with a legacy version of the Replicated product. For the current Replicated product docs, click here.
The Console API offers developers the ability to retrieve Replicated console settings.
Console settings are not the same as application config settings. Application config settings should be provided to your applications via template functions in the release YAML.
Applications may find it useful to know certain properties about a Replicated install, such as its airgap status, console host, or proxy settings. The Console API can be used to retrieve all of this information. The API can also be used to retrieve the TLS certificates generated by Replicated or uploaded during the initial install process.
GET /console/v1/option
Returns values corresponding to the given console option name.
Request parameters
Name | Type | Description |
---|---|---|
name | String | Option name |
Available Options
Airgap
All file names and paths are relative to the primary node
airgap.install
- Returns if an installation is airgappedairgap.license.path
- In an airgapped install, returns the license file pathairgap.package.path
- In an airgapped install, returns the package file path
Snapshots
snapshot.destination
- File path for snapshotssnapshot.retention
- Snapshot retention periodsnapshot.timeout
- Snapshot timeout periodsnapshot.schedule
- Returns all of thesnapshot.schedule
subfields.snapshot.schedule.enabled
- Returns if snapshots are enabledsnapshot.schedule.spec
- Returns the snapshot definition YMLsnapshot.schedule.time.daily
- Snapshot time each day, if default settings are usedsnapshot.schedule.day.weekly
- Snapshot day each week, if default settings are usedsnapshot.schedule.time.weekly
- Snapshot time each week, if default settings are usedsnapshot.schedule.custom.interval
- Snapshot cron entry, if custom settings are used
TLS / Security
All file names and paths are relative to the primary node
cert.filename
- Certificate file namecert.filepath
- Certificate pathkey.filename
- Private key file namekey.filepath
- Private key file pathsecurity.cert
- PEM encoded TLS certificatesecurity.key
- PEM encoded TLS private keytls.authority.cert
- PEM encoded Certificate Authoritytls.config.option
- TLS Config
Misc
app.update.check.schedule
- Application update scheduleclock.skew.threshold.milliseconds
- Clock skew threshold between primary and operator nodeshostname
- Primary node hostname, configured on initial installhttp.proxy
- HTTP proxy settingshttp.proxy.enabled
- Returns if an HTTP proxy is enabledlanguage.source
- Language Replicated is set to use. Deprecated.license.sync.schedule
- License sync schedulestatsd.data.location
- Statsd file paths on the primary nodestatsd.endpoint
- Statsd endpoint for metrics and monitoringscheduler
- Returns the current scheduler, one of: replicated, swarm, kubernetesupdate.check.schedule.custom.interval
- Returns if update checks are set to a custom cron interval
Response Status
Status | Description |
---|---|
200 | Success |
400 | Bad request |
Response body
Option value (string)
Example
$ curl -k $REPLICATED_INTEGRATIONAPI/console/v1/option?name=app.update.check.schedule
@every 5h
GET /console/v1/auth
Retrieves the console auth type and form object to be sent as a request to the POST /console/v1/auth
route.
Response Status
Status | Description |
---|---|
200 | Success |
Response body
Name | Type | Description |
---|---|---|
authType | String | Console auth type (one of anonymous, password, ldap, ldap_advanced) |
form | Object | Console auth object to be sent to the POST /console/v1/auth route |
Example
$ curl -k $REPLICATED_INTEGRATIONAPI/console/v1/auth | jq
{
"authType": "ldap",
"form": {
"password": "",
"username": ""
}
}
POST /console/v1/auth
Authenticates against the console authentication settings.
Request payload
Name | Type | Description |
---|---|---|
username | String | Username (required only for authentication type LDAP) |
password | String | Password |
Response Status
Status | Description |
---|---|
200 | Authentication successful |
400 | Bad request |
401 | Invalid authentication credentials |
Response body
no content
Example
$ curl -ik -X POST -H 'content-type:application/json' $REPLICATED_INTEGRATIONAPI/console/v1/auth -d '{"password":"mysupersecretpassword"}'
HTTP/2 200
content-type: text/plain; charset=utf-8
date: Thu, 13 Feb 2020 00:38:40 GMT
content-length: 0