Giter VIP home page Giter VIP logo

slack-api-specs's Introduction

slack-api-specs

This repository contains API specifications of Slack platform features and APIs.

⚠️ Not Accepting Contributions

Because our specifications are artifacts of an incredible machine, we cannot accept pull requests for this repo. Please file issues with suggestions or bugs with the spec itself. Feedback about the APIs or features the specs describe should be directed to Slack's developer support team.

Overview

You'll find OpenAPI specs for the Slack Web API and AsyncAPI specs for the Events API.

Read more about our open specification strategy in this announcement.

Specification menu

We continue to refine and expand schema and example coverage throughout all of our specifications.

How the specs are made

We use a combination of internal metadata, custom scripting, and old fashioned writing-by-hand to produce these specifications. They don't always tell the whole truth and are subject to author and operator error. They are really useful though.

Recent changes

Now we'll recount the major changes found in each new release of our specifications.

Using with external tools

Postman

It's possible to use slack_web_openapi_v2.json to generate a Postman Collection, but you must first modify the spec to be technically and factually invalid unfortunately.

Add a top-level "openapi": "3.0" attribute near where "swagger": "2.0" is defined. While openapi isn't a valid attribute for OpenAPI 2.0 schemas, and if it were, the version should be 2.0. Being wrong this way instructs Postman to do continue importing as a collection.

Postman doesn't pick up the defined hostname and path https://slack.com/api that precedes all Web API methods (for example, https://slack.com/api/chat.postMessage) as the {{baseUrl}} variable for the collection.

Populate {{baseUrl}} by first hovering over your collection in the navigation bar click on the action menu that appears. Then, select "Edit". A modal will appear. Click into the rightmost section, Variables which should have a green dot next to it. In the Initial Value column next to baseUrl, enter https://slack.com/api and then click Reset All. Once you see that both the initial and current values have been set, click update and your imported collection will properly use "https://slack.com/api" as its base domain.

slack-api-specs's People

Contributors

episod avatar filmaj avatar roach avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

slack-api-specs's Issues

Block Kit support

Description

The documentation already supports Block Kit. However, the changes to parameters/response are not yet reflected in this repository. Do you have any plans to work on it in the short term? If I can do something for it, I am keen to be involved in it.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

External select documentation problem

Description

We are trying to implement interactivity select with the external datasource as described here - https://api.slack.com/reference/block-kit/block-elements#external_select

Our select inside actions:

{
	"blocks": [{
		"type": "actions",
		"elements": [{
			"type": "external_select",
			"action_id": "subprocess",
			"placeholder": {
				"type": "plain_text",
				"text": "Subprocess"
			},
			"min_query_length": 4
		}]
	}]
}

Request for external options:

{
	"type": "block_suggestion",
	"action_id": "subprocess",
	"block_id": "+7x/Z",
	"value": "4367",
	"message": {
		"bot_id": "BNQSQ2ZDK",
		"type": "message",
		"text": "This content can't be displayed.",
		"user": "UNQCZ5C4U",
		"ts": "1570463370.018100",
		"team": "T2V37EATG",
		"blocks": [{
			"type": "actions",
			"block_id": "+7x/Z",
			"elements": [{
				"type": "external_select",
				"action_id": "subprocess",
				"placeholder": {
					"type": "plain_text",
					"text": "Subproess",
					"emoji": true
				},
				"min_query_length": 4
			}]
		}]
	}
}

Our response to POST with code 200 as application/json:

{
	"options": [{
		"text": {
			"type": "plain_text",
			"text": "Scoring"
		},
		"value": "Scoring"
	}, {
		"text": {
			"type": "plain_text",
			"text": "Delivery"
		},
		"value": "Delivery"
	}]
}

After this response we have the error: {ok: false, error: "invalid_response_json"} on Slack client.
What is the correct response format for this method?

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

chat.postEphemeral missing parameters

Description

Operation chat.postEphemeral (line 7184) does not specify all of the parameters as declared in the text docs, specifically:

  • icon_emoji
  • icon_url
  • username

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Q: Bot vs. User token for reminders methods

Description

The add reminders method (as well as complete and delete) only accepts a User token; however, I can assign the reminders:write scope to the Bot token, which would never come into play - why include the Bot token here?

Further, even when you do provide a User token and call the method via the Web API, the "Slackbot" is what adds the reminder in Slack, which is confusing. What is the interplay between the User and Bot token in this case of managing reminders via the API?

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

Deprecated endpoints not noted in spec

Description

There are a number of deprecated endpoints defined in the schema according the Slack methods documentation (specifically channels, im, groups, and mpim).

Since OpenAPI Specification has a deprecated boolean field, it would be helpful to include that to note which endpoints will not see further updates and will likely eventually be sunset.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Missing response_metadata and its next_cursor property in users.list response schema

Description

It looks like the /users.list response miss the definition of the object response_metadata and its next_cursor property.

FYI, the property is mentionned in the openapi example and in the official API documentation. To fix this, you probably only need to add this definition in the schema (inspired from next_cursor defintion in other endpoints):

 "response_metadata": {
    "properties": {
        "next_cursor": {
            "type": "string",
            "x-examples": [
                "dXNlcjpVMEc5V0ZYTlo="
            ]
        }
    },
    "required": [
        "next_cursor"
    ],
    "type": "object"
}

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Request not reaching Request URL

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • [ x] bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • [x ] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

  1. I have registered a Request URL and toggled on interactivity. I launch the shortcut and the request comes to the URL. Now I post a payload to view.Open API and the modal is opened
  2. I filled the details in the modal and request never reached the request URL
  3. The response is
{"ok":false,"error":"curl_error","code":0,"curl_errno":28,"curl_error":"Operation timed out after 3000 milliseconds with 0 bytes received","total_time":2.999589,"url":"http:\/\/<domain>\/thanks"}

Expected result:

I expect the view_submission event

Actual result:

Request didn't reach my API

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

Groups Create Child should be a GET

Groups Create Child should be a GET

groups_create_child is documented as a POST instead of a GET.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

You need to update the documentation for this API to be a GET.

See details here:
https://api.slack.com/methods/groups.createChild

Postman Collection

Description

What can we do to get your OpenAPI imported into Postman and published as a collection to the Postman network (https://explore.postman.com/)? Would offer one click access beyond the instructions on the README -- Plus it would be access via the network by 12 Million developers.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

[Question] Any plans on supplying specifications for the RTM API events?

Description

Is there any plans to supply Swagger specifications for the RTM messages? It would be very useful for SDKs out there to be able to generate code from official specifications instead of scraping the documentation website (which a lot of them are doing right now).

Examples of this happening:

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Inconsistent type of response field in /conversations.open

Description

In the specification of the Web API endpoint /conversations.open, the type of the created field in the response is string, while it is integer in definitions/objs_conversation. I think this should be corrected to integer for consistency. The Slack API documentation also shows this field to be of integer type.

What type of issue is this?

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Enhancement request: OpenAPI 3.0 support

Description

It would be great to work with an OpenAPI 3.0 specification for the Web API in a future version of the spec.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

[Bug] Specification is invalid(?)

Description

Specification seems to be invalid from what I can tell. I tried opening it in the online Swagger Editor at https://editor.swagger.io and I get the following errors:

Errors

Semantic error at definitions.objs_user.properties.tz.type
Schema "type" key must be a string
Jump to line 12541

Semantic error at definitions.objs_user_profile.properties.fields.type
Schema "type" key must be a string
Jump to line 12776

Semantic error at definitions.objs_team_profile_field.properties.possible_values.type
Schema "type" key must be a string
Jump to line 12827

Semantic error at definitions.objs_team_profile_field.properties.options.type
Schema "type" key must be a string
Jump to line 12840

Semantic error at definitions.objs_user_profile_short.properties.first_name.type
Schema "type" key must be a string
Jump to line 13164

Semantic error at definitions.objs_user_profile_shortest.properties.first_name.type
Schema "type" key must be a string
Jump to line 13622

Most of these look like this in the specification:

"type": [
  "null",
  "string"
]

I think Swagger/OpenAPI uses another schema to mark fields as nullable.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

The provided openapi schema is invalid

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

go to https://editor.swagger.io/

import the schema

view the errors

Errors

 
Structural error at definitions.objs_channel.properties.latest.items
should be object
Jump to line 190
Structural error at definitions.objs_conversation.items
should be object
Jump to line 315
Structural error at definitions.objs_group.properties.latest.items
should be object
Jump to line 1059
Structural error at definitions.objs_message.properties.bot_id.items
should be object
Jump to line 1204
Structural error at definitions.objs_resources.properties.excluded_ids.items.items
should be object
Jump to line 1386
Structural error at definitions.objs_resources.properties.ids.items.items
should be object
Jump to line 1392
Structural error at definitions.objs_subteam.properties.auto_type.items
should be object
Jump to line 1426
Structural error at definitions.objs_subteam.properties.deleted_by.items
should be object
Jump to line 1441
Structural error at definitions.objs_user.items
should be object
Jump to line 1612
Semantic error at definitions.objs_user_profile.properties.fields.type
Schema "type" key must be a string
Jump to line 1797
Structural error at definitions.objs_user_profile.properties.fields.type
should be equal to one of the allowed values
allowedValues: array, boolean, integer, number, object, string
Jump to line 1797
Structural error at paths./channels.history.get.responses.200.schema.properties.channel_actions_ts.items
should be object
Jump to line 6122
Structural error at paths./channels.replies.get.responses.200.schema.properties.messages.items.items
should be object
Jump to line 7196
Structural error at paths./conversations.history.get.responses.200.schema.properties.channel_actions_ts.items
should be object
Jump to line 9434
Structural error at paths./conversations.open.post.responses.200.schema.properties.channel.items
should be object
Jump to line 10534
Structural error at paths./conversations.replies.get.responses.200.schema.properties.messages.items.items
should be object
Jump to line 10863
Structural error at paths./files.info.get.responses.200.schema.properties.content_html.type
should be equal to one of the allowed values
allowedValues: array, boolean, integer, number, object, string
Jump to line 12189
Structural error at paths./groups.history.get.responses.200.schema.properties.channel_actions_ts.items
should be object
Jump to line 13591
Structural error at paths./im.history.get.responses.200.schema.properties.channel_actions_ts.items
should be object
Jump to line 14909
Structural error at paths./im.replies.get.responses.200.schema.properties.messages.items.items
should be object
Jump to line 15375
Structural error at paths./mpim.history.get.responses.200.schema.properties.channel_actions_ts.items
should be object
Jump to line 15791
Structural error at paths./mpim.replies.get.responses.200.schema.properties.messages.items.items
should be object
Jump to line 16183
Structural error at paths./pins.list.get.responses.200.schema.items
should be object
Jump to line 16738
Semantic error at paths./pins.list.get.responses.200.schema.items.0.properties.items.items
`items` must be an object
Jump to line 16742
Structural error at paths./reactions.get.get.responses.200.schema.items
should be object
Jump to line 17088
Structural error at paths./reactions.list.get.responses.200.schema.properties.items.items.items
should be object
Jump to line 17300
Structural error at paths./stars.list.get.responses.200.schema.properties.items.items.items
should be object
Jump to line 18352
Structural error at paths./users.identity.get.responses.200.schema.items
should be object
Jump to line 20426
 

Trying to use this project to generate a client library with the provided spec and a lot of schemas aren't translated into code.

is this something that can be fixed?

cc @Roach @episod

/stars.list should have items in its response

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

The response from /stars.list API should include items for normal cases. Thus, responses.200.schema.properties / responses.200.examples should have items under the hierarchy.

I am willing to send a pull request to fix this if needed.

Reproducible in:

I found the discrepancy when reading slack_web_openapi_v2.json.

Steps to reproduce:

None.

Expected result:

I've mentioned in the Bug Report part.

Actual result:

I've mentioned in the Bug Report part.

Attachments:

None.

Cannot post long links to Slack

I'm not sure if we reached the correct repository, we created a Slack App and used https://api.slack.com/messaging/sending to send messages to a channel. This message contains a very long link, which we can't shorten anymore.

Slack is always returning HTTP 413 "Message too long". How to overcome this problem?

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Suggestion: Prevent duplicate messages by offering an optional post ID field

Description

Whether we are using the API from a client or server application, it may happen that the application using the slack API successfully sent a message, but that the connection got interrupted during the request, thus resulting in the application considering the post as a failure even though the slack API received and processed the request successfully. Usually, in case of failures, applications often perform retries (with back-off policy), this can result in duplicate messages. To avoid this, a new optional field can be added to the slack API, and if there is already a message posted with this ID, then the API could result in a 409 status code result instead of re-posting the msg.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

New surface: sidebar

Description

I'd like to suggest the creation of a new surface: sidebar.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Idea

The idea is to be able to customize the sidebar of a specific channel.
Example of usage:

  • Each product on my company has a channel, in the sidebar we'd like to display info like changelog, latested version.
  • Each POD has a channel: we'd like to display relevant info about each POD: logo, roles, projects we are in
  • An app related to gamification could use the sidebar to show the ranking.
  • An app for poll could show the history and open polls.
  • A Github app could display open PR/issues

The sidebar could request new content every time it's opened.
The app could also push new content (like the incoming webhook).
It could also display buttons/actions

Please, let me know what do you think,

Implementing `views.*` methods?

Description

Hello Slack folks!

I was trying to implement the new modal views in one of my apps, but the views.open, views.push, and views.update methods are not available in slack-ruby/slack-ruby-client . After reading the source for that library, it looks like the methods are missing because they are not in the OpenAPI spec.

Is support for these new methods coming? Is there a timeline for implementation? I'm wondering if I should abandon slack-ruby-client and just write my own instead.

Thanks!

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

`team.billableInfo` is wrong

Description

Describe your issue here.

The response for team.billableInfo only includes the okay not the actual values.

What type of issue is this? (place an x in one of the [ ])

  • [ x] bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • [x ] I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • [ x] I've read and agree to the Code of Conduct.
  • [x ] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

New Socket mode not described here

Description

The docs for new slack apps say to use the new Socket Mode and that the RTM client mode is deprecated:
https://api.slack.com/rtm

New mode is described here: https://api.slack.com/apis/connections/socket

Yet there don't seem to be any schemas for apps.connections.open as the first step in connecting with the new mode: https://api.slack.com/methods/apps.connections.open

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

No schema seems to be defined for https://api.slack.com/methods/apps.connections.open

Steps to reproduce:

  1. self-explanatory

Expected result:

Documented schema available - if new apps are automatically pushed over to Socket Mode instead.

Actual result:

https://media.tenor.com/images/0308bf8934e765802f95cb6dacccd040/tenor.gif

Attachments:

https://i.pinimg.com/originals/07/6d/51/076d514bbf5a5387f24a5896c26805af.gif

external_multi_select view issue when pressing enter key

Description

Hi Slack team,

Pressing enter key in multi_select view causes view to crash. See details in below bug section.

What type of issue is this? (place an x in one of the [ ])

  • [ x] bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • [ x] I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • [ x] I've read and agree to the Code of Conduct.
  • [ x] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

I am using views API to create a Modal that contains a multi_external_select element. When I type and try to select an item from options list via keyboard pressing enter key turns modal into "We can't fully display this message" dialog.

Reproducible in:

Development environment:
Mac OS Mojave Slack app
Web slack app on Google Chrome

Steps to reproduce:

  1. Open a modal view with multi_external_select element
  2. Start typing with computer keyboard to bring option suggestions
  3. Navigate with arrow down button and press enter button to select

Expected result:

The option I press enter on should be added to selected options

Actual result:

Dialog turns into "We can't fully display this message" dialog and the content is lost

Attachments:

Screen Shot 2019-11-03 at 10 36 26 PM

Screen Shot 2019-11-03 at 10 36 19 PM

openapi-generator cannot process Web API spec

Description

openapi-generator seems to be unable to process Web API spec. Same goes for swagger-codegen

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:
Mac OS X 10.14.3 with Homebrew
openapi-generator 3.3.4

Steps to reproduce:

  1. brew install openapi-generator
  2. openapi-generator generate -i ../slack-api-spec/web-api/slack_web_openapi_v2.json -g go

Expected result:

Client code generated.

Actual result:

% openapi-generator generate -i ../slack-api-spec/web-api/slack_web_openapi_v2.json -g go --skip-validate-spec
[main] WARN  io.swagger.util.PropertyDeserializer - no property from null, null, {ENUM=null, TITLE=null, DESCRIPTION=null, DEFAULT=null, PATTERN=null, DESCRIMINATOR=null, MIN_ITEMS=null, MAX_ITEMS=null, MIN_PROPERTIES=null, MAX_PROPERTIES=null, MIN_LENGTH=null, MAX_LENGTH=null, MINIMUM=null, MAXIMUM=null, EXCLUSIVE_MINIMUM=null, EXCLUSIVE_MAXIMUM=null, UNIQUE_ITEMS=null, EXAMPLE=null, TYPE=null, FORMAT=null, READ_ONLY=null, VENDOR_EXTENSIONS={}, MULTIPLE_OF=null}
[main] WARN  io.swagger.util.PropertyDeserializer - no property from null, null, {ENUM=null, TITLE=null, DESCRIPTION=null, DEFAULT=null, PATTERN=null, DESCRIMINATOR=null, MIN_ITEMS=null, MAX_ITEMS=null, MIN_PROPERTIES=null, MAX_PROPERTIES=null, MIN_LENGTH=null, MAX_LENGTH=null, MINIMUM=null, MAXIMUM=null, EXCLUSIVE_MINIMUM=null, EXCLUSIVE_MAXIMUM=null, UNIQUE_ITEMS=null, EXAMPLE=null, TYPE=null, FORMAT=null, READ_ONLY=null, VENDOR_EXTENSIONS={}, MULTIPLE_OF=null}
[main] WARN  io.swagger.util.PropertyDeserializer - no property from null, null, {ENUM=null, TITLE=null, DESCRIPTION=null, DEFAULT=null, PATTERN=null, DESCRIMINATOR=null, MIN_ITEMS=null, MAX_ITEMS=null, MIN_PROPERTIES=null, MAX_PROPERTIES=null, MIN_LENGTH=null, MAX_LENGTH=null, MINIMUM=null, MAXIMUM=null, EXCLUSIVE_MINIMUM=null, EXCLUSIVE_MAXIMUM=null, UNIQUE_ITEMS=null, EXAMPLE=null, TYPE=null, FORMAT=null, READ_ONLY=null, VENDOR_EXTENSIONS={}, MULTIPLE_OF=null}
[main] WARN  io.swagger.util.PropertyDeserializer - no property from null, null, {ENUM=null, TITLE=null, DESCRIPTION=null, DEFAULT=null, PATTERN=null, DESCRIMINATOR=null, MIN_ITEMS=null, MAX_ITEMS=null, MIN_PROPERTIES=null, MAX_PROPERTIES=null, MIN_LENGTH=null, MAX_LENGTH=null, MINIMUM=null, MAXIMUM=null, EXCLUSIVE_MINIMUM=null, EXCLUSIVE_MAXIMUM=null, UNIQUE_ITEMS=null, EXAMPLE=null, TYPE=null, FORMAT=null, READ_ONLY=null, VENDOR_EXTENSIONS={}, MULTIPLE_OF=null}
[main] WARN  o.o.c.config.CodegenConfigurator - There were issues with the specification, but validation has been explicitly disabled.
Errors: 
	-attribute definitions.objs_file_object_with_id_only.title is unexpected
	-attribute definitions.objs_file_object_with_id_only.additionalProperties is unexpected
	-attribute definitions.objs_file_object_with_id_only.type is unexpected
Warnings: 
	-Unused model: defs_comment_id
	-Unused model: defs_ok_false
	-Unused model: objs_team
	-Unused model: defs_ts
	-Unused model: defs_invite_id
	-Unused model: defs_room_id
	-Unused model: objs_inviting_user
	-Unused model: defs_team
	-Unused model: defs_group_id
	-Unused model: defs_ok_true
	-Unused model: objs_file_object_with_id_only
	-Unused model: defs_dm_id
	-Unused model: defs_bot_id
	-Unused model: objs_reaction
	-Unused model: objs_comment
	-Unused model: defs_topic_purpose_creator
	-Unused model: objs_channel
	-Unused model: defs_pinned_info
	-Unused model: defs_app_id
	-Unused model: objs_group
	-Unused model: objs_file
	-Unused model: objs_im
	-Unused model: objs_paging
	-Unused model: objs_team_profile_field
	-Unused model: objs_conversation
	-Unused model: objs_user
	-Unused model: objs_dnd
	-Unused model: prefs_prefs
	-Unused model: objs_scopes
	-Unused model: defs_file_id
	-Unused model: objs_comments
	-Unused model: defs_channel
	-Unused model: defs_user_id
	-Unused model: objs_message
	-Unused model: objs_user_profile
	-Unused model: team_prefs_prefs
	-Unused model: objs_user_profile_short
	-Unused model: defs_channel_name
	-Unused model: defs_channel_id
	-Unused model: objs_user_profile_shortest

[main] INFO  o.o.c.ignore.CodegenIgnoreProcessor - No .openapi-generator-ignore file found.
[main] INFO  o.o.c.languages.AbstractGoCodegen - Environment variable GO_POST_PROCESS_FILE not defined so Go code may not be properly formatted. To define it, try `export GO_POST_PROCESS_FILE="/usr/local/bin/gofmt -w"` (Linux/Mac)
[main] INFO  o.o.c.languages.AbstractGoCodegen - NOTE: To enable file post-processing, 'enablePostProcessFile' must be set to `true` (--enable-post-process-file for CLI).
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] WARN  o.o.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
[main] INFO  o.o.codegen.DefaultGenerator - Model objs_comments not generated since it's an alias to array (without property)
[main] INFO  o.o.codegen.DefaultGenerator - Model defs_pinned_info not generated since it's an alias to map (without property)
Exception in thread "main" java.lang.RuntimeException: Could not process model 'team_prefs_prefs'.Please make sure that your schema is correct!
	at org.openapitools.codegen.DefaultGenerator.generateModels(DefaultGenerator.java:457)
	at org.openapitools.codegen.DefaultGenerator.generate(DefaultGenerator.java:888)
	at org.openapitools.codegen.cmd.Generate.run(Generate.java:355)
	at org.openapitools.codegen.OpenAPIGenerator.main(OpenAPIGenerator.java:62)
