Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

API endpoints that return a list of results use a set of common parameters, return formats and rules for pagination.

 

Parameters

NameOptionalDescription
rowsNO

Number of elements to return. Range must be between 10 and 200

Individual services may define different allowed ranges

offsetNO

Offset of the query

 

Return codes

HTTP CodeDescription
200

OK

400

Parameters rows or offset are not present

rows is out of range

offset is negative

404

offset > num_found

If there are 0 results, a request will offset 0 will return 200 with an empty results list. Any other offset will be a 404.

Result format

The API result will include at least 2 values: the total number of elements and the elements for the current pagination.

Services may include extra fields on the root object.

{
  "num_found": N,
  "results": [...],
  ...
}
KeyTypeDescription
num_foundintegerTotal number of results
resultsarrayActual results. The type of result depends on the API endpoint

 

 

  • No labels