Introduction¶
The Cantabular Extended API provides a powerful interface to
publishable data hosted by a separate cantabular-server
service, combined with
reference metadata hosted by an instance of cantabular-metadata
.
It offers a GraphQL endpoint as its primary means of allowing a user to query for tabulations of data, structural metadata and reference metadata. GraphQL was chosen to give an API user flexibility in requesting exactly what they need and increased usability in the output format.
The API uses the HTTP(S) protocol. Requests typically use the GET method, but requests to the GraphQL endpoint that have a large body can alternatively use the POST method. Responses to valid queries are provided as JSON (RFC 7159). Responses to queries containing invalid parameter values are provided as JSON-encoded error objects.
There is also an optional JSON-stat endpoint.
About GraphQL¶
GraphQL is a query language for APIs that was designed by Facebook and is now an open, community standard. It allows consumers to query for data across a range of related entities, requesting only the entities and associated attributes that they require for their own use case.
The GraphQL endpoint affords a high degree of flexibility and power in requesting exactly the data a user needs, whether that’s structural metadata about a dataset in Cantabular or executing a cross-tabulation.