Mileage - Get routes

API Url

Used to get mileage routes for an employee.

GET
http://localhost:16010/ProMarkREST/rest/Mileage/employees/{emp_id}/routes

Permissions: user

Path parameters

FieldTypeDescription
emp_idString

Employee ID.

Success 200

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data.

    routesObject[]

Collection of absence intervals.

      distanceNumber

Distance of a route.

      fromString

Starting position of a route.

      idNumber

Unique identifier for the absence object.

      nameString

Route name given by the emplyee.

      toString

Ending position of a route.

      viaoptionalString

Alternate route.

  messageoptionalObject

Object containing response messages.

    codeNumber

Message code.

    textString

Message text.

    typeString

Type of message.

Allowed values:"warning""info"

Success example:

HTTP/1.1 200 OK
{
"response": {
"data": {
"routes": [
{
"id": 343423
"name": KICKOFF
"from": "Bucharest",
"to": "Copenhagen",
"distance" : 2137
}
]
},
"errorCode": 0,
"errorMessage": ""
}
}

Error 4xx

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data (empty).

  errorCodeNumber

Error code.

  errorMessageString

Error description.