Skip to content
This repository was archived by the owner on Mar 27, 2024. It is now read-only.

Required parameters are not marked as required #70

@aviks

Description

@aviks

Description

The token, channel and ts parameters are shown as required in the documentation for the chat.delete method : https://api.slack.com/methods/chat.delete#arg_token

However, in slack_web_openapi_v2.json , the parameter definitions lack the "required": true annotation.

The same issue exists in other 46 other methods, as far as I can see. These include, among others: chat.meMessage, chat.scheduleMessage, chat.scheduleMessages_list

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 environments

Steps to reproduce:

Inspect and compare the method documentation and the openapi schema for the above methods

Expected result:

All parameters documented as required should be marked as "required": true in the schema files

Actual result:

Some methods in the schema do not have the "required":true annotation.

Attachments:

"/chat.delete": {
            "post": {
                "consumes": [
                    "application/x-www-form-urlencoded",
                    "application/json"
                ],
                "description": "Deletes a message.",
                "externalDocs": {
                    "description": "API method documentation",
                    "url": "https://api.slack.com/methods/chat.delete"
                },
                "operationId": "chat_delete",
                "parameters": [
                    {
                        "description": "Authentication token. Requires scope: `chat:write`",
                        "in": "header",
                        "name": "token",
                        "type": "string"
                    },
                    {
                        "description": "Timestamp of the message to be deleted.",
                        "in": "formData",
                        "name": "ts",
                        "type": "number"
                    },
                    {
                        "description": "Channel containing the message to be deleted.",
                        "in": "formData",
                        "name": "channel",
                        "type": "string"
                    },
                    {
                        "description": "Pass true to delete the message as the authed user with `chat:write:user` scope. [Bot users](/bot-users) in this context are considered authed users. If unused or false, the message will be deleted with `chat:write:bot` scope.",
                        "in": "formData",
                        "name": "as_user",
                        "type": "boolean"
                    }
                ],
...............

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions