We use cookies 🍪 to keep things running smoothly (like logging in). If you’re cool with it, we’d love to use analytics and marketing cookies too. They help us make your experience even better and measure our ads. Totally fine if you’d rather not!

Partner integration

Direct link: prefilled applications by API

Create a prefilled insurance application with one POST request and send your customers straight to sign-up. A single API call is all it takes.

Live demo

Set the parameters and see what the API call for them looks like.

Basics
Bike
€
Customer

The two-letter country code, such as AT.

cURL command for these settings

curl -X POST https://karlbikes.com/api/v1/proposals/prepare \
  -H "Content-Type: application/json" \
  -d '{
  "token": "YOUR_PARTNER_TOKEN",
  "locale": "en-SK"
}'

API response (example)

{
  "success": true,
  "proposalId": "prop-a1b2c3d4",
  "link": "https://karlbikes.com/en-SK/proposals/prop-a1b2c3d4"
}

How it works

  1. 1.Create the application

    Your system sends a POST request with your partner token and the details it already knows.

  2. 2.Pass on the link

    The response holds the link to the prefilled application. Redirect your customer there or send them the link.

  3. 3.The customer signs up

    Your customer checks the details, adds what is missing and signs up. The sale is credited to you.

The request

One POST request to our API. The response holds the finished link for your customer.

cURL

The smallest request: only the partner token is needed.

curl -X POST https://karlbikes.com/api/v1/proposals/prepare \
  -H "Content-Type: application/json" \
  -d '{"token": "YOUR_PARTNER_TOKEN"}'

JavaScript (fetch)

The full request with bike and customer details.

const response = await fetch(
  "https://karlbikes.com/api/v1/proposals/prepare",
  {
    method: "POST",
    headers: { "Content-Type": "application/json" },
    body: JSON.stringify({
      token: "YOUR_PARTNER_TOKEN",
      locale: "de-AT",
      bike_desc: "Canyon Spectral 125 CF",
      bike_value: 3499,
      firstname: "Max",
      lastname: "Mustermann",
      email: "max@example.com",
    }),
  }
)
const { link } = await response.json()
// Redirect the customer to link

API parameters

Every field in the request’s JSON body.

API parameters
ParameterRequiredDefaultDescription
tokenYesnonePartner token that attributes the leads to you (e.g. “pdemo”).
localeNode-ATLanguage of the offer. Supported: de-AT, de-DE, de-IT, en-AT, en-DE, en-IT, it-AT, it-DE, it-IT, fr-AT, fr-DE, fr-IT, es-AT, es-DE, es-IT. Short codes (de, en, it, fr, es) are accepted as aliases for the matching *-AT.
bike_descNononeDescription of the bike (e.g. brand and model).
bike_valueNononeBike value in EUR (0–100,000).
bike_frameNononeFrame number of the bike.
firstnameNononeFirst name of the policyholder.
lastnameNononeLast name of the policyholder.
emailNononeEmail address of the policyholder.
phoneNononePhone number.
addressNononeStreet and house number.
address2NononeAddress line 2 (e.g. floor, door number).
zipNononePostcode.
cityNononeCity.
countryNononeEEA country code as ISO 3166-1 alpha-2 (e.g. AT, DE, IT). All 30 EEA states are accepted.

Check an offer’s status

Ask for an offer’s current state at any time, say to show or hide an insurance section in your customer portal. You need no token: the offer ID from the response is enough.

Request

A GET request with the offer ID, nothing more.

curl https://karlbikes.com/api/v1/proposals/PROPOSAL_ID/status

JavaScript (fetch)

Check the status and match your own interface to it.

const response = await fetch(
  `https://karlbikes.com/api/v1/proposals/${proposalId}/status`,
)
const { status } = await response.json()

// Show the insurance section only once the policy is active
const showInsuranceSection = status === "BOUND"

API response (example)

{
  "proposalId": "550e8400-e29b-41d4-a716-446655440000",
  "status": "BOUND"
}

Possible status values

Possible status values
StatusMeaning
PENDINGOffer created — the customer has not filled in the application yet.
DRAFTEDDraft contract created — the customer has given the details needed.
ACCEPTEDThe customer has signed the contract.
REJECTEDThe offer was declined.
BOUNDPolicy issued — the insurance is active.

If the offer ID is unknown, the API answers with HTTP 404.

What you get

  • Prefilled applications

    Bike and customer details are already filled in, so your customers type less.

  • Sales credited to you

    Every sale made through your direct link is credited to your partner account automatically.

  • From any system

    Works from any backend: with cURL, with fetch or server-side in any language.

More ways

Karl fits into your sales in other ways too. Your token and ready-made code are waiting in the partner portal.

  • Premium calculator on your website

    Two lines of code, and your customers see their premium right on your site.

    Read the calculator guide
  • Karl app for Shopify

    Insurance on the product page and after checkout in your store.

    Read the Shopify guide
  • Your token, your code

    In the partner portal you find your partner token and the calculator code with your token already in it.

    Go to Integrations

No partner access yet?

Write to us and we will set up your access within one working day.