From 9eec3e1729eb7d91c77f6a7f0bfef8043cbe6dba Mon Sep 17 00:00:00 2001 From: Scott Anderson Date: Mon, 30 Sep 2019 10:00:22 -0600 Subject: [PATCH] WIP api-docs autogen, stylesheets, and auto-build process --- .circleci/config.yml | 5 +- .gitignore | 1 + api-docs/generate-api-docs.sh | 40 ++ api-docs/template.hbs | 28 + assets/styles/layouts/_api-overrides.scss | 266 +++++++++ assets/styles/styles-api.scss | 4 + content/v2.0/api.html | 648 +++++++++++----------- content/v2.0/reference/api.md | 9 +- layouts/partials/header/stylesheets.html | 4 + 9 files changed, 692 insertions(+), 313 deletions(-) create mode 100644 api-docs/generate-api-docs.sh create mode 100644 assets/styles/layouts/_api-overrides.scss create mode 100644 assets/styles/styles-api.scss diff --git a/.circleci/config.yml b/.circleci/config.yml index ffd410c2d..c02b6b06b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -23,7 +23,10 @@ jobs: command: ./deploy/ci-install-s3deploy.sh - run: name: Install NPM dependencies - command: sudo npm i -g postcss-cli autoprefixer + command: sudo npm i -g postcss-cli autoprefixer redoc-cli + - run: + name: Generate API documentation + command: cd api-docs && sh generate-api-docs.sh - save_cache: key: install-v1-{{ checksum ".circleci/config.yml" }} paths: diff --git a/.gitignore b/.gitignore index 07f198c85..b69d13c23 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ public node_modules *.log /resources +/content/**/api.html diff --git a/api-docs/generate-api-docs.sh b/api-docs/generate-api-docs.sh new file mode 100644 index 000000000..a9419c248 --- /dev/null +++ b/api-docs/generate-api-docs.sh @@ -0,0 +1,40 @@ +#!/bin/bash -e + +# Get list of versions from directory names +versions="$(ls -d -- */)" + +for version in $versions +do + # Trim the trailing slash off the directory name + version="${version%/}" + menu="${version//./_}_ref" + + # Generate the frontmatter + frontmatter="--- +title: InfluxDB $version API documentation +description: > + The InfluxDB API provides a programmatic interface for interactions with InfluxDB $version. +layout: api +menu: + $menu: + parent: InfluxDB v2 API + name: View full API docs +weight: 102 +--- +" + + # Use Redoc to generate the API html + redoc-cli bundle -t template.hbs \ + --title="InfluxDB $version API documentation" \ + --options.sortPropsAlphabetically \ + --options.menuToggle \ + --options.hideHostname \ + --templateOptions.version="$version" \ + $version/swagger.yml + + # Create temp file with frontmatter and Redoc html + echo "$frontmatter" >> $version.tmp + cat redoc-static.html >> $version.tmp + rm -f redoc-static.html + mv $version.tmp ../content/$version/api.html +done diff --git a/api-docs/template.hbs b/api-docs/template.hbs index 5b8c294b8..b63535da2 100644 --- a/api-docs/template.hbs +++ b/api-docs/template.hbs @@ -7,6 +7,16 @@ + + + + + {{#unless disableGoogleFont}}{{/unless}} {{{redocHead}}} + +
+
+
+
+ InfluxDB {{templateOptions.version}} Docs +
{{{redocHTML}}} + diff --git a/assets/styles/layouts/_api-overrides.scss b/assets/styles/layouts/_api-overrides.scss new file mode 100644 index 000000000..080b3d918 --- /dev/null +++ b/assets/styles/layouts/_api-overrides.scss @@ -0,0 +1,266 @@ +@import "tools/color-palette"; +@import "tools/icomoon"; + +// Fonts +$rubik: 'Rubik', sans-serif; +$roboto: 'Roboto', sans-serif; +$roboto-mono: 'Roboto Mono', monospace; + +// Font weights +$medium: 500; +$bold: 700; + +//////////////////////////////////// LOADER //////////////////////////////////// + +#loading { + position: fixed; + width: 100vw; + height: 100vh; + z-index: 1000; + background-color: $g20-white; + opacity: 1; + transition: opacity .5s; +} + +@keyframes spinner { + to {transform: rotate(360deg);} +} + +.spinner:before { + content: ''; + box-sizing: border-box; + position: absolute; + top: 50%; + left: 50%; + width: 50px; + height: 50px; + margin-top: -25px; + margin-left: -25px; + border-radius: 50%; + border: 3px solid $g16-pearl; + border-top-color: $cp-comet; + animation: spinner .6s linear infinite; +} + +//////////////////////////////// InfluxDB Header /////////////////////////////// + +#influx-header { + font-family: $rubik; + padding: 15px 20px ; + display: block; + background-color: $wp-violentdark; + a { + color: $g20-white; + text-decoration: none; + transition: color .2s; + &:hover { + color: $b-pool; + } + &:before { + content: '\e918'; + font-family: 'icomoon'; + margin-right: .65rem; + } + } +} + +//////////////////////////////////////////////////////////////////////////////// + +.cjtbAK { + h1,h2,h3,h4,h5,h6, + p,li,th,td { + font-family: $rubik !important; + } +} + +#redoc { + h1,h2,h3,h4,h5,h6 { + font-weight: $medium !important; + } +} + +// Section title padding +.dluJDj { + padding: 20px 0; +} + +// Page h1 +.dTJWQH { + color: $g7-graphite; + font-size: 2rem; +} + +// Download button +.jIdpVJ { + background: $b-dodger; + color: $g20-white; + border: none; + border-radius: 3px; + font-family: $rubik; + font-size: .85rem; + font-weight: $medium; + transition: background-color .2s; + &:hover { + background-color: $b-pool; + } +} + +// Tag h1s +.WxWXp { + color: $g7-graphite; + font-size: 1.75rem; +} + +// Summaru h2s and table headers +.ioYTqA, .bxcHYI, .hoUoen { + color: $g7-graphite; +} + +// h3s +.espozG { + color: $g8-storm; +} + +// Links +.bnFPhO a { color: $b-dodger; + &:visited {color: $b-dodger;} +} + +.redoc-json { + font-family: $roboto-mono !important; +} + +// Inline Code +.flfxUM code, +.gDsWLk code, +.kTVySD { + font-family: $roboto-mono !important; + color: $cp-marguerite; + background: $cp-titan; + border-color: $cp-titan; +} + +// Required tags +.jsTAxL { + color: $o-curacao; +} + +///////////////////////////// RESPONSE COLOR BLOCKS //////////////////////////// + +// Green +.hLVzSF { + background-color: rgba($gr-wasabi, .5); + color: $gr-emerald; +} + +// Red +.byLrBg { + background-color: rgba($o-marmelade, .35); + color: $o-curacao; +} + + + +/////////////////////////////////// LEFT NAV /////////////////////////////////// + +// Left nav background +.gZdDsM { + background-color: $g19-ghost; +} + +.gpbcFk:hover, .sc-eTuwsz.active { + background-color: rgb(237, 237, 237); +} + +// List item text +.SmuWE, .gcUzvG, .bbViyS, .sc-hrWEMg label { + font-family: $rubik !important; +} + +.fyUykq { + font-weight: $medium; +} + +// Request method tags +.cFwMcp { + &.post { background-color: $b-curious; } + &.get { background-color: $gr-canopy; } + &.put { background-color: $cp-comet; } + &.patch { background-color: $ch-keylime; } + &.delete { background-color: $o-curacao; } +} + +// Active nav section +.gcUzvG, .iNzLCk:hover { + color: $m-magenta; +} + +/////////////////////////////// RIGHT CODE COLUMN ////////////////////////////// + +// Right column backgrounds +.dtUibw, .fLUKgj { + background-color: $wp-jagger; + h3,h4,h5,h6 { + font-family: $rubik !important; + font-weight: $medium !important; + } +} + +// Code backgrounds +.irpqyy > .react-tabs__tab-panel { + background-color: $wp-telopea; +} +.dHLKeu, .fVaxnA { + padding-left: 10px; + background-color: $wp-telopea; +} + +// Response code tabs +.irpqyy > ul > li { + background-color: $wp-telopea; + border-radius: 3px; + &.react-tabs__tab--selected{ color: $cp-blueviolet; } + &.tab-error { color: $o-fire; } + &.tab-success { color: $gr-viridian; } +} + +// Request methods +.bNYCAJ, +.jBjYbV, +.hOczRB, +.fRsrDc, +.hPskZd { + font-family: $rubik; + font-weight: $medium; + letter-spacing: .04em; + border-radius: 3px; +} +.bNYCAJ { background-color: $b-curious; } /* Post */ +.jBjYbV { background-color: $gr-canopy; } /* Get */ +.hOczRB { background-color: $cp-comet; } /* Put */ +.fRsrDc { background-color: $ch-chartreuse; color: $ch-olive; } /* Patch */ +.hPskZd { background-color: $o-curacao; } /* Delete */ + +// Content type block +.gzAoUb { + background-color: rgba($wp-jagger, .4); + font-family: $rubik; +} +.iENVAs { font-family: $roboto-mono; } +.dpMbau { font-family: $rubik; } + +// Code controls +.fCJmC { + font-family: $rubik; + span { border-radius: 3px; } +} + +// Code blocks +.kZHJcC { font-family: $roboto-mono; } +.jCgylq { + .token.string { + color: $gr-honeydew; + & + a { color: $b-malibu; } + } + .token.boolean { color: #f955b0; } +} diff --git a/assets/styles/styles-api.scss b/assets/styles/styles-api.scss new file mode 100644 index 000000000..df8888069 --- /dev/null +++ b/assets/styles/styles-api.scss @@ -0,0 +1,4 @@ +// InfluxData API Docs style overrides +// These override styles generated by ReDoc + +@import "layouts/api-overrides"; diff --git a/content/v2.0/api.html b/content/v2.0/api.html index 708c65520..c305402ba 100644 --- a/content/v2.0/api.html +++ b/content/v2.0/api.html @@ -19,6 +19,16 @@ weight: 102 + + + + + + - +
+
+
+
+ InfluxDB v2.0 Docs +
+
get /setup
/api/v2/setup

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "allowed": true
}

Set up initial user, org and bucket

Post an onboarding request to set up initial user, org and bucket.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Source to create

-
username
required
string
password
required
string
org
required
string
bucket
required
string
retentionPeriodHrs
integer

Responses

201

Created default user, bucket, org

-
post /setup
/api/v2/setup

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "username": "string",
  • "password": "string",
  • "org": "string",
  • "bucket": "string",
  • "retentionPeriodHrs": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "user":
    {
    },
  • "org":
    {
    },
  • "bucket":
    {
    },
  • "auth":
    {
    }
}

Templates

GetDocumentsTemplates

query Parameters
org
string

Specifies the name of the organization of the template.

+
bucket
required
string
org
required
string
password
required
string
retentionPeriodHrs
integer
username
required
string

Responses

201

Created default user, bucket, org

+
post /setup
/api/v2/setup

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "username": "string",
  • "password": "string",
  • "org": "string",
  • "bucket": "string",
  • "retentionPeriodHrs": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "user":
    {
    },
  • "org":
    {
    },
  • "bucket":
    {
    },
  • "auth":
    {
    }
}

Templates

GetDocumentsTemplates

query Parameters
org
string

Specifies the name of the organization of the template.

orgID
string

Specifies the organization ID of the template.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of template documents

default

Unexpected error

-
get /documents/templates
/api/v2/documents/templates

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "documents":
    [
    ]
}

Create a template

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /documents/templates
/api/v2/documents/templates

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "documents":
    [
    ]
}

Create a template

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Template that will be created

-
meta
required
object (DocumentMeta)
content
required
object
org
string

The organization Name. Specify either orgID or org.

-
orgID
string

The organization Name. Specify either orgID or org.

-
labels
Array of strings

An array of label IDs to be added as labels to the document.

+
content
required
object
labels
Array of strings

An array of label IDs to be added as labels to the document.

+
meta
required
object (DocumentMeta)
org
string

The organization Name. Specify either orgID or org.

+
orgID
string

The organization Name. Specify either orgID or org.

Responses

201

Template created

default

Unexpected error

-
post /documents/templates
/api/v2/documents/templates

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "meta":
    {
    },
  • "content": { },
  • "org": "string",
  • "orgID": "string",
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

GetDocumentsTemplatesID

path Parameters
templateID
required
string

The template ID.

+
post /documents/templates
/api/v2/documents/templates

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "meta":
    {
    },
  • "content": { },
  • "org": "string",
  • "orgID": "string",
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

GetDocumentsTemplatesID

path Parameters
templateID
required
string

The template ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

The template requested

default

Unexpected error

-
get /documents/templates/{templateID}
/api/v2/documents/templates/{templateID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

PutDocumentsTemplatesID

path Parameters
templateID
required
string

The template ID.

+
get /documents/templates/{templateID}
/api/v2/documents/templates/{templateID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

PutDocumentsTemplatesID

path Parameters
templateID
required
string

The template ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Template that will be updated

-
meta
object (DocumentMeta)
content
object

Responses

200

The newly updated template

+
content
object
meta
object (DocumentMeta)

Responses

200

The newly updated template

default

Unexpected error

-
put /documents/templates/{templateID}
/api/v2/documents/templates/{templateID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "meta":
    {
    },
  • "content": { }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

Delete a template

path Parameters
templateID
required
string

The template ID.

+
put /documents/templates/{templateID}
/api/v2/documents/templates/{templateID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "meta":
    {
    },
  • "content": { }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "meta":
    {
    },
  • "content": { },
  • "labels":
    [
    ],
  • "links":
    {
    }
}

Delete a template

path Parameters
templateID
required
string

The template ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

default

Unexpected error

@@ -399,8 +416,8 @@ and limitations under the License.
Request Body schema: application/json

Label to add

labelID
string

Responses

201

The label added to the template

default

Unexpected error

-
post /documents/templates/{templateID}/labels
/api/v2/documents/templates/{templateID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a template

path Parameters
templateID
required
string

The template ID.

-
labelID
required
string

The label ID.

+
post /documents/templates/{templateID}/labels
/api/v2/documents/templates/{templateID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a template

path Parameters
labelID
required
string

The label ID.

+
templateID
required
string

The template ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Template not found

@@ -411,17 +428,17 @@ and limitations under the License.
default

Unexpected error

get /telegrafs
/api/v2/telegrafs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "configurations":
    [
    ]
}

Create a Telegraf config

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Telegraf config to create

-
name
string
description
string
agent
object
plugins
Array of TelegrafPluginInputCpu (object) or TelegrafPluginInputDisk (object) or TelegrafPluginInputDiskio (object) or TelegrafPluginInputDocker (object) or TelegrafPluginInputFile (object) or TelegrafPluginInputKubernetes (object) or TelegrafPluginInputLogParser (object) or TelegrafPluginInputProcstat (object) or TelegrafPluginInputPrometheus (object) or TelegrafPluginInputRedis (object) or TelegrafPluginInputSyslog (object) or TelegrafPluginOutputFile (object) or TelegrafPluginOutputInfluxDBV2 (object) (TelegrafRequestPlugin)
orgID
string

Responses

201

Telegraf config created

+
agent
object
description
string
name
string
orgID
string
plugins
Array of TelegrafPluginInputCpu (object) or TelegrafPluginInputDisk (object) or TelegrafPluginInputDiskio (object) or TelegrafPluginInputDocker (object) or TelegrafPluginInputFile (object) or TelegrafPluginInputKubernetes (object) or TelegrafPluginInputLogParser (object) or TelegrafPluginInputProcstat (object) or TelegrafPluginInputPrometheus (object) or TelegrafPluginInputRedis (object) or TelegrafPluginInputSyslog (object) or TelegrafPluginOutputFile (object) or TelegrafPluginOutputInfluxDBV2 (object) (TelegrafRequestPlugin)

Responses

201

Telegraf config created

default

Unexpected error

post /telegrafs
/api/v2/telegrafs

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "agent":
    {
    },
  • "plugins":
    [
    ],
  • "orgID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "agent":
    {
    },
  • "plugins":
    [
    ],
  • "orgID": "string",
  • "id": "string",
  • "links":
    {
    },
  • "labels":
    [
    ]
}

Retrieve a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

-
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Accept
string
Default: "application/toml"
Enum: "application/toml" "application/json" "application/octet-stream"

Responses

200

Telegraf config details

+
header Parameters
Accept
string
Default: "application/toml"
Enum: "application/toml" "application/json" "application/octet-stream"
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+

Responses

200

Telegraf config details

default

Unexpected error

get /telegrafs/{telegrafID}
/api/v2/telegrafs/{telegrafID}

Response samples

Content type
Copy
[agent]
 interval = "10s"

Update a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Telegraf config update to apply

-
name
string
description
string
agent
object
plugins
Array of TelegrafPluginInputCpu (object) or TelegrafPluginInputDisk (object) or TelegrafPluginInputDiskio (object) or TelegrafPluginInputDocker (object) or TelegrafPluginInputFile (object) or TelegrafPluginInputKubernetes (object) or TelegrafPluginInputLogParser (object) or TelegrafPluginInputProcstat (object) or TelegrafPluginInputPrometheus (object) or TelegrafPluginInputRedis (object) or TelegrafPluginInputSyslog (object) or TelegrafPluginOutputFile (object) or TelegrafPluginOutputInfluxDBV2 (object) (TelegrafRequestPlugin)
orgID
string

Responses

200

An updated Telegraf config

+
agent
object
description
string
name
string
orgID
string
plugins
Array of TelegrafPluginInputCpu (object) or TelegrafPluginInputDisk (object) or TelegrafPluginInputDiskio (object) or TelegrafPluginInputDocker (object) or TelegrafPluginInputFile (object) or TelegrafPluginInputKubernetes (object) or TelegrafPluginInputLogParser (object) or TelegrafPluginInputProcstat (object) or TelegrafPluginInputPrometheus (object) or TelegrafPluginInputRedis (object) or TelegrafPluginInputSyslog (object) or TelegrafPluginOutputFile (object) or TelegrafPluginOutputInfluxDBV2 (object) (TelegrafRequestPlugin)

Responses

200

An updated Telegraf config

default

Unexpected error

put /telegrafs/{telegrafID}
/api/v2/telegrafs/{telegrafID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "agent":
    {
    },
  • "plugins":
    [
    ],
  • "orgID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "agent":
    {
    },
  • "plugins":
    [
    ],
  • "orgID": "string",
  • "id": "string",
  • "links":
    {
    },
  • "labels":
    [
    ]
}

Delete a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

@@ -436,8 +453,8 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

201

The label added to the Telegraf config

default

Unexpected error

-
post /telegrafs/{telegrafID}/labels
/api/v2/telegrafs/{telegrafID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

-
labelID
required
string

The label ID.

+
post /telegrafs/{telegrafID}/labels
/api/v2/telegrafs/{telegrafID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a Telegraf config

path Parameters
labelID
required
string

The label ID.

+
telegrafID
required
string

The Telegraf config ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Telegraf config not found

@@ -451,8 +468,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to Telegraf config

default

Unexpected error

-
post /telegrafs/{telegrafID}/members
/api/v2/telegrafs/{telegrafID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a Telegraf config

path Parameters
userID
required
string

The ID of the member to remove.

-
telegrafID
required
string

The Telegraf config ID.

+
post /telegrafs/{telegrafID}/members
/api/v2/telegrafs/{telegrafID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -465,8 +482,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Telegraf config owner added

default

Unexpected error

-
post /telegrafs/{telegrafID}/owners
/api/v2/telegrafs/{telegrafID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a Telegraf config

path Parameters
userID
required
string

The ID of the owner to remove.

-
telegrafID
required
string

The Telegraf config ID.

+
post /telegrafs/{telegrafID}/owners
/api/v2/telegrafs/{telegrafID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -479,8 +496,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to Telegraf config

default

Unexpected error

-
post /telegrafs/{telegrafID}/members
/api/v2/telegrafs/{telegrafID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a Telegraf config

path Parameters
userID
required
string

The ID of the member to remove.

-
telegrafID
required
string

The Telegraf config ID.

+
post /telegrafs/{telegrafID}/members
/api/v2/telegrafs/{telegrafID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -493,8 +510,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Telegraf config owner added

default

Unexpected error

-
post /telegrafs/{telegrafID}/owners
/api/v2/telegrafs/{telegrafID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a Telegraf config

path Parameters
userID
required
string

The ID of the owner to remove.

-
telegrafID
required
string

The Telegraf config ID.

+
post /telegrafs/{telegrafID}/owners
/api/v2/telegrafs/{telegrafID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a Telegraf config

path Parameters
telegrafID
required
string

The Telegraf config ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -507,8 +524,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to scraper targets

default

Unexpected error

-
post /scrapers/{scraperTargetID}/members
/api/v2/scrapers/{scraperTargetID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a scraper target

path Parameters
userID
required
string

The ID of member to remove.

-
scraperTargetID
required
string

The scraper target ID.

+
post /scrapers/{scraperTargetID}/members
/api/v2/scrapers/{scraperTargetID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

+
userID
required
string

The ID of member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -521,8 +538,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Scraper target owner added

default

Unexpected error

-
post /scrapers/{scraperTargetID}/owners
/api/v2/scrapers/{scraperTargetID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a scraper target

path Parameters
userID
required
string

The ID of owner to remove.

-
scraperTargetID
required
string

The scraper target ID.

+
post /scrapers/{scraperTargetID}/owners
/api/v2/scrapers/{scraperTargetID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

+
userID
required
string

The ID of owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -535,8 +552,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to dashboard members

default

Unexpected error

-
post /dashboards/{dashboardID}/members
/api/v2/dashboards/{dashboardID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a dashboard

path Parameters
userID
required
string

The ID of the member to remove.

-
dashboardID
required
string

The dashboard ID.

+
post /dashboards/{dashboardID}/members
/api/v2/dashboards/{dashboardID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -549,8 +566,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Added to dashboard owners

default

Unexpected error

-
post /dashboards/{dashboardID}/owners
/api/v2/dashboards/{dashboardID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a dashboard

path Parameters
userID
required
string

The ID of the owner to remove.

-
dashboardID
required
string

The dashboard ID.

+
post /dashboards/{dashboardID}/owners
/api/v2/dashboards/{dashboardID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -563,8 +580,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to bucket

default

Unexpected error

-
post /buckets/{bucketID}/members
/api/v2/buckets/{bucketID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a bucket

path Parameters
userID
required
string

The ID of the member to remove.

-
bucketID
required
string

The bucket ID.

+
post /buckets/{bucketID}/members
/api/v2/buckets/{bucketID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -577,8 +594,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Bucket owner added

default

Unexpected error

-
post /buckets/{bucketID}/owners
/api/v2/buckets/{bucketID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a bucket

path Parameters
userID
required
string

The ID of the owner to remove.

-
bucketID
required
string

The bucket ID.

+
post /buckets/{bucketID}/owners
/api/v2/buckets/{bucketID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -591,8 +608,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to organization created

default

Unexpected error

-
post /orgs/{orgID}/members
/api/v2/orgs/{orgID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from an organization

path Parameters
userID
required
string

The ID of the member to remove.

-
orgID
required
string

The organization ID.

+
post /orgs/{orgID}/members
/api/v2/orgs/{orgID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from an organization

path Parameters
orgID
required
string

The organization ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -605,8 +622,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Organization owner added

default

Unexpected error

-
post /orgs/{orgID}/owners
/api/v2/orgs/{orgID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from an organization

path Parameters
userID
required
string

The ID of the owner to remove.

-
orgID
required
string

The organization ID.

+
post /orgs/{orgID}/owners
/api/v2/orgs/{orgID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from an organization

path Parameters
orgID
required
string

The organization ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -626,8 +643,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to task members

default

Unexpected error

-
post /tasks/{taskID}/members
/api/v2/tasks/{taskID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a task

path Parameters
userID
required
string

The ID of the member to remove.

-
taskID
required
string

The task ID.

+
post /tasks/{taskID}/members
/api/v2/tasks/{taskID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a task

path Parameters
taskID
required
string

The task ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -640,8 +657,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Added to task owners

default

Unexpected error

-
post /tasks/{taskID}/owners
/api/v2/tasks/{taskID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a task

path Parameters
userID
required
string

The ID of the owner to remove.

-
taskID
required
string

The task ID.

+
post /tasks/{taskID}/owners
/api/v2/tasks/{taskID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a task

path Parameters
taskID
required
string

The task ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -650,7 +667,7 @@ interval = "10s"<
default

Unexpected error

get /users
/api/v2/users

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "users":
    [
    ]
}

Create a user

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

User to create

-
oauthID
string
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the user is inactive.

+
name
required
string
oauthID
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the user is inactive.

Responses

201

User created

default

Unexpected error

post /users
/api/v2/users

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "oauthID": "string",
  • "name": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    }
}

Retrieve a user

path Parameters
userID
required
string

The user ID.

@@ -660,7 +677,7 @@ interval = "10s"<
get /users/{userID}
/api/v2/users/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    }
}

Update a user

path Parameters
userID
required
string

The ID of the user to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

User update to apply

-
oauthID
string
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the user is inactive.

+
name
required
string
oauthID
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the user is inactive.

Responses

200

User updated

default

Unexpected error

patch /users/{userID}
/api/v2/users/{userID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "oauthID": "string",
  • "name": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    }
}

Delete a user

path Parameters
userID
required
string

The ID of the user to delete.

@@ -673,22 +690,22 @@ interval = "10s"<
password
required
string

Responses

204

Password successfully updated

default

Unsuccessful authentication

put /users/{userID}/password
/api/v2/users/{userID}/password

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "password": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve operation logs for a user

path Parameters
userID
required
string

The user ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the user

default

Unexpected error

-
get /users/{userID}/logs
/api/v2/users/{userID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

ScraperTargets

Get all scraper targets

query Parameters
name
string

Specifies the name of the scraper target.

-
id
Array of strings

List of scraper target IDs to return. If both id and owner are specified, only id is used.

-
orgID
string

Specifies the organization ID of the scraper target.

-
org
string

Specifies the organization name of the scraper target.

+
get /users/{userID}/logs
/api/v2/users/{userID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

ScraperTargets

Get all scraper targets

query Parameters
id
Array of strings

List of scraper target IDs to return. If both id and owner are specified, only id is used.

+
name
string

Specifies the name of the scraper target.

+
org
string

Specifies the organization name of the scraper target.

+
orgID
string

Specifies the organization ID of the scraper target.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

All scraper targets

get /scrapers
/api/v2/scrapers

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "configurations":
    [
    ]
}

Create a scraper target

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Scraper target to create

-
name
string

The name of the scraper target.

-
type
string
Value: "prometheus"

The type of the metrics to be parsed.

-
url
string

The URL of the metrics endpoint.

+
bucketID
string

The ID of the bucket to write to.

+
name
string

The name of the scraper target.

orgID
string

The organization ID.

-
bucketID
string

The ID of the bucket to write to.

+
type
string
Value: "prometheus"

The type of the metrics to be parsed.

+
url
string

The URL of the metrics endpoint.

Responses

201

Scraper target created

default

Internal server error

post /scrapers
/api/v2/scrapers

Request samples

Content type
application/json
Copy
Expand all Collapse all
{}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "type": "prometheus",
  • "orgID": "string",
  • "bucketID": "string",
  • "id": "string",
  • "org": "string",
  • "bucket": "string",
  • "links":
    {
    }
}

Get a scraper target by ID

path Parameters
scraperTargetID
required
string

The scraper target ID.

@@ -702,11 +719,11 @@ interval = "10s"<
delete /scrapers/{scraperTargetID}
/api/v2/scrapers/{scraperTargetID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Update a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Scraper target update to apply

-
name
string

The name of the scraper target.

-
type
string
Value: "prometheus"

The type of the metrics to be parsed.

-
url
string

The URL of the metrics endpoint.

+
bucketID
string

The ID of the bucket to write to.

+
name
string

The name of the scraper target.

orgID
string

The organization ID.

-
bucketID
string

The ID of the bucket to write to.

+
type
string
Value: "prometheus"

The type of the metrics to be parsed.

+
url
string

The URL of the metrics endpoint.

Responses

200

Scraper target updated

default

Internal server error

patch /scrapers/{scraperTargetID}
/api/v2/scrapers/{scraperTargetID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "type": "prometheus",
  • "orgID": "string",
  • "bucketID": "string",
  • "id": "string",
  • "org": "string",
  • "bucket": "string",
  • "links":
    {
    }
}

List all labels for a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

@@ -718,14 +735,14 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

201

The newly added label

default

Unexpected error

-
post /scrapers/{scraperTargetID}/labels
/api/v2/scrapers/{scraperTargetID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

-
labelID
required
string

The label ID.

+
post /scrapers/{scraperTargetID}/labels
/api/v2/scrapers/{scraperTargetID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a scraper target

path Parameters
labelID
required
string

The label ID.

+
scraperTargetID
required
string

The scraper target ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Scraper target not found

default

Unexpected error

-
delete /scrapers/{scraperTargetID}/labels/{labelID}
/api/v2/scrapers/{scraperTargetID}/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Update a label on a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

-
labelID
required
string

The label ID.

+
delete /scrapers/{scraperTargetID}/labels/{labelID}
/api/v2/scrapers/{scraperTargetID}/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Update a label on a scraper target

path Parameters
labelID
required
string

The label ID.

+
scraperTargetID
required
string

The scraper target ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Label update to apply

name
string
properties
object

Key/Value pairs associated with this label. Keys can be removed by sending an update with an empty value.

@@ -741,8 +758,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to scraper targets

default

Unexpected error

-
post /scrapers/{scraperTargetID}/members
/api/v2/scrapers/{scraperTargetID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a scraper target

path Parameters
userID
required
string

The ID of member to remove.

-
scraperTargetID
required
string

The scraper target ID.

+
post /scrapers/{scraperTargetID}/members
/api/v2/scrapers/{scraperTargetID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

+
userID
required
string

The ID of member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -755,8 +772,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Scraper target owner added

default

Unexpected error

-
post /scrapers/{scraperTargetID}/owners
/api/v2/scrapers/{scraperTargetID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a scraper target

path Parameters
userID
required
string

The ID of owner to remove.

-
scraperTargetID
required
string

The scraper target ID.

+
post /scrapers/{scraperTargetID}/owners
/api/v2/scrapers/{scraperTargetID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a scraper target

path Parameters
scraperTargetID
required
string

The scraper target ID.

+
userID
required
string

The ID of owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

@@ -768,28 +785,28 @@ interval = "10s"<
default

Internal server error

get /variables
/api/v2/variables

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "variables":
    [
    ]
}

Create a variable

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Variable to create

-
orgID
required
string
name
required
string
description
string
selected
Array of strings
labels
Array of objects (Labels)
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
updatedAt
string <date-time>

Responses

201

Variable created

+
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
description
string
labels
Array of objects (Labels)
name
required
string
orgID
required
string
selected
Array of strings
updatedAt
string <date-time>

Responses

201

Variable created

default

Internal server error

-
post /variables
/api/v2/variables

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Get a variable

path Parameters
variableID
required
string

The variable ID.

+
post /variables
/api/v2/variables

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Get a variable

path Parameters
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Variable found

404

Variable not found

default

Internal server error

-
get /variables/{variableID}
/api/v2/variables/{variableID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Delete a variable

path Parameters
variableID
required
string

The variable ID.

+
get /variables/{variableID}
/api/v2/variables/{variableID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Delete a variable

path Parameters
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Variable deleted

default

Internal server error

delete /variables/{variableID}
/api/v2/variables/{variableID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Update a variable

path Parameters
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Variable update to apply

-
orgID
required
string
name
required
string
description
string
selected
Array of strings
labels
Array of objects (Labels)
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
updatedAt
string <date-time>

Responses

200

Variable updated

+
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
description
string
labels
Array of objects (Labels)
name
required
string
orgID
required
string
selected
Array of strings
updatedAt
string <date-time>

Responses

200

Variable updated

default

Internal server error

-
patch /variables/{variableID}
/api/v2/variables/{variableID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Replace a variable

path Parameters
variableID
required
string

The variable ID.

+
patch /variables/{variableID}
/api/v2/variables/{variableID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Replace a variable

path Parameters
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Variable to replace

-
orgID
required
string
name
required
string
description
string
selected
Array of strings
labels
Array of objects (Labels)
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
updatedAt
string <date-time>

Responses

200

Variable updated

+
arguments
required
QueryVariableProperties (object) or ConstantVariableProperties (object) or MapVariableProperties (object)
createdAt
string <date-time>
description
string
labels
Array of objects (Labels)
name
required
string
orgID
required
string
selected
Array of strings
updatedAt
string <date-time>

Responses

200

Variable updated

default

Internal server error

-
put /variables/{variableID}
/api/v2/variables/{variableID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z"
}

List all labels for a variable

path Parameters
variableID
required
string

The variable ID.

+
put /variables/{variableID}
/api/v2/variables/{variableID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "id": "string",
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "selected":
    [
    ],
  • "labels":
    [
    ],
  • "arguments":
    {
    },
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z"
}

List all labels for a variable

path Parameters
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of all labels for a variable

default

Unexpected error

@@ -798,21 +815,21 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

201

The newly added label

default

Unexpected error

-
post /variables/{variableID}/labels
/api/v2/variables/{variableID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a variable

path Parameters
variableID
required
string

The variable ID.

-
labelID
required
string

The label ID to delete.

+
post /variables/{variableID}/labels
/api/v2/variables/{variableID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a variable

path Parameters
labelID
required
string

The label ID to delete.

+
variableID
required
string

The variable ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Variable not found

default

Unexpected error

-
delete /variables/{variableID}/labels/{labelID}
/api/v2/variables/{variableID}/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Write

Write time series data into InfluxDB

query Parameters
org
required
string

Specifies the destination organization for writes. Takes either the ID or Name interchangeably. If both orgID and org are specified, org takes precedence.

+
delete /variables/{variableID}/labels/{labelID}
/api/v2/variables/{variableID}/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Write

Write time series data into InfluxDB

query Parameters
bucket
required
string

The destination bucket for writes.

+
org
required
string

Specifies the destination organization for writes. Takes either the ID or Name interchangeably. If both orgID and org are specified, org takes precedence.

orgID
string

Specifies the ID of the destination organization for writes. If both orgID and org are specified, org takes precedence.

-
bucket
required
string

The destination bucket for writes.

precision
string (WritePrecision)
Enum: "ms" "s" "us" "ns"

The precision for the unix timestamps within the body line-protocol.

-
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
header Parameters
Accept
string
Default: "application/json"
Value: "application/json"

Specifies the return content format.

Content-Encoding
string
Default: "identity"
Enum: "gzip" "identity"

When present, its value indicates to the database that compression is applied to the line-protocol body.

-
Content-Type
string
Default: "text/plain; charset=utf-8"
Enum: "text/plain" "text/plain; charset=utf-8" "application/vnd.influx.arrow"

Content-Type is used to indicate the format of the data sent to the server.

Content-Length
integer

Content-Length is an entity header is indicating the size of the entity-body, in bytes, sent to the database. If the length is greater than the database max body configuration option, a 413 response is sent.

-
Accept
string
Default: "application/json"
Value: "application/json"

Specifies the return content format.

+
Content-Type
string
Default: "text/plain; charset=utf-8"
Enum: "text/plain" "text/plain; charset=utf-8" "application/vnd.influx.arrow"

Content-Type is used to indicate the format of the data sent to the server.

+
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: text/plain

Line protocol body

string

Responses

204

Write data is correctly formatted and accepted for writing to the bucket.

400

Line protocol poorly formed and no points were written. Response can be used to determine the first malformed line in the body line-protocol. All data in body was rejected and not written.

@@ -831,7 +848,7 @@ interval = "10s"<
default

Unexpected error

get /health
/health

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "message": "string",
  • "checks":
    [
    ],
  • "status": "pass"
}

Sources

Creates a source

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Source to create

-
links
object
id
string
orgID
string
default
boolean
name
string
type
string
Enum: "v1" "v2" "self"
url
string <uri>
insecureSkipVerify
boolean
telegraf
string
token
string
username
string
password
string
sharedSecret
string
metaUrl
string <uri>
defaultRP
string

Responses

201

Created Source

+
default
boolean
defaultRP
string
id
string
insecureSkipVerify
boolean
links
object
metaUrl
string <uri>
name
string
orgID
string
password
string
sharedSecret
string
telegraf
string
token
string
type
string
Enum: "v1" "v2" "self"
url
string <uri>
username
string

Responses

201

Created Source

default

Unexpected error

post /sources
/api/v2/sources

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "orgID": "string",
  • "default": true,
  • "name": "string",
  • "type": "v1",
  • "insecureSkipVerify": true,
  • "telegraf": "string",
  • "token": "string",
  • "username": "string",
  • "password": "string",
  • "sharedSecret": "string",
  • "metaUrl": "http://example.com",
  • "defaultRP": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "orgID": "string",
  • "default": true,
  • "name": "string",
  • "type": "v1",
  • "insecureSkipVerify": true,
  • "telegraf": "string",
  • "token": "string",
  • "username": "string",
  • "password": "string",
  • "sharedSecret": "string",
  • "metaUrl": "http://example.com",
  • "defaultRP": "string",
  • "languages":
    [
    ]
}

Get all sources

query Parameters
org
string

The organization name.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

@@ -845,7 +862,7 @@ interval = "10s"<
delete /sources/{sourceID}
/api/v2/sources/{sourceID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Update a Source

path Parameters
sourceID
required
string

The source ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Source update

-
links
object
id
string
orgID
string
default
boolean
name
string
type
string
Enum: "v1" "v2" "self"
url
string <uri>
insecureSkipVerify
boolean
telegraf
string
token
string
username
string
password
string
sharedSecret
string
metaUrl
string <uri>
defaultRP
string

Responses

200

Created Source

+
default
boolean
defaultRP
string
id
string
insecureSkipVerify
boolean
links
object
metaUrl
string <uri>
name
string
orgID
string
password
string
sharedSecret
string
telegraf
string
token
string
type
string
Enum: "v1" "v2" "self"
url
string <uri>
username
string

Responses

200

Created Source

404

Source not found

default

Unexpected error

patch /sources/{sourceID}
/api/v2/sources/{sourceID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "orgID": "string",
  • "default": true,
  • "name": "string",
  • "type": "v1",
  • "insecureSkipVerify": true,
  • "telegraf": "string",
  • "token": "string",
  • "username": "string",
  • "password": "string",
  • "sharedSecret": "string",
  • "metaUrl": "http://example.com",
  • "defaultRP": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "orgID": "string",
  • "default": true,
  • "name": "string",
  • "type": "v1",
  • "insecureSkipVerify": true,
  • "telegraf": "string",
  • "token": "string",
  • "username": "string",
  • "password": "string",
  • "sharedSecret": "string",
  • "metaUrl": "http://example.com",
  • "defaultRP": "string",
  • "languages":
    [
    ]
}

Get a source

path Parameters
sourceID
required
string

The source ID.

@@ -864,34 +881,34 @@ interval = "10s"<

Responses

200

A source

404

Source not found

default

Unexpected error

-
get /sources/{sourceID}/buckets
/api/v2/sources/{sourceID}/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

Buckets

Get buckets in a source

path Parameters
sourceID
required
string

The source ID.

+
get /sources/{sourceID}/buckets
/api/v2/sources/{sourceID}/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

Buckets

Get buckets in a source

path Parameters
sourceID
required
string

The source ID.

query Parameters
org
string

The organization name.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A source

404

Source not found

default

Unexpected error

-
get /sources/{sourceID}/buckets
/api/v2/sources/{sourceID}/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

List all buckets

query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
org
string

The organization name.

-
orgID
string

The organization ID.

-
name
string

Only returns buckets with a specific name.

+
get /sources/{sourceID}/buckets
/api/v2/sources/{sourceID}/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

List all buckets

query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
name
string

Only returns buckets with a specific name.

+
offset
integer >= 0
org
string

The organization name.

+
orgID
string

The organization ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of buckets

default

Unexpected error

-
get /buckets
/api/v2/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

Create a bucket

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /buckets
/api/v2/buckets

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "buckets":
    [
    ]
}

Create a bucket

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Bucket to create

-
name
required
string
description
string
orgID
string
rp
string
retentionRules
required
Array of objects

Rules to expire or retain data. No rules means data never expires.

-
labels
Array of objects (Labels)

Responses

201

Bucket created

+
description
string
labels
Array of objects (Labels)
name
required
string
orgID
string
retentionRules
required
Array of objects

Rules to expire or retain data. No rules means data never expires.

+
rp
string

Responses

201

Bucket created

default

Unexpected error

-
post /buckets
/api/v2/buckets

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Retrieve a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
post /buckets
/api/v2/buckets

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Retrieve a bucket

path Parameters
bucketID
required
string

The bucket ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Bucket details

default

Unexpected error

-
get /buckets/{bucketID}
/api/v2/buckets/{bucketID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Update a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
get /buckets/{bucketID}
/api/v2/buckets/{bucketID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Update a bucket

path Parameters
bucketID
required
string

The bucket ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Bucket update to apply

-
name
required
string
description
string
orgID
string
rp
string
retentionRules
required
Array of objects

Rules to expire or retain data. No rules means data never expires.

-
labels
Array of objects (Labels)

Responses

200

An updated bucket

+
description
string
labels
Array of objects (Labels)
name
required
string
orgID
string
retentionRules
required
Array of objects

Rules to expire or retain data. No rules means data never expires.

+
rp
string

Responses

200

An updated bucket

default

Unexpected error

-
patch /buckets/{bucketID}
/api/v2/buckets/{bucketID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-27T20:40:41Z",
  • "updatedAt": "2019-09-27T20:40:41Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Delete a bucket

path Parameters
bucketID
required
string

The ID of the bucket to delete.

+
patch /buckets/{bucketID}
/api/v2/buckets/{bucketID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "type": "user",
  • "name": "string",
  • "description": "string",
  • "orgID": "string",
  • "rp": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "retentionRules":
    [
    ],
  • "labels":
    [
    ]
}

Delete a bucket

path Parameters
bucketID
required
string

The ID of the bucket to delete.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Bucket not found

@@ -920,8 +937,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Member added to bucket

default

Unexpected error

-
post /buckets/{bucketID}/members
/api/v2/buckets/{bucketID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a bucket

path Parameters
userID
required
string

The ID of the member to remove.

-
bucketID
required
string

The bucket ID.

+
post /buckets/{bucketID}/members
/api/v2/buckets/{bucketID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -934,17 +951,17 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Bucket owner added

default

Unexpected error

-
post /buckets/{bucketID}/owners
/api/v2/buckets/{bucketID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a bucket

path Parameters
userID
required
string

The ID of the owner to remove.

-
bucketID
required
string

The bucket ID.

+
post /buckets/{bucketID}/owners
/api/v2/buckets/{bucketID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

delete /buckets/{bucketID}/owners/{userID}
/api/v2/buckets/{bucketID}/owners/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve operation logs for a bucket

path Parameters
bucketID
required
string

The bucket ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the bucket

default

Unexpected error

-
get /buckets/{bucketID}/logs
/api/v2/buckets/{bucketID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Labels

Create a label

Request Body schema: application/json

Label to create

-
orgID
required
string
name
string
properties
object

Key/Value pairs associated with this label. Keys can be removed by sending an update with an empty value.

+
get /buckets/{bucketID}/logs
/api/v2/buckets/{bucketID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Labels

Create a label

Request Body schema: application/json

Label to create

+
name
string
orgID
required
string
properties
object

Key/Value pairs associated with this label. Keys can be removed by sending an update with an empty value.

Responses

201

Added label

default

Unexpected error

post /labels
/api/v2/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Get all labels

query Parameters
orgID
string

The organization ID.

@@ -969,34 +986,34 @@ interval = "10s"<
default

Unexpected error

delete /labels/{labelID}
/api/v2/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Dashboards

Create a dashboard

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Dashboard to create

-
orgID
required
string

The ID of the organization that owns the dashboard.

+
description
string

The user-facing description of the dashboard.

name
required
string

The user-facing name of the dashboard.

-
description
string

The user-facing description of the dashboard.

+
orgID
required
string

The ID of the organization that owns the dashboard.

Responses

201

Added dashboard

default

Unexpected error

-
post /dashboards
/api/v2/dashboards

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Get all dashboards

query Parameters
owner
string

The owner ID.

-
sortBy
string
Enum: "ID" "CreatedAt" "UpdatedAt"

The column to sort by.

-
id
Array of strings

List of dashboard IDs to return. If both id andownerare specified, onlyid` is used.

+
post /dashboards
/api/v2/dashboards

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Get all dashboards

query Parameters
id
Array of strings

List of dashboard IDs to return. If both id andownerare specified, onlyid` is used.

+
org
string

The organization name.

orgID
string

The organization ID.

-
org
string

The organization name.

+
owner
string

The owner ID.

+
sortBy
string
Enum: "ID" "CreatedAt" "UpdatedAt"

The column to sort by.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

All dashboards

default

Unexpected error

-
get /dashboards
/api/v2/dashboards

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "dashboards":
    [
    ]
}

Get a Dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

+
get /dashboards
/api/v2/dashboards

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "dashboards":
    [
    ]
}

Get a Dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Get a single dashboard

404

Dashboard not found

default

Unexpected error

-
get /dashboards/{dashboardID}
/api/v2/dashboards/{dashboardID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Update a dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

+
get /dashboards/{dashboardID}
/api/v2/dashboards/{dashboardID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Update a dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Patching of a dashboard

-
orgID
required
string

The ID of the organization that owns the dashboard.

-
name
required
string

The user-facing name of the dashboard.

-
description
string

The user-facing description of the dashboard.

-
links
object
meta
object
cells
Array of objects (Cells)
labels
Array of objects (Labels)

Responses

200

Updated dashboard

+
cells
Array of objects (Cells)
description
string

The user-facing description of the dashboard.

+
labels
Array of objects (Labels)
links
object
meta
object
name
required
string

The user-facing name of the dashboard.

+
orgID
required
string

The ID of the organization that owns the dashboard.

+

Responses

200

Updated dashboard

404

Dashboard not found

default

Unexpected error

-
patch /dashboards/{dashboardID}
/api/v2/dashboards/{dashboardID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Delete a dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

+
patch /dashboards/{dashboardID}
/api/v2/dashboards/{dashboardID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Delete a dashboard

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Dashboard not found

@@ -1004,38 +1021,38 @@ interval = "10s"<
delete /dashboards/{dashboardID}
/api/v2/dashboards/{dashboardID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Replace cells in a dashboard

Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Request Body schema: application/json
Array
id
string
links
object
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>
viewID
string

The reference to a view from the views API.

-

Responses

200

Replaced dashboard cells

+
Request Body schema: application/json
Array
h
integer <int32>
id
string
links
object
viewID
string

The reference to a view from the views API.

+
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

200

Replaced dashboard cells

404

Dashboard not found

default

Unexpected error

-
put /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
[
  • {
    }
]

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Create a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

+
put /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
[
  • {
    }
]

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Create a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Cell that will be added

-
name
string
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>
usingView
string

Makes a copy of the provided view.

-

Responses

201

Cell successfully added

+
h
integer <int32>
name
string
usingView
string

Makes a copy of the provided view.

+
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

201

Cell successfully added

404

Dashboard not found

default

Unexpected error

post /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "usingView": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Update the non-positional information related to a cell

Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.

-
path Parameters
dashboardID
required
string

The ID of the dashboard to update.

-
cellID
required
string

The ID of the cell to update.

+
path Parameters
cellID
required
string

The ID of the cell to update.

+
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Request Body schema: application/json
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>

Responses

200

Updated dashboard cell

+
Request Body schema: application/json
h
integer <int32>
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

200

Updated dashboard cell

404

Cell or dashboard not found

default

Unexpected error

-
patch /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Delete a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to delete.

-
cellID
required
string

The ID of the cell to delete.

+
patch /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Delete a dashboard cell

path Parameters
cellID
required
string

The ID of the cell to delete.

+
dashboardID
required
string

The ID of the dashboard to delete.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Cell successfully deleted

404

Cell or dashboard not found

default

Unexpected error

-
delete /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve the view for a cell

path Parameters
dashboardID
required
string

The dashboard ID.

-
cellID
required
string

The cell ID.

+
delete /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve the view for a cell

path Parameters
cellID
required
string

The cell ID.

+
dashboardID
required
string

The dashboard ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A dashboard cells view

404

Cell or dashboard not found

default

Unexpected error

-
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

-
cellID
required
string

The ID of the cell to update.

+
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
cellID
required
string

The ID of the cell to update.

+
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json
name
required
string
properties
required
LinePlusSingleStatProperties (object) or XYViewProperties (object) or SingleStatViewProperties (object) or HistogramViewProperties (object) or GaugeViewProperties (object) or TableViewProperties (object) or MarkdownViewProperties (object) or CheckViewProperties (object) or ScatterViewProperties (object) or HeatmapViewProperties (object) (ViewProperties)

Responses

200

Updated cell view

404

Cell or dashboard not found

@@ -1064,8 +1081,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to dashboard members

default

Unexpected error

-
post /dashboards/{dashboardID}/members
/api/v2/dashboards/{dashboardID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a dashboard

path Parameters
userID
required
string

The ID of the member to remove.

-
dashboardID
required
string

The dashboard ID.

+
post /dashboards/{dashboardID}/members
/api/v2/dashboards/{dashboardID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -1078,85 +1095,85 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Added to dashboard owners

default

Unexpected error

-
post /dashboards/{dashboardID}/owners
/api/v2/dashboards/{dashboardID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a dashboard

path Parameters
userID
required
string

The ID of the owner to remove.

-
dashboardID
required
string

The dashboard ID.

+
post /dashboards/{dashboardID}/owners
/api/v2/dashboards/{dashboardID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

delete /dashboards/{dashboardID}/owners/{userID}
/api/v2/dashboards/{dashboardID}/owners/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve operation logs for a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the dashboard

default

Unexpected error

-
get /dashboards/{dashboardID}/logs
/api/v2/dashboards/{dashboardID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Cells

Replace cells in a dashboard

Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.

+
get /dashboards/{dashboardID}/logs
/api/v2/dashboards/{dashboardID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Cells

Replace cells in a dashboard

Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Request Body schema: application/json
Array
id
string
links
object
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>
viewID
string

The reference to a view from the views API.

-

Responses

200

Replaced dashboard cells

+
Request Body schema: application/json
Array
h
integer <int32>
id
string
links
object
viewID
string

The reference to a view from the views API.

+
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

200

Replaced dashboard cells

404

Dashboard not found

default

Unexpected error

-
put /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
[
  • {
    }
]

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Create a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

+
put /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
[
  • {
    }
]

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "orgID": "string",
  • "name": "string",
  • "description": "string",
  • "links":
    {
    },
  • "id": "string",
  • "meta":
    {
    },
  • "cells":
    [
    ],
  • "labels":
    [
    ]
}

Create a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Cell that will be added

-
name
string
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>
usingView
string

Makes a copy of the provided view.

-

Responses

201

Cell successfully added

+
h
integer <int32>
name
string
usingView
string

Makes a copy of the provided view.

+
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

201

Cell successfully added

404

Dashboard not found

default

Unexpected error

post /dashboards/{dashboardID}/cells
/api/v2/dashboards/{dashboardID}/cells

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "usingView": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Update the non-positional information related to a cell

Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.

-
path Parameters
dashboardID
required
string

The ID of the dashboard to update.

-
cellID
required
string

The ID of the cell to update.

+
path Parameters
cellID
required
string

The ID of the cell to update.

+
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Request Body schema: application/json
x
integer <int32>
y
integer <int32>
w
integer <int32>
h
integer <int32>

Responses

200

Updated dashboard cell

+
Request Body schema: application/json
h
integer <int32>
w
integer <int32>
x
integer <int32>
y
integer <int32>

Responses

200

Updated dashboard cell

404

Cell or dashboard not found

default

Unexpected error

-
patch /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Delete a dashboard cell

path Parameters
dashboardID
required
string

The ID of the dashboard to delete.

-
cellID
required
string

The ID of the cell to delete.

+
patch /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "links":
    {
    },
  • "x": 0,
  • "y": 0,
  • "w": 0,
  • "h": 0,
  • "viewID": "string"
}

Delete a dashboard cell

path Parameters
cellID
required
string

The ID of the cell to delete.

+
dashboardID
required
string

The ID of the dashboard to delete.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Cell successfully deleted

404

Cell or dashboard not found

default

Unexpected error

-
delete /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve the view for a cell

path Parameters
dashboardID
required
string

The dashboard ID.

-
cellID
required
string

The cell ID.

+
delete /dashboards/{dashboardID}/cells/{cellID}
/api/v2/dashboards/{dashboardID}/cells/{cellID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve the view for a cell

path Parameters
cellID
required
string

The cell ID.

+
dashboardID
required
string

The dashboard ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A dashboard cells view

404

Cell or dashboard not found

default

Unexpected error

-
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

-
cellID
required
string

The ID of the cell to update.

+
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
cellID
required
string

The ID of the cell to update.

+
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json
name
required
string
properties
required
LinePlusSingleStatProperties (object) or XYViewProperties (object) or SingleStatViewProperties (object) or HistogramViewProperties (object) or GaugeViewProperties (object) or TableViewProperties (object) or MarkdownViewProperties (object) or CheckViewProperties (object) or ScatterViewProperties (object) or HeatmapViewProperties (object) (ViewProperties)

Responses

200

Updated cell view

404

Cell or dashboard not found

default

Unexpected error

-
patch /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "properties":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Views

Retrieve the view for a cell

path Parameters
dashboardID
required
string

The dashboard ID.

-
cellID
required
string

The cell ID.

+
patch /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "properties":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Views

Retrieve the view for a cell

path Parameters
cellID
required
string

The cell ID.

+
dashboardID
required
string

The dashboard ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A dashboard cells view

404

Cell or dashboard not found

default

Unexpected error

-
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
dashboardID
required
string

The ID of the dashboard to update.

-
cellID
required
string

The ID of the cell to update.

+
get /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

Update the view for a cell

path Parameters
cellID
required
string

The ID of the cell to update.

+
dashboardID
required
string

The ID of the dashboard to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json
name
required
string
properties
required
LinePlusSingleStatProperties (object) or XYViewProperties (object) or SingleStatViewProperties (object) or HistogramViewProperties (object) or GaugeViewProperties (object) or TableViewProperties (object) or MarkdownViewProperties (object) or CheckViewProperties (object) or ScatterViewProperties (object) or HeatmapViewProperties (object) (ViewProperties)

Responses

200

Updated cell view

404

Cell or dashboard not found

default

Unexpected error

patch /dashboards/{dashboardID}/cells/{cellID}/view
/api/v2/dashboards/{dashboardID}/cells/{cellID}/view

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "properties":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "properties":
    {
    }
}

OperationLogs

Retrieve operation logs for a dashboard

path Parameters
dashboardID
required
string

The dashboard ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the dashboard

default

Unexpected error

-
get /dashboards/{dashboardID}/logs
/api/v2/dashboards/{dashboardID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for a bucket

path Parameters
bucketID
required
string

The bucket ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /dashboards/{dashboardID}/logs
/api/v2/dashboards/{dashboardID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for a bucket

path Parameters
bucketID
required
string

The bucket ID.

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the bucket

default

Unexpected error

-
get /buckets/{bucketID}/logs
/api/v2/buckets/{bucketID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for an organization

path Parameters
orgID
required
string

The organization ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /buckets/{bucketID}/logs
/api/v2/buckets/{bucketID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for an organization

path Parameters
orgID
required
string

The organization ID.

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the organization

default

Unexpected error

-
get /orgs/{orgID}/logs
/api/v2/orgs/{orgID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for a user

path Parameters
userID
required
string

The user ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /orgs/{orgID}/logs
/api/v2/orgs/{orgID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Retrieve operation logs for a user

path Parameters
userID
required
string

The user ID.

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the user

default

Unexpected error

-
get /users/{userID}/logs
/api/v2/users/{userID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Query

PostQueryAst

Analyzes flux query and generates a query specification.

-
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Content-Type
string
Value: "application/json"
Request Body schema: application/json

Analyzed Flux query to generate abstract syntax tree.

+
get /users/{userID}/logs
/api/v2/users/{userID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Query

PostQueryAst

Analyzes flux query and generates a query specification.

+
header Parameters
Content-Type
string
Value: "application/json"
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
Request Body schema: application/json

Analyzed Flux query to generate abstract syntax tree.

query
required
string

Flux query script to be analyzed

Responses

200

Abstract syntax tree of flux query.

default

Any response other than 200 is an internal server error

@@ -1167,45 +1184,45 @@ interval = "10s"<
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Suggestions for next functions in call chain

default

Any response other than 200 is an internal server error

-
get /query/suggestions/{name}
/api/v2/query/suggestions/{name}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "params":
    {
    }
}

Analyze an InfluxQL or Flux query

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Content-Type
string
Value: "application/json"
Request Body schema: application/json

Flux or InfluxQL query to analyze

-
extern
object (File)

Represents a source from a single file

-
query
required
string

Query script to execute.

-
type
string
Default: "flux"
Enum: "flux" "influxql"

The type of query.

+
get /query/suggestions/{name}
/api/v2/query/suggestions/{name}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "params":
    {
    }
}

Analyze an InfluxQL or Flux query

header Parameters
Content-Type
string
Value: "application/json"
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
Request Body schema: application/json

Flux or InfluxQL query to analyze

+
cluster
string

Required for influxql type queries.

db
string

Required for influxql type queries.

+
dialect
object (Dialect)

Dialect are options to change the default CSV output format; https://www.w3.org/TR/2015/REC-tabular-metadata-20151217/#dialect-descriptions

+
extern
object (File)

Represents a source from a single file

+
query
required
string

Query script to execute.

rp
string

Required for influxql type queries.

-
cluster
string

Required for influxql type queries.

-
dialect
object (Dialect)

Dialect are options to change the default CSV output format; https://www.w3.org/TR/2015/REC-tabular-metadata-20151217/#dialect-descriptions

+
type
string
Default: "flux"
Enum: "flux" "influxql"

The type of query.

Responses

200

Query analyze results. Errors will be empty if the query is valid.

default

Internal server error

post /query/analyze
/api/v2/query/analyze

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "extern":
    {
    },
  • "query": "string",
  • "type": "flux",
  • "db": "string",
  • "rp": "string",
  • "cluster": "string",
  • "dialect":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "errors":
    [
    ]
}

Query InfluxDB

query Parameters
org
string

Specifies the name of the organization executing the query. Takes either the ID or Name interchangeably. If both orgID and org are specified, org takes precedence.

orgID
string

Specifies the ID of the organization executing the query. If both orgID and org are specified, org takes precedence.

-
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

-
Accept-Encoding
string
Default: "identity"
Enum: "gzip" "identity"

The Accept-Encoding request HTTP header advertises which content encoding, usually a compression algorithm, the client is able to understand.

-
Content-Type
string
Enum: "application/json" "application/vnd.flux"
Request Body schema:

Flux query or specification to execute

-
extern
object (File)

Represents a source from a single file

-
query
required
string

Query script to execute.

-
type
string
Default: "flux"
Enum: "flux" "influxql"

The type of query.

+
header Parameters
Accept-Encoding
string
Default: "identity"
Enum: "gzip" "identity"

The Accept-Encoding request HTTP header advertises which content encoding, usually a compression algorithm, the client is able to understand.

+
Content-Type
string
Enum: "application/json" "application/vnd.flux"
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
Request Body schema:

Flux query or specification to execute

+
cluster
string

Required for influxql type queries.

db
string

Required for influxql type queries.

+
dialect
object (Dialect)

Dialect are options to change the default CSV output format; https://www.w3.org/TR/2015/REC-tabular-metadata-20151217/#dialect-descriptions

+
extern
object (File)

Represents a source from a single file

+
query
required
string

Query script to execute.

rp
string

Required for influxql type queries.

-
cluster
string

Required for influxql type queries.

-
dialect
object (Dialect)

Dialect are options to change the default CSV output format; https://www.w3.org/TR/2015/REC-tabular-metadata-20151217/#dialect-descriptions

+
type
string
Default: "flux"
Enum: "flux" "influxql"

The type of query.

Responses

200

Query results

429

Token is temporarily over quota. The Retry-After header describes when to try the read again.

default

Error processing query

-
post /query
/api/v2/query

Request samples

Content type
Copy
Expand all Collapse all
{
  • "extern":
    {
    },
  • "query": "string",
  • "type": "flux",
  • "db": "string",
  • "rp": "string",
  • "cluster": "string",
  • "dialect":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Authorizations

List all authorizations

query Parameters
userID
string

Only show authorizations that belong to a user ID.

-
user
string

Only show authorizations that belong to a user name.

+
post /query
/api/v2/query

Request samples

Content type
Copy
Expand all Collapse all
{
  • "extern":
    {
    },
  • "query": "string",
  • "type": "flux",
  • "db": "string",
  • "rp": "string",
  • "cluster": "string",
  • "dialect":
    {
    }
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Authorizations

List all authorizations

query Parameters
org
string

Only show authorizations that belong to a organization name.

orgID
string

Only show authorizations that belong to an organization ID.

-
org
string

Only show authorizations that belong to a organization name.

+
user
string

Only show authorizations that belong to a user name.

+
userID
string

Only show authorizations that belong to a user ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of authorizations

default

Unexpected error

get /authorizations
/api/v2/authorizations

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "authorizations":
    [
    ]
}

Create an authorization

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Authorization to create

-
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the token is inactive and requests using the token will be rejected.

-
description
string

A description of the token.

+
description
string

A description of the token.

orgID
required
string

ID of org that authorization is scoped to.

-
permissions
required
Array of objects (Permission) non-empty

List of permissions for an auth. An auth must have at least one Permission.

+
permissions
required
Array of objects (Permission) non-empty

List of permissions for an auth. An auth must have at least one Permission.

+
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the token is inactive and requests using the token will be rejected.

Responses

201

Authorization created

400

Invalid request

default

Unexpected error

@@ -1216,8 +1233,8 @@ interval = "10s"<
get /authorizations/{authID}
/api/v2/authorizations/{authID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "active",
  • "description": "string",
  • "orgID": "string",
  • "permissions":
    [
    ],
  • "id": "string",
  • "token": "string",
  • "userID": "string",
  • "user": "string",
  • "org": "string",
  • "links":
    {
    }
}

Update an authorization to be active or inactive

path Parameters
authID
required
string

The ID of the authorization to update.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Authorization to update

-
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the token is inactive and requests using the token will be rejected.

-
description
string

A description of the token.

+
description
string

A description of the token.

+
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the token is inactive and requests using the token will be rejected.

Responses

200

The active or inactie authorization

default

Unexpected error

patch /authorizations/{authID}
/api/v2/authorizations/{authID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "active",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "active",
  • "description": "string",
  • "orgID": "string",
  • "permissions":
    [
    ],
  • "id": "string",
  • "token": "string",
  • "userID": "string",
  • "user": "string",
  • "org": "string",
  • "links":
    {
    }
}

Delete a authorization

path Parameters
authID
required
string

The ID of the authorization to delete.

@@ -1229,22 +1246,22 @@ interval = "10s"<
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of organizations

default

Unexpected error

-
get /orgs
/api/v2/orgs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "orgs":
    [
    ]
}

Create an organization

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /orgs
/api/v2/orgs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "orgs":
    [
    ]
}

Create an organization

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Organization to create

-
name
required
string
description
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the organization is inactive.

+
description
string
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the organization is inactive.

Responses

201

Organization created

default

Unexpected error

-
post /orgs
/api/v2/orgs

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active"
}

Retrieve an organization

path Parameters
orgID
required
string

The ID of the organization to get.

+
post /orgs
/api/v2/orgs

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "status": "active"
}

Retrieve an organization

path Parameters
orgID
required
string

The ID of the organization to get.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Organization details

default

Unexpected error

-
get /orgs/{orgID}
/api/v2/orgs/{orgID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active"
}

Update an organization

path Parameters
orgID
required
string

The ID of the organization to get.

+
get /orgs/{orgID}
/api/v2/orgs/{orgID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "status": "active"
}

Update an organization

path Parameters
orgID
required
string

The ID of the organization to get.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Organization update to apply

-
name
required
string
description
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the organization is inactive.

+
description
string
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

If inactive the organization is inactive.

Responses

200

Organization updated

default

Unexpected error

-
patch /orgs/{orgID}
/api/v2/orgs/{orgID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active"
}

Delete an organization

path Parameters
orgID
required
string

The ID of the organization to delete.

+
patch /orgs/{orgID}
/api/v2/orgs/{orgID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {
    },
  • "id": "string",
  • "name": "string",
  • "description": "string",
  • "createdAt": "2019-09-30T15:58:24Z",
  • "updatedAt": "2019-09-30T15:58:24Z",
  • "status": "active"
}

Delete an organization

path Parameters
orgID
required
string

The ID of the organization to delete.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Organization not found

@@ -1258,8 +1275,8 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

201

Returns the created label

default

Unexpected error

-
post /orgs/{orgID}/labels
/api/v2/orgs/{orgID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from an organization

path Parameters
orgID
required
string

The organization ID.

-
labelID
required
string

The label ID.

+
post /orgs/{orgID}/labels
/api/v2/orgs/{orgID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from an organization

path Parameters
labelID
required
string

The label ID.

+
orgID
required
string

The organization ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Organization not found

@@ -1287,8 +1304,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to organization created

default

Unexpected error

-
post /orgs/{orgID}/members
/api/v2/orgs/{orgID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from an organization

path Parameters
userID
required
string

The ID of the member to remove.

-
orgID
required
string

The organization ID.

+
post /orgs/{orgID}/members
/api/v2/orgs/{orgID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from an organization

path Parameters
orgID
required
string

The organization ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -1301,16 +1318,16 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Organization owner added

default

Unexpected error

-
post /orgs/{orgID}/owners
/api/v2/orgs/{orgID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from an organization

path Parameters
userID
required
string

The ID of the owner to remove.

-
orgID
required
string

The organization ID.

+
post /orgs/{orgID}/owners
/api/v2/orgs/{orgID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from an organization

path Parameters
orgID
required
string

The organization ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

delete /orgs/{orgID}/owners/{userID}
/api/v2/orgs/{orgID}/owners/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retrieve operation logs for an organization

path Parameters
orgID
required
string

The organization ID.

-
query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Operation logs for the organization

default

Unexpected error

-
get /orgs/{orgID}/logs
/api/v2/orgs/{orgID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Secrets

List all secret keys for an organization

path Parameters
orgID
required
string

The organization ID.

+
get /orgs/{orgID}/logs
/api/v2/orgs/{orgID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Secrets

List all secret keys for an organization

path Parameters
orgID
required
string

The organization ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of all secret keys

default

Unexpected error

@@ -1324,82 +1341,82 @@ interval = "10s"<
Request Body schema: application/json

Secret key to delete

secrets
Array of strings

Responses

204

Keys successfully patched

default

Unexpected error

-
post /orgs/{orgID}/secrets/delete
/api/v2/orgs/{orgID}/secrets/delete

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "secrets":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Tasks

List all tasks

query Parameters
name
string

Returns task with a specific name.

-
after
string

Return tasks after a specified ID.

-
user
string

Filter tasks to a specific user ID.

+
post /orgs/{orgID}/secrets/delete
/api/v2/orgs/{orgID}/secrets/delete

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "secrets":
    [
    ]
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Tasks

List all tasks

query Parameters
after
string

Return tasks after a specified ID.

+
limit
integer [ 1 .. 500 ]
Default: 100

The number of tasks to return

+
name
string

Returns task with a specific name.

org
string

Filter tasks to a specific organization name.

orgID
string

Filter tasks to a specific organization ID.

-
limit
integer [ 1 .. 500 ]
Default: 100

The number of tasks to return

+
user
string

Filter tasks to a specific user ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of tasks

default

Unexpected error

-
get /tasks
/api/v2/tasks

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "tasks":
    [
    ]
}

Create a new task

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /tasks
/api/v2/tasks

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "tasks":
    [
    ]
}

Create a new task

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Task to create

-
type
string

The type of task, this can be used for filtering tasks on list actions.

-
orgID
string

The ID of the organization that owns this Task.

+
description
string

An optional description of the task.

+
flux
required
string

The Flux script to run for this task.

org
string

The name of the organization that owns this Task.

-
status
string (TaskStatusType)
Enum: "active" "inactive"
flux
required
string

The Flux script to run for this task.

-
description
string

An optional description of the task.

+
orgID
string

The ID of the organization that owns this Task.

+
status
string (TaskStatusType)
Enum: "active" "inactive"
type
string

The type of task, this can be used for filtering tasks on list actions.

Responses

201

Task created

default

Unexpected error

-
post /tasks
/api/v2/tasks

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "status": "active",
  • "flux": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-27T20:40:42Z",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Retrieve a task

path Parameters
taskID
required
string

The task ID.

+
post /tasks
/api/v2/tasks

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "status": "active",
  • "flux": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-30T15:58:25Z",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Retrieve a task

path Parameters
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Task details

default

Unexpected error

-
get /tasks/{taskID}
/api/v2/tasks/{taskID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-27T20:40:42Z",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Update a task

Update a task. This will cancel all queued runs.

+
get /tasks/{taskID}
/api/v2/tasks/{taskID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-30T15:58:25Z",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Update a task

Update a task. This will cancel all queued runs.

path Parameters
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Task update to apply

-
status
string (TaskStatusType)
Enum: "active" "inactive"
flux
string

The Flux script to run for this task.

-
name
string

Override the 'name' option in the flux script.

+
cron
string

Override the 'cron' option in the flux script.

+
description
string

An optional description of the task.

every
string

Override the 'every' option in the flux script.

-
cron
string

Override the 'cron' option in the flux script.

+
flux
string

The Flux script to run for this task.

+
name
string

Override the 'name' option in the flux script.

offset
string

Override the 'offset' option in the flux script.

-
description
string

An optional description of the task.

-

Responses

200

Task updated

+
status
string (TaskStatusType)
Enum: "active" "inactive"

Responses

200

Task updated

default

Unexpected error

-
patch /tasks/{taskID}
/api/v2/tasks/{taskID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "active",
  • "flux": "string",
  • "name": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-27T20:40:42Z",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Delete a task

Deletes a task and all associated records

+
patch /tasks/{taskID}
/api/v2/tasks/{taskID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "active",
  • "flux": "string",
  • "name": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "description": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "type": "string",
  • "orgID": "string",
  • "org": "string",
  • "name": "string",
  • "description": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "authorizationID": "string",
  • "flux": "string",
  • "every": "string",
  • "cron": "string",
  • "offset": "string",
  • "latestCompleted": "2019-09-30T15:58:25Z",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Delete a task

Deletes a task and all associated records

path Parameters
taskID
required
string

The ID of the task to delete.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Task deleted

default

Unexpected error

delete /tasks/{taskID}
/api/v2/tasks/{taskID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

List runs for a task

path Parameters
taskID
required
string

The ID of the task to get runs for.

query Parameters
after
string

Returns runs after a specific ID.

-
limit
integer [ 1 .. 500 ]
Default: 100

The number of runs to return

afterTime
string <date-time>

Filter runs to those scheduled after this time, RFC3339

-
beforeTime
string <date-time>

Filter runs to those scheduled before this time, RFC3339

+
beforeTime
string <date-time>

Filter runs to those scheduled before this time, RFC3339

+
limit
integer [ 1 .. 500 ]
Default: 100

The number of runs to return

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of task runs

default

Unexpected error

-
get /tasks/{taskID}/runs
/api/v2/tasks/{taskID}/runs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "runs":
    [
    ]
}

Manually start a task run, overriding the current schedule

path Parameters
taskID
required
string
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

+
get /tasks/{taskID}/runs
/api/v2/tasks/{taskID}/runs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "links":
    {},
  • "runs":
    [
    ]
}

Manually start a task run, overriding the current schedule

path Parameters
taskID
required
string
header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json
scheduledFor
string <date-time> Nullable

Time used for run's "now" option, RFC3339. Default is the server's now time.

Responses

201

Run scheduled to start

default

Unexpected error

-
post /tasks/{taskID}/runs
/api/v2/tasks/{taskID}/runs

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "scheduledFor": "2019-09-27T20:40:42Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-27T20:40:42Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-27T20:40:42Z",
  • "finishedAt": "2019-09-27T20:40:42Z",
  • "requestedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Retrieve a single run for a task

path Parameters
taskID
required
string

The task ID.

-
runID
required
string

The run ID.

+
post /tasks/{taskID}/runs
/api/v2/tasks/{taskID}/runs

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "scheduledFor": "2019-09-30T15:58:25Z"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-30T15:58:25Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-30T15:58:25Z",
  • "finishedAt": "2019-09-30T15:58:25Z",
  • "requestedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Retrieve a single run for a task

path Parameters
runID
required
string

The run ID.

+
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

The run record

default

Unexpected error

-
get /tasks/{taskID}/runs/{runID}
/api/v2/tasks/{taskID}/runs/{runID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-27T20:40:42Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-27T20:40:42Z",
  • "finishedAt": "2019-09-27T20:40:42Z",
  • "requestedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Cancel a running task

path Parameters
taskID
required
string

The task ID.

-
runID
required
string

The run ID.

+
get /tasks/{taskID}/runs/{runID}
/api/v2/tasks/{taskID}/runs/{runID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-30T15:58:25Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-30T15:58:25Z",
  • "finishedAt": "2019-09-30T15:58:25Z",
  • "requestedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Cancel a running task

path Parameters
runID
required
string

The run ID.

+
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

default

Unexpected error

-
delete /tasks/{taskID}/runs/{runID}
/api/v2/tasks/{taskID}/runs/{runID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retry a task run

path Parameters
taskID
required
string

The task ID.

-
runID
required
string

The run ID.

+
delete /tasks/{taskID}/runs/{runID}
/api/v2/tasks/{taskID}/runs/{runID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Retry a task run

path Parameters
runID
required
string

The run ID.

+
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

Run that has been queued

default

Unexpected error

-
post /tasks/{taskID}/runs/{runID}/retry
/api/v2/tasks/{taskID}/runs/{runID}/retry

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-27T20:40:42Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-27T20:40:42Z",
  • "finishedAt": "2019-09-27T20:40:42Z",
  • "requestedAt": "2019-09-27T20:40:42Z",
  • "links":
    {
    }
}

Retrieve all logs for a task

path Parameters
taskID
required
string

The task ID.

+
post /tasks/{taskID}/runs/{runID}/retry
/api/v2/tasks/{taskID}/runs/{runID}/retry

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "taskID": "string",
  • "status": "scheduled",
  • "scheduledFor": "2019-09-30T15:58:25Z",
  • "log":
    [
    ],
  • "startedAt": "2019-09-30T15:58:25Z",
  • "finishedAt": "2019-09-30T15:58:25Z",
  • "requestedAt": "2019-09-30T15:58:25Z",
  • "links":
    {
    }
}

Retrieve all logs for a task

path Parameters
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

All logs for a task

default

Unexpected error

-
get /tasks/{taskID}/logs
/api/v2/tasks/{taskID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "events":
    [
    ]
}

Retrieve all logs for a run

path Parameters
taskID
required
string

ID of task to get logs for.

-
runID
required
string

ID of run to get logs for.

+
get /tasks/{taskID}/logs
/api/v2/tasks/{taskID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "events":
    [
    ]
}

Retrieve all logs for a run

path Parameters
runID
required
string

ID of run to get logs for.

+
taskID
required
string

ID of task to get logs for.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

All logs for a run

default

Unexpected error

-
get /tasks/{taskID}/runs/{runID}/logs
/api/v2/tasks/{taskID}/runs/{runID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "events":
    [
    ]
}

List all labels for a task

path Parameters
taskID
required
string

The task ID.

+
get /tasks/{taskID}/runs/{runID}/logs
/api/v2/tasks/{taskID}/runs/{runID}/logs

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "events":
    [
    ]
}

List all labels for a task

path Parameters
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of all labels for a task

default

Unexpected error

@@ -1408,8 +1425,8 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

200

A list of all labels for a task

default

Unexpected error

-
post /tasks/{taskID}/labels
/api/v2/tasks/{taskID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a task

path Parameters
taskID
required
string

The task ID.

-
labelID
required
string

The label ID.

+
post /tasks/{taskID}/labels
/api/v2/tasks/{taskID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete a label from a task

path Parameters
labelID
required
string

The label ID.

+
taskID
required
string

The task ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Task not found

@@ -1423,8 +1440,8 @@ interval = "10s"<
Request Body schema: application/json

User to add as member

id
required
string
name
string

Responses

201

Added to task members

default

Unexpected error

-
post /tasks/{taskID}/members
/api/v2/tasks/{taskID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a task

path Parameters
userID
required
string

The ID of the member to remove.

-
taskID
required
string

The task ID.

+
post /tasks/{taskID}/members
/api/v2/tasks/{taskID}/members

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "member"
}

Remove a member from a task

path Parameters
taskID
required
string

The task ID.

+
userID
required
string

The ID of the member to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Member removed

default

Unexpected error

@@ -1437,55 +1454,55 @@ interval = "10s"<
Request Body schema: application/json

User to add as owner

id
required
string
name
string

Responses

201

Added to task owners

default

Unexpected error

-
post /tasks/{taskID}/owners
/api/v2/tasks/{taskID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a task

path Parameters
userID
required
string

The ID of the owner to remove.

-
taskID
required
string

The task ID.

+
post /tasks/{taskID}/owners
/api/v2/tasks/{taskID}/owners

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": "string",
  • "oauthID": "string",
  • "name": "string",
  • "status": "active",
  • "links":
    {
    },
  • "role": "owner"
}

Remove an owner from a task

path Parameters
taskID
required
string

The task ID.

+
userID
required
string

The ID of the owner to remove.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Owner removed

default

Unexpected error

-
delete /tasks/{taskID}/owners/{userID}
/api/v2/tasks/{taskID}/owners/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Checks

Get all checks

query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
orgID
required
string

Only show checks that belong to a specific organization ID.

+
delete /tasks/{taskID}/owners/{userID}
/api/v2/tasks/{taskID}/owners/{userID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}

Checks

Get all checks

query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
orgID
required
string

Only show checks that belong to a specific organization ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of checks

default

Unexpected error

-
get /checks
/api/v2/checks

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "checks":
    [
    ],
  • "links":
    {}
}

Add new check

Request Body schema: application/json

Check to create

-
name
required
string
orgID
required
string

The ID of the organization that owns this check.

-
query
required
object (DashboardQuery)
status
string (TaskStatusType)
Enum: "active" "inactive"
every
string

Check repetition interval.

-
offset
string

Duration to delay after the schedule, before executing check.

-
tags
Array of objects

List of tags to write to each status.

-
description
string

An optional description of the check.

-
statusMessageTemplate
string

The template used to generate and write a status message.

-
labels
Array of objects (Labels)
type
required
string
timeSince
string

String duration before deadman triggers.

+
get /checks
/api/v2/checks

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "checks":
    [
    ],
  • "links":
    {}
}

Add new check

Request Body schema: application/json

Check to create

+
description
string

An optional description of the check.

+
every
string

Check repetition interval.

+
labels
Array of objects (Labels)
level
string (CheckStatusLevel)
Enum: "UNKNOWN" "OK" "INFO" "CRIT" "WARN"

The state to record if check matches a criteria.

+
name
required
string
offset
string

Duration to delay after the schedule, before executing check.

+
orgID
required
string

The ID of the organization that owns this check.

+
query
required
object (DashboardQuery)
reportZero
boolean

If only zero values reported since time, trigger an alert

staleTime
string

String duration for time that a series is considered stale and should not trigger deadman.

-
reportZero
boolean

If only zero values reported since time, trigger an alert

-
level
string (CheckStatusLevel)
Enum: "UNKNOWN" "OK" "INFO" "CRIT" "WARN"

The state to record if check matches a criteria.

-

Responses

201

Check created

+
status
string (TaskStatusType)
Enum: "active" "inactive"
statusMessageTemplate
string

The template used to generate and write a status message.

+
tags
Array of objects

List of tags to write to each status.

+
timeSince
string

String duration before deadman triggers.

+
type
required
string

Responses

201

Check created

default

Unexpected error

-
post /checks
/api/v2/checks

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "name": "string",
  • "orgID": "string",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Get a check

path Parameters
checkID
required
string

The check ID.

+
post /checks
/api/v2/checks

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "name": "string",
  • "orgID": "string",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Get a check

path Parameters
checkID
required
string

The check ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

The check requested

default

Unexpected error

-
get /checks/{checkID}
/api/v2/checks/{checkID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Update a check

path Parameters
checkID
required
string

The check ID.

+
get /checks/{checkID}
/api/v2/checks/{checkID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Update a check

path Parameters
checkID
required
string

The check ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Check update to apply

-
name
required
string
orgID
required
string

The ID of the organization that owns this check.

-
query
required
object (DashboardQuery)
status
string (TaskStatusType)
Enum: "active" "inactive"
every
string

Check repetition interval.

-
offset
string

Duration to delay after the schedule, before executing check.

-
tags
Array of objects

List of tags to write to each status.

-
description
string

An optional description of the check.

-
statusMessageTemplate
string

The template used to generate and write a status message.

-
labels
Array of objects (Labels)
type
required
string
timeSince
string

String duration before deadman triggers.

+
description
string

An optional description of the check.

+
every
string

Check repetition interval.

+
labels
Array of objects (Labels)
level
string (CheckStatusLevel)
Enum: "UNKNOWN" "OK" "INFO" "CRIT" "WARN"

The state to record if check matches a criteria.

+
name
required
string
offset
string

Duration to delay after the schedule, before executing check.

+
orgID
required
string

The ID of the organization that owns this check.

+
query
required
object (DashboardQuery)
reportZero
boolean

If only zero values reported since time, trigger an alert

staleTime
string

String duration for time that a series is considered stale and should not trigger deadman.

-
reportZero
boolean

If only zero values reported since time, trigger an alert

-
level
string (CheckStatusLevel)
Enum: "UNKNOWN" "OK" "INFO" "CRIT" "WARN"

The state to record if check matches a criteria.

-

Responses

200

An updated check

+
status
string (TaskStatusType)
Enum: "active" "inactive"
statusMessageTemplate
string

The template used to generate and write a status message.

+
tags
Array of objects

List of tags to write to each status.

+
timeSince
string

String duration before deadman triggers.

+
type
required
string

Responses

200

An updated check

404

The check was not found

default

Unexpected error

-
put /checks/{checkID}
/api/v2/checks/{checkID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "name": "string",
  • "orgID": "string",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Update a check

path Parameters
checkID
required
string

The check ID.

+
put /checks/{checkID}
/api/v2/checks/{checkID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "name": "string",
  • "orgID": "string",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Update a check

path Parameters
checkID
required
string

The check ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Check update to apply

-
name
string
description
string
status
string
Enum: "active" "inactive"

Responses

200

An updated check

+
description
string
name
string
status
string
Enum: "active" "inactive"

Responses

200

An updated check

404

The check was not found

default

Unexpected error

-
patch /checks/{checkID}
/api/v2/checks/{checkID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Delete a check

path Parameters
checkID
required
string

The check ID.

+
patch /checks/{checkID}
/api/v2/checks/{checkID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "name": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "query":
    {
    },
  • "status": "active",
  • "every": "string",
  • "offset": "string",
  • "tags":
    [
    ],
  • "description": "string",
  • "statusMessageTemplate": "string",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "deadman",
  • "timeSince": "string",
  • "staleTime": "string",
  • "reportZero": true,
  • "level": "UNKNOWN"
}

Delete a check

path Parameters
checkID
required
string

The check ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

The check was not found

@@ -1511,50 +1528,50 @@ interval = "10s"<
400

Invalid request

404

Check not found

default

Unexpected error

-
get /checks/{checkID}/query
/api/v2/checks/{checkID}/query

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "flux": "string"
}

NotificationRules

Get all notification rules

query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
orgID
required
string

Only show notification rules that belong to a specific organization ID.

-
checkID
string

Only show notifications that belong to the specific check ID.

+
get /checks/{checkID}/query
/api/v2/checks/{checkID}/query

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "flux": "string"
}

NotificationRules

Get all notification rules

query Parameters
checkID
string

Only show notifications that belong to the specific check ID.

+
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
orgID
required
string

Only show notification rules that belong to a specific organization ID.

tag
string^[a-zA-Z0-9_]+:[a-zA-Z0-9_]+$
Example: tag=env%3Aprod

Only show notification rules that match a tag pair. Uses AND to specify multiple tags.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of notification rules

default

Unexpected error

-
get /notificationRules
/api/v2/notificationRules

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "notificationRules":
    [
    ],
  • "links":
    {}
}

Add a notification rule

Request Body schema: application/json

Notification rule to create

-
endpointID
required
string
orgID
required
string

The ID of the organization that owns this notification rule.

-
status
required
string (TaskStatusType)
Enum: "active" "inactive"
name
required
string

Human-readable name describing the notification rule.

-
sleepUntil
string
every
string

The notification repetition interval.

+
get /notificationRules
/api/v2/notificationRules

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "notificationRules":
    [
    ],
  • "links":
    {}
}

Add a notification rule

Request Body schema: application/json

Notification rule to create

+
channel
string
description
string

An optional description of the notification rule.

+
endpointID
required
string
every
string

The notification repetition interval.

+
labels
Array of objects (Labels)
limit
integer

Don't notify me more than times every seconds. If set, limitEvery cannot be empty.

+
limitEvery
integer

Don't notify me more than times every seconds. If set, limit cannot be empty.

+
messageTemplate
required
string
name
required
string

Human-readable name describing the notification rule.

offset
string

Duration to delay after the schedule, before executing check.

-
runbookLink
string
limitEvery
integer

Don't notify me more than times every seconds. If set, limit cannot be empty.

-
limit
integer

Don't notify me more than times every seconds. If set, limitEvery cannot be empty.

+
orgID
required
string

The ID of the organization that owns this notification rule.

+
runbookLink
string
sleepUntil
string
status
required
string (TaskStatusType)
Enum: "active" "inactive"
statusRules
required
Array of objects (StatusRule) non-empty

List of status rules the notification rule attempts to match.

tagRules
required
Array of objects (TagRule)

List of tag rules the notification rule attempts to match.

-
description
string

An optional description of the notification rule.

-
statusRules
required
Array of objects (StatusRule) non-empty

List of status rules the notification rule attempts to match.

-
labels
Array of objects (Labels)
type
required
string
channel
string
messageTemplate
required
string

Responses

201

Notification rule created

+
type
required
string

Responses

201

Notification rule created

default

Unexpected error

-
post /notificationRules
/api/v2/notificationRules

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "endpointID": "string",
  • "orgID": "string",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Get a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

+
post /notificationRules
/api/v2/notificationRules

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "endpointID": "string",
  • "orgID": "string",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Get a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

The notification rule requested

default

Unexpected error

-
get /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Update a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

+
get /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Update a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Notification rule update to apply

-
endpointID
required
string
orgID
required
string

The ID of the organization that owns this notification rule.

-
status
required
string (TaskStatusType)
Enum: "active" "inactive"
name
required
string

Human-readable name describing the notification rule.

-
sleepUntil
string
every
string

The notification repetition interval.

+
channel
string
description
string

An optional description of the notification rule.

+
endpointID
required
string
every
string

The notification repetition interval.

+
labels
Array of objects (Labels)
limit
integer

Don't notify me more than times every seconds. If set, limitEvery cannot be empty.

+
limitEvery
integer

Don't notify me more than times every seconds. If set, limit cannot be empty.

+
messageTemplate
required
string
name
required
string

Human-readable name describing the notification rule.

offset
string

Duration to delay after the schedule, before executing check.

-
runbookLink
string
limitEvery
integer

Don't notify me more than times every seconds. If set, limit cannot be empty.

-
limit
integer

Don't notify me more than times every seconds. If set, limitEvery cannot be empty.

+
orgID
required
string

The ID of the organization that owns this notification rule.

+
runbookLink
string
sleepUntil
string
status
required
string (TaskStatusType)
Enum: "active" "inactive"
statusRules
required
Array of objects (StatusRule) non-empty

List of status rules the notification rule attempts to match.

tagRules
required
Array of objects (TagRule)

List of tag rules the notification rule attempts to match.

-
description
string

An optional description of the notification rule.

-
statusRules
required
Array of objects (StatusRule) non-empty

List of status rules the notification rule attempts to match.

-
labels
Array of objects (Labels)
type
required
string
channel
string
messageTemplate
required
string

Responses

200

An updated notification rule

+
type
required
string

Responses

200

An updated notification rule

404

The notification rule was not found

default

Unexpected error

-
put /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "endpointID": "string",
  • "orgID": "string",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Update a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

+
put /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "endpointID": "string",
  • "orgID": "string",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Update a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Notification rule update to apply

-
name
string
description
string
status
string
Enum: "active" "inactive"

Responses

200

An updated notification rule

+
description
string
name
string
status
string
Enum: "active" "inactive"

Responses

200

An updated notification rule

404

The notification rule was not found

default

Unexpected error

-
patch /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Delete a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

+
patch /notificationRules/{ruleID}
/api/v2/notificationRules/{ruleID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "endpointID": "string",
  • "orgID": "string",
  • "ownerID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "status": "active",
  • "name": "string",
  • "sleepUntil": "string",
  • "every": "string",
  • "offset": "string",
  • "runbookLink": "string",
  • "limitEvery": 0,
  • "limit": 0,
  • "tagRules":
    [
    ],
  • "description": "string",
  • "statusRules":
    [
    ],
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "channel": "string",
  • "messageTemplate": "string"
}

Delete a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

The check was not found

@@ -1568,8 +1585,8 @@ interval = "10s"<
Request Body schema: application/json

Label to add

labelID
string

Responses

201

The label was added to the notification rule

default

Unexpected error

-
post /notificationRules/{ruleID}/labels
/api/v2/notificationRules/{ruleID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete label from a notification rule

path Parameters
ruleID
required
string

The notification rule ID.

-
labelID
required
string

The ID of the label to delete.

+
post /notificationRules/{ruleID}/labels
/api/v2/notificationRules/{ruleID}/labels

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "labelID": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{}

Delete label from a notification rule

path Parameters
labelID
required
string

The ID of the label to delete.

+
ruleID
required
string

The notification rule ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

Rule or label not found

@@ -1580,38 +1597,38 @@ interval = "10s"<
400

Invalid request

404

Notification rule not found

default

Unexpected error

-
get /notificationRules/{ruleID}/query
/api/v2/notificationRules/{ruleID}/query

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "flux": "string"
}

NotificationEndpoints

Get all notification endpoints

query Parameters
offset
integer >= 0
limit
integer [ 1 .. 100 ]
Default: 20
orgID
required
string

Only show notification endpoints that belong to specific organization ID.

+
get /notificationRules/{ruleID}/query
/api/v2/notificationRules/{ruleID}/query

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "flux": "string"
}

NotificationEndpoints

Get all notification endpoints

query Parameters
limit
integer [ 1 .. 100 ]
Default: 20
offset
integer >= 0
orgID
required
string

Only show notification endpoints that belong to specific organization ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

A list of notification endpoints

default

Unexpected error

-
get /notificationEndpoints
/api/v2/notificationEndpoints

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "notificationEndpoints":
    [
    ],
  • "links":
    {}
}

Add a notification endpoint

Request Body schema: application/json

Notification endpoint to create

-
id
string
orgID
string
userID
string
description
string

An optional description of the notification endpoint.

-
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

The status of the endpoint.

-
labels
Array of objects (Labels)
type
required
string (NotificationEndpointType)
url
string

Specifies the URL of the Slack endpoint. Specify either URL or Token.

-
token
string

Specifies the API token string. Specify either URL or Token.

-

Responses

201

Notification endpoint created

+
get /notificationEndpoints
/api/v2/notificationEndpoints

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "notificationEndpoints":
    [
    ],
  • "links":
    {}
}

Add a notification endpoint

Request Body schema: application/json

Notification endpoint to create

+
description
string

An optional description of the notification endpoint.

+
id
string
labels
Array of objects (Labels)
name
required
string
orgID
string
status
string
Default: "active"
Enum: "active" "inactive"

The status of the endpoint.

+
token
string

Specifies the API token string. Specify either URL or Token.

+
type
required
string (NotificationEndpointType)
url
string

Specifies the URL of the Slack endpoint. Specify either URL or Token.

+
userID
string

Responses

201

Notification endpoint created

default

Unexpected error

-
post /notificationEndpoints
/api/v2/notificationEndpoints

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Get a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

+
post /notificationEndpoints
/api/v2/notificationEndpoints

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Get a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

200

The notification endpoint requested

default

Unexpected error

-
get /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Update a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

+
get /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Update a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

A new notification endpoint to replace the existing endpoint with

-
id
string
orgID
string
userID
string
description
string

An optional description of the notification endpoint.

-
name
required
string
status
string
Default: "active"
Enum: "active" "inactive"

The status of the endpoint.

-
labels
Array of objects (Labels)
type
required
string (NotificationEndpointType)
url
string

Specifies the URL of the Slack endpoint. Specify either URL or Token.

-
token
string

Specifies the API token string. Specify either URL or Token.

-

Responses

200

An updated notification endpoint

+
description
string

An optional description of the notification endpoint.

+
id
string
labels
Array of objects (Labels)
name
required
string
orgID
string
status
string
Default: "active"
Enum: "active" "inactive"

The status of the endpoint.

+
token
string

Specifies the API token string. Specify either URL or Token.

+
type
required
string (NotificationEndpointType)
url
string

Specifies the URL of the Slack endpoint. Specify either URL or Token.

+
userID
string

Responses

200

An updated notification endpoint

404

The notification endpoint was not found

default

Unexpected error

-
put /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Update a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

+
put /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Update a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Request Body schema: application/json

Check update to apply

-
name
string
description
string
status
string
Enum: "active" "inactive"

Responses

200

An updated notification endpoint

+
description
string
name
string
status
string
Enum: "active" "inactive"

Responses

200

An updated notification endpoint

404

The notification endpoint was not found

default

Unexpected error

-
patch /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-27T20:40:42Z",
  • "updatedAt": "2019-09-27T20:40:42Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Delete a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

+
patch /notificationEndpoints/{endpointID}
/api/v2/notificationEndpoints/{endpointID}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "name": "string",
  • "description": "string",
  • "status": "active"
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "id": "string",
  • "orgID": "string",
  • "userID": "string",
  • "createdAt": "2019-09-30T15:58:25Z",
  • "updatedAt": "2019-09-30T15:58:25Z",
  • "description": "string",
  • "name": "string",
  • "status": "active",
  • "labels":
    [
    ],
  • "links":
    {
    },
  • "type": "slack",
  • "url": "string",
  • "token": "string"
}

Delete a notification endpoint

path Parameters
endpointID
required
string

The notification endpoint ID.

header Parameters
Zap-Trace-Span
string
Example: trace_id,1,span_id,1,baggage,[object Object]

OpenTracing span context

Responses

204

Delete has been accepted

404

The endpoint was not found

@@ -1633,12 +1650,23 @@ interval = "10s"<
default

Unexpected error

delete /notificationEndpoints/{endpointID}/labels/{labelID}
/api/v2/notificationEndpoints/{endpointID}/labels/{labelID}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "code": "internal error",
  • "message": "string"
}
+ diff --git a/content/v2.0/reference/api.md b/content/v2.0/reference/api.md index 62352ca3a..22c9426f1 100644 --- a/content/v2.0/reference/api.md +++ b/content/v2.0/reference/api.md @@ -22,8 +22,13 @@ curl --request GET \ ``` ## View Influx v2 API Documentation -Full InfluxDB v2 API documentation is built into the `influxd` service. -To view the API documentation, [start InfluxDB](/v2.0/get-started/#start-influxdb) + +InfluxDB v2.0 API documentation + +### View InfluxDB API documentation locally +InfluxDB API documentation is built into the `influxd` service and represents +the API specific to the current version of InfluxDB. +To view the API documentation locally, [start InfluxDB](/v2.0/get-started/#start-influxdb) and visit the `/docs` endpoint in a browser. localhost:9999/docs diff --git a/layouts/partials/header/stylesheets.html b/layouts/partials/header/stylesheets.html index 4300db76f..fe39ab799 100644 --- a/layouts/partials/header/stylesheets.html +++ b/layouts/partials/header/stylesheets.html @@ -5,6 +5,7 @@ {{ $cssOptionsLight := (dict "targetPath" "light-theme.css" "outputStyle" "compressed" "enableSourceMap" true) }} {{ $cssSidebarOpen := (dict "targetPath" "sidebar-open.css" "outputStyle" "compressed" "enableSourceMap" true) }} {{ $cssSidebarClose := (dict "targetPath" "sidebar-closed.css" "outputStyle" "compressed" "enableSourceMap" true) }} +{{ $cssAPIOverrides := (dict "targetPath" "api.css" "outputStyle" "compressed" "enableSourceMap" true) }} {{ $PostCSSOptions := (dict "use" "autoprefixer" "noMap" false) }} {{ $stylesLight := resources.Get "styles/styles-default.scss" | toCSS $cssOptionsLight | postCSS $PostCSSOptions | fingerprint }} @@ -18,3 +19,6 @@ {{ $stylesSidebarClosed := resources.Get "styles/sidebar-closed.scss" | toCSS $cssOptionsLight | postCSS $PostCSSOptions | fingerprint }} + +{{ $stylesAPIOverrides := resources.Get "styles/styles-api.scss" | toCSS $cssAPIOverrides | postCSS $PostCSSOptions }} +