Swagger Inspector - Host name

26 views
Skip to first unread message

ny_shelly

unread,
Apr 13, 2018, 1:57:03 PM4/13/18
to Swagger
Hi - Our group is new at using RESTful APIs. We added swashbuckle to our Visual Studio and created a sample API with the json output. We then used Inspector to consume it and we can see all of the API calls listed.

The problem is the host. We did not hard-code a host within the json. This didn't seem to make sense because this can change.

Inspector seems to prompt for a host but when we enter it, Inspector does not add it to the address of the api call. It just seems to get confused.

How do you use Inspector without hard-coding the host?

Thanks,
Shelly

Shannon Wallace

unread,
Apr 16, 2018, 8:11:40 AM4/16/18
to Swagger
Thanks for giving us a heads up about this! We have not thought about API definitions that don't have a host set - our impression is that most companies do eventually hard code a host in their API definition file. Otherwise, how would API consumers (even internal ones) know what base URL to hit?

For the moment, we don't support this case of no set host well - my apologies. We'll think about this in the future, though!

Best Regards,
Shannon Wallace
Product Manager, Swagger
Reply all
Reply to author
Forward
0 new messages