# Get a session's tool approval mode

Source: <https://everruns.com/docs/api/operations/get_session_approval_mode/>

[Docs](https://everruns.com/docs/)/[API reference](https://everruns.com/docs/api/)/[Sessions & workspaces](https://everruns.com/docs/api/groups/sessions-workspaces/)/Get a session's tool approval mode

# Get a session's tool approval mode

Preview

Manage execution sessions and rooms, and their files, tasks, storage, databases and managed sandboxes.

Public APIEverruns Cloud and self-hosted Platform

GET`/v1/sessions/{session_id}/approval-mode`

See [authentication](https://everruns.com/docs/sre/runbooks/authentication/) for credentials and permissions.

## Parameters

### Path Parameters

**session_id**

required

string

Prefixed public identifier

## Responses

200Success

### 200

Success

Media typeapplication/json

The session’s approval mode switch and the modes the organization allows.

object

**allowed_modes**

required

Modes the organization allows (`off`, `auto`, `normal`, `protective`).

Array\<string>

**mode**

The mode a person picked for this session, or `null` when the session follows the owner’s default and the agent’s own mode.

string | null

### Example generated

```json
{
  "allowed_modes": [
    "example"
  ],
  "mode": "example"
}
```

FetchcURL

Request

```js
const url = 'https://app.everruns.com/api/v1/sessions/example/approval-mode';
const options = {method: 'GET'};


try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

Request

```sh
curl --request GET \
  --url https://app.everruns.com/api/v1/sessions/example/approval-mode
```

Additional language examples require JavaScript. The default request example is available above.

200

200 · Success

```json
{
  "allowed_modes": [
    "string"
  ]
}
```

## Matching endpoints