The Service Information endpoint allows workshop personnel and dealers to quickly retrieve service and maintenance details for leased bikes. Instead of manually checking different leasing provider portals, this endpoint provides a unified way to access service package information, inspection status, and insurance coverage details.
Note: This endpoint is particularly useful for bicycle workshops that need to verify service coverage and available budgets before performing maintenance work. It eliminates the need to log into multiple leasing provider portals and streamlines the service verification process.
POST /v1/service-information/{leasingproviderslug}
leasingproviderslug
(string, required, path)
The unique identifier of the leasing provider (e.g., jobrad
, deutsche-dienstrad
)
x-api-key
(string, required, header)
Your API key for authentication. For more information on API keys, see Authentication
The endpoint accepts three different types of queries to find service information. You must use exactly one of these query types in your request:
{ "query": { "type": "email", "value": "user@example.com" } }
{ "query": { "type": "frameNumber", "value": "ABC123" } }
{ "query": { "type": "customer", "firstName": "John", "lastName": "Doe", "postalCode": "12345" } }
200
)Returns a JSON object containing the customer's service information and leasing details.
Example Response
{ "customer": { "firstName": "John", "lastName": "Doe", "email": "john.doe@example.com" }, "leasingDetails": [{ "bike": { "bikeType": "pedelec", "category": "city-bike", "brand": "cube", "model": "Town Sport Hybrid", "size": "50 cm", "color": "black", "year": "2024", "frameNumber": "ABC123XYZ" }, "leasing": { "startDate": "2024-01-01T00:00:00.000Z", "endDate": "2026-01-01T00:00:00.000Z" }, "servicePackage": { "type": "fullService", "budget": { "current": 500.0, "maximum": 500.0, "currency": "EUR" }, "inspections": { "available": 3, "lastDate": "2024-02-01T00:00:00.000Z", "isMandatory": false, "isValid": true, "isActive": true }, "hasExtendedCoverage": true }, "insurance": { "mobilityGuarantee": true, "fullCoverage": true, "wearCoverage": true } }] }
Response Fields
customer
: Basic information about the leasing customerfirstName
: Customer's first namelastName
: Customer's last nameemail
: Customer's email addressleasingDetails
: Array of leased bikes and their service information
bike
: Bike specifications
bikeType
: Type of bike (bike
, pedelec
, s-pedelec
)
category
: Bike category (e.g., city-bike
, mountain-bike
)
brand
: Manufacturer
model
: Model name
size
: Frame size
color
: Bike color
year
: Model year
frameNumber
: Unique frame number
leasing
: Leasing contract information
startDate
: Start date of the leasing contract
endDate
: End date of the leasing contract
servicePackage
: Service coverage details
type
: Service package type (none
, inspection
, fullService
)
budget
: Service budget information
current
: Currently available budget
maximum
: Maximum budget
currency
: Currency code
inspections
: Inspection details
available
: Number of remaining inspections
lastDate
: Date of the last inspection
isMandatory
: Whether inspections are mandatory
isValid
: Current validity status
isActive
: Whether the service package is active
hasExtendedCoverage
: Extended service coverage status
insurance
: Insurance coverage details
mobilityGuarantee
: Mobility guarantee coverage status
fullCoverage
: Full insurance coverage status
wearCoverage
: Wear and tear coverage status
400 Bad Request
– Invalid query format or missing required fields{ "error": "Invalid query format", "details": [{ "code": "invalid_type", "expected": "string", "received": "undefined", "path": ["value"], "message": "Required" }] }
401 Unauthorized
– Missing or invalid API key{ "error": "Unauthorized" }
403 Forbidden
– Insufficient permissions{ "error": "Forbidden" }
404 Not Found
– No service information found for the query{ "error": "No Service information for user found" }
500 Internal Server Error
– Server error or missing provider credentials{ "error": "Internal server error", "details": [{ "code": "INTERNAL_ERROR", "field": "unknown", "message": "An unexpected error occurred" }] }
Here are example curl
commands for each query type:
curl --location 'https://api.leasingautomation.de/v1/service-information/jobrad' \ --header 'x-api-key: YOUR_API_KEY' \ --header 'Content-Type: application/json' \ --data '{ "query": { "type": "email", "value": "user@example.com" } }'
curl --location 'https://api.leasingautomation.de/v1/service-information/jobrad' \ --header 'x-api-key: YOUR_API_KEY' \ --header 'Content-Type: application/json' \ --data '{ "query": { "type": "frameNumber", "value": "ABC123" } }'
curl --location 'https://api.leasingautomation.de/v1/service-information/jobrad' \ --header 'x-api-key: YOUR_API_KEY' \ --header 'Content-Type: application/json' \ --data '{ "query": { "type": "customer", "firstName": "John", "lastName": "Doe", "postalCode": "12345" } }'
You can also explore and test each endpoint in our OpenAPI/Swagger interactive API console, which provides a hands-on way to examine request/response details in real time.