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

Shared parameters get picked up as a method #4

Open
acossta opened this issue Sep 28, 2021 · 2 comments
Open

Shared parameters get picked up as a method #4

acossta opened this issue Sep 28, 2021 · 2 comments

Comments

@acossta
Copy link

acossta commented Sep 28, 2021

When you have shared parameters between methods ( as shown below), parameters taken as a method and not shown in the individual method pages

/Users/{userId}:
    parameters:
      - in: path
        name: userId
        required: true
        schema:
            type: String
        description: "The User's ID."
    get:
      summary: 'Returns details about a particular User'
@carlosrivera
Copy link
Contributor

That's true, it should be easily fixable by parsing the path then look for parameters set with the option in: path, let me find some time this week to fix it. :)

Btw, somehow related: while the spec is already dereferenced and can be navigated, we haven't implemented full support for the entire schema, but fixing this kind of scenarios can get us closer to a more stable/generalized version.

@acossta
Copy link
Author

acossta commented Sep 29, 2021

The shared parameters can be either in: path or in: query. It is more about their position in the spec. If parameters are placed above the methods it means that all the methods of that route take those params. The idea is for the params to be populated on each of the method md files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants