Purpose

The tag route contains all endpoints related to tag management.

get all

This endpoint is used to retrieve all tags.

Request:
GET /api/v1/tags/all

Response:

[
    {
        "id": "baf5ba00-440c-4d8a-a614-be2cbf4c2beb",
        "name": "something",
        "user_id": "6b875d6c-7d4e-4ae3-931f-270604df1d7f",
        "parent_id": "1048e93b-b53e-4bdc-a1b7-98726ef65027"
    }
]
PropertyDescriptionTypeFilterableSortable
idid of the tagUUIDv4YesNo
namename of the tagstringYesNo
user_iduser_id that owns this tagUUIDv4NoNo
parent_idid of the parent tag, if specifiedUUIDv4?YesNo

get by id

This endpoint is used to retrieve a single tag by its id. You need to specify the id of the tag you want to retrieve in the request path.

Request:
GET /api/v1/tags/{tag_id}

Response:

{
    "id": "baf5ba00-440c-4d8a-a614-be2cbf4c2beb",
    "name": "something",
    "user_id": "6b875d6c-7d4e-4ae3-931f-270604df1d7f",
    "parent_id": "1048e93b-b53e-4bdc-a1b7-98726ef65027"
}
PropertyDescriptionType
idid of the tagUUIDv4
namename of the tagstring
user_iduser_id that owns this tagUUIDv4
parent_idid of the parent tag, if specifiedUUIDv4?

create tag

This endpoint is used to create a new tag.

Request:
POST /api/v1/tags

{
    "name": "something",
    "parent_id": "1048e93b-b53e-4bdc-a1b7-98726ef65027"
}
PropertyDescriptionType
namename of the tagstring
parent_idid of the parent tag, if specifiedUUIDv4?

update tag

This endpoint is used to update an existing tag.
You need to specify the id of the tag you want to modify in the request path.

Request:
PUT /api/v1/tags/{tag_id}

{
    "name": "something else",
    "parent_id": "1048e93b-b53e-4bdc-a1b7-98726ef65027"
}
PropertyDescriptionType
namename of the tagstring
parent_idid of the parent tag, if specifiedUUIDv4?

delete tag

This endpoint is used to delete an existing tag. This can be safely called even if the tag is still referenced in other places. Other tags that have the to be deleted tag as a parent will get null set as the parent_id. Transactions, etc will simply get this tag removed as well.
You need to specify the id of the tag you want to delete in the request path.

Request:
DELETE /api/v1/tags/{tag_id}