import { SDK } from "@meetkai/mka1";
const sdk = new SDK();
async function run() {
const result = await sdk.auth.cluster.inviteOrgMembers({
sessionCookie: "<YOUR_API_KEY_HERE>",
}, {
id: "<id>",
requestBody: {
invitations: [
{
email: "Aurelio1@yahoo.com",
},
],
},
});
console.log(result);
}
run();using MeetKai.MKA1;
using MeetKai.MKA1.Types.Requests;
using System.Collections.Generic;
var sdk = new SDK();
var res = await sdk.Auth.Cluster.InviteOrgMembersAsync(
security: new InviteClusterOrgMembersSecurity() {
SessionCookie = "<YOUR_API_KEY_HERE>",
},
id: "<id>",
body: new InviteClusterOrgMembersRequestBody() {
Invitations = new List<InviteClusterOrgMembersInvitation>() {
new InviteClusterOrgMembersInvitation() {
Email = "Aurelio1@yahoo.com",
},
},
}
);
// handle responsefrom meetkai_mka1 import SDK, models
with SDK() as sdk:
res = sdk.auth.cluster.invite_org_members(security=models.InviteClusterOrgMembersSecurity(
session_cookie="<YOUR_API_KEY_HERE>",
), id="<id>", invitations=[
{
"email": "Aurelio1@yahoo.com",
},
])
# Handle response
print(res)curl --request POST \
--url https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations \
--header 'Content-Type: application/json' \
--cookie __Secure-mka1-auth-v2.session_token= \
--data '
{
"invitations": [
{
"email": "<string>",
"role": "member",
"resend": true
}
]
}
'const options = {
method: 'POST',
headers: {
cookie: '__Secure-mka1-auth-v2.session_token=',
'Content-Type': 'application/json'
},
body: JSON.stringify({invitations: [{email: '<string>', role: 'member', resend: true}]})
};
fetch('https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations', 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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations",
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' => '<string>',
'role' => 'member',
'resend' => true
]
]
]),
CURLOPT_COOKIE => "__Secure-mka1-auth-v2.session_token=",
CURLOPT_HTTPHEADER => [
"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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations"
payload := strings.NewReader("{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "__Secure-mka1-auth-v2.session_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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations")
.header("cookie", "__Secure-mka1-auth-v2.session_token=")
.header("Content-Type", "application/json")
.body("{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = '__Secure-mka1-auth-v2.session_token='
request["Content-Type"] = 'application/json'
request.body = "{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": [
{
"email": "<string>",
"status": "sent",
"invitationId": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Invite members on behalf of an organization
Requires a cluster-admin session with Cluster as its active organization. The target must be active and cannot be Cluster. Sends up to 20 organization invitations without switching the admin’s session or joining the target organization. Each row accepts role member or admin, defaulting to member; owner and custom roles are not supported. New invitations include the target’s oldest team when one exists. Results follow input order; invalid emails, duplicates, existing members, pending invitations, and delivery failures are reported per row. An existing pending invitation must match the requested role, including when resend is false. An explicit resend reuses a matching pending invitation with no team or the target’s oldest team, preserving its inviter, role, and team. Invitation expiry is 48 hours; at most 100 unexpired pending invitations are allowed per organization. API keys are not supported.
import { SDK } from "@meetkai/mka1";
const sdk = new SDK();
async function run() {
const result = await sdk.auth.cluster.inviteOrgMembers({
sessionCookie: "<YOUR_API_KEY_HERE>",
}, {
id: "<id>",
requestBody: {
invitations: [
{
email: "Aurelio1@yahoo.com",
},
],
},
});
console.log(result);
}
run();using MeetKai.MKA1;
using MeetKai.MKA1.Types.Requests;
using System.Collections.Generic;
var sdk = new SDK();
var res = await sdk.Auth.Cluster.InviteOrgMembersAsync(
security: new InviteClusterOrgMembersSecurity() {
SessionCookie = "<YOUR_API_KEY_HERE>",
},
id: "<id>",
body: new InviteClusterOrgMembersRequestBody() {
Invitations = new List<InviteClusterOrgMembersInvitation>() {
new InviteClusterOrgMembersInvitation() {
Email = "Aurelio1@yahoo.com",
},
},
}
);
// handle responsefrom meetkai_mka1 import SDK, models
with SDK() as sdk:
res = sdk.auth.cluster.invite_org_members(security=models.InviteClusterOrgMembersSecurity(
session_cookie="<YOUR_API_KEY_HERE>",
), id="<id>", invitations=[
{
"email": "Aurelio1@yahoo.com",
},
])
# Handle response
print(res)curl --request POST \
--url https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations \
--header 'Content-Type: application/json' \
--cookie __Secure-mka1-auth-v2.session_token= \
--data '
{
"invitations": [
{
"email": "<string>",
"role": "member",
"resend": true
}
]
}
'const options = {
method: 'POST',
headers: {
cookie: '__Secure-mka1-auth-v2.session_token=',
'Content-Type': 'application/json'
},
body: JSON.stringify({invitations: [{email: '<string>', role: 'member', resend: true}]})
};
fetch('https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations', 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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations",
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' => '<string>',
'role' => 'member',
'resend' => true
]
]
]),
CURLOPT_COOKIE => "__Secure-mka1-auth-v2.session_token=",
CURLOPT_HTTPHEADER => [
"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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations"
payload := strings.NewReader("{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "__Secure-mka1-auth-v2.session_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://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations")
.header("cookie", "__Secure-mka1-auth-v2.session_token=")
.header("Content-Type", "application/json")
.body("{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apigw.mka1.com/api/v1/authentication/admin/cluster/orgs/{id}/invitations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = '__Secure-mka1-auth-v2.session_token='
request["Content-Type"] = 'application/json'
request.body = "{\n \"invitations\": [\n {\n \"email\": \"<string>\",\n \"role\": \"member\",\n \"resend\": true\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": [
{
"email": "<string>",
"status": "sent",
"invitationId": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Authorizations
Current Better Auth browser or device-login session
Headers
Optional external end-user identifier forwarded by the API gateway.
Path Parameters
Body
1 - 20 elementsShow child attributes
Show child attributes
Response
OK
Show child attributes
Show child attributes
Was this page helpful?