> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Resource Restrictions

> Control access to resources by restricting or unrestricting them using the Arize TypeScript SDK.

> [!NOTE]
>
> The `resource_restrictions` functions are currently in **BETA**. The API may change without notice. A one-time warning is emitted on first use.

Restricting a resource prevents roles bound at higher hierarchy levels (space, org, account) from granting access to it. Only space admins or users with the `PROJECT_RESTRICT` permission can perform these actions. Creating a restriction currently supports only `PROJECT` resources; listing returns restrictions of all supported types (`PROJECT`, `DASHBOARD`, and `PROMPT`).

## List Resource Restrictions

List active resource restrictions the authenticated user is permitted to manage. Returns a paginated list of `ResourceRestriction` objects.

**Parameters**

* `resourceType` (`"PROJECT" | "DASHBOARD" | "PROMPT"`, optional): Filter to a single resource type. When omitted, restrictions of all supported types are returned.
* `limit` (number, optional): Maximum number of restrictions to return.
* `cursor` (string, optional): Pagination cursor from a previous response.
* `client` (ArizeClient, optional): An ArizeClient instance to use for the request.

```typescript theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
import { listResourceRestrictions } from "@arizeai/ax-client";

const { data: restrictions, pagination } = await listResourceRestrictions({
  resourceType: "PROJECT",  // optional
  limit: 10,
});
```

## Restrict a Resource

Mark a resource as restricted. This operation is idempotent. Returns a `ResourceRestriction`.

**Parameters**

* `resourceId` (string, required): The global ID of the resource to restrict. Must encode a project.
* `client` (ArizeClient, optional): An ArizeClient instance to use for the request.

```typescript theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
import { restrictResource } from "@arizeai/ax-client";

const restriction = await restrictResource({
  resourceId: "your_project_id",
});
console.log(restriction);
```

## Unrestrict a Resource

Remove restriction from a resource. Returns `void`.

**Parameters**

* `resourceId` (string, required): The global ID of the resource to unrestrict.
* `client` (ArizeClient, optional): An ArizeClient instance to use for the request.

```typescript theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
import { unrestrictResource } from "@arizeai/ax-client";

await unrestrictResource({
  resourceId: "your_project_id",
});
```
