Get the contract of service
const url = 'https://api-uat.flinkey.de/v3/services/example/contracts';const options = { method: 'GET', headers: { 'Customer-ID': 'example', 'flinkey-API-Key': '<flinkey-API-Key>', Authorization: 'Bearer <token>' }};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api-uat.flinkey.de/v3/services/example/contracts \ --header 'Authorization: Bearer <token>' \ --header 'Customer-ID: example' \ --header 'flinkey-API-Key: <flinkey-API-Key>'Purpose
Retrieve contract information assigned to one specific service in the selected customer context.
A contract represents the contractual information associated with a flinkey service.
Use this operation for operational lookup, reconciliation and support workflows where contract-level information for a service is required.
In standard developer integrations, partner backends usually work primarily with Car, User and Assignment.
When to use this operation
Use this operation when the partner backend needs to retrieve contract information for a specific service.
Typical situations:
- retrieving contract metadata for operational support,
- checking order number or document number,
- checking contract start and end dates,
- checking term of contract,
- checking term of notice,
- reconciling service and contract state with partner or support records,
- troubleshooting service or product assignment.
Do not treat Contract as the primary access permission object.
Access permissions are managed through assignments between User and Car.
Validation notes
- The operation returned
200 OKwith one contract object despite the plural/contractspath. - Regular active and terminated services retained populated contract data. Service termination did not remove the historical contract object.
- An unlimited service created directly in the administration portal returned the complete contract shape with every field set to
null; missing SAP contract data did not produce404 Not Found. - Contract end dates and service termination are separate concepts. The contract object alone does not expose whether the service is terminated; use
isTerminatedfrom the service resource. unitOfNoticewas returned as an opaque string code and must not be interpreted without an explicit mapping.- Collection-style OData options returned
400 Bad Requestbecause the resource is not a collection.
Async behavior
Synchronous.
The contract information is 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.
Service and contract identifiers are environment-specific.
Do not mix UAT and PROD service references or contract references.
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 service
Header Parameters
Section titled “Header Parameters”Customer database ID
Responses
Section titled “Responses”Contract information for the service was retrieved successfully
object
Contract order number, if available
Contract document number, if available
Contract order position
Contract start date in date-time format, if available
Contract end date in date-time format, if available
Term of contract
Term of notice
Unit of notice
Example
{ "orderNumber": "ORD-2026-0001", "documentNumber": "DOC-2026-0001", "orderPosition": "1", "start": "2026-01-31T10:00:00Z", "end": "2027-01-31T10:00:00Z", "termOfContract": 12, "termOfNotice": 3, "unitOfNotice": "months"}Invalid subscription key or missing / invalid access token
Recommended handling: Check flinkey-API-Key, bearer token and environment configuration
API Manager, customer context or service was not found
Recommended handling: Check credentials, Customer-ID and local serviceId reference
Server-side error
Recommended handling: Retry later if appropriate and escalate if persistent
