cancel
Showing results for 
Search instead for 
Did you mean: 
Welcome to the September Hub-bub

We are inviting you to join our exciting online event where you can learn a lot of useful information, share your knowledge and have fun. Each week, we will reward the best posters with free gift cards .

Just pick any topic you like in the SwaggerHub Community, or create your own to dive into the wonderful September Hub-bub.

Event duration: September 2-27. More information.

This Week Top Contributors:

We will decide the winners next Monday

SwaggerHub - Interactive API Docs 'Try it out!' does not return results

SOLVED
Occasional Contributor

SwaggerHub - Interactive API Docs 'Try it out!' does not return results

I have an API that validates and produces results using the Try this Operation / 'Send Request' button in the application http://editor.swagger.io/#/.

 

However, the same API definition does not produce results through SwaggerHub / Interactive API Docs tab / 'Try it out!' and SwaggerHub / Editor tab / Send Request. The screen does not report any errors it just shows the animated elipsis forever.

 

Should I expect those features to work? If it were a cross origin issue I would expect the editor.swagger.io application to fail also. My cors header exceptions are not specific to edtior.swagger.io but are wide open.

 

Thanks for any help you can provide. Lovely tool!

1 ACCEPTED SOLUTION

Accepted Solutions
Moderator

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

Apologies for the confusion, I had an issue with testing it on my end.

 

So it seems the problem is that the requests being generated is http and that doesn't work well because SwaggerHub is hosted on https. I can see that you've defined both http and https and the API calls do work with https.

 

I'd suggest trying to change the order of schemes and put https first to see if that works. If not, for now, you can remove the http from the spec itself. Fixing that issue would require a more elaborate solution from our end but we'll get it done.

7 REPLIES 7
Moderator

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

Hi there!

 

Thank you for the kind words.

The behavior of the try it out should be similar in both cases. Can you point us to your API definition and specific operation so we can futher investigate the case?

Occasional Contributor

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

https://swaggerhub.com/api/evosus/webapi/1.1.0

 

I suggest using:

GET /method/ServiceCheck

 

You can supply the required values shown in the intro of the API spec.

 

These are the request/results from http://editor.swagger.io/#/

https://www.dropbox.com/s/wg7ndsxtsq734wj/GETServiceCheck.JPG?dl=0

 

Moderator

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

Thanks for the details. There's indeed an issue that needs to be checked and fixed so thanks for pointing that out.

We'll keep you updated to when we deploy a fix.

Occasional Contributor

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

I am thrilled with your responsiveness. Much respect!

Moderator

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

Which browser have you tested it with? Have you or can you try it with another browser and provide the details?

Moderator

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

Apologies for the confusion, I had an issue with testing it on my end.

 

So it seems the problem is that the requests being generated is http and that doesn't work well because SwaggerHub is hosted on https. I can see that you've defined both http and https and the API calls do work with https.

 

I'd suggest trying to change the order of schemes and put https first to see if that works. If not, for now, you can remove the http from the spec itself. Fixing that issue would require a more elaborate solution from our end but we'll get it done.

Occasional Contributor

Re: SwaggerHub - Interactive API Docs 'Try it out!' does not return results

I tried Chrome 47 originally. Since then I have tried IE 9.0.8 and Firefox 41.0.1. I get the same results.

 

The key does seem to be the protocol. So I removed the HTTP protocol and left HTTPS. 'Try it out' from Interactive API Docs worked. Then I added HTTP protocol in the second order position. This worked also because the UI selects the first protocol by default. So it is the same request.

 

I'm happy to have a work-around. Thank you.

New Here?
Join us and watch the welcome video:
SeptemberNews
Join the September Hub-bub to show off, learn and win