The UI will take the host from the location of the spec, so it shouldn’t be a problem.
From: <[email protected]> on behalf of Marcus Eklöf <[email protected]> Reply-To: "[email protected]" <[email protected]> Date: Friday, 7 April 2017 at 5:29 To: Swagger <[email protected]> Subject: adding host to swagger.json when calling Swagger UI I am generating swagger.json files for several domains and I have not found a good way to get the host specified in my beanconfig. Now I am putting together a webapp with just the links to the swagger.json files for my domains using Swagger UI. Since host is not included in the generated swagger.json files I cant "try" the REST calls from my Swagger UI. However, I do know the host when a am calling the Swagger UI so I was wondering if there is a way to add the host in my Swagger UI config? I was hoping for something like this: <script> window.onload = function() { // Build a system const ui = SwaggerUIBundle({ url: "ws/rest/swagger.json", host: "ddweb.snowman00.se:19019", dom_id: '#swagger-ui', validatorUrl: null, presets: [ SwaggerUIBundle.presets.apis, SwaggerUIStandalonePreset ], plugins: [ SwaggerUIBundle.plugins.DownloadUrl ], layout: "StandaloneLayout" }) window.ui = ui } </script> It seems that this is not an existing option. How would I go about adding this to the source code? Does someone have any suggestions? -- You received this message because you are subscribed to the Google Groups "Swagger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Swagger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
