hepster API Implementation Guide
Sales API Electronic 1.0 - Seamlessly integrate insurance contract bookings into your system with our embedded insurance API.
Introduction
The hepster Embedded Insurance API allows seamless integration of insurance contract bookings into your system. This guide provides all the necessary steps and resources to integrate and test the API effectively.
Getting Started
- You will receive your credentials (BasicAuth) and the URL for the test environment by your hepster contact person
- Please provide us with your static IP addresses or IP ranges to be added to our whitelist
- Your IP address will be whitelisted on our preprod environment, so you can start testing
- After successful integration and joint testing, access to the production environment will be provided
Technical Requirements
- API Type: REST
- Authentication: BasicAuth
- Data Format: JSON
Overview
Policy Booking
/services/integrator/partner/v1/order
Creates a new insurance policy
Key Request Elements
- Customer details (e.g., name, email, address)
- Selected tariff and pricing
- Insured object or person details
Key Response Elements
- Contract details (e.g., certificate number, start date)
- Error messages in case of issues
- Status Codes
Additional Endpoints
- Contract Cancellation: Suspend specific contracts
- Document Retrieval: Fetch policy documents for a contract
- Contract Overview: Retrieve all active contracts and details
Sample Request and Responses
Policy Booking
The following request will initiate the creation of an insurance contract at hepster.
Staging:
https://staging.hepster-services.com/services/integrator/partner/v1/order
Production:
https://api.platform.hepster-services.com/services/integrator/partner/v1/order
Request
POST
{
"policyHolder": {
"insuredLegalEntity": "",
"VATId": "",
"taxId": "",
"insuranceUserFirstName": "Muster",
"insuranceUserLastName": "Mustername",
"country": "DE",
"email": "placeholder@mail.de"
},
"Contract": {
"externalOrderReference": "TBD",
"contractStart": "2025-12-22",
"contractEnd": null,
"legalwarrantyEnd": null,
"productCode": "HEP_Repair_599,99",
"duration": "3Y",
"costsharing": 10
},
"insuredObject": {
"serialNumber": "8C555625",
"objectType": "Notebook",
"itemsalesPrice": 555.0,
"manufacturer": "HP",
"model": "HP OmniBook 5 Flip 14",
"undamagedConfirmed": true
}
}
About the Data
-
policyHolder:
Subscription holder / insured person.
Contains personal or company data depending on customer type. - insuredLegalEntity: Company name (only if customer is a company)
- VATId: VAT ID (only if customer is a company)
- taxId: Tax ID (only if customer is a company)
- insuranceUserFirstName: First name (only if customer is a private person)
- insuranceUserLastName: Last name (only if customer is a private person)
- country: ISO 3166-1 alpha-2 country code
- email: Customer contact email
- Contract: Contract and product configuration.
- externalOrderReference: External / partner-internal order reference
- contractStart: Contract start date (00:00 o'clock)
- contractEnd: Contract end date (only for fixed-term contracts)
- legalwarrantyEnd: Legal warranty end (for warranty extension products)
- voluntarywarrantyEnd: Voluntary warranty end (for warranty extension products)
- productCode: Product identifier
- type:
recurring= subscription,fix= fixed-term or warranty extension - duration: Duration in months (recurring renewal or fixed term)
- costsharing: Deductible (customer share) in %
- insuredObject: Insured item details.
- serialNumber: Serial number of the insured item
- objectType: Item type (e.g. Phone, Notebook – extendable)
- itemsalesPrice: Sales price of the item
- manufacturer: Manufacturer of the insured item
- model: Model of the Item
- undamagedConfirmed: Confirms whether the item is undamaged
Sample Response
{
"status": {
"id": 200,
"text": "OK"
},
"message": "We received your n orders. You will receive a message once the booking process is done.",
"count": n
}
Sample Response to customer provided Webhook
{
"status": {
"id": 200,
"text": "OK"
},
"messages": [
{
"message": "OK",
"type": "info"
}
],
"order_reference": "123",
"contracts": [
{
"product": "Elektro-Abo-Versicherung",
"certificate_number": "I11305328852504453133107193811",
"contract_start_date": "2025-03-01",
"contract_premium": 5.56
}
]
}
Error Handling
Responses include status codes and descriptive messages.
Missing required fields, authentication failures, or whitelist restrictions
Error Response Example
{
"message": "Validation error - errors in booking payload.",
"detailMessage": "Errors in: Booking - contract_start_date is over 28 days ago.",
"code": 1001
}
Error Response to webhook
{
"status": {
"id": 1005
},
"messages": [
{
"message": "Product not found",
"type": "error"
}
]
}
Code Types
| Code | Reason |
|---|---|
| 1001 | Payload Validation Error |
| 1002 | Product Not Found |
| 1003 | Coverage Not Found |
| 1004 | Cancellation Reason Forbidden |
| 1009 | Certificate not found for certificatenumber |
| 1010 | Pib not found for certificatenumber |
| 1011 | Contract not found for certificatenumber |
| 1012 | Unknown filter <filtername> |
| 1013 | Invalid request parameter |
| 1099 | Unknown Server Error |
Document Retrieval
Fetch documents for a specific certificate number. You can retrieve all documents or filter by type (certificate, PIB/IPID). The documents are delivered as a ZIP file.
All Documents
https://staging.hepster-services.com/services/documents/<CertificateNumber>
Certificate and PIB (IPID)
https://staging.hepster-services.com/services/integrator/documents/<CertificateNumber>?filter=certificate;pib
Certificate Only
https://staging.hepster-services.com/services/integrator/documents/<CertificateNumber>?filter=certificate
PIB (IPID) Only
https://staging.hepster-services.com/services/integrator/documents/<CertificateNumber>?filter=pib
Contract Overview
Retrieve all active contracts and their details. Optional parameters allow filtering by date, page, and sorting.
Lookup Contracts
https://staging.hepster-services.com/services/integrator/contracts/lookup/organisation?size=2&page=1&sortBy=CREATED_DATE&sortDirection=DESC
Optional parameters:
- size: contracts per page (default: 10)
- page: page number (default: 0)
- sortBy: CREATED_DATE (default), START_DATE, END_DATE
- sortDirection: ASC, DESC (default)
Contact and Support
For technical assistance or customizations, reach out to: