Travel Insurance API Documentation

Table of Contents


Authenticate

Authenticates a user and generates an access token. The endpoint uses JSON Web Tokens (JWT) for generating tokens and managing user sessions.

Method

POST

URL

https://isatravelonline.com/api/v2/Authenticate

Request

Body Parameters

Name Type Required Description
Username string Yes User's username
Password string Yes User's password
Request Body Example
{ "Username": "green", "Password": "blue" }

Success Response

{ "accessToken": "your_access_token_here" }

Lookups

This section provides documentation for Lookups.

Genders

This will allow you to return the list of Genders available in the system along with there ID and description

Method

GET

URL

https://isatravelonline.com/api/v2/Lookup/Genders

Headers

For making requests to the API endpoints, ensure to include the following headers:

Success Response

[ { "Id": 1, "Description": "Male" }, { "Id": 2, "Description" : "Female" } ]

Marital Status

This will allow you to return the list of Marital Statuses available in the system along with there ID and description.

Method

GET

URL

https://isatravelonline.com/api/v2/Lookup/GetMaritalStatus

Headers

For making requests to the API endpoints, ensure to include the following headers:

Success Response

[ { "Id": 1, "Description": "Single" }, { "Id": 2, "Description" : "Married" } ]

Countries

This will allow you to return the list of Countries available in the system along with there ID and description.

Method

GET

URL

https://isatravelonline.com/api/v2/Lookup/GetCountries

Headers

For making requests to the API endpoints, ensure to include the following headers:

Success Response

[ { "id": 203, "description": "Aruba" }, { "id": 9, "description": "Australia" }, { "id": 10, "description": "Austria" } ]

Relation Types

This is used to identify the relationship type between 1 Insured or another, this type could be principle, spouce, or child.

Method

GET

URL

https://isatravelonline.com/api/v2/Lookup/GetRelationTypes

Headers

For making requests to the API endpoints, ensure to include the following headers:

Success Response

[ { "Id": 1, "Description": "Spouse" }, { "Id": 2, "Description" : "Child" } ]

Travel Insurance

This section provides documentation for Insurance Api's including issuing info, quotation and policy issuance.

Issue Info

Return related issuing info for user to proceed with issuing policy. It contains the following :

Method

GET

URL

https://isatravelonline.com/api/v2/TravelInsurance/issue-info

Headers

For making requests to the API endpoints, ensure to include the following headers:

Success Response

Insurance Offers

Get insurance offers based on the provided request.

It contains the following :

Method

POST

URL

https://isatravelonline.com/api/v2/TravelInsurance/offers

Headers

For making requests to the API endpoints, ensure to include the following headers:

Request

Parameter Type Required Description
FromDate DateTime Yes Start date for insurance coverage.
ToDate DateTime Yes End date for insurance coverage.
Destination string Yes The destination for the insurance coverage (comma-separated for multiple destinations).
Insureds List Yes List of insured object consists of date of birth and optional covers for each insured(comma-separated for Individual/Group policies, if applicable).
IsFamily boolean No Indicates if the policy is for a family and not a group.
AdditionalFees decimal No Additional fees for the insurance.
PolicyOptionalCovers string No Optional covers for the policy (comma-separated for Family policies, if applicable).

Example Usage

curl -X POST '/api/v2/offers' \ -H 'Content-Type: application/json' \ -d '{ "FromDate": "2023-12-01", "ToDate": "2024-01-01", "Destination": "92", "Insureds": [ { "dateOfBirth": "1996-08-01", "optionalCovers": "2" }, { "dateOfBirth": "1997-07-29", "optionalCovers": "1,2" } ], "IsFamily": false, "AdditionalFees": 10.50, "PolicyOptionalCovers": "" }'

Success Response

Quotation

Validate Travel Insurance Policy based on the provided request before proceeding to payment and this endpoint is optional.

Method

POST

URL

https://isatravelonline.com/api/v2/TravelInsurance/quotation

Headers

For making requests to the API endpoints, ensure to include the following headers:

Request

Parameter Type Required Description
CoverageAreaId int Yes Id taken from selected package per product from Insurance Offer Endpoint
Insureds Array of insureds Yes List of insureds
Insureds[0].Address.CountryID int Yes Taken from Countries Lookup
Insureds[0].Address.RegionID int No Not used, pass 0
Insureds[0].Address.CityID int No Not used, pass 0
Insureds[0].DateofBirth DateTime Yes Insured Date of Birth
Insureds[0].Firstname String Yes Insured First Name
Insureds[0].GenderID int Yes Taken from Genders Lookup
Insureds[0].Lastname String Yes Insured Last Name
Insureds[0].MaidenName String No Insured Maiden Name
Insureds[0].MiddleName String No Insured Middle Name
Insureds[0].MaritalStatus int No Taken from Marital Status Lookup
Insureds[0].PassportNumber String No Insured Passport Number
Insureds[0].Relation String Yes Taken from Relation Types lookup
Insureds[0].Contact.Email String No Insured Email
Insureds[0].Contact.MobileNumber String Yes Insured Mobile Number
Insureds[0].Contact.PhoneNumber String No Insured Phone Number
Insureds[0].OptionalCovers String No Optional Covers Comma separated
Insureds[0].NationalityId int Yes Taken from Countries Lookup
MarkupValue decimal No Amount added on the price when issuing policy
ProductID string Yes ProductId taken from Insurance Offer Endpoint
DestinationId string Yes Taken from Countries Lookup, use comma for multiple destination
InceptionDate DateTime Yes Date of Policy Inception
ExpiryDate DateTime Yes Date of Policy Expiry
PolicyReferenceId String No Client PolicyId
Policy Optional Covers Array of integers No Optional covers on the level of policy

Example Usage

