Background and strategic fit
The purpose of this Integration is to pull over Location information that can be used in other APIs as request. This document provides information on how to consume the API's by the end Users.
Assumptions
- ProcessMAP system User permissions would not be considered while exposing the data
- Data will be shown in Readable JSON format
- User accessing this endpoint through a valid Token & ConsumerId, provided by ProcessMAP, will have access to complete data
User Interaction
Location
Location Details
Request
Ex: papi/v1/imsoutbound/nearmissincidents?locationCode=westlake&dateFrom=2019-07-01&dateTo=2019-07-30
URI Parameters
Location Code in string format, DateFrom & DateTo are to be passed as parameters.
Name | Description | Type | Additional information |
---|---|---|---|
locationCode | Represents the unique code of location for which Incident records to return. | string | Required |
dateFrom | Represents the starting date of Incident records to return. | date | Required |
dateTo | Represents the ending date of Incident records to return. | date | Required |
Headers
Name | Description | Sample |
---|---|---|
Authorization | Represents the value of the authentication token. Allow multiple values: no. | Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ... |
ConsumerId | Represents the value of the consumer id. Allow multiple values: no. | 2426 |
Response
Sample:
{
}
Errors/Validation Messages
Generic Error codes are given below.
HTTP ERROR 401
{
"HttpStatusCode": 401,
"HttpStatus": "Unauthorized",
"ErrorCode": 1030,
"ErrorMessage": "Invalid tenant."
}
If the location code given is invalid:
{
"Message": "Invalid Location Code"
}
If the dates were not properly passed, i.e, From Date is greater than To Date
{
"Message": "Date From is greater than Date To"
}