GET
/
organizations
/
{organization_id}
/
worksites
/
{worksite_id}
/
insurance-details
Get Worksite Insurance Details
curl --request GET \
  --url https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://dev.intermezzo.ai/organizations/{organization_id}/worksites/{worksite_id}/insurance-details")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "id": 123,
  "valid_from": "2023-12-25",
  "valid_to": "2023-12-25",
  "insurance_country": "DE",
  "worksite_location_number": "98797889",
  "accident_insurance_company_number": "98797889",
  "accident_insurance_pin": "DE-WS-PIN-456",
  "payroll_service_provider_number": "98797889",
  "payroll_processing_location_number": "98797889"
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}

Authorizations

Authorization
string
header
required

Get token from Auth0 and paste it here

Path Parameters

worksite_id
required
organization_id
required

Response

DEWorksiteInsuranceDetailsResponse · object | null

Successful Response

id
integer
required
valid_from
string<date> | null
valid_to
string<date> | null
insurance_country
string
default:DE
Allowed value: "DE"
worksite_location_number
string | null

German Betriebsnummer (8 digits: xxx-yyyy-z format)

Pattern: ^\d{8}$
Example:

"98797889"

accident_insurance_company_number
string | null

German Betriebsnummer (8 digits: xxx-yyyy-z format)

Pattern: ^\d{8}$
Example:

"98797889"

accident_insurance_pin
string | null

German accident insurance PIN (5 digits)

Pattern: ^\d{5}$
Example:

"DE-WS-PIN-456"

payroll_service_provider_number
string | null

German Betriebsnummer (8 digits: xxx-yyyy-z format)

Pattern: ^\d{8}$
Example:

"98797889"

payroll_processing_location_number
string | null

German Betriebsnummer (8 digits: xxx-yyyy-z format)

Pattern: ^\d{8}$
Example:

"98797889"