Introduction
The MaSS API gives access to the data of all the sites covered by MaSS.
There are four methods: Search, List, Get and References. All methods return json.
To prevent abuse, we limit the access to the API per IP address. If your application stays under 720 queries per hour, you'll be fine. If we detect abuse, we will have to block your IP address.
We will release a new version when we make backwards-incompatible changes.
Latest version: v1
.
Search
Find sites for wich the name, location or description matches the search term.
URL template
https://mass.cultureelerfgoed.nl/api/v1/search/{searchterm}
Method
GET
Request example
https://mass.cultureelerfgoed.nl/api/v1/search/bahia
Parameters
Name | Data type | Conditions | Description | Default value |
---|---|---|---|---|
{searchterm} | string | (required), at least 4 characters | The term to search for. | null |
Response
Returns an array of objects. Each object has the following properties:
Name | Data type | Description | Example |
---|---|---|---|
id | integer | Unique database id | 233 |
code | string | Unique code | utrecht-the |
label | string | Name | Utrecht, The |
type | string | Heritage type, one of wreck, site, structure, plane, other | wreck |
lat | float | Latitude of location coordinates | -12.9938530 |
lon | float | Longitude of location coordinates | -38.6718750 |
location | string | Location name | Bahia, Brazil |
aliases | string | Other names under which the site is known | Stad Utrecht, De Uytrecht, Wapen van Utrecht |
List
Retrieve all sites.
URL template
https://mass.cultureelerfgoed.nl/api/v1/list/{language}/{wrapper}
Method
GET
Request examples
https://mass.cultureelerfgoed.nl/api/v1/list/
https://mass.cultureelerfgoed.nl/api/v1/list/nl/myCallback()
Parameters
Name | Data type | Conditions | Description | Default value |
---|---|---|---|---|
{language} | string | (optional), one of en, nl | Specifies the desired language of the response. | en |
{wrapper} | string | (optional) |
Wrap the response in JavaScript. If the value contains “()” then the response will be wrapped in: {wrapper}([]); .Otherwise the response will be wrapped in: var {wrapper} = []; .
|
null |
Response
Returns an array of objects. Each object has the following properties:
Name | Data type | Description | Example |
---|---|---|---|
id | integer | Unique database id | 233 |
code | string | Unique code | utrecht-the |
label | string | Name | Utrecht, The |
type | string | Heritage type, one of wreck, site, structure, plane, other | wreck |
lat | float | Latitude of location coordinates | -12.9938530 |
lon | float | Longitude of location coordinates | -38.6718750 |
location | string | Location name | Bahia, Brazil |
firstyear | signed integer | First year of building / commissioning | 1737 |
firstyearend | signed integer | Last year of building / commissioning | 1738 |
lastyear | signed integer | First year of demise | 1740 |
lastyearend | signed integer | Last year of demise | 1741 |
discovery | signed integer | Year of discovery | 2004 |
subtype | string | Specification of the type (in specified language) | Frigate |
Get
Get the properties of a specific site.
URL template
https://mass.cultureelerfgoed.nl/api/v1/get/{language}/{id}
Method
GET
Request examples
https://mass.cultureelerfgoed.nl/api/v1/get/233
https://mass.cultureelerfgoed.nl/api/v1/get/nl/utrecht-the
Parameters
Name | Data type | Conditions | Description | Default value |
---|---|---|---|---|
{language} | string | (optional), one of en, nl | Specifies the desired language of the response. | en |
{id} | string integer |
(required) | The unique code (string) or database id (integer). | null |
Response
Returns an object with the following properties:
Name | Data type | Description | Example |
---|---|---|---|
id | integer | Unique database id | 233 |
code | string | Unique code | utrecht-the |
name | string | Name | Utrecht, The |
type | string | Heritage type, one of wreck, site, structure, plane, other | wreck |
lat | float | Latitude of location coordinates | -12.9938530 |
lon | float | Longitude of location coordinates | -38.6718750 |
location | string | Location name | Bahia, Brazil |
firstdate | date | Date of commissioning (yyyy-mm-dd) | 1600-01-31 |
firstyear | signed integer | First year of building / commissioning | 1737 |
firstyearend | signed integer | Last year of building / commissioning | 1738 |
lastdate | date | Date of demise (yyyy-mm-dd) | 1600-01-31 |
lastyear | signed integer | First year of demise | 1740 |
lastyearend | signed integer | Last year of demise | 1741 |
country | string | Country of origin (in specified language) | Nederland |
countrycode | string | ISO 3166-1 alpha-2 code for the country of origin | NL |
author | string | Name of the author initialy added the site to the dataset | |
created_on | timestamp | Timestamp when the site was added to the dataset | 2010-12-06 00:00:00 |
modified_on | timestamp | Timestamp when the site data was last modfied | 2024-11-21 07:41:19 |
deleted_on | timestamp | Timestamp when the site was deleted from the dataset | null |
body | string | Description of the site in html format. | |
license | object | License for content use | |
license.title | string | Name of the license | |
license.href | string | Link to the license |
References
Retrieve all references.
URL template
https://mass.cultureelerfgoed.nl/api/v1/references/{wrapper}
Method
GET
Request examples
https://mass.cultureelerfgoed.nl/api/v1/references/
https://mass.cultureelerfgoed.nl/api/v1/references/myCallback()
Parameters
Name | Data type | Conditions | Description | Default value |
---|---|---|---|---|
{wrapper} | string | (optional) |
Wrap the response in JavaScript. If the value contains “()” then the response will be wrapped in: {wrapper}([]); .Otherwise the response will be wrapped in: var {wrapper} = []; .
|
null |
Response
Returns an array of objects. Each object has the following properties:
Name | Data type | Description | Example |
---|---|---|---|
type | string | Reference type, one of book, journal, webpage | journal |
title | string | The title of the book, journal article or webpage | The Dutch fluitship Anna Maria, foundered in Dalarö harbour in 1709 |
publicationyear | signed integer | Year of publication | 1987 |
author | string | Name of author(s), organisation or website | Britt-Marie Petersen |
journal | string | Journal title, volume (number), page numbers. | International Journal of Nautical Archaeology, vol 16.2 |
publisher | string | Publisher of the book, journal article or webpage | Wiley Blackwell Publishing Ltd |
url | string | Internet address of the online publication | https://onlinelibrary.wiley.com /doi/abs/10.1111 /j.1095-9270.1987.tb00603.x |
backlinks | array | List of internet addresses referring to this reference | [ "https://…/anna-maria-1693" ] |