Caused by: java.lang.NullPointerException
	at org.openapitools.codegen.utils.ModelUtils.isArraySchema(ModelUtils.java:343)
	at org.openapitools.codegen.languages.AbstractGoCodegen.getTypeDeclaration(AbstractGoCodegen.java:263)
	at org.openapitools.codegen.languages.AbstractGoCodegen.getTypeDeclaration(AbstractGoCodegen.java:266)
	at org.openapitools.codegen.DefaultCodegen.fromProperty(DefaultCodegen.java:2006)
	at org.openapitools.codegen.DefaultCodegen.addVars(DefaultCodegen.java:3455)
	at org.openapitools.codegen.DefaultCodegen.addVars(DefaultCodegen.java:3425)
	at org.openapitools.codegen.DefaultCodegen.addVars(DefaultCodegen.java:3412)
	at org.openapitools.codegen.DefaultCodegen.fromModel(DefaultCodegen.java:1708)
	at org.openapitools.codegen.DefaultGenerator.processModels(DefaultGenerator.java:1126)
	at org.openapitools.codegen.DefaultGenerator.generateModels(DefaultGenerator.java:452)
	... 3 more

Incomplete "consumes" definition for chat.postMessage

Description

The consumes definition for chat.postMessage may be application/json, but there is no JSON spec to choose from; the parameters are all formData parameter. JSON needs a request body parameter in OAS 2.0 (in OAS 3.0, any input parameter can be JSON).

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

all

Steps to reproduce:

Expected result:

JSON input defined in the schema

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

API for slackbot responses

Description

There should be a rest endpoint for slackbot responses. I'd like to get list of slackbot responses, both triggers and values. I'd like to create new responses or manage currently defined ones.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Wrong type on user profile fields when fields are empty

Description

I've found a bug in the api specs. When you retrieve an user profile using slack api and the user fields are empty, fields are an empty array. And when they are not, it's an object.

What type of issue is this?

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

According to the openapi specs user profile fields must be an object.

When fields are not empty, slack api returns an object like:
"fields": { "somekey": { "value": "somevalue", "alt": "", "label": "somelabel" } }

But when fields are empty, slack api returns an empty array:
"fields": []

This is really annoying when you are using a strongly typed language.

Reproducible in:

Everywhere

Expected result:

"fields": {}

Actual result:

"fields": []

Update Postman import advice

Description

I think the readme section on Postman may need to be updated. I am running Postman Canary (v8 -- the closest I can find to an exact version is this millisecond timestamp: 1612567779979) and was able to import the collection from https://api.slack.com/specs/openapi/v2/slack_web.json without modification. I experienced no difficulty and the {{baseUrl}} variable worked as expected without my needing to set the value.

I don't know if this is an improvement in Postman 8 or when this started working as this was my first attempt, but figured you might want to know that this is now (or will soon be for non-Canary users) simple to import.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

