Tags
Tags List
https://api.linode.com/v4/tags
Tags are User-defined labels attached to objects in your Account, such as Linodes. They are used for specifying and grouping attributes of objects that are relevant to the User.
This endpoint returns a paginated list of Tags on your account.
Important: You must be an unrestricted User in order to access, add, or modify Tags information.
Query Parameters
The page of a collection to return.
The number of items to return per page.
Request Samples
- Shell
curl -H "Authorization: Bearer $TOKEN" \
https://api.linode.com/v4/tags
Response Samples
- 200
- default
{
"data": [
{
"label": "example tag"
}
],
"page": 1,
"pages": 1,
"results": 1
}
Responses
200: A paginated list of Tags
default: Error
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.
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.
New Tag Create
https://api.linode.com/v4/tags
Creates a new Tag and optionally tags requested objects with it immediately.
Important: You must be an unrestricted User in order to access, add, or modify Tags information.
Request Body Schema
The new Tag.
A list of Domain IDs to apply the new Tag to. You must be allowed to read_write
all of the requested Domains, or the Tag will not be created and an error will be returned.
A list of Linode IDs to apply the new Tag to. You must be allowed to read_write
all of the requested Linodes, or the Tag will not be created and an error will be returned.
A list of NodeBalancer IDs to apply the new Tag to. You must be allowed to read_write
all of the requested NodeBalancers, or the Tag will not be created and an error will be returned.
A list of Volume IDs to apply the new Tag to. You must be allowed to read_write
all of the requested Volumes, or the Tag will not be created and an error will be returned.
Request Samples
- Shell
- CLI
curl -H "Content-Type: application/json" \
-H "Authorization: Bearer $TOKEN" \
-X POST -d '{
"label": "example tag",
"linodes": [123,456],
"volumes": [9082,10003]
}' \
https://api.linode.com/v4/tags
Response Samples
- 200
- default
{
"label": "example tag"
}
Responses
200: The new Tag.
A Label used for organization of objects on your Account.
default: Error
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.
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.