# Remove agent public access

Source: https://docs.vlayers.ai/reference/public-access/delete-agent-public-access

`DELETE /v1/public-access/settings/agents/{agentId}` · scope `public_access:write`

Removes one agent's row, so the agent inherits the workspace's values.

Requires an API key with the `public_access:write` scope.

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `agentId` | path | string | yes | The agent id. Example: `"0192f5c2-6f7a-7b9c-8d1e-2f3a4b5c6d78"` |
| `if-match` | header | string | no | The `version` of the row this edit was made from. A stale one is refused with 409 `version_conflict` instead of overwriting a newer change. Leave it out when creating a row. Example: `"3"` |

## Request

cURL:

```bash
curl -X DELETE "https://api.vlayers.ai/v1/public-access/settings/agents/$AGENT_ID" \
  -H "Authorization: Bearer $VOICELAYER_API_KEY"
```

TypeScript:

```ts
import { VoiceLayer } from '@voicelayer/api';

const voicelayer = new VoiceLayer();

await voicelayer.publicAccess.removeAgent('<agent-id>');
```

Python:

```python
from voicelayer import VoiceLayer

vl = VoiceLayer()

vl.publicAccess.remove_agent("<agent-id>")
```