See the Description for details. Do with this what you will. Hope it helps.

'Types' argument in conversations.list ignores private_channel if public_channel also specified

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment: Node (Bolt, WebAPI)
Also reproduced with HTTP requests

Steps to reproduce:

  1. Give access to public and private channels to an app
  2. Get conversations.list with type public_channel: returns public channels
  3. Get conversations.list with type private_channel: returns private channels the bot has access to
  4. Get conversations.list with type public_channel,private_channel (or private_channel,public_channel)

Expected result:

A list of both public channels and private channels the app was invited in (results from 2. and 3. joined)

Actual result:

The same result as 2., only public channels are listed.

"token" header parameter not actually required

Description

“token” is designated as a required header parameter for many methods in the OpenAPI spec for the Web API (e.g. "operationId": "chat_postMessage"), but this input behaves as optional and is not actually needed when a request is made with a valid token for Authorization: Bearer. Please update the spec to ensure any occurrence of the header parameter of name "token" is properly designated as true or false...and included in the spec conjunction with the Authorization header behavior.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Both of the following calls work, proving that the token parameter is not required:
/* No token parameter */
curl --location --request POST 'https://slack.com/api/chat.postMessage'
--header 'Content-Type: application/x-www-form-urlencoded'
--header 'Authorization: Bearer xoxb-'
--data-urlencode 'channel='
--data-urlencode 'as_user=1'
--data-urlencode 'text=hello'

