diff --git a/.gitignore b/.gitignore
index 43643aa4e..f4923ef05 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,3 +6,4 @@ node_modules
*.log
/resources
/content/influxdb/*/api/*.html
+/api-docs/redoc-static.html*
diff --git a/api-docs/cloud/swagger.yml b/api-docs/cloud/swagger.yml
index c91440315..c12bd6104 100644
--- a/api-docs/cloud/swagger.yml
+++ b/api-docs/cloud/swagger.yml
@@ -5,7 +5,7 @@ info:
description: |
The InfluxDB v2 API provides a programmatic interface for all interactions with InfluxDB. Access the InfluxDB API using the `/api/v2/` endpoint.
servers:
- - url: /api/v2
+- url: "/"
tags:
- name: Authentication
description: |
@@ -35,8 +35,9 @@ tags:
| `204` | No content | For a `POST` request, `204` indicates that InfluxDB accepted the request and request data is valid. Asynchronous operations, such as `write`, might not have completed yet. |
| `400` | Bad request | `Authorization` header is missing or malformed or the API token does not have permission for the operation. |
| `401` | Unauthorized | May indicate one of the following:
`Authorization: Token` header is missing or malformedAPI token value is missing from the headerAPI token does not have permission. For more information about token types and permissions, see [Manage API tokens](https://docs.influxdata.com/influxdb/cloud/security/tokens/) |
- | `404` | Not found | Requested resource was not found. `message` in the response body contains details about the requested resource. |
+ | `404` | Not found | Requested resource was not found. `message` in the response body provides details about the requested resource. |
| `413` | Request entity too large | Request payload exceeds the size limit. |
+ | `422` | Unprocessible entity | Request data is invalid. `code` and `message` in the response body provide details about the problem. |
| `429` | Too many requests | API token is temporarily over the request quota. The `Retry-After` header describes when to try the request again. |
| `500` | Internal server error | |
| `503` | Service unavailable | Server is temporarily unavailable to process the request. The `Retry-After` header describes when to try the request again. |
@@ -64,6 +65,7 @@ x-tagGroups:
- Buckets
- Dashboards
- Tasks
+ - Resources
- name: Security and access endpoints
tags:
- Authorizations
@@ -75,6 +77,7 @@ x-tagGroups:
- Routes
- name: All endpoints
tags:
+ - Annotations
- Authorizations
- Buckets
- Cells
@@ -83,6 +86,7 @@ x-tagGroups:
- Dashboards
- Delete
- DemoDataBuckets
+ - Invocable Scripts
- Labels
- Limits
- NotificationEndpoints
@@ -92,14 +96,16 @@ x-tagGroups:
- Ping
- Public Flags
- Query
+ - Resources
- Routes
- Rules
- Secrets
- Setup
- Signin
- Signout
- - Sources
+ - Streams
- Tasks
+ - Telegraf Plugins
- Telegrafs
- Templates
- Usage
@@ -107,2117 +113,3679 @@ x-tagGroups:
- Variables
- Write
paths:
- /signin:
- post:
- operationId: PostSignin
- summary: Create a user session.
- description: 'Authenticates ***Basic Auth*** credentials for a user. If successful, creates a new UI session for the user.'
- tags:
- - Signin
- security:
- - BasicAuthentication: []
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- responses:
- '204':
- description: Success. User authenticated.
- '401':
- description: Unauthorized access.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '403':
- description: User account is disabled.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unsuccessful authentication.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /signout:
- post:
- operationId: PostSignout
- summary: Expire the current UI session
- tags:
- - Signout
- description: Expires the current UI session for the user.
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- responses:
- '204':
- description: Session successfully expired
- '401':
- description: Unauthorized access
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unsuccessful session expiry
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /ping:
- get:
- operationId: GetPing
- summary: Checks the status of InfluxDB instance and version of InfluxDB.
- servers:
- - url: ''
- tags:
- - Ping
- responses:
- '204':
- description: OK
- headers:
- X-Influxdb-Build:
- schema:
- type: string
- description: The type of InfluxDB build.
- X-Influxdb-Version:
- schema:
- type: integer
- description: The version of InfluxDB.
- head:
- operationId: HeadPing
- summary: Checks the status of InfluxDB instance and version of InfluxDB.
- servers:
- - url: ''
- tags:
- - Ping
- responses:
- '204':
- description: OK
- headers:
- X-Influxdb-Build:
- schema:
- type: string
- description: The type of InfluxDB build.
- X-Influxdb-Version:
- schema:
- type: integer
- description: The version of InfluxDB.
- /:
+ /api/v2/:
get:
operationId: GetRoutes
- summary: List all top level routes
- tags:
- - Routes
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
responses:
default:
- description: All routes
content:
application/json:
schema:
$ref: '#/components/schemas/Routes'
- /documents/templates:
- get:
- operationId: GetDocumentsTemplates
+ description: All routes
+ summary: List all top level routes
tags:
- - Templates
- summary: List all templates
+ - Routes
+ /api/v2/authorizations:
+ get:
+ operationId: GetAuthorizations
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: org
- description: Specifies the name of the organization of the template.
- schema:
- type: string
- - in: query
- name: orgID
- description: Specifies the organization ID of the template.
- schema:
- type: string
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Only show authorizations that belong to a user ID.
+ in: query
+ name: userID
+ schema:
+ type: string
+ - description: Only show authorizations that belong to a user name.
+ in: query
+ name: user
+ schema:
+ type: string
+ - description: Only show authorizations that belong to an organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Only show authorizations that belong to a organization name.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: Find a token by value.
+ in: query
+ name: token
+ schema:
+ type: string
responses:
- '200':
- description: A list of template documents
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/Documents'
+ $ref: '#/components/schemas/Authorizations'
+ description: A list of authorizations
default:
+ $ref: '#/components/responses/ServerError'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ summary: List all authorizations
+ tags:
+ - Authorizations
post:
- operationId: PostDocumentsTemplates
- tags:
- - Templates
- summary: Create a template
+ operationId: PostAuthorizations
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
- description: Template that will be created
- required: true
content:
application/json:
schema:
- $ref: '#/components/schemas/DocumentCreate'
- responses:
- '201':
- description: Template created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Document'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/documents/templates/{templateID}':
- get:
- operationId: GetDocumentsTemplatesID
- tags:
- - Templates
- summary: Retrieve a template
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- responses:
- '200':
- description: The template requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Document'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- put:
- operationId: PutDocumentsTemplatesID
- tags:
- - Templates
- summary: Update a template
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- requestBody:
- description: Template that will be updated
+ $ref: '#/components/schemas/Authorization'
+ description: Authorization to create
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DocumentUpdate'
responses:
- '200':
- description: The newly updated template
+ "201":
content:
application/json:
schema:
- $ref: '#/components/schemas/Document'
+ $ref: '#/components/schemas/Authorization'
+ description: Authorization created
+ "400":
+ $ref: '#/components/responses/ServerError'
+ description: Invalid request
default:
+ $ref: '#/components/responses/ServerError'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ summary: Create an authorization
+ tags:
+ - Authorizations
+ /api/v2/authorizations/{authID}:
delete:
- operationId: DeleteDocumentsTemplatesID
- tags:
- - Templates
- summary: Delete a template
+ operationId: DeleteAuthorizationsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- responses:
- '204':
- description: Delete has been accepted
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/documents/templates/{templateID}/labels':
- get:
- operationId: GetDocumentsTemplatesIDLabels
- tags:
- - Templates
- summary: List all labels for a template
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- responses:
- '200':
- description: A list of all labels for a template
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostDocumentsTemplatesIDLabels
- tags:
- - Templates
- summary: Add a label to a template
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- requestBody:
- description: Label to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The identifier of the authorization to delete.
+ in: path
+ name: authID
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
+ schema:
+ type: string
responses:
- '201':
- description: The label added to the template
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
+ "204":
+ description: Authorization deleted
default:
+ $ref: '#/components/responses/ServerError'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/documents/templates/{templateID}/labels/{labelID}':
- delete:
- operationId: DeleteDocumentsTemplatesIDLabelsID
+ summary: Delete an authorization
tags:
- - Templates
- summary: Delete a label from a template
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: templateID
- schema:
- type: string
- required: true
- description: The template ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The label ID.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Template not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /dbrps:
+ - Authorizations
get:
- operationId: GetDBRPs
- tags:
- - DBRPs
- summary: List database retention policy mappings
+ operationId: GetAuthorizationsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: Specifies the organization ID to filter on
- schema:
- type: string
- - in: query
- name: org
- description: Specifies the organization name to filter on
- schema:
- type: string
- - in: query
- name: id
- description: Specifies the mapping ID to filter on
- schema:
- type: string
- - in: query
- name: bucketID
- description: Specifies the bucket ID to filter on
- schema:
- type: string
- - in: query
- name: default
- description: Specifies filtering on default
- schema:
- type: boolean
- - in: query
- name: db
- description: Specifies the database to filter on
- schema:
- type: string
- - in: query
- name: rp
- description: Specifies the retention policy to filter on
- schema:
- type: string
- responses:
- '200':
- description: Success. Returns a list of database retention policy mappings.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DBRPs'
- '400':
- description: Bad request. The request has one or more invalid parameters.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostDBRP
- tags:
- - DBRPs
- summary: Add a database retention policy mapping
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: The database retention policy mapping to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The identifier of the authorization to get.
+ in: path
+ name: authID
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DBRPCreate'
+ schema:
+ type: string
responses:
- '201':
- description: Created. Returns the created database retention policy mapping.
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/DBRP'
- '400':
- description: Bad request. The mapping in the request has one or more invalid IDs.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ $ref: '#/components/schemas/Authorization'
+ description: Authorization details
default:
+ $ref: '#/components/responses/ServerError'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/dbrps/{dbrpID}':
- get:
- operationId: GetDBRPsID
+ summary: Retrieve an authorization
tags:
- - DBRPs
- summary: Retrieve a database retention policy mapping
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: Specifies the organization ID of the mapping
- schema:
- type: string
- - in: query
- name: org
- description: Specifies the organization name of the mapping
- schema:
- type: string
- - in: path
- name: dbrpID
- schema:
- type: string
- required: true
- description: The database retention policy mapping ID
- responses:
- '200':
- description: The database retention policy requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DBRPGet'
- '400':
- description: if any of the IDs passed is invalid
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ - Authorizations
patch:
- operationId: PatchDBRPID
- tags:
- - DBRPs
- summary: Update a database retention policy mapping
- requestBody:
- description: Database retention policy update to apply
+ description: Update an authorization's status to `active` or `inactive`.
+ operationId: PatchAuthorizationsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The identifier of the authorization to update.
+ in: path
+ name: authID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
- $ref: '#/components/schemas/DBRPUpdate'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: Specifies the organization ID of the mapping
- schema:
- type: string
- - in: query
- name: org
- description: Specifies the organization name of the mapping
- schema:
- type: string
- - in: path
- name: dbrpID
- schema:
- type: string
- required: true
- description: The database retention policy mapping.
+ $ref: '#/components/schemas/AuthorizationUpdateRequest'
+ description: The updated Authorization object.
+ required: true
responses:
- '200':
- description: An updated mapping
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/DBRPGet'
- '400':
- description: if any of the IDs passed is invalid
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '404':
- description: The mapping was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ $ref: '#/components/schemas/Authorization'
+ description: The updated authorization.
default:
+ $ref: '#/components/responses/ServerError'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteDBRPID
+ summary: Update authorization status
tags:
- - DBRPs
- summary: Delete a database retention policy
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: Specifies the organization ID of the mapping
- schema:
- type: string
- - in: query
- name: org
- description: Specifies the organization name of the mapping
- schema:
- type: string
- - in: path
- name: dbrpID
- schema:
- type: string
- required: true
- description: The database retention policy mapping
- responses:
- '204':
- description: Delete has been accepted
- '400':
- description: if any of the IDs passed is invalid
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /telegraf/plugins:
+ - Authorizations
+ /api/v2/buckets:
get:
- operationId: GetTelegrafPlugins
- tags:
- - Telegraf Plugins
- summary: List all Telegraf plugins
+ operationId: GetBuckets
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: type
- description: The type of plugin desired.
- schema:
- type: string
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Limit'
+ - $ref: '#/components/parameters/After'
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Only returns buckets with a specific name.
+ in: query
+ name: name
+ schema:
+ type: string
+ - description: Only returns buckets with a specific ID.
+ in: query
+ name: id
+ schema:
+ type: string
responses:
- '200':
- description: A list of Telegraf plugins.
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/TelegrafPlugins'
+ $ref: '#/components/schemas/Buckets'
+ description: A list of buckets
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /telegrafs:
- get:
- operationId: GetTelegrafs
- tags:
- - Telegrafs
- summary: List all Telegraf configurations
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: The organization ID the Telegraf config belongs to.
- schema:
- type: string
- responses:
- '200':
- description: A list of Telegraf configurations
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Telegrafs'
- default:
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ summary: List all buckets
+ tags:
+ - Buckets
post:
- operationId: PostTelegrafs
- tags:
- - Telegrafs
- summary: Create a Telegraf configuration
+ operationId: PostBuckets
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
- description: Telegraf configuration to create
- required: true
content:
application/json:
schema:
- $ref: '#/components/schemas/TelegrafRequest'
- responses:
- '201':
- description: Telegraf configuration created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Telegraf'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}':
- get:
- operationId: GetTelegrafsID
- tags:
- - Telegrafs
- summary: Retrieve a Telegraf configuration
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf configuration ID.
- - in: header
- name: Accept
- required: false
- schema:
- type: string
- default: application/toml
- enum:
- - application/toml
- - application/json
- - application/octet-stream
- responses:
- '200':
- description: Telegraf configuration details
- content:
- application/toml:
- example: |-
- [agent]
- interval = "10s"
- schema:
- type: string
- application/json:
- schema:
- $ref: '#/components/schemas/Telegraf'
- application/octet-stream:
- example: |-
- [agent]
- interval = "10s"
- schema:
- type: string
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- put:
- operationId: PutTelegrafsID
- tags:
- - Telegrafs
- summary: Update a Telegraf configuration
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
- requestBody:
- description: Telegraf configuration update to apply
+ $ref: '#/components/schemas/PostBucketRequest'
+ description: Bucket to create
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/TelegrafRequest'
responses:
- '200':
- description: An updated Telegraf configurations
+ "201":
content:
application/json:
schema:
- $ref: '#/components/schemas/Telegraf'
- default:
- description: Unexpected error
+ $ref: '#/components/schemas/Bucket'
+ description: Bucket created
+ "422":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Request body failed validation
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Create a bucket
+ tags:
+ - Buckets
+ /api/v2/buckets/{bucketID}:
delete:
- operationId: DeleteTelegrafsID
- tags:
- - Telegrafs
- summary: Delete a Telegraf configuration
+ operationId: DeleteBucketsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf configuration ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the bucket to delete.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Delete has been accepted
- default:
- description: Unexpected error
+ "404":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/labels':
- get:
- operationId: GetTelegrafsIDLabels
+ description: Bucket not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a bucket
tags:
- - Telegrafs
- summary: List all labels for a Telegraf config
+ - Buckets
+ get:
+ operationId: GetBucketsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of all labels for a Telegraf config
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Bucket'
+ description: Bucket details
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a bucket
+ tags:
+ - Buckets
+ patch:
+ operationId: PatchBucketsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PatchBucketRequest'
+ description: Bucket update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Bucket'
+ description: An updated bucket
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a bucket
+ tags:
+ - Buckets
+ /api/v2/buckets/{bucketID}/labels:
+ get:
+ operationId: GetBucketsIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a bucket
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- post:
- operationId: PostTelegrafsIDLabels
+ description: Unexpected error
+ summary: List all labels for a bucket
tags:
- - Telegrafs
- summary: Add a label to a Telegraf config
+ - Buckets
+ post:
+ operationId: PostBucketsIDLabels
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
- requestBody:
- description: Label to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
responses:
- '201':
- description: The label added to the Telegraf config
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelResponse'
+ description: The newly added label
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/labels/{labelID}':
+ description: Unexpected error
+ summary: Add a label to a bucket
+ tags:
+ - Buckets
+ /api/v2/buckets/{bucketID}/labels/{labelID}:
delete:
- operationId: DeleteTelegrafsIDLabelsID
- tags:
- - Telegrafs
- summary: Delete a label from a Telegraf config
+ operationId: DeleteBucketsIDLabelsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The label ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Delete has been accepted
- '404':
- description: Telegraf config not found
+ "404":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Bucket not found
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/members':
- get:
- operationId: GetTelegrafsIDMembers
+ description: Unexpected error
+ summary: Delete a label from a bucket
tags:
- - Telegrafs
- summary: List all users with member privileges for a Telegraf config
+ - Buckets
+ /api/v2/buckets/{bucketID}/members:
+ get:
+ operationId: GetBucketsIDMembers
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of Telegraf config members
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceMembers'
+ description: A list of bucket members
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- post:
- operationId: PostTelegrafsIDMembers
+ description: Unexpected error
+ summary: List all users with member privileges for a bucket
tags:
- - Telegrafs
- summary: Add a member to a Telegraf config
+ - Buckets
+ post:
+ operationId: PostBucketsIDMembers
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
- requestBody:
- description: User to add as member
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as member
+ required: true
responses:
- '201':
- description: Member added to Telegraf config
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceMember'
+ description: Member added to bucket
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/members/{userID}':
- delete:
- operationId: DeleteTelegrafsIDMembersID
+ description: Unexpected error
+ summary: Add a member to a bucket
tags:
- - Telegrafs
- summary: Remove a member from a Telegraf config
+ - Buckets
+ /api/v2/buckets/{bucketID}/members/{userID}:
+ delete:
+ operationId: DeleteBucketsIDMembersID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the member to remove.
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the member to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Member removed
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/owners':
- get:
- operationId: GetTelegrafsIDOwners
+ description: Unexpected error
+ summary: Remove a member from a bucket
tags:
- - Telegrafs
- summary: List all owners of a Telegraf configuration
+ - Buckets
+ /api/v2/buckets/{bucketID}/owners:
+ get:
+ operationId: GetBucketsIDOwners
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf configuration ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: Returns Telegraf configuration owners as a ResourceOwners list
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceOwners'
+ description: A list of bucket owners
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- post:
- operationId: PostTelegrafsIDOwners
+ description: Unexpected error
+ summary: List all owners of a bucket
tags:
- - Telegrafs
- summary: Add an owner to a Telegraf configuration
+ - Buckets
+ post:
+ operationId: PostBucketsIDOwners
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf configuration ID.
- requestBody:
- description: User to add as owner
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The bucket ID.
+ in: path
+ name: bucketID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as owner
+ required: true
responses:
- '201':
- description: Telegraf configuration owner was added. Returns a ResourceOwner that references the User.
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceOwner'
+ description: Bucket owner added
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/telegrafs/{telegrafID}/owners/{userID}':
- delete:
- operationId: DeleteTelegrafsIDOwnersID
+ description: Unexpected error
+ summary: Add an owner to a bucket
tags:
- - Telegrafs
- summary: Remove an owner from a Telegraf config
+ - Buckets
+ /api/v2/buckets/{bucketID}/owners/{userID}:
+ delete:
+ operationId: DeleteBucketsIDOwnersID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the owner to remove.
- - in: path
- name: telegrafID
- schema:
- type: string
- required: true
- description: The Telegraf config ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the owner to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The bucket ID.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Owner removed
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/variables/{variableID}/labels':
- get:
- operationId: GetVariablesIDLabels
+ description: Unexpected error
+ summary: Remove an owner from a bucket
tags:
- - Variables
- summary: List all labels for a variable
+ - Buckets
+ /api/v2/buckets/{bucketID}/schema/measurements:
+ get:
+ operationId: getMeasurementSchemas
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- schema:
- type: string
- required: true
- description: The variable ID.
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The name of the measurement to return schemas for.
+ in: query
+ name: name
+ schema:
+ type: string
+ - description: The identifier of the bucket.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of all labels for a variable
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchemaList'
+ description: A list of measurement schemas returning summary information.
+ headers:
+ ETag:
+ description: The current version of the bucket schema
+ schema:
+ type: string
+ "404":
+ $ref: '#/components/responses/ServerError'
+ description: Bucket not found
+ summary: List all measurement schemas of a bucket
+ tags:
+ - Bucket Schemas
+ post:
+ operationId: createMeasurementSchema
+ parameters:
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The identifier of the bucket.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchemaCreateRequest'
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchema'
+ description: The created measurement schema.
+ headers:
+ ETag:
+ description: The current version of the measurement schema
+ schema:
+ type: string
+ "400":
+ content:
+ application/json:
+ examples:
+ badNameExample:
+ description: The error returned when the name is invalid, such as
+ too few or too many characters or the name contains non-printable
+ ASCII or is not valid UTF-8.
+ summary: Invalid name
+ value:
+ code: invalid
+ message: name is invalid
+ duplicateColumnNamesExample:
+ description: The error returned when the request body contains duplicate
+ column names.
+ summary: Duplicate column names
+ value:
+ code: invalid
+ message: Duplicate column names
+ missingColumnsExample:
+ description: The error returned when the request body is missing
+ the columns property.
+ summary: Missing columns
+ value:
+ code: invalid
+ message: columns is required
+ missingFieldExample:
+ description: The error returned when the request body is missing
+ at least one field type column.
+ summary: Missing field
+ value:
+ code: invalid
+ message: At least one field column is required
+ missingTimestampExample:
+ description: The error returned when the request body is missing
+ a timestamp type column.
+ summary: Missing timestamp
+ value:
+ code: invalid
+ message: Timestamp column is required
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Client error with create request
+ summary: Create a measurement schema for a bucket
+ tags:
+ - Bucket Schemas
+ summary: Bucket schemas
+ /api/v2/buckets/{bucketID}/schema/measurements/{measurementID}:
+ get:
+ operationId: getMeasurementSchema
+ parameters:
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The identifier of the bucket.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ - description: The identifier of the measurement.
+ in: path
+ name: measurementID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchema'
+ description: Schema definition for a single measurement
+ headers:
+ ETag:
+ description: The current version of the measurement schema
+ schema:
+ type: string
+ summary: Retrieve measurement schema information
+ tags:
+ - Bucket Schemas
+ patch:
+ operationId: updateMeasurementSchema
+ parameters:
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The identifier of the bucket.
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ - description: The identifier of the measurement.
+ in: path
+ name: measurementID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchemaUpdateRequest'
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/MeasurementSchema'
+ description: The updated measurement schema
+ "400":
+ content:
+ application/json:
+ examples:
+ missingColumnsExample:
+ description: The error returned when the request body does not contain
+ all the columns from the source.
+ summary: Deleted columns
+ value:
+ code: invalid
+ message: Unable to delete columns from schema
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Client error updating measurement schema
+ summary: Update a measurement schema
+ tags:
+ - Bucket Schemas
+ summary: Bucket Schema
+ /api/v2/checks:
+ get:
+ operationId: GetChecks
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Limit'
+ - description: Only show checks that belong to a specific organization ID.
+ in: query
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Checks'
+ description: A list of checks
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all checks
+ tags:
+ - Checks
+ post:
+ operationId: CreateCheck
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PostCheck'
+ description: Check to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Check'
+ description: Check created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add new check
+ tags:
+ - Checks
+ /api/v2/checks/{checkID}:
+ delete:
+ operationId: DeleteChecksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The check was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a check
+ tags:
+ - Checks
+ get:
+ operationId: GetChecksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Check'
+ description: The check requested
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a check
+ tags:
+ - Checks
+ patch:
+ operationId: PatchChecksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/CheckPatch'
+ description: Check update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Check'
+ description: An updated check
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The check was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a check
+ tags:
+ - Checks
+ put:
+ operationId: PutChecksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Check'
+ description: Check update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Check'
+ description: An updated check
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The check was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a check
+ tags:
+ - Checks
+ /api/v2/checks/{checkID}/labels:
+ get:
+ operationId: GetChecksIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a check
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- post:
- operationId: PostVariablesIDLabels
+ description: Unexpected error
+ summary: List all labels for a check
tags:
- - Variables
- summary: Add a label to a variable
+ - Checks
+ post:
+ operationId: PostChecksIDLabels
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- schema:
- type: string
- required: true
- description: The variable ID.
- requestBody:
- description: Label to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
responses:
- '201':
- description: The newly added label
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelResponse'
+ description: The label was added to the check
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/variables/{variableID}/labels/{labelID}':
+ description: Unexpected error
+ summary: Add a label to a check
+ tags:
+ - Checks
+ /api/v2/checks/{checkID}/labels/{labelID}:
delete:
- operationId: DeleteVariablesIDLabelsID
- tags:
- - Variables
- summary: Delete a label from a variable
+ operationId: DeleteChecksIDLabelsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- schema:
- type: string
- required: true
- description: The variable ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The label ID to delete.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Delete has been accepted
- '404':
- description: Variable not found
+ "404":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Check or label not found
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /delete:
+ description: Unexpected error
+ summary: Delete label from a check
+ tags:
+ - Checks
+ /api/v2/checks/{checkID}/query:
+ get:
+ operationId: GetChecksIDQuery
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The check ID.
+ in: path
+ name: checkID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/FluxResponse'
+ description: The check query requested
+ "400":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Invalid request
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Check not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a check query
+ tags:
+ - Checks
+ /api/v2/dashboards:
+ get:
+ operationId: GetDashboards
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Descending'
+ - description: The non-zero number of dashboards to return
+ in: query
+ name: limit
+ schema:
+ default: 20
+ maximum: 100
+ minimum: -1
+ type: integer
+ - description: A user identifier. Returns only dashboards where this user has
+ the `owner` role.
+ in: query
+ name: owner
+ schema:
+ type: string
+ - description: The column to sort by.
+ in: query
+ name: sortBy
+ schema:
+ enum:
+ - ID
+ - CreatedAt
+ - UpdatedAt
+ type: string
+ - description: A list of dashboard identifiers. Returns only the listed dashboards.
+ If both `id` and `owner` are specified, only `id` is used.
+ in: query
+ name: id
+ schema:
+ items:
+ type: string
+ type: array
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Dashboards'
+ description: All dashboards
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all dashboards
+ tags:
+ - Dashboards
post:
- operationId: PostDelete
- tags:
- - Delete
- summary: Delete data
+ operationId: PostDashboards
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
- description: Deletes data from an InfluxDB bucket.
- required: true
content:
application/json:
schema:
- $ref: '#/components/schemas/DeletePredicateRequest'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: org
- description: Specifies the organization to delete data from.
- schema:
- type: string
- description: Only points from this organization are deleted.
- - in: query
- name: bucket
- description: Specifies the bucket to delete data from.
- schema:
- type: string
- description: Only points from this bucket are deleted.
- - in: query
- name: orgID
- description: Specifies the organization ID of the resource.
- schema:
- type: string
- - in: query
- name: bucketID
- description: Specifies the bucket ID to delete data from.
- schema:
- type: string
- description: Only points from this bucket ID are deleted.
- responses:
- '204':
- description: delete has been accepted
- '400':
- description: Invalid request.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '403':
- description: no token was sent or does not have sufficient permissions.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '404':
- description: the bucket or organization is not found.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: internal server error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /labels:
- post:
- operationId: PostLabels
- tags:
- - Labels
- summary: Create a label
- requestBody:
- description: Label to create
+ $ref: '#/components/schemas/CreateDashboardRequest'
+ description: Dashboard to create
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelCreateRequest'
responses:
- '201':
- description: Added label
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- get:
- operationId: GetLabels
- tags:
- - Labels
- summary: List all labels
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: orgID
- description: The organization ID.
- schema:
- type: string
- responses:
- '200':
- description: A list of labels
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/labels/{labelID}':
- get:
- operationId: GetLabelsID
- tags:
- - Labels
- summary: Retrieve a label
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to update.
- responses:
- '200':
- description: A label
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchLabelsID
- tags:
- - Labels
- summary: Update a label
- requestBody:
- description: Label update
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelUpdate'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to update.
- responses:
- '200':
- description: Updated label
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- '404':
- description: Label not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteLabelsID
- tags:
- - Labels
- summary: Delete a label
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Label not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}':
- get:
- operationId: GetDashboardsID
- tags:
- - Dashboards
- summary: Retrieve a Dashboard
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
- - in: query
- name: include
- required: false
- schema:
- type: string
- enum:
- - properties
- description: Includes the cell view properties in the response if set to `properties`
- responses:
- '200':
- description: Retrieve a single dashboard
+ "201":
content:
application/json:
schema:
oneOf:
- - $ref: '#/components/schemas/Dashboard'
- - $ref: '#/components/schemas/DashboardWithViewProperties'
- '404':
- description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ - $ref: '#/components/schemas/Dashboard'
+ - $ref: '#/components/schemas/DashboardWithViewProperties'
+ description: Added dashboard
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- patch:
- operationId: PatchDashboardsID
+ description: Unexpected error
+ summary: Create a dashboard
tags:
- - Dashboards
- summary: Update a dashboard
- requestBody:
- description: Patching of a dashboard
- required: true
- content:
- application/json:
- schema:
- type: object
- title: PatchDashboardRequest
- properties:
- name:
- description: 'optional, when provided will replace the name'
- type: string
- description:
- description: 'optional, when provided will replace the description'
- type: string
- cells:
- description: 'optional, when provided will replace all existing cells with the cells provided'
- $ref: '#/components/schemas/CellWithViewProperties'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
- responses:
- '200':
- description: Updated dashboard
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Dashboard'
- '404':
- description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}:
delete:
operationId: DeleteDashboardsID
- tags:
- - Dashboards
- summary: Delete a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/cells':
- put:
- operationId: PutDashboardsIDCells
- tags:
- - Cells
- - Dashboards
- summary: Replace cells in a dashboard
- description: Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.
- requestBody:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Dashboard not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a dashboard
+ tags:
+ - Dashboards
+ get:
+ operationId: GetDashboardsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ - description: Includes the cell view properties in the response if set to `properties`
+ in: query
+ name: include
+ required: false
+ schema:
+ enum:
+ - properties
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ oneOf:
+ - $ref: '#/components/schemas/Dashboard'
+ - $ref: '#/components/schemas/DashboardWithViewProperties'
+ description: Retrieve a single dashboard
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Dashboard not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a Dashboard
+ tags:
+ - Dashboards
+ patch:
+ operationId: PatchDashboardsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
- $ref: '#/components/schemas/Cells'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
+ properties:
+ cells:
+ $ref: '#/components/schemas/CellWithViewProperties'
+ description: optional, when provided will replace all existing cells
+ with the cells provided
+ description:
+ description: optional, when provided will replace the description
+ type: string
+ name:
+ description: optional, when provided will replace the name
+ type: string
+ title: PatchDashboardRequest
+ type: object
+ description: Patching of a dashboard
+ required: true
responses:
- '201':
- description: Replaced dashboard cells
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Dashboard'
- '404':
+ description: Updated dashboard
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/cells:
post:
operationId: PostDashboardsIDCells
- tags:
- - Cells
- - Dashboards
- summary: Create a dashboard cell
- requestBody:
- description: Cell that will be added
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateCell'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
+ description: Cell that will be added
+ required: true
responses:
- '201':
- description: Cell successfully added
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/Cell'
- '404':
+ description: Cell successfully added
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/cells/{cellID}':
- patch:
- operationId: PatchDashboardsIDCellsID
+ description: Unexpected error
+ summary: Create a dashboard cell
tags:
- - Cells
- - Dashboards
- summary: Update the non-positional information related to a cell
- description: Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.
- requestBody:
+ - Cells
+ - Dashboards
+ put:
+ description: Replaces all cells in a dashboard. This is used primarily to update
+ the positional information of all cells.
+ operationId: PutDashboardsIDCells
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Cells'
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Dashboard'
+ description: Replaced dashboard cells
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Dashboard not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Replace cells in a dashboard
+ tags:
+ - Cells
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/cells/{cellID}:
+ delete:
+ operationId: DeleteDashboardsIDCellsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to delete.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the cell to delete.
+ in: path
+ name: cellID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Cell successfully deleted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Cell or dashboard not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a dashboard cell
+ tags:
+ - Cells
+ - Dashboards
+ patch:
+ description: Updates the non positional information related to a cell. Updates
+ to a single cell's positional data could cause grid conflicts.
+ operationId: PatchDashboardsIDCellsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the cell to update.
+ in: path
+ name: cellID
+ required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CellUpdate'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
- - in: path
- name: cellID
- schema:
- type: string
- required: true
- description: The ID of the cell to update.
+ required: true
responses:
- '200':
- description: Updated dashboard cell
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Cell'
- '404':
+ description: Updated dashboard cell
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Cell or dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteDashboardsIDCellsID
+ description: Unexpected error
+ summary: Update the non-positional information related to a cell
tags:
- - Cells
- - Dashboards
- summary: Delete a dashboard cell
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to delete.
- - in: path
- name: cellID
- schema:
- type: string
- required: true
- description: The ID of the cell to delete.
- responses:
- '204':
- description: Cell successfully deleted
- '404':
- description: Cell or dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/cells/{cellID}/view':
+ - Cells
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/cells/{cellID}/view:
get:
operationId: GetDashboardsIDCellsIDView
- tags:
- - Cells
- - Dashboards
- - Views
- summary: Retrieve the view for a cell
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
- - in: path
- name: cellID
- schema:
- type: string
- required: true
- description: The cell ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ - description: The cell ID.
+ in: path
+ name: cellID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A dashboard cells view
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/View'
- '404':
+ description: A dashboard cells view
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Cell or dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve the view for a cell
+ tags:
+ - Cells
+ - Dashboards
+ - Views
patch:
operationId: PatchDashboardsIDCellsIDView
- tags:
- - Cells
- - Dashboards
- - Views
- summary: Update the view for a cell
- requestBody:
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the dashboard to update.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ - description: The ID of the cell to update.
+ in: path
+ name: cellID
+ required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/View'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The ID of the dashboard to update.
- - in: path
- name: cellID
- schema:
- type: string
- required: true
- description: The ID of the cell to update.
+ required: true
responses:
- '200':
- description: Updated cell view
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/View'
- '404':
+ description: Updated cell view
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Cell or dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/labels':
+ description: Unexpected error
+ summary: Update the view for a cell
+ tags:
+ - Cells
+ - Dashboards
+ - Views
+ /api/v2/dashboards/{dashboardID}/labels:
get:
operationId: GetDashboardsIDLabels
- tags:
- - Dashboards
- summary: List all labels for a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of all labels for a dashboard
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a dashboard
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels for a dashboard
+ tags:
+ - Dashboards
post:
operationId: PostDashboardsIDLabels
- tags:
- - Dashboards
- summary: Add a label to a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
- requestBody:
- description: Label to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
responses:
- '201':
- description: The label added to the dashboard
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/LabelResponse'
+ description: The label added to the dashboard
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/labels/{labelID}':
+ description: Unexpected error
+ summary: Add a label to a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/labels/{labelID}:
delete:
operationId: DeleteDashboardsIDLabelsID
- tags:
- - Dashboards
- summary: Delete a label from a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Delete has been accepted
- '404':
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Dashboard not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/members':
+ description: Unexpected error
+ summary: Delete a label from a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/members:
get:
operationId: GetDashboardsIDMembers
- tags:
- - Dashboards
- summary: List all dashboard members
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of users who have member privileges for a dashboard
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceMembers'
+ description: A list of users who have member privileges for a dashboard
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all dashboard members
+ tags:
+ - Dashboards
post:
operationId: PostDashboardsIDMembers
- tags:
- - Dashboards
- summary: Add a member to a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
- requestBody:
- description: User to add as member
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as member
+ required: true
responses:
- '201':
- description: Added to dashboard members
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceMember'
+ description: Added to dashboard members
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/members/{userID}':
+ description: Unexpected error
+ summary: Add a member to a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/members/{userID}:
delete:
operationId: DeleteDashboardsIDMembersID
- tags:
- - Dashboards
- summary: Remove a member from a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the member to remove.
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the member to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Member removed
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/owners':
+ description: Unexpected error
+ summary: Remove a member from a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/owners:
get:
operationId: GetDashboardsIDOwners
- tags:
- - Dashboards
- summary: List all dashboard owners
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: A list of users who have owner privileges for a dashboard
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceOwners'
+ description: A list of users who have owner privileges for a dashboard
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all dashboard owners
+ tags:
+ - Dashboards
post:
operationId: PostDashboardsIDOwners
- tags:
- - Dashboards
- summary: Add an owner to a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
- requestBody:
- description: User to add as owner
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as owner
+ required: true
responses:
- '201':
- description: Added to dashboard owners
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/ResourceOwner'
+ description: Added to dashboard owners
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/dashboards/{dashboardID}/owners/{userID}':
+ description: Unexpected error
+ summary: Add an owner to a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dashboards/{dashboardID}/owners/{userID}:
delete:
operationId: DeleteDashboardsIDOwnersID
- tags:
- - Dashboards
- summary: Remove an owner from a dashboard
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the owner to remove.
- - in: path
- name: dashboardID
- schema:
- type: string
- required: true
- description: The dashboard ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the owner to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The dashboard ID.
+ in: path
+ name: dashboardID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Owner removed
default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Unexpected error
+ summary: Remove an owner from a dashboard
+ tags:
+ - Dashboards
+ /api/v2/dbrps:
+ get:
+ operationId: GetDBRPs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Specifies the organization ID to filter on
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Specifies the organization name to filter on
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: Specifies the mapping ID to filter on
+ in: query
+ name: id
+ schema:
+ type: string
+ - description: Specifies the bucket ID to filter on
+ in: query
+ name: bucketID
+ schema:
+ type: string
+ - description: Specifies filtering on default
+ in: query
+ name: default
+ schema:
+ type: boolean
+ - description: Specifies the database to filter on
+ in: query
+ name: db
+ schema:
+ type: string
+ - description: Specifies the retention policy to filter on
+ in: query
+ name: rp
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/DBRPs'
+ description: Success. Returns a list of database retention policy mappings.
+ "400":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /query/ast:
- post:
- operationId: PostQueryAst
- description: Analyzes flux query and generates a query specification.
+ description: Bad request. The request has one or more invalid parameters.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List database retention policy mappings
tags:
- - Query
- summary: Generate an Abstract Syntax Tree (AST) from a query
+ - DBRPs
+ post:
+ operationId: PostDBRP
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: header
- name: Content-Type
- schema:
- type: string
- enum:
- - application/json
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
- description: Analyzed Flux query to generate abstract syntax tree.
content:
application/json:
schema:
- $ref: '#/components/schemas/LanguageRequest'
+ $ref: '#/components/schemas/DBRPCreate'
+ description: The database retention policy mapping to add
+ required: true
responses:
- '200':
- description: Abstract syntax tree of the flux query.
+ "201":
content:
application/json:
schema:
- $ref: '#/components/schemas/ASTResponse'
- default:
- description: Any response other than 200 is an internal server error
+ $ref: '#/components/schemas/DBRP'
+ description: Created. Returns the created database retention policy mapping.
+ "400":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /query/suggestions:
+ description: Bad request. The mapping in the request has one or more invalid
+ IDs.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a database retention policy mapping
+ tags:
+ - DBRPs
+ /api/v2/dbrps/{dbrpID}:
+ delete:
+ operationId: DeleteDBRPID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Specifies the organization ID of the mapping
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Specifies the organization name of the mapping
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The database retention policy mapping
+ in: path
+ name: dbrpID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "400":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: if any of the IDs passed is invalid
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a database retention policy
+ tags:
+ - DBRPs
get:
- operationId: GetQuerySuggestions
- tags:
- - Query
- summary: Retrieve query suggestions
+ operationId: GetDBRPsID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Specifies the organization ID of the mapping
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Specifies the organization name of the mapping
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The database retention policy mapping ID
+ in: path
+ name: dbrpID
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: Suggestions for next functions in call chain
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/FluxSuggestions'
- default:
- description: Any response other than 200 is an internal server error
+ $ref: '#/components/schemas/DBRPGet'
+ description: The database retention policy requested
+ "400":
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/query/suggestions/{name}':
- get:
- operationId: GetQuerySuggestionsName
- tags:
- - Query
- summary: Retrieve query suggestions for a branching suggestion
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: name
- schema:
- type: string
- required: true
- description: The name of the branching suggestion.
- responses:
- '200':
- description: Suggestions for next functions in call chain
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/FluxSuggestion'
+ description: if any of the IDs passed is invalid
default:
- description: Any response other than 200 is an internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /query/analyze:
- post:
- operationId: PostQueryAnalyze
+ description: Unexpected error
+ summary: Retrieve a database retention policy mapping
tags:
- - Query
- summary: Analyze an InfluxQL or Flux query
+ - DBRPs
+ patch:
+ operationId: PatchDBRPID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: header
- name: Content-Type
- schema:
- type: string
- enum:
- - application/json
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Specifies the organization ID of the mapping
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Specifies the organization name of the mapping
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The database retention policy mapping.
+ in: path
+ name: dbrpID
+ required: true
+ schema:
+ type: string
requestBody:
- description: Flux or InfluxQL query to analyze
content:
application/json:
schema:
- $ref: '#/components/schemas/Query'
+ $ref: '#/components/schemas/DBRPUpdate'
+ description: Database retention policy update to apply
+ required: true
responses:
- '200':
- description: Query analyze results. Errors will be empty if the query is valid.
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/AnalyzeQueryResponse'
+ $ref: '#/components/schemas/DBRPGet'
+ description: An updated mapping
+ "400":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: if any of the IDs passed is invalid
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The mapping was not found
default:
- description: Internal server error
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a database retention policy mapping
+ tags:
+ - DBRPs
+ /api/v2/delete:
+ post:
+ operationId: PostDelete
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Specifies the organization to delete data from.
+ in: query
+ name: org
+ schema:
+ description: Only points from this organization are deleted.
+ type: string
+ - description: Specifies the bucket to delete data from.
+ in: query
+ name: bucket
+ schema:
+ description: Only points from this bucket are deleted.
+ type: string
+ - description: Specifies the organization ID of the resource.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Specifies the bucket ID to delete data from.
+ in: query
+ name: bucketID
+ schema:
+ description: Only points from this bucket ID are deleted.
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/DeletePredicateRequest'
+ description: Deletes data from an InfluxDB bucket.
+ required: true
+ responses:
+ "204":
+ description: delete has been accepted
+ "400":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Invalid request.
+ "403":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: no token was sent or does not have sufficient permissions.
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: the bucket or organization is not found.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: internal server error
+ summary: Delete data
+ tags:
+ - Delete
+ /api/v2/experimental/sampledata/buckets:
+ get:
+ operationId: GetDemoDataBuckets
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/DemoDataBuckets'
+ description: A list of demo data buckets
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: List of Demo Data Buckets
+ tags:
+ - DemoDataBuckets
+ /api/v2/experimental/sampledata/buckets/{bucketID}/members:
+ delete:
+ operationId: DeleteDemoDataBucketMembers
+ parameters:
+ - description: bucket id
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ description: if sampledata route is not available gateway responds with
+ 200
+ "204":
+ description: A list of demo data buckets
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List of Demo Data Buckets
+ tags:
+ - DemoDataBuckets
+ post:
+ operationId: GetDemoDataBucketMembers
+ parameters:
+ - description: bucket id
+ in: path
+ name: bucketID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ description: if sampledata route is not available gateway responds with
+ 200
+ "204":
+ description: A list of demo data buckets
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List of Demo Data Buckets
+ tags:
+ - DemoDataBuckets
+ /api/v2/flags:
+ get:
+ operationId: GetFlags
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Flags'
+ description: Feature flags for the currently authenticated user
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Return the feature flags for the currently authenticated user
+ tags:
+ - Users
+ /api/v2/labels:
+ get:
+ operationId: GetLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of labels
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels
+ tags:
+ - Labels
+ post:
+ operationId: PostLabels
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelCreateRequest'
+ description: Label to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: Added label
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Create a label
+ tags:
+ - Labels
+ /api/v2/labels/{labelID}:
+ delete:
+ operationId: DeleteLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Label not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a label
+ tags:
+ - Labels
+ get:
+ operationId: GetLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the label to update.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: A label
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a label
+ tags:
+ - Labels
+ patch:
+ operationId: PatchLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the label to update.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelUpdate'
+ description: Label update
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: Updated label
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Label not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a label
+ tags:
+ - Labels
+ /api/v2/maps/mapToken:
+ get:
+ operationId: getMapboxToken
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Token'
+ description: A temp token for Mapbox
+ "401":
+ $ref: '#/components/responses/ServerError'
+ "500":
+ $ref: '#/components/responses/ServerError'
+ default:
+ $ref: '#/components/responses/ServerError'
+ /api/v2/me:
+ get:
+ operationId: GetMe
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/UserResponse'
+ description: The currently authenticated user.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve the currently authenticated user
+ tags:
+ - Users
+ /api/v2/me/password:
+ put:
+ operationId: PutMePassword
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PasswordResetBody'
+ description: New password
+ required: true
+ responses:
+ "204":
+ description: Password successfully updated
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unsuccessful authentication
+ security:
+ - BasicAuthentication: []
+ summary: Update a password
+ tags:
+ - Users
+ /api/v2/notificationEndpoints:
+ get:
+ operationId: GetNotificationEndpoints
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Limit'
+ - description: Only show notification endpoints that belong to specific organization
+ ID.
+ in: query
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoints'
+ description: A list of notification endpoints
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all notification endpoints
+ tags:
+ - NotificationEndpoints
+ post:
+ operationId: CreateNotificationEndpoint
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PostNotificationEndpoint'
+ description: Notification endpoint to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoint'
+ description: Notification endpoint created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a notification endpoint
+ tags:
+ - NotificationEndpoints
+ /api/v2/notificationEndpoints/{endpointID}:
+ delete:
+ operationId: DeleteNotificationEndpointsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The endpoint was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a notification endpoint
+ tags:
+ - NotificationEndpoints
+ get:
+ operationId: GetNotificationEndpointsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoint'
+ description: The notification endpoint requested
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a notification endpoint
+ tags:
+ - NotificationEndpoints
+ patch:
+ operationId: PatchNotificationEndpointsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpointUpdate'
+ description: Check update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoint'
+ description: An updated notification endpoint
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The notification endpoint was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a notification endpoint
+ tags:
+ - NotificationEndpoints
+ put:
+ operationId: PutNotificationEndpointsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoint'
+ description: A new notification endpoint to replace the existing endpoint
+ with
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationEndpoint'
+ description: An updated notification endpoint
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The notification endpoint was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a notification endpoint
+ tags:
+ - NotificationEndpoints
+ /api/v2/notificationEndpoints/{endpointID}/labels:
+ get:
+ operationId: GetNotificationEndpointsIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a notification endpoint
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels for a notification endpoint
+ tags:
+ - NotificationEndpoints
+ post:
+ operationId: PostNotificationEndpointIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: The label was added to the notification endpoint
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a label to a notification endpoint
+ tags:
+ - NotificationEndpoints
+ /api/v2/notificationEndpoints/{endpointID}/labels/{labelID}:
+ delete:
+ operationId: DeleteNotificationEndpointsIDLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification endpoint ID.
+ in: path
+ name: endpointID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Endpoint or label not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a label from a notification endpoint
+ tags:
+ - NotificationEndpoints
+ /api/v2/notificationRules:
+ get:
+ operationId: GetNotificationRules
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Limit'
+ - description: Only show notification rules that belong to a specific organization
+ ID.
+ in: query
+ name: orgID
+ required: true
+ schema:
+ type: string
+ - description: Only show notifications that belong to the specific check ID.
+ in: query
+ name: checkID
+ schema:
+ type: string
+ - description: Only return notification rules that "would match" statuses which
+ contain the tag key value pairs provided.
+ in: query
+ name: tag
+ schema:
+ example: env:prod
+ pattern: ^[a-zA-Z0-9_]+:[a-zA-Z0-9_]+$
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRules'
+ description: A list of notification rules
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all notification rules
+ tags:
+ - NotificationRules
+ post:
+ operationId: CreateNotificationRule
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PostNotificationRule'
+ description: Notification rule to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRule'
+ description: Notification rule created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a notification rule
+ tags:
+ - NotificationRules
+ /api/v2/notificationRules/{ruleID}:
+ delete:
+ operationId: DeleteNotificationRulesID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The check was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a notification rule
+ tags:
+ - NotificationRules
+ get:
+ operationId: GetNotificationRulesID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRule'
+ description: The notification rule requested
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a notification rule
+ tags:
+ - NotificationRules
+ patch:
+ operationId: PatchNotificationRulesID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRuleUpdate'
+ description: Notification rule update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRule'
+ description: An updated notification rule
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The notification rule was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a notification rule
+ tags:
+ - NotificationRules
+ put:
+ operationId: PutNotificationRulesID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRule'
+ description: Notification rule update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/NotificationRule'
+ description: An updated notification rule
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: The notification rule was not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a notification rule
+ tags:
+ - NotificationRules
+ /api/v2/notificationRules/{ruleID}/labels:
+ get:
+ operationId: GetNotificationRulesIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a notification rule
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels for a notification rule
+ tags:
+ - NotificationRules
+ post:
+ operationId: PostNotificationRuleIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: The label was added to the notification rule
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a label to a notification rule
+ tags:
+ - NotificationRules
+ /api/v2/notificationRules/{ruleID}/labels/{labelID}:
+ delete:
+ operationId: DeleteNotificationRulesIDLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ - description: The ID of the label to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Rule or label not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete label from a notification rule
+ tags:
+ - NotificationRules
+ /api/v2/notificationRules/{ruleID}/query:
+ get:
+ operationId: GetNotificationRulesIDQuery
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The notification rule ID.
+ in: path
+ name: ruleID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/FluxResponse'
+ description: The notification rule query requested
+ "400":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Invalid request
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Notification rule not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a notification rule query
+ tags:
+ - Rules
+ /api/v2/orgs:
+ get:
+ operationId: GetOrgs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/Offset'
+ - $ref: '#/components/parameters/Limit'
+ - $ref: '#/components/parameters/Descending'
+ - description: Filter organizations to a specific organization name.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: Filter organizations to a specific organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Filter organizations to a specific user ID.
+ in: query
+ name: userID
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Organizations'
+ description: A list of organizations
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all organizations
+ tags:
+ - Organizations
+ post:
+ operationId: PostOrgs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PostOrganizationRequest'
+ description: Organization to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Organization'
+ description: Organization created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Create an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}:
+ delete:
+ operationId: DeleteOrgsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the organization to delete.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Organization not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete an organization
+ tags:
+ - Organizations
+ get:
+ operationId: GetOrgsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the organization to get.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Organization'
+ description: Organization details
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve an organization
+ tags:
+ - Organizations
+ patch:
+ operationId: PatchOrgsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the organization to get.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PatchOrganizationRequest'
+ description: Organization update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Organization'
+ description: Organization updated
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}/limits:
+ get:
+ parameters:
+ - description: The identifier of the organization.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ description: These are org limits similar to those configured in/by
+ quartz.
+ properties:
+ limits:
+ $ref: '#/components/schemas/Limit'
+ links:
+ $ref: '#/components/schemas/Links'
+ type: object
+ description: The Limits defined for the organization.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: unexpected error
+ summary: Retrieve limits for an organization
+ tags:
+ - Limits
+ /api/v2/orgs/{orgID}/members:
+ get:
+ operationId: GetOrgsIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMembers'
+ description: A list of organization members
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Organization not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all members of an organization
+ tags:
+ - Organizations
+ post:
+ operationId: PostOrgsIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as member
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMember'
+ description: Added to organization created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a member to an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}/members/{userID}:
+ delete:
+ operationId: DeleteOrgsIDMembersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the member to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Member removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove a member from an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}/owners:
+ get:
+ operationId: GetOrgsIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwners'
+ description: A list of organization owners
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Organization not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all owners of an organization
+ tags:
+ - Organizations
+ post:
+ operationId: PostOrgsIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as owner
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwner'
+ description: Organization owner added
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add an owner to an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}/owners/{userID}:
+ delete:
+ operationId: DeleteOrgsIDOwnersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the owner to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Owner removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove an owner from an organization
+ tags:
+ - Organizations
+ /api/v2/orgs/{orgID}/secrets:
+ get:
+ operationId: GetOrgsIDSecrets
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/SecretKeysResponse'
+ description: A list of all secret keys
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all secret keys for an organization
+ tags:
+ - Secrets
+ patch:
+ operationId: PatchOrgsIDSecrets
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Secrets'
+ description: Secret key value pairs to update/add
+ required: true
+ responses:
+ "204":
+ description: Keys successfully patched
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update secrets in an organization
+ tags:
+ - Secrets
+ /api/v2/orgs/{orgID}/secrets/{secretID}:
+ delete:
+ operationId: DeleteOrgsIDSecretsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ - description: The secret ID.
+ in: path
+ name: secretID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Keys successfully deleted
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Delete a secret from an organization
+ tags:
+ - Secrets
+ /api/v2/orgs/{orgID}/secrets/delete:
+ post:
+ deprecated: true
+ operationId: PostOrgsIDSecrets
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/SecretKeys'
+ description: Secret key to delete
+ required: true
+ responses:
+ "204":
+ description: Keys successfully patched
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete secrets from an organization
+ tags:
+ - Secrets
+ /api/v2/orgs/{orgID}/usage:
+ get:
+ parameters:
+ - description: The identifier of the organization.
+ in: path
+ name: orgID
+ required: true
+ schema:
+ type: string
+ - description: start time
+ in: query
+ name: start
+ required: true
+ schema:
+ type: timestamp
+ - description: stop time
+ in: query
+ name: stop
+ required: false
+ schema:
+ type: timestamp
+ - description: return raw usage data
+ in: query
+ name: raw
+ required: false
+ schema:
+ default: false
+ type: boolean
+ responses:
+ "200":
+ content:
+ text/csv:
+ schema:
+ example: |
+ #group,false,false,true,true,false,false,true,true,true,true #datatype,string,long,dateTime:RFC3339,dateTime:RFC3339,dateTime:RFC3339,double,string,string,string,string #default,_result,,,,,,,,, ,result,table,_start,_stop,_time,_value,_field,_measurement,bucket_id,org_id ,,0,2021-05-10T14:25:10.865702397Z,2021-05-10T15:25:10.865702397Z,2021-05-10T15:00:00Z,5434066,gauge,storage_usage_bucket_bytes,2f6ba0cf9a2fdcbb,cec6fc1d2176dc11 ,,1,2021-05-10T14:25:10.865702397Z,2021-05-10T15:25:10.865702397Z,2021-05-10T15:00:00Z,9924053.966666665,gauge,storage_usage_bucket_bytes,8af67bcaf69d9daf,cec6fc1d2176dc11
+ type: string
+ description: Usage data
headers:
- X-Influx-Error:
- description: Error string describing the problem
+ Content-Encoding:
+ description: The Content-Encoding entity header is used to compress
+ the media-type. When present, its value indicates which encodings
+ were applied to the entity-body
+ schema:
+ default: identity
+ description: Specifies that the response in the body is encoded with
+ gzip or not encoded with identity.
+ enum:
+ - gzip
+ - identity
+ type: string
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: unexpected error
+ summary: Retrieve usage for an organization
+ tags:
+ - Usage
+ /ping:
+ get:
+ operationId: GetPing
+ responses:
+ "204":
+ description: OK
+ headers:
+ X-Influxdb-Build:
+ description: The type of InfluxDB build.
schema:
type: string
- X-Influx-Reference:
- description: Reference code unique to the error type
+ X-Influxdb-Version:
+ description: The version of InfluxDB.
schema:
type: integer
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /query:
- post:
- operationId: PostQuery
+ servers:
+ - url: ""
+ summary: Checks the status of InfluxDB instance and version of InfluxDB.
tags:
- - Query
- summary: Query data
+ - Ping
+ head:
+ operationId: HeadPing
+ responses:
+ "204":
+ description: OK
+ headers:
+ X-Influxdb-Build:
+ description: The type of InfluxDB build.
+ schema:
+ type: string
+ X-Influxdb-Version:
+ description: The version of InfluxDB.
+ schema:
+ type: integer
+ servers:
+ - url: ""
+ summary: Checks the status of InfluxDB instance and version of InfluxDB.
+ tags:
+ - Ping
+ /api/v2/query:
+ post:
description: |
Retrieves data from InfluxDB buckets.
@@ -2229,1231 +3797,1905 @@ paths:
- [Flux](https://docs.influxdata.com/influxdb/cloud/reference/flux) or [InfluxQL](https://docs.influxdata.com/influxdb/cloud/query-data/influxql/) query.
For more information and examples, see [Query with the InfluxDB API](https://docs.influxdata.com/influxdb/cloud/query-data/execute-queries/influx-api/).
+ operationId: PostQuery
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: header
- name: Accept-Encoding
- description: 'The Accept-Encoding request HTTP header advertises which content encoding, usually a compression algorithm, the client is able to understand.'
- schema:
- type: string
- description: Specifies that the query response in the body should be encoded with gzip or not encoded with identity.
- default: identity
- enum:
- - gzip
- - identity
- - in: header
- name: Content-Type
- schema:
- type: string
- enum:
- - application/json
- - application/vnd.flux
- - in: query
- name: org
- description: 'Specifies the name of the organization executing the query. Takes either the ID or Name. If both `orgID` and `org` are specified, `org` takes precedence.'
- schema:
- type: string
- - in: query
- name: orgID
- description: 'Specifies the ID of the organization executing the query. If both `orgID` and `org` are specified, `org` takes precedence.'
- schema:
- type: string
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Accept-Encoding request HTTP header advertises which content
+ encoding, usually a compression algorithm, the client is able to understand.
+ in: header
+ name: Accept-Encoding
+ schema:
+ default: identity
+ description: Specifies that the query response in the body should be encoded
+ with gzip or not encoded with identity.
+ enum:
+ - gzip
+ - identity
+ type: string
+ - in: header
+ name: Content-Type
+ schema:
+ enum:
+ - application/json
+ - application/vnd.flux
+ type: string
+ - description: Specifies the name of the organization executing the query. Takes
+ either the ID or Name. If both `orgID` and `org` are specified, `org` takes
+ precedence.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: Specifies the ID of the organization executing the query. If
+ both `orgID` and `org` are specified, `org` takes precedence.
+ in: query
+ name: orgID
+ schema:
+ type: string
requestBody:
- description: Flux query or specification to execute
content:
application/json:
schema:
oneOf:
- - $ref: '#/components/schemas/Query'
- - $ref: '#/components/schemas/InfluxQLQuery'
+ - $ref: '#/components/schemas/Query'
+ - $ref: '#/components/schemas/InfluxQLQuery'
application/vnd.flux:
schema:
type: string
+ description: Flux query or specification to execute
responses:
- '200':
+ "200":
+ content:
+ application/vnd.influx.arrow:
+ schema:
+ format: binary
+ type: string
+ text/csv:
+ schema:
+ example: |
+ result,table,_start,_stop,_time,region,host,_value mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:00Z,east,A,15.43 mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:20Z,east,B,59.25 mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:40Z,east,C,52.62
+ type: string
description: Success. Returns query results.
headers:
Content-Encoding:
- description: 'The Content-Encoding entity header is used to compress the media-type. When present, its value indicates which encodings were applied to the entity-body'
+ description: The Content-Encoding entity header is used to compress
+ the media-type. When present, its value indicates which encodings
+ were applied to the entity-body
schema:
- type: string
- description: Specifies that the response in the body is encoded with gzip or not encoded with identity.
default: identity
+ description: Specifies that the response in the body is encoded with
+ gzip or not encoded with identity.
enum:
- - gzip
- - identity
+ - gzip
+ - identity
+ type: string
Trace-Id:
- description: 'The Trace-Id header reports the request''s trace ID, if one was generated.'
+ description: The Trace-Id header reports the request's trace ID, if
+ one was generated.
schema:
- type: string
description: Specifies the request's trace ID.
- content:
- text/csv:
- schema:
type: string
- example: |
- result,table,_start,_stop,_time,region,host,_value mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:00Z,east,A,15.43 mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:20Z,east,B,59.25 mean,0,2018-05-08T20:50:00Z,2018-05-08T20:51:00Z,2018-05-08T20:50:40Z,east,C,52.62
- application/vnd.influx.arrow:
- schema:
- type: string
- format: binary
- '429':
- description: Token is temporarily over quota. The Retry-After header describes when to try the read again.
+ "429":
+ description: Token is temporarily over quota. The Retry-After header describes
+ when to try the read again.
headers:
Retry-After:
- description: A non-negative decimal integer indicating the seconds to delay after the response is received.
+ description: A non-negative decimal integer indicating the seconds to
+ delay after the response is received.
+ schema:
+ format: int32
+ type: integer
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Error processing query
+ summary: Query data
+ tags:
+ - Query
+ /api/v2/query/analyze:
+ post:
+ operationId: PostQueryAnalyze
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - in: header
+ name: Content-Type
+ schema:
+ enum:
+ - application/json
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Query'
+ description: Flux or InfluxQL query to analyze
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AnalyzeQueryResponse'
+ description: Query analyze results. Errors will be empty if the query is
+ valid.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Internal server error
+ headers:
+ X-Influx-Error:
+ description: Error string describing the problem
+ schema:
+ type: string
+ X-Influx-Reference:
+ description: Reference code unique to the error type
schema:
type: integer
- format: int32
- default:
- description: Error processing query
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /buckets:
- get:
- operationId: GetBuckets
+ summary: Analyze an InfluxQL or Flux query
tags:
- - Buckets
- summary: List all buckets
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Limit'
- - $ref: '#/components/parameters/After'
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The organization ID.
- schema:
- type: string
- - in: query
- name: name
- description: Only returns buckets with a specific name.
- schema:
- type: string
- - in: query
- name: id
- description: Only returns buckets with a specific ID.
- schema:
- type: string
- responses:
- '200':
- description: A list of buckets
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Buckets'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ - Query
+ /api/v2/query/ast:
post:
- operationId: PostBuckets
- tags:
- - Buckets
- summary: Create a bucket
+ description: Analyzes flux query and generates a query specification.
+ operationId: PostQueryAst
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
+ - in: header
+ name: Content-Type
+ schema:
+ enum:
+ - application/json
+ type: string
requestBody:
- description: Bucket to create
- required: true
content:
application/json:
schema:
- $ref: '#/components/schemas/PostBucketRequest'
+ $ref: '#/components/schemas/LanguageRequest'
+ description: Analyzed Flux query to generate abstract syntax tree.
responses:
- '201':
- description: Bucket created
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/Bucket'
- '422':
- description: Request body failed validation
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ $ref: '#/components/schemas/ASTResponse'
+ description: Abstract syntax tree of the flux query.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/buckets/{bucketID}':
+ description: Any response other than 200 is an internal server error
+ summary: Generate an Abstract Syntax Tree (AST) from a query
+ tags:
+ - Query
+ /api/v2/query/suggestions:
get:
- operationId: GetBucketsID
- tags:
- - Buckets
- summary: Retrieve a bucket
+ operationId: GetQuerySuggestions
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
+ - $ref: '#/components/parameters/TraceSpan'
responses:
- '200':
- description: Bucket details
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/Bucket'
+ $ref: '#/components/schemas/FluxSuggestions'
+ description: Suggestions for next functions in call chain
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- patch:
- operationId: PatchBucketsID
+ description: Any response other than 200 is an internal server error
+ summary: Retrieve query suggestions
tags:
- - Buckets
- summary: Update a bucket
- requestBody:
- description: Bucket update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PatchBucketRequest'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '200':
- description: An updated bucket
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Bucket'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteBucketsID
- tags:
- - Buckets
- summary: Delete a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The ID of the bucket to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Bucket not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/labels':
+ - Query
+ /api/v2/query/suggestions/{name}:
get:
- operationId: GetBucketsIDLabels
- tags:
- - Buckets
- summary: List all labels for a bucket
+ operationId: GetQuerySuggestionsName
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '200':
- description: A list of all labels for a bucket
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostBucketsIDLabels
- tags:
- - Buckets
- summary: Add a label to a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- requestBody:
- description: Label to add
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The name of the branching suggestion.
+ in: path
+ name: name
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
+ schema:
+ type: string
responses:
- '201':
- description: The newly added label
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/LabelResponse'
+ $ref: '#/components/schemas/FluxSuggestion'
+ description: Suggestions for next functions in call chain
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/labels/{labelID}':
- delete:
- operationId: DeleteBucketsIDLabelsID
+ description: Any response other than 200 is an internal server error
+ summary: Retrieve query suggestions for a branching suggestion
tags:
- - Buckets
- summary: Delete a label from a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Bucket not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/members':
- get:
- operationId: GetBucketsIDMembers
- tags:
- - Buckets
- summary: List all users with member privileges for a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '200':
- description: A list of bucket members
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMembers'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostBucketsIDMembers
- tags:
- - Buckets
- summary: Add a member to a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- requestBody:
- description: User to add as member
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Member added to bucket
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMember'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/members/{userID}':
- delete:
- operationId: DeleteBucketsIDMembersID
- tags:
- - Buckets
- summary: Remove a member from a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the member to remove.
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '204':
- description: Member removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/owners':
- get:
- operationId: GetBucketsIDOwners
- tags:
- - Buckets
- summary: List all owners of a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '200':
- description: A list of bucket owners
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwners'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostBucketsIDOwners
- tags:
- - Buckets
- summary: Add an owner to a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- requestBody:
- description: User to add as owner
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Bucket owner added
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwner'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/owners/{userID}':
- delete:
- operationId: DeleteBucketsIDOwnersID
- tags:
- - Buckets
- summary: Remove an owner from a bucket
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the owner to remove.
- - in: path
- name: bucketID
- schema:
- type: string
- required: true
- description: The bucket ID.
- responses:
- '204':
- description: Owner removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /orgs:
- get:
- operationId: GetOrgs
- tags:
- - Organizations
- summary: List all organizations
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Limit'
- - $ref: '#/components/parameters/Descending'
- - in: query
- name: org
- schema:
- type: string
- description: Filter organizations to a specific organization name.
- - in: query
- name: orgID
- schema:
- type: string
- description: Filter organizations to a specific organization ID.
- - in: query
- name: userID
- schema:
- type: string
- description: Filter organizations to a specific user ID.
- responses:
- '200':
- description: A list of organizations
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Organizations'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostOrgs
- tags:
- - Organizations
- summary: Create an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: Organization to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PostOrganizationRequest'
- responses:
- '201':
- description: Organization created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Organization'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}':
- get:
- operationId: GetOrgsID
- tags:
- - Organizations
- summary: Retrieve an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The ID of the organization to get.
- responses:
- '200':
- description: Organization details
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Organization'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchOrgsID
- tags:
- - Organizations
- summary: Update an organization
- requestBody:
- description: Organization update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PatchOrganizationRequest'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The ID of the organization to get.
- responses:
- '200':
- description: Organization updated
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Organization'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteOrgsID
- tags:
- - Organizations
- summary: Delete an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The ID of the organization to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Organization not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/secrets':
- get:
- operationId: GetOrgsIDSecrets
- tags:
- - Secrets
- summary: List all secret keys for an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- responses:
- '200':
- description: A list of all secret keys
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/SecretKeysResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchOrgsIDSecrets
- tags:
- - Secrets
- summary: Update secrets in an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- requestBody:
- description: Secret key value pairs to update/add
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Secrets'
- responses:
- '204':
- description: Keys successfully patched
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/members':
- get:
- operationId: GetOrgsIDMembers
- tags:
- - Organizations
- summary: List all members of an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- responses:
- '200':
- description: A list of organization members
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMembers'
- '404':
- description: Organization not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostOrgsIDMembers
- tags:
- - Organizations
- summary: Add a member to an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- requestBody:
- description: User to add as member
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Added to organization created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMember'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/members/{userID}':
- delete:
- operationId: DeleteOrgsIDMembersID
- tags:
- - Organizations
- summary: Remove a member from an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the member to remove.
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- responses:
- '204':
- description: Member removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/owners':
- get:
- operationId: GetOrgsIDOwners
- tags:
- - Organizations
- summary: List all owners of an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- responses:
- '200':
- description: A list of organization owners
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwners'
- '404':
- description: Organization not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostOrgsIDOwners
- tags:
- - Organizations
- summary: Add an owner to an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- requestBody:
- description: User to add as owner
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Organization owner added
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwner'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/owners/{userID}':
- delete:
- operationId: DeleteOrgsIDOwnersID
- tags:
- - Organizations
- summary: Remove an owner from an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the owner to remove.
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- responses:
- '204':
- description: Owner removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/secrets/delete':
- post:
- deprecated: true
- operationId: PostOrgsIDSecrets
- tags:
- - Secrets
- summary: Delete secrets from an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- requestBody:
- description: Secret key to delete
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/SecretKeys'
- responses:
- '204':
- description: Keys successfully patched
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/secrets/{secretID}':
- delete:
- operationId: DeleteOrgsIDSecretsID
- tags:
- - Secrets
- summary: Delete a secret from an organization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: orgID
- schema:
- type: string
- required: true
- description: The organization ID.
- - in: path
- name: secretID
- schema:
- type: string
- required: true
- description: The secret ID.
- responses:
- '204':
- description: Keys successfully deleted
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- /resources:
+ - Query
+ /api/v2/resources:
get:
operationId: GetResources
- tags:
- - resource list
- summary: List all known resources
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
responses:
- '200':
- description: All resources targets
+ "200":
content:
application/json:
schema:
- type: array
items:
type: string
+ type: array
+ description: All resources targets
default:
- description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /stacks:
+ description: Internal server error
+ summary: List all known resources
+ tags:
+ - Resources
+ /api/v2/scripts:
+ get:
+ operationId: GetScripts
+ parameters:
+ - description: The number of scripts to return.
+ in: query
+ name: limit
+ required: false
+ schema:
+ type: integer
+ - description: The offset for pagination.
+ in: query
+ name: offset
+ required: false
+ schema:
+ type: integer
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Scripts'
+ description: The list of scripts.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: List scripts
+ tags:
+ - Invocable Scripts
+ post:
+ operationId: PostScripts
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ScriptCreateRequest'
+ description: The script to create.
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Script'
+ description: The created script.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Create a script
+ tags:
+ - Invocable Scripts
+ /api/v2/scripts/{scriptID}:
+ delete:
+ description: Deletes a script and all associated records.
+ operationId: DeleteScriptsID
+ parameters:
+ - description: The ID of the script to delete.
+ in: path
+ name: scriptID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: The script is deleted.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Delete a script
+ tags:
+ - Invocable Scripts
+ get:
+ description: Uses script ID to retrieve details of an invocable script.
+ operationId: GetScriptsID
+ parameters:
+ - description: The script ID.
+ in: path
+ name: scriptID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Script'
+ description: The requested script object.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Retrieve a script
+ tags:
+ - Invocable Scripts
+ patch:
+ description: |
+ Updates properties (`name`, `description`, and `script`) of an invocable script.
+ operationId: PatchScriptsID
+ parameters:
+ - description: The script ID.
+ in: path
+ name: scriptID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ScriptUpdateRequest'
+ description: Script update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Script'
+ description: The updated script.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Update a script
+ tags:
+ - Invocable Scripts
+ /api/v2/scripts/{scriptID}/invoke:
+ post:
+ description: Invokes a script and substitutes `params` keys referenced in the
+ script with `params` key-values sent in the request body.
+ operationId: PostScriptsIDInvoke
+ parameters:
+ - in: path
+ name: scriptID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ScriptInvocationParams'
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ScriptHTTPResponseData'
+ description: The result of the script execution.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Invoke a script
+ tags:
+ - Invocable Scripts
+ /api/v2/setup:
+ get:
+ description: Check if setup is allowed. Returns `true` if no default user, organization,
+ or bucket have been created.
+ operationId: GetSetup
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/IsOnboarding'
+ description: Setup is allowed, true or false
+ summary: Retrieve setup status
+ tags:
+ - Setup
+ post:
+ description: Post an onboarding request to create an initial user, organization,
+ and bucket.
+ operationId: PostSetup
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/OnboardingRequest'
+ description: Source to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/OnboardingResponse'
+ description: The created default user, bucket, and organization
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Create an initial user, organization, and bucket
+ tags:
+ - Setup
+ /api/v2/setup/user:
+ post:
+ description: Post an onboarding request to create a new user, organization,
+ and bucket.
+ operationId: PostSetupUser
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/OnboardingRequest'
+ description: Source to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/OnboardingResponse'
+ description: The created default user, bucket, and organization.
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: Create a new user, organization, and bucket
+ tags:
+ - Setup
+ /api/v2/signin:
+ post:
+ description: Authenticates ***Basic Auth*** credentials for a user. If successful,
+ creates a new UI session for the user.
+ operationId: PostSignin
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ responses:
+ "204":
+ description: Success. User authenticated.
+ "401":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unauthorized access.
+ "403":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: User account is disabled.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unsuccessful authentication.
+ security:
+ - BasicAuthentication: []
+ summary: Create a user session.
+ tags:
+ - Signin
+ /api/v2/signout:
+ post:
+ description: Expires the current UI session for the user.
+ operationId: PostSignout
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ responses:
+ "204":
+ description: Session successfully expired
+ "401":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unauthorized access
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unsuccessful session expiry
+ summary: Expire the current UI session
+ tags:
+ - Signout
+ /api/v2/stacks:
get:
operationId: ListStacks
- tags:
- - Templates
- summary: List installed templates
parameters:
- - in: query
- name: orgID
- required: true
- schema:
- type: string
- description: The organization ID of the stacks
- - in: query
- name: name
- schema:
- type: string
- description: A collection of names to filter the list by.
- - in: query
- name: stackID
- schema:
- type: string
- description: A collection of stackIDs to filter the list by.
+ - description: The organization ID of the stacks
+ in: query
+ name: orgID
+ required: true
+ schema:
+ type: string
+ - description: A collection of names to filter the list by.
+ in: query
+ name: name
+ schema:
+ type: string
+ - description: A collection of stackIDs to filter the list by.
+ in: query
+ name: stackID
+ schema:
+ type: string
responses:
- '200':
- description: Success. Returns the list of stacks.
+ "200":
content:
application/json:
schema:
- type: object
properties:
stacks:
- type: array
items:
$ref: '#/components/schemas/Stack'
+ type: array
+ type: object
+ description: Success. Returns the list of stacks.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List installed templates
+ tags:
+ - Templates
post:
operationId: CreateStack
- tags:
- - Templates
- summary: Create a new stack
requestBody:
- description: The stack to create.
- required: true
content:
application/json:
schema:
- type: object
- title: PostStackRequest
properties:
+ description:
+ type: string
+ name:
+ type: string
orgID:
type: string
- name:
- type: string
- description:
- type: string
urls:
- type: array
items:
type: string
+ type: array
+ title: PostStackRequest
+ type: object
+ description: The stack to create.
+ required: true
responses:
- '201':
- description: Success. Returns the newly created stack.
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/Stack'
+ description: Success. Returns the newly created stack.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- '/stacks/{stack_id}':
+ description: Unexpected error
+ summary: Create a new stack
+ tags:
+ - Templates
+ /api/v2/stacks/{stack_id}:
+ delete:
+ operationId: DeleteStack
+ parameters:
+ - description: The identifier of the stack.
+ in: path
+ name: stack_id
+ required: true
+ schema:
+ type: string
+ - description: The identifier of the organization.
+ in: query
+ name: orgID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: The stack and its associated resources were deleted.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a stack and associated resources
+ tags:
+ - Templates
get:
operationId: ReadStack
- tags:
- - Templates
- summary: Retrieve a stack
parameters:
- - in: path
- name: stack_id
- required: true
- schema:
- type: string
- description: The identifier of the stack.
+ - description: The identifier of the stack.
+ in: path
+ name: stack_id
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: Returns the stack.
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Stack'
+ description: Returns the stack.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a stack
+ tags:
+ - Templates
patch:
operationId: UpdateStack
- tags:
- - Templates
- summary: Update a stack
parameters:
- - in: path
- name: stack_id
- required: true
- schema:
- type: string
- description: The identifier of the stack.
- requestBody:
- description: The stack to update.
+ - description: The identifier of the stack.
+ in: path
+ name: stack_id
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
- type: object
- title: PatchStackRequest
properties:
- name:
- type: string
- nullable: true
- description:
- type: string
- nullable: true
- templateURLs:
- type: array
- items:
- type: string
- nullable: true
additionalResources:
- type: array
items:
- type: object
properties:
- resourceID:
- type: string
kind:
type: string
+ resourceID:
+ type: string
templateMetaName:
type: string
required:
- - kind
- - resourceID
+ - kind
+ - resourceID
+ type: object
+ type: array
+ description:
+ nullable: true
+ type: string
+ name:
+ nullable: true
+ type: string
+ templateURLs:
+ items:
+ type: string
+ nullable: true
+ type: array
+ title: PatchStackRequest
+ type: object
+ description: The stack to update.
+ required: true
responses:
- '200':
- description: Returns the updated stack.
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Stack'
+ description: Returns the updated stack.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteStack
+ description: Unexpected error
+ summary: Update a stack
tags:
- - Templates
- summary: Delete a stack and associated resources
- parameters:
- - in: path
- name: stack_id
- required: true
- schema:
- type: string
- description: The identifier of the stack.
- - in: query
- name: orgID
- required: true
- schema:
- type: string
- description: The identifier of the organization.
- responses:
- '204':
- description: The stack and its associated resources were deleted.
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/stacks/{stack_id}/uninstall':
+ - Templates
+ /api/v2/stacks/{stack_id}/uninstall:
post:
operationId: UninstallStack
- tags:
- - Templates
- summary: Uninstall a stack
parameters:
- - in: path
- name: stack_id
- required: true
- schema:
- type: string
- description: The identifier of the stack.
+ - description: The identifier of the stack.
+ in: path
+ name: stack_id
+ required: true
+ schema:
+ type: string
responses:
- '200':
- description: Returns the uninstalled stack.
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Stack'
+ description: Returns the uninstalled stack.
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /templates/apply:
- post:
- operationId: ApplyTemplate
+ description: Unexpected error
+ summary: Uninstall a stack
tags:
- - Templates
- summary: Apply or dry-run a template
- description: Applies or performs a dry-run of template in an organization.
+ - Templates
+ /api/v2/tasks:
+ get:
+ operationId: GetTasks
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: Returns task with a specific name.
+ in: query
+ name: name
+ schema:
+ type: string
+ - description: Return tasks after a specified ID.
+ in: query
+ name: after
+ schema:
+ type: string
+ - description: Filter tasks to a specific user ID.
+ in: query
+ name: user
+ schema:
+ type: string
+ - description: Filter tasks to a specific organization name.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: Filter tasks to a specific organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: Filter tasks by a status--"inactive" or "active".
+ in: query
+ name: status
+ schema:
+ enum:
+ - active
+ - inactive
+ type: string
+ - description: The non-zero number of tasks to return
+ in: query
+ name: limit
+ schema:
+ default: 100
+ maximum: 500
+ minimum: -1
+ type: integer
+ - description: Type of task, unset by default.
+ in: query
+ name: type
+ required: false
+ schema:
+ default: ""
+ enum:
+ - basic
+ - system
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Tasks'
+ description: A list of tasks
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all tasks
+ tags:
+ - Tasks
+ post:
+ operationId: PostTasks
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TaskCreateRequest'
+ description: Task to create
required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Task'
+ description: Task created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Create a new task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}:
+ delete:
+ description: Deletes a task and all associated records
+ operationId: DeleteTasksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the task to delete.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Task deleted
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a task
+ tags:
+ - Tasks
+ get:
+ operationId: GetTasksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Task'
+ description: Task details
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a task
+ tags:
+ - Tasks
+ patch:
+ description: Update a task. This will cancel all queued runs.
+ operationId: PatchTasksID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TaskUpdateRequest'
+ description: Task update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Task'
+ description: Task updated
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/labels:
+ get:
+ operationId: GetTasksIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a task
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels for a task
+ tags:
+ - Tasks
+ post:
+ operationId: PostTasksIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: A list of all labels for a task
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a label to a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/labels/{labelID}:
+ delete:
+ operationId: DeleteTasksIDLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: The label ID.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Task not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a label from a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/logs:
+ get:
+ operationId: GetTasksIDLogs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Logs'
+ description: All logs for a task
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve all logs for a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/members:
+ get:
+ operationId: GetTasksIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMembers'
+ description: A list of users who have member privileges for a task
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all task members
+ tags:
+ - Tasks
+ post:
+ operationId: PostTasksIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as member
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMember'
+ description: Added to task members
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a member to a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/members/{userID}:
+ delete:
+ operationId: DeleteTasksIDMembersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the member to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Member removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove a member from a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/owners:
+ get:
+ operationId: GetTasksIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwners'
+ description: A list of users who have owner privileges for a task
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all owners of a task
+ tags:
+ - Tasks
+ post:
+ operationId: PostTasksIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as owner
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwner'
+ description: Added to task owners
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add an owner to a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/owners/{userID}:
+ delete:
+ operationId: DeleteTasksIDOwnersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the owner to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Owner removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove an owner from a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/runs:
+ get:
+ operationId: GetTasksIDRuns
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the task to get runs for.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: Returns runs after a specific ID.
+ in: query
+ name: after
+ schema:
+ type: string
+ - description: The number of runs to return
+ in: query
+ name: limit
+ schema:
+ default: 100
+ maximum: 500
+ minimum: 1
+ type: integer
+ - description: Filter runs to those scheduled after this time, RFC3339
+ in: query
+ name: afterTime
+ schema:
+ format: date-time
+ type: string
+ - description: Filter runs to those scheduled before this time, RFC3339
+ in: query
+ name: beforeTime
+ schema:
+ format: date-time
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Runs'
+ description: A list of task runs
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List runs for a task
+ tags:
+ - Tasks
+ post:
+ operationId: PostTasksIDRuns
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/RunManually'
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Run'
+ description: Run scheduled to start
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Manually start a task run, overriding the current schedule
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/runs/{runID}:
+ delete:
+ operationId: DeleteTasksIDRunsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: The run ID.
+ in: path
+ name: runID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Cancel a running task
+ tags:
+ - Tasks
+ get:
+ operationId: GetTasksIDRunsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: The run ID.
+ in: path
+ name: runID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Run'
+ description: The run record
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a single run for a task
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/runs/{runID}/logs:
+ get:
+ operationId: GetTasksIDRunsIDLogs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: ID of task to get logs for.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: ID of run to get logs for.
+ in: path
+ name: runID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Logs'
+ description: All logs for a run
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve all logs for a run
+ tags:
+ - Tasks
+ /api/v2/tasks/{taskID}/runs/{runID}/retry:
+ post:
+ operationId: PostTasksIDRunsIDRetry
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The task ID.
+ in: path
+ name: taskID
+ required: true
+ schema:
+ type: string
+ - description: The run ID.
+ in: path
+ name: runID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json; charset=utf-8:
+ schema:
+ type: object
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Run'
+ description: Run that has been queued
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retry a task run
+ tags:
+ - Tasks
+ /api/v2/telegraf/plugins:
+ get:
+ operationId: GetTelegrafPlugins
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The type of plugin desired.
+ in: query
+ name: type
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TelegrafPlugins'
+ description: A list of Telegraf plugins.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all Telegraf plugins
+ tags:
+ - Telegraf Plugins
+ /api/v2/telegrafs:
+ get:
+ operationId: GetTelegrafs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The organization ID the Telegraf config belongs to.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Telegrafs'
+ description: A list of Telegraf configurations
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all Telegraf configurations
+ tags:
+ - Telegrafs
+ post:
+ operationId: PostTelegrafs
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TelegrafRequest'
+ description: Telegraf configuration to create
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Telegraf'
+ description: Telegraf configuration created
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Create a Telegraf configuration
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}:
+ delete:
+ operationId: DeleteTelegrafsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf configuration ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a Telegraf configuration
+ tags:
+ - Telegrafs
+ get:
+ operationId: GetTelegrafsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf configuration ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ - in: header
+ name: Accept
+ required: false
+ schema:
+ default: application/toml
+ enum:
+ - application/toml
+ - application/json
+ - application/octet-stream
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Telegraf'
+ application/octet-stream:
+ example: |-
+ [agent]
+ interval = "10s"
+ schema:
+ type: string
+ application/toml:
+ example: |-
+ [agent]
+ interval = "10s"
+ schema:
+ type: string
+ description: Telegraf configuration details
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Retrieve a Telegraf configuration
+ tags:
+ - Telegrafs
+ put:
+ operationId: PutTelegrafsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TelegrafRequest'
+ description: Telegraf configuration update to apply
+ required: true
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Telegraf'
+ description: An updated Telegraf configurations
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Update a Telegraf configuration
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/labels:
+ get:
+ operationId: GetTelegrafsIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a Telegraf config
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all labels for a Telegraf config
+ tags:
+ - Telegrafs
+ post:
+ operationId: PostTelegrafsIDLabels
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/LabelResponse'
+ description: The label added to the Telegraf config
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a label to a Telegraf config
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/labels/{labelID}:
+ delete:
+ operationId: DeleteTelegrafsIDLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ - description: The label ID.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Telegraf config not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a label from a Telegraf config
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/members:
+ get:
+ operationId: GetTelegrafsIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMembers'
+ description: A list of Telegraf config members
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all users with member privileges for a Telegraf config
+ tags:
+ - Telegrafs
+ post:
+ operationId: PostTelegrafsIDMembers
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as member
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceMember'
+ description: Member added to Telegraf config
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add a member to a Telegraf config
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/members/{userID}:
+ delete:
+ operationId: DeleteTelegrafsIDMembersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the member to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Member removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove a member from a Telegraf config
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/owners:
+ get:
+ operationId: GetTelegrafsIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf configuration ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwners'
+ description: Returns Telegraf configuration owners as a ResourceOwners list
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: List all owners of a Telegraf configuration
+ tags:
+ - Telegrafs
+ post:
+ operationId: PostTelegrafsIDOwners
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The Telegraf configuration ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/AddResourceMemberRequestBody'
+ description: User to add as owner
+ required: true
+ responses:
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ResourceOwner'
+ description: Telegraf configuration owner was added. Returns a ResourceOwner
+ that references the User.
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Add an owner to a Telegraf configuration
+ tags:
+ - Telegrafs
+ /api/v2/telegrafs/{telegrafID}/owners/{userID}:
+ delete:
+ operationId: DeleteTelegrafsIDOwnersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the owner to remove.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ - description: The Telegraf config ID.
+ in: path
+ name: telegrafID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Owner removed
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Remove an owner from a Telegraf config
+ tags:
+ - Telegrafs
+ /api/v2/templates/apply:
+ post:
+ description: Applies or performs a dry-run of template in an organization.
+ operationId: ApplyTemplate
+ requestBody:
content:
application/json:
schema:
@@ -3464,45 +5706,45 @@ paths:
text/yml:
schema:
$ref: '#/components/schemas/TemplateApply'
+ required: true
responses:
- '200':
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/TemplateSummary'
description: |
Success. The package dry-run succeeded. No new resources were created. Returns a diff and summary of the dry-run. The diff and summary won't contain IDs for resources that didn't exist at the time of the dry-run.
+ "201":
content:
application/json:
schema:
$ref: '#/components/schemas/TemplateSummary'
- '201':
description: |
Success. The package applied successfully. Returns a diff and summary of the run. The summary contains newly created resources. The diff compares the initial state to the state after the package applied. This corresponds to `"dryRun": true`.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/TemplateSummary'
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /templates/export:
+ description: Unexpected error
+ summary: Apply or dry-run a template
+ tags:
+ - Templates
+ /api/v2/templates/export:
post:
operationId: ExportTemplate
- tags:
- - Templates
- summary: Export a new template
requestBody:
- description: Export resources as an InfluxDB template.
- required: false
content:
application/json:
schema:
oneOf:
- - $ref: '#/components/schemas/TemplateExportByID'
- - $ref: '#/components/schemas/TemplateExportByName'
+ - $ref: '#/components/schemas/TemplateExportByID'
+ - $ref: '#/components/schemas/TemplateExportByName'
+ description: Export resources as an InfluxDB template.
+ required: false
responses:
- '200':
- description: The template was created successfully. Returns the newly created template.
+ "200":
content:
application/json:
schema:
@@ -3510,2686 +5752,422 @@ paths:
application/x-yaml:
schema:
$ref: '#/components/schemas/Template'
+ description: The template was created successfully. Returns the newly created
+ template.
default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}':
- get:
- operationId: GetTasksID
+ summary: Export a new template
tags:
- - Tasks
- summary: Retrieve a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: Task details
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Task'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchTasksID
- tags:
- - Tasks
- summary: Update a task
- description: Update a task. This will cancel all queued runs.
- requestBody:
- description: Task update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/TaskUpdateRequest'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: Task updated
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Task'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteTasksID
- tags:
- - Tasks
- summary: Delete a task
- description: Deletes a task and all associated records
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The ID of the task to delete.
- responses:
- '204':
- description: Task deleted
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/runs':
- get:
- operationId: GetTasksIDRuns
- tags:
- - Tasks
- summary: List runs for a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The ID of the task to get runs for.
- - in: query
- name: after
- schema:
- type: string
- description: Returns runs after a specific ID.
- - in: query
- name: limit
- schema:
- type: integer
- minimum: 1
- maximum: 500
- default: 100
- description: The number of runs to return
- - in: query
- name: afterTime
- schema:
- type: string
- format: date-time
- description: 'Filter runs to those scheduled after this time, RFC3339'
- - in: query
- name: beforeTime
- schema:
- type: string
- format: date-time
- description: 'Filter runs to those scheduled before this time, RFC3339'
- responses:
- '200':
- description: A list of task runs
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Runs'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostTasksIDRuns
- tags:
- - Tasks
- summary: 'Manually start a task run, overriding the current schedule'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- requestBody:
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/RunManually'
- responses:
- '201':
- description: Run scheduled to start
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Run'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/runs/{runID}':
- get:
- operationId: GetTasksIDRunsID
- tags:
- - Tasks
- summary: Retrieve a single run for a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- - in: path
- name: runID
- schema:
- type: string
- required: true
- description: The run ID.
- responses:
- '200':
- description: The run record
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Run'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteTasksIDRunsID
- tags:
- - Tasks
- summary: Cancel a running task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- - in: path
- name: runID
- schema:
- type: string
- required: true
- description: The run ID.
- responses:
- '204':
- description: Delete has been accepted
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/runs/{runID}/retry':
- post:
- operationId: PostTasksIDRunsIDRetry
- tags:
- - Tasks
- summary: Retry a task run
- requestBody:
- content:
- application/json; charset=utf-8:
- schema:
- type: object
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- - in: path
- name: runID
- schema:
- type: string
- required: true
- description: The run ID.
- responses:
- '200':
- description: Run that has been queued
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Run'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/logs':
- get:
- operationId: GetTasksIDLogs
- tags:
- - Tasks
- summary: Retrieve all logs for a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: All logs for a task
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Logs'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/runs/{runID}/logs':
- get:
- operationId: GetTasksIDRunsIDLogs
- tags:
- - Tasks
- summary: Retrieve all logs for a run
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: ID of task to get logs for.
- - in: path
- name: runID
- schema:
- type: string
- required: true
- description: ID of run to get logs for.
- responses:
- '200':
- description: All logs for a run
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Logs'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/labels':
- get:
- operationId: GetTasksIDLabels
- tags:
- - Tasks
- summary: List all labels for a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: A list of all labels for a task
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostTasksIDLabels
- tags:
- - Tasks
- summary: Add a label to a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- requestBody:
- description: Label to add
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
- responses:
- '201':
- description: A list of all labels for a task
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/labels/{labelID}':
- delete:
- operationId: DeleteTasksIDLabelsID
- tags:
- - Tasks
- summary: Delete a label from a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The label ID.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Task not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /flags:
- get:
- operationId: GetFlags
- tags:
- - Users
- summary: Return the feature flags for the currently authenticated user
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- responses:
- '200':
- description: Feature flags for the currently authenticated user
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Flags'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /me:
- get:
- operationId: GetMe
- tags:
- - Users
- summary: Retrieve the currently authenticated user
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- responses:
- '200':
- description: The currently authenticated user.
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/UserResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /me/password:
- put:
- operationId: PutMePassword
- tags:
- - Users
- summary: Update a password
- security:
- - BasicAuthentication: []
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: New password
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PasswordResetBody'
- responses:
- '204':
- description: Password successfully updated
- default:
- description: Unsuccessful authentication
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/members':
- get:
- operationId: GetTasksIDMembers
- tags:
- - Tasks
- summary: List all task members
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: A list of users who have member privileges for a task
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMembers'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostTasksIDMembers
- tags:
- - Tasks
- summary: Add a member to a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- requestBody:
- description: User to add as member
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Added to task members
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceMember'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/members/{userID}':
- delete:
- operationId: DeleteTasksIDMembersID
- tags:
- - Tasks
- summary: Remove a member from a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the member to remove.
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '204':
- description: Member removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/owners':
- get:
- operationId: GetTasksIDOwners
- tags:
- - Tasks
- summary: List all owners of a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '200':
- description: A list of users who have owner privileges for a task
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwners'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostTasksIDOwners
- tags:
- - Tasks
- summary: Add an owner to a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- requestBody:
- description: User to add as owner
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/AddResourceMemberRequestBody'
- responses:
- '201':
- description: Added to task owners
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ResourceOwner'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/tasks/{taskID}/owners/{userID}':
- delete:
- operationId: DeleteTasksIDOwnersID
- tags:
- - Tasks
- summary: Remove an owner from a task
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the owner to remove.
- - in: path
- name: taskID
- schema:
- type: string
- required: true
- description: The task ID.
- responses:
- '204':
- description: Owner removed
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/users/{userID}/password':
- post:
- operationId: PostUsersIDPassword
- tags:
- - Users
- summary: Update a password
- security:
- - BasicAuthentication: []
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The user ID.
- requestBody:
- description: New password
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PasswordResetBody'
- responses:
- '204':
- description: Password successfully updated
- default:
- description: Unsuccessful authentication
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /checks:
- get:
- operationId: GetChecks
- tags:
- - Checks
- summary: List all checks
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Limit'
- - in: query
- name: orgID
- required: true
- description: Only show checks that belong to a specific organization ID.
- schema:
- type: string
- responses:
- '200':
- description: A list of checks
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Checks'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: CreateCheck
- tags:
- - Checks
- summary: Add new check
- requestBody:
- description: Check to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PostCheck'
- responses:
- '201':
- description: Check created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Check'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/checks/{checkID}':
- get:
- operationId: GetChecksID
- tags:
- - Checks
- summary: Retrieve a check
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '200':
- description: The check requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Check'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- put:
- operationId: PutChecksID
- tags:
- - Checks
- summary: Update a check
- requestBody:
- description: Check update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Check'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '200':
- description: An updated check
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Check'
- '404':
- description: The check was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchChecksID
- tags:
- - Checks
- summary: Update a check
- requestBody:
- description: Check update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/CheckPatch'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '200':
- description: An updated check
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Check'
- '404':
- description: The check was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteChecksID
- tags:
- - Checks
- summary: Delete a check
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: The check was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/checks/{checkID}/labels':
- get:
- operationId: GetChecksIDLabels
- tags:
- - Checks
- summary: List all labels for a check
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '200':
- description: A list of all labels for a check
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostChecksIDLabels
- tags:
- - Checks
- summary: Add a label to a check
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- requestBody:
- description: Label to add
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
- responses:
- '201':
- description: The label was added to the check
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/checks/{checkID}/labels/{labelID}':
- delete:
- operationId: DeleteChecksIDLabelsID
- tags:
- - Checks
- summary: Delete label from a check
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Check or label not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /notificationRules:
- get:
- operationId: GetNotificationRules
- tags:
- - NotificationRules
- summary: List all notification rules
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Limit'
- - in: query
- name: orgID
- required: true
- description: Only show notification rules that belong to a specific organization ID.
- schema:
- type: string
- - in: query
- name: checkID
- description: Only show notifications that belong to the specific check ID.
- schema:
- type: string
- - in: query
- name: tag
- description: Only return notification rules that "would match" statuses which contain the tag key value pairs provided.
- schema:
- type: string
- pattern: '^[a-zA-Z0-9_]+:[a-zA-Z0-9_]+$'
- example: 'env:prod'
- responses:
- '200':
- description: A list of notification rules
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRules'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: CreateNotificationRule
- tags:
- - NotificationRules
- summary: Add a notification rule
- requestBody:
- description: Notification rule to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PostNotificationRule'
- responses:
- '201':
- description: Notification rule created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRule'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/checks/{checkID}/query':
- get:
- operationId: GetChecksIDQuery
- tags:
- - Checks
- summary: Retrieve a check query
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: checkID
- schema:
- type: string
- required: true
- description: The check ID.
- responses:
- '200':
- description: The check query requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/FluxResponse'
- '400':
- description: Invalid request
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '404':
- description: Check not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationRules/{ruleID}':
- get:
- operationId: GetNotificationRulesID
- tags:
- - NotificationRules
- summary: Retrieve a notification rule
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '200':
- description: The notification rule requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRule'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- put:
- operationId: PutNotificationRulesID
- tags:
- - NotificationRules
- summary: Update a notification rule
- requestBody:
- description: Notification rule update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRule'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '200':
- description: An updated notification rule
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRule'
- '404':
- description: The notification rule was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchNotificationRulesID
- tags:
- - NotificationRules
- summary: Update a notification rule
- requestBody:
- description: Notification rule update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRuleUpdate'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '200':
- description: An updated notification rule
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationRule'
- '404':
- description: The notification rule was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteNotificationRulesID
- tags:
- - NotificationRules
- summary: Delete a notification rule
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: The check was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationRules/{ruleID}/labels':
- get:
- operationId: GetNotificationRulesIDLabels
- tags:
- - NotificationRules
- summary: List all labels for a notification rule
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '200':
- description: A list of all labels for a notification rule
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostNotificationRuleIDLabels
- tags:
- - NotificationRules
- summary: Add a label to a notification rule
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- requestBody:
- description: Label to add
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
- responses:
- '201':
- description: The label was added to the notification rule
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationRules/{ruleID}/labels/{labelID}':
- delete:
- operationId: DeleteNotificationRulesIDLabelsID
- tags:
- - NotificationRules
- summary: Delete label from a notification rule
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Rule or label not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationRules/{ruleID}/query':
- get:
- operationId: GetNotificationRulesIDQuery
- tags:
- - Rules
- summary: Retrieve a notification rule query
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: ruleID
- schema:
- type: string
- required: true
- description: The notification rule ID.
- responses:
- '200':
- description: The notification rule query requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/FluxResponse'
- '400':
- description: Invalid request
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '404':
- description: Notification rule not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /notificationEndpoints:
- get:
- operationId: GetNotificationEndpoints
- tags:
- - NotificationEndpoints
- summary: List all notification endpoints
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Limit'
- - in: query
- name: orgID
- required: true
- description: Only show notification endpoints that belong to specific organization ID.
- schema:
- type: string
- responses:
- '200':
- description: A list of notification endpoints
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoints'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: CreateNotificationEndpoint
- tags:
- - NotificationEndpoints
- summary: Add a notification endpoint
- requestBody:
- description: Notification endpoint to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/PostNotificationEndpoint'
- responses:
- '201':
- description: Notification endpoint created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoint'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationEndpoints/{endpointID}':
- get:
- operationId: GetNotificationEndpointsID
- tags:
- - NotificationEndpoints
- summary: Retrieve a notification endpoint
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- responses:
- '200':
- description: The notification endpoint requested
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoint'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- put:
- operationId: PutNotificationEndpointsID
- tags:
- - NotificationEndpoints
- summary: Update a notification endpoint
- requestBody:
- description: A new notification endpoint to replace the existing endpoint with
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoint'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- responses:
- '200':
- description: An updated notification endpoint
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoint'
- '404':
- description: The notification endpoint was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- patch:
- operationId: PatchNotificationEndpointsID
- tags:
- - NotificationEndpoints
- summary: Update a notification endpoint
- requestBody:
- description: Check update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpointUpdate'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- responses:
- '200':
- description: An updated notification endpoint
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/NotificationEndpoint'
- '404':
- description: The notification endpoint was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteNotificationEndpointsID
- tags:
- - NotificationEndpoints
- summary: Delete a notification endpoint
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: The endpoint was not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationEndpoints/{endpointID}/labels':
- get:
- operationId: GetNotificationEndpointsIDLabels
- tags:
- - NotificationEndpoints
- summary: List all labels for a notification endpoint
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- responses:
- '200':
- description: A list of all labels for a notification endpoint
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelsResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- post:
- operationId: PostNotificationEndpointIDLabels
- tags:
- - NotificationEndpoints
- summary: Add a label to a notification endpoint
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- requestBody:
- description: Label to add
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelMapping'
- responses:
- '201':
- description: The label was added to the notification endpoint
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/LabelResponse'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/notificationEndpoints/{endpointID}/labels/{labelID}':
- delete:
- operationId: DeleteNotificationEndpointsIDLabelsID
- tags:
- - NotificationEndpoints
- summary: Delete a label from a notification endpoint
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: endpointID
- schema:
- type: string
- required: true
- description: The notification endpoint ID.
- - in: path
- name: labelID
- schema:
- type: string
- required: true
- description: The ID of the label to delete.
- responses:
- '204':
- description: Delete has been accepted
- '404':
- description: Endpoint or label not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /users:
+ - Templates
+ /api/v2/users:
get:
operationId: GetUsers
- tags:
- - Users
- summary: List all users
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
responses:
- '200':
- description: A list of users
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Users'
+ description: A list of users
default:
- description: Unexpected error
$ref: '#/components/responses/ServerError'
+ description: Unexpected error
+ summary: List all users
+ tags:
+ - Users
post:
operationId: PostUsers
- tags:
- - Users
- summary: Create a user
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/User'
description: User to create
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/User'
responses:
- '201':
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/UserResponse'
description: User created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/UserResponse'
default:
- description: Unexpected error
$ref: '#/components/responses/ServerError'
- '/users/{userID}':
- get:
- operationId: GetUsersID
+ description: Unexpected error
+ summary: Create a user
tags:
- - Users
- summary: Retrieve a user
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The user ID.
- responses:
- '200':
- description: User details
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/UserResponse'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- patch:
- operationId: PatchUsersID
- tags:
- - Users
- summary: Update a user
- requestBody:
- description: User update to apply
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/User'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the user to update.
- responses:
- '200':
- description: User updated
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/UserResponse'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
+ - Users
+ /api/v2/users/{userID}:
delete:
operationId: DeleteUsersID
- tags:
- - Users
- summary: Delete a user
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: userID
- schema:
- type: string
- required: true
- description: The ID of the user to delete.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the user to delete.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: User deleted
default:
- description: Unexpected error
$ref: '#/components/responses/ServerError'
- /setup:
+ description: Unexpected error
+ summary: Delete a user
+ tags:
+ - Users
get:
- operationId: GetSetup
- tags:
- - Setup
- summary: Retrieve setup status
- description: 'Check if setup is allowed. Returns `true` if no default user, organization, or bucket have been created.'
+ operationId: GetUsersID
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- responses:
- '200':
- description: 'Setup is allowed, true or false'
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/IsOnboarding'
- post:
- operationId: PostSetup
- tags:
- - Setup
- summary: 'Create an initial user, organization, and bucket'
- description: 'Post an onboarding request to create an initial user, organization, and bucket.'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: Source to create
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The user ID.
+ in: path
+ name: userID
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/OnboardingRequest'
+ schema:
+ type: string
responses:
- '201':
- description: 'The created default user, bucket, and organization'
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/OnboardingResponse'
+ $ref: '#/components/schemas/UserResponse'
+ description: User details
default:
- description: Unexpected error
$ref: '#/components/responses/ServerError'
- /setup/user:
- post:
- operationId: PostSetupUser
- tags:
- - Setup
- summary: 'Create a new user, organization, and bucket'
- description: 'Post an onboarding request to create a new user, organization, and bucket.'
- requestBody:
- description: Source to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/OnboardingRequest'
- responses:
- '201':
- description: 'The created default user, bucket, and organization.'
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/OnboardingResponse'
- default:
description: Unexpected error
- $ref: '#/components/responses/ServerError'
- /authorizations:
- get:
- operationId: GetAuthorizations
+ summary: Retrieve a user
tags:
- - Authorizations
- summary: List all authorizations
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: userID
- schema:
- type: string
- description: Only show authorizations that belong to a user ID.
- - in: query
- name: user
- schema:
- type: string
- description: Only show authorizations that belong to a user name.
- - in: query
- name: orgID
- schema:
- type: string
- description: Only show authorizations that belong to an organization ID.
- - in: query
- name: org
- schema:
- type: string
- description: Only show authorizations that belong to a organization name.
- - in: query
- name: token
- schema:
- type: string
- description: Find a token by value.
- responses:
- '200':
- description: A list of authorizations
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Authorizations'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- post:
- operationId: PostAuthorizations
- tags:
- - Authorizations
- summary: Create an authorization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: Authorization to create
- required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Authorization'
- responses:
- '201':
- description: Authorization created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Authorization'
- '400':
- description: Invalid request
- $ref: '#/components/responses/ServerError'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- /experimental/sampledata/buckets:
- get:
- operationId: GetDemoDataBuckets
- tags:
- - DemoDataBuckets
- summary: List of Demo Data Buckets
- responses:
- '200':
- description: A list of demo data buckets
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DemoDataBuckets'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- '/experimental/sampledata/buckets/{bucketID}/members':
- post:
- operationId: GetDemoDataBucketMembers
- tags:
- - DemoDataBuckets
- summary: List of Demo Data Buckets
- parameters:
- - in: path
- name: bucketID
- required: true
- schema:
- type: string
- description: bucket id
- responses:
- '200':
- description: if sampledata route is not available gateway responds with 200
- '204':
- description: A list of demo data buckets
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- delete:
- operationId: DeleteDemoDataBucketMembers
- tags:
- - DemoDataBuckets
- summary: List of Demo Data Buckets
- parameters:
- - in: path
- name: bucketID
- required: true
- schema:
- type: string
- description: bucket id
- responses:
- '200':
- description: if sampledata route is not available gateway responds with 200
- '204':
- description: A list of demo data buckets
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '/authorizations/{authID}':
- get:
- operationId: GetAuthorizationsID
- tags:
- - Authorizations
- summary: Retrieve an authorization
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: authID
- schema:
- type: string
- required: true
- description: The identifier of the authorization to get.
- responses:
- '200':
- description: Authorization details
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Authorization'
- default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
+ - Users
patch:
- operationId: PatchAuthorizationsID
- tags:
- - Authorizations
- summary: Update authorization status
- description: Update an authorization's status to `active` or `inactive`.
- requestBody:
- description: The updated Authorization object.
+ operationId: PatchUsersID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The ID of the user to update.
+ in: path
+ name: userID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
- $ref: '#/components/schemas/AuthorizationUpdateRequest'
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: authID
- schema:
- type: string
- required: true
- description: The identifier of the authorization to update.
+ $ref: '#/components/schemas/User'
+ description: User update to apply
+ required: true
responses:
- '200':
- description: The updated authorization.
+ "200":
content:
application/json:
schema:
- $ref: '#/components/schemas/Authorization'
+ $ref: '#/components/schemas/UserResponse'
+ description: User updated
default:
- description: Unexpected error
$ref: '#/components/responses/ServerError'
- delete:
- operationId: DeleteAuthorizationsID
+ description: Unexpected error
+ summary: Update a user
tags:
- - Authorizations
- summary: Delete an authorization
+ - Users
+ /api/v2/users/{userID}/password:
+ post:
+ operationId: PostUsersIDPassword
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: authID
- schema:
- type: string
- required: true
- description: The identifier of the authorization to delete.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The user ID.
+ in: path
+ name: userID
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/PasswordResetBody'
+ description: New password
+ required: true
responses:
- '204':
- description: Authorization deleted
+ "204":
+ description: Password successfully updated
default:
- description: Unexpected error
- $ref: '#/components/responses/ServerError'
- /variables:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unsuccessful authentication
+ security:
+ - BasicAuthentication: []
+ summary: Update a password
+ tags:
+ - Users
+ /api/v2/variables:
get:
operationId: GetVariables
- tags:
- - Variables
- summary: List all variables
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The organization ID.
- schema:
- type: string
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The name of the organization.
+ in: query
+ name: org
+ schema:
+ type: string
+ - description: The organization ID.
+ in: query
+ name: orgID
+ schema:
+ type: string
responses:
- '200':
- description: A list of variables for an organization.
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Variables'
- '400':
+ description: A list of variables for an organization.
+ "400":
+ $ref: '#/components/responses/ServerError'
description: Invalid request
- $ref: '#/components/responses/ServerError'
default:
- description: Internal server error
$ref: '#/components/responses/ServerError'
+ description: Internal server error
+ summary: List all variables
+ tags:
+ - Variables
post:
operationId: PostVariables
- summary: Create a variable
- tags:
- - Variables
parameters:
- - $ref: '#/components/parameters/TraceSpan'
+ - $ref: '#/components/parameters/TraceSpan'
requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Variable'
description: Variable to create
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Variable'
responses:
- '201':
+ "201":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Variable'
description: Variable created
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Variable'
default:
- description: Internal server error
$ref: '#/components/responses/ServerError'
- '/variables/{variableID}':
- get:
- operationId: GetVariablesID
+ description: Internal server error
+ summary: Create a variable
tags:
- - Variables
- summary: Retrieve a variable
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- required: true
- schema:
- type: string
- description: The variable ID.
- responses:
- '200':
- description: Variable found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Variable'
- '404':
- description: Variable not found
- $ref: '#/components/responses/ServerError'
- default:
- description: Internal server error
- $ref: '#/components/responses/ServerError'
+ - Variables
+ /api/v2/variables/{variableID}:
delete:
operationId: DeleteVariablesID
- tags:
- - Variables
- summary: Delete a variable
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- required: true
- schema:
- type: string
- description: The variable ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
+ required: true
+ schema:
+ type: string
responses:
- '204':
+ "204":
description: Variable deleted
default:
- description: Internal server error
$ref: '#/components/responses/ServerError'
+ description: Internal server error
+ summary: Delete a variable
+ tags:
+ - Variables
+ get:
+ operationId: GetVariablesID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
+ required: true
+ schema:
+ type: string
+ responses:
+ "200":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Variable'
+ description: Variable found
+ "404":
+ $ref: '#/components/responses/ServerError'
+ description: Variable not found
+ default:
+ $ref: '#/components/responses/ServerError'
+ description: Internal server error
+ summary: Retrieve a variable
+ tags:
+ - Variables
patch:
operationId: PatchVariablesID
- summary: Update a variable
- tags:
- - Variables
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- required: true
- schema:
- type: string
- description: The variable ID.
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
+ required: true
+ schema:
+ type: string
requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Variable'
description: Variable update to apply
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Variable'
responses:
- '200':
- description: Variable updated
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Variable'
+ description: Variable updated
default:
- description: Internal server error
$ref: '#/components/responses/ServerError'
+ description: Internal server error
+ summary: Update a variable
+ tags:
+ - Variables
put:
operationId: PutVariablesID
- summary: Replace a variable
- tags:
- - Variables
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: path
- name: variableID
- required: true
- schema:
- type: string
- description: The variable ID.
- requestBody:
- description: Variable to replace
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/Variable'
+ description: Variable to replace
+ required: true
responses:
- '200':
- description: Variable updated
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/Variable'
+ description: Variable updated
default:
+ $ref: '#/components/responses/ServerError'
description: Internal server error
- $ref: '#/components/responses/ServerError'
- '/buckets/{bucketID}/schema/measurements':
- summary: APIs for bucket schema
+ summary: Replace a variable
+ tags:
+ - Variables
+ /api/v2/variables/{variableID}/labels:
get:
- summary: List all measurement schemas of a bucket
- operationId: getMeasurementSchemas
+ operationId: GetVariablesIDLabels
parameters:
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The identifier of the organization.
- schema:
- type: string
- - in: query
- name: name
- description: The name of a measurement. Return schemas for this measurement only.
- schema:
- type: string
- - in: path
- name: bucketID
- description: The identifier of the bucket.
- schema:
- type: string
- required: true
- tags:
- - Bucket Schemas
- responses:
- '200':
- description: A list of measurement schemas returning summary information
- headers:
- ETag:
- description: The current version of the bucket schema
- schema:
- type: string
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchemaList'
- '404':
- description: Bucket not found
- $ref: '#/components/responses/ServerError'
- post:
- summary: Create a measurement schema for a bucket
- operationId: createMeasurementSchema
- parameters:
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The identifier of the organization.
- schema:
- type: string
- - in: path
- name: bucketID
- description: The identifier of the bucket.
- schema:
- type: string
- required: true
- tags:
- - Bucket Schemas
- requestBody:
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchemaCreateRequest'
- responses:
- '201':
- description: The created measurement schema
- headers:
- ETag:
- description: The current version of the measurement schema
- schema:
- type: string
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchema'
- '400':
- description: Client error with create request
- content:
- application/json:
- examples:
- badNameExample:
- summary: Invalid name
- description: 'The error returned when the name is invalid, such as too few or too many characters or the name contains non-printable ASCII or is not valid UTF-8.'
- value:
- code: invalid
- message: name is invalid
- missingColumnsExample:
- summary: Missing columns
- description: The error returned when the request body is missing the columns property.
- value:
- code: invalid
- message: columns is required
- missingTimestampExample:
- summary: Missing timestamp
- description: The error returned when the request body is missing a timestamp type column.
- value:
- code: invalid
- message: Timestamp column is required
- duplicateColumnNamesExample:
- summary: Duplicate column names
- description: The error returned when the request body contains duplicate column names.
- value:
- code: invalid
- message: Duplicate column names
- missingFieldExample:
- summary: Missing field
- description: The error returned when the request body is missing at least one field type column.
- value:
- code: invalid
- message: At least one field column is required
- schema:
- $ref: '#/components/schemas/Error'
- '/buckets/{bucketID}/schema/measurements/{measurementID}':
- summary: APIs for tables
- get:
- summary: Retrieve measurement schema information
- operationId: getMeasurementSchema
- parameters:
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The identifier of the organization.
- schema:
- type: string
- - in: path
- name: bucketID
- description: The identifier of the bucket.
- schema:
- type: string
- required: true
- - in: path
- name: measurementID
- description: The identifier of the measurement.
- schema:
- type: string
- required: true
- tags:
- - Bucket Schemas
- responses:
- '200':
- description: Schema definition for a single measurement
- headers:
- ETag:
- description: The current version of the measurement schema
- schema:
- type: string
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchema'
- patch:
- summary: Update a measurement schema
- operationId: updateMeasurementSchema
- parameters:
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- - in: query
- name: orgID
- description: The identifier of the organization.
- schema:
- type: string
- - in: path
- name: bucketID
- description: The identifier of the bucket.
- schema:
- type: string
- required: true
- - in: path
- name: measurementID
- description: The identifier of the measurement.
- schema:
- type: string
- required: true
- tags:
- - Bucket Schemas
- requestBody:
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchemaUpdateRequest'
- responses:
- '200':
- description: The updated measurement schema
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MeasurementSchema'
- '400':
- description: Client error updating measurement schema
- content:
- application/json:
- examples:
- missingColumnsExample:
- summary: Deleted columns
- description: The error returned when the request body does not contain all the columns from the source.
- value:
- code: invalid
- message: Unable to delete columns from schema
- schema:
- $ref: '#/components/schemas/Error'
- '/orgs/{orgID}/limits':
- get:
- tags:
- - Limits
- summary: Retrieve limits for an organization
- parameters:
- - in: path
- name: orgID
- description: The identifier of the organization.
- required: true
- schema:
- type: string
- responses:
- '200':
- description: The Limits defined for the organization.
- content:
- application/json:
- schema:
- type: object
- description: These are org limits similar to those configured in/by quartz.
- properties:
- links:
- $ref: '#/components/schemas/Links'
- limits:
- $ref: '#/components/schemas/Limit'
- default:
- description: unexpected error
- $ref: '#/components/responses/ServerError'
- '/orgs/{orgID}/usage':
- get:
- tags:
- - Usage
- summary: Retrieve usage for an organization
- parameters:
- - in: path
- name: orgID
- description: The identifier of the organization.
- required: true
- schema:
- type: string
- - in: query
- name: start
- description: start time
- required: true
- schema:
- type: timestamp
- - in: query
- name: stop
- description: stop time
- required: false
- schema:
- type: timestamp
- - in: query
- name: raw
- description: return raw usage data
- required: false
- schema:
- type: boolean
- default: false
- responses:
- '200':
- description: Usage data
- headers:
- Content-Encoding:
- description: 'The Content-Encoding entity header is used to compress the media-type. When present, its value indicates which encodings were applied to the entity-body'
- schema:
- type: string
- description: Specifies that the response in the body is encoded with gzip or not encoded with identity.
- default: identity
- enum:
- - gzip
- - identity
- content:
- text/csv:
- schema:
- type: string
- example: |
- #group,false,false,true,true,false,false,true,true,true,true #datatype,string,long,dateTime:RFC3339,dateTime:RFC3339,dateTime:RFC3339,double,string,string,string,string #default,_result,,,,,,,,, ,result,table,_start,_stop,_time,_value,_field,_measurement,bucket_id,org_id ,,0,2021-05-10T14:25:10.865702397Z,2021-05-10T15:25:10.865702397Z,2021-05-10T15:00:00Z,5434066,gauge,storage_usage_bucket_bytes,2f6ba0cf9a2fdcbb,cec6fc1d2176dc11 ,,1,2021-05-10T14:25:10.865702397Z,2021-05-10T15:25:10.865702397Z,2021-05-10T15:00:00Z,9924053.966666665,gauge,storage_usage_bucket_bytes,8af67bcaf69d9daf,cec6fc1d2176dc11
- default:
- description: unexpected error
- $ref: '#/components/responses/ServerError'
- /dashboards:
- post:
- operationId: PostDashboards
- tags:
- - Dashboards
- summary: Create a dashboard
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: Dashboard to create
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
required: true
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/CreateDashboardRequest'
+ schema:
+ type: string
responses:
- '201':
- description: Added dashboard
+ "200":
content:
application/json:
schema:
- oneOf:
- - $ref: '#/components/schemas/Dashboard'
- - $ref: '#/components/schemas/DashboardWithViewProperties'
+ $ref: '#/components/schemas/LabelsResponse'
+ description: A list of all labels for a variable
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- get:
- operationId: GetDashboards
+ description: Unexpected error
+ summary: List all labels for a variable
tags:
- - Dashboards
- summary: List all dashboards
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - $ref: '#/components/parameters/Offset'
- - $ref: '#/components/parameters/Descending'
- - in: query
- name: limit
- schema:
- type: integer
- minimum: -1
- maximum: 100
- default: 20
- description: The non-zero number of dashboards to return
- - in: query
- name: owner
- description: A user identifier. Returns only dashboards where this user has the `owner` role.
- schema:
- type: string
- - in: query
- name: sortBy
- description: The column to sort by.
- schema:
- type: string
- enum:
- - ID
- - CreatedAt
- - UpdatedAt
- - in: query
- name: id
- description: 'A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used.'
- schema:
- type: array
- items:
- type: string
- - in: query
- name: orgID
- description: The identifier of the organization.
- schema:
- type: string
- - in: query
- name: org
- description: The name of the organization.
- schema:
- type: string
- responses:
- '200':
- description: All dashboards
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Dashboards'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /tasks:
- get:
- operationId: GetTasks
- tags:
- - Tasks
- summary: List all tasks
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: query
- name: name
- description: Returns task with a specific name.
- schema:
- type: string
- - in: query
- name: after
- schema:
- type: string
- description: Return tasks after a specified ID.
- - in: query
- name: user
- schema:
- type: string
- description: Filter tasks to a specific user ID.
- - in: query
- name: org
- schema:
- type: string
- description: Filter tasks to a specific organization name.
- - in: query
- name: orgID
- schema:
- type: string
- description: Filter tasks to a specific organization ID.
- - in: query
- name: status
- schema:
- type: string
- enum:
- - active
- - inactive
- description: Filter tasks by a status--"inactive" or "active".
- - in: query
- name: limit
- schema:
- type: integer
- minimum: -1
- maximum: 500
- default: 100
- description: The non-zero number of tasks to return
- - in: query
- name: type
- description: 'Type of task, unset by default.'
- required: false
- schema:
- default: ''
- type: string
- enum:
- - basic
- - system
- responses:
- '200':
- description: A list of tasks
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Tasks'
- default:
- description: Unexpected error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
+ - Variables
post:
- operationId: PostTasks
- tags:
- - Tasks
- summary: Create a new task
+ operationId: PostVariablesIDLabels
parameters:
- - $ref: '#/components/parameters/TraceSpan'
- requestBody:
- description: Task to create
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
required: true
+ schema:
+ type: string
+ requestBody:
content:
application/json:
schema:
- $ref: '#/components/schemas/TaskCreateRequest'
+ $ref: '#/components/schemas/LabelMapping'
+ description: Label to add
+ required: true
responses:
- '201':
- description: Task created
+ "201":
content:
application/json:
schema:
- $ref: '#/components/schemas/Task'
+ $ref: '#/components/schemas/LabelResponse'
+ description: The newly added label
default:
- description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /write:
- post:
- operationId: PostWrite
+ description: Unexpected error
+ summary: Add a label to a variable
tags:
- - Write
- summary: Write data
+ - Variables
+ /api/v2/variables/{variableID}/labels/{labelID}:
+ delete:
+ operationId: DeleteVariablesIDLabelsID
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: The variable ID.
+ in: path
+ name: variableID
+ required: true
+ schema:
+ type: string
+ - description: The label ID to delete.
+ in: path
+ name: labelID
+ required: true
+ schema:
+ type: string
+ responses:
+ "204":
+ description: Delete has been accepted
+ "404":
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Variable not found
+ default:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Unexpected error
+ summary: Delete a label from a variable
+ tags:
+ - Variables
+ /api/v2/write:
+ post:
description: |
Writes data to a bucket.
@@ -6204,126 +6182,141 @@ paths:
- data in [line protocol](https://docs.influxdata.com/influxdb/cloud/reference/syntax/line-protocol) format.
For more information and examples, see [Write data with the InfluxDB API](https://docs.influxdata.com/influxdb/cloud/write-data/developer-tools/api).
- requestBody:
- description: Data in line protocol format.
+ operationId: PostWrite
+ parameters:
+ - $ref: '#/components/parameters/TraceSpan'
+ - description: When present, the header value tells the database that compression
+ is applied to the line protocol in the request body.
+ in: header
+ name: Content-Encoding
+ schema:
+ default: identity
+ description: The header value specifies that the line protocol in the request
+ body is encoded with gzip or not encoded with identity.
+ enum:
+ - gzip
+ - identity
+ type: string
+ - description: The header value indicates the format of the data in the request
+ body.
+ in: header
+ name: Content-Type
+ schema:
+ default: text/plain; charset=utf-8
+ description: |
+ `text/plain` specifies line protocol. `UTF-8` is the default character set.
+ enum:
+ - text/plain
+ - text/plain; charset=utf-8
+ - application/vnd.influx.arrow
+ type: string
+ - description: The header value indicates the size of the entity-body, in bytes,
+ sent to the database. If the length is greater than the database's `max
+ body` configuration option, the server responds with status code `413`.
+ in: header
+ name: Content-Length
+ schema:
+ description: The length in decimal number of octets.
+ type: integer
+ - description: The header value specifies the response format.
+ in: header
+ name: Accept
+ schema:
+ default: application/json
+ description: The response format for errors.
+ enum:
+ - application/json
+ type: string
+ - description: The parameter value specifies the destination organization for
+ writes. The database writes all points in the batch to this organization.
+ If you provide both `orgID` and `org` parameters, `org` takes precedence.
+ in: query
+ name: org
required: true
+ schema:
+ description: Organization name or ID.
+ type: string
+ - description: The parameter value specifies the ID of the destination organization
+ for writes. If both `orgID` and `org` are specified, `org` takes precedence.
+ in: query
+ name: orgID
+ schema:
+ type: string
+ - description: The destination bucket for writes.
+ in: query
+ name: bucket
+ required: true
+ schema:
+ description: All points within batch are written to this bucket.
+ type: string
+ - description: The precision for the unix timestamps within the body line-protocol.
+ in: query
+ name: precision
+ schema:
+ $ref: '#/components/schemas/WritePrecision'
+ requestBody:
content:
text/plain:
schema:
- type: string
format: byte
- parameters:
- - $ref: '#/components/parameters/TraceSpan'
- - in: header
- name: Content-Encoding
- description: 'When present, the header value tells the database that compression is applied to the line protocol in the request body.'
- schema:
- type: string
- description: The header value specifies that the line protocol in the request body is encoded with gzip or not encoded with identity.
- default: identity
- enum:
- - gzip
- - identity
- - in: header
- name: Content-Type
- description: The header value indicates the format of the data in the request body.
- schema:
- type: string
- description: |
- `text/plain` specifies line protocol. `UTF-8` is the default character set.
- default: text/plain; charset=utf-8
- enum:
- - text/plain
- - text/plain; charset=utf-8
- - application/vnd.influx.arrow
- - in: header
- name: Content-Length
- description: 'The header value indicates the size of the entity-body, in bytes, sent to the database. If the length is greater than the database''s `max body` configuration option, the server responds with status code `413`.'
- schema:
- type: integer
- description: The length in decimal number of octets.
- - in: header
- name: Accept
- description: The header value specifies the response format.
- schema:
- type: string
- description: The response format for errors.
- default: application/json
- enum:
- - application/json
- - in: query
- name: org
- description: 'The parameter value specifies the destination organization for writes. The database writes all points in the batch to this organization. If you provide both `orgID` and `org` parameters, `org` takes precedence.'
- required: true
- schema:
- type: string
- description: Organization name or ID.
- - in: query
- name: orgID
- description: 'The parameter value specifies the ID of the destination organization for writes. If both `orgID` and `org` are specified, `org` takes precedence.'
- schema:
- type: string
- - in: query
- name: bucket
- description: The destination bucket for writes.
- required: true
- schema:
- type: string
- description: All points within batch are written to this bucket.
- - in: query
- name: precision
- description: The precision for the unix timestamps within the body line-protocol.
- schema:
- $ref: '#/components/schemas/WritePrecision'
+ type: string
+ description: Data in line protocol format.
+ required: true
responses:
- '204':
- description: 'InfluxDB validated the request data format and accepted the data for writing to the bucket. `204` doesn''t indicate a successful write operation since writes are asynchronous. See [how to check for write errors](https://docs.influxdata.com/influxdb/cloud/write-data/troubleshoot).'
- '400':
- description: Bad request. The line protocol data in the request is malformed. The response body contains the first malformed line in the data. InfluxDB rejected the batch and did not write any data.
+ "204":
+ description: InfluxDB validated the request data format and accepted the
+ data for writing to the bucket. `204` doesn't indicate a successful write
+ operation since writes are asynchronous. See [how to check for write errors](https://docs.influxdata.com/influxdb/cloud/write-data/troubleshoot).
+ "400":
content:
application/json:
- schema:
- $ref: '#/components/schemas/LineProtocolError'
examples:
measurementSchemaFieldTypeConflict:
summary: Field type conflict thrown by an explicit bucket schema
value:
code: invalid
- message: 'partial write error (2 written): unable to parse ''air_sensor,service=S1,sensor=L1 temperature="90.5",humidity=70.0 1632850122'': schema: field type for field "temperature" not permitted by schema; got String but expected Float'
- '401':
- description: |
- Unauthorized. The error may indicate one of the following:
- * The `Authorization: Token` header is missing or malformed.
- * The API token value is missing from the header.
- * The token does not have sufficient permissions to write to this organization and bucket.
+ message: 'partial write error (2 written): unable to parse ''air_sensor,service=S1,sensor=L1
+ temperature="90.5",humidity=70.0 1632850122'': schema: field
+ type for field "temperature" not permitted by schema; got String
+ but expected Float'
+ schema:
+ $ref: '#/components/schemas/LineProtocolError'
+ description: Bad request. The line protocol data in the request is malformed.
+ The response body contains the first malformed line in the data. InfluxDB
+ rejected the batch and did not write any data.
+ "401":
content:
application/json:
- schema:
- $ref: '#/components/schemas/Error'
examples:
tokenNotAuthorized:
summary: Token is not authorized to access the organization or resource
value:
code: unauthorized
message: unauthorized access
- '404':
- description: 'Not found. A requested resource was not found. The response body contains the requested resource type, e.g. `organization name` or `bucket`, and name.'
- content:
- application/json:
schema:
$ref: '#/components/schemas/Error'
+ description: |
+ Unauthorized. The error may indicate one of the following:
+ * The `Authorization: Token` header is missing or malformed.
+ * The API token value is missing from the header.
+ * The token does not have sufficient permissions to write to this organization and bucket.
+ "404":
+ content:
+ application/json:
examples:
resource-not-found:
summary: Not found error
value:
code: not found
message: bucket "air_sensor" not found
- '413':
- description: Request entity too large. The payload exceeded the 50MB size limit. InfluxDB rejected the batch and did not write any data.
+ schema:
+ $ref: '#/components/schemas/Error'
+ description: Not found. A requested resource was not found. The response
+ body contains the requested resource type, e.g. `organization name` or
+ `bucket`, and name.
+ "413":
content:
text/html:
- schema:
- type: string
examples:
dataExceedsSizeLimit:
summary: Cloud response
@@ -6336,671 +6329,1091 @@ paths:
nginx