Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Encoding Object #43

Open
puug opened this issue Aug 24, 2021 · 2 comments
Open

Support Encoding Object #43

puug opened this issue Aug 24, 2021 · 2 comments
Labels
type: community enhancement feature request not on Twilio's roadmap

Comments

@puug
Copy link

puug commented Aug 24, 2021

Issue Summary

As part of the 3.0.1 OpenAPI spec there's the ability to give further information about the behaviour of individual properties
https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.1.md#encoding-object

This is useful for crafting requests and mocking services to more accurately replicate the live services and SDKs.

I've been looking into the notify arena so my examples are from there

Steps to Reproduce

  1. Import the notify spec into https://editor.swagger.io/
  2. Craft a notification request POST /v1​/Services​/{ServiceSid}​/Notifications with multiple Identities
  3. Resulting payload looks like Identity=string1,string2
  4. Edit the spec to have
            encoding:
              Identity:
                style: form
  1. The payload now looks like Identity=string1&Identity=string2 (this matches how Twilio Java SDK crafts the request)

This is one simple example, but there's many other properties that could benefit from this treatment, (ie objects encoded in application/json) which would help with other services like prism when they also support encoding - see stoplightio/prism#1622

@twilio-dx
Copy link
Collaborator

Ahoy! Thank you for opening your first issue here! If this request is regarding troubleshooting your application, please reach out to the support team via https://support.twilio.com.

@shwetha-manvinkurke
Copy link
Contributor

@puug Thanks for the suggestion. This issue has been added to our internal backlog to be prioritized. Pull requests and +1s on the issue summary will help it move up the backlog.

@shwetha-manvinkurke shwetha-manvinkurke added status: help wanted requesting help from the community type: community enhancement feature request not on Twilio's roadmap and removed status: help wanted requesting help from the community labels Aug 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: community enhancement feature request not on Twilio's roadmap
Projects
None yet
Development

No branches or pull requests

3 participants