Longview v4.176.0
Longview Clients List
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.
Authorizations
| personalAccessToken | |
| oauth | longview:read_only | 
Query Parameters
| page | 
 The page of a collection to return.  | 
| page_size | 
 The number of items to return per page.  | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/clients
linode-cli longview list
Response Samples
{
  "data": [
    {
      "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
      "apps": {
        "apache": true,
        "mysql": true,
        "nginx": false
      },
      "created": "2018-01-01T00:01:01",
      "id": 789,
      "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
      "label": "client789",
      "updated": "2018-01-01T00:01:01"
    }
  ],
  "page": 1,
  "pages": 1,
  "results": 1
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
data  | array
of objects
  | ||||||||||||||||||||
page  | integerThe current page.  | ||||||||||||||||||||
pages  | integerThe total number of pages.  | ||||||||||||||||||||
results  | integerThe total number of results.  | 
errors  | array
of objects
  | 
Longview Client Create
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.
Authorizations
| personalAccessToken | |
| oauth | longview:read_write | 
Request Samples
curl -H "Content-Type: application/json" \
    -H "Authorization: Bearer $TOKEN" \
    -X POST -d '{
      "label": "client789"
    }' \
    https://api.linode.com/v4/longview/clients
linode-cli longview create \
  --label client789
Request Body Schema
label  | string
3..32
charactersThis Client’s unique label. This is for display purposes only.  | 
Response Samples
{
  "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
  "apps": {
    "apache": true,
    "mysql": true,
    "nginx": false
  },
  "created": "2018-01-01T00:01:01",
  "id": 789,
  "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
  "label": "client789",
  "updated": "2018-01-01T00:01:01"
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
api_key  | stringThe API key for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
apps  | objectThe 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. 
  | ||||||
created  | string<date-time>When this Longview Client was created.  | ||||||
id  | integerThis Client’s unique ID.  | ||||||
install_code  | stringThe install code for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
label  | string
3..32
charactersThis Client’s unique label. This is for display purposes only.  | ||||||
updated  | string<date-time>When this Longview Client was last updated.  | 
errors  | array
of objects
  | 
Longview Client Delete
Deletes a Longview Client from your Account.
All information stored for this client will be lost.
This does not uninstall the Longview Client application for your Linode - you must do that manually.
Authorizations
| personalAccessToken | |
| oauth | longview:read_write | 
Path Parameters
| clientId | integerRequiredThe Longview Client ID to access.  | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    -X DELETE \
    https://api.linode.com/v4/longview/clients/789
linode-cli longview delete 789
Response Samples
{}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
errors  | array
of objects
  | 
Longview Client View
Returns a single Longview Client you can access.
Authorizations
| personalAccessToken | |
| oauth | longview:read_only | 
Path Parameters
| clientId | integerRequiredThe Longview Client ID to access.  | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/clients/789
linode-cli longview view 789
Response Samples
{
  "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
  "apps": {
    "apache": true,
    "mysql": true,
    "nginx": false
  },
  "created": "2018-01-01T00:01:01",
  "id": 789,
  "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
  "label": "client789",
  "updated": "2018-01-01T00:01:01"
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
api_key  | stringThe API key for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
apps  | objectThe 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. 
  | ||||||
created  | string<date-time>When this Longview Client was created.  | ||||||
id  | integerThis Client’s unique ID.  | ||||||
install_code  | stringThe install code for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
label  | string
3..32
charactersThis Client’s unique label. This is for display purposes only.  | ||||||
updated  | string<date-time>When this Longview Client was last updated.  | 
errors  | array
of objects
  | 
Longview Client Update
Updates a Longview Client. This cannot update how it monitors your server; use the Longview Client application on your Linode for monitoring configuration.
Authorizations
| personalAccessToken | |
| oauth | longview:read_write | 
Path Parameters
| clientId | integerRequiredThe Longview Client ID to access.  | 
Request Samples
curl -H "Content-Type: application/json" \
    -H "Authorization: Bearer $TOKEN" \
    -X POST -d '{
      "label": "client789"
    }' \
    https://api.linode.com/v4/longview/clients/789
linode-cli longview update 789 \
  --label client789
Request Body Schema
label  | string
3..32
charactersThis Client’s unique label. This is for display purposes only.  | 
Response Samples
{
  "api_key": "BD1B4B54-D752-A76D-5A9BD8A17F39DB61",
  "apps": {
    "apache": true,
    "mysql": true,
    "nginx": false
  },
  "created": "2018-01-01T00:01:01",
  "id": 789,
  "install_code": "BD1B5605-BF5E-D385-BA07AD518BE7F321",
  "label": "client789",
  "updated": "2018-01-01T00:01:01"
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
api_key  | stringThe API key for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
apps  | objectThe 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. 
  | ||||||
created  | string<date-time>When this Longview Client was created.  | ||||||
id  | integerThis Client’s unique ID.  | ||||||
install_code  | stringThe install code for this Client, used when configuring the Longview Client application on your Linode. Returns as   | ||||||
label  | string
3..32
charactersThis Client’s unique label. This is for display purposes only.  | ||||||
updated  | string<date-time>When this Longview Client was last updated.  | 
errors  | array
of objects
  | 
Longview Plan View
Get the details of your current Longview plan. This returns a LongviewSubscription object for your current Longview Pro plan, or an empty set {} if your current plan is Longview Free.
You must have at least one of the following global
User Grants in order to access this endpoint:
"account_access": read_write"account_access": read_only"longview_subscription": true"add_longview": true
To update your subscription plan, send a request to Update Longview Plan.
Authorizations
| personalAccessToken | |
| oauth | longview:read_only | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/plan
linode-cli longview plan-view
Response Samples
{
  "clients_included": 10,
  "id": "longview-10",
  "label": "Longview Pro 10 pack",
  "price": {
    "hourly": 0.06,
    "monthly": 40
  }
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
clients_included  | integerThe number of Longview Clients that may be created with this Subscription tier.  | ||||
id  | stringEnum:
 longview-3
longview-10
longview-40
longview-100The unique ID of this Subscription tier.  | ||||
label  | stringA display name for this Subscription tier.  | ||||
price  | objectPricing information about this Subscription tier. 
  | 
errors  | array
of objects
  | 
Longview Plan Update
Update your Longview plan to that of the given subcription ID. This returns a LongviewSubscription object for the updated Longview Pro plan, or an empty set {} if the updated plan is Longview Free.
You must have "longview_subscription": true configured as a global
User Grant in order to access this endpoint.
You can send a request to the
List Longview Subscriptions endpoint to receive the details, including id’s, of each plan.
Authorizations
| personalAccessToken | |
| oauth | longview:read_write | 
Request Samples
curl -H "Content-Type: application/json" \
    -H "Authorization: Bearer $TOKEN" \
    -X PUT -d '{
        "longview_subscription": "longview-10"
    }' \
    https://api.linode.com/v4/longview/plan
linode-cli longview plan-update --longview_subscription longview-10
Request Body Schema
longview_subscription Nullable  | stringEnum:
 longview-3
longview-10
longview-40
longview-100The subscription ID for a particular Longview plan. A value of  You can send a request to the List Longview Subscriptions endpoint to receive the details of each plan.  | 
Response Samples
{
  "clients_included": 10,
  "id": "longview-10",
  "label": "Longview Pro 10 pack",
  "price": {
    "hourly": 0.06,
    "monthly": 40
  }
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
clients_included  | integerThe number of Longview Clients that may be created with this Subscription tier.  | ||||
id  | stringEnum:
 longview-3
longview-10
longview-40
longview-100The unique ID of this Subscription tier.  | ||||
label  | stringA display name for this Subscription tier.  | ||||
price  | objectPricing information about this Subscription tier. 
  | 
errors  | array
of objects
  | 
Longview Subscriptions List
Returns a paginated list of available Longview Subscriptions. This is a public endpoint and requires no authentication.
Authorizations
Query Parameters
| page | 
 The page of a collection to return.  | 
| page_size | 
 The number of items to return per page.  | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/subscriptions
linode-cli longview subscriptions-list
Response Samples
{
  "data": [
    {
      "clients_included": 10,
      "id": "longview-10",
      "label": "Longview Pro 10 pack",
      "price": {
        "hourly": 0.06,
        "monthly": 40
      }
    }
  ],
  "page": 1,
  "pages": 1,
  "results": 1
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
data  | array
of objects
  | ||||||||||||
page  | integerThe current page.  | ||||||||||||
pages  | integerThe total number of pages.  | ||||||||||||
results  | integerThe total number of results.  | 
errors  | array
of objects
  | 
Longview Subscription View
Get the Longview plan details as a single LongviewSubscription object for the provided subscription ID. This is a public endpoint and requires no authentication.
Authorizations
Path Parameters
| subscriptionId | stringRequiredThe Longview Subscription to look up.  | 
Request Samples
curl -H "Authorization: Bearer $TOKEN" \
    https://api.linode.com/v4/longview/subscriptions/longview-10
linode-cli longview subscription-view \
  longview-10
Response Samples
{
  "clients_included": 10,
  "id": "longview-10",
  "label": "Longview Pro 10 pack",
  "price": {
    "hourly": 0.06,
    "monthly": 40
  }
}{
  "errors": [
    {
      "field": "fieldname",
      "reason": "fieldname must be a valid value"
    }
  ]
}Responses
clients_included  | integerThe number of Longview Clients that may be created with this Subscription tier.  | ||||
id  | stringEnum:
 longview-3
longview-10
longview-40
longview-100The unique ID of this Subscription tier.  | ||||
label  | stringA display name for this Subscription tier.  | ||||
price  | objectPricing information about this Subscription tier. 
  | 
errors  | array
of objects
  |