curl -X POST 'https://isatravelonline.com/api/v2/TravelInsurance/quotation' \ -H 'Content-Type: application/json' \ -d '{ { "coverageAreaId": 520, "insureds": [ { "firstName": "Hadi", "lastName": "Nasrallah", "address": { "countryId": 96, "regionId": 0, "cityId": 0 }, "dateOfBirth": "1996-08-01", "genderId": 1, "middleName": "", "maritalStatus": 0, "passportNumber": "LR098761", "relation": "principal", "contact": { "email": "hadi.nasrallah@test.com", "mobileNumber": "+96170000000", "phoneNumber": "" }, "optionalCovers": "1", "nationalityId": 0 } ], "markupValue": 0, "productId": "216 - 514", "destinationId": "92,2", "inceptionDate": "2023-12-07", "expiryDate": "2023-12-25", "policyReferenceId": "", "optionalCovers": [ ] } }'

Success Response

{ "totalTaxes": 1.15, "policyId": "0", "policyNumber": 0, "beneficiariesPremium": [ { "id": 0, "passportNo": "LR098761", "firstName": "Hadi", "lastName": "Nasrallah", "covers": [ { "premium": 20.00, "id": 861, "description": "TCH-Covid-19 - Cash-Silver: Worldwide excluding USA, Canada, Australia, & Japan" } ], "premium": 23.00, "coversPremium": [ { "premium": 3.00, "id": 1, "description": "No Deductible" } ] } ], "currency": { "isoName": "$", "id": 1, "description": "USD" }, "coversPremium": [], "premium": 23.00, "additionalPremium": 0.00, "totalPremium": 24.15, "totalUSD": 24.15, "issuingFees": 0.00, "additionalFees": 0.00, "resultStatus": true, "errorMessage": "", "certificateUrl": "" }

Issue Policy

Issue Travel Insurance Policy based on the provided request.

Method

POST

URL

https://isatravelonline.com/api/v2/TravelInsurance/issue

Headers

For making requests to the API endpoints, ensure to include the following headers:

Request

Parameter Type Required Description
CoverageAreaId int Yes Id taken from selected package per product from Insurance Offer Endpoint
Insureds Array of insureds Yes List of insureds
Insureds[0].Address.CountryID int Yes Taken from Countries Lookup
Insureds[0].Address.RegionID int No Not used, pass 0
Insureds[0].Address.CityID int No Not used, pass 0
Insureds[0].DateofBirth DateTime Yes Insured Date of Birth
Insureds[0].Firstname String Yes Insured First Name
Insureds[0].GenderID int Yes Taken from Genders Lookup
Insureds[0].Lastname String Yes Insured Last Name
Insureds[0].MaidenName String No Insured Maiden Name
Insureds[0].MiddleName String No Insured Middle Name
Insureds[0].MaritalStatus int No Taken from Marital Status Lookup
Insureds[0].PassportNumber String No Insured Passport Number
Insureds[0].Relation String Yes Taken from Relation Types lookup
Insureds[0].Contact.Email String No Insured Email
Insureds[0].Contact.MobileNumber String Yes Insured Mobile Number
Insureds[0].Contact.PhoneNumber String No Insured Phone Number
Insureds[0].OptionalCovers String No Optional Covers Comma separated
Insureds[0].NationalityId int Yes Taken from Countries Lookup
MarkupValue decimal No Amount added on the price when issuing policy
ProductID string Yes ProductId taken from Insurance Offer Endpoint
DestinationId string Yes Taken from Countries Lookup, use comma for multiple destination
InceptionDate DateTime Yes Date of Policy Inception
ExpiryDate DateTime Yes Date of Policy Expiry
PolicyReferenceId String No Client PolicyId
Policy Optional Covers Array of integers No Optional covers on the level of policy

Example Usage

curl -X POST 'https://isatravelonline.com/api/v2/TravelInsurance/issue' \ -H 'Content-Type: application/json' \ -d '{ { "coverageAreaId": 520, "insureds": [ { "firstName": "Hadi", "lastName": "Nasrallah", "address": { "countryId": 96, "regionId": 0, "cityId": 0 }, "dateOfBirth": "1996-08-01", "genderId": 1, "middleName": "", "maritalStatus": 0, "passportNumber": "LR098761", "relation": "principal", "contact": { "email": "hadi.nasrallah@test.com", "mobileNumber": "+96170000000", "phoneNumber": "" }, "optionalCovers": "1", "nationalityId": 0 } ], "markupValue": 0, "productId": "216 - 514", "destinationId": "92,2", "inceptionDate": "2023-12-07", "expiryDate": "2023-12-25", "policyReferenceId": "", "optionalCovers": [ ] } }'

Success Response

{ "totalTaxes": 1.15, "policyId": "2512755", "policyNumber": 2512755, "beneficiariesPremium": [ { "id": 0, "passportNo": "LR098761", "firstName": "Hadi", "lastName": "Nasrallah", "covers": [ { "premium": 20.00, "id": 861, "description": "TCH-Covid-19 - Cash-Silver: Worldwide excluding USA, Canada, Australia, & Japan" } ], "premium": 23.00, "coversPremium": [ { "premium": 3.00, "id": 1, "description": "No Deductible" } ] } ], "currency": { "isoName": "$", "id": 1, "description": "USD" }, "coversPremium": [], "premium": 23.00, "additionalPremium": 0.00, "totalPremium": 24.15, "totalUSD": 24.15, "issuingFees": 0.00, "additionalFees": 0.00, "resultStatus": true, "errorMessage": "", "certificateUrl": "https://www.isatravelonline.com/api/v1/PrintPolicy/Print?PolicyCode=2512755&ProdCode=0&beneficiaryCode=1&ShowTotal=1" }