# Connection Info

> Store credentials for an external system once, then reference them from actions, plugins, and integrations

---

Site [llms.txt](/llms.txt)

---

A Connection Info object holds the details needed to reach an external system: an IP address or hostname, a port, a protocol, and credentials such as a username and password, an SSH key, or authentication headers. Cloud Management Platform (CMP) stores the password securely, so any action can use the connection without the credentials appearing in code. There is a standard form, one for Git connections, and another for AWS account profiles.

![Screenshot of the Connection Info page.](/img/cmp/configure/integrations/connection-info/connection-info.png)

## Add Connection Info

1. Go to **Admin** > **Connection Info**.
1. Select **Add**.
1. Complete the form.
1. Select **Create**.

| Field | Description |
| --- | --- |
| **Name** | A descriptive name for this connection. |
| **IP/Hostname** | Either the IP address or the hostname for this connection. |
| **Port** | The port used for this connection. |
| **Protocol** | HTTP or HTTPS are the standard options. See [Development tips for plugins](/docs/cmp/use/orchestration/plugins/development-tips/). |
| **Username** | The username of the account being connected to. |
| **Password** | The password of the account being connected to. It is stored securely. If the password vault feature is enabled, this field offers **Locally Stored** or **Vault Managed**. Select **Vault Managed** to read the secret from a configured vault provider. See [Use password vaults](/docs/cmp/configure/access-and-security/security/use-password-vaults/). |
| **SSH Key** | An SSH key used in place of a password. If a key is selected and a script runs over this SSH connection, the key is used, and any password is ignored. |
| **Use Auth Headers** | Select this to authenticate with headers rather than a username and password. |
| **Headers** | Header text in JSON format, used instead of the username and password. |
| **Labels** | Use labels to organize and filter Connection Info entries. Begin typing in the Labels field to add a new label or choose an existing one. |
| **Description** | Optional description text for this Connection Info. |

The same page also has an **AWS Account Profile** button, which stores an **Access Key ID** and **Secret Access Key** for use by AWS resource handlers that authenticate with an IAM Role ARN. If the password vault feature is enabled, **Secret Access Key** offers **Locally Stored** or **Vault Managed**.

## Add Git Connection Info

The Git form is for HTTP and HTTPS Git URLs, and is used for Terraform plans held in private repositories.

1. Go to **Admin** > **Connection Info**.
1. Select **New Git Connection Info**.
1. Complete the form.
1. Select **Create**.

<div class="alert alert-warning" role="alert">


A Connection Info used for a remote source, such as blueprints and actions, **must** be named **Source Code Repository**. CMP looks up the connection by that exact name, so a different name prevents the remote source from authenticating.
</div>


| Field | Description |
| --- | --- |
| **Name** | Enter **Source Code Repository**. |
| **Host** | The host for the source control connection, in domain format, such as `github.com`. |
| **Protocol** | HTTPS or HTTP, defaulting to HTTPS. SSH Git sources are not supported. |
| **Username** | The username of the source control account. |
| **Auth Token** | A personal access token. Most Git services expect a token rather than a password for third-party apps, and a token is required when two-factor authentication is enabled on the account. See the token documentation for [GitHub](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens), [GitLab](https://docs.gitlab.com/user/profile/personal_access_tokens/), or [Bitbucket](https://confluence.atlassian.com/bitbucketserver/personal-access-tokens-939515499.html). For Azure DevOps, create a [personal access token](https://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate) and use it here in place of a password. If the password vault feature is enabled, this field offers **Locally Stored** or **Vault Managed**. Select **Vault Managed** to read the token from a configured vault provider. |
| **Labels** | For Git-hosted Terraform plans, add the `terraform-plan-source` label. If several Connection Info entries share a host and carry that label, CMP filters further on the protocol; if more than one still matches, it uses the lowest Connection Info ID. |
| **Description** | Optional description text for this Connection Info. |

## Edit Connection Info

1. Go to **Admin** > **Connection Info** and find the entry.
1. In the **Actions** column, select the **edit** icon.

Take care when changing a Name, since some features expect a specific name.

## Delete Connection Info

1. Go to **Admin** > **Connection Info** and find the entry.
1. In the **Actions** column, select the delete icon.
1. Select **Delete** to confirm.

<div class="alert alert-danger" role="alert">


Deleting a Connection Info entry cannot be undone, and anything that authenticates through it stops working.
</div>


## Advanced configuration

Connection Info objects can be used in plugins to securely store credentials or to run scripts against systems that lack a REST API. For more examples, see [Development tips for plugins](/docs/cmp/use/orchestration/plugins/development-tips/).

### Storing credentials in plugins

1. Create a Connection Info object with a recognizable name.
1. In your plugin, look it up by that name:

   ```python
   from utilities.models import ConnectionInfo
   connection_info = ConnectionInfo.objects.get(name='my_connection_info')
   ip = connection_info.ip
   username = connection_info.username
   password = connection_info.password
   ```

## Related

- [Integrate a remote source code repository](/docs/cmp/configure/integrations/source-code-repository/): link a repository through Source Code Repositories.
- [Development tips for plugins](/docs/cmp/use/orchestration/plugins/development-tips/): further examples of reading a Connection Info object from plugin code.
