curl --request POST \
--url https://app.base44.com/api/workspace/invitations/bulk-invite \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"invitations": [
{
"email": "dana@acme.com",
"role": "editor"
},
{
"email": "sam@acme.com"
}
]
}
'import requests
url = "https://app.base44.com/api/workspace/invitations/bulk-invite"
payload = { "invitations": [{
"email": "dana@acme.com",
"role": "editor"
}, { "email": "sam@acme.com" }] }
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({
invitations: [{email: 'dana@acme.com', role: 'editor'}, {email: 'sam@acme.com'}]
})
};
fetch('https://app.base44.com/api/workspace/invitations/bulk-invite', 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.base44.com/api/workspace/invitations/bulk-invite",
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([
'invitations' => [
[
'email' => 'dana@acme.com',
'role' => 'editor'
],
[
'email' => 'sam@acme.com'
]
]
]),
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://app.base44.com/api/workspace/invitations/bulk-invite"
payload := strings.NewReader("{\n \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\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://app.base44.com/api/workspace/invitations/bulk-invite")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.base44.com/api/workspace/invitations/bulk-invite")
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 \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"total_sent": 1,
"successful": [
"dana@acme.com"
],
"failed": [
{
"email": "sam@acme.com",
"error": "User already has a pending invitation"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Invite workspace members in bulk
Invites up to 50 people to a workspace at once, the same way as Invite workspace member.
The whole request is refused when a role or group_id isn’t allowed. Otherwise each invitation succeeds or fails on its own, so a 200 doesn’t mean every invitation went out. Check failed, which lists existing members, people with a pending invitation, and invitations that couldn’t be saved or emailed.
Retrying is safe: invitations that went out the first time come back in failed as already pending.
Inviting is limited to 6 requests per minute, shared by Invite workspace member, Invite workspace members in bulk, Resend workspace invitation, and Resend workspace invitations in bulk. A signed-in session has its own limit, and every personal access token for the workspace shares one. Some workspaces have a different limit.
curl --request POST \
--url https://app.base44.com/api/workspace/invitations/bulk-invite \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"invitations": [
{
"email": "dana@acme.com",
"role": "editor"
},
{
"email": "sam@acme.com"
}
]
}
'import requests
url = "https://app.base44.com/api/workspace/invitations/bulk-invite"
payload = { "invitations": [{
"email": "dana@acme.com",
"role": "editor"
}, { "email": "sam@acme.com" }] }
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({
invitations: [{email: 'dana@acme.com', role: 'editor'}, {email: 'sam@acme.com'}]
})
};
fetch('https://app.base44.com/api/workspace/invitations/bulk-invite', 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.base44.com/api/workspace/invitations/bulk-invite",
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([
'invitations' => [
[
'email' => 'dana@acme.com',
'role' => 'editor'
],
[
'email' => 'sam@acme.com'
]
]
]),
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://app.base44.com/api/workspace/invitations/bulk-invite"
payload := strings.NewReader("{\n \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\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://app.base44.com/api/workspace/invitations/bulk-invite")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.base44.com/api/workspace/invitations/bulk-invite")
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 \"invitations\": [\n {\n \"email\": \"dana@acme.com\",\n \"role\": \"editor\"\n },\n {\n \"email\": \"sam@acme.com\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"total_sent": 1,
"successful": [
"dana@acme.com"
],
"failed": [
{
"email": "sam@acme.com",
"error": "User already has a pending invitation"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Personal access token, sent as Authorization: Bearer <token>.
Query Parameters
Body
Invitations to send in one request.
The people to invite, 1 to 50. Each email can appear once.
1 - 50 elementsShow child attributes
Show child attributes
[
{
"email": "dana@acme.com",
"role": "editor"
},
{ "email": "sam@acme.com" }
]
Response
Which invitations went out.
Which invitations went out.
Number of invitations sent, the length of successful.
1
Emails an invitation was sent to.
["dana@acme.com"]
Invitations that weren't sent, with the reason. Empty when every invitation went out.
Show child attributes
Show child attributes
[
{
"email": "sam@acme.com",
"error": "User already has a pending invitation"
}
]
Was this page helpful?