---
title: "Create Org Provider Key"
method: POST
path: "/v1/organizations/me/provider-keys"
tags: ["provider-keys"]
---

# Create Org Provider Key

`POST /v1/organizations/me/provider-keys`

Create a provider key in the caller's organization. Organization owners and admins only.

## Request body

- OrgProviderKeyCreateRequest — What a caller sends to create a key. The plaintext key is never stored as sent: the service encrypts it (`services/secret_box.py`) and keeps only the ciphertext and ``last4``, the same convention `entities.ProviderCredential` already uses.
  - `api_base` string, nullable
  - `api_key` string, nullable
  - `client_args` object, nullable
  - `name` string, required
  - `provider` string, required

## Response `201`

Successful Response

- OrgProviderKeyPublic — The API-facing shape. Never carries the key, only whether one is set.
  - `api_base` string, nullable
  - `archived_at` string, date-time, nullable
  - `client_args` object, nullable
  - `created_at` string, date-time, required
  - `id` string, uuid, required
  - `is_org_default` boolean, required
  - `last4` string, nullable
  - `name` string, required
  - `organization_id` string, uuid, required
  - `provider` string, required
  - `updated_at` string, date-time, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-08-20** `6c2c5c81580a` — 1 info
  - endpoint added
- **2026-08-20** `64b189825111` — 1 breaking
  - api path removed without deprecation
- **2026-08-20** `9bb9f2baf8cd` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/mozilla-ai/apis/otari/changes/v1/organizations/me/provider-keys/post.md)

---

[API](https://skmtc.dev/mozilla-ai/apis/otari.md) · [All operations](https://skmtc.dev/mozilla-ai/apis/otari/llms.txt) · [OpenAPI document](https://skmtc.dev/mozilla-ai/apis/otari/revisions/80c117c36f36?raw)
