UNPKG

openapi-directory

Version:

Building & bundling https://github.com/APIs-guru/openapi-directory for easy use from JS

1 lines 352 kB
{"openapi":"3.0.0","info":{"description":"One way to interact with the Slack platform is its HTTP RPC-based Web API, a collection of methods requiring OAuth 2.0-based user, bot, or workspace tokens blessed with related OAuth scopes.","title":"Slack","version":"1.0.6","x-apisguru-categories":["collaboration","messaging"],"x-logo":{"url":"http://static.tumblr.com/wvuzcz9/LlKncfhmp/slack_logo_240.png"},"x-origin":[{"format":"swagger","url":"https://raw.githubusercontent.com/slackapi/slack-api-specs/master/web-api/slack_web_openapi_v2.json","version":"2.0"}],"x-providerName":"slack.com"},"externalDocs":{"description":"Learn more about the Slack Web API","url":"https://api.slack.com/web"},"paths":{"/api.test":{"get":{"description":"Checks API calling code.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/api.test"},"operationId":"api_test","parameters":[{"description":"example property to return","in":"query","name":"foo","schema":{"type":"string"}},{"description":"Error response to return","in":"query","name":"error","schema":{"type":"string"}}],"responses":{"200":{"description":"Standard success response","content":{"application/json":{"schema":{"additionalProperties":{"type":"object"},"description":"Schema for successful response api.test method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"api.test success schema","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Artificial error response","content":{"application/json":{"schema":{"additionalProperties":{"type":"object"},"description":"Schema for error response api.test method","properties":{"error":{"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"api.test error schema","type":"object"},"examples":{"response":{"value":{"args":{"error":"my_error"},"error":"my_error","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["api"]}},"/apps.permissions.info":{"get":{"description":"Returns list of permissions this app has on a team.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/apps.permissions.info"},"operationId":"apps_permissions_info","parameters":[{"description":"Authentication token. Requires scope: `none`","in":"query","name":"token","schema":{"type":"string"}}],"responses":{"200":{"description":"Standard success response when used with a user token","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default success template","type":"object"},"examples":{"response":{"value":{"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}}}}}},"default":{"description":"Standard failure response when used with an invalid token","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default error template","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["apps.permissions","apps"]}},"/apps.permissions.request":{"get":{"description":"Allows an app to request additional scopes","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/apps.permissions.request"},"operationId":"apps_permissions_request","parameters":[{"description":"A comma separated list of scopes to request for","in":"query","name":"scopes","schema":{"type":"string"}},{"description":"Authentication token. Requires scope: `none`","in":"query","name":"token","schema":{"type":"string"}},{"description":"Token used to trigger the permissions API","in":"query","name":"trigger_id","schema":{"type":"string"}}],"responses":{"200":{"description":"Standard success response when used with a user token","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from apps.permissions.request method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"apps.permissions.request schema","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Standard failure response when trigger_id is invalid","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from apps.permissions.request method","properties":{"error":{"enum":["invalid_trigger","trigger_exchanged","invalid_scope","invalid_user","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"apps.permissions.request error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_trigger_id","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["apps.permissions","apps"]}},"/apps.permissions.resources.list":{"get":{"description":"Returns list of resource grants this app has on a team.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/apps.permissions.resources.list"},"operationId":"apps_permissions_resources_list","parameters":[{"description":"Paginate through collections of data by setting the `cursor` parameter to a `next_cursor` attribute returned by a previous request's `response_metadata`. Default value fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more detail.","in":"query","name":"cursor","schema":{"type":"string"}},{"description":"Authentication token. Requires scope: `none`","in":"query","name":"token","schema":{"type":"string"}},{"description":"The maximum number of items to return.","in":"query","name":"limit","schema":{"type":"integer"}}],"responses":{"200":{"description":"Typical successful paginated response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response apps.permissions.resources.list method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"},"resources":{"items":{"properties":{"id":{"title":"An ID for a resource","type":"string","x-examples":["T0DES3UAN","C0ABC1ABC"]},"type":{"title":"The type of resource the `id` corresponds to","type":"string","x-examples":["team","channel","mpim"]}},"type":"object"},"type":"array"},"response_metadata":{"additionalProperties":true,"properties":{"next_cursor":{"type":"string","x-examples":["dGVhbTpDMUg5UkVTR0w="]}},"required":["next_cursor"],"type":"object"}},"required":["ok","resources"],"title":"apps.permissions.resources.list success schema","type":"object"},"examples":{"response":{"value":{"ok":true,"resources":[{"id":"T0DES3UAN","type":"team"},{"id":"D024BFF1M","type":"app_home"},{"id":"C024BE91L","type":"channel"}],"response_metadata":{"next_cursor":"dGVhbTpDMUg5UkVTR0w="}}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from apps.permissions.resources.list method","properties":{"error":{"enum":["invalid_cursor","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"apps.permissions.resources.list error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_cursor","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["apps.permissions.resources","apps"]}},"/apps.permissions.scopes.list":{"get":{"description":"Returns list of scopes this app has on a team.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/apps.permissions.scopes.list"},"operationId":"apps_permissions_scopes_list","parameters":[{"description":"Authentication token. Requires scope: `none`","in":"query","name":"token","schema":{"type":"string"}}],"responses":{"200":{"description":"Typical successful paginated response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response api.permissions.scopes.list method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"},"scopes":{"additionalProperties":true,"properties":{"app_home":{"$ref":"#/components/schemas/objs_scopes"},"channel":{"$ref":"#/components/schemas/objs_scopes"},"group":{"$ref":"#/components/schemas/objs_scopes"},"im":{"$ref":"#/components/schemas/objs_scopes"},"mpim":{"$ref":"#/components/schemas/objs_scopes"},"team":{"$ref":"#/components/schemas/objs_scopes"},"user":{"$ref":"#/components/schemas/objs_scopes"}},"type":"object"}},"required":["ok","scopes"],"title":"api.permissions.scopes.list success schema","type":"object"},"examples":{"response":{"value":{"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":[]}}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from apps.permissions.scopes.list method","properties":{"error":{"enum":["not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"apps.permissions.scopes.list error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["apps.permissions.scopes","apps"]}},"/auth.revoke":{"get":{"description":"Revokes a token.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/auth.revoke"},"operationId":"auth_revoke","parameters":[{"description":"Setting this parameter to `1` triggers a _testing mode_ where the specified token will not actually be revoked.","in":"query","name":"test","schema":{"type":"boolean"}},{"description":"Authentication token. Requires scope: `none`","in":"query","name":"token","schema":{"type":"string"}}],"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from auth.revoke method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"},"revoked":{"type":"boolean"}},"required":["ok","revoked"],"title":"auth.revoke schema","type":"object"},"examples":{"response":{"value":{"ok":true,"revoked":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from auth.revoke method","properties":{"error":{"enum":["not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"auth.revoke error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["auth"]}},"/auth.test":{"get":{"description":"Checks authentication & identity.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/auth.test"},"operationId":"auth_test","parameters":[{"description":"Authentication token. Requires scope: `none`","in":"header","name":"token","schema":{"type":"string"}}],"responses":{"200":{"description":"Standard success response when used with a user token","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response auth.test method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"},"team":{"type":"string"},"team_id":{"$ref":"#/components/schemas/defs_team"},"url":{"type":"string"},"user":{"type":"string"},"user_id":{"$ref":"#/components/schemas/defs_user_id"}},"required":["ok","url","team","user","team_id","user_id"],"title":"auth.test success schema","type":"object"},"examples":{"response":{"value":{"ok":true,"team":"Subarachnoid Workspace","team_id":"T12345678","url":"https://subarachnoid.slack.com/","user":"grace","user_id":"W12345678"}}}}}},"default":{"description":"Standard failure response when used with an invalid token","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response auth.test method","properties":{"error":{"enum":["not_authed","invalid_auth","token_revoked","account_inactive","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"auth.test error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["none"]}],"tags":["auth"]}},"/bots.info":{"get":{"description":"Gets information about a bot user.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/bots.info"},"operationId":"bots_info","parameters":[{"description":"Authentication token. Requires scope: `users:read`","in":"query","name":"token","schema":{"type":"string"}},{"description":"Bot user to get info on","in":"query","name":"bot","schema":{"type":"string"}}],"responses":{"200":{"description":"When successful, returns bot info by bot ID.","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from bots.info method","properties":{"bot":{"additionalProperties":true,"properties":{"app_id":{"$ref":"#/components/schemas/defs_app_id"},"deleted":{"type":"boolean"},"icons":{"additionalProperties":true,"properties":{"image_36":{"format":"uri","type":"string"},"image_48":{"format":"uri","type":"string"},"image_72":{"format":"uri","type":"string"}},"required":["image_36","image_48","image_72"],"type":"object"},"id":{"$ref":"#/components/schemas/defs_bot_id"},"name":{"type":"string"},"updated":{"type":"integer"},"user_id":{"$ref":"#/components/schemas/defs_user_id"}},"required":["id","deleted","name","updated","app_id","icons"],"type":"object"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","bot"],"title":"bots.info schema","type":"object"},"examples":{"response":{"value":{"bot":{"app_id":"A061BLERW","deleted":false,"icons":{"image_36":"https://...","image_48":"https://...","image_72":"https://..."},"id":"B061F7JQ1","name":"commandeer","updated":1449272004},"ok":true}}}}}},"default":{"description":"When no bot can be found, it returns an error.","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from bots.info method","properties":{"error":{"enum":["bot_not_found","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"bots.info error schema","type":"object"},"examples":{"response":{"value":{"error":"bot_not_found","ok":false}}}}}}},"security":[{"slackAuth":["users:read"]}],"tags":["bots"]}},"/channels.archive":{"post":{"description":"Archives a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.archive"},"operationId":"channels_archive","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"channel":{"description":"Channel to archive","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from channels.archive method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"channels.archive success schema","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.archive method","properties":{"error":{"enum":["channel_not_found","already_archived","cant_archive_general","restricted_action","not_authed","invalid_auth","account_inactive","user_is_bot","user_is_restricted","user_is_ultra_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required","team_added_to_org","missing_charset","superfluous_charset"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.archive error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.create":{"post":{"description":"Creates a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.create"},"operationId":"channels_create","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"validate":{"description":"Whether to return errors on invalid channel name instead of modifying it to meet the specified criteria.","type":"boolean"},"name":{"description":"Name of channel to create","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response resulting in a new channel","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.create method","properties":{"channel":{"$ref":"#/components/schemas/objs_channel"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channel"],"title":"channels.create error schema","type":"object"},"examples":{"response":{"value":{"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","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}}}}}},"default":{"description":"Example error response when an invalid name is provided","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.create method","properties":{"error":{"enum":["name_taken","restricted_action","no_channel","invalid_name_required","invalid_name_punctuation","invalid_name_maxlength","invalid_name_specials","invalid_name","not_authed","invalid_auth","account_inactive","user_is_bot","user_is_restricted","user_is_ultra_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required","team_added_to_org","missing_charset","superfluous_charset"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.create error schema","type":"object"},"examples":{"response":{"value":{"detail":"Value passed for `name` contained unallowed special characters.","error":"invalid_name_specials","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.history":{"get":{"description":"Fetches history of messages and events from a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.history"},"operationId":"channels_history","parameters":[{"description":"Number of messages to return, between 1 and 1000.","in":"query","name":"count","schema":{"type":"integer"}},{"description":"Include `unread_count_display` in the output?","in":"query","name":"unreads","schema":{"type":"boolean"}},{"description":"Include messages with latest or oldest timestamp in results.","in":"query","name":"inclusive","schema":{"type":"boolean"}},{"description":"Authentication token. Requires scope: `channels:history`","in":"query","name":"token","schema":{"type":"string"}},{"description":"Start of time range of messages to include in results.","in":"query","name":"oldest","schema":{"type":"number"}},{"description":"Channel to fetch history for.","in":"query","name":"channel","schema":{"type":"string"}},{"description":"End of time range of messages to include in results.","in":"query","name":"latest","schema":{"type":"number"}}],"responses":{"200":{"description":"Typical success response containing the channel's history","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.history method","properties":{"has_more":{"type":"boolean"},"messages":{"items":{"$ref":"#/components/schemas/objs_message"},"minItems":1,"type":"array","uniqueItems":true},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","messages","has_more"],"title":"channels.history success schema","type":"object"},"examples":{"response":{"value":{"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}}}}}},"default":{"description":"Error response when the specified channel cannot be found","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.history method","properties":{"error":{"enum":["channel_not_found","invalid_ts_latest","invalid_ts_oldest","not_authed","invalid_auth","account_inactive","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.history error schema","type":"object"},"examples":{"response":{"value":{"error":"channel_not_found","ok":false}}}}}}},"security":[{"slackAuth":["channels:history"]}],"tags":["channels"]}},"/channels.info":{"get":{"description":"Gets information about a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.info"},"operationId":"channels_info","parameters":[{"description":"Authentication token. Requires scope: `channels:read`","in":"query","name":"token","schema":{"type":"string"}},{"description":"Set this to `true` to receive the locale for this channel. Defaults to `false`","in":"query","name":"include_locale","schema":{"type":"boolean"}},{"description":"Channel to get info on","in":"query","name":"channel","schema":{"type":"string"}}],"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.info method","properties":{"channel":{"$ref":"#/components/schemas/objs_channel"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channel"],"title":"channels.info success schema","type":"object"},"examples":{"response":{"value":{"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}}}}}},"default":{"description":"Error response when the specified channel cannot be found","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.info method","properties":{"error":{"enum":["channel_not_found","not_authed","invalid_auth","account_inactive","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required","team_added_to_org","missing_charset","superfluous_charset"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.info error schema","type":"object"},"examples":{"response":{"value":{"error":"channel_not_found","ok":false}}}}}}},"security":[{"slackAuth":["channels:read"]}],"tags":["channels"]}},"/channels.invite":{"post":{"description":"Invites a user to a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.invite"},"operationId":"channels_invite","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"user":{"description":"User to invite to channel.","type":"string"},"channel":{"description":"Channel to invite user to.","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.invite method","properties":{"channel":{"$ref":"#/components/schemas/objs_channel"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channel"],"title":"channels.invite error schema","type":"object"},"examples":{"response":{"value":{"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"},"members":["U0G9QF9C6","U1QNSQB9U"],"name":"busting","name_normalized":"busting","previous_names":[],"purpose":{"creator":"U0G9QF9C6","last_set":1503435128,"value":"My Purpose"},"topic":{"creator":"U0G9QF9C6","last_set":1503435128,"value":"My Topic"},"unread_count":0,"unread_count_display":0},"ok":true}}}}}},"default":{"description":"A somewhat typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.invite method","properties":{"error":{"enum":["channel_not_found","user_not_found","cant_invite_self","not_in_channel","already_in_channel","is_archived","cant_invite","too_many_users","ura_max_channels","not_authed","invalid_auth","account_inactive","user_is_bot","user_is_restricted","user_is_ultra_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required","team_added_to_org","missing_charset","superfluous_charset"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.invite error schema","type":"object"},"examples":{"response":{"value":{"error":"cant_invite","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.join":{"post":{"description":"Joins a channel, creating it if needed.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.join"},"operationId":"channels_join","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"validate":{"description":"Whether to return errors on invalid channel name instead of modifying it to meet the specified criteria.","type":"boolean"},"name":{"description":"Name of channel to join","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from channels.join method","properties":{"already_in_channel":{"type":"boolean"},"channel":{"$ref":"#/components/schemas/objs_channel"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channel"],"title":"channels.join schema","type":"object"},"examples":{"response":{"value":{"already_in_channel":true,"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,"members":["U0G9QF9C6","U1QNSQB9U"],"name":"busting","name_normalized":"busting","previous_names":[],"purpose":{"creator":"U0G9QF9C6","last_set":1503435128,"value":"My Purpose"},"topic":{"creator":"U0G9QF9C6","last_set":1503435128,"value":"My Topic"}},"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from channels.join method","properties":{"error":{"enum":["channel_not_found","name_taken","restricted_action","no_channel","is_archived","invalid_name_required","invalid_name_punctuation","invalid_name_maxlength","invalid_name_specials","invalid_name","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","user_is_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.join error schema","type":"object"},"examples":{"response":{"value":{"error":"channel_not_found","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.kick":{"post":{"description":"Removes a user from a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.kick"},"operationId":"channels_kick","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"user":{"description":"User to remove from channel.","type":"string"},"channel":{"description":"Channel to remove user from.","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from channels.kick method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"channels.kick schema","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from channels.kick method","properties":{"error":{"enum":["channel_not_found","user_not_found","cant_kick_self","not_in_channel","cant_kick_from_general","restricted_action","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","user_is_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.kick error schema","type":"object"},"examples":{"response":{"value":{"error":"not_in_channel","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.leave":{"post":{"description":"Leaves a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.leave"},"operationId":"channels_leave","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"channel":{"description":"Channel to leave","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default success template","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default error template","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.list":{"get":{"description":"Lists all channels in a Slack team.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.list"},"operationId":"channels_list","parameters":[{"description":"Exclude the `members` collection from each `channel`","in":"query","name":"exclude_members","schema":{"type":"boolean"}},{"description":"Paginate through collections of data by setting the `cursor` parameter to a `next_cursor` attribute returned by a previous request's `response_metadata`. Default value fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more detail.","in":"query","name":"cursor","schema":{"type":"string"}},{"description":"Authentication token. Requires scope: `channels:read`","in":"query","name":"token","schema":{"type":"string"}},{"description":"The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the users list hasn't been reached.","in":"query","name":"limit","schema":{"type":"integer"}},{"description":"Exclude archived channels from the list","in":"query","name":"exclude_archived","schema":{"type":"boolean"}}],"responses":{"200":{"description":"Typical cursored success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.list method","properties":{"channels":{"items":{"$ref":"#/components/schemas/objs_channel"},"minItems":1,"type":"array","uniqueItems":true},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channels"],"title":"channels.list success schema","type":"object"},"examples":{"response":{"value":{"channels":[{"created":1449709280,"creator":"U0G9QF9C6","id":"C0G9QF9GW","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,"members":["U0G9QF9C6","U0G9WFXNZ"],"name":"random","name_normalized":"random","num_members":2,"previous_names":[],"purpose":{"creator":"","last_set":0,"value":"A place for non-work-related flimflam, faffing, hodge-podge or jibber-jabber you'd prefer to keep out of more focused work-related channels."},"topic":{"creator":"U0G9QF9C6","last_set":1449709352,"value":"Other stuff"}},{"created":1449709280,"creator":"U0G9QF9C6","id":"C0G9QKBBL","is_archived":false,"is_channel":true,"is_general":true,"is_member":true,"is_mpim":false,"is_org_shared":false,"is_private":false,"is_shared":false,"members":["U0G9QF9C6","U0G9WFXNZ"],"name":"general","name_normalized":"general","num_members":2,"previous_names":[],"purpose":{"creator":"U0G9QF9C6","last_set":1449709334,"value":"To talk about anything!"},"topic":{"creator":"U0G9QF9C6","last_set":1449709364,"value":"Talk about anything!"}}],"ok":true,"response_metadata":{"next_cursor":"dGVhbTpDMUg5UkVTR0w="}}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.list method","properties":{"error":{"enum":["not_authed","invalid_auth","account_inactive","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.list error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:read"]}],"tags":["channels"]}},"/channels.mark":{"post":{"description":"Sets the read cursor in a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.mark"},"operationId":"channels_mark","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"ts":{"description":"Timestamp of the most recently seen message.","type":"number"},"channel":{"description":"Channel to set reading cursor in.","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response channels.mark method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"channels.mark success schema","type":"object"},"examples":{"response":{"value":{"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response channels.mark method","properties":{"error":{"enum":["channel_not_found","invalid_timestamp","not_in_channel","not_authed","invalid_auth","account_inactive","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","invalid_json","json_not_object","request_timeout","upgrade_required"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.mark error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.rename":{"post":{"description":"Renames a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.rename"},"operationId":"channels_rename","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"validate":{"description":"Whether to return errors on invalid channel name instead of modifying it to meet the specified criteria.","type":"boolean"},"name":{"description":"New name for channel.","type":"string"},"channel":{"description":"Channel to rename","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from channels.rename method","properties":{"channel":{"$ref":"#/components/schemas/objs_channel"},"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok","channel"],"title":"channels.rename schema","type":"object"},"examples":{"response":{"value":{"channel":{"created":1477445146,"creator":"U2U85N1RZ","id":"C2U875RJN","is_archived":false,"is_channel":true,"is_general":false,"is_member":false,"is_mpim":false,"is_org_shared":false,"is_private":false,"is_shared":false,"members":[],"name":"humans-and-bots","name_normalized":"humans-and-bots","previous_names":["humans"],"purpose":{"creator":"U2U85N1RZ","last_set":1509475801,"value":"the purpose of this channel is to bring people and robots together in harmony"},"topic":{"creator":"U2U85N1RZ","last_set":1509475775,"value":"here be robots"},"unlinked":0},"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from channels.rename method","properties":{"error":{"enum":["channel_not_found","not_in_channel","not_authorized","invalid_name","name_taken","invalid_name_required","invalid_name_punctuation","invalid_name_maxlength","invalid_name_specials","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","user_is_bot","user_is_restricted","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.rename error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.replies":{"get":{"description":"Retrieve a thread of messages posted to a channel","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.replies"},"operationId":"channels_replies","parameters":[{"description":"Unique identifier of a thread's parent message","in":"query","name":"thread_ts","schema":{"type":"number"}},{"description":"Authentication token. Requires scope: `channels:history`","in":"query","name":"token","schema":{"type":"string"}},{"description":"Channel to fetch thread from","in":"query","name":"channel","schema":{"type":"string"}}],"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default success template","type":"object"},"examples":{"response":{"value":{"has_more":false,"messages":[{"last_read":"1509484885.000082","replies":[{"ts":"1509484424.000601","user":"U2U85N1RZ"},{"ts":"1509484885.000082","user":"U2U85N1RZ"}],"reply_count":2,"subscribed":true,"text":"This is a channel message","thread_ts":"1485913694.000025","ts":"1485913694.000025","type":"message","unread_count":0,"user":"U2X9P5FEL"},{"parent_user_id":"U2X9P5FEL","text":"This is a thread reply","thread_ts":"1485913694.000025","ts":"1509484424.000601","type":"message","user":"U2U85N1RZ"},{"parent_user_id":"U2X9P5FEL","text":"This is another thread reply","thread_ts":"1485913694.000025","ts":"1509484885.000082","type":"message","user":"U2U85N1RZ"}],"ok":true}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default error template","type":"object"},"examples":{"response":{"value":{"error":"thread_not_found","ok":false}}}}}}},"security":[{"slackAuth":["channels:history"]}],"tags":["channels"]}},"/channels.setPurpose":{"post":{"description":"Sets the purpose for a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.setPurpose"},"operationId":"channels_setPurpose","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"purpose":{"description":"The new purpose","type":"string"},"channel":{"description":"Channel to set the purpose of","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for successful response from channels.setPurpose method","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"},"purpose":{"type":"string"}},"required":["ok","purpose"],"title":"channels.setPurpose schema","type":"object"},"examples":{"response":{"value":{"ok":true,"purpose":"My special purpose"}}}}}},"default":{"description":"Typical error response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Schema for error response from channels.setPurpose method","properties":{"error":{"enum":["channel_not_found","not_in_channel","is_archived","too_long","user_is_restricted","not_authed","invalid_auth","account_inactive","token_revoked","no_permission","org_login_required","invalid_arg_name","invalid_array_arg","invalid_charset","invalid_form_data","invalid_post_type","missing_post_type","team_added_to_org","invalid_json","json_not_object","request_timeout","upgrade_required","fatal_error"],"type":"string"},"ok":{"$ref":"#/components/schemas/defs_ok_false"}},"required":["ok","error"],"title":"channels.setPurpose error schema","type":"object"},"examples":{"response":{"value":{"error":"invalid_auth","ok":false}}}}}}},"security":[{"slackAuth":["channels:write"]}],"tags":["channels"]}},"/channels.setTopic":{"post":{"description":"Sets the topic for a channel.","externalDocs":{"description":"API method documentation","url":"https://api.slack.com/methods/channels.setTopic"},"operationId":"channels_setTopic","parameters":[{"description":"Authentication token. Requires scope: `channels:write`","in":"header","name":"token","schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"topic":{"description":"The new topic","type":"string"},"channel":{"description":"Channel to set the topic of","type":"string"}}}}}},"responses":{"200":{"description":"Typical success response","content":{"application/json":{"schema":{"additionalProperties":true,"description":"Verbose schema not yet ready for this method.","properties":{"ok":{"$ref":"#/components/schemas/defs_ok_true"}},"required":["ok"],"title":"Default success template","type":"object"},"examples":{"response":{"value":{"ok":true,"topic":"To picture topicality"}}}}}},"defaul