Code Monkey home page Code Monkey logo

apiee's Introduction

Apiee

Easy Swagger and Swagger UI in Java EE.

Build Status Maven Central License Javadocs

logo

[email protected]

Twitter URL


Quick Start

Apiee creates swagger documentation from your JAX-RS and Swagger annotations in Runtime. It also give you a custom Swagger UI screen.

The apiee-core library is published to maven central and artefacts is available in Nexus OSS

In your pom.xml:

 <!-- Apiee -->
 <dependency>
        <groupId>com.github.phillip-kruger</groupId>
        <artifactId>apiee-core</artifactId>
        <version>1.0.8</version>
 </dependency>

In you JAX-RS Application class:

@ApplicationPath("/api")
@SwaggerDefinition (info = @Info (
                    title = "Example Service",
                    description = "A simple example of apiee",
                    version = "1.0.0",
                    contact = @Contact (
                        name = "Phillip Kruger", 
                        email = "[email protected]", 
                        url = "http://phillip-kruger.com"
                    )
                )
            )
public class ApplicationConfig extends Application {

}

You can also set the @SwaggerDefinition part in apiee.properties (more about that later)

In your JAX-RS Endpoint class:

@Path("/example")
@Produces({MediaType.APPLICATION_JSON}) 
@Consumes({MediaType.APPLICATION_JSON})
@Api(value = "Example service")
@Log
public class ExampleService {
    
    @GET
    @ApiOperation(value = "Retrieve some example content", notes = "This will return some json to the client",response = JsonObject.class)
    public Response getExample(){
        JsonObject jsonObject = Json.createObjectBuilder().add("name", "apiee example").add("url", "https://github.com/phillip-kruger/apiee-example").build();
        log.log(Level.INFO, "GET: {0}", jsonObject);
        return Response.ok(jsonObject).build();
    }
}

You can then go to the apiee swagger-ui :

http://localhost:8080/your-application-context/your-jaxrs-application-path/apiee/

Security

You can add security using the normal Swagger annotation, or some properties in apiee.properties or a combination of both.

Basic Auth example:

As annotation:

@SwaggerDefinition (securityDefinition = 
    @SecurityDefinition(basicAuthDefinitions = @BasicAuthDefinition(key = "basic",description = "foo"))
)

Or in apiee.properties:

securityBasicAuthKey=basic
securityBasicAuthDesc=foo # Optional

API Key example

As annotation:

@SwaggerDefinition (securityDefinition = 
    @SecurityDefinition(apiKeyAuthDefinitions = @ApiKeyAuthDefinition(key = "api" , name="Authorization", in = ApiKeyAuthDefinition.ApiKeyLocation.HEADER))
)

Or in apiee.properties:

securityApiKeyKey=Bearer
securityApiKeyIn=HEADER # Optional. Default is HEADER. (HEADER/QUERY)
securityApiKeyDesc=foo # Optional
securityApiKeyName=Authorization # Optional. Authorization

OAuth 2 example

As annotation:

@SwaggerDefinition (securityDefinition = 
    @SecurityDefinition(oAuth2Definitions = @OAuth2Definition(key="oauth2",
                                authorizationUrl = "/auth",
                                description = "Bla bla bla",
                                flow = OAuth2Definition.Flow.PASSWORD,
                                scopes = @Scope(name = "scopename",description = "the scope"),
                                tokenUrl = "/auth/token"))
)

Or in apiee.properties:

securityOAuth2Key=oauth2
securityOAuth2AuthUrl=/auth
securityOAuth2TokenUrl=/auth/token
securityOAuth2Flow=PASSWORD # One of ACCESS_CODE,APPLICATION,IMPLICIT,PASSWORD
securityOAuth2Scopes=scopename:the scope,anotherName:the other scope # Comma-seperated with name:description
securityOAuth2Desc=bla bla bla

(above: an API key example)

Whitelabel

Apiee comes out of the box with it's own themed swagger ui. However, you might not want a monkey's face on you API documentation, so Apiee makes it easy to whitelabel the UI.

(above: default theme out-of-the-box)

In your web app /src/main/resources you can include the following files:

  • apiee.properties
  • apiee.png
  • apiee.css
  • apiee.html

Variables (apiee.properties)

The HTML template that creates the Swagger UI has some variables that you can define in a properties

