-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Different parameters for different actions in the same resource #418
Labels
Comments
See below, you can define the URI Template with parameters specific to the action within the action. ## Courses [/courses]
### List All Courses [GET /courses{?quarter_id,professor_id}]
+ Parameters
+ `quarter_id` (optional, number) - Limit the list to courses that were taught during the specified quarter
+ `professor_id` (optional, number) - Limit the list to courses that were taught by the specified professor
+ Response 200 (application/json)
### Post Courses [POST]
+ Response 200 (application/json) |
Oh I see, tried something similar but put a comma between the GET and the URI. I think this should be made clearer in the docs. Not sure how much you guys control it, but in the Polls API they don't do this, they just let it render incorrectly. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have the same issue as #40. It's a very old one but there is no clear solution to it. Some docs were referred to at the end that are now gone, and I am experiencing the exact same thing.
This is some sample code:
Despite that the POST does not have any parameters, the URL still gets rendered like this:
If I remove the parameters from the URL in the doc, naturally they don't show up for any action. How are you supposed to do it? There is no clear way documented in the docs for API Blueprint/Apiary.
I would have expected to leave the parameters out and then have Apiary just automatically insert them for each action.
The text was updated successfully, but these errors were encountered: