Thread

SA
Saif Ali Shaik12:44 PMOpen in Slack
Can I create a user in Archestra programmatically? I was assuming making a POST call to /api/teams/{id}/members woudl also create members

2 replies
J(
joey (archestra team)2:06 PMOpen in Slack
POST /api/teams/:id/members adds an existing user to a team — it doesn't create new users. Teams in Archestra are for access control (which agents/MCP gateways/servers a user can see), not for user management.
To create users programmatically, you use the invitation flow via better-auth's built-in endpoint:
Authorization: archestra_<your-api-key>
Content-Type: application/json

{
  "email": "<mailto:newuser@example.com|newuser@example.com>",
  "role": "member"
}```
This returns an invitation ID, you then construct the invitation link yourself and share it:
The invited user visits that link and creates their account.
J(
joey (archestra team)2:07 PMOpen in Slack
if you try going through the invite user flow in the UI you'll see what I mean - currently we don't support straight-up user creation through the API (but again, if you need this for your hackathon project, to unblock your project, feel free to hack something together!)