---
title: "Create a delegation"
method: POST
path: "/v1/agents/{agent_id}/delegations"
tags: ["Delegations"]
---

# Create a delegation

`POST /v1/agents/{agent_id}/delegations`

## Request

- Base URL: `https://api.1claw.co`
- URL: `https://api.1claw.co/v1/agents/{agent_id}/delegations`
- Auth: HTTP bearer

Grant an agent (delegator) permission to delegate tasks to another agent (delegate).
Human-only — agents cannot create their own delegations.

## Path parameters

- `agent_id` string, uuid, required

## Request body

- CreateDelegationRequest
  - `delegate_id` string, uuid, required: The agent ID to delegate to.
  - `allowed_tools` string[]: Tool names the delegate may use. Empty means all tools allowed.
  - `blocked_tools` string[]: Tool names the delegate may NOT use.
  - `max_daily_delegations` integer: Maximum delegation calls per UTC day. NULL means unlimited.
  - `max_depth` integer: Maximum delegation chain depth (default 3).
  - `guardrails` object: Additional guardrail constraints for this delegation.
  - `delegation_mode` 'caller' | 'target' | 'both': Execution mode: caller (use delegator's creds), target (use delegate's config), or both.
  - `expires_at` string, date-time: Optional expiration timestamp.

## Response `201`

Delegation created

- DelegationResponse
  - `id` string, uuid
  - `org_id` string, uuid
  - `delegator_id` string, uuid
  - `delegate_id` string, uuid
  - `delegator_name` string
  - `delegate_name` string
  - `allowed_tools` string[]
  - `blocked_tools` string[]
  - `max_daily_delegations` integer, nullable
  - `max_depth` integer
  - `guardrails` object
  - `delegation_mode` 'caller' | 'target' | 'both'
  - `is_active` boolean
  - `created_by` string, uuid
  - `expires_at` string, date-time, nullable
  - `created_at` string, date-time
  - `updated_at` string, date-time
  - `delegations_today` integer: Number of delegations used today (present in effective endpoint).

## Other responses

- `400`: Invalid request
- `403`: Insufficient permissions
- `409`: Delegation already exists for this delegator/delegate pair

---

[API](https://skmtc.dev/1claw/apis/1claw-api.md) · [All operations](https://skmtc.dev/1claw/apis/1claw-api/llms.txt) · [OpenAPI document](https://skmtc.dev/1claw/apis/1claw-api/revisions/ae109b496830?raw)
