JSonPath
Skip to end of metadata
Go to start of metadata

JSonPath

Available as of Camel 2.13

Camel supports JSonPath to allow using Expression or Predicate on json messages.

Using XML configuration

If you prefer to configure your routes in your Spring XML file then you can use JSonPath expressions as follows

Syntax

See the JSonPath project page for further examples.

JSonPath injection

You can use Bean Integration to invoke a method on a bean and use various languages such as JSonPath to extract a value from the message and bind it to a method parameter.

For example

Dependencies

To use JSonPath in your camel routes you need to add the a dependency on camel-jsonpath which implements the JSonPath language.

If you use maven you could just add the following to your pom.xml, substituting the version number for the latest & greatest release (see the download page for the latest versions).

Labels
  • No labels