curl --request PUT \
--url https://api.example.com/api/v1/orgs/compliance \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/orgs/compliance"
payload = {
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({compliance_legal_name: '<string>', compliance_mailing_address: '<string>'})
};
fetch('https://api.example.com/api/v1/orgs/compliance', 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://api.example.com/api/v1/orgs/compliance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'compliance_legal_name' => '<string>',
'compliance_mailing_address' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.example.com/api/v1/orgs/compliance"
payload := strings.NewReader("{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://api.example.com/api/v1/orgs/compliance")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/orgs/compliance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>",
"force_compliance": false,
"name": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Update Org Compliance
Update the caller’s org CASL sender identity + mailing address (org-scoped).
Only compliance_legal_name + compliance_mailing_address are settable;
both are trimmed and a blank value clears the field (stored NULL). The UPDATE
dict is built from ONLY those two model fields, so force_compliance can
never be set here regardless of what the client sends. Returns the
round-tripped compliance record (return=representation gives the full row).
curl --request PUT \
--url https://api.example.com/api/v1/orgs/compliance \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/orgs/compliance"
payload = {
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({compliance_legal_name: '<string>', compliance_mailing_address: '<string>'})
};
fetch('https://api.example.com/api/v1/orgs/compliance', 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://api.example.com/api/v1/orgs/compliance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'compliance_legal_name' => '<string>',
'compliance_mailing_address' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.example.com/api/v1/orgs/compliance"
payload := strings.NewReader("{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://api.example.com/api/v1/orgs/compliance")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/orgs/compliance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"compliance_legal_name\": \"<string>\",\n \"compliance_mailing_address\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"compliance_legal_name": "<string>",
"compliance_mailing_address": "<string>",
"force_compliance": false,
"name": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Body for PUT /api/v1/orgs/compliance.
ONLY the sender identity + address are user-settable. force_compliance is a
reseller/operator control and is intentionally absent — a client that sends it
has it ignored (extra fields dropped), never written. Both fields are trimmed;
a blank value clears the field (stored as NULL).
Response
Successful Response
The org's CASL compliance identity + reseller override (read model).
Mirrors what the frontend reads: legal name, mailing address, the read-only
force_compliance flag, and the org display name. Unset fields are returned
as null (the frontend coerces to "").