These docs are for v1.0. Click to read the latest docs for v2.0.

interface-iboardtagscommands

Interface: IBoardTagsCommands

Commands to interact and manipulate tags

Hierarchy

  • IBoardTagsCommands

Index

Methods

Methods

create

create(tags: OneOrMany<CreateTagRequest>): Promise<ITag[]>

Creates one or many tags as defined in the CreateTagRequest.

Requires scope: BOARDS:WRITE
Requires BoardPermission.EDIT_CONTENT for current user

Parameters:

NameTypeDescription
tagsOneOrMany<CreateTagRequest>Details of the tag being created. It may include what widgets will have the tag. A title is always required.

Returns: Promise<ITag[]>

A promise resolving into the created tags.


delete

delete(tags: InputTags): Promise<void>

Deletes one or many tags.

Requires scope: BOARDS:WRITE
Requires BoardPermission.EDIT_CONTENT for current user

Parameters:

NameTypeDescription
tagsInputTagsThe tags to be deleted.

Returns: Promise<void>

A promise resolving when the tags are deleted.


get

get(filterBy?: Record<string, unknown>): Promise<ITag[]>

Gets all tags in the board, optionally filtered as specific in filterBy

Requires scope: BOARDS:READ

Parameters:

NameTypeDescription
filterBy?Record<string, unknown>Conditions to filter tags.

Returns: Promise<ITag[]>

A promise resolving into the found tags.


update

update(tags: OneOrMany<UpdateTagRequest>): Promise<ITag[]>

Update one or many tags as defined in the UpdateTagRequest

Requires scope: BOARDS:WRITE
Requires BoardPermission.EDIT_CONTENT for current user

Parameters:

NameTypeDescription
tagsOneOrMany<UpdateTagRequest>The tags to be updated. An id is always required.

Returns: Promise<ITag[]>

A promise resolving into the updated tags.