# Permission sets in a workspace

`GET /workspaces/:workspace/permissions`

Get details of custom permission sets in a workspace

**Required Scopes:** `WORKSPACE`

## URL Parameters

```typescript
interface URLParameters {
  /** Workspace domain */
  workspace: string; // Example: "my-company"
}
```

## Response Body

```typescript
interface ResponseBody {
  /** API endpoint to GET this object */
  url?: string;
  /** Web URL to view this object in Buddy.works */
  html_url?: string;
  permission_sets?: PermissionSetView[];
}
```

## Type Definitions

```typescript
interface PermissionSetView {
  /** API endpoint to GET this object */
  url?: string;
  /** Web URL to view this object in Buddy.works */
  html_url?: string;
  /** The name of the permission set */
  name: string;
  /** The description of the permission set */
  description?: string;
  /** The repository access level */
  repository_access_level: "DENIED" | "READ_ONLY" | "READ_WRITE" | "MANAGE";
  /** The pipeline access level */
  pipeline_access_level: "DENIED" | "READ_ONLY" | "RUN_ONLY" | "READ_WRITE";
  /** The sandbox access level */
  sandbox_access_level: "DENIED" | "READ_ONLY" | "RUN_ONLY" | "READ_WRITE";
  /** The project team access level */
  project_team_access_level: "READ_ONLY" | "MANAGE";
  /** The environment access level */
  environment_access_level: "DENIED" | "MANAGE" | "USE_ONLY";
  /** The package access level */
  package_access_level: "DENIED" | "READ_ONLY" | "READ_WRITE" | "MANAGE";
  /** The routing access level */
  routing_access_level: "DENIED" | "READ_ONLY" | "MANAGE";
  /** The target access level */
  target_access_level: "DENIED" | "READ_ONLY" | "USE_ONLY" | "MANAGE";
  /** The ID of the permission set */
  id: number;
  /** The type of the permission set */
  type?: "DEVELOPER" | "READ_ONLY" | "CUSTOM" | "PROJECT_MANAGER";
}

```

## Response Example

**Status:** `200 Permission sets retrieved successfully`

```json
{
  "url": "https://api.buddy.works/workspaces/my-workspace/permissions",
  "html_url": "https://app.buddy.works/my-workspace/-/permissions",
  "permission_sets": [
    {
      "url": "https://api.buddy.works/workspaces/my-workspace/permissions/1",
      "html_url": "https://app.buddy.works/my-workspace/-/permissions/edit/1",
      "id": 1,
      "name": "Developer",
      "type": "DEVELOPER",
      "repository_access_level": "READ_WRITE",
      "pipeline_access_level": "READ_WRITE",
      "sandbox_access_level": "READ_WRITE",
      "project_team_access_level": "READ_ONLY",
      "environment_access_level": "MANAGE",
      "package_access_level": "MANAGE"
    },
    {
      "url": "https://api.buddy.works/workspaces/my-workspace/permissions/2",
      "html_url": "https://app.buddy.works/my-workspace/-/permissions/edit/2",
      "id": 2,
      "name": "Viewer",
      "type": "READ_ONLY",
      "repository_access_level": "READ_ONLY",
      "pipeline_access_level": "READ_ONLY",
      "sandbox_access_level": "READ_ONLY",
      "project_team_access_level": "READ_ONLY",
      "environment_access_level": "USE_ONLY",
      "package_access_level": "READ_ONLY"
    },
    {
      "url": "https://api.buddy.works/workspaces/my-workspace/permissions/3",
      "html_url": "https://app.buddy.works/my-workspace/-/permissions/edit/3",
      "id": 3,
      "name": "Project Manager",
      "type": "PROJECT_MANAGER",
      "repository_access_level": "MANAGE",
      "pipeline_access_level": "READ_WRITE",
      "sandbox_access_level": "READ_WRITE",
      "project_team_access_level": "MANAGE",
      "environment_access_level": "MANAGE",
      "package_access_level": "MANAGE"
    }
  ]
}
```

---
Original source: https://buddy.works/docs/api/platform/permissions/get/workspace-permission