Instalments Workflow
Last updated
Last updated
This feature allows customers to pay for an insurance product that covers them for a period of time (annually) in instalments instead of up-front.
The above diagram illustrates the API calls and webhook events made in order to record the payment of each instalment.
When a quote request is made for a policy that allows payment to be made in instalments an instalment_plans
property will be returned in the API response.
The amount to surface to the customer is reflected in the first_instalment_amount
attribute.
The instalment plan can be selected by provide the desired instalment name in the instalment_plan
attribute during a booking request.
Depending on the payment services provider a periodic payment will generate a webhook event. This event should be processed by your platform and the following API calls should be made to the instalments endpoint.
In order to record an instalment the correct instalment_id
needs to be provided. The next scheduled instalment_id
can be obtained by performing a GET request against the instalment endpoint.
GET
https://api.xcover.com/x/partners/:partner_id/bookings/:quote_package_id/instalments/
Returns instalment details including the payment schedule.
To confirm the instalment once a payment attempt has been made a request to the following endpoint needs to be made containing the instalment_id
from the previous step.
POST
https://api.xcover.com/x/partners/:partner_id/bookings/:quote_package_id/instalments/
Confirms the instalment providing whether the payment was successful or not.
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
partner_id
string
Unique Partner ID
quote_package_id
string
Quote Package ID (INS)
Content-Type
string
application/json
Date
string
Current Datetime
Authorization
string
HMAC Signature
X-API-Key
string
API Key
partner_id
string
Unique Partner ID
quote_package_id
string
Quote Package ID (INS)
Content-Type
string
application/json
Date
string
Current Datetime
Authorization
string
HMAC Signature
X-API-Key
string
API Key