Referring local JSON specification file

21 megtekintés
Ugrás az első olvasatlan üzenetre

Ashok Kumar Soundararajan

olvasatlan,
2015. aug. 28. 8:10:052015. 08. 28.
– Swagger
Hi,

I have my swagger specification JSON file local to my project.

How do I refer it in swagger so that the documentation is generated from my local file?

I believe it should be specified in URL in index.html, but not sure how exactly I should mention the file path.

Please help in this regard.

Regards,
Ashok

Ron Ratovsky

olvasatlan,
2015. aug. 28. 8:11:082015. 08. 28.
– Swagger
You can't mention a file path. You can include the JSON in the index.html and pass it internally to the SwaggerUi object.

--
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 swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
-----------------------------------------
http://swagger.io
https://twitter.com/SwaggerApi
-----------------------------------------

Ashok Kumar Soundararajan

olvasatlan,
2015. aug. 28. 8:49:412015. 08. 28.
– Swagger
Thank you Ron. Can you please give me a sample code(as how to JSON in the index.html and pass it internally to the SwaggerUi object)  as I am very new to swagger.

Appreciate your help....


On Friday, 28 August 2015 17:41:08 UTC+5:30, Ron wrote:
You can't mention a file path. You can include the JSON in the index.html and pass it internally to the SwaggerUi object.

On Fri, Aug 28, 2015 at 3:10 PM, Ashok Kumar Soundararajan <blosso...@gmail.com> wrote:
Hi,

I have my swagger specification JSON file local to my project.

How do I refer it in swagger so that the documentation is generated from my local file?

I believe it should be specified in URL in index.html, but not sure how exactly I should mention the file path.

Please help in this regard.

Regards,
Ashok





--

Ron Ratovsky

olvasatlan,
2015. aug. 28. 8:51:512015. 08. 28.
– Swagger
Look at the 'spec' parameter here - https://github.com/swagger-api/swagger-ui#parameters.

--
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 swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ashok Kumar Soundararajan

olvasatlan,
2015. aug. 28. 8:54:002015. 08. 28.
– Swagger
Cool....Thank you so much Ron
Válasz mindenkinek
Válasz a szerzőnek
Továbbítás
0 új üzenet