blob: d27ca3c0c164331ef270fa9534155e529414671a [file] [log] [blame]
== Camel Rest OpenApi example
This example shows how to call a REST service defined using OpenApi
specification with the help of Camel Rest OpenApi component.
The example is a standalong Spring Boot application that acts as a REST
client, you can run simply by issuing:
$ mvn spring-boot:run
Or by packaging it and running it using `+java+` CLI:
$ mvn package
$ java -jar target/camel-example-spring-boot-rest-openapi-simple-*.jar
The example by default uses the PetStore demo hosted on and
invokes the `+logoutUser+` operation. You can make it call any API
that you have OpenApi specification for and any operation with simple
arguments, for instance this retrives a pet from the PetStore demo with
ID `+14+`:
$ java -jar target/camel-example-spring-boot-rest-openapi-*.jar \
--openapi= \
--operation=getPetById \
=== Help and contributions
If you hit any problem using Camel or have some feedback, then please[let us know].
We also love contributors, so[get involved] :-)
The Camel riders!