copyrighBy=John Smith
title=Company X
jsonButtonCaption=download json
yamlButtonCaption=download yaml
swaggerUiTheme=monokai 

There are also some Swagger UI parameters (with default values) that you can include changing (below contains the default values):

supportedSubmitMethods=['get', 'post', 'put', 'delete']
docExpansion=none
jsonEditor=true
defaultModelRendering=scheme
showRequestHeaders=true
showOperationIds=false
validatorUrl=null

And some OAuth parameters (below contains the default values):

oauthClientId=your-client-id
oauthClientSecret=your-client-secret-if-required
oauthRealm=your-realms
oauthAppName=your-app-name
oauthScopeSeparator=

If you want more customization, you can include your own template (apiee.html), see Template section below.

You can also define the @SwaggerDefinition in the apiee.properties with the following properties (so then you can omit it from the source code annotation). NOTE: all properties are optional.

infoTitle=Company X Services
infoDescription=REST API of Company X
infoVersion=1.0.1
infoContactName=Phillip Kruger
[email protected]
infoContactUrl=http://phillip-kruger.com
infoLicenseName=Apache License, Version 2.0
infoLicenseUrl=http://www.apache.org/licenses/LICENSE-2.0
infoTermsOfService=Some terms here
consumes=application/json,application/xml
produces=application/json
basePath=/api
schemes=HTTP,HTTPS # valid values: HTTP,HTTPS,WS,WSS
host=myhost.com # if ommited, will figure this out based on headers and server
tags=example:example description,foo,bar

Theme (apiee.css)

Apiee includes swagger-ui-themes and use the muted theme as default. You can override the theme by setting the swaggerUiTheme in the apiee.properties (see above). You can also include your own CSS called apiee.css to style the UI. Themes available from swagger-ui-themes:

  • feeling-blue
  • flattop
  • material
  • monokai
  • muted
  • newspaper
  • outline

(above: some variables and theme changed)

Logo (apiee.png)

To replace the default monkey face logo, include the apiee.png file

(above: logo changed)

Template (apiee.html)

(Advanced) Lastly, if you want even more customization, you can provide you own HTML template to override the default default. This allows you to really change the Look and Feel of you Swagger UI

(above: custome html template)

Application Servers

Apiee has been tested using the following Java EE 7 application servers:

Via a Proxy

You can set some headers to create the correct URL in swagger documents and to make the the UI works. This is handy if the request is going through a proxy.

  • x-request-uri (if this is set, the path part of the URL will be set to this)
  • x-forwarded-port (if this is set, the port part of the URL will be set to this)
  • x-forwarded-host (if this is set, the host part of the URL will be set to this)
  • x-forwarded-proto (if this is set, the scheme or protocol part of the URL will be set to this)

Cache

The generation of the swagger document happens at first request and are cached per url for the lifetime of the running server (Application Scoped)

You can clear the cache in the following ways:

You can also see the time that the document has been created in the footer of the swagger UI screen.

Other usefull REST endpoints that might help with debugging:

{
  "date": "Fri Apr 20 14:06:00 SAST 2018",
  "formattedDate": "2018/04/20 2:06 PM"
}
[
  {
    "hash": 1912183572,
    "generatedOn": "Fri Apr 20 14:06:00 SAST 2018",
    "url": "http://localhost:8080/apiee-example/api/apiee/swagger.json"
  }
]

Blog entry

Also see this blog entry

Documentation available here: https://github.com/phillip-kruger/apiee/wiki

apiee's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

apiee's Issues

How can I back to Swagger 2.0?

Hi @phillip-kruger , this project is awesome and very useful.
Just one question for you: I use the latest version and it generates .json and .yaml files as Open API 3.0. Now I only need file in Swagger 2.0. Can I do that?
Thank you

Need Help: swagger.json file is generating swagger UI

Dear Sir,

If I have swagger.json file for any application(Say Test1), then can we use this json file to create rest document on the fly (into Another application say Test2)using our aipee dependency?

As I mailed, in order to meet my requirement ,

  1. I will save swagger.json file into db for each of applications
  2. In seperate application , Dynamically specific swagger.json file i will get from db
  3. and then I will use this fetched swagger.json to create swagger UI

Please guide me if we can proceed.

Thanks for your support in advance.

thanks.

Open API specification

Hi Philip,
Great Job.
I have a question about your integration.
Which version of open api your tooling implements? (3.0?)

