Skip to content

Get assignments of car

GET
/cars/{carId}/assignments
curl --request GET \
--url https://api-uat.flinkey.de/v3/cars/1/assignments \
--header 'Authorization: Bearer <token>' \
--header 'Customer-ID: example' \
--header 'flinkey-API-Key: <flinkey-API-Key>'

Purpose

Retrieve assignments for one specific car in the selected customer context.

An assignment grants access from a user to a car for a defined time range.

Use this operation to inspect which assignments exist for a specific car.

The returned assignment data can be used for reconciliation, support workflows or backend state validation.

When to use this operation

Use this operation when the partner backend needs to retrieve assignments related to one specific flinkey car.

Typical situations:

  • checking which users currently have access to a car,
  • validating assignment state for a vehicle,
  • troubleshooting mobile access for a specific car,
  • troubleshooting assignment creation,
  • reconciling partner vehicle access records with flinkey assignment records,
  • inspecting assignment start and end times for a vehicle.

In most integrations, the partner backend should persist a mapping between the partner vehicle and the flinkey carId.

Use the mapped carId to retrieve assignments for the correct flinkey car.

Do not create new assignments before checking whether the intended access already exists, if duplicate access would cause operational issues.

Validation notes

PROD validation result:

  • GET /cars/{carId}/assignments was successfully executed with flinkey-API-Key, Authorization: Bearer {{accessToken}} and Customer-ID.
  • The response is an array.
  • id is returned as number.
  • userId is returned as number.
  • start is returned as UTC timestamp string.
  • end may be null.
  • lifetime is returned as number when provided.
  • renewableAfter may be null.
  • The response model does not include carId; the car context is defined by the path parameter.
  • $top, $skip, $filter and $orderby are supported.
  • $select is not recommended and must not be used.

Async behavior

Synchronous.

The assignments are returned directly in the API response.

Webhook result

No.

This operation does not produce a webhook result.

Security notes

Never log:

  • flinkey-API-Key,
  • bearer token,
  • full request headers.

Car and assignment identifiers are environment-specific.

Do not mix UAT and PROD car IDs or assignment IDs.

Use placeholders in documentation, examples, screenshots and AI prompts.

For standard partner integrations, the mobile app must not receive API Manager credentials, backend bearer tokens or the flinkey-API-Key.

carId
required
number

Database ID of the car

Customer-ID
required
string

Customer database ID

Assignments of the car were retrieved successfully

Media typeapplication/json
Array<object>
object
id

Assignment database ID

number
userId

User database ID assigned to the car

number
start

Assignment start time as UTC timestamp

string
end

Assignment end time as UTC timestamp, or null for open-ended access

string | null
lifetime

Assignment lifetime in seconds, if provided

number | null
renewableAfter

Renewal timing information, if provided

number | null
Example
[
{
"id": 10001,
"userId": 30001,
"start": "2026-02-10T10:11:02.240Z",
"end": null,
"lifetime": 604800,
"renewableAfter": null
}
]

Invalid subscription key or missing / invalid access token

Recommended handling: Check flinkey-API-Key, bearer token and environment configuration

API Manager, customer context or assignment data was not found

Recommended handling: Check credentials, Customer-ID and local carId mapping

Server-side error

Recommended handling: Retry later if appropriate and escalate if persistent