Tag
The Tag API allows you to list, rename, and merge tags in the Eagle library.
Endpoints Overview
GET
/api/v2/tag/get
List all tags
POST
/api/v2/tag/get
List tags (body)
GET
/api/v2/tag/getRecentTags
Get recently used tags
GET
/api/v2/tag/getStarredTags
Get starred tags
POST
/api/v2/tag/update
Rename a tag
POST
/api/v2/tag/merge
Merge two tags
GET /api/v2/tag/get
List all tags in the library. Returns paginated results.
Query Parameters
namestring (optional) — Filter tags by name (substring match)offsetinteger (optional) — Pagination offset, default0limitinteger (optional) — Pagination limit, default50, max1000
Response
Examples
POST /api/v2/tag/get
Same as GET, but accepts filter parameters in the JSON body.
Request Body
namestring (optional) — Filter tags by name (substring match)offsetinteger (optional) — Pagination offset, default0limitinteger (optional) — Pagination limit, default50, max1000
Example
GET /api/v2/tag/getRecentTags
Get recently used tags. Returns paginated results.
Query Parameters
offsetinteger (optional) — Pagination offset, default0limitinteger (optional) — Pagination limit, default50, max1000
Response
Example
GET /api/v2/tag/getStarredTags
Get starred (pinned) tags. Returns paginated results.
Query Parameters
offsetinteger (optional) — Pagination offset, default0limitinteger (optional) — Pagination limit, default50, max1000
Response
Same format as /api/v2/tag/getRecentTags.
Example
POST /api/v2/tag/update
Rename an existing tag. All items using this tag will be updated automatically.
Request Body
originalNamestring (required) — The current tag namenamestring (required) — The new tag name
Response
Returns the updated tag object.
Example
POST /api/v2/tag/merge
Merge a source tag into a target tag. All items with the source tag will have it replaced by the target tag. The source tag is removed after merging.
Request Body
sourcestring (required) — The tag name to merge from (will be removed)targetstring (required) — The tag name to merge into (will be kept)
Response
Example
Tag Properties
Tags returned by the API contain the following properties:
name
string
Tag name
count
integer
Number of items using this tag
color
string
Tag color (empty string if unset)
groups
string[]
Array of tag group IDs
pinyin
string
Pinyin representation of the name
Last updated