Longview

Longview Clients List

get
https://api.linode.com/v4/longview/clients

Returns a paginated list of Longview Clients you have access to. Longview Client is used to monitor stats on your Linode with the help of the Longview Client application.

Query Parameters

page
integer > = 1
Default: 1

The page of a collection to return.

page_size
integer [25 .. 500]
Default: 100

The number of items to return per page.

Request Samples

curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/clients

Response Samples

{
  "data": [
    {
      "id": "",
      "created": "2018-01-01T00:01:01.000Z",
      "label": "client789",
      "updated": "2018-01-01T00:01:01.000Z",
      "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
      "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
      "apps": {
        "apache": true,
        "nginx": "",
        "mysql": true
      }
    }
  ],
  "page": 1,
  "pages": 1,
  "results": 1
}

Responses

200: A paginated list of Longview Clients.

data
array of objects
id
integer

This Client's unique ID.

created
string

When this Longview Client was created.

label
Filterable
string[a-zA-Z0-9-_]{3,32}

This Client's unique label. This is for display purposes only.

updated
string

When this Longview Client was last updated.

api_key
string

The API key for this Client, used when configuring the Longview Client application on your Linode.

Returns as [REDACTED] if you do not have read-write access to this client.

install_code
string

The install code for this Client, used when configuring the Longview Client application on your Linode.

Returns as [REDACTED] if you do not have read-write access to this client.

apps
object

The apps this Client is monitoring on your Linode. This is configured when you install the Longview Client application, and is present here for information purposes only.

apache
boolean

If True, the Apache Longview Client module is monitoring Apache on your server.

nginx
boolean

If True, the Nginx Longview Client module is monitoring Nginx on your server.

mysql
boolean

If True, the MySQL Longview Client modules is monitoring MySQL on your server.

page
integer

The current page.

pages
integer

The total number of pages.

results
integer

The total number of results.

default: Error

errors
array of objects
reason
string

What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.

field
string

The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.

Longview Client Create

post
https://api.linode.com/v4/longview/clients

Creates a Longview Client. This Client will not begin monitoring the status of your server until you configure the Longview Client application on your Linode using the returning install_code and api_key.

Request Body Schema

label
Filterable
string [3 .. 32] characters [a-zA-Z0-9-_]{3,32}

This Client's unique label. This is for display purposes only.

Request Samples

curl -H "Content-Type: application/json" \
    -H "Authorization: Bearer $TOKEN" \
    -X POST -d '{
      "label": "client789"
    }' \
    https://api.linode.com/v4/longview/clients

Response Samples

{
  "created": "2018-01-01T00:01:01.000Z",
  "updated": "2018-01-01T00:01:01.000Z",
  "id": 1234,
  "label": "client789",
  "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
  "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
  "apps": {
    "apache": true,
    "nginx": false,
    "mysql": true
  }
}

Responses

200: Longview Client created successfully.

created
string <date-time>

When this Longview Client was created.

updated
string <date-time>

When this Longview Client was last updated.

id
integer

This Client's unique ID.

label
Filterable
string [3 .. 32] characters [a-zA-Z0-9-_]{3,32}

This Client's unique label. This is for display purposes only.

api_key
string

The API key for this Client, used when configuring the Longview Client application on your Linode.

Returns as [REDACTED] if you do not have read-write access to this client.

install_code
string

The install code for this Client, used when configuring the Longview Client application on your Linode.

Returns as [REDACTED] if you do not have read-write access to this client.

apps
object

The apps this Client is monitoring on your Linode. This is configured when you install the Longview Client application, and is present here for information purposes only.

apache
boolean

If True, the Apache Longview Client module is monitoring Apache on your server.

nginx
boolean

If True, the Nginx Longview Client module is monitoring Nginx on your server.

mysql
boolean

If True, the MySQL Longview Client modules is monitoring MySQL on your server.

default: Error

errors
array of objects
reason
string

What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.

field
string

The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.