All Projects → swagger-api → swagger-petstore

swagger-api / swagger-petstore

Licence: Apache-2.0 license
petstore.swagger.io

Programming Languages

java
68154 projects - #9 most used programming language
HTML
75241 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to swagger-petstore

openapi-petstore
The pet store sample
Stars: ✭ 35 (-58.33%)
Mutual labels:  openapi, openapi3, petstore
oas
OpenAPI Spec builder in go
Stars: ✭ 15 (-82.14%)
Mutual labels:  openapi, openapi3
firecracker
Stop half-done API specifications! Cherrybomb is a CLI tool that helps you avoid undefined user behaviour by validating your API specifications.
Stars: ✭ 438 (+421.43%)
Mutual labels:  openapi, openapi3
OpenAlchemy
Define SQLAlchemy models using the OpenAPI specification.
Stars: ✭ 39 (-53.57%)
Mutual labels:  openapi, openapi3
openapi
OpenAPI 3 Specification for golang
Stars: ✭ 18 (-78.57%)
Mutual labels:  openapi, openapi3
whook
Build strong and efficient REST web services.
Stars: ✭ 18 (-78.57%)
Mutual labels:  openapi, openapi3
Tavis.OpenApi
Parser for OpenAPI Specification
Stars: ✭ 18 (-78.57%)
Mutual labels:  openapi, openapi3
openapi4j
OpenAPI 3 parser, JSON schema and request validator.
Stars: ✭ 92 (+9.52%)
Mutual labels:  openapi, openapi3
Unchase.OpenAPI.Connectedservice
📜 Visual Studio extension to generate OpenAPI (Swagger) web service reference.
Stars: ✭ 69 (-17.86%)
Mutual labels:  openapi, openapi3
swaggerhub-cli
SwaggerHub CLI
Stars: ✭ 28 (-66.67%)
Mutual labels:  openapi, openapi3
openapimux
Open API router in go
Stars: ✭ 21 (-75%)
Mutual labels:  openapi, openapi3
swagger-converter
OpenAPI/Swagger 2.0 to OpenAPI 3.0 Converter WebService
Stars: ✭ 58 (-30.95%)
Mutual labels:  openapi, openapi3
ogen
OpenAPI v3 code generator for go
Stars: ✭ 436 (+419.05%)
Mutual labels:  openapi, openapi3
openapi-generator-go
An opinionated OpenAPI v3 code generator for Go. Use this to generate API models and router scaffolding.
Stars: ✭ 42 (-50%)
Mutual labels:  openapi, openapi3
openapi-eller
Generate OpenAPI v3 clients and servers from the command line
Stars: ✭ 19 (-77.38%)
Mutual labels:  openapi, openapi3
HibiAPI
一个实现了多种常用站点的易用化API的程序 / A program that implements easy-to-use APIs for a variety of commonly used sites.
Stars: ✭ 427 (+408.33%)
Mutual labels:  openapi, openapi3
openapi-filter
Filter internal paths, operations, parameters, schemas etc from OpenAPI/Swagger/AsyncAPI definitions
Stars: ✭ 112 (+33.33%)
Mutual labels:  openapi, openapi3
intellij-openapi-generator
Intellij Plugin for openapi-generator
Stars: ✭ 73 (-13.1%)
Mutual labels:  openapi, openapi3
n26-api
Unofficial N26 Bank API documentation
Stars: ✭ 41 (-51.19%)
Mutual labels:  openapi, openapi3
KaiZen-OpenApi-Parser
High-performance Parser, Validator, and Java Object Model for OpenAPI 3.x
Stars: ✭ 119 (+41.67%)
Mutual labels:  openapi, openapi3

Swagger Petstore Sample

Overview

This is the pet store sample hosted at https://petstore3.swagger.io. For other versions, check the branches. We welcome suggestion both the code and the API design. To make changes to the design itself, take a look at https://github.com/swagger-api/swagger-petstore/blob/master/src/main/resources/openapi.yaml.

This is a java project to build a stand-alone server which implements the OpenAPI 3 Spec. You can find out more about both the spec and the framework at http://swagger.io.

This sample is based on swagger-inflector, and provides an example of swagger / OpenAPI 3 petstore.

To run (with Maven)

To run the server, run this task:

mvn package jetty:run

This will start Jetty embedded on port 8080.

To run (via Docker)

Expose port 8080 from the image and access petstore via the exposed port. You can then add and delete pets as you see fit.

Example:

docker build -t swaggerapi/petstore3:unstable .
docker pull swaggerapi/petstore3:unstable
docker run  --name swaggerapi-petstore3 -d -p 8080:8080 swaggerapi/petstore3:unstable

Testing the server

Once started, you can navigate to http://localhost:8080/api/v3/openapi.json to view the Swagger Resource Listing. This tells you that the server is up and ready to demonstrate Swagger.

Using the UI

There is an HTML5-based API tool bundled in this sample--you can view it it at http://localhost:8080. This lets you inspect the API using an interactive UI. You can access the source of this code from here

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].