---
title: "Connect With Api Key"
method: POST
path: "/api/py/mcp/connect-with-key"
---

# Connect With Api Key

`POST /api/py/mcp/connect-with-key`

## Request

- Base URL: `https://api.getauctor.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.getauctor.com/api/py/mcp/connect-with-key`
- Auth: none declared

Create an MCP connection using a static API key instead of OAuth.

Stores the key, validates it by running MCP discovery, and returns
the connection info with tool count on success.

## Request body

- ConnectWithKeyRequest
  - `server_url` string, required
  - `connection_id` string, nullable
  - `api_key` string, nullable
  - `header_name` string, nullable
  - `headers` HeaderEntry[], nullable
    - `name` string, required
    - `value` string, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

## Changes

- **2026-09-09** `de54e725bfd2`: 1 info
  - added the new optional request property `connection_id`
- **2026-09-01** `aeb6faa3b8f0`: 4 info
  - added the new optional request property `header_name`
  - added the new optional request property `headers`
  - the request property `api_key` became optional
  - request property `api_key` list-of-types was widened by adding types `null` to media type `application/json`

[Operation history](https://skmtc.dev/getauctor/apis/getauctor-api/changes/api/py/mcp/connect-with-key/post.md)

---

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