how we can document for the same api which is having two diffrent ussage .
Hi SwaggerHub team,
i have an api to login, i am using same api to get login using OTP .
same api i am using to get login using MPIN by changing parameters with same URL.
when i create a document i am unable to access that api in UI part and getting an warning as "definition was declared but never used in document' in editor section
screen shot is attached below
can you guide me how can i document it .
as below mentioned i am passing values with same Post method using same URL :
mobileNum : '8888888888'
mpin : '1234'
If you are using OpenAPI 3.x, you can look at using oneOf. Here is an example:
paths: /login: post: #... responses: 201: application/json: content: schema: oneOf: - '#/components/schemas/one' - '#/components/schemas/two'
If this doesn't help, could you please share the entire definitions?
SmartBear Community and Education Manager