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

Incorrect schema for calls.add and calls.info #69

@AndreaMGuzman

Description

@AndreaMGuzman

Description

Calls.add
The 200 response schema for calls.add can be improved by moving the response value id from additionalProperty to a named properties. Since this id value will be used in other operations such as calls.info, calls.end and more, it is actually a “required” response property, not “additional”. The OpenApi swagger parser library has limitations in additionalProperties when both additionalProperties and properties are defined, resulting in additionalProperties values being ignored, so the services that use this parser will lose the call id information from the response.

Possible solution
Change the 200 response for calls.add to:

"schema": {
  "properties": {
     "ok": { "$ref": "#/definitions/defs_ok_true" },
     "call": {
       "type": "object",
       "properties": {
         "id": {"type": "string"}
       }
     }
  }
}

Calls.info
The consumes for calls.info is defined to be application/json and application/x-www-form-urlencoded. However, when sending the request with application/json Content-Type header, Slack ignores the input parameter id. The server only accepts request with no Content-Type, or Content-Type: application/x-www-form-urlencoded.

Possible solution
remove application/json from the consumes definition

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 [ ])

  • [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:

all
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.

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