---
title: "Create a custom provider"
method: POST
path: "/api/providers/"
tags: ["Models"]
---

# Create a custom provider

`POST /api/providers/`

## Request

- Base URL: `https://api.respan.ai`
- URL: `https://api.respan.ai/api/providers/`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

To update an existing provider, use `PATCH /api/providers/{provider_id}/`.

## Request body

- object
  - `provider_id` string, required: Unique provider identifier within your organization.
  - `provider_name` string, required: Human-readable provider name.
  - `extra_kwargs` object: Provider configuration. Put provider credentials under extra_kwargs.api_key.

## Response `201`

Created provider.

- object
  - `id` string, required: Provider string ID. Same value as `provider_id`.
  - `provider_id` string, required: Unique provider identifier within your organization.
  - `provider_name` string, required: Human-readable provider name.
  - `extra_kwargs` object: Stored provider configuration. The current backend returns this object, including credentials it contains; handle the response as sensitive.
  - `created_at` string, date-time, nullable
  - `updated_at` string, date-time, nullable

## Other responses

- `400`: Bad Request
- `403`: The API key is missing, invalid or expired.

## Changes

- **2026-10-21** `c30bcb383ee8`: 3 breaking, 4 info
  - request body became required
  - the response property `created_at` became nullable for the status `201`
  - the response property `updated_at` became nullable for the status `201`
  - api operation id `models_createCustomProvider` removed and replaced with `createCustomProvider`
  - …3 more
- **2026-10-02** `b830b79cfd52`: 2 info
  - added the non-success response with the status `403`
  - removed the non-success response with the status `401`
- **2026-09-17** `6fa8242da8c2`: 1 warning, 1 info
  - deleted the `header` request parameter `Authorization`
  - the endpoint scheme security `RespanApiKey` was added to the API
- **2026-09-12** `22b868ef3f22`: 1 info
  - api operation id `create-custom-provider` removed and replaced with `models_createCustomProvider`
- **2026-08-13** `4e064cf81dae`: 5 breaking, 4 warning, 2 info
  - the `extra_kwargs` request property type changed from no type to `object`
  - the response property `created_at` became optional for the status `201`
  - the response property `updated_at` became optional for the status `201`
  - the `extra_kwargs` response's property type changed from no type to `object` for status `201`
  - …7 more

[Operation history](https://skmtc.dev/keywordsai/apis/respan-api/changes/api/providers/post.md)

---

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