Query mileage
curl --request POST \
--url https://sandbox.tight.com/v6/mileage/query \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"cursor": "<string>",
"limit": 123,
"sort": {},
"filter": {
"status": {
"in": [],
"notIn": []
},
"mileageStatus": {
"in": [],
"notIn": []
}
}
}
'{
"data": [
{
"id": "mlg_12345",
"date": "2024-03-15",
"status": "ACTIVE",
"mileageStatus": "BUSINESS",
"description": "Drive to client meeting",
"notes": "Client was not available",
"customer": {
"id": "cus_4852707",
"name": "Abigail Adams",
"email": "abigail@tight.com"
},
"dimensionValues": [
{
"id": "dv_593051",
"dimension": {
"id": "dim_4521",
"name": "Region",
"requiredness": "NOT_REQUIRED"
},
"name": "Mid-Atlantic",
"child": {
"id": "dv_593052",
"dimension": {
"id": "dim_4521",
"name": "Region",
"requiredness": "NOT_REQUIRED"
},
"name": "Washington DC",
"child": "<unknown>"
}
}
],
"distance": {
"type": "MILE",
"value": "12.5"
},
"start": {
"time": "2023-11-07T05:31:56Z",
"lat": "38.8977",
"lng": "-77.0365",
"location": {
"id": "loc_28868401",
"name": "Home Office"
},
"address": {
"countryCode": "USA",
"state": "<string>",
"city": "<string>",
"zip": "<string>",
"phoneWork": "<string>",
"address1": "<string>",
"address2": "<string>"
}
},
"end": {
"time": "2023-11-07T05:31:56Z",
"lat": "38.8977",
"lng": "-77.0365",
"location": {
"id": "loc_28868401",
"name": "Home Office"
},
"address": {
"countryCode": "USA",
"state": "<string>",
"city": "<string>",
"zip": "<string>",
"phoneWork": "<string>",
"address1": "<string>",
"address2": "<string>"
}
},
"duration": 3600000,
"deduction": {
"amount": 6775
},
"route": {
"id": "mrt_12345",
"waypoints": [
{
"lat": "38.8977",
"lng": "-77.0365"
}
]
},
"car": {
"id": "car_28868401",
"name": "My Toyota Camry",
"make": "Toyota",
"model": "Camry"
},
"customData": {
"internal_key": "some_internal_key",
"some_other_field": 23434
}
}
],
"cursor": {
"after": "<string>",
"before": "<string>"
}
}Mileage
Query mileage
Query mileage records for the authenticated user
POST
/
v6
/
mileage
/
query
Query mileage
curl --request POST \
--url https://sandbox.tight.com/v6/mileage/query \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"cursor": "<string>",
"limit": 123,
"sort": {},
"filter": {
"status": {
"in": [],
"notIn": []
},
"mileageStatus": {
"in": [],
"notIn": []
}
}
}
'{
"data": [
{
"id": "mlg_12345",
"date": "2024-03-15",
"status": "ACTIVE",
"mileageStatus": "BUSINESS",
"description": "Drive to client meeting",
"notes": "Client was not available",
"customer": {
"id": "cus_4852707",
"name": "Abigail Adams",
"email": "abigail@tight.com"
},
"dimensionValues": [
{
"id": "dv_593051",
"dimension": {
"id": "dim_4521",
"name": "Region",
"requiredness": "NOT_REQUIRED"
},
"name": "Mid-Atlantic",
"child": {
"id": "dv_593052",
"dimension": {
"id": "dim_4521",
"name": "Region",
"requiredness": "NOT_REQUIRED"
},
"name": "Washington DC",
"child": "<unknown>"
}
}
],
"distance": {
"type": "MILE",
"value": "12.5"
},
"start": {
"time": "2023-11-07T05:31:56Z",
"lat": "38.8977",
"lng": "-77.0365",
"location": {
"id": "loc_28868401",
"name": "Home Office"
},
"address": {
"countryCode": "USA",
"state": "<string>",
"city": "<string>",
"zip": "<string>",
"phoneWork": "<string>",
"address1": "<string>",
"address2": "<string>"
}
},
"end": {
"time": "2023-11-07T05:31:56Z",
"lat": "38.8977",
"lng": "-77.0365",
"location": {
"id": "loc_28868401",
"name": "Home Office"
},
"address": {
"countryCode": "USA",
"state": "<string>",
"city": "<string>",
"zip": "<string>",
"phoneWork": "<string>",
"address1": "<string>",
"address2": "<string>"
}
},
"duration": 3600000,
"deduction": {
"amount": 6775
},
"route": {
"id": "mrt_12345",
"waypoints": [
{
"lat": "38.8977",
"lng": "-77.0365"
}
]
},
"car": {
"id": "car_28868401",
"name": "My Toyota Camry",
"make": "Toyota",
"model": "Camry"
},
"customData": {
"internal_key": "some_internal_key",
"some_other_field": 23434
}
}
],
"cursor": {
"after": "<string>",
"before": "<string>"
}
}Authorizations
Bearer authentication header of the form Bearer <token>, see Authentication for more detail.
Body
application/json
Response
Success
The result of the action performed.
Available options:
SUCCESS, FAILURE The data generated by the action performed.
Show child attributes
Show child attributes
Cursor to be used in your subsequent paginated request. Only populated if there are more pages available.
Show child attributes
Show child attributes
⌘I