---
title: "Connect the caller's LiteLLM key"
method: PUT
path: "/v1/inference-providers/{inferenceProviderId}/litellm/member-key"
tags: ["Inference Providers"]
---

# Connect the caller's LiteLLM key

`PUT /v1/inference-providers/{inferenceProviderId}/litellm/member-key`

## Request

- Base URL: `https://api.openworklabs.com`
- URL: `https://api.openworklabs.com/v1/inference-providers/{inferenceProviderId}/litellm/member-key`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Stores the caller's own LiteLLM key for a per-user LiteLLM provider after checking it with the LiteLLM proxy, and grants the shared model group whose models match what that key can reach. Requires a user session and an admin grant that lets the caller connect a key. Replacing the key re-matches the group. The key is write-only. Disconnect with DELETE /v1/inference-providers/{inferenceProviderId}/oauth.

## Path parameters

- `inferenceProviderId` string, typeid, required

## Request body

- object
  - `apiKey` string, required
  - `credentialSetId` string, typeid: Den TypeID with 'gcs_' prefix and a 26-character base32 suffix.

## Response `200`

Connect the caller's LiteLLM key

- object
  - `connected` true, required
  - `modelGroupId` string, typeid, required: Den TypeID with 'gmg_' prefix and a 26-character base32 suffix.
  - `modelGroupName` string, required
  - `modelIds` string[], required

## Other responses

- `400`: Invalid request or provider configuration.
- `401`: Sign-in required.
- `403`: Access denied or Gateway management disabled.
- `404`: Resource not found.
- `409`: Selection or resource conflict.

## Changes

- **2026-10-23** `c93387179b31`: 1 info
  - response property `anyOf[#/components/schemas/InvalidRequestError]/details/items/path/items/` list-of-types was narrowed by removing types `number` from media type `application/json` of response `400`
- **2026-10-07** `993c1535473e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/openworklabs/apis/den-api/changes/v1/inference-providers/:inferenceProviderId/litellm/member-key/put.md)

---

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