Create a new tenant
curl --request POST \
--url https://api.engagefabric.com/tenants \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"metadata": {
"industry": "SaaS",
"companySize": "50-100"
}
}
'import requests
url = "https://api.engagefabric.com/tenants"
payload = {
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"metadata": {
"industry": "SaaS",
"companySize": "50-100"
}
}
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 Corporation',
slug: 'acme-corp',
plan: 'FREE',
metadata: {industry: 'SaaS', companySize: '50-100'}
})
};
fetch('https://api.engagefabric.com/tenants', 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.engagefabric.com/tenants",
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 Corporation',
'slug' => 'acme-corp',
'plan' => 'FREE',
'metadata' => [
'industry' => 'SaaS',
'companySize' => '50-100'
]
]),
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.engagefabric.com/tenants"
payload := strings.NewReader("{\n \"name\": \"Acme Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\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://api.engagefabric.com/tenants")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Acme Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.engagefabric.com/tenants")
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 Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"status": "ACTIVE",
"isActive": true,
"isAlphaLocked": true,
"onboardingStatus": "PENDING",
"alphaApprovalStatus": "PENDING",
"createdAt": "2025-01-15T10:30:00Z",
"updatedAt": "2025-01-15T10:30:00Z",
"alphaApprovedAt": "2025-01-15T10:30:00Z",
"alphaApprovedBy": "admin@engagefabric.com",
"alphaRejectionReason": "Not a good fit for alpha program",
"alphaApplicationNote": "We are building a gamification platform",
"metadata": {
"industry": "SaaS"
},
"deletedAt": null,
"_count": {
"projects": 3,
"members": 5
}
}tenants
Create a new tenant
POST
/
tenants
Create a new tenant
curl --request POST \
--url https://api.engagefabric.com/tenants \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"metadata": {
"industry": "SaaS",
"companySize": "50-100"
}
}
'import requests
url = "https://api.engagefabric.com/tenants"
payload = {
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"metadata": {
"industry": "SaaS",
"companySize": "50-100"
}
}
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 Corporation',
slug: 'acme-corp',
plan: 'FREE',
metadata: {industry: 'SaaS', companySize: '50-100'}
})
};
fetch('https://api.engagefabric.com/tenants', 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.engagefabric.com/tenants",
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 Corporation',
'slug' => 'acme-corp',
'plan' => 'FREE',
'metadata' => [
'industry' => 'SaaS',
'companySize' => '50-100'
]
]),
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.engagefabric.com/tenants"
payload := strings.NewReader("{\n \"name\": \"Acme Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\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://api.engagefabric.com/tenants")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Acme Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.engagefabric.com/tenants")
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 Corporation\",\n \"slug\": \"acme-corp\",\n \"plan\": \"FREE\",\n \"metadata\": {\n \"industry\": \"SaaS\",\n \"companySize\": \"50-100\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "Acme Corporation",
"slug": "acme-corp",
"plan": "FREE",
"status": "ACTIVE",
"isActive": true,
"isAlphaLocked": true,
"onboardingStatus": "PENDING",
"alphaApprovalStatus": "PENDING",
"createdAt": "2025-01-15T10:30:00Z",
"updatedAt": "2025-01-15T10:30:00Z",
"alphaApprovedAt": "2025-01-15T10:30:00Z",
"alphaApprovedBy": "admin@engagefabric.com",
"alphaRejectionReason": "Not a good fit for alpha program",
"alphaApplicationNote": "We are building a gamification platform",
"metadata": {
"industry": "SaaS"
},
"deletedAt": null,
"_count": {
"projects": 3,
"members": 5
}
}Body
application/json
Response
Tenant created successfully
