cancel
Showing results for 
Search instead for 
Did you mean: 

Importing legacy Java project into Swagger, Swagger Hub

New Member

Importing legacy Java project into Swagger, Swagger Hub


I have some Java code with Java annotations in it that define a Swagger interface. I have the URL but no YAML file defining the interface. How do I create a YAML file from the annotated Java code?

Here is an example of the Java code:
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
...
@ApiOperation(value="(get the AAR files under directory AAR )")
@ApiImplicitParams({
@ApiImplicitParam(value = "this is Campus Id eg:101" ,name = "CAMPUS",required = false,dataType = "String",paramType = "query"),

1 REPLY 1
Moderator

Re: Importing legacy Java project into Swagger, Swagger Hub


I have the URL but no YAML file defining the interface.

You can export OpenAPI YAML/JSON file from Swagger UI as explained here:

https://stackoverflow.com/questions/48525546/how-to-export-a-swagger-json-yaml-file-from-swagger-ui/...

 


Helen Kosova
SmartBear Documentation Team Lead
________________________
Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
New Here?
Join us and watch the welcome video:
Announcements