ConnectionsOperations Class
Warning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
<xref:connections> attribute.
Constructor
ConnectionsOperations(*args, **kwargs)
Methods
get |
Get a connection by name. |
get_default |
Get the default connection for a given connection type. |
list |
List all connections in the project, without populating connection credentials. |
get
Get a connection by name.
get(name: str, *, include_credentials: bool | None = False, **kwargs: Any) -> Connection
Parameters
Name | Description |
---|---|
name
Required
|
The name of the connection. Required. |
Keyword-Only Parameters
Name | Description |
---|---|
include_credentials
|
Whether to include credentials in the response. Default is False. Default value: False
|
Returns
Type | Description |
---|---|
Connection. The Connection is compatible with MutableMapping |
Exceptions
Type | Description |
---|---|
get_default
Get the default connection for a given connection type.
get_default(connection_type: str | ConnectionType, *, include_credentials: bool | None = False, **kwargs: Any) -> Connection
Parameters
Name | Description |
---|---|
connection_type
Required
|
The type of the connection. Required. |
Keyword-Only Parameters
Name | Description |
---|---|
include_credentials
|
Whether to include credentials in the response. Default is False. Default value: False
|
Returns
Type | Description |
---|---|
Connection. The Connection is compatible with MutableMapping |
Exceptions
Type | Description |
---|---|
If no default connection is found for the given type. |
|
list
List all connections in the project, without populating connection credentials.
list(*, connection_type: str | ConnectionType | None = None, default_connection: bool | None = None, **kwargs: Any) -> Iterable[Connection]
Keyword-Only Parameters
Name | Description |
---|---|
connection_type
|
List connections of this specific type. Known values are: "AzureOpenAI", "AzureBlob", "AzureStorageAccount", "CognitiveSearch", "CosmosDB", "ApiKey", "AppConfig", "AppInsights", and "CustomKeys". Default value is None. Default value: None
|
default_connection
|
List connections that are default connections. Default value is None. Default value: None
|
Returns
Type | Description |
---|---|
An iterator like instance of Connection |
Exceptions
Type | Description |
---|---|