# Connection configuration

> For the complete documentation index, see [llms.txt](https://developers.thoughtspot.com/docs/llms.txt)

Source: https://developers.thoughtspot.com/docs/connection-config

# Connection configuration

ThoughtSpot supports multiple configurations per connection feature allowing developers to define and manage several distinct connection configurations under a single data connection object in ThoughtSpot. This is currently supported for Snowflake, Databricks, and BigQuery.

## Connection Configuration APIs

The connection configuration API endpoints allow you to create, edit, delete, and search connection configuration for an existing data connection on a ThoughtSpot instance.

### Required permissions

You must have data management permissions to create, search, update, and delete connection configuration objects. Make sure your user account has the `DATAMANAGEMENT` privilege.

If [Role-Based Access Control (RBAC)]({{navprefix}}/{{roles}}) is enabled on your ThoughtSpot cluster, the `CAN_CREATE_OR_EDIT_CONNECTIONS` **(Can create/edit Connections)** privilege is required.

### Create connection configuration

To create a connection configuration to an existing data connection object in ThoughtSpot, send a `POST` request to the `POST /api/rest/2.0/connection-configurations/create` API endpoint.

#### Request parameters

In your `POST` request body, include the following parameters:

 
| Parameter | Description |
| --- | --- |
| 
`name`

 | 

_String_. Required. Name of the connection configuration.





 |
| 

`description`

 | 

_String_. Optional. Description of the connection configuration.





 |
| 

`connection_identifier`

 | 

_String_. Required. Unique ID of the connection for which the configuration will be created.





 |
| 

`authentication_type`

 | 

_String_. Optional. Type of authentication used for the connection. Default value is `SERVICE_ACCOUNT`.





 |
| 

`configuration`

 | 

_String_. Required. A JSON map of the connection configuration attributes. For example,  
"configuration": {"accountName":"DEMO\_SNOWFLAKE","user":"DEMO\_USER","password":"Password@1234","role":"DEMO\_ROLE","warehouse":"DEV\_WH"},





 |
| 

`policy_type`

 | 

_String_. Optional. Policy type in connection configuration APIs determines how a specific configuration is assigned and used. Default value is `NO_POLICY`. The main policy types are:

-   **NO\_POLICY:** The configuration is saved but not assigned to any users, groups, or processes.  
    
-   **PRINCIPALS:** The configuration is assigned to specific users and groups, allowing only them to use this configuration.  
    
-   **PROCESSES:** The configuration is assigned for use by specific processes, such as search indexing or row count statistics jobs.
    





 |
| 

`policy_principals`

 | 

_String_. Required when the `policy_type` is `PRINCIPALS`. The users or groups which can access and use the connection for querying data. A sample value for this could be,  
"policy\_principals": \[ "testuser", "98617aac-9643-4e94-a2d7-8e4b2c8e8175" \]





 |
| 

`policy_processes`

 | 

_String_. Required when the `policy_type` is `PROCESSES`. Processes which can use the connection. Valid values include:  

-   `SAGE_INDEXING`
    
-   `ROW_COUNT_STATS`
    
-   `SCHEDULED_LIVEBOARDS`
    





 |

### Search a connection configuration

To create a connection configuration to an existing data connection object in ThoughtSpot, send a `POST` request to the `POST /api/rest/2.0/connection-configurations/search` API endpoint.

#### Request parameters

In your `POST` request body, include the following parameters:

 
| Parameter | Description |
| --- | --- |
| 
`connection_identifier`

 | 

_String_. Required. Unique ID of the connection. To get a list of all configurations available in the ThoughtSpot system, send the API request with only the connection name or GUID in the request body.





 |
| 

`configuration_identifier`

 | 

_String_. Optional. Unique ID of the configuration. Specify the configuration object name or GUID to fetch the details for it.





 |
| 

`policy_type`

 | 

_String_. Optional. The type of policy associated with the configuration object.





 |

### Update a connection configuration

To update an existing connection configuration in ThoughtSpot, send a `POST` request to the `POST /api/rest/2.0/connection-configurations/{configuration_identifier}/update` API endpoint.

#### Request parameters

In your `POST` request body, include the following parameters:

 
| Parameter | Description |
| --- | --- |
| 
`configuration_identifier`

 | 

_String_. Required. Unique ID of the configuration to be updated.





 |
| 

`connection_identifier`

 | 

_String_. Required. Unique ID of the connection object.





 |
| 

`name`

 | 

_String_. Optional. The name of the configuration.





 |
| 

`description`

 | 

_String_. Optional. The description for the configuration.





 |
| 

`authentication_type`

 | 

_String_. Optional. Type of authentication used for the connection.





 |
| 

`policy_type`

 | 

_String_. Optional. The type of policy associated with the configuration object.





 |
| 

`disable`

 | 

_Boolean_. Optional. Indicates whether a configuration is enabled or disabled.





 |
| 

`policy_principals`

 | 

_String_. Required when the `policy_type` is `PRINCIPALS`.





 |
| 

`policy_processes`

 | 

_String_. Required when the `policy_type` is `PROCESSES`.





 |

### Delete connection configuration

To delete an existing connection configuration from ThoughtSpot, send a `POST` request to the `POST /api/rest/2.0/connection-configurations/delete` API endpoint.

#### Request parameters

In your `POST` request body, include the following parameters:

 
| Parameter | Description |
| --- | --- |
| 
`configuration_identifier`

 | 

_String_. Required. Unique ID of the configuration to be deleted.





 |
| 

`connection_identifier`

 | 

_String_. Required. Unique ID of the connection object for the configuration to be deleted.





 |

## Additional Resources

-   [Connections]({{navprefix}}/{{connections}})
    
-   [REST APIs v2]({{navprefix}}/{{rest-api-v2-reference}})