From 0b8e2aab8188fd150783a5389019079ff233f062 Mon Sep 17 00:00:00 2001 From: David Xu Date: Tue, 31 Dec 2024 12:59:32 -0500 Subject: [PATCH] info text about org admin pat --- docs/administration/concepts/index.mdx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/administration/concepts/index.mdx b/docs/administration/concepts/index.mdx index d93c1f97..25854930 100644 --- a/docs/administration/concepts/index.mdx +++ b/docs/administration/concepts/index.mdx @@ -186,7 +186,10 @@ Use [resource tags](#resource-tags) to organize resources by environment using t permissions when we release attribute based access control (ABAC). ABAC on the resource tag will provide a fine-grained way to restrict access to production tracing projects, for example. We do not recommend that you use Workspaces for environment separation as you cannot share resources across Workspaces. If you would like to promote a prompt from `staging` to `prod`, we recommend you use prompt tags instead. See [docs](../prompt_engineering/concepts#tags) for more information. -### Cross-workspace access +### Programmatically Managing Workspaces +:::info +A PAT associated with an organization admin has access to all resources within an organization. Ensure this token is only provided to developers who need to manage resources across workspaces. +::: Use a personal access token (PAT) associated with an organization admin to programmatically create workspaces. This PAT can also be used to manage resources across your organization's workspaces (e.g. creating and deleting tracing projects, datasets, prompts, etc.). By default, the PAT will target the workspace it was created in. To manage resources in a workspace different from the default, you can specify the desired workspace ID in the client declaration. The sample code @@ -245,8 +248,6 @@ url = client.push_prompt("example-joke-prompt", object=prompt) print("Successfully created prompt and tracing project in default workspace", project.id, url) -session = requests.Session() - # Specify new workspace id session.headers.update({"X-Tenant-Id": ""}) client = ls.Client(session=session)