> 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/17.latest/management-api/connections.md).

# Connections

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/capabilities/{capability}`    | Get connections by capability |
| 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/G1UD6MHPksQdQxA0KE9C" %}
[List Connections](/ai-in-umbraco/17.latest/management-api/connections/list.md)
{% endcontent-ref %}

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

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

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

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

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

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

{% content-ref url="/pages/F0H5oFYuFsXJZL2jEFyL" %}
[Get Models](/ai-in-umbraco/17.latest/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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

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

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
