---
title: "Create a new tool"
url: https://hexelstudio.com/docs/api/titan/tool-registry/create-a-new-tool
---

# Create a new tool

**POST** `/titan/tools/tools`

Create a new tool in a toolkit the caller may write: its organization's own toolkit, or a system toolkit when the caller is the system tools organization. The tool is owned through its toolkit. A tool's slug and version are unique within its toolkit: a second create of the same pair is 409 TOOL_EXISTS. An organization's tool created published counts against its published tools limit (409 PUBLISHED_TOOLS_LIMIT).

Requires permission `tool-gateway:tool:write`.

## Headers

- `Authorization: string`

  `Bearer <token>`. A Hexel Studio access token for a member or a service user of your organization (or send a service user's API key as X-API-Key).

- `X-Workspace-Id: optional string`

  Workspace scope used by permission checks, if applicable.

- `X-Environment-Id: optional string`

  Optional environment scope.

## Body parameters

- `available_versions: array of string`

  AvailableVersions lists the tool's versions; send [] or [version] (an
omitted list is refused by the database).

- `backend_config: optional HTTPBackendConfig or MCPBackendConfig`

  BackendConfig is the HTTPBackendConfig of an http tool or the
MCPBackendConfig of an mcp tool.

- `cacheable_seconds: optional integer`

  CacheableSeconds, when set, lets a result be cached that long.

- `capability_tags: array of string`

  CapabilityTags label the tool (policy tags); send [] for none (an
omitted list is refused by the database).

- `description: optional string`

  Description is shown to agents choosing the tool.

- `execution_backend: string`

  ExecutionBackend selects how the tool runs and the shape of
backend_config: "http" (an HTTP or GraphQL API call) or "mcp" (a
tools/call on an MCP server).

  One of: `"http"`, `"mcp"`

- `idempotency_required: optional boolean`

  IdempotencyRequired requires an idempotency key on every execution.

- `input_schema: object`

  InputSchema is the JSON Schema of the tool's arguments: it needs a
"type", and an object schema needs "properties".

- `is_side_effecting: optional boolean`

  IsSideEffecting marks a tool that changes state at the destination.

- `lifecycle: optional string`

  Lifecycle is "draft" (the default) or "published". A tool created
published must pass the publish lint (400 TOOL_LINT_FAILED) and counts
against its organization's published tools limit.

  One of: `"draft"`, `"published"`

- `max_retries: optional integer`

  MaxRetries defaults to 3 when omitted or 0.

- `name: string`

- `output_schema: object`

  OutputSchema is the JSON Schema of the tool's result, with the same
rules as input_schema.

- `required_scopes: array of string`

  RequiredScopes lists the provider scopes the tool needs; send [] for
none (an omitted list is refused by the database).

- `requires_auth: optional boolean`

  RequiresAuth says the tool needs a connected account of its toolkit.

- `slug: string`

  Slug identifies the tool within its toolkit (with version).

- `timeout_seconds: optional integer`

  TimeoutSeconds defaults to 30 when omitted or 0.

- `toolkit_id: optional string`

  ToolkitID names the toolkit by id; it takes precedence over
toolkit_slug.

- `toolkit_slug: optional string`

  ToolkitSlug names the toolkit; give it or toolkit_id.

- `version: string`

## Returns

`201` Created (`Tool`)

- `auth: optional ToolAuthV1`

  - `config_id: optional string`

  - `connected_account_id: optional string`

  - `mode: optional string`

  - `required: optional boolean`

  - `schemes: optional array of string`

  - `scopes: optional array of string`

- `available_versions: optional array of string`

- `backend_config: optional object`

- `cacheable_seconds: optional integer`

- `capabilities: optional array of string`

- `capability_tags: optional array of string`

- `created_at: optional string`

- `deprecated_at: optional string`

- `description: optional string`

- `endpoint: optional string`

- `execution_backend: optional string`

- `idempotency: optional boolean`

- `idempotency_required: optional boolean`

- `input_schema: optional object`

- `is_side_effecting: optional boolean`

- `lifecycle: optional string`

  draft, published, deprecated, retired

- `max_retries: optional integer`

- `name: optional string`

- `output_schema: optional object`

- `owner_organization_id: optional string`

  OwnerOrganizationID is the owner of the tool's toolkit, absent for a
system tool. Read-only.

- `policy_tags: optional array of string`

- `published_at: optional string`

- `rate_limit: optional ToolRateLimitV1`

  - `bucket: optional string`

  - `limit_per_window: optional integer`

  - `scope: optional string`

  - `window_seconds: optional integer`

- `required_scopes: optional array of string`

- `requires_auth: optional boolean`

