> For the complete documentation index, see [llms.txt](https://docs.umbraco.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.umbraco.com/ai-in-umbraco/management-api/connections.md).

# Connections

Manage AI provider connections via the Management API.

The connection endpoints allow you to manage AI provider connections programmatically.

## Available Endpoints

| Method | Endpoint                                                                       | Description                     |
| ------ | ------------------------------------------------------------------------------ | ------------------------------- |
| GET    | `/umbraco/ai/management/api/v1/connections`                                    | List all connections            |
| GET    | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}`              | Get a specific connection       |
| POST   | `/umbraco/ai/management/api/v1/connections`                                    | Create a connection             |
| PUT    | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}`              | Update a connection             |
| DELETE | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}`              | Delete a connection             |
| POST   | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}/test`         | Test a connection               |
| GET    | `/umbraco/ai/management/api/v1/connections/capabilities`                       | List available capabilities     |
| GET    | `/umbraco/ai/management/api/v1/connections?capability={capability}`            | List connections by capability  |
| GET    | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}/capabilities` | Get a connection's capabilities |
| GET    | `/umbraco/ai/management/api/v1/connections/{connectionIdOrAlias}/models`       | Get available models            |

## Connection Model

{% code title="Connection Response" %}

```json
{
    "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "alias": "openai-prod",
    "name": "OpenAI Production",
    "providerId": "openai",
    "isActive": true,
    "dateCreated": "2024-01-15T10:30:00Z",
    "dateModified": "2024-01-15T10:30:00Z",
    "settings": {
        "apiKey": "sk-***",
        "organization": null
    }
}
```

{% endcode %}

### Properties

| Property       | Type     | Description                   |
| -------------- | -------- | ----------------------------- |
| `id`           | guid     | Unique identifier             |
| `alias`        | string   | Unique alias for lookups      |
| `name`         | string   | Display name                  |
| `providerId`   | string   | ID of the provider            |
| `isActive`     | boolean  | Whether connection is enabled |
| `dateCreated`  | datetime | Creation timestamp            |
| `dateModified` | datetime | Last modification timestamp   |
| `settings`     | object   | Provider-specific settings    |

{% hint style="info" %}
Settings are returned with sensitive values masked (for example, API keys show as `sk-***`).
{% endhint %}

## In This Section

{% content-ref url="/pages/hwy6DDHNDNXGGzgvady8" %}
[List Connections](/ai-in-umbraco/management-api/connections/list.md)
{% endcontent-ref %}

{% content-ref url="/pages/HWbkv052goANkfJHuFBk" %}
[Get Connection](/ai-in-umbraco/management-api/connections/get.md)
{% endcontent-ref %}

{% content-ref url="/pages/TNHnZ77xZKBNZ0kj7EAz" %}
[Create Connection](/ai-in-umbraco/management-api/connections/create.md)
{% endcontent-ref %}

{% content-ref url="/pages/nuDiL9Mf4qe6zD9M9wdt" %}
[Update Connection](/ai-in-umbraco/management-api/connections/update.md)
{% endcontent-ref %}

{% content-ref url="/pages/3Pkalk2mtaEpfSNeDJLS" %}
[Delete Connection](/ai-in-umbraco/management-api/connections/delete.md)
{% endcontent-ref %}

{% content-ref url="/pages/zYf2RJHjJ0nDcsmNOh3y" %}
[Test Connection](/ai-in-umbraco/management-api/connections/test.md)
{% endcontent-ref %}

{% content-ref url="/pages/iKCyLmApirGUu7LEUzMv" %}
[List Capabilities](/ai-in-umbraco/management-api/connections/capabilities.md)
{% endcontent-ref %}

{% content-ref url="/pages/By8wVLRaCONBeqR2iNYO" %}
[Get Models](/ai-in-umbraco/management-api/connections/models.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.umbraco.com/ai-in-umbraco/management-api/connections.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
