openapi-generator/samples/server/petstore/undertow
Benjamin Douglas 34d9dca5e7 Update samples to current code/scripts
This is the result of

  - `$ git checkout master`
  - `$ bin/run-all-petstore`

No change was made to the code, just ran the aggregate sample generation
script.
2017-05-02 10:33:06 -07:00
..
src/main Update samples to current code/scripts 2017-05-02 10:33:06 -07:00
.swagger-codegen-ignore Add a new language generator for undertow-server framework (#3820) 2016-09-19 22:45:10 +08:00
dependency-reduced-pom.xml Replace ^M with new line (\r) in mustache template (#3865) 2016-09-26 16:49:44 +08:00
pom.xml Add a new language generator for undertow-server framework (#3820) 2016-09-19 22:45:10 +08:00
README.md Add a new language generator for undertow-server framework (#3820) 2016-09-19 22:45:10 +08:00

Swagger Undertow Server

Start server

Run with

mvn package exec:exec
``

## Test

By default, all endpoints are protected by OAuth jwt token verifier. It can be turned off with config change through for development.


In order to access the server, there is a long lived token below issued by my
oauth2 server [undertow-server-oauth2](https://github.com/networknt/undertow-server-oauth2)

Bearer eyJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJ1cm46Y29tOm5ldHdvcmtudDpvYXV0aDI6djEiLCJhdWQiOiJ1cm46Y29tLm5ldHdvcmtudCIsImV4cCI6MTc4ODEzMjczNSwianRpIjoiNWtyM2ZWOHJaelBZNEJrSnNYZzFpQSIsImlhdCI6MTQ3Mjc3MjczNSwibmJmIjoxNDcyNzcyNjE1LCJ2ZXJzaW9uIjoiMS4wIiwidXNlcl9pZCI6InN0ZXZlIiwidXNlcl90eXBlIjoiRU1QTE9ZRUUiLCJjbGllbnRfaWQiOiJkZGNhZjBiYS0xMTMxLTIyMzItMzMxMy1kNmYyNzUzZjI1ZGMiLCJzY29wZSI6WyJhcGkuciIsImFwaS53Il19.gteJiy1uao8HLeWRljpZxHWUgQfofwmnFP-zv3EPUyXjyCOy3xclnfeTnTE39j8PgBwdFASPcDLLk1YfZJbsU6pLlmYXLtdpHDBsVmIRuch6LFPCVQ3JdqSQVci59OhSK0bBThGWqCD3UzDI_OnX4IVCAahcT9Bu94m5u_H_JNmwDf1XaP3Lt4I34buYMuRD9stchsnZi-tuIRkL13FARm1XA9aPZUMUXFdedBWDXo1zMREQ_qCJXOpaZDJM9Im0rIkq9wTEVU00pbRp_Vcdya3dfkFteBMHiwFVt6VNQaco5BXURDAIzXidwQxNEbX1ek03wra8AIani65ZK7fy_w


Postman is the best tool to test REST APIs

Add "Authorization" header with value as above token and a dummy message will return from the generated stub.