Timeplus (v1)

Download OpenAPI specification:Download

Welcome to the Timeplus HTTP REST API specification.

Authentication

ApiKeyAuth

use API keys created via the CreateAPIKey API to authorize API access.

Security Scheme Type API Key
Header parameter name: X-Api-Key

Alerts internal

start an alert.

Start the alert with the given ID. If the alert is already running, the API does nothing and returns 204.

Authorizations:
path Parameters
id
required
string

Alert ID

Responses

Response samples

Content type
application/json
{
  • "code": 0,
  • "message": "string"
}

Sinks internal

start a sink.

Start the sink with the given ID. If the sink is already running, the API does nothing and returns 204.

Authorizations:
path Parameters
id
required
string

Sink ID

Responses

Response samples

Content type
application/json
{
  • "code": 0,
  • "message": "string"
}

Alerts v1beta2

stop an alert.

Stop the alert with the given ID.

Authorizations:
path Parameters
id
required
string

alert ID

Responses

Response samples

Content type
application/json
{
  • "code": 0,
  • "message": "string"
}

API keys v1beta2

List API keys

list all API keys created by current user

Authorizations:

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create an API key

create a new API key with optional expiration, the created API key represents the owner thus has the same permissions as the owner

Authorizations:
Request Body schema: application/json

API Key parameters

expire_at
string <RFC3339>

define the expiration time of the API key by specifying the exact date time, cannot use with expire_in

expire_in
string

define the expiration time of the API key by specifying the amount of time to count from now, cannot use with expire_at

name
required
string [ 3 .. 64 ] characters

the name of the API key

Responses

Request samples

Content type
application/json
{
  • "expire_at": "2022-06-07T12:00:00Z08:00",
  • "expire_in": "24h",
  • "name": "string"
}

Response samples

Content type
application/json
{
  • "api_key": "vthm5o5ENm4TaX5RcixG+DB8q9ALQtrU3VlfQBVFv1lQauWeDXR87MI5kOjXG",
  • "created_at": 1257894000,
  • "expire_at": 1257894000,
  • "id": "string",
  • "name": "string",
  • "permissions": [
    ]
}

Delete an API key

delete the API key with the specified ID

Authorizations:
path Parameters
id
required
string

API key ID

Responses

Response samples

Content type
application/json
{
  • "code": 0,
  • "message": "string"
}

Dashboards v1beta2

list dashboards.

Get all dashboards.

Authorizations:

Responses

Response samples

Content type
application/json
[
  • {
    }
]

create a dashboard.

create a dashboard.

Authorizations:
Request Body schema: application/json

dashboard request parameters

description
string
name
required
string
Array of objects (dashboard.Panel) [ items ]

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "panels": [
    ]
}

Response samples

Content type
application/json
{
  • "created_at": "2023-02-01 23:22:59",
  • "created_by": {
    },
  • "description": "string",
  • "id": "string",
  • "last_updated_at": "2023-02-05 11:12:13",
  • "last_updated_by": {
    },
  • "name": "string",
  • "panels": [
    ]
}

delete a dashboard.

Delete the dashboard with the given ID.

Authorizations:
path Parameters
id
required
string

dashboard ID

Responses

Response samples

Content type
application/json
{
  • "code": 0,
  • "message": "string"
}

get a dashboard.

get a dashboard.

Authorizations:
path Parameters
id
required
string

dashboard ID

Responses

Response samples

Content type
application/json
{
  • "created_at": "2023-02-01 23:22:59",
  • "created_by": {
    },
  • "description": "string",
  • "id": "string",
  • "last_updated_at": "2023-02-05 11:12:13",
  • "last_updated_by": {
    },
  • "name": "string",
  • "panels": [
    ]
}

Update a dashboard.

Update the specific dashboard with the given ID.

Authorizations:
path Parameters
id
required
string

dashboard ID

Request Body schema: application/json

update dashboard request parameters

description
string
name
required
string
Array of objects (dashboard.Panel) [ items ]

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "panels": [