# Forwarding

Manage forwarding rules and forwarding addresses.

The examples use A2A code mode. MCP exposes the same code mode through its `execute` tool.

## Functions

### `forwarding.activate`

```text
forwarding.activate(account_id: str, forwarding_id: str, active: bool) -> ForwardingRule
```

Update forwarding active state.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `PATCH /v1/public/accounts/{account_id}/forwarding/{forwarding_id}/active` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `forwarding_id` | `str` | yes | Forwarding rule UUID from the route path |
| `active` | `bool` | yes | Whether forwarding should be active |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `active` | `bool` | yes | Whether forwarding is active |
| `created_at` | `str` | yes | Forwarding rule creation timestamp |
| `id` | `str` | yes | Forwarding rule UUID |
| `scope_id` | `str` | yes | Resource UUID for the forwarding scope |
| `scope_type` | `"account" \| "workspace" \| "domain"` | yes | Resource scope type for the forwarding rule |
| `target_email` | `str` | yes | Forwarding destination email address |
| `updated_at` | `str` | yes | Forwarding rule last update timestamp |
| `verification_required` | `bool` | yes | Whether recipient verification is required |
| `verification_state` | `"internal" \| "pending" \| "verified" \| "expired"` | yes | Recipient verification state |
| `verification_expires_at` | `str \| null` | no | Verification expiry timestamp |
| `verification_sent_at` | `str \| null` | no | Verification email sent timestamp |
| `verification_verified_at` | `str \| null` | no | Verification completion timestamp |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.activate(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", active=true)"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": true
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.activate",
      "status": "completed",
      "result": true
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.activate(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", active=true)"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": true\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.activate\",\n      \"status\": \"completed\",\n      \"result\": true\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.add`

```text
forwarding.add(account_id: str, target_email: str, domain?: str | null, workspace_id?: str | null) -> ForwardingRule
```

Create forwarding.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `POST /v1/public/accounts/{account_id}/forwarding` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `target_email` | `str` | yes | Forwarding destination email address |
| `domain` | `str \| null` | no | Domain UUID or domain name scope for the forwarding rule |
| `workspace_id` | `str \| null` | no | Workspace UUID scope for the forwarding rule |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `active` | `bool` | yes | Whether forwarding is active |
| `created_at` | `str` | yes | Forwarding rule creation timestamp |
| `id` | `str` | yes | Forwarding rule UUID |
| `scope_id` | `str` | yes | Resource UUID for the forwarding scope |
| `scope_type` | `"account" \| "workspace" \| "domain"` | yes | Resource scope type for the forwarding rule |
| `target_email` | `str` | yes | Forwarding destination email address |
| `updated_at` | `str` | yes | Forwarding rule last update timestamp |
| `verification_required` | `bool` | yes | Whether recipient verification is required |
| `verification_state` | `"internal" \| "pending" \| "verified" \| "expired"` | yes | Recipient verification state |
| `verification_expires_at` | `str \| null` | no | Verification expiry timestamp |
| `verification_sent_at` | `str \| null` | no | Verification email sent timestamp |
| `verification_verified_at` | `str \| null` | no | Verification completion timestamp |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", target_email=\"user@example.com\", domain=\"example.com\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": true
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.add",
      "status": "completed",
      "result": true
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", target_email=\"user@example.com\", domain=\"example.com\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": true\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.add\",\n      \"status\": \"completed\",\n      \"result\": true\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.delete`

```text
forwarding.delete(account_id: str, forwarding_id: str) -> {}
```

Delete forwarding.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `DELETE /v1/public/accounts/{account_id}/forwarding/{forwarding_id}` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `forwarding_id` | `str` | yes | Forwarding rule UUID from the route path |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `result` | `{}` | yes |  |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": {}
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.delete",
      "status": "completed",
      "result": {}
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {}\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.delete\",\n      \"status\": \"completed\",\n      \"result\": {}\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.list`

```text
forwarding.list(account_id: str, page?: int, page_size?: int) -> Page[ForwardingRule]
```

List forwarding.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.view` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.view` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `GET /v1/public/accounts/{account_id}/forwarding` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `page` | `int` | no | One-based forwarding rule page number |
| `page_size` | `int` | no | Maximum forwarding rules per page |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `items` | `[{"active": bool, "created_at": str, "id": str, "scope_id": str, "scope_type": "account" \| "workspace" \| "domain", "target_email": str, "updated_at": str, "verification_required": bool, "verification_state": "internal" \| "pending" \| "verified" \| "expired", "verification_expires_at"?: str \| null, "verification_sent_at"?: str \| null, "verification_verified_at"?: str \| null}]` | yes | Forwarding rules on this page |
| `page` | `int` | yes | Current one-based page number |
| `page_size` | `int` | yes | Maximum items per page |
| `total` | `int` | yes | Total matching forwarding rules |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": true
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.list",
      "status": "completed",
      "result": true
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": true\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.list\",\n      \"status\": \"completed\",\n      \"result\": true\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.update`

```text
forwarding.update(account_id: str, forwarding_id: str, target_email: str) -> ForwardingRule
```

Update forwarding.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `PATCH /v1/public/accounts/{account_id}/forwarding/{forwarding_id}` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `forwarding_id` | `str` | yes | Forwarding rule UUID from the route path |
| `target_email` | `str` | yes | Forwarding destination email address |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `active` | `bool` | yes | Whether forwarding is active |
| `created_at` | `str` | yes | Forwarding rule creation timestamp |
| `id` | `str` | yes | Forwarding rule UUID |
| `scope_id` | `str` | yes | Resource UUID for the forwarding scope |
| `scope_type` | `"account" \| "workspace" \| "domain"` | yes | Resource scope type for the forwarding rule |
| `target_email` | `str` | yes | Forwarding destination email address |
| `updated_at` | `str` | yes | Forwarding rule last update timestamp |
| `verification_required` | `bool` | yes | Whether recipient verification is required |
| `verification_state` | `"internal" \| "pending" \| "verified" \| "expired"` | yes | Recipient verification state |
| `verification_expires_at` | `str \| null` | no | Verification expiry timestamp |
| `verification_sent_at` | `str \| null` | no | Verification email sent timestamp |
| `verification_verified_at` | `str \| null` | no | Verification completion timestamp |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", target_email=\"user@example.com\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": true
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.update",
      "status": "completed",
      "result": true
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", target_email=\"user@example.com\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": true\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.update\",\n      \"status\": \"completed\",\n      \"result\": true\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.verification.confirm`

```text
forwarding.verification.confirm(account_id: str, forwarding_id: str, code: str) -> ForwardingRule
```

Confirm forwarding verification.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `POST /v1/public/accounts/{account_id}/forwarding/{forwarding_id}/verification/confirm` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `forwarding_id` | `str` | yes | Forwarding rule UUID from the route path |
| `code` | `str` | yes | Forwarding verification code |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `verified` | `bool` | yes | Whether forwarding verification succeeded |
| `forwarding_id` | `str \| null` | no | Forwarding rule UUID |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.verification.confirm(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", code=\"<string>\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": true
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.verification.confirm",
      "status": "completed",
      "result": true
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.verification.confirm(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", code=\"<string>\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": true\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.verification.confirm\",\n      \"status\": \"completed\",\n      \"result\": true\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `forwarding.verification.send`

```text
forwarding.verification.send(account_id: str, forwarding_id: str) -> ForwardingRule
```

Send forwarding verification.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `forwarding.manage` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `forwarding.manage` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `POST /v1/public/accounts/{account_id}/forwarding/{forwarding_id}/verification/send` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `forwarding_id` | `str` | yes | Forwarding rule UUID from the route path |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `cooldown_seconds` | `int` | yes | Seconds before another verification email can be sent |
| `sent` | `bool` | yes | Whether a verification email was sent |
| `expires_at` | `str \| null` | no | Verification expiry timestamp |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "forwarding.verification.send(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": 123
  },
  "responses": [
    {
      "index": 0,
      "function": "forwarding.verification.send",
      "status": "completed",
      "result": 123
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "forwarding.verification.send(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", forwarding_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": 123\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"forwarding.verification.send\",\n      \"status\": \"completed\",\n      \"result\": 123\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```
