@archastro/sdk
    Preparing search index...
    Index

    Constructors

    Methods

    Constructors

    Methods

    • Add tags to a thread Adds one or more status tags to the thread and returns the updated thread. Any participant of the thread — a human member or an agent member — may edit tags; this is broader than the owner/admin permission required to update other thread fields. Adding a tag the thread already has is a no-op. Tags are normalized (trimmed and lowercased) and may contain only lowercase letters, numbers, hyphens, and underscores.

      Parameters

      • thread: string

        Thread ID (thr_...) to untag.

      • input: { tags: string[] }

        Request body.

        • tags: string[]

          Tags to add to the thread.

      Returns Promise<Thread>

      The thread object after the tags were added.

    • Remove tags from a thread Removes one or more status tags from the thread and returns the updated thread. Removing a tag the thread does not have is a no-op. Any participant of the thread — a human member or an agent member — may edit tags. Supply the tags to remove as repeated query parameters, e.g. ?tags[]=blocked&tags[]=needs-review.

      Parameters

      • thread: string

        Thread ID (thr_...) to untag.

      Returns Promise<Thread>

      The thread object after the tags were removed.

    • Replace a thread's tags Replaces the thread's entire set of status tags with the provided list and returns the updated thread. Passing an empty array clears all tags. Any participant of the thread — a human member or an agent member — may edit tags. Tags are normalized (trimmed and lowercased) and may contain only lowercase letters, numbers, hyphens, and underscores.

      Parameters

      • thread: string

        Thread ID (thr_...) to untag.

      • input: { tags: string[] }

        Request body.

        • tags: string[]

          The complete set of tags for the thread. An empty array clears all tags.

      Returns Promise<Thread>

      The thread object after its tags were replaced.