- `retired_at: optional string`

- `slug: optional string`

- `streaming: optional boolean`

- `timeout_ms: optional integer`

- `timeout_seconds: optional integer`

- `tool_id: optional string`

- `toolkit_id: optional string`

- `toolkit_slug: optional string`

  For discovery/auth resolution

- `updated_at: optional string`

- `version: optional string`

## Errors

- `400` Bad Request
- `401` Unauthenticated: token missing or rejected at the edge
- `403` Forbidden
- `404` Not Found
- `409` Conflict
- `500` Internal Server Error

## Example

```bash
curl --request POST \
  --url 'https://api.hexelstudio.com/v1/titan/tools/tools' \
  --header "Authorization: Bearer $ACCESS_TOKEN" \
  --header 'Content-Type: application/json' \
  --data '{
  "available_versions": [
    "1"
  ],
  "backend_config": {
    "url": "https://api.example.com/v1/items/{id}",
    "method": "GET",
    "headers": {
      "key": "string"
    },
    "query_params": [
      "string"
    ],
    "credential": {
      "slots": [
        {
          "field": "access_token",
          "format": "bearer",
          "in": "header",
          "name": "Authorization",
          "password": "string",
          "prefix": "string",
          "username": "string"
        }
      ]
    },
    "request": {
      "body": "json",
      "idempotency_header": "Idempotency-Key",
      "query": "flat"
    },
    "response": {
      "reject_present": [
        "string"
      ],
      "require": {}
    },
    "response_options": {
      "body": "json",
      "error_body_bytes": 0,
      "max_body_bytes": 0,
      "pagination": "link",
      "redirects": {
        "max_hops": 0
      },
      "retry_after": true
    },
    "protocol": "graphql",
    "document": "string",
    "operation_name": "string",
    "rate_limit": {
      "bucket": "string",
      "limit_per_window": 0,
      "scope": "toolkit",
      "window_seconds": 0
    },
    "streaming": true
  },
  "cacheable_seconds": 0,
  "capability_tags": [
    "string"
  ],
  "description": "string",
  "execution_backend": "http",
  "idempotency_required": true,
  "input_schema": {},
  "is_side_effecting": true,
  "lifecycle": "draft",
  "max_retries": 3,
  "name": "Get item",
  "output_schema": {},
  "required_scopes": [
    "string"
  ],
  "requires_auth": true,
  "slug": "GET_ITEM",
  "timeout_seconds": 30,
  "toolkit_id": "00000000-0000-0000-0000-000000000000",
  "toolkit_slug": "ACME",
  "version": "1"
}'
```

### Response (201)

```json
{
  "auth": {
    "config_id": "string",
    "connected_account_id": "string",
    "mode": "string",
    "required": true,
    "schemes": [
      "string"
    ],
    "scopes": [
      "string"
    ]
  },
  "available_versions": [
    "string"
  ],
  "backend_config": {},
  "cacheable_seconds": 0,
  "capabilities": [
    "string"
  ],
  "capability_tags": [
    "string"
  ],
  "created_at": "2026-01-01T00:00:00Z",
  "deprecated_at": "2026-01-01T00:00:00Z",
  "description": "string",
  "endpoint": "string",
  "execution_backend": "string",
  "idempotency": true,
  "idempotency_required": true,
  "input_schema": {},
  "is_side_effecting": true,
  "lifecycle": "string",
  "max_retries": 0,
  "name": "string",
  "output_schema": {},
  "owner_organization_id": "string",
  "policy_tags": [
    "string"
  ],
  "published_at": "2026-01-01T00:00:00Z",
  "rate_limit": {
    "bucket": "string",
    "limit_per_window": 0,
    "scope": "string",
    "window_seconds": 0
  },
  "required_scopes": [
    "string"
  ],
  "requires_auth": true,
  "retired_at": "2026-01-01T00:00:00Z",
  "slug": "string",
  "streaming": true,
  "timeout_ms": 0,
  "timeout_seconds": 0,
  "tool_id": "string",
  "toolkit_id": "string",
  "toolkit_slug": "string",
  "updated_at": "2026-01-01T00:00:00Z",
  "version": "string"
}
```

### Response (400)

```json
{
  "error": {
    "code": "string",
    "message": "string"
  }
}
```

### Response (403)

```json
{
  "error": {
    "code": "string",
    "message": "string"
  }
}
```

### Response (404)

```json
{
  "error": {
    "code": "string",
    "message": "string"
  }
}
```

### Response (409)

```json
{
  "error": {
    "code": "string",
    "message": "string"
  }
}
```

### Response (500)

```json
{
  "error": {
    "code": "string",
    "message": "string"
  }
}
```
