DB Connections¶
Database connections of a project. The API reads them, without connection properties or secrets; create and change them in the dashboard. Authentication, pagination and errors are described in the Overview.
| Method | Path | Description |
|---|---|---|
GET | /v1/db-connections | List db connections |
GET | /v1/db-connections/{db_connection_id} | Get a db connection |
List db connections¶
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
limit | query | integer | No | Maximum number of rows to return (default: 200, max: 5000) |
Responses
| Status | Description | Body |
|---|---|---|
200 | List db connections | array of DbConnection |
400 | Invalid limit | ApiError |
401 | Not authenticated | ApiError |
500 | Internal error | ApiError |
Example
curl -X GET 'https://digna.example.com/v1/db-connections' \
-H "Authorization: Bearer $DIGNA_API_KEY"
Get a db connection¶
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
db_connection_id | path | integer | Yes | Db connection ID |
Responses
| Status | Description | Body |
|---|---|---|
200 | Get a db connection | DbConnection |
401 | Not authenticated | ApiError |
404 | Db connection not found | ApiError |
500 | Internal error | ApiError |
Example
curl -X GET 'https://digna.example.com/v1/db-connections/<db_connection_id>' \
-H "Authorization: Bearer $DIGNA_API_KEY"
Schemas¶
ApiError¶
| Field | Type | Required | Description |
|---|---|---|---|
code | ApiErrorCode | Yes | |
message | string | Yes |
DbConnection¶
| Field | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | |
name | string | Yes | |
profiling_location | StableProfilingLocation | Yes | |
profiling_mode | StableDbConnectionProfilingMode | Yes | |
technology | StableDbConnectionTechnology | Yes | |
work_schema | string | Yes |
ApiErrorCode¶
One of: INTERNAL_ERROR, INVALID_CREDENTIALS, NOT_FOUND, NOT_AUTHENTICATED, NOT_AUTHORIZED, INVALID_LICENSE, BAD_REQUEST.
StableProfilingLocation¶
One of: source-database, digna-engine.
StableDbConnectionProfilingMode¶
One of: permanent, session, standard.
StableDbConnectionTechnology¶
One of: hive, postgres, oracle, sqlserver, databricks, teradata, netezza, snowflake, impala.