UNPKG

@itentialopensource/adapter-slack

Version:

This adapter integrates with system Slack

1,588 lines (1,587 loc) 438 kB
{ "openapi": "3.1.0", "info": { "title": "", "version": "1.0.0" }, "paths": { "/api.test": { "get": { "tags": [ "Api" ], "operationId": "getApitest", "description": "The parameters and request body are for method: getApitest. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" } } }, "example": { "ok": true } } } } }, "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "foo": { "type": "string" }, "error": { "type": "string" } } }, "example": { "foo": "foo", "error": "error" } } } } } }, "/apps.permissions.info": { "get": { "tags": [ "Appspermissions" ], "operationId": "getAppspermissionsinfo", "description": "The parameters and request body are for method: getAppspermissionsinfo. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "info": { "type": "object", "properties": { "app_home": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "ids": { "type": "array", "items": { "type": "string" } } } }, "scopes": { "type": "array", "items": { "type": "string" } } } }, "channel": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "excluded_ids": { "type": "object" }, "ids": { "type": "array", "items": { "type": "string" } }, "wildcard": { "type": "boolean" } } }, "scopes": { "type": "array", "items": { "type": "string" } } } }, "group": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "ids": { "type": "object" } } }, "scopes": { "type": "object" } } }, "im": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "ids": { "type": "object" } } }, "scopes": { "type": "object" } } }, "mpim": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "ids": { "type": "object" } } }, "scopes": { "type": "object" } } }, "team": { "type": "object", "properties": { "resources": { "type": "object", "properties": { "ids": { "type": "object" } } }, "scopes": { "type": "object" } } } } }, "ok": { "type": "boolean" } } }, "example": { "info": { "app_home": { "resources": { "ids": [ "D0C0NU1Q8", "D0BH95DLH" ] }, "scopes": [ "chat:write", "im:history", "im:read" ] }, "channel": { "resources": { "excluded_ids": [], "ids": [ "C061FA5PB" ], "wildcard": false }, "scopes": [ "channels:read" ] }, "group": { "resources": { "ids": [] }, "scopes": [] }, "im": { "resources": { "ids": [] }, "scopes": [] }, "mpim": { "resources": { "ids": [] }, "scopes": [] }, "team": { "resources": { "ids": [] }, "scopes": [] } }, "ok": true } } } } }, "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/apps.permissions.request": { "get": { "tags": [ "Appspermissions" ], "operationId": "getAppspermissionsrequest", "description": "The parameters and request body are for method: getAppspermissionsrequest. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" } } }, "example": { "ok": true } } } } }, "parameters": [ { "name": "scopes", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "triggerId", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/apps.permissions.resources.list": { "get": { "tags": [ "Appspermissionsresources" ], "operationId": "getAppspermissionsresourceslist", "description": "The parameters and request body are for method: getAppspermissionsresourceslist. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" }, "resources": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "type": { "type": "string" } } } }, "response_metadata": { "type": "object", "properties": { "next_cursor": { "type": "string" } } } } }, "example": { "ok": true, "resources": [ { "id": "T0DES3UAN", "type": "team" }, { "id": "D024BFF1M", "type": "app_home" }, { "id": "C024BE91L", "type": "channel" } ], "response_metadata": { "next_cursor": "dGVhbTpDMUg5UkVTR0w=" } } } } } }, "parameters": [ { "name": "cursor", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "limit", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/apps.permissions.scopes.list": { "get": { "tags": [ "Appspermissionsscopes" ], "operationId": "getAppspermissionsscopeslist", "description": "The parameters and request body are for method: getAppspermissionsscopeslist. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" }, "scopes": { "type": "object", "properties": { "app_home": { "type": "array", "items": { "type": "string" } }, "channel": { "type": "array", "items": { "type": "string" } }, "group": { "type": "array", "items": { "type": "string" } }, "im": { "type": "array", "items": { "type": "string" } }, "mpim": { "type": "array", "items": { "type": "string" } }, "team": { "type": "array", "items": { "type": "string" } }, "user": { "type": "object" } } } } }, "example": { "ok": true, "scopes": { "app_home": [ "chat:write", "im:history", "im:read" ], "channel": [ "channels:history", "chat:write" ], "group": [ "chat:write" ], "im": [ "chat:write" ], "mpim": [ "chat:write" ], "team": [ "users:read" ], "user": [] } } } } } }, "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/auth.revoke": { "get": { "tags": [ "Auth" ], "operationId": "getAuthrevoke", "description": "The parameters and request body are for method: getAuthrevoke. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" }, "revoked": { "type": "boolean" } } }, "example": { "ok": true, "revoked": true } } } } }, "parameters": [ { "name": "test", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/auth.test": { "get": { "tags": [ "Auth" ], "operationId": "getAuthtest", "description": "The parameters and request body are for method: getAuthtest. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" }, "team": { "type": "string" }, "team_id": { "type": "string" }, "url": { "type": "string" }, "user": { "type": "string" }, "user_id": { "type": "string" } } }, "example": { "ok": true, "team": "Subarachnoid Workspace", "team_id": "T12345678", "url": "https://subarachnoid.slack.com/", "user": "grace", "user_id": "W12345678" } } } } }, "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/bots.info": { "get": { "tags": [ "Bots" ], "operationId": "getBotsinfo", "description": "The parameters and request body are for method: getBotsinfo. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "bot": { "type": "object", "properties": { "app_id": { "type": "string" }, "deleted": { "type": "boolean" }, "icons": { "type": "object", "properties": { "image_36": { "type": "string" }, "image_48": { "type": "string" }, "image_72": { "type": "string" } } }, "id": { "type": "string" }, "name": { "type": "string" }, "updated": { "type": "number" } } }, "ok": { "type": "boolean" } } }, "example": { "bot": { "app_id": "A061BLERW", "deleted": false, "icons": { "image_36": "https://...", "image_48": "https://...", "image_72": "https://..." }, "id": "B061F7JQ1", "name": "commandeer", "updated": 1449272004 }, "ok": true } } } } }, "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "bot", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/channels.archive": { "post": { "tags": [ "Channels" ], "operationId": "postChannelsarchive", "description": "The parameters and request body are for method: postChannelsarchive. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "ok": { "type": "boolean" } } }, "example": { "ok": true } } } } }, "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "channel": { "type": "string" } } }, "example": { "channel": "channel" } } } } } }, "/channels.create": { "post": { "tags": [ "Channels" ], "operationId": "postChannelscreate", "description": "The parameters and request body are for method: postChannelscreate. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "channel": { "type": "object", "properties": { "created": { "type": "number" }, "creator": { "type": "string" }, "id": { "type": "string" }, "is_archived": { "type": "boolean" }, "is_channel": { "type": "boolean" }, "is_general": { "type": "boolean" }, "is_member": { "type": "boolean" }, "is_mpim": { "type": "boolean" }, "is_org_shared": { "type": "boolean" }, "is_private": { "type": "boolean" }, "is_shared": { "type": "boolean" }, "last_read": { "type": "string" }, "latest": { "type": "object" }, "members": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "name_normalized": { "type": "string" }, "previous_names": { "type": "object" }, "purpose": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "topic": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "unread_count": { "type": "number" }, "unread_count_display": { "type": "number" } } }, "ok": { "type": "boolean" } } }, "example": { "channel": { "created": 1502833204, "creator": "U061F7AUR", "id": "C0DEL09A5", "is_archived": false, "is_channel": true, "is_general": false, "is_member": true, "is_mpim": false, "is_org_shared": false, "is_private": false, "is_shared": false, "last_read": "0000000000.000000", "latest": null, "members": [ "U061F7AUR" ], "name": "endeavor", "name_normalized": "endeavor", "previous_names": [], "purpose": { "creator": "", "last_set": 0, "value": "" }, "topic": { "creator": "", "last_set": 0, "value": "" }, "unread_count": 0, "unread_count_display": 0 }, "ok": true } } } } }, "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "validate": { "type": "string" }, "name": { "type": "string" } } }, "example": { "validate": "validate", "name": "name" } } } } } }, "/channels.history": { "get": { "tags": [ "Channels" ], "operationId": "getChannelshistory", "description": "The parameters and request body are for method: getChannelshistory. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "has_more": { "type": "boolean" }, "latest": { "type": "string" }, "messages": { "type": "array", "items": { "type": "object", "properties": { "text": { "type": "string" }, "ts": { "type": "string" }, "type": { "type": "string" }, "user": { "type": "string" } } } }, "ok": { "type": "boolean" } } }, "example": { "has_more": false, "latest": "1358547726.000003", "messages": [ { "text": "Hello", "ts": "1358546515.000008", "type": "message", "user": "U2147483896" }, { "is_starred": true, "reactions": [ { "count": 3, "name": "space_invader", "users": [ "U1", "U2", "U3" ] }, { "count": 5, "name": "sweet_potato", "users": [ "U1", "U2", "U3", "U4", "U5" ] } ], "text": "World", "ts": "1358546515.000007", "type": "message", "user": "U2147483896" }, { "ts": "1358546515.000007", "type": "something_else" }, { "attachments": [ { "fallback": "This is an attachment fallback", "id": 1, "text": "Don't get too attached" } ], "bot_id": "B19LU7CSY", "subtype": "bot_message", "text": "Containment unit is 98% full", "ts": "1503435956.000247", "type": "message", "username": "ecto1138" } ], "ok": true } } } } }, "parameters": [ { "name": "count", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "unreads", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "inclusive", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "oldest", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "channel", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "latest", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/channels.info": { "get": { "tags": [ "Channels" ], "operationId": "getChannelsinfo", "description": "The parameters and request body are for method: getChannelsinfo. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "channel": { "type": "object", "properties": { "created": { "type": "number" }, "creator": { "type": "string" }, "id": { "type": "string" }, "is_archived": { "type": "boolean" }, "is_channel": { "type": "boolean" }, "is_general": { "type": "boolean" }, "is_member": { "type": "boolean" }, "is_mpim": { "type": "boolean" }, "is_org_shared": { "type": "boolean" }, "is_private": { "type": "boolean" }, "is_shared": { "type": "boolean" }, "last_read": { "type": "string" }, "latest": { "type": "object", "properties": { "attachments": { "type": "array", "items": { "type": "object", "properties": { "fallback": { "type": "string" }, "id": { "type": "number" }, "text": { "type": "string" } } } }, "bot_id": { "type": "string" }, "subtype": { "type": "string" }, "text": { "type": "string" }, "ts": { "type": "string" }, "type": { "type": "string" }, "username": { "type": "string" } } }, "members": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "name_normalized": { "type": "string" }, "previous_names": { "type": "array", "items": { "type": "string" } }, "purpose": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "topic": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "unread_count": { "type": "number" }, "unread_count_display": { "type": "number" } } }, "ok": { "type": "boolean" } } }, "example": { "channel": { "created": 1466025154, "creator": "U0G9QF9C6", "id": "C1H9RESGL", "is_archived": false, "is_channel": true, "is_general": false, "is_member": true, "is_mpim": false, "is_org_shared": false, "is_private": false, "is_shared": false, "last_read": "1503435939.000101", "latest": { "attachments": [ { "fallback": "This is an attachment fallback", "id": 1, "text": "Don't get too attached" } ], "bot_id": "B19LU7CSY", "subtype": "bot_message", "text": "Containment unit is 98% full", "ts": "1503435956.000247", "type": "message", "username": "ecto1138" }, "members": [ "U0G9QF9C6", "U1QNSQB9U" ], "name": "busting", "name_normalized": "busting", "previous_names": [ "dusting" ], "purpose": { "creator": "U0G9QF9C6", "last_set": 1503435128, "value": "Discuss busting ghosts" }, "topic": { "creator": "U0G9QF9C6", "last_set": 1503435128, "value": "Spiritual containment strategies" }, "unread_count": 1, "unread_count_display": 1 }, "ok": true } } } } }, "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "includeLocale", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "channel", "in": "query", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object" }, "example": {} } } } } }, "/channels.invite": { "post": { "tags": [ "Channels" ], "operationId": "postChannelsinvite", "description": "The parameters and request body are for method: postChannelsinvite. Same endpoint also used in methods:", "responses": { "200": { "description": "Successful operation", "content": { "application/json": { "schema": { "type": "object", "properties": { "channel": { "type": "object", "properties": { "created": { "type": "number" }, "creator": { "type": "string" }, "id": { "type": "string" }, "is_archived": { "type": "boolean" }, "is_channel": { "type": "boolean" }, "is_general": { "type": "boolean" }, "is_member": { "type": "boolean" }, "is_mpim": { "type": "boolean" }, "is_org_shared": { "type": "boolean" }, "is_private": { "type": "boolean" }, "is_shared": { "type": "boolean" }, "last_read": { "type": "string" }, "latest": { "type": "object", "properties": { "subtype": { "type": "string" }, "text": { "type": "string" }, "ts": { "type": "string" }, "type": { "type": "string" }, "user": { "type": "string" } } }, "members": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "name_normalized": { "type": "string" }, "previous_names": { "type": "object" }, "purpose": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "topic": { "type": "object", "properties": { "creator": { "type": "string" }, "last_set": { "type": "number" }, "value": { "type": "string" } } }, "unread_count": { "type": "number" }, "unread_count_display": { "type": "number" } } }, "ok": { "type": "boolean" } } }, "example": { "channel": { "created": 1466025154, "creator": "U0G9QF9C6", "id": "C1H9RESGL", "is_archived": false, "is_channel": true, "is_general": false, "is_member": true, "is_mpim": false, "is_org_shared": false, "is_private": false, "is_shared": false, "last_read": "1503435963.000307", "latest": { "subtype": "channel_leave", "text": "<@U1QNSQB9U|protobot> has left the channel", "ts": "1503435963.000307", "type": "message", "user": "U1QNSQB9U" },