Skip to content
Konstera
Capability catalogue
macrosread

macros.list

List ticket-system macros / canned responses

List the tenant's macros / canned responses from the ticket system for one-way mirror into Konstera (ADR-022 §Macros). Zendesk: GET /api/v2/macros.json. Freshdesk: GET /api/v2/admin/canned_responses. Intercom: GET /articles (closest analogue). Called on first connection sync and on manual re-sync.

Effect
read
Fanout
no
Cache TTL
none
Traits
none

Request arguments

Passed as the args parameter to ctx.capability.call("macros.list", …).

FieldTypeRequiredDescription
folderstringnoFilter to a specific folder/category if the ticket system groups macros

Response

Returned by ctx.capability.call("macros.list", …).

Array; each element is an object with the following fields.

FieldTypeRequiredDescription
titlestringyes
folderstringno
bodyHtmlstringyes
variablesarray<object>noVariable substitution hints — connector-normalised
externalIdstringyesTicket-system macro id — used as the dedup key when syncing into Konstera macros table

Example call

From inside your agent's handle(). The kernel resolves macros.list to the tenant's connector binding at invocation time.

response = await ctx.capability.call(
    "macros.list",
    args={
        "folder": "...",
    },
)

See SDK quickstart for the full agent handler template; code examples covers invocation patterns including fanout and error handling.