This page describes basic steps for browsing available products, select one and create a quote, update the quote, specify sales discounts and commissions, and accept and purchase the quote.
Authenticate and retrieve an access token
Every request to Seamless needs to be authenticated. Please refer to the Authentication for more details of how to authenticate and get an access token.
Get available products for sales
To get product versions available for sales, please send an HTTP request to the Agency Configuration API as in the example below.
### Get active product versions GET {{base-url-configuration}}/api/v1/salesProducts/activeVersions?page[size]=100&page[number]=1 Authorization: {{access-token}} Accept: application/vnd.api+json
Sample response
HTTP/2 200 OK { "data": [ { "type": "salesProductVersions", "id": "4c2fbd66-301f-4885-96cb-d60be50b113c", "attributes": { "productVersionId": "productversion-0ea0d37a-9efd-08db-0bd7-c0600705dec3", "productId": "product-f3d34719-1987-08db-e9ed-98992bb3c0cf", "productName": "Travel", "salesChannelId": "saleschannel-d032531b-4664-08db-861e-ae779787d6cc", "salesChannelName": "Channel 1", "salesChannelReference": "Ref-1", "productIconId": "2cddad98-7e2c-4d58-b91b-42c1752663d4", "iconBackgroundColor": "#fff", "paymentOptions": null } }, ... ] }
Create a new-business quote
Send a request with request payload attributes as below to the Quotation Service.
policyHolderId
is the customer Id.salesChannel
,salesChannelName
,productVersionId
,productName
, andproductId
are data from the response of step Get available production versions for sales.organisationContext
is the authenticated user's organization context.
### Create a new-business quote POST {{base-url-sales}}/api/v1/quotes/createQuoteRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "createQuoteRequests", "attributes": { "salesChannel": "saleschannel-d032531b-4664-08db-861e-ae779787d6cc", "salesChannelName": "Channel 1", "salesChannelReference": "Ref-1", "productVersionId": "productversion-0ea0d37a-9efd-08db-0bd7-c0600705dec3", "productName": "Travel", "productId": "product-f3d34719-1987-08db-e9ed-98992bb3c0cf", "organisationContext": "contemi-developers", "policyHolderId": "caa40751-80cd-4b18-9f0a-55b9af4be886" } } }
Sample response
HTTP/2 201 Created { "data": { "type": "quotes", "id": "quote-d697f696-1f3e-08dd-cc76-1eabd4dc87c4", "attributes": { "reference": "1106475", "description": "", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, ... } } }
Update quote answers
To update the quote answers, send a request with the payload as below to the Quotation Service.
quoteId
is the quote Id taken from the previous step.policyHolderId
andpolicyHolderData
are customer data.The answer tags and values in
changedAnswers
are varied and defined by the product version associated with the quote.
### Update quote answers POST {{base-url-sales}}/api/v1/quotes/updateQuoteRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "updateQuoteRequests", "attributes": { "quoteId": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "policyHolderId": "caa40751-80cd-4b18-9f0a-55b9af4be886", "policyHolderData": { "id": "caa40751-80cd-4b18-9f0a-55b9af4be886", "nin": "01019012345", "reference": "1000", "name": "Peter Customer", "dateOfBirth": "1990-01-01", "addrLine1": "123 Some St.", "addrPostCode": "0048", "city": "Oslo", "phoneNumber": "0987654321", "email": "peter.nguyen@contemi.com", "organizationContext": "contemi-developers", "addresses": { "addresses": [ { "id": "4cbae8df-8fb4-4e06-8259-6c8ec244d463", "address": "123 Some St.", "extraAddress": null, "city": "Oslo", "province": null, "postCode": "0048", "type": "visiting_address", "country": null } ] }, "customFields": { "preferredLanguage": null, "type": "pl" } }, "changedAnswers": { "InsuredPersonNameTag": "Sample Customer Name", "InsuredPersonDOBTag": "1990-12-15T00:00:00.000Z", "NoOfTravellers": "1", "AdditionalCoverTag": true, "LuggageExcessTag": "250" }, "quotedPeriodChange": { "start": "2024-12-19T00:00:00.000Z", "end": "2025-12-18T00:00:00.000Z" } } } }
Sample reqponse
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "reference": "1106467", "description": "Sample Customer Name", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, ... } } }
Calculate quote price
To calculate a quote price, send a request to the Quotation Service.
### Calculate quote price POST {{base-url-sales}}/api/v1/quotes/calculatePriceRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "calculatePriceRequests", "attributes": { "quoteId": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "salesDiscount": 0, "productCommission": 0, "salesCommission": 0, "underwritingAdjustmentReason": "", "underwritingAdjustment": 0 } } }
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "reference": "1106467", "description": "Sample Customer Name", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, ... } } }
Sales discount, product commission, sales commission, and underwriting adjustment can be specified in the request payload.
Poll quote price
Since quote price is calculated asynchronously, clients may need to poll for the quote price calculation complete.
To poll quote price, send a request like the example below, replace the :id
path variable with the quote Id. The request can be repeated until reaching the max polling time or receiving a response with hasBeenCalculated
attribute as true
.
### Poll quote price GET {{base-url-sales}}/api/v1/quotes/:id?fields[quotes]=premium Authorization: {{access-token}} Accept: application/vnd.api+json
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "premium": { "isBeingCalculated": false, "hasBeenCalculated": true, "isConstrained": false, "canBeAccessed": true } } } }
Specify a payment option
A payment option may need to be specified for the quote, depending on the agency configuration. To specify the payment option, send a request like below.
### Specify payment option POST {{base-url-sales}}/api/v1/quotes/updateQuoteRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "updateQuoteRequests", "attributes": { "quoteId": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "paymentOptionName": "Cash Monthly", "paymentOptionValue": "cash_monthly", "paymentMethod": "External", "paymentFrequency": "Monthly" } } }
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "reference": "1106467", "description": "Sample Customer Name", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, ... } } }
Complete quote
Send a request with a quoteId
specified in the request payload. Take note of the version
and the policyHolderId
in the response payload.
### Complete quote POST {{base-url-sales}}/api/v1/quotes/completeQuoteRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "completeQuoteRequests", "attributes": { "quoteId": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca" } } }
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "reference": "1106467", "description": "Sample Customer Name", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, "version": 28, "policyHolderId": "caa40751-80cd-4b18-9f0a-55b9af4be886", ... } } }
Accept quote
Send a request with following information.
quoteId
: Id of the quote to accept.acceptedVersion
: The quote version noted down in the previous step.policyHolderId
: Id of the policy holder noted down in the previous step.paymentMethod
: Can be one ofInvoice
,IntegratedCheckout
, orExternal
.paymentFrequency
: Choose one of these available optionsAnnually
,Semi-Annually
,Quarterly
,Monthly
,Single
orOne-Off
.
### Accept quote POST {{base-url-sales}}/api/v1/quotes/acceptanceRequest Authorization: {{access-token}} Accept: application/vnd.api+json Content-Type: application/vnd.api+json { "data": { "type": "acceptanceRequests", "attributes": { "quoteId": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "acceptedVersion": 28, "policyHolderId": "caa40751-80cd-4b18-9f0a-55b9af4be886", "preferredCollectionDay": 1 } } }
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "reference": "1106467", "description": "Sample Customer Name", "period": { "start": "2024-12-19T00:00:00+00:00", "end": "2025-12-18T23:59:59+00:00" }, ... } } }
Poll issued policy Id
Since the policy is issued asynchronously, the client should poll for the policy issuance result by sending the following request. Please replace the :id
path variable with the actual quote Id.
### Poll policy issuance GET {{base-url-sales}}/api/v1/quotes/:id?fields[quotes]=status,underwrittenByPolicyId,acceptanceFailureReason Authorization: {{access-token}} Accept: application/vnd.api+json
Sample response
HTTP/2 200 OK { "data": { "type": "quotes", "id": "quote-4fbe88f2-1f3e-08dd-46e2-d1f2631efeca", "attributes": { "status": "Underwritten", "underwrittenByPolicyId": "policy-6f21f713-f977-5ded-a1d0-15d82ee48931", "acceptanceFailureReason": null } } }
Please take note of the underwrittenByPolicyId
if you need to retrieve the policy details.