Clone wiki

vapour / api

Vapour exposes exactly the same RDF report through a REST API (currently only RDF/XML is supported). The reports are generated using EARL as the primary vocabulary.

It can be accessed using content negotiation, for instance using curl:

$ curl -H "Accept: application/rdf+xml" ""

Or forcing the returned format with a query parameter, for instance:

$ curl ""


Although you are free to use the raw RDF version of the report, we are also providing API bindings for some popular programming languages:


This bindings provides a Java-native API to use Vapour, allowing to perform validations and retrieve the details if the test suite executed. Using maven you just need to declare this dependency:


If you don't want to install it from the code, the simplest method to get the library is using the following repository:


For those who are not using maven in their projects, a JAR package with dependencies is also provided (vapour-api-1.0-with-dependencies.jar).

Please, be careful using this package in your projects, because the dependencies included could conflict with yours.

Finally, the code you would need to used could be something like:

VapourApi api = VapourApiFactory.createVapourApi();
VapourReport report = api.check("");

If you would require more details, this class diagram might be useful.


Although it is still in an early development state, the Vapour API can be also used from Javascript (the public service is CORS-enabled). You just need to include something like this in your webpage:

<form id="vapour">
  <label for="uri">
    <input type="text" name="uri" id="uri" size="50" value="" />
  <input type="submit" value="check" />

<script type="text/javascript" src=""></script>
<script type="text/javascript" src=""></script>
<script type="text/javascript" src=""></script>
<script type="text/javascript" src=""></script>
<script type="text/javascript">
  $(document).ready(function() {

The file vapour.js provides the basic functionality to work with Vapour, allowing the validation of a URI and embedding the report with the performed tests on any web page. A full demo file is provided at the same source code repository for explain its usage.

This bindings are based on rdfQuery plugin for jQuery.


FundaciĆ³n CTIC