---
title: "Store an API key connection for a manifest api_key provider"
method: POST
path: "/connections/{provider}/api-key"
tags: ["Setup · Connections"]
---

# Store an API key connection for a manifest api_key provider

`POST /connections/{provider}/api-key`

## Request

- Base URL: `https://api.ziggsai.com`
- URL: `https://api.ziggsai.com/connections/{provider}/api-key`
- Auth: HTTP bearer

## Path parameters

- `provider` string, required

## Request body

- StoreApiKeyConnectionDto
  - `apiKey` string, required: User API key; stored encrypted, never returned
  - `externalAccountLabel` string

## Response `201`

Created

- ConnectionCreatedResponseSchema
  - `connection` ConnectionViewSchema, required
    - `connectionId` string, required
    - `ownerId` string, required
    - `provider` string, required
    - `externalAccountLabel` string, nullable
    - `externalAccountId` string, nullable
    - `scopesGranted` string[]
    - `mcpServerUrl` string, nullable: Remote MCP server URL for `provider: "mcp"` connections.
    - `status` string, required
    - `createdAt` string, date-time

---

[API](https://skmtc.dev/ziggsai/apis/ziggs-developer-api.md) · [All operations](https://skmtc.dev/ziggsai/apis/ziggs-developer-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ziggsai/apis/ziggs-developer-api/revisions/eda79030e072?raw)
