curl -X POST https://api.bota.dev/v1/end-users \
-H "Authorization: Bearer sk_live_..." \
-H "Content-Type: application/json" \
-d '{
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
}
}'
const response = await fetch('https://api.bota.dev/v1/end-users', {
method: 'POST',
headers: {
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
body: JSON.stringify({
external_id: 'user_12345',
email: 'john@example.com',
name: 'John Doe',
metadata: {
plan: 'pro',
department: 'sales',
},
}),
});
const endUser = await response.json();
import requests
response = requests.post(
'https://api.bota.dev/v1/end-users',
headers={
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
json={
'external_id': 'user_12345',
'email': 'john@example.com',
'name': 'John Doe',
'metadata': {
'plan': 'pro',
'department': 'sales',
},
},
)
end_user = response.json()
{
"id": "eu_abc123",
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
},
"created_at": "2025-01-15T10:30:00Z"
}
{
"error": {
"code": "invalid_request",
"message": "Invalid email format"
}
}
End Users
Create End User
Create a new end user in your project
POST
/
end-users
curl -X POST https://api.bota.dev/v1/end-users \
-H "Authorization: Bearer sk_live_..." \
-H "Content-Type: application/json" \
-d '{
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
}
}'
const response = await fetch('https://api.bota.dev/v1/end-users', {
method: 'POST',
headers: {
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
body: JSON.stringify({
external_id: 'user_12345',
email: 'john@example.com',
name: 'John Doe',
metadata: {
plan: 'pro',
department: 'sales',
},
}),
});
const endUser = await response.json();
import requests
response = requests.post(
'https://api.bota.dev/v1/end-users',
headers={
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
json={
'external_id': 'user_12345',
'email': 'john@example.com',
'name': 'John Doe',
'metadata': {
'plan': 'pro',
'department': 'sales',
},
},
)
end_user = response.json()
{
"id": "eu_abc123",
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
},
"created_at": "2025-01-15T10:30:00Z"
}
{
"error": {
"code": "invalid_request",
"message": "Invalid email format"
}
}
End users represent the people who wear devices and are subjects of recordings. They exist in your Bota project but don’t log into Bota directly.
Authentication
Requires an API key withend_users:write scope.
curl -X POST https://api.bota.dev/v1/end-users \
-H "Authorization: Bearer sk_live_..." \
-H "Content-Type: application/json" \
-d '{
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
}
}'
const response = await fetch('https://api.bota.dev/v1/end-users', {
method: 'POST',
headers: {
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
body: JSON.stringify({
external_id: 'user_12345',
email: 'john@example.com',
name: 'John Doe',
metadata: {
plan: 'pro',
department: 'sales',
},
}),
});
const endUser = await response.json();
import requests
response = requests.post(
'https://api.bota.dev/v1/end-users',
headers={
'Authorization': 'Bearer sk_live_...',
'Content-Type': 'application/json',
},
json={
'external_id': 'user_12345',
'email': 'john@example.com',
'name': 'John Doe',
'metadata': {
'plan': 'pro',
'department': 'sales',
},
},
)
end_user = response.json()
Request Body
Your system’s unique identifier for this user. Use this to link Bota end users to users in your application.
User’s email address.
User’s display name.
Arbitrary key-value metadata for your own use.
Response
Returns the created end user object.{
"id": "eu_abc123",
"external_id": "user_12345",
"email": "john@example.com",
"name": "John Doe",
"metadata": {
"plan": "pro",
"department": "sales"
},
"created_at": "2025-01-15T10:30:00Z"
}
{
"error": {
"code": "invalid_request",
"message": "Invalid email format"
}
}
Response Fields
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier for the end user (prefixed with eu_). |
external_id | string | Your system’s unique identifier for this user. |
email | string | User’s email address. |
name | string | User’s display name. |
metadata | object | Arbitrary key-value metadata. |
created_at | string | ISO 8601 timestamp of when the end user was created. |
Was this page helpful?
⌘I

