Create Custom Object
curl --request POST \
--url https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {
"vehicleMake": "Toyota",
"vehicleModel": "Camry",
"year": 2024,
"vin": "1HGBH41JXMN109186"
}
}
'import requests
url = "https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}"
payload = { "data": {
"vehicleMake": "Toyota",
"vehicleModel": "Camry",
"year": 2024,
"vin": "1HGBH41JXMN109186"
} }
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: {
vehicleMake: 'Toyota',
vehicleModel: 'Camry',
year: 2024,
vin: '1HGBH41JXMN109186'
}
})
};
fetch('https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}', 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://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'vehicleMake' => 'Toyota',
'vehicleModel' => 'Camry',
'year' => 2024,
'vin' => '1HGBH41JXMN109186'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}"
payload := strings.NewReader("{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "550e8400-e29b-41d4-a716-446655440020"
}Custom Objects
Create Custom Object
Creates a new custom object of the given type.
The request body must include a data object where keys are field
referenceIds defined in the type’s configuration. Use the
Get Configuration
endpoint to discover available fields.
Relationship fields are not accepted in data — use the dedicated
relationship management endpoints instead.
Required permission: company.fmv1_custom_object:create
POST
/
api
/
v1
/
external
/
companies
/
{companyId}
/
custom-objects
/
{objectType}
Create Custom Object
curl --request POST \
--url https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {
"vehicleMake": "Toyota",
"vehicleModel": "Camry",
"year": 2024,
"vin": "1HGBH41JXMN109186"
}
}
'import requests
url = "https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}"
payload = { "data": {
"vehicleMake": "Toyota",
"vehicleModel": "Camry",
"year": 2024,
"vin": "1HGBH41JXMN109186"
} }
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: {
vehicleMake: 'Toyota',
vehicleModel: 'Camry',
year: 2024,
vin: '1HGBH41JXMN109186'
}
})
};
fetch('https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}', 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://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'vehicleMake' => 'Toyota',
'vehicleModel' => 'Camry',
'year' => 2024,
'vin' => '1HGBH41JXMN109186'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}"
payload := strings.NewReader("{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.aiinsurance.io/api/v1/external/companies/{companyId}/custom-objects/{objectType}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {\n \"vehicleMake\": \"Toyota\",\n \"vehicleModel\": \"Camry\",\n \"year\": 2024,\n \"vin\": \"1HGBH41JXMN109186\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "550e8400-e29b-41d4-a716-446655440020"
}Authorizations
API key authentication. Include your API key in the Authorization header.
Path Parameters
Company identifier
Custom object type in snake_case format (e.g., vehicle, building_info)
Body
application/json
Field values keyed by referenceId
Response
Custom object created successfully
The ID of the created custom object
Was this page helpful?
⌘I
