For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Connect
BlogHelp CenterAPI PricingSign up
OverviewElevenCreativeElevenAgentsElevenAPIReception AIAPI referenceChangelog
OverviewElevenCreativeElevenAgentsElevenAPIReception AIAPI referenceChangelog
  • API reference
    • Introduction
    • Authentication
    • Streaming
  • ElevenAgents
  • ElevenAPI
  • ElevenCreative
  • Core Resources
  • Workspace
        • GETGet Resource
        • POSTShare Workspace Resource
        • POSTUnshare Workspace Resource
  • Legacy
LogoLogo
Login
Login
Connect
BlogHelp CenterAPI PricingSign up
WorkspaceWorkspaceResources

Share Workspace Resource

POST
/v1/workspace/resources/:resource_id/share
POST
/v1/workspace/resources/:resource_id/share
$curl -X POST https://api.elevenlabs.io/v1/workspace/resources/resource_id/share \
> -H "Content-Type: application/json" \
> -d '{
> "role": "admin",
> "resource_type": "voice"
>}'
Grants a role (one of 'admin', 'editor', 'commenter', or 'viewer') on a workspace resource to a user, group, or workspace (service account) API key. This overrides any existing role the target has on the resource. To target a user or service account, pass only the user email; the user must be in your workspace. To target a group, pass only the group id. To target a workspace (service account) API key, pass the api key id; the resource will be shared with the service account associated with that key. You must have admin access to the resource to share it.
Was this page helpful?
Previous

Unshare Workspace Resource

Next
Built with

Grants a role (one of ‘admin’, ‘editor’, ‘commenter’, or ‘viewer’) on a workspace resource to a user, group, or workspace (service account) API key. This overrides any existing role the target has on the resource. To target a user or service account, pass only the user email; the user must be in your workspace. To target a group, pass only the group id. To target a workspace (service account) API key, pass the api key id; the resource will be shared with the service account associated with that key. You must have admin access to the resource to share it.

Path parameters

resource_idstringRequired
The ID of the target resource.

Headers

xi-api-keystringOptional

Request

This endpoint expects an object.
roleenumRequired

Role to grant to the target: one of ‘admin’, ‘editor’, ‘commenter’, or ‘viewer’.

Allowed values:
resource_typeenumRequired
Resource type of the target resource.
user_emailstring or nullOptional
The email of the user or service account.
group_idstring or nullOptional

The ID of the target group. Use ‘default’ to set the resource’s baseline role — every workspace member receives this role unless they hold a higher one through a direct user grant, group membership, or workspace (service account) API key.

workspace_api_key_idstring or nullOptional

The ID of the target workspace (service account) API key. This is not the API key string itself that you pass in the header for authentication — it is the key’s ID, which workspace admins can find under Developers → Service Accounts.

Response

Successful Response

Errors

422
Unprocessable Entity Error