curl --request GET \
--url https://go.aiinsurance.io/api/v1/me/companies \
--header 'Authorization: Bearer <token>'import requests
url = "https://go.aiinsurance.io/api/v1/me/companies"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://go.aiinsurance.io/api/v1/me/companies', 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://go.aiinsurance.io/api/v1/me/companies",
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://go.aiinsurance.io/api/v1/me/companies"
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://go.aiinsurance.io/api/v1/me/companies")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://go.aiinsurance.io/api/v1/me/companies")
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{
"companies": [
{
"companyId": "11111111-1111-1111-1111-111111111111",
"companyName": "Alpha Co",
"roleName": "admin",
"roleDisplayName": "Admin"
},
{
"companyId": "22222222-2222-2222-2222-222222222222",
"companyName": "Bravo Co",
"roleName": "underwriter",
"roleDisplayName": "Underwriter"
}
],
"defaultCompanyId": "11111111-1111-1111-1111-111111111111"
}List my accessible companies
Lists the companies the Bearer-authenticated user may act on — each with
the user’s role on it — plus the user’s defaultCompanyId (their sticky
active-company pointer) as the suggested default selection.
Unlike every other endpoint, this one is not company-scoped: it
precedes company selection. It is the entry point of the MCP
company-selection flow (list_companies) — the caller uses it to discover
which companyId to pass to the company-scoped endpoints.
Authentication: user-principal Bearer only. Send a user-scoped Auth0
access token as Authorization: Bearer <jwt>. An API key is not accepted
here (an API key is scoped to a single company and has no notion of “my
companies”); a request without a valid user Bearer token returns 401.
The roster contains only the companies the user holds a real, assigned
role on. A user who is a member of no company gets an empty list (a
200, not an error).
curl --request GET \
--url https://go.aiinsurance.io/api/v1/me/companies \
--header 'Authorization: Bearer <token>'import requests
url = "https://go.aiinsurance.io/api/v1/me/companies"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://go.aiinsurance.io/api/v1/me/companies', 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://go.aiinsurance.io/api/v1/me/companies",
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://go.aiinsurance.io/api/v1/me/companies"
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://go.aiinsurance.io/api/v1/me/companies")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://go.aiinsurance.io/api/v1/me/companies")
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{
"companies": [
{
"companyId": "11111111-1111-1111-1111-111111111111",
"companyName": "Alpha Co",
"roleName": "admin",
"roleDisplayName": "Admin"
},
{
"companyId": "22222222-2222-2222-2222-222222222222",
"companyName": "Bravo Co",
"roleName": "underwriter",
"roleDisplayName": "Underwriter"
}
],
"defaultCompanyId": "11111111-1111-1111-1111-111111111111"
}Authorizations
User-principal OAuth 2.0 Bearer authentication. Send a user-scoped Auth0 access token (audience = the app API audience) as Authorization: Bearer <jwt>. The request resolves to the user's identity and is authorized by their Role on the {companyId} in the path — the same role-based permissions the web app enforces. This is the path the MCP connector uses to act on a user's behalf; endpoints that accept it list both BearerAuth and ApiKeyAuth.
Response
The user's accessible companies and default selection.
Every company the user holds a real, assigned role on. Empty if the user is a member of no company.
Show child attributes
Show child attributes
The user's sticky active-company pointer, as a suggested default. null if unset. It is only a suggestion — honor it only when it appears in companies (the pointer can dangle at a company the user no longer belongs to).
