You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.
It's inconvenient to add such responses to almost every action. If we adds/modify/remove some common responses we have to process all actions. Chance to forget or misspell something is huge. So it will be very useful to have an ability to write common responses only once and drafter should do all required magic. Here is example:
# Group Authorized resources#Common Data+Response401(application/json)+ Attributes
+ status: Unauthorized (required, fixed)
## Posts [GET /posts]+Response200(application/json)+ Attributes
+ result (array) - list of posts
## Comments [GET /comments]+Response200(application/json)+ Attributes
+ result (array) - list of comments
In this case response 401 should be added to GET /posts and GET /comments actions. If I need to modify it - I'll do it only once in one place.
If I need to add some common data to one group only I can do it like this:
# Group Authorized resources#Common Data+Response401(application/json)+ Attributes
+ status: Unauthorized (required, fixed)
## Posts [GET /posts]+Response200(application/json)+ Attributes
+ result (array) - list of posts
## Comments [GET /comments]+Response200(application/json)+ Attributes
+ result (array) - list of comments
# Group Authentication## Login [POST /login]
In this section 401 response will not be added, because it was defined in another group
The text was updated successfully, but these errors were encountered:
In our project we have very big api documentation. A lot of actions have identical responses like:
It's inconvenient to add such responses to almost every action. If we adds/modify/remove some common responses we have to process all actions. Chance to forget or misspell something is huge. So it will be very useful to have an ability to write common responses only once and drafter should do all required magic. Here is example:
In this case response 401 should be added to
GET /posts
andGET /comments
actions. If I need to modify it - I'll do it only once in one place.If I need to add some common data to one group only I can do it like this:
The text was updated successfully, but these errors were encountered: