Assign car to group
const url = 'https://api-uat.flinkey.de/v3/groups/1/cars';const options = { method: 'PUT', headers: { 'Customer-ID': 'example', 'flinkey-API-Key': '<flinkey-API-Key>', Authorization: 'Bearer <token>', 'Content-Type': 'application/json' }, body: '{"carId":12345}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://api-uat.flinkey.de/v3/groups/1/cars \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --header 'Customer-ID: example' \ --header 'flinkey-API-Key: <flinkey-API-Key>' \ --data '{ "carId": 12345 }'Purpose
Assign a car to one specific group in the selected customer context.
A group is an entity represented by a group ID.
A group can contain cars, users, services and products.
Use this operation for operational grouping workflows where a car must be added to an existing group.
When to use this operation
Use this operation when the partner backend or operational backend needs to assign a car to a group.
Typical situations:
- adding a car to an operational group,
- preparing group-based vehicle administration,
- grouping vehicles for support workflows,
- grouping vehicles for setup or reconciliation workflows,
- correcting group membership after reconciliation,
- maintaining group-based operational views.
Before assigning a car to a group, the partner backend should have resolved:
- the correct
Customer-ID, - the flinkey
groupId, - the flinkey
carId, - whether the group exists,
- whether the car exists,
- whether the car is already assigned to the group.
For standard access flows, partner backends usually work primarily with Car, User and Assignment.
Group membership is an operational grouping concept and should not be treated as the primary vehicle access permission.
Validation notes
- PROD returned
204 No Contentwith an empty response body. - A subsequent
GET /groups/{groupId}/carsreturned the assigned car. - After removal, the same GET returned an empty array.
Async behavior
Synchronous.
The group assignment result is represented by 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.
Group and car identifiers are environment-specific.
Do not mix UAT and PROD group IDs or car 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.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Database ID of the group
Header Parameters
Section titled “Header Parameters”Customer database ID
Request Bodyrequired
Section titled “Request Bodyrequired”object
Database ID of the car to assign to the group
Example
{ "carId": 12345}Responses
Section titled “Responses”Car was assigned to the group successfully
Invalid subscription key or missing / invalid access token
Recommended handling: Check flinkey-API-Key, bearer token and environment configuration
API Manager, customer context, group or car was not found
Recommended handling: Check credentials, token context, Customer-ID, local groupId mapping and local carId mapping
The car is already assigned to the group
Recommended handling: Treat as already assigned if this matches the intended state, or reconcile local group-car mapping
Request content type is missing or incorrect
Recommended handling: Ensure Content-Type: application/json is used
Server-side error
Recommended handling: Retry later if appropriate and escalate if persistent