/* Invalid token parameter */
curl --location --request POST 'https://slack.com/api/chat.postMessage'
--header 'token: garbage'
--header 'Content-Type: application/x-www-form-urlencoded'
--header 'Authorization: Bearer xoxb-'
--data-urlencode 'channel='
--data-urlencode 'as_user=1'
--data-urlencode 'text=hello'

Expected result:

If the token header parameter is actually required, I'd expect both of the above requests to fail.

Actual result:

Both requests succeed

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

Response of chat.update is underspecified

Description

The response type of the chat.update endpoint is underspecified:

"properties": {
"channel": {
"type": "string"
},
"message": {
"properties": {
"attachments": {
"items": {
"type": "object"
},
"type": "array"
},
"blocks": {
"type": "object"
},
"text": {
"type": "string"
}
},
"required": [
"text"
],
"title": "Message object",
"type": "object"
},
"ok": {
"$ref": "#/definitions/defs_ok_true"
},
"text": {
"type": "string"
},
"ts": {
"type": "string"
}
},

Specifically, the types of message.attachments and message.blocks are set to a generic object type. I think these could be specified more narrowly, ideally using one of the already existing definitions such as #/definitions/objs_message or #/definitions/blocks.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

'objs_conversation' contains more than one object

Description

I am working with Slack Swagger for my project. I am using NSwag to create a client out of the swagger file.

The generated client file does not contain the properties for 'objs_conversation' definition. This is because, in swagger file, it does not contain 'properties' and 'data type' properties directly. Instead it contains only 'items' (which then contains 3 definitions).

Swagger definition for the same - https://justpaste.it/388lf

Questions

  1. Is this the latest swagger json file? and is it officially supported by slack? (I know it is, just getting the confirmation :) )
  2. How to identify which definition to choose for 'objs_conversation'?

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

I am using NSwag to create a client out of the swagger file.

The generated client file does not contain the properties for 'objs_conversation' definition. This is because, in swagger file, it does not contain 'properties' and 'data type' properties directly. Instead it contains only 'items' (which then contains 3 definitions).

Swagger definition for the same - https://justpaste.it/388lf

Reproducible in:

All environments

Steps to reproduce:

Generate the c# client using NSwag from the swagger file.

Expected result:

'objs_conversation' to contains properties. (3 different objects under 'objs_converstion' is confusing and how would we be able to differentiate? it could be with three different names)

Actual result:

It is empty

Attachments:

image

Missing response schema for search.messages endpoint

Description

The https://api.slack.com/methods/search.messages endpoint response is not specified:

"/search.messages": {
"get": {
"consumes": [
"application/x-www-form-urlencoded"
],
"description": "Searches for messages matching a query.",
"externalDocs": {
"description": "API method documentation",
"url": "https://api.slack.com/methods/search.messages"
},
"operationId": "search_messages",
"parameters": [
{
"description": "Authentication token. Requires scope: `search:read`",
"in": "query",
"name": "token",
"required": true,
"type": "string"
},
{
"description": "Pass the number of results you want per \"page\". Maximum of `100`.",
"in": "query",
"name": "count",
"type": "integer"
},
{
"description": "Pass a value of `true` to enable query highlight markers (see below).",
"in": "query",
"name": "highlight",
"type": "boolean"
},
{
"in": "query",
"name": "page",
"type": "integer"
},
{
"description": "Search query.",
"in": "query",
"name": "query",
"required": true,
"type": "string"
},
{
"description": "Return matches sorted by either `score` or `timestamp`.",
"in": "query",
"name": "sort",
"type": "string"
},
{
"description": "Change sort direction to ascending (`asc`) or descending (`desc`).",
"in": "query",
"name": "sort_dir",
"type": "string"
}
],
"produces": [
"application/json"
],
"responses": {
"200": {
"description": "Typical success response",
"schema": {
"additionalProperties": true,
"description": "This method either only returns a brief _OK_ response or a verbose schema is not available for this method.",
"properties": {
"ok": {
"$ref": "#/definitions/defs_ok_true"
}
},
"required": [
"ok"
],
"title": "Default success template",
"type": "object"
}
},
"default": {
"description": "Typical error response",
"schema": {
"additionalProperties": true,
"description": "This method either only returns a brief _not OK_ response or a verbose schema is not available for this method.",
"properties": {
"ok": {
"$ref": "#/definitions/defs_ok_false"
}
},
"required": [
"ok"
],
"title": "Default error template",
"type": "object"
}
}
},
"security": [
{
"slackAuth": [
"search:read"
]
}
],
"tags": [
"search"
]
}
},