Thx,

Disable Swagger UI programmatically

Hello Phillip,
I am trying to disable programmatically Swagger UI, when in Production for example.
But, I haven´t found any clue how to do it through Apiee.
Might be that a Apiee´s new feature ?

Thanks.

Parameter Deccription cant be set

Hi @phillip-kruger
how can I set parameter description for the method's input especially header parameters?
I also tried the @parameter annotation from swagger v3 but it doesn't help.
@Parameter(description = "The bla bla bla. ", required = true) @NotNull @HeaderParam(HttpConstant.X_REQUEST_ID) long requestId,

Swagger.json and generated ui are different

Hi! I use your project, and it generated the following definition( i see it when i click on the json button)- however in the ui it only shows note, authentication and realobjectservice?

{
  "swagger" : "2.0",
  "info" : {
    "description" : "Footnote combines real objects with digital information",
    "version" : "0.8",
    "title" : "Footnote-Server Swagger-UI",
    "contact" : {
      "name" : "Christopher Gusenbauer",
      "email" : "[email protected]"
    }
  },
  "host" : "localhost:8080",
  "basePath" : "/footnote/rest",
  "tags" : [ {
    "name" : "Authentication Rest Service"
  }, {
    "name" : "Note Rest Service"
  }, {
    "name" : "RealObject Rest Service"
  }, {
    "name" : "Main Rest Service"
  }, {
    "name" : "User Rest Service"
  } ],
  "schemes" : [ "http" ],
  "paths" : {
    "/auth/login" : {
      "post" : {
        "tags" : [ "Authentication Rest Service" ],
        "operationId" : "login",
        "consumes" : [ "application/json" ],
        "produces" : [ "text/plain" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/LoginInformation"
          }
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "string"
            },
            "headers" : { }
          }
        }
      }
    },
    "/note/insertNote/{id}" : {
      "post" : {
        "tags" : [ "Note Rest Service" ],
        "operationId" : "insertNote",
        "consumes" : [ "application/json" ],
        "produces" : [ "text/plain" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/Note"
          }
        }, {
          "name" : "id",
          "in" : "path",
          "required" : true,
          "type" : "integer",
          "format" : "int64"
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "string"
            },
            "headers" : { }
          }
        }
      }
    },
    "/note" : {
      "get" : {
        "tags" : [ "Note Rest Service" ],
        "summary" : "Finds all Entities of this Type",
        "description" : "",
        "operationId" : "findAll",
        "produces" : [ "application/json" ],
        "parameters" : [ ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "array",
              "items" : {
                "type" : "object"
              }
            }
          }
        }
      },
      "post" : {
        "tags" : [ "Note Rest Service" ],
        "summary" : "Updates Entity",
        "description" : "",
        "operationId" : "edit",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/Note"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "put" : {
        "tags" : [ "Note Rest Service" ],
        "summary" : "Inserts a New Entity in the Database",
        "description" : "",
        "operationId" : "create",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/Note"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "delete" : {
        "tags" : [ "Note Rest Service" ],
        "summary" : "Deletes Entity",
        "description" : "",
        "operationId" : "remove",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/Note"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/note/{id}" : {
      "post" : {
        "tags" : [ "Note Rest Service" ],
        "summary" : "Finds Entity with sent key",
        "description" : "",
        "operationId" : "find",
        "consumes" : [ "application/json" ],
        "produces" : [ "application/json" ],
        "parameters" : [ {
          "name" : "id",
          "in" : "path",
          "required" : true,
          "type" : "integer",
          "format" : "int64"
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "object"
            }
          }
        }
      }
    },
    "/realObject/getObjectsNotes" : {
      "post" : {
        "tags" : [ "RealObject Rest Service" ],
        "operationId" : "getObjectsNotes",
        "consumes" : [ "text/plain" ],
        "produces" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "integer",
            "format" : "int64"
          }
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "array",
              "items" : {
                "$ref" : "#/definitions/Note"
              }
            },
            "headers" : { }
          }
        }
      }
    },
    "/realObject" : {
      "get" : {
        "tags" : [ "RealObject Rest Service" ],
        "summary" : "Finds all Entities of this Type",
        "description" : "",
        "operationId" : "findAll_1",
        "produces" : [ "application/json" ],
        "parameters" : [ ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "array",
              "items" : {
                "type" : "object"
              }
            }
          }
        }
      },
      "post" : {
        "tags" : [ "RealObject Rest Service" ],
        "summary" : "Updates Entity",
        "description" : "",
        "operationId" : "edit_1",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/RealObject"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "put" : {
        "tags" : [ "RealObject Rest Service" ],
        "summary" : "Inserts a New Entity in the Database",
        "description" : "",
        "operationId" : "create_1",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/RealObject"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "delete" : {
        "tags" : [ "RealObject Rest Service" ],
        "summary" : "Deletes Entity",
        "description" : "",
        "operationId" : "remove_1",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/RealObject"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/realObject/{id}" : {
      "post" : {
        "tags" : [ "RealObject Rest Service" ],
        "summary" : "Finds Entity with sent key",
        "description" : "",
        "operationId" : "find_1",
        "consumes" : [ "application/json" ],
        "produces" : [ "application/json" ],
        "parameters" : [ {
          "name" : "id",
          "in" : "path",
          "required" : true,
          "type" : "integer",
          "format" : "int64"
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "object"
            }
          }
        }
      }
    },
    "/getFile" : {
      "post" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "getFile",
        "consumes" : [ "application/json" ],
        "produces" : [ "application/octet-stream" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "file"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/test" : {
      "post" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "test",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "string"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/json" : {
      "get" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "getHelloWorldJSON",
        "produces" : [ "application/json" ],
        "parameters" : [ ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "string"
            },
            "headers" : { }
          }
        }
      }
    },
    "/postNewTarget" : {
      "post" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "postNewTarget",
        "consumes" : [ "application/json" ],
        "produces" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "string"
          }
        }, {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "string"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/xml" : {
      "get" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "getHelloWorldXML",
        "produces" : [ "application/xml" ],
        "parameters" : [ ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "string"
            },
            "headers" : { }
          }
        }
      }
    },
    "/testContext" : {
      "get" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "testContext",
        "parameters" : [ ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/getFilewithPath" : {
      "post" : {
        "tags" : [ "Main Rest Service" ],
        "operationId" : "getFilewithPath",
        "consumes" : [ "text/plain" ],
        "produces" : [ "application/octet-stream" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "string"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/user/test" : {
      "post" : {
        "tags" : [ "User Rest Service" ],
        "operationId" : "test",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "type" : "string"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/user" : {
      "get" : {
        "tags" : [ "User Rest Service" ],
        "summary" : "Finds all Entities of this Type",
        "description" : "",
        "operationId" : "findAll_2",
        "produces" : [ "application/json" ],
        "parameters" : [ ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "array",
              "items" : {
                "type" : "object"
              }
            }
          }
        }
      },
      "post" : {
        "tags" : [ "User Rest Service" ],
        "summary" : "Updates Entity",
        "description" : "",
        "operationId" : "edit_2",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/User"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "put" : {
        "tags" : [ "User Rest Service" ],
        "summary" : "Inserts a New Entity in the Database",
        "description" : "",
        "operationId" : "create_2",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/User"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      },
      "delete" : {
        "tags" : [ "User Rest Service" ],
        "summary" : "Deletes Entity",
        "description" : "",
        "operationId" : "remove_2",
        "consumes" : [ "application/json" ],
        "parameters" : [ {
          "in" : "body",
          "name" : "body",
          "required" : false,
          "schema" : {
            "$ref" : "#/definitions/User"
          }
        } ],
        "responses" : {
          "default" : {
            "description" : "successful operation"
          }
        }
      }
    },
    "/user/{id}" : {
      "post" : {
        "tags" : [ "User Rest Service" ],
        "summary" : "Finds Entity with sent key",
        "description" : "",
        "operationId" : "find_2",
        "consumes" : [ "application/json" ],
        "produces" : [ "application/json" ],
        "parameters" : [ {
          "name" : "id",
          "in" : "path",
          "required" : true,
          "type" : "integer",
          "format" : "int64"
        } ],
        "responses" : {
          "200" : {
            "description" : "successful operation",
            "schema" : {
              "type" : "object"
            }
          }
        }
      }
    }
  },
  "securityDefinitions" : { },
  "definitions" : {
    "LoginInformation" : {
      "type" : "object",
      "properties" : {
        "email" : {
          "type" : "string"
        },
        "password" : {
          "type" : "string"
        }
      }
    },
    "Note" : {
      "type" : "object",
      "properties" : {
        "id" : {
          "type" : "integer",
          "format" : "int64"
        },
        "content" : {
          "type" : "string"
        },
        "files" : {
          "type" : "string"
        }
      },
      "description" : "A Note"
    },
    "RealObject" : {
      "type" : "object",
      "properties" : {
        "id" : {
          "type" : "integer",
          "format" : "int64"
        },
        "name" : {
          "type" : "string"
        },
        "description" : {
          "type" : "string"
        },
        "latitude" : {
          "type" : "number",
          "format" : "double"
        },
        "longitude" : {
          "type" : "number",
          "format" : "double"
        },
        "notes" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/definitions/Note"
          }
        }
      },
      "description" : "An Object in the Real World"
    },
    "User" : {
      "type" : "object",
      "properties" : {
        "id" : {
          "type" : "integer",
          "format" : "int64"
        },
        "firstname" : {
          "type" : "string"
        },
        "lastname" : {
          "type" : "string"
        },
        "email" : {
          "type" : "string"
        },
        "mobile" : {
          "type" : "string"
        },
        "passwordhash" : {
          "type" : "string"
        },
        "passwordsalt" : {
          "type" : "string"
        },
        "role" : {
          "type" : "string",
          "enum" : [ "GUEST", "USER", "MODERATOR", "ADMINISTRATOR" ]
        },
        "last_update" : {
          "type" : "string",
          "format" : "date-time"
        }
      },
      "description" : "Application User with Password that can login"
    }
  }
}

