Request Headers
In order to make a valid HTTP Request to the API server, there are a number of headers to be included in the HTTP request for the purpose of authentication and request handling.
Depending on the platform you are using, a typical HTTP request would look similar to the following JavaScript example.
var options = {
'method' : 'post',
'contentType': 'application/json',
'muteHttpExceptions':true,
'headers':{
"X-RapidAPI-Key": *XRapidAPIKey*,
"X-RapidAPI-Host":"maintenanceman-nl-asset-management-api.p.rapidapi.com",
},
'payload' : JSON.stringify({*Request Body as JSON*})
};
var response = UrlFetchApp.fetch('https://maintenanceman-nl-asset-management-api.p.rapidapi.com/schedule', options);
General Request Headers
The general request headers to be included with every HTTP request are:
- Method: ‘post’
- Content-type: ‘application/json’
Specific Request Headers
Besides the general request headers, there are two additional custom headers to be included in every HTTP Request, being:
- X-RapidAPI-Key: ‘*YourAPIKey*’
This is your own unique API key that you can get from your subscription on the Maintenanceman API at rapidAPI.com - X-RapidAPI-Host:‘maintenanceman-nl-asset-management-api.p.rapidapi.com’
This value is used at rapidAPI.com to identify your request as being meant to be forwarded to the Maintenanceman API backend.
Request end-point
The URL that your request should be sent to is always: ‘https://maintenanceman-nl-asset-management-api.p.rapidapi.com/schedule’.
