curl --request POST \
--url https://your-instance.example.com/api/organizations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Acme Corp",
"phoneNumber": "+14165550100",
"address": "123 Yonge St, Toronto, ON",
"adminDetails": {
"email": "admin@acme.example",
"password": "CorrectHorseBatteryStaple9!",
"fullName": "Alex Admin"
}
}
'import requests
url = "https://your-instance.example.com/api/organizations"
payload = {
"name": "Acme Corp",
"phoneNumber": "+14165550100",
"address": "123 Yonge St, Toronto, ON",
"adminDetails": {
"email": "admin@acme.example",
"password": "CorrectHorseBatteryStaple9!",
"fullName": "Alex Admin"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Acme Corp',
phoneNumber: '+14165550100',
address: '123 Yonge St, Toronto, ON',
adminDetails: {
email: 'admin@acme.example',
password: 'CorrectHorseBatteryStaple9!',
fullName: 'Alex Admin'
}
})
};
fetch('https://your-instance.example.com/api/organizations', 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://your-instance.example.com/api/organizations",
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([
'name' => 'Acme Corp',
'phoneNumber' => '+14165550100',
'address' => '123 Yonge St, Toronto, ON',
'adminDetails' => [
'email' => 'admin@acme.example',
'password' => 'CorrectHorseBatteryStaple9!',
'fullName' => 'Alex Admin'
]
]),
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://your-instance.example.com/api/organizations"
payload := strings.NewReader("{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://your-instance.example.com/api/organizations")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://your-instance.example.com/api/organizations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Organization with admin user created successfully",
"data": {
"_id": "5f7b1c2e8a1d4e0012c3b400",
"name": "Acme Corp",
"phoneNumber": "+14165550100"
}
}{
"error": "Organization not found",
"details": "No organization exists with the provided id"
}{
"error": "Organization not found",
"details": "No organization exists with the provided id"
}Create a new organization
Creates an organization plus its first ADMIN user, seeded credentials document, default document/process types, and a default DynamicProperties (Contact) layout. Rejects duplicates by name or phone number and validates credentials are not already in use.
curl --request POST \
--url https://your-instance.example.com/api/organizations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Acme Corp",
"phoneNumber": "+14165550100",
"address": "123 Yonge St, Toronto, ON",
"adminDetails": {
"email": "admin@acme.example",
"password": "CorrectHorseBatteryStaple9!",
"fullName": "Alex Admin"
}
}
'import requests
url = "https://your-instance.example.com/api/organizations"
payload = {
"name": "Acme Corp",
"phoneNumber": "+14165550100",
"address": "123 Yonge St, Toronto, ON",
"adminDetails": {
"email": "admin@acme.example",
"password": "CorrectHorseBatteryStaple9!",
"fullName": "Alex Admin"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Acme Corp',
phoneNumber: '+14165550100',
address: '123 Yonge St, Toronto, ON',
adminDetails: {
email: 'admin@acme.example',
password: 'CorrectHorseBatteryStaple9!',
fullName: 'Alex Admin'
}
})
};
fetch('https://your-instance.example.com/api/organizations', 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://your-instance.example.com/api/organizations",
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([
'name' => 'Acme Corp',
'phoneNumber' => '+14165550100',
'address' => '123 Yonge St, Toronto, ON',
'adminDetails' => [
'email' => 'admin@acme.example',
'password' => 'CorrectHorseBatteryStaple9!',
'fullName' => 'Alex Admin'
]
]),
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://your-instance.example.com/api/organizations"
payload := strings.NewReader("{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://your-instance.example.com/api/organizations")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://your-instance.example.com/api/organizations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Acme Corp\",\n \"phoneNumber\": \"+14165550100\",\n \"address\": \"123 Yonge St, Toronto, ON\",\n \"adminDetails\": {\n \"email\": \"admin@acme.example\",\n \"password\": \"CorrectHorseBatteryStaple9!\",\n \"fullName\": \"Alex Admin\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Organization with admin user created successfully",
"data": {
"_id": "5f7b1c2e8a1d4e0012c3b400",
"name": "Acme Corp",
"phoneNumber": "+14165550100"
}
}{
"error": "Organization not found",
"details": "No organization exists with the provided id"
}{
"error": "Organization not found",
"details": "No organization exists with the provided id"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Organization display name shown across UI and templates.
Primary organization phone number in E.164 format (must start with +1 or +91 followed by 10 digits).
Initial admin user created alongside the organization; email and password seed the first login.
Show child attributes
Show child attributes
{
"email": "admin@acme.example",
"password": "CorrectHorseBatteryStaple9!",
"fullName": "Alex Admin",
"phoneNumber": "+14165550100",
"designation": "Operations Lead",
"sinchPhoneNumber": "+14165550101"
}
Mailing/business address for the organization.
Optional third-party API credentials (Anthropic, Sinch SMS/MMS) provisioned for the new organization.
Show child attributes
Show child attributes
{
"anthropicApiKey": "sk-ant-api03-EXAMPLE-key-redacted",
"sinchServicePlanId": "srv-plan-example-123",
"sinchApiToken": "sinch-token-example-redacted",
"sinchMmsApiKey": "sinch-mms-key-example",
"sinchMmsServiceId": "sinch-mms-service-example"
}