Currently it is possible to access our database via simple rest API, which allows read-only queries (via GET, HEAD or POST requests) and returns data in json format. The data are paginated, but it is very easy to retrieve all data, when needed.
To prevent overloading of our website, you will have to specify access-token={your_access_token}
in each query.
To obtain it, you must be logged in
https://avisample.net/api/sample?access-token={your_access_token}
will return sample descriptions.
https://avisample.net/api/tissue
will return list of all tissue types that are in the database.
https://avisample.net/api/taxon
will return list of all taxa that are in the database (out of all in the Clemens checklist).
https://avisample.net/api/country
will return list of all countries.
Filtering is done via keywords, e.g. filter[taxon_common]
and operators [like]
, [gt]
, [lt]
, [eq]
. See some examples below
https://avisample.net/api/sample?filter[taxon_scientific][like]=Acrocephalus
will return all sample descriptions of birds whose taxonomic names contains word acrocephalus, i.e. those from genus Acrocephalus.https://avisample.net/api/sample?filter[date][gt]=2010-01-01
will return all sample descriptions that were collected after 2010-01-01.https://avisample.net/api/sample?filter[tissue][like]=bone
will return all sample descriptions of collected bones.The filters can be combined, thus https://avisample.net/api/sample?filter[taxon_scientific][like]=Acrocephalus&filter[tissue][like]=feather&filter[date][gt]=2010-01-01
will return all sample descriptions of feathers of birds from genus Acrocephalus collected after 1st January 2010.
If you prefer you can access the API via R, and potentially our avisample
package - it is available for experimental use at github