61 lines
2.8 KiB
JSON
61 lines
2.8 KiB
JSON
{
|
|
"schema": 1,
|
|
"id": "slack",
|
|
"name": "Slack",
|
|
"version": "1.0.0",
|
|
"description": "Slack thread pills: thread links (a reply link joins its thread), thread reads, channel names learned from any Slack result.",
|
|
"category": "chat",
|
|
"icon": "slack",
|
|
"color": "#6e3d55",
|
|
"author": "gabrielvidal",
|
|
"settings": {
|
|
"subtitle": "Which conversations show Slack thread pills",
|
|
"fields": [
|
|
{ "key": "slackWorkspace", "label": "Workspace", "type": "text",
|
|
"help": "The `<workspace>` of `<workspace>.slack.com` — builds the link of a thread known only by its channel + timestamp (a thread read, `conv add C0…/1791….818179`)" },
|
|
{ "key": "channelMap", "label": "Channel names", "type": "textarea",
|
|
"help": "One `C0123ABCD=name` per line (a leading `#` is optional) — wins over the names learned from transcripts; DMs always read `DM`" },
|
|
{ "key": "workers", "label": "Runners", "type": "list",
|
|
"help": "Runner ids whose conversations show Slack pills (`local` = the lab); empty = every runner" },
|
|
{ "key": "cwdGlobs", "label": "Folders", "type": "list",
|
|
"help": "Working-directory globs (`~/work/acme*`); empty = anywhere" },
|
|
{ "key": "notifPills", "label": "Pills on notifications", "type": "checkbox", "default": false,
|
|
"help": "Show the thread pill on the pushes of the conversations in scope" }
|
|
]
|
|
},
|
|
"resources": [
|
|
{
|
|
"id": "slack",
|
|
"label": "Slack thread",
|
|
"urlRegex": "^https://(?P<workspace>[\\w-]+)\\.slack\\.com/archives/(?P<channel>[CDG][A-Z0-9]{6,})/p(?P<ptss>\\d{10})(?P<ptsu>\\d{6})(?:\\?(?:[^#\\s]*&)?thread_ts=(?P<tss>\\d{10})\\.(?P<tsu>\\d{6}))?",
|
|
"idRegex": "^(?P<channel>[CDG][A-Z0-9]{6,})/(?P<tss>\\d{10})\\.(?P<tsu>\\d{6})$",
|
|
"idTemplate": "{channel}/{tss|ptss}.{tsu|ptsu}",
|
|
"urlTemplate": "https://{workspace|config.slackWorkspace}.slack.com/archives/{channel}/p{tss|ptss}{tsu|ptsu}",
|
|
"labelTemplate": [{ "match": "^D", "template": "DM" }, { "template": "#{name}" }],
|
|
"titleToken": [{ "match": "^D", "template": "" }, { "template": "{label}" }],
|
|
"namesGroup": "channel",
|
|
"dateGroup": "tss",
|
|
"ignoreUrlRegex": "^https://[\\w-]+\\.slack\\.com/(?!archives/[CDG][A-Z0-9]{6,}/p\\d{16})",
|
|
"toolExtractors": [
|
|
{
|
|
"tool": "mcp__*slack_read_thread*",
|
|
"inputTemplate": "{channel_id|channel}/{message_ts}",
|
|
"tagOnCall": true
|
|
},
|
|
{
|
|
"tool": "*",
|
|
"channelMapRegex": [
|
|
"Channel: #(?P<name>[\\w.-]+) \\(ID: (?P<id>[CDG][A-Z0-9]{6,})\\)",
|
|
"<#(?P<id>[CDG][A-Z0-9]{6,})\\|(?P<name>[\\w.-]+)>"
|
|
],
|
|
"textHint": ["Channel: #", "<#"]
|
|
}
|
|
],
|
|
"icon": "slack",
|
|
"color": "fuchsia",
|
|
"clickAction": "open",
|
|
"priority": 30
|
|
}
|
|
]
|
|
}
|