---
title: "Set Task Permissions"
method: PUT
path: "/v1/ai/agents/tasks/{taskId}/permissions"
tags: ["AI Agent Tasks"]
---

# Set Task Permissions

`PUT /v1/ai/agents/tasks/{taskId}/permissions`

## Request

- Base URL: `https://eu1.api.matillion.com/dpc`
- URL: `https://eu1.api.matillion.com/dpc/v1/ai/agents/tasks/{taskId}/permissions`
- Auth: HTTP bearer

Replaces the full set of granted tool permissions for a task. Pass an empty list to clear all permissions.

## Path parameters

- `taskId` string, uuid, required

## Request body

- SetPermissionsRequest
  - `grantedPermissions` AllowedTool[], required
    - `toolName` string, required: The name of the tool to allow

## Response `200`

Permissions updated successfully

- SetPermissionsResponse
  - `grantedPermissions` AllowedTool[]: The full list of tools now granted permission for this task
    - `toolName` string, required: The name of the tool to allow
  - `taskId` string, uuid: The unique identifier of the task

## Other responses

- `400`: Invalid request body
- `401`: Missing or invalid authentication token
- `403`: Insufficient permissions
- `404`: Task not found
- `502`: Upstream service error
- `504`: Upstream service timeout

---

[API](https://skmtc.dev/maia/apis/maia-public-rest-api.md) - [All operations](https://skmtc.dev/maia/apis/maia-public-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/maia/apis/maia-public-rest-api/revisions/6239825f68eb?raw)
