Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
https://api.fusionbase.com/api/v2https://api.fusionbase.com/api/v2/stream/data/[Stream ID]Master the Fusionbase Data Hub Search API with our concise guide. Detailed instructions and examples ensure easy integration and powerful search use.
/api/v2/stream/data/{STREAM_ID}?query_parameters={"project_fields": ["manufacturer_brand"]}&format=json/api/v2/stream/data/{STREAM_ID}?skip=0&limit=10&sort_keys=fb_datetime&sort_order=desc/api/v2/stream/data/403398?skip=0&limit=10&sort_keys=fb_datetime&sort_order=descGET https://api.fusionbase.com/api/v2/stream/data/{STREAM_ID}?version_boundary={FB_DATA_VERSION}&format=json/api/v2/stream/data/{STREAM_ID}?version_boundary=bd764e07-50a1-4c0e-a102-ae1a259557av&format=json/api/v2/stream/data/{STREAM_ID}?version_boundary=version1ID,version2ID&format=jsonhttps://api.fusionbase.com/api/v2/search/entities/person?q=Kevin%20Goßling{
"results": [
{
"entity_type": "PERSON",
"entity": {
"fb_entity_id": "8e03af05947fdff52a182084b5ce0a24",
"entity_type": "PERSON",
"entity_subtype": "INDIVIDUAL",
"name": {
"given": "Kevin",
"family": "Goßling"
},
"locations": {
"home": {
"formatted_address": "Munich, Germany"
}
},
"relations": {
"ORGANIZATION": [
{
"label": "MANAGING_DIRECTOR",
"entity_to": {
"fb_entity_id": "ff525267e6ff5f67a6dbe0af29b7e5cc",
"display_name": "Fusionbase GmbH"
},
"meta": {
"start_date": "2019-10-24"
}
}
]
},
"source_id": "data_sources/1051122944"
},
"score": 19.639364
}
],
"total": 1
}
[
{
"fb_id":
/api/v2/stream/data/{STREAM_ID}?query_parameters={"sort_keys": ["fb_datetime", "price"], "sort_order": ["asc", "desc"]}&format=jsonhttps://api.fusionbase.com/api/v2/search/entities/location?q=Agnes-Pockels-Bogen%201,%2080992%20München{
"results": [
{
"entity": {
"fb_entity_id": "45d488830421ebc1d9130cc0856b3c5d",
"fb_datetime": "2023-12-18T16:17:53.570000",
"fb_entity_version": "9cefd42e59f49e3de4b0b33f983b740c",
"entity_type": "LOCATION",
"updated_at": "2023-12-18T16:17:53.570000",
"created_at": "2023-11-09T16:17:51.381000",
"external_ids": {
"nominatim": {
"osm_id": 1787145076,
"osm_type": "node",
"class": "amenity"
}
},
"coordinate": {
"latitude": 48.1735835,
"longitude": 11.5323446
},
"location_level": null,
"address_components": [
{
"component_type": "house_number",
"component_value": "1"
},
{
"component_type": "street",
"component_value": "Agnes-Pockels-Bogen"
},
{
"component_type": "postal_code",
"component_value": "80992"
},
{
"component_type": "city",
"component_value": "Munich"
},
{
"component_type": "state",
"component_value": "Bavaria"
},
{
"component_type": "country",
"component_value": "Germany"
}
],
"alternative_names": [],
"fb_semantic_id": "location|locality:germany:bavaria:80992:munich:agnes-pockels-bogen:1",
"formatted_address": "Agnes-Pockels-Bogen 1, 80992 Munich, Germany"
},
"entity_type": "LOCATION"
}
]
}https://api.fusionbase.com/api/v2/search/entities/organization?q=OroraTech%20GmbH{
"results": [
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "82a68ab9f7151fa0af9bf189c1caa753",
"status": "ACTIVE",
"display_address": "Sankt-Martin-Straße 112, 81669 Munich, Germany",
"registration_authority_entity_name": "München HRB 243843",
"display_name": "OroraTech GmbH",
"name": "OroraTech GmbH",
"source_key": "1051122944"
},
"score": 40.53212
},
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "64ab4b0ada714a56939c70f5e8a62e8a",
"status": "ACTIVE",
"display_address": "Birkenweg, 15834 Rangsdorf, Germany",
"registration_authority_entity_name": "Potsdam HRB 15953",
"display_name": "FloraTech GmbH",
"name": "FloraTech GmbH",
"source_key": "1051122944"
},
"score": 14.997058
}
],
"total": 10
}
filtersquery_parameters[
{
"fb_id":
limit[
{
"fb_id":
curl -X GET "https://api.fusionbase.com/api/v2/stream/base/430410" \
-H 'X-API-KEY: 'YOUR_API_KEY \
-H 'Content-Type: application/json; charset=utf-8' \
import requests
url = "https://api.fusionbase.com/api/v2/stream/base/430410"
headers = {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8',
}
response = requests.get(url, headers=headers)
print(response.json())
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;
public class Main {
public static void main(String[] args) throws Exception {
URL url = new URL("https://api.fusionbase.com/api/v2/stream/base/430410");
HttpURLConnection con = (HttpURLConnection) url.openConnection();
con.setRequestMethod("GET");
con.setRequestProperty("X-API-KEY", "YOUR_API_KEY");
con.setRequestProperty("Content-Type", "application/json; charset=utf-8");
BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer content = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
content.append(inputLine);
}
in.close();
con.disconnect();
System.out.println(content.toString());
}
}package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.fusionbase.com/api/v2/stream/base/430410"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "YOUR_API_KEY")
req.Header.Add("Content-Type", "application/json; charset=utf-8")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}const axios = require('axios');
axios.get('https://api.fusionbase.com/api/v2/stream/base/430410', {
headers: {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8'
}
})
.then((response) => {
console.log(response.data);
})
.catch((error) => {
console.error(error);
});<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.fusionbase.com/api/v2/stream/base/430410",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: YOUR_API_KEY",
"Content-Type: application/json; charset=utf-8"
],
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
?>/api/v2/stream/data/{STREAM_ID}?query_parameters={"filters": [{"property": "construction_year_end", "operator": "GREATER_THAN", "value": 2013}]}&format=jsonPOST https://api.fusionbase.com/api/v2/relation/resolve/<RELATION_ID>/<ENTITY_ID>[
{
"label": "ENTITY_NETWORK",
"entity_from": {
"fb_entity_id": "75e8887e25587ed64cc8e1733a6c7160",
"entity_type": "ORGANIZATION",
"display_name": "ADOS GmbH"
},
"entity": {
"entity_type": "FEATURE",
"entity_subtype": "NETWORK",
"fb_semantic_id": "feature|network|organization:75e8887e25587ed64cc8e1733a6c7160",
"value": {
"root": {
"fb_entity_id": "75e8887e25587ed64cc8e1733a6c7160",
"entity_type": "ORGANIZATION",
"display_name": "ADOS GmbH"
},
"links": [
{
"depth": 1,
"relation_id": "135ff9ab592bb1b41ab948b3ad95f91f",
"label": "MANAGING_DIRECTOR",
"entity_from": {
"fb_entity_id": "8a00ab6520e0b64eb83345586ba1613e",
"entity_type": "PERSON",
"display_name": "Herbert Rütgers"
},
"entity_to": {
"fb_entity_id": "75e8887e25587ed64cc8e1733a6c7160",
"entity_type": "ORGANIZATION",
"display_name": "ADOS GmbH"
},
"meta": {
"start_date": "2002-06-03",
"end_date": "2020-07-06"
}
}
// Additional links omitted for brevity
]
}
}
}
]

import requests
url = "https://api.fusionbase.com/api/v2/entities/location/get/FB_ENTITY_ID"
const axios = require('axios');
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) {
HttpClient client = HttpClient.newHttpClient();
String url = "https://api.fusionbase.com/api/v2/entities/location/get/FB_ENTITY_ID";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create(url))
.header("X-API-KEY", "<YOUR API KEY>")
.header("Content-Type", "application/json")
.GET()
.build();
client.sendAsync(request, HttpResponse.BodyHandlers.ofString())
.thenApply(HttpResponse::body)
.thenAccept(System.out::println)
.join();
}
}package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.fusionbase.com/api/v2/entities/location/get/FB_ENTITY_ID"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<YOUR API KEY>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}{
"fb_entity_id": "bfcc19ddd9edb12efb9cfea181b0dcd3",
"fb_datetime": "2024-01-24T10:24:58.231000",
"fb_entity_version": "cbff4cb34ac7130802e07d0679aa417b",
"entity_type": "LOCATION",
"updated_at": "2024-01-24T10:24:58.231000",
"created_at": "2023-11-09T16:14:38.082000",
"external_ids": {
"nominatim": {
"osm_id": 62428,
"osm_type": "relation",
"class": "boundary"
}
},
"coordinate": {
"latitude": 48.1371079,
"longitude": 11.5753822
},
"location_level": null,
"address_components": [
{
"component_type": "city",
"component_value": "Munich"
},
{
"component_type": "state",
"component_value": "Bavaria"
},
{
"component_type": "country",
"component_value": "Germany"
}
],
"alternative_names": [],
"fb_semantic_id": "location|city_no_postal_code:germany:bavaria:munich",
"formatted_address": "Munich, Germany"
}{
"results": [
{
"linked_data_id": "",
"linked_context_id": "4994292",
"linked_data_value": "Geodata Lookups for Germany",
"entity": {
"key": "4994292",
"name": {
"en": "Geodata Lookups for Germany"
},
"display_name": null,
"source": {
"name": "Fusionbase"
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"DEU"
]
}
}
}
},
"score": 0.7391094863414764,
"distance": 0.26089051365852356,
"entity_type": "STREAM"
},
{
"linked_data_id": "",
"linked_context_id": "3390386",
"linked_data_value": "IPv4 Geolocation Mappings for Germany - Timeseries",
"entity": {
"key": "3390386",
"name": {
"en": "IPv4 Geolocation Mappings for Germany - Timeseries"
},
"display_name": null,
"source": {
"name": "Fusionbase"
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"DEU"
]
}
}
}
},
"score": 0.6845411658287048,
"distance": 0.31545883417129517,
"entity_type": "STREAM"
}
}
]
import requests
url = "https://api.fusionbase.com/api/v2/entities/person/get/FB_ENTITY_ID"
headers = {
"X-API-KEY": "<YOUR API KEY>",
"Content-Type": "application/json"
}
response = requests.get(url, headers=headers)
print(response.json())const axios = require('axios');
const url = "https://api.fusionbase.com/api/v2/entities/person/get/FB_ENTITY_ID";
const headers = {
"X-API-KEY": "<YOUR API KEY>",
"Content-Type": "application/json"
};
axios.get(url, { headers })
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});curl -X "GET" "https://api.fusionbase.com/api/v2/search/data?q=$(urlencode "<QUERY>")" \
-H 'X-API-KEY: YOUR_API_KEY' \
-H 'Content-Type: application/json; charset=utf-8'import requests
import urllib.parse
query = urllib.parse.quote("<QUERY>")
url = f"https://api.fusionbase.com/api/v2/search/data?q={query}"
headers = {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8'
}
response = requests.get(url, headers=headers)
print(response.json())const axios = require('axios');
const querystring = require('querystring');
const query = querystring.escape("<QUERY>");
const url = `https://api.fusionbase.com/api/v2/search/data?q=${query}`;
const headers = {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8'
};
axios.get(url, { headers })
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
public class StreamsServicesAPIExample {
public static void main(String[] args) {
try {
String query = URLEncoder.encode("<QUERY>", StandardCharsets.UTF_8.toString());
URL url = new URL("https://api.fusionbase.com/api/v2/search/data?q=" + query);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("X-API-KEY", "YOUR_API_KEY");
connection.setRequestProperty("Content-Type", "application/json; charset=utf-8");
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
String inputLine;
StringBuffer content = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
content.append(inputLine);
}
in.close();
System.out.println(content.toString());
} catch (Exception e) {
e.printStackTrace();
}
}
}package main
import (
"fmt"
"net/http"
"net/url"
"io/ioutil"
)
func main() {
// Prepare the base URL and the query parameter
baseURL := "https://api.fusionbase.com/api/v2/search/data?q="
queryParam := "<QUERY>" // replace with your actual query
encodedQuery := url.QueryEscape(queryParam)
requestURL := baseURL + encodedQuery
// Create a new HTTP client and request
client := &http.Client{}
req, err := http.NewRequest("GET", requestURL, nil)
if err != nil {
fmt.Println("Error creating request:", err)
return
}
// Add headers to the request
req.Header.Add("X-API-KEY", "YOUR_API_KEY") // replace with your actual API key
req.Header.Add("Content-Type", "application/json; charset=utf-8")
// Perform the request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Error making request:", err)
return
}
defer resp.Body.Close
// Read and print the response body
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
fmt.Println("Error reading response:", err)
return
}
fmt.Println(string(body))
}import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) {
HttpClient client = HttpClient.newHttpClient();
String url = "https://api.fusionbase.com/api/v2/entities/person/get/FB_ENTITY_ID";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create(url))
.header("X-API-KEY", "<YOUR API KEY>")
.header("Content-Type", "application/json")
.GET()
.build();
client.sendAsync(request, HttpResponse.BodyHandlers.ofString())
.thenApply(HttpResponse::body)
.thenAccept(System.out::println)
.join();
}
}package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.fusionbase.com/api/v2/entities/person/get/FB_ENTITY_ID"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<YOUR API KEY>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}curl -X GET \
"https://api.fusionbase.com/api/v2/entities/person/get/FB_ENTITY_ID" \
-H "X-API-KEY: <YOUR API KEY>" \
-H "Content-Type: application/json"{
"fb_entity_id": "35a263b5408b085899b5a4fab6be5d75",
"fb_datetime": "2023-11-24T12:33:49.162000",
"fb_entity_version": "8b98f7dd22a477db37f3d0741be8239d",
"entity_type": "PERSON",
"entity_subtype": "INDIVIDUAL",
"updated_at": "2023-11-24T12:33:49.162000",
"created_at": "2023-11-24T12:33:49.162000",
"external_ids": {
"fb_german_business_registry_entity_id": "35a263b5408b085899b5a4fab6be5d75"
},
"name": {
"given": "Oliver",
"family": "Bäte",
"maiden": null,
"aliases": []
},
"locations": {
"home": {
"fb_entity_id": "6823b26e115adfa60fe49caea0485615",
"fb_datetime": "2023-11-09T16:14:38.553000",
"fb_entity_version": "f05bf4207b19eaa9e8d8c9b6f2afd387",
"entity_type": "LOCATION",
"entity_subtype": "CITY_NO_POSTAL_CODE",
"updated_at": "2023-11-09T16:14:38.553000",
"created_at": "2023-11-09T16:14:38.553000",
"external_ids": {
"nominatim": {
"osm_id": 62578,
"osm_type": "relation",
"class": "boundary"
}
},
"coordinate": {
"latitude": 50.938361,
"longitude": 6.959974
},
"location_level": null,
"address_components": [
{
"component_type": "city",
"component_value": "Cologne"
},
{
"component_type": "state",
"component_value": "North Rhine-Westphalia"
},
{
"component_type": "country",
"component_value": "Germany"
}
],
"elevation": null,
"alternative_names": [],
"fb_semantic_id": "location|city_no_postal_code:germany:north_rhine-westphalia:cologne",
"formatted_address": "Cologne, Germany"
}
},
"birth_date": {
"value": "1965-03-01T00:00:00",
"is_month": false
},
"source": {
"id": "data_sources/1051122944"
},
"fb_semantic_id": "person|individual|name:given:oliver|name:family:bäte|birth_date:value:1965-03-01t00:00:00|birth_date:is_month:false|locations:home:location|city_no_postal_code:germany:north_rhine-westphalia:cologne|source:data_sources/1051122944"
}pip install fusionbasepip install pandas
pip install numpypip install orjson# Import Fusionbase
from fusionbase import Fusionbase
# Create a new datastream
# Provide your API Key
fusionbase = Fusionbase(auth={"api_key": "*** SECRET CREDENTIALS ***"})
# If you prefer to have extended logging output and information
# Like a progress bar for downloading datastreams etc.
# Turn on the log
fusionbase = Fusionbase(auth={"api_key": "*** SECRET CREDENTIALS ***"}, log=True)
# Get the datastream with the key "28654971"
data_stream_key = "28654971"
data_stream = fusionbase.get_datastream(data_stream_key)# Print a nice table containing the meta data of the stream
data_stream.pretty_meta_data()# The following returns the full datastream as a list of dictionaries
# It uses a local cache if available
data = data_stream.get_data()
print(data)
# Get always the latest data from Fusionbase
data = data_stream.get_data(live=True)
print(data)
# If you only need a subset of the columns
# You'll gain much performance by only selecting those columns
data = data_stream.get_data(fields=["NAME_OF_COLUMN_1", "NAME_OF_COLUMN_N"])
print(data)
# If you need only an excerpt of the data you can use skip and limit
# The sample below gets the 10 first rows
data = data_stream.get_data(skip=0, limit=10)
print(data)
# Load the data from Fusionbase, cache it and put it in a pandas DataFrame
df = data_stream.as_dataframe()
print(df)
# Force ignoring the cache and make sure to get the latest data
df = data_stream.as_dataframe(live=True)
print(df)from pathlib import Path
# Store as JSON files
data_stream.as_json_files(storage_path=Path("./data/"))
# Store as CSV files
data_stream.as_csv_files(storage_path=Path("./data/"))
# Store as Pickle files
data_stream.as_pickle_files(storage_path=Path("./data/"))# Import Fusionbase
from fusionbase.Fusionbase import Fusionbase
# Create a new dataservice
# Provide your API Key and the Fusionbase API URI (usually: https://api.fusionbase.com/api/v1)
fusionbase = Fusionbase(auth={"api_key": "*** SECRET CREDENTIALS ***"})
data_service_key = "50527318"
data_service = fusionbase.get_dataservice(data_service_key)# Retrieves the metadata from a Service by giving a Service specific key and prints it nicely to console
data_service.pretty_meta_data()# Retrieve the request definition (such as required parameters) from a Service by giving a Service specific key and print it to console.
data_service.pretty_request_definition()# Invoke a service by providing input data
# The following lines of code are equivalent
# Services can be invoked directly by their parameter names
result = data_service.invoke(company_name="OroraTech GmbH", zip_code="81669")
print(result)
import requests
url = "https://api.fusionbase.com/api/v2/chat/completions"
headers = {
"Content-Type": "application/json",
"X-API-KEY": "<YOUR API KEY>"
}
data = {
"model": "fusion-one",
"linked_context": [
{"type": "ORGANIZATION", "id": "35b263b5408bc85899b5a4fab6be5d75"},
{"type": "PERSON", "id": "bc6a357dc563ad838e213ff06e0c1c91"}
],
"messages": [
{"role": "system", "content": "You are an insurance and underwriting expert."},
{"role": "user", "content": "What are potential insurance risks of the given company?"}
]
}
response = requests.post(url, json=data, headers=headers)
print(response.json())curl -X "POST" "https://api.fusionbase.com/api/v2/service/invoke" \
-H 'X-API-KEY: YOUR_API_KEY' \
-H 'Content-Type: application/json; charset=utf-8' \
-d $'{
"inputs": {
"entity_name": "OroraTech GmbH",
"postal_code": "81669",
"street": "St. Martin Straße 112",
"city": "München"
},
"service_key": "4658603456" # THE ID OF THE SERVICE
}'import requests
import json
url = "https://api.fusionbase.com/api/v2/service/invoke"
headers = {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json; charset=utf-8"
}
payload = {
"inputs": {
"entity_name": "OroraTech GmbH",
"postal_code": "81669",
"street": "St. Martin Straße 112",
"city": "München"
},
"service_key": "4658603456"
}
response = requests.post(url, headers=headers, data=json.dumps(payload))
print(response.text)
const axios = require('axios');
const url = "https://api.fusionbase.com/api/v2/service/invoke";
const headers = {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json; charset=utf-8"
};
const payload = {
inputs: {
entity_name: "OroraTech GmbH",
postal_code: "81669",
street: "St. Martin Straße 112",
city: "München"
},
service_key: "4658603456"
};
axios.post(url, payload, { headers: headers })
.then(response => console.log(response.data))
.catch(error => console.error('Error:', error));
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.OutputStream;
import java.nio.charset.StandardCharsets;
public class Main {
public static void main(String[] args) {
try {
URL url = new URL("https://api.fusionbase.com/api/v2/service/invoke");
String jsonInputString = "{\"inputs\": {"
+ "\"entity_name\": \"OroraTech GmbH\", "
+ "\"postal_code\": \"81669\", "
+ "\"street\": \"St. Martin Straße 112\", "
+ "\"city\": \"München\"}, "
+ "\"service_key\": \"4658603456\"}";
byte[] postData = jsonInputString.getBytes(StandardCharsets.UTF_8);
HttpURLConnection con = (HttpURLConnection) url.openConnection();
con.setRequestMethod("POST");
con.setRequestProperty("X-API-KEY", "YOUR_API_KEY");
con.setRequestProperty("Content-Type", "application/json; charset=utf-8");
con.setDoOutput(true);
try(OutputStream os = con.getOutputStream()) {
os.write(postData, 0, postData.length);
}
int responseCode = con.getResponseCode();
System.out.println("POST Response Code : " + responseCode);
// Handle response...
} catch (Exception e) {
e.printStackTrace();
}
}
}
package main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
)
func main() {
url := "https://api.fusionbase.com/api/v2/service/invoke"
payload := map[string]interface{}{
"inputs": map[string]string{
"entity_name": "OroraTech GmbH",
"postal_code": "81669",
"street": "St. Martin Straße 112",
"city": "München"
},
"service_key": "4658603456",
}
jsonPayload, _ := json.Marshal(payload)
client := &http.Client{}
req, _ := http.NewRequest("POST", url, bytes.NewBuffer(jsonPayload))
req.Header.Add("X-API-KEY", "YOUR_API_KEY")
req.Header.Add("Content-Type", "application/json; charset=utf-8")
resp, err := client.Do(req)
if err != nil {
fmt.Println("Error:", err)
return
}
defer resp.Body.Close()
// Read response
fmt.Println("Response status:", resp.Status)
}
const axios = require('axios');
const url = "https://api.fusionbase.com/api/v2/chat/completions";
const headers = {
"Content-Type": "application/json",
"X-API-KEY": "<YOUR API KEY>"
};
const data = {
model: "fusion-one",
linked_context: [
{ type: "ORGANIZATION", id: "35b263b5408bc85899b5a4fab6be5d75" },
{ type: "PERSON", id: "bc6a357dc563ad838e213ff06e0c1c91" }
],
messages: [
{ role: "system", content: "You are an insurance and underwriting expert." },
{ role: "user", content: "What are potential insurance risks of the given company?" }
]
};
axios.post(url, data, { headers: headers })
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});import okhttp3.*;
import java.io.IOException;
public class Main {
public static void main(String[] args) throws IOException {
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"model\": \"fusion-one\",\n \"linked_context\": [\n {\n \"type\": \"ORGANIZATION\",\n \"id\": \"35b263b5408bc85899b5a4fab6be5d75\"\n },\n {\n \"type\": \"PERSON\",\n \"id\": \"bc6a357dc563ad838e213ff06e0c1c91\"\n }\n ],\n \"messages\": [\n {\n \"role\": \"system\",\n \"content\": \"You are an insurance and underwriting expert.\"\n },\n {\n \"role\": \"user\",\n \"content\": \"What are potential insurance risks of the given company?\"\n }\n ]\n}");
Request request = new Request.Builder()
.url("https://api.fusionbase.com/api/v2/chat/completions")
.post(body)
.addHeader("Content-Type", "application/json")
.addHeader("X-API-KEY", "<YOUR API KEY>")
.build();
Response response = client.newCall(request).execute();
System.out.println(response.body().string());
}
}package main
import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
)
func main() {
url := "https://api.fusionbase.com/api/v2/chat/completions"
requestBody := map[string]interface{}{
"model": "fusion-one",
"linked_context": []map[string]string{
{"type": "ORGANIZATION", "id": "35b263b5408bc85899b5a4fab6be5d75"},
{"type": "PERSON", "id": "bc6a357dc563ad838e213ff06e0c1c91"},
},
"messages": []map[string]string{
{"role": "system", "content": "You are an insurance and underwriting expert."},
{"role": "user", "content": "What are potential insurance risks of the given company?"},
},
}
jsonData, err := json.Marshal(requestBody)
if err != nil {
panic(err)
}
req, err := http.NewRequest("POST", url, bytes.NewBuffer(jsonData))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-KEY", "<YOUR API KEY>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println("Response: ", string(body))
}
curl https://api.fusionbase.com/api/v2/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-KEY: <YOUR API KEY>" \
-d '{
"model": "fusion-one",
"linked_context": [
{
"type": "ORGANIZATION",
"id": "35b263b5408bc85899b5a4fab6be5d75"
},
{
"type": "PERSON",
"id": "bc6a357dc563ad838e213ff06e0c1c91"
}
],
"messages": [
{
"role": "system",
"content": "You are an insurance and underwriting expert."
},
{
"role": "user",
"content": "What are potential insurance risks of the given company?"
}
]
}'{
"id": "1234abcd5678efgh9012ijkl3456mnop",
"object": "chat.completion",
"created": 1677858242,
"model": "fusion-one",
"usage": {
"prompt_tokens": 13,
"completion_tokens": 7,
"total_tokens": 20
},
"choices": [
{
"message": {
"role": "assistant",
"content": "The potential insurance risks for the given company include..."
},
"logprobs": null,
"finish_reason": "stop",
"index": 0
}
]
}import requests
url = "https://api.fusionbase.com/api/v2/entities/organization/get/FB_ENTITY_ID"
const axios = require('axios');
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) {
HttpClient client = HttpClient.newHttpClient();
String url = "https://api.fusionbase.com/api/v2/entities/organization/get/FB_ENTITY_ID";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create(url))
.header("X-API-KEY", "<YOUR API KEY>")
.header("Content-Type", "application/json")
.GET()
.build();
client.sendAsync(request, HttpResponse.BodyHandlers.ofString())
.thenApply(HttpResponse::body)
.thenAccept(System.out::println)
.join();
}
}package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.fusionbase.com/api/v2/entities/organization/get/FB_ENTITY_ID"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<YOUR API KEY>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}curl -X GET \
"https://api.fusionbase.com/api/v2/entities/organization/get/FB_ENTITY_ID" \
-H "X-API-KEY: <YOUR API KEY> " \
-H "Content-Type: application/json"{
"fb_entity_id": "75e8887e25587ed64cc8e1733a6c7160",
"fb_datetime": "2024-02-01T16:12:18.849000",
"fb_entity_version": "55afcba0d74181bd508e0207e3fbddfc",
"entity_type": "ORGANIZATION",
"entity_subtype": "CORPORATION",
"updated_at": "2024-02-01T16:12:18.849000",
"created_at": "2023-11-24T10:30:02.502000",
"external_ids": {
"fb_german_business_registry_entity_id": "75e8887e25587ed64cc8e1733a6c7160"
},
"status": {
"active": true,
"status": "ACTIVE",
"status_detail": null
},
"name": "ADOS GmbH",
"other_names": [
"Ados Gesellschaft mit beschränkter Haftung"
],
"description": {
"registry": {
"de": "Gegenstand des Unternehmens ist die Herstellung und der Verkauf der unter dem Namen \"ADOS\" geschützten Artikel sowie der Erwerb, die Veräußerung, die Verwertung von Patenten und Erfinderrechten und die Herstellung, Anschaffung und der Vertrieb von anderen Gegenständen des Gewerbefleisses."
}
},
"address": {
"fb_entity_id": "b69ea5ed95c054a3ad9b3d75335386a7",
"fb_datetime": "2023-11-23T16:00:34.569000",
"fb_entity_version": "036c16c81f808da80a4099ca1ad85d22",
"updated_at": "2023-11-23T16:00:34.569000",
"created_at": "2023-11-23T16:00:34.569000",
"external_ids": {
"nominatim": {
"osm_id": 163641824,
"osm_type": "way",
"class": "building"
}
},
"coordinate": {
"latitude": 50.7697654,
"longitude": 6.1196758544025
},
"location_level": null,
"address_components": [
{
"component_type": "house_number",
"component_value": "23-25"
},
{
"component_type": "street",
"component_value": "Trierer Straße"
},
{
"component_type": "postal_code",
"component_value": "52078"
},
{
"component_type": "city",
"component_value": "Aachen"
},
{
"component_type": "county",
"component_value": "Städteregion Aachen"
},
{
"component_type": "state",
"component_value": "North Rhine-Westphalia"
},
{
"component_type": "country",
"component_value": "Germany"
}
],
"alternative_names": [],
"fb_semantic_id": "location|locality:germany:north_rhine-westphalia:52078:aachen:trierer_strasse:23-25",
"formatted_address": "Trierer Straße 23-25, 52078 Aachen, Germany"
},
"other_addresses": null,
"jurisdiction": {
"iso_alpha3": "DEU"
},
"contact": {
"websites": {
"primary": "https://www.ados.de/"
},
"phone_numbers": {
"primary": "0241 97690"
}
},
"founding_date": "1961-02-20T00:00:00",
"cessation_date": null,
"classifications": {
"web": [
{
"source": "Google",
"value": {
"de": "Hersteller elektronischer Geräte"
}
}
],
"industry_codes": null,
"legal_form": null
},
"source": {
"id": "data_sources/1051122944"
},
"fb_semantic_id": "organization|corporation|registration_authority_id:r3101|registration_authority_name:r3101|registration_type:hrb|registration_number:5|registration_authority_location_id:2077c7f46e95a3740492448c2beb2011|source:data_sources/1051122944",
"legal": {
"registration_authority": {
"local": {
"registration_authority_id": "R3101",
"registration_authority_name": "Aachen",
"registration_authority_entity_id": "R3101 HRB 5",
"registration_authority_entity_name": "Aachen HRB 5",
"registration_type": "HRB",
"registration_number": "5",
"registration_id_extra": null,
"registration_authority_location": {
"fb_entity_id": "2077c7f46e95a3740492448c2beb2011",
"fb_datetime": "2023-11-17T07:29:40.987000",
"fb_entity_version": "feddb22b0fa9166a41602a99f63601af",
"entity_type": "LOCATION",
"entity_subtype": "CITY_NO_POSTAL_CODE",
"updated_at": "2023-11-17T07:29:40.987000",
"created_at": "2023-11-09T16:14:31.050000",
"external_ids": {
"nominatim": {
"osm_id": 62564,
"osm_type": "relation",
"class": "boundary"
}
},
"coordinate": {
"latitude": 50.776351,
"longitude": 6.083862
},
"location_level": null,
"address_components": [
{
"component_type": "city",
"component_value": "Aachen"
},
{
"component_type": "county",
"component_value": "Städteregion Aachen"
},
{
"component_type": "state",
"component_value": "North Rhine-Westphalia"
},
{
"component_type": "country",
"component_value": "Germany"
}
],
"elevation": null,
"alternative_names": [],
"fb_semantic_id": "location|city_no_postal_code:germany:north_rhine-westphalia:aachen",
"formatted_address": "Aachen, Germany"
}
}
}
}
}import requests
url = "https://api.fusionbase.com/api/v2/entities/event/get/FB_ENTITY_ID"
headers = {
"X-API-KEY": "<YOUR API KEY>",
"Content-Type": "application/json"
}
response = requests.get(url, headers=headers)
print(response.json())const axios = require('axios');
const url = "https://api.fusionbase.com/api/v2/entities/event/get/FB_ENTITY_ID";
const headers = {
"X-API-KEY": "<YOUR API KEY>",
"Content-Type": "application/json"
};
axios.get(url, { headers })
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) {
HttpClient client = HttpClient.newHttpClient();
String url = "https://api.fusionbase.com/api/v2/entities/event/get/FB_ENTITY_ID";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create(url))
.header("X-API-KEY", "<YOUR API KEY>")
.header("Content-Type", "application/json")
.GET()
.build();
client.sendAsync(request, HttpResponse.BodyHandlers.ofString())
.thenApply(HttpResponse::body)
.thenAccept(System.out::println)
.join();
}
}package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.fusionbase.com/api/v2/entities/event/get/FB_ENTITY_ID"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<YOUR API KEY>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}curl -X GET \
"https://api.fusionbase.com/api/v2/entities/event/get/FB_ENTITY_ID" \
-H "X-API-KEY: <YOUR API KEY>" \
-H "Content-Type: application/json"{
"fb_entity_id": "9befc075e19843dba4ed7dcfc3b70dc5",
"fb_entity_version": "7fe58d301af8541a1eaee7adc0861120",
"entity_type": "EVENT",
"entity_subtype": "PUBLICATION",
"external_ids": null,
"name": {
"en": "Exit of position",
"de": "Austritt einer Position"
},
"description": {
"short": {
"en": "A member has exited their position",
"de": "Ein Mitglied hat seine Position verlassen"
}
},
"start_date": "2013-11-26T00:00:00",
"live_date": null,
"end_date": null,
"announce_date": "2013-11-26T00:00:00",
"status": "FINISHED",
"category": "MEMBER_EXIT_POSITION",
"source": {
"id": "data_sources/1784627846"
},
"details": {
"value": {
"role": {
"name": "Director",
"original_name_source": "director",
"responsibilities": null,
"representation_scheme": null,
"liability_deposit": null
}
},
"linked_entities": {
"person": {
"fb_entity_id": "72a0dbb560e4219e76763d28d6eeadb6",
"name": {
"given": "Nicholas John",
"family": "Dell",
"maiden": null,
"aliases": []
}
},
"organization": {
"fb_entity_id": "745973f63bb8ce5c36bd16361fc7da3a",
"name": "The Bristol Law Society"
}
}
},
"origin_location": null,
"event_location": null,
"effect_location": null
}{
"knowledge_graph": {
"intent": "RELATION",
"from_entity_type": "ORGANIZATION",
"from_entity_id": "546bb06ee922e3b09dc50c50068044a3",
"relation_id": "67533702",
"relation_parameters": {}
},
"results": {
"persons": [],
"organizations": [
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "546bb06ee922e3b09dc50c50068044a3",
"status": "ACTIVE",
"display_address": "Aidenbachstraße 140, 81479 Munich, Germany",
"registration_authority_entity_name": "München HRB 137024",
"display_name": "Health Care Insurance Versicherungsservice GmbH, Zweigniederlassung München",
"old_display_name_matched": null,
"name": "Health Care Insurance Versicherungsservice GmbH, Zweigniederlassung München"
},
"score": 10.070869
},
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "b868b2702752d55edd2c25115724f621",
"status": "ACTIVE",
"display_address": "Schockenriedstraße 17, 70565 Stuttgart, Germany",
"registration_authority_entity_name": "Stuttgart HRB 23323",
"display_name": "Health Insurance Service AG",
"old_display_name_matched": null,
"name": "Health Insurance Service AG"
},
"score": 26.590382
},
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "5e1c322419666b33fd0d89442f46766c",
"status": "ACTIVE",
"display_address": null,
"registration_authority_entity_name": "07391552",
"display_name": "Health Insurance Services (Sw) Limited",
"old_display_name_matched": null,
"name": "Health Insurance Services (Sw) Limited"
},
"score": 24.026272
},
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "3228a8cd0c6d720672d4e97b837a73cc",
"status": "ACTIVE",
"display_address": null,
"registration_authority_entity_name": "05191059",
"display_name": "Health Insurance Matters Ltd.",
"old_display_name_matched": null,
"name": "Health Insurance Matters Ltd."
},
"score": 26.590382
},
{
"entity_type": "ORGANIZATION",
"entity": {
"fb_entity_id": "9419edbe466b488ed13b6e568e83e032",
"status": "ACTIVE",
"display_address": null,
"registration_authority_entity_name": "07350776",
"display_name": "The Health Insurance Bureau Limited",
"old_display_name_matched": null,
"name": "The Health Insurance Bureau Limited"
},
"score": 24.026272
}
],
"locations": [],
"relations": [
{
"entity": {
"id": "64395606",
"key": "64395606",
"name": {
"en": "Multiscale Global and Local Statistical Indicators for Locations",
"de": "Standortbezogene Globale und Lokale Statistische Indikatoren"
},
"description": {
"en": "Comprehensive statistical indicators across various levels of granularity worldwide, encompassing a wide range of demographic, economic, and social data for countries, regions, and municipalities.",
"de": "Umfassende statistische Indikatoren auf verschiedenen Granularitätsstufen weltweit, die eine breite Palette an demographischen, wirtschaftlichen und sozialen Daten für Länder, Regionen und Gemeinden abdecken."
},
"parameter": {
"name": {
"de": "Deutschland: Gesamtzahl der Krankenhäuser nach Region",
"en": "Germany: Total Number of Hospitals by Region"
},
"value": {
"indicator_name": "TOTAL_HOSPITALS"
},
"source": {
"name": "Bundesinstitut für Bau-, Stadt- und Raumforschung (BBSR)"
}
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"DEU"
]
}
},
"granularity": {
"geographical": [
2,
6
]
}
}
},
"score": 0.6493748426437378,
"distance": 0.3506251573562622,
"entity_type": "RELATION"
},
{
"entity": {
"id": "64395606",
"key": "64395606",
"name": {
"en": "Multiscale Global and Local Statistical Indicators for Locations",
"de": "Standortbezogene Globale und Lokale Statistische Indikatoren"
},
"description": {
"en": "Comprehensive statistical indicators across various levels of granularity worldwide, encompassing a wide range of demographic, economic, and social data for countries, regions, and municipalities.",
"de": "Umfassende statistische Indikatoren auf verschiedenen Granularitätsstufen weltweit, die eine breite Palette an demographischen, wirtschaftlichen und sozialen Daten für Länder, Regionen und Gemeinden abdecken."
},
"parameter": {
"name": {
"en": "Global: Global Jobs Indicators Database (JOIN)"
},
"value": {
"indicator_name": "GLOBAL_JOBS_INDICATORS_DATABASE__JOIN"
},
"source": {
"name": "World Bank"
}
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"TUR",
"BWA",
"MHL",
"ETH",
"COM",
"DEU",
"SDN",
"BGR",
"AUS",
"NIC",
"MWI",
"PAK",
"BTN",
"TJK",
"SLV",
"CRI",
"VNM",
"GNB",
"TGO",
"EGY",
"LSO",
"BLR",
"TCD",
"BDI",
"CZE",
"DOM",
"KIR",
"CIV",
"DNK",
"MOZ",
"AFG",
"NAM",
"POL",
"IRQ",
"RWA",
"CHL",
"ARM",
"PRI",
"HTI",
"SSD",
"ZWE",
"ALB",
"PER",
"ITA",
"NLD",
"FRA",
"UGA",
"KEN",
"MLI",
"MNG",
"JOR",
"TZA",
"CPV",
"MYS",
"GHA",
"GBR",
"LBR",
"BIH",
"STP",
"AUT",
"SEN",
"IDN",
"ECU",
"USA",
"MDG",
"MNE",
"GTM",
"SVK",
"ISL",
"TUV",
"PNG",
"MMR",
"DJI",
"IND",
"PHL",
"NOR",
"YEM",
"VUT",
"URY",
"JAM",
"MAR",
"ROU",
"BEL",
"ARG",
"GUY",
"ESP",
"LKA",
"NPL",
"SOM",
"MDV",
"SYC",
"LAO",
"VEN",
"BHS",
"PRT",
"MUS",
"MEX",
"IRN",
"TUN",
"HRV",
"BEN",
"CAF",
"RUS",
"TTO",
"KOR",
"PLW",
"HUN",
"MLT",
"ZMB",
"CHN",
"GAB",
"IRL",
"BLZ",
"CAN",
"COG",
"SRB",
"FSM",
"UZB",
"BFA",
"CYP",
"LUX",
"MKD",
"GIN",
"NGA",
"BRB",
"ZAF",
"AZE",
"MDA",
"LTU",
"CHE",
"COL",
"PAN",
"FIN",
"KHM",
"NER",
"UKR",
"BRA",
"BOL",
"GMB",
"SLE",
"KGZ",
"SWZ",
"AGO",
"GRC",
"SLB",
"LVA",
"PRY",
"KAZ",
"MRT",
"EST",
"CMR",
"COD",
"SVN",
"SWE",
"TLS",
"THA",
"FJI",
"GEO",
"BGD",
"TON",
"HND"
]
}
},
"granularity": {
"geographical": [
1
]
}
}
},
"score": 0.6404404044151306,
"distance": 0.3595595955848694,
"entity_type": "RELATION"
}
],
"streams": [
{
"linked_data_id": "",
"linked_context_id": "55012638",
"linked_data_value": "USA: ACS1 - Imputation of Direct-purchase Health Insurance",
"entity": {
"key": "55012638",
"name": {
"en": "USA: ACS1 - Imputation of Direct-purchase Health Insurance"
},
"display_name": null,
"source": {
"name": "United States Census Bureau"
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"USA"
]
}
}
}
},
"score": 0.7111876904964447,
"distance": 0.2888123095035553,
"entity_type": "STREAM"
},
{
"linked_data_id": "",
"linked_context_id": "55000993",
"linked_data_value": "USA: ACS1 - Imputation of Health Insurance Coverage",
"entity": {
"key": "55000993",
"name": {
"en": "USA: ACS1 - Imputation of Health Insurance Coverage"
},
"display_name": null,
"source": {
"name": "United States Census Bureau"
},
"meta": {
"coverage": {
"geographical": {
"iso_alpha_3": [
"USA"
]
}
}
}
},
"score": 0.7104124128818512,
"distance": 0.2895875871181488,
"entity_type": "STREAM"
}
],
"services": []
},
"ranks": [
"STREAM",
"RELATION",
"ORGANIZATION"
]
}curl -X "GET" "https://api.fusionbase.com/api/v2/search/fusion?q=<QUERY>" \
-H 'X-API-KEY: YOUR_API_KEY' \
-H 'Content-Type: application/json; charset=utf-8'import requests
import urllib.parse
query = urllib.parse.quote("<QUERY>")
url = f"https://api.fusionbase.com/api/v2/search/fusion?q={query}"
headers = {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8'
}
response = requests.get(url, headers=headers)
print(response.json())const axios = require('axios');
const querystring = require('querystring');
const query = querystring.escape("<QUERY>");
const url = `https://api.fusionbase.com/api/v2/search/fusion?q=${query}`;
const headers = {
'X-API-KEY': 'YOUR_API_KEY',
'Content-Type': 'application/json; charset=utf-8'
};
axios.get(url, { headers })
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});import java.net.HttpURLConnection;
import java.net.URL;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
public class FusionbaseAPIExample {
public static void main(String[] args) {
try {
String query = URLEncoder.encode("<QUERY>", StandardCharsets.UTF_8.toString());
URL url = new URL("https://api.fusionbase.com/api/v2/search/fusion?q=" + query);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("X-API-KEY", "YOUR_API_KEY");
connection.setRequestProperty("Content-Type", "application/json; charset=utf-8");
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
String inputLine;
StringBuffer content = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
content.append(inputLine);
}
in.close();
System.out.println(content.toString());
} catch (Exception e) {
e.printStackTrace();
}
}
}
package main
import (
"fmt"
"net/http"
"net/url"
"io/ioutil"
)
func main() {
baseURL := "https://api.fusionbase.com/api/v2/search/fusion?q="
query := url.QueryEscape("<QUERY>")
requestURL := baseURL + query
client := &http.Client{}
req, _ := http.NewRequest("GET", requestURL, nil)
req.Header.Add("X-API-KEY", "YOUR_API_KEY")
req.Header.Add("Content-Type", "application/json; charset=utf-8")
resp, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}import requests
headers = {
'x-api-key': 'YOUR_API_KEY',
}
response = requests.get('https://api.fusionbase.com/api/v2/stream/base/STREAM_ID', headers=headers, params=params)
assert response.code == 200, "CONNECTION_ERROR"
data_stream = response.json()
print(data_stream)import requests
import json
# Replace 'YOUR_API_KEY' with your actual API key
headers = {
'x-api-key': 'YOUR_API_KEY',
}
# Define the query parameters
params = {
'skip': '1000',
'limit': '5',
'version_boundary': 'bd764e07-50a1-4c0e-a102-ae1a259557av',
'format': 'json',
'query_parameters': json.dumps({
"sort_order": ["asc"],
"sort_keys": ["fb_datetime"],
"skip": 0,
"limit": 2,
"project_fields": ["manufacturer_brand", "recall_supervised_by_kba"],
"filters": [{
"property": "construction_year_end",
"operator": "GREATER_THAN",
"value": 2013
}]
})
}
# The URL for the GET request
url = 'https://api.fusionbase.com/api/v2/stream/data/430410'
# Make the GET request
response = requests.get(url, headers=headers, params=params)
# Check if the request was successful
assert response.status_code == 200, "CONNECTION_ERROR"
# Parse the response to JSON
data = response.json()
# Example of how to use the data
print(data)import requests
# Replace 'YOUR_API_KEY' with your actual API key
headers = {
'x-api-key': 'YOUR_API_KEY',
}
# Define the query parameters
params = {
'q': 'LAMBORGHINI', # Your search query
'format': 'json' # Specify the response format
}
# Construct the full URL for the GET request
url = f'https://api.fusionbase.com/api/v2/stream/data/search/430410'
# Make the GET request
response = requests.get(url, headers=headers, params=params)
# Check if the request was successful
assert response.status_code == 200, "CONNECTION_ERROR"
# Parse the response to JSON
search_results = response.json()
# Example of how to use the data
print(search_results)
{
"id": "data_streams/430410",
"key": "430410",
"name": {
"en": "Germany: Automotive Recalls"
},
"description": {
"en": "This extensive database presents a systematic compilation of all automotive recalls issued in Germany from 1995 to the current date. Encompassing a wide range of vehicles and car accessories, the catalog serves as a vital tool for researchers, automotive engineers, policy makers, and safety analysts. Each entry in the database is meticulously documented, providing detailed information on the nature of the defect, the models and components affected, and the remedial actions recommended. By offering a chronological and categorical organization of the data, the catalog facilitates trend analysis and retrospective studies, contributing to the broader understanding of automotive safety and reliability over time. The aim of this resource is to support scientific inquiry and data-driven decision-making in the field of automotive safety, ensuring a safer and more informed vehicular environment in Germany."
},
"meta": {
"entry_count": 8119,
"main_property_count": 18
},
"created_at": "2021-06-16T12:16:18.367162",
"updated_at": "2023-10-26T22:35:11.296891",
"data_item_collections": [
{
"id": "data_item_collections/430413",
"key": "430413",
"name": "fb_id",
"description": {
"en": "The ID is a unique fingerprint that is calculated based on the values of all non-Fusionbase specific columns."
},
"meta": null,
"created_at": "2021-06-16T12:16:18.525145",
"updated_at": "2021-06-18T10:46:26.888675",
"definition": {
"en": "Unique record identifier and primary key"
},
"basic_data_type": "String",
"semantic_type": "Fusionbase ID",
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430416",
"key": "430416",
"name": "kba_reference_number",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.528423",
"updated_at": "2021-06-18T10:46:26.894534",
"definition": {
"en": "Unique reference number provided by Kraftfahrtbundesamt"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430419",
"key": "430419",
"name": "manufacturer_recall_code",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.531390",
"updated_at": "2021-06-18T10:46:26.900453",
"definition": {
"en": "Unique recall code provided by the manufacturer"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430422",
"key": "430422",
"name": "manufacturer_brand",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.533831",
"updated_at": "2021-06-18T10:46:26.906302",
"definition": {
"en": "Manufacturer brand of the car or accessory"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430425",
"key": "430425",
"name": "trade_name",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.536421",
"updated_at": "2021-06-18T10:46:26.912149",
"definition": {
"en": "Trade name of the car or accessory"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430428",
"key": "430428",
"name": "construction_year_start",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.538828",
"updated_at": "2021-06-18T10:46:26.918302",
"definition": {
"en": "Year when construction began"
},
"basic_data_type": "int",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430431",
"key": "430431",
"name": "construction_year_end",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.541334",
"updated_at": "2021-06-18T10:46:26.924226",
"definition": {
"en": "Year when construction ended"
},
"basic_data_type": "int",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430434",
"key": "430434",
"name": "affected_vehicles_worldwide",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.543767",
"updated_at": "2021-06-18T10:46:26.930195",
"definition": {
"en": "Number of vehicles affected worldwide"
},
"basic_data_type": "float",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430437",
"key": "430437",
"name": "affected_vehicles_germany",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.546184",
"updated_at": "2021-06-18T10:46:26.936015",
"definition": {
"en": "Number of vehicles affected in Germany"
},
"basic_data_type": "float",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430440",
"key": "430440",
"name": "recall_supervised_by_kba",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.548717",
"updated_at": "2021-06-18T10:46:26.941896",
"definition": {
"en": "Note whether the recall is supervised by Kraftfahrtbundesamt"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430443",
"key": "430443",
"name": "recall_description",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.551148",
"updated_at": "2021-06-18T10:46:26.947900",
"definition": {
"en": "Description of the recall"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430446",
"key": "430446",
"name": "possible_restrictions_of_the_affected_vehicle_versions",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.553559",
"updated_at": "2021-06-18T10:46:26.954070",
"definition": {
"en": "Possible restrictions that apply to the affected vehicle version"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430449",
"key": "430449",
"name": "remedial_action_by_the_manufacturer",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.556197",
"updated_at": "2021-06-18T10:46:26.960045",
"definition": {
"en": "Remedial action suggested by the manufacturer"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430452",
"key": "430452",
"name": "known_incidents",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.558624",
"updated_at": "2021-06-18T10:46:26.966000",
"definition": {
"en": "Known incidents in connection to the recall"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430455",
"key": "430455",
"name": "release_date",
"description": {
"en": ""
},
"meta": null,
"created_at": "2021-06-16T12:16:18.561138",
"updated_at": "2021-06-18T10:46:26.971823",
"definition": {
"en": "Release date of the recall"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430458",
"key": "430458",
"name": "support_hotline",
"description": {
"en": "This can be from Kraftfahrtbundesamt, the manufacturer or other separate organizations. "
},
"meta": null,
"created_at": "2021-06-16T12:16:18.563631",
"updated_at": "2021-06-18T10:46:26.977575",
"definition": {
"en": "Support hotline for the recall"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430461",
"key": "430461",
"name": "fb_datetime",
"description": {
"en": "The ISO-8601 timestamp of when the record was added to the data stream."
},
"meta": null,
"created_at": "2021-06-16T12:16:18.566053",
"updated_at": "2021-06-18T10:46:26.983433",
"definition": {
"en": "Timestamp of the record"
},
"basic_data_type": "Datetime",
"semantic_type": "Datetime",
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
},
{
"id": "data_item_collections/430464",
"key": "430464",
"name": "fb_data_version",
"description": {
"en": "Each new set of records that is added to the data stream gets automatically versioned by Fusionbase."
},
"meta": null,
"created_at": "2021-06-16T12:16:18.568492",
"updated_at": "2021-06-18T10:46:26.994883",
"definition": {
"en": "Version of the record"
},
"basic_data_type": "String",
"semantic_type": null,
"semantic_tags": null,
"data_streams": [
"data_streams/430410"
]
}
],
"source": {
"_id": "data_sources/47480",
"stream_specific": {
"uri": "https://www.kba.de/DE/Home/home_node.html"
}
},
"store_version": null,
"data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b",
"data_updated_at": "2023-06-16T10:41:28.220833",
"data": [
{
"fb_id": "31f72e92f33bcfb39ad100d8b981c9ac",
"kba_reference_number": "011209",
"manufacturer_recall_code": "NC3I6515R (0797186)",
"manufacturer_brand": "MERCEDES-BENZ LKW",
"trade_name": "SPRINTER",
"construction_year_start": 2011,
"construction_year_end": 2013,
"affected_vehicles_worldwide": 5799.0,
"affected_vehicles_germany": 3368.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Entfernung unzulässiger Abschalteinrichtungen bzw. der unzulässigen Reduzierung der Wirksamkeit des Emissionskontrollsystems.",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": "Software Steuergeräte aktualisieren.",
"known_incidents": "unknown",
"release_date": "2021-10-25",
"support_hotline": "06986798274",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "e8ffe1c04bc7f094520a13921e018579",
"kba_reference_number": "011713",
"manufacturer_recall_code": "30_2028161",
"manufacturer_brand": "KTM",
"trade_name": "125 SX, 125 XC, 150 SX",
"construction_year_start": 2021,
"construction_year_end": 2022,
"affected_vehicles_worldwide": 5806.0,
"affected_vehicles_germany": 104.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Defektes Zündsteuergerät führt zum Bruch des Pleuels. Es besteht erhöhte Sturzgefahr.",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": "Austausch des Zündsteuergeräts.",
"known_incidents": "Es sind derzeit 2 Schadenereignisse mit Unfallfolge oder Personenschäden bekannt.",
"release_date": "2022-07-11",
"support_hotline": "0962892110",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "619f71bc1d0ddf6c7231af2019ecc2a4",
"kba_reference_number": "012715",
"manufacturer_recall_code": "21DC10",
"manufacturer_brand": "HYUNDAI",
"trade_name": "I30",
"construction_year_start": 2021,
"construction_year_end": 2022,
"affected_vehicles_worldwide": 5858.0,
"affected_vehicles_germany": 2958.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Durch eine nicht korrekte Ansteuerung der elektrischen Ölpumpe kann es zu einem plötzlichen Druckabfall im Doppelkupplungsgetriebe kommen.",
"possible_restrictions_of_the_affected_vehicle_versions": "i30 N",
"remedial_action_by_the_manufacturer": "Ein Softwareupdate wird auf das Getriebesteuergerät (TCU) aufgespielt.",
"known_incidents": "unknown",
"release_date": "2023-04-27",
"support_hotline": "069380767212",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "a80368505a45f8576b1eceea1e72138d",
"kba_reference_number": "012543",
"manufacturer_recall_code": "0061460700",
"manufacturer_brand": "BMW",
"trade_name": "7, I7",
"construction_year_start": 2022,
"construction_year_end": 2023,
"affected_vehicles_worldwide": 6074.0,
"affected_vehicles_germany": 580.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Softwarefehler kann zum Verlust der Initialisierung des Airbagsteuergeräts führen. Dadurch würden die Beifahrer-Front- und Knieairbags sowie die aktive Kopfstütze deaktiviert werden.",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": "Die Steuergeräte (Sitzmodul) werden programmiert.",
"known_incidents": "unknown",
"release_date": "2023-02-23",
"support_hotline": "089125016175",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "439068622105a7c514cd708e2094eaad",
"kba_reference_number": "012459",
"manufacturer_recall_code": "26V",
"manufacturer_brand": "IVECO",
"trade_name": "S-WAY, T-WAY, X-WAY",
"construction_year_start": 2022,
"construction_year_end": 2022,
"affected_vehicles_worldwide": 6279.0,
"affected_vehicles_germany": 622.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Eine nicht konforme geschweißte Zylinderhalterung an der Kippkabine kann brechen, wenn das Fahrerhaus gekippt wird.",
"possible_restrictions_of_the_affected_vehicle_versions": "Wenn die Chargenkennzeichnung eine der folgenden ist: NF3 / NF4 / NF5 / NG1 / NG2 / NG3 / NH4 / NH5 / NJ1 / NJ2 / NJ3 / NJ4 / NK1 / NK2 / NK3 / NK4 , muss die Halterung des Zylinders getauscht werden. Ist die Chargenkennzeichnung nicht sichtbar oder können die Zeichen nicht gelesen werden, sit die Halterung des Zylinders auszutauschen.",
"remedial_action_by_the_manufacturer": "Überprüfung und ggf. Austausch der Halterung der Kippvorrichtung.",
"known_incidents": "no_incidents",
"release_date": "2023-02-09",
"support_hotline": "07314085419",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "b71c2f87c3f4a6310dce0fb54931991f",
"kba_reference_number": "012284",
"manufacturer_recall_code": "F-PEDAL",
"manufacturer_brand": "MERCEDES-BENZ LKW",
"trade_name": "E-ACTROS, E-AROCS, E- ATEGO",
"construction_year_start": 2021,
"construction_year_end": 2022,
"affected_vehicles_worldwide": 6349.0,
"affected_vehicles_germany": 2069.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Kurzschluss im Fahrpedalsensor kann zur Unterbrechung der Gasannahme und in der Folge zum Liegenbleiben des Fahrzeugs führen.",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": "Überprüfung und ggf. Erneuerung des Fahrpedals",
"known_incidents": "no_incidents",
"release_date": "2022-11-16",
"support_hotline": "+49 69 95 30 73 89",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "0cd42887e6f0bc92f1b52e80fe564632",
"kba_reference_number": "002000",
"manufacturer_recall_code": "4",
"manufacturer_brand": "MASERATI",
"trade_name": "CILINDRI, GHIBLI, QUATTROPORTE",
"construction_year_start": 1995,
"construction_year_end": 1997,
"affected_vehicles_worldwide": null,
"affected_vehicles_germany": 110.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Möglicher Kraftstoffverlust an den Kraftstoffleitungen im Motorraum",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": null,
"known_incidents": "unknown",
"release_date": "2008-01-01",
"support_hotline": null,
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "5e7bee1560328da245cd993fc9c77355",
"kba_reference_number": "001909",
"manufacturer_recall_code": "163",
"manufacturer_brand": "MASERATI",
"trade_name": "QUATTROPORTE",
"construction_year_start": 2007,
"construction_year_end": 2007,
"affected_vehicles_worldwide": null,
"affected_vehicles_germany": 71.0,
"recall_supervised_by_kba": "supervised",
"recall_description": "Fehlerhafte Software führt zum Ausfall des Stabilitätsprogramms.",
"possible_restrictions_of_the_affected_vehicle_versions": "Automatic",
"remedial_action_by_the_manufacturer": null,
"known_incidents": "unknown",
"release_date": "2008-01-01",
"support_hotline": null,
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "830fd08351a6ce095a2677500357c8f9",
"kba_reference_number": "003195",
"manufacturer_recall_code": "R29162",
"manufacturer_brand": "VOLVO",
"trade_name": "C30, S40, S60, S80, V50, V60, V70, XC60, XC70",
"construction_year_start": 2010,
"construction_year_end": 2010,
"affected_vehicles_worldwide": null,
"affected_vehicles_germany": 291.0,
"recall_supervised_by_kba": "unsupervised",
"recall_description": "Bei Fahrzeugen mit einem Fünfzylinder-Diesel (D5) sind die Kraftstoffleitungen möglicherweise nicht mit dem erforderlichen Anzugsdrehmoment am Motor befestigt worden. Dies kann zu Kraftstoffaustritt und folglich zu einer verminderten Motorleistung und Kraftstoffgeruch führen. Ausgetretener Kraftstoff kann sich im Motorraum entzünden.",
"possible_restrictions_of_the_affected_vehicle_versions": "unknown",
"remedial_action_by_the_manufacturer": null,
"known_incidents": "unknown",
"release_date": "2011-02-21",
"support_hotline": "02219393393",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
},
{
"fb_id": "74044378a70c356b2c570f1dba775b30",
"kba_reference_number": "008428",
"manufacturer_recall_code": "18SMD-113",
"manufacturer_brand": "LEXUS",
"trade_name": "LS",
"construction_year_start": 2017,
"construction_year_end": 2018,
"affected_vehicles_worldwide": 6600.0,
"affected_vehicles_germany": 9.0,
"recall_supervised_by_kba": "unsupervised",
"recall_description": "Durch eine fehlerhafte Berechnung der Luftmasse kann es unter bestimmten Bedingungen bei der Verwendung des Start-Stopp-Systems zum Absterben des Motors kommen.",
"possible_restrictions_of_the_affected_vehicle_versions": "LS500",
"remedial_action_by_the_manufacturer": "Neuprogrammierung des Motor-Steuergeräts",
"known_incidents": "unknown",
"release_date": "2018-12-12",
"support_hotline": "022341026111",
"fb_datetime": "2023-06-16T10:41:28.220000",
"fb_data_version": "3e727ad8-5cf0-43a9-ae28-88c08421187b"
}
]
}