How to Manage Connection Details for Vultr Managed Database for Valkey

Updated on 28 August, 2025

Managed database connection details consist of host, port, username, password, default database, connection strings, and SSL certificates. These credentials allow you to connect to the managed databases from your favorite database client or modern programming language libraries. These include redis-cli, the Redis® command line interface, Redis® Python library (redis-py), Redis® Go client (go-redis), and Redis® client library for PHP (PhpRedis).

Follow this guide to manage connection details for Vultr Managed Database for Valkey using the Vultr Customer Portal, API, CLI, or Terraform.

  • Vultr Customer Portal
  • Vultr API
  • Vultr CLI
  • Terraform
  1. Navigate to Products and select Databases.
  2. Click the target database instance.
  3. Navigate to Connection Details under Overview.
  4. Click Copy Connection String.
  5. Click Copy URL.
  6. Click Download Signed Certificate.
  1. List all the database instances by sending a GET request to the List Managed Databases endpoint and note the database ID. For example, 43b4c774-5dff-4ac0-a01f-78a23c2205b5.

    console
    $ curl "https://api.vultr.com/v2/databases" \
        -X GET \
        -H "Authorization: Bearer ${VULTR_API_KEY}"
    
  2. Send a GET request to the Get Managed Database endpoint and specify a database ID.

    console
    $ curl "https://api.vultr.com/v2/databases/database_id" \
        -X GET \
        -H "Authorization: Bearer ${VULTR_API_KEY}"
    

    Visit the Get Managed Database endpoint to view additional attributes to add to your request.

  3. Copy the host, port, user, and password values.

  1. List all database instances and note the database ID. For instance, d6ac2a3c-92ea-43ef-8185-71a23e58ad8c.

    console
    $ vultr-cli database list --summarize
    
  2. Retrieve connection details by specifying the database ID.

    console
    $ vultr-cli database get database_id
    

    Run vultr-cli database get --help to view all options.

  1. If you manage the database with Terraform, you can output connection details from the resource.

    terraform
    # Assuming a managed database resource exists
    resource "vultr_database" "valkey" {
        database_engine         = "valkey"
        database_engine_version = "7"
        region                  = "jnb"
        plan                    = "vultr-dbaas-startup-occ-mo-2-26-16"
        label                   = "valkey-db-1"
    }
    
    output "valkey_host" { value = vultr_database.valkey.host }
    output "valkey_port" { value = vultr_database.valkey.port }
    output "valkey_user" { value = vultr_database.valkey.user }
    # output "valkey_password" { value = vultr_database.valkey.password  sensitive = true }
    
  2. Apply the configuration and view the outputs with terraform output.

Comments

No comments yet.