We only have the "ok" field, not all the data fields of the results.
This is an issue when trying to generate compatible client (jolicode/slack-php-api#59).

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Mark Repo as Unmaintained

Description

Following this comment - don’t waste people’s time or efforts. It the project is unmaintained and the product is proprietary. Clearly the “incredible machine” is broken as well.

#55 (comment)

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Event payload of the `message` event does not have a consistent schema (missing `team` property when message subtype is `file_share`)

Description

event payload of the message event is missing the team property when the message contains files (i.e. subtype is file_share).

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Reproducible in:

Development environment: Mac OS 11.2, Node.js 14.15.4, Bolt.js 3.4.0

Steps to reproduce:

  1. perform the required configurations of a Slack app to listen to the message event
  2. post a message with text only (no files attached)
  3. observe the event payload
  4. post a message with a file attached
  5. observe the event payload

Expected result:

The event payload in steps 3 and 5 both include the team property

Actual result:

The event payload in step 3 includes the team property and the one in step 5 doesn't

Allowed values of parse field unclear

Description

The set of allowed values for the parse field used by chat.postMessage and chat.update are underspecified and slightly contradictory:

{
"description": "Change how messages are treated. Defaults to `client`, unlike `chat.postMessage`. Accepts either `none` or `full`. If you do not specify a value for this field, the original value set for the message will be overwritten with the default, `client`.",
"in": "formData",
"name": "parse",
"type": "string"
},

On the one hand, the documentation string claims that parse

Accepts either none or full.

On the other hand, it also claims that the field

Defaults to client

which makes me think that the field accepts client, full, and none (or are even more values allowed?).

Also, I didn’t find any good documentation on the full list of allowed values for this field, let alone their semantics.

The only mention of the parse field I could find in the documentation simply states that

You can specify values for parse and link_names to change formatting behavior.
https://api.slack.com/methods/chat.postMessage#formatting

with no further explanation.

I think that both the specification and the documentation should be improved.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Fields property in `objs_user_profile` has incorrect type

Description

Type of one of the objs_user_profile properties is incorrect.
property fields has a type which is an array ("type": ["object", "null", "array"]) which is incorrect according to OpenAPI 2.0 docs, where type can be only a string

It is similar to #8

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Error enums are inconsistent with documentation

Description

Path /files.info, method get has timezone_count_failed as one of the errors in the spec enum but it's not documented at https://api.slack.com/methods/files.info

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

/groups.close is no longer available?

Description

I just want to know the latest status of /groups.close. In this spec document, the endpoint seems to be no longer listed.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

On WebAPI missing examples, default and required fields on formData

Missing examples, default values and required fields in all the requests containing data with type in: formData, for example: chat_postMessage
"operationId": "chat_postMessage", "parameters": [ { "description": "A JSON-based array of structured attachments, presented as a URL-encoded string.", "in": "formData", "name": "attachments", "type": "string" },

Get all the messages with replies

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Currently conversation.replies method gives the list of all the replies for a given ts. But there is no way to identify or get the list of messages which have been responded.

The only way to do this at the moment is to get all the parent messages from the conversations.history method and then loop through those messages and call conversation.replies api to check if they have a reply or not. Now following this will mean that we will have to make an api call for every message, which will result in a lot of api calls.

Use case:

We need to get all the messages that someone has responded back in the last X hours.

Possible solution:

  • In the conversations.history method if we can add a boolean that says has_reply that can help in identifying all the messages with replies, then that can help a lot in reducing the number of api calls.

  • Have a way to get all the parent messages along with their replies for a duration the downside of this will be a too heavy response body in case a message has a lot of replies, but that can be controlled by pagination i suppose.

is this still being maintained?

Description

Is this repo still being maintained? It doesn't seem to include all published endpoints. For example, it's missing chat.scheduleMessage

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Missing default values

Description

I noticed that the API spec is missing default values that are present in the HTML reference.

For example: https://api.slack.com/methods/users.list has a parameter limit with a Default: 0.

However, the OpenAPI spec is missing this default:

                    {
                        "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",
                        "type": "integer"
                    },

What type of issue is this? (place an x in one of the [ ])

  • enhancement (feature request)

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Specify token type(s) for API methods in the spec

Description

In addition to the scopes, indicate which of User or Bot token is required for a given operation in the OAS, a detail that is currently only available in the dev docs (e.g. https://api.slack.com/methods/reminders.add).

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Development environment:

Steps to reproduce:

Expected result:

What you expected to happen

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.
If attaching logs, please remove user data and tokens.

Cannot get an oauth token using the API Spec because of invalid scopes

Description

Cannot get an oauth token using the API Spec because of invalid scopes. ### Is this spec still valid and being maintained? Some of the scopes mentioned in the Web API Spec aren't even listed as possible scopes for the app I am building.

What type of issue is this? (place an x in one of the [ ])

  • [X ] bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • [X ] I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • [ X] I've read and agree to the Code of Conduct.
  • [X ] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

When I try to get an oauth token, using this spec file, I get the following error -

Invalid permissions requested
Invalid scopes: none, rtm:stream, tokens.basic

SCREENSHOT BELOW
image

A couple typos in error enums

Description

There are two errors in the spec that look like typos:

  1. Within team.info it lists token_revokedno_permission as an error, which looks like two adjacent errors jammed together.
  2. Within reactions.list it has account_inactiv instead of account_inactive.

I can submit a PR if you'd like.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

See description above.

85 validation errors reported in Swagger Editor

Description

I copy/pasted the contents of https://api.slack.com/specs/openapi/v2/slack_web.json into Swagger Editor (auto-conversion of JSON to YAML) and have found that there are 85 validation errors throw:

https://app.swaggerhub.com/apis/krissirk/slack-web/1.0#/

Similar to the impact reported in this GitHub issue, the presence of these issues in the spec inhibits our customers' ability to consume the JSON as-is and successfully make callouts + work with the API response in the Salesforce External Services feature.

As an example, the "chat_postMessage" operation 200 response references "objs_message" object, which contains a seemingly malformed property definition "bot_id":
image

This property definition doesn't specify "type" and it's using an array for "items". As a result, our callout runtime from Salesforce Flow fails to process the response as it does not match the spec.

There are four other "bot_id" references defined in the spec as

"bot_id": { "$ref": "#/definitions/defs_bot_id" }

If the above definition is used instead of

"bot_id": { "items": [ { "$ref": "#/definitions/defs_bot_id" }, { "title": "Nil bot_id set when display_as_bot is false", "type": "null" } ] }
within "objs_message", or (just like the Swagger validator indicates) it could be made an “object” with the "title" and "reference" under it, our callout runtime will succeed.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

Swagger Tools; Salesforce Platform

Steps to reproduce:

  1. Copy https://api.slack.com/specs/openapi/v2/slack_web.json
  2. Paste into Swagger Editor
  3. Accept conversion from JSON to YAML
  4. Observe 85 errors reported in the Swagger UI

Expected result:

No validation errors when the spec is viewed in Swagger Editor. Codegen with the spec as input succeeds. Salesforce automation via External Services + Flow succeeds.

Actual result:

85 validation errors reported by Swagger Editor.

Error throw by API response in debug during demo - skip to ~15:00 of https://www.salesforce.com/video/19792276.

Attachments:

demo problem

Feature Request: Add CRUD operations for Emoji in the api

Description

I am unable to manage emoji directly through the api. It would be nice to offer a way to create, edit, update, delete emoji directly through the api. This would offer the opportunity build some awesome integrations that could make emoji for you automatically. Haven't you wanted an emoji that didn't exist and wanted to be able to make it with something like /giphy?

Imagine this workflow:

Jeb> I need a rock emoji but we don't have one
Bill> Look at this tool I made to make them for you
Bill> /emojify rock
Emojify> Here's some rock pictures... which one do you want to make into the rock emoji?
Bill> That one ---->>> ()
Emojify> Here is your new emoji 🪨 Enjoy!
Bill> Thanks Emojify
Jeb> You're awesome Emojify

Please make a rich emoji api so I or someone else can build this integration :)

What type of issue is this? (place an x in one of the [ ])

  • bug
  • [X ] enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • [X ] I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

`duplicate_external_id` unavoidable if modal not explicitly closed

Description

Receiving duplicate_external_id error from views.open endpoint when the modal was previously open and then closed by any means other than explicitly clicking the close or submit buttons.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Reproducible in:

production

Steps to reproduce:

  1. Use views.open to open a modal with external_id: 'foo'.
  2. Press CMD+R in Slack app to reload.
  3. -the modal will now be gone-
  4. Try to open the same modal with same external_id: 'foo' again.

Expected result:

The modal should open again.

Actual result:

The modal does not open, and I get the duplicate_external_id error code.

Attachments:

https://youtu.be/ITAyKDSFg0w

When bot is in group chat, I don't receive messages using the bolt-js library

Description

Describe your issue here.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

I'm registering a callback with the following code:

app.message(/ping/, (e) => { console.log(e) })

It is not printing anything if I'm on group chat. I see the message on the debug console, but it fails with error: Conversation not found.

[DEBUG]  bolt-app {"token":"k7PRs87qbRwzm4A4LAtOCSGb","team_id":"T0JV0MYCE","api_app_id":"A01Q2UP4HQQ","event":{"client_msg_id":"0b3149e4-1243-4a27-be4c-2aecb715cab9","type":"app_mention","text":"<@U01PDC4EB8B> ping","user":"UR62DEJCX","ts":"1614363797.012900","team":"T0JV0MYCE","blocks":[{"type":"rich_text","block_id":"fxp","elements":[{"type":"rich_text_section","elements":[{"type":"user","user_id":"U01PDC4EB8B"},{"type":"text","text":" ping"}]}]}],"channel":"G01PJFVB4GK","event_ts":"1614363797.012900"},"type":"event_callback","event_id":"Ev01PQKP3RNY","event_time":1614363797,"authorizations":[{"enterprise_id":null,"team_id":"T0JV0MYCE","user_id":"U01PDC4EB8B","is_bot":true,"is_enterprise_install":false}],"is_ext_shared_channel":false,"event_context":"1-app_mention-T0JV0MYCE-G01PJFVB4GK"}
[DEBUG]  socket-mode:SocketModeClient:0 calling ack events_api
[DEBUG]  socket-mode:SocketModeClient:0 send() in state: connected,ready
[DEBUG]  socket-mode:SocketModeClient:0 sending message on websocket: {"envelope_id":"889495a0-c7ce-4ad4-a7cd-5329ba5c7295","payload":{}}
[DEBUG]  bolt-app Conversation context failed loading for ID: G01PJFVB4GK, error: Conversation not found

Reproducible in:

Bolt-js version 3.2.0, node.js v12.13.0, Ubuntu 18.04

Steps to reproduce:

  1. Listen to anything using the .message call
  2. Add the bot in a group chat with at least two people
  3. Mention the bot with the message that it should listen

Expected result:

The callback to be called

Actual result:

Nothing happened.

Attachments:

There are lots of information on how I'm trying to debug this on slackapi/bolt-js#817. I tried to pinpoint the error by listening directly to slack_event, exactly the same as the bolt-js listens to callbacks to check what's wrong. What I did found is that body.event.type of that callback is something_mention, and that what the API is expecting is message. I don't know if the API is supposed to send message as the event type - what I do know is that when I mention the bot with @bot ping (bot being the bot's name) on public channels, private channels, and direct messages, I receive a message event. When I mention on group chat (a chat with my user, another user, and the bot) I don't receive a message and instead receive a mention.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.