Test Connection Configuration

Version 4.0.24.6 (latest)

Test a connection configuration.

Note that a connection's 'dialect' property has a 'connection_tests' property that lists the specific types of tests that the connection supports.

This API is rate limited.

Unsupported tests in the request will be ignored.

Request

PUT /connections/test
Datatype
Description
Request
HTTP Request
body
HTTP Body
Expand HTTP Body definition...
body
Connection
Expand DBConnection definition...
can
object
Operations the current user is able to perform on this object
name
string
Name of the connection. Also used as the unique identifier
dialect
(Read-only) SQL Dialect details
snippets
pdts_enabled
boolean
True if PDTs are enabled on this connection
host
string
Host name/address of server; or the string 'localhost' in case of a connection over an SSH tunnel.
port
string
Port number on server. If the connection is over an SSH tunnel, then the local port associated with the SSH tunnel.
username
string
Username for server authentication
password
string
(Write-Only) Password for server authentication
uses_oauth
boolean
Whether the connection uses OAuth for authentication.
certificate
string
(Write-Only) Base64 encoded Certificate body for server authentication (when appropriate for dialect).
file_type
string
(Write-Only) Certificate keyfile type - .json or .p12
database
string
Database name
db_timezone
string
Time zone of database
query_timezone
string
Timezone to use in queries
schema
string
Schema name
max_connections
integer
Maximum number of concurrent connection to use
max_billing_gigabytes
string
Maximum size of query in GBs (BigQuery only, can be a user_attribute name)
ssl
boolean
Use SSL/TLS when connecting to server
verify_ssl
boolean
Verify the SSL
tmp_db_name
string
Name of temporary database (if used)
jdbc_additional_params
string
Additional params to add to JDBC connection string
pool_timeout
integer
Connection Pool Timeout, in seconds
dialect_name
string
(Read/Write) SQL Dialect name
supports_data_studio_link
boolean
Database connection has the ability to support open data studio from explore
created_at
string
Creation date for this connection
user_id
string
Id of user who last modified this connection configuration
example
boolean
Is this an example connection?
user_db_credentials
boolean
(Limited access feature) Are per user db credentials enabled. Enabling will remove previously set username and password
user_attribute_fields
string[]
maintenance_cron
string
Cron string specifying when maintenance such as PDT trigger checks and drops should be performed
last_regen_at
string
Unix timestamp at start of last completed PDT trigger check process
last_reap_at
string
Unix timestamp at start of last completed PDT reap process
sql_runner_precache_tables
boolean
Precache tables in the SQL Runner
sql_writing_with_info_schema
boolean
Fetch Information Schema For SQL Writing
after_connect_statements
string
SQL statements (semicolon separated) to issue after connecting to the database. Requires `custom_after_connect_statements` license feature
pdt_context_override
db_connection_override for this connection in the `pdt` maintenance context
managed
boolean
Is this connection created and managed by Looker
custom_local_port
integer
This field is only applicable to connections over an SSH Tunnel. The value of this field would be the local port associated with the SSH tunnel if configured manually. Otherwise either enter NULL or exclude this field.
tunnel_id
string
The Id of the ssh tunnel this connection uses
uses_tns
boolean
Enable Transparent Network Substrate (TNS) connections
pdt_concurrency
integer
Maximum number of threads to use to build PDTs in parallel
disable_context_comment
boolean
When disable_context_comment is true comment will not be added to SQL
oauth_application_id
string
An External OAuth Application to use for authenticating to the database
always_retry_failed_builds
boolean
When true, error PDTs will be retried every regenerator cycle
cost_estimate_enabled
boolean
When true, query cost estimate will be displayed in explore.
pdt_api_control_enabled
boolean
PDT builds on this connection can be kicked off and cancelled via API.
query
HTTP Query
Expand HTTP Query definition...
tests
string[]

Response

200: Test results

Datatype
Description
can
object
Operations the current user is able to perform on this object
connection_string
string
JDBC connection string. (only populated in the 'connect' test)
message
string
Result message of test
name
string
Name of test
status
string
Result code of test

400: Bad Request

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link

404: Not Found

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link

429: Too Many Requests

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link