Entities

Would it be possible to show the entities in the Web-UI and their attributes, like in the normal Swagger UI?

Use Jwt Authentication Bearer

Hello,

We have an application using jwt bearer tokens for authentication.

Is it possible to configure apiee so a Authorization header can be added?

Regards

Server Port detection

The server port detection logic does not make provision for setting a port in the header if the server port is something other than 80 or 443

Not compatible with newest Jackson

Due to

'com.fasterxml.jackson.databind.JavaType com.fasterxml.jackson.databind.introspect.AnnotatedMember.getType(com.fasterxml.jackson.databind.type.TypeBindings)'

I've addressed this in my PR #19 , however, I found it a bit confusing where to merge the branch. As it's a fix to the OpenAPI 2 version of this application, and thus "belongs" to ApiEE 1, I'd merge it into the version_1 branch, but that one already has some other code in it which is more OpenAPI 3. So please help me out 😅

not showing all swaggerdefinition attribute if they are listed in aipee.properties

Hi ,

Thanks for your support in advance. I am using aipee library ..its really very useful.
i have few findings about this library. kindly help me on this.

  1. I put below attributes aipee.properties file but they are not getting shown in swagger UI
    consumes=application/json
    produces=application/json
    schemes=http
    tagsName=Private
    tagsDescription=Tag used to denote operations as private
    infoTermsOfService=sharing
    infoContactEmail=[email protected]

  2. Is there anyway to change this value at runtime and swagger will pick up changes as in my case at run time , i want to display current version of apps . because version keeps changing . So it would be really great if you help me on this as i am new to Swagger.

  3. One feedback , We are showing BASE URI at the bottom, ideally we should display at top because its important information. if possible , may i request you please to change it.

thanks again.

kindly help me on this

@ApiResponse annotation value is not getting displayed in Swagger UI

Dear Sir,

I observed one issue that @ApiResponse annotation like ( @ApiResponse(code = HttpURLConnection.HTTP_CREATED, message = "Successfully inserted historical data") ) is not getting displayed in Swagger UI.

Syntactically Here i tried both ways code=201 and code=HttpURLConnection.HTTP_CREATED , but no luck.

May I request you please to look into this issue.

For this issue, Please find attachment for code snippet and swagger UI.
codesnippet
swaggerui

I am using Aipee dependency with version 1.0.5 for swagger implementation of JAVA EE app.

com.github.phillip-kruger apiee-core 1.0.5

thanks

Version 2.0.0 (jakarta version) not published to maven central

Hi,

will you publish version 2.0.0 or 2.0.1 to maven central?. I found only the 2.0.0-oa3 for javax.

We use the library in some projects for Wildfly 30, and works great with 2.0.0... but adding the code to our project.

Thank you for your project and effort!

Using proxy

When i change

host=somehost.com

in apiee.properties

image

It does not change the url to the assets.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.