Create Location Entry
Create a new LocationEntry for a Vehicle or for a Contact. If you need to create many Location Entries at once, use the Bulk API to avoid Rate Limiting errors.
- application/json
Request Body
- For Contact
- For Vehicle
- contact_id integer required
Possible values:
>= 1
- date date-time required
We recommend using ISO-8601 formatted dates to avoid ambiguity.
- latitude Coordinate required
Possible values:
>= -90
and<= 90
- longitude Coordinate required
Possible values:
>= -90
and<= 90
- vehicle_id integer required
Possible values:
>= 1
- date date-time required
We recommend using ISO-8601 formatted dates to avoid ambiguity.
- latitude Coordinate required
Possible values:
>= -90
and<= 90
- longitude Coordinate required
Possible values:
>= -90
and<= 90
- 201
- 401
- 422
- 500
OK
Response Headers
- application/json
- Schema
- Example (from schema)
Schema
- id integer
Possible values:
>= 1
- created_at date-time
The date and time at which this record was created.
- updated_at date-time
The date and time at which this record was most recently updated.
- account_id integer
Possible values:
>= 1
- date date-time
The date and time at which this Location Entry was recorded.
- item_type string
Possible values: [
Vehicle
,Contact
]The type of object that this Location Entry is associated with.
- item_id NullableId
Possible values:
>= 1
- locatable_type string
Possible values: [
FuelEntry
,ServiceEntry
,SubmittedInspectionForm
]The type of object that triggered the creation of this Location Entry, if applicable.
- locatable_id NullableId
Possible values:
>= 1
- contact_id NullableId
Possible values:
>= 1
- address string
The full address where this Location Entry took place.
address_components object
street_number stringThe street number in the address.
street stringThe street name in the address.
city stringThe city in the address.
region stringThe region, state or province in the address.
region_short stringThe abbreviated region, state or province code.
country stringThe country in the address.
country_short stringThe abbreviated country code.
postal_code stringThe postal code, ZIP, or equivalent in the address.
- is_current boolean
Indicates whether this Location Entry is the most recent one for this object.
- location string
A string representation of the recorded location.
- account_membership_id NullableId
Possible values:
>= 1
- vehicle_archived_at date-time
The date and time at which the
Vehicle
associated with this Location Entry was archived, if applicable. - contact_archived_at date-time
The date and time at which the
Contact
associated with this Location Entry was archived, if applicable.
{
"id": 0,
"created_at": "2023-03-14T13:46:27-06:00",
"updated_at": "2023-03-14T13:46:27-06:00",
"account_id": 0,
"date": "2023-03-14T13:46:27-06:00",
"item_type": "Vehicle",
"item_id": 0,
"locatable_type": "FuelEntry",
"locatable_id": 0,
"contact_id": 0,
"address": "string",
"address_components": {
"street_number": "string",
"street": "string",
"city": "string",
"region": "string",
"region_short": "string",
"country": "string",
"country_short": "string",
"postal_code": "string"
},
"is_current": true,
"location": "POINT (33.515000,-86.807610)",
"account_membership_id": 0,
"vehicle_archived_at": "2024-12-19",
"contact_archived_at": "2024-12-19"
}
Request could not be authenticated
- application/json
- Schema
- Example (from schema)
Schema
- status integer
Possible values:
>= 400
and<= 599
- title string
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- instance string
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Unprocessable Entity
- application/json
- Schema
- Example (from schema)
- Example
Schema
errors object
typeitems string
{
"errors": {}
}
{
"errors": {
"field1": [
"error1",
"error2"
],
"field2": [
"error3"
]
}
}
Something unexpected happened
- application/json
- Schema
- Example (from schema)
Schema
- status integer
Possible values:
>= 400
and<= 599
- title string
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- instance string
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}