/*!
@page sql-override-authentication How to Override the Authentication Credentials

Unless otherwise configured, the client libraries use
[Application Default Credentials] to authenticate with Google Cloud Services.
While this works for most applications, in some cases you may need to override
this default. You can do so by providing the
[UnifiedCredentialsOption](@ref google::cloud::UnifiedCredentialsOption)
The following example shows how to explicitly load a service account key file:

<!-- inject-service-account-snippet-start -->
@snippet sql_available_database_versions_client_samples.cc with-service-account

Follow these links to find examples for other \c *Client classes:

- [\c sql_v1::SqlAvailableDatabaseVersionsServiceClient](@ref sql_v1::SqlAvailableDatabaseVersionsServiceClient-service-account-snippet)
- [\c sql_v1::SqlBackupRunsServiceClient](@ref sql_v1::SqlBackupRunsServiceClient-service-account-snippet)
- [\c sql_v1::SqlConnectServiceClient](@ref sql_v1::SqlConnectServiceClient-service-account-snippet)
- [\c sql_v1::SqlDatabasesServiceClient](@ref sql_v1::SqlDatabasesServiceClient-service-account-snippet)
- [\c sql_v1::SqlEventsServiceClient](@ref sql_v1::SqlEventsServiceClient-service-account-snippet)
- [\c sql_v1::SqlFlagsServiceClient](@ref sql_v1::SqlFlagsServiceClient-service-account-snippet)
- [\c sql_v1::SqlIamPoliciesServiceClient](@ref sql_v1::SqlIamPoliciesServiceClient-service-account-snippet)
- [\c sql_v1::SqlInstanceNamesServiceClient](@ref sql_v1::SqlInstanceNamesServiceClient-service-account-snippet)
- [\c sql_v1::SqlInstancesServiceClient](@ref sql_v1::SqlInstancesServiceClient-service-account-snippet)
- [\c sql_v1::SqlOperationsServiceClient](@ref sql_v1::SqlOperationsServiceClient-service-account-snippet)
- [\c sql_v1::SqlRegionsServiceClient](@ref sql_v1::SqlRegionsServiceClient-service-account-snippet)
- [\c sql_v1::SqlSslCertsServiceClient](@ref sql_v1::SqlSslCertsServiceClient-service-account-snippet)
- [\c sql_v1::SqlTiersServiceClient](@ref sql_v1::SqlTiersServiceClient-service-account-snippet)
- [\c sql_v1::SqlUsersServiceClient](@ref sql_v1::SqlUsersServiceClient-service-account-snippet)

<!-- inject-service-account-snippet-end -->

Keep in mind that we chose this as an example because it is relatively easy to
understand. Consult the [Best practices for managing service account keys]
guide for more details.

@see @ref guac - for more information on the factory functions to create
`google::cloud::Credentials` objects.

[Best practices for managing service account keys]: https://cloud.google.com/iam/docs/best-practices-for-managing-service-account-keys
[Application Default Credentials]: https://cloud.google.com/docs/authentication#adc

*/

// <!-- inject-authentication-pages-start -->

/*! @page sql_v1::SqlAvailableDatabaseVersionsServiceClient-service-account-snippet Override sql_v1::SqlAvailableDatabaseVersionsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_available_database_versions_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlBackupRunsServiceClient-service-account-snippet Override sql_v1::SqlBackupRunsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_backup_runs_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlConnectServiceClient-service-account-snippet Override sql_v1::SqlConnectServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_connect_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlDatabasesServiceClient-service-account-snippet Override sql_v1::SqlDatabasesServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_databases_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlEventsServiceClient-service-account-snippet Override sql_v1::SqlEventsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_events_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlFlagsServiceClient-service-account-snippet Override sql_v1::SqlFlagsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_flags_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlIamPoliciesServiceClient-service-account-snippet Override sql_v1::SqlIamPoliciesServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_iam_policies_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlInstanceNamesServiceClient-service-account-snippet Override sql_v1::SqlInstanceNamesServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_instance_names_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlInstancesServiceClient-service-account-snippet Override sql_v1::SqlInstancesServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_instances_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlOperationsServiceClient-service-account-snippet Override sql_v1::SqlOperationsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_operations_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlRegionsServiceClient-service-account-snippet Override sql_v1::SqlRegionsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_regions_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlSslCertsServiceClient-service-account-snippet Override sql_v1::SqlSslCertsServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_ssl_certs_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlTiersServiceClient-service-account-snippet Override sql_v1::SqlTiersServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_tiers_client_samples.cc with-service-account

*/

/*! @page sql_v1::SqlUsersServiceClient-service-account-snippet Override sql_v1::SqlUsersServiceClient Authentication Defaults

@snippet google/cloud/sql/v1/samples/sql_users_client_samples.cc with-service-account

*/
// <!-- inject-authentication-pages-end -->
