Introduction
This guide describes the Travel Insurance APIs available on Yasmina’s platform. These APIs cover the core operations required for issuing and managing travel insurance policies, including quoting, issuing policies, generating payment links, and handling claims. Our APIs follow RESTful standards and are designed with consistent request and response structures, making them easy to integrate, test, and maintain within your systems.What you will learn
- Creating travel insurance quotes
- Handling payments
- Issuing and showing the policy
Prerequisites
- Account in Yasmina – See the Onboarding section for details.
- Authenticated Token - You can follow the Authentication guide or head straight to the Generate Token API.
- Backend server - Required to securely call Yasmina APIs.
Travel Insurance Overview
Travel insurance is designed to cover individuals or groups during international trips. Yasmina currently supports Schengen-compliant travel insurance, with configurable trip duration and multi-traveller support. A typical travel insurance flow includes:- Collecting trip and traveller information
- Requesting a quote
- Issuing the policy
- Completing payment
- Downloading policy documents
Request Quote
In this step, your customer provides information about the trip and you present them with the price of the insurance. In order to request a quote, you need to execute the following Request Quote API.Endpoint
POST /api/v1/travel/quotes
Example request
quote_id field. The value is needed later in the Purchase Policy API.
Example response
Purchase the Travel Policy
Before your customers can get the Travel Insurance Policy, they will need to complete the payment. The Purchase Policy API is used to get a policy object with a payment link. You will need to provide thequote_id obtained from the previous step.
Afterwards you get a response that has a policy object, and in that response there is a payment_link.
Redirect the customer to this link to complete the payment process.
Endpoint
POST /api/v1/yasmina-schengen-travel
Example request
Example response
Redirect URL
In addition to supplying thequote_id you can also add redirect_url. This is used to redirect the customer to any page or deep link you need after the payment is completed. You can also include a query string with policyID and it will automatically replace it with the actual id of the policy object.
Example for policy id 123
Showing & Downloading the policy
In order to get a status of a policy, you can use the Show Policy API. This API, takes a Yasmina Policyid and will return the policy object
The response includes both policy_url and invoice_url, these URLs contain pdf files that your customer can download.
