-
Notifications
You must be signed in to change notification settings - Fork 94
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
Problem in swagger output using empty Uri template #7
Comments
Can you check if this would solve your problem? putting |
That should work. Maybe i can cut u[p the words to mkae it happen :) like trans to delegate to TRanslations.Svc and then havel "lations" in the method path. |
nope does not work. i do need a slash in between trans and lations now. get /gw/trans/lations |
One other issue is that although i have a nullable field and put required=false in the Swagger parameter attribute it still shows the parameter to be required. |
Would it work if you changed like this? on
to
and on Service:
to
and also the methods
to
|
I'll check what implication it might have to remove the method name when UriTemplate is empty It makes sense to not have the method name |
I'll also check that issue with thanks |
about the If I use
I get books required If I use
books are not required |
Hi abelsilva, Here it goes. This is in the interface: [SwaggerWcfPath("By culture and page", "Retrieves a translation by culture and page")] This is implementation (svc.cs) : [SwaggerWcf("/gw/translations")]
this is the base path: /gw/translations/cult/{culture}/page/{page} And then in swagger output page I see all 3 fields |
oh yeah, If i say string and use =null then it will make it an optional parameter? |
if i change it to:
I still see required in the fields of swagger. |
ok, I was checking this issue with body parameters now I see the issue you have, it makes sense, it's a bug, I'll check it thanks |
If I have
|
make sure you are using V 0.1.4 |
if I change the function to
I also see the reftime as not required |
Hi Abelsilva, Thank you so much for improving the swagger functionality. It is great that now it is working with the empty Uri templates. This makes the interface so much better. But alas, the fields are still all required in my solution. I do not understand because I have the exact same parameters And my swagger still says they are required. |
are you able to paste the full interface and class? you may omit the contents of the functions |
Dear abelsilva, Thank you so much for your help and quick response and fix. I got swagger working now the way i hoped it would. Thank you so much. |
The required stuff is working alos :) |
thanks! nice to ear it is working |
When I have a method like this:
I see that it is shown in Swagger like this:
/gw/translations/Get
I did expect: /gw/translations to be the path. This is also the path i give to call this functionality.
likewise with Post:
How can I use swagger wcf to get or post on the main svc without sub path
The text was updated successfully, but these errors were encountered: