---
title: "Attach Provider To Agent"
method: POST
path: "/api/v1/agents/{agent_id}/providers/{provider_id}"
tags: ["providers"]
---

# Attach Provider To Agent

`POST /api/v1/agents/{agent_id}/providers/{provider_id}`

## Path parameters

- `provider_id` string, uuid, required
- `agent_id` string, uuid, required

## Headers

- `Authorization` string, nullable
- `X-Request-ID` string, nullable

## Response `201`

Successful Response

- ProviderRead
  - `id` string, uuid, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `org_id` string, uuid, required
  - `name` string, required
  - `provider` string, required
  - `model` string, nullable, required
  - `params` object, nullable, required
  - `has_api_token` boolean, required
  - `credential_ref` string, nullable
  - `last_tested_at` string, date-time, nullable
  - `last_test_ok` boolean, nullable
  - `last_test_error` string, nullable
  - `last_test_latency_ms` integer, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-27** `b20a3bdd6219` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/xenovia/apis/controlplane/changes/api/v1/agents/:agent_id/providers/:provider_id/post.md)

---

[API](https://skmtc.dev/xenovia/apis/controlplane.md) · [All operations](https://skmtc.dev/xenovia/apis/controlplane/llms.txt) · [OpenAPI document](https://skmtc.dev/xenovia/apis/controlplane/revisions/b20a3bdd6219?raw)
