New ACM paper, free-tier cloud, and open-source license

Connect to server

This guide covers connecting to TypeDB Cloud or TypeDB Core servers with Studio, Console, or one of the drivers.

Understanding connections

TypeDB uses a gRPC-based protocol for external communications, including queries. TypeDB clients, like Studio and Console, as well as language-specific drivers with native APIs, have been developed to implement this protocol.

Connect to TypeDB Core

A network connection to TypeDB Core requires the address and port of the server to connect to.

  • Studio

  • Console

Run Studio and follow instructions below:

  1. Click Connect to TypeDB on the right side of the top toolbar.

  2. Make sure the TypeDB Core option is selected in the Server field.

  3. Enter the address and port of the server to connect to (e.g., localhost:1729).

  4. Click Connect.

Run Console using the --core argument to set the address and port to connect to:

Connect to TypeDB Core
$ typedb console --core=<server-address>

The --core argument is used to set the TypeDB Core server IP address and port to connect to, for example, 10.0.0.5:1729.

For programmatic access, use one of the TypeDB drivers via native API:

  • Rust

  • Python

  • Java

  • Node.js

  • C++

Connect to TypeDB Core
let driver = Connection::new_core("127.0.0.1:1729")?;

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Core
driver = TypeDB.core_driver("127.0.0.1:1729")

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Core
TypeDBDriver driver = TypeDB.coreDriver("127.0.0.1:1729");

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Core
let coreDriver = await TypeDB.coreDriver("127.0.0.1:1729");

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Core
TypeDB::Driver driver = TypeDB::Driver::coreDriver("127.0.0.1:1729");

Where 127.0.0.1:1729 is the address and port to connect to.

After connecting to TypeDB Core, see how to create a database and manage sessions and transactions.

Connect to TypeDB Cloud

A network connection to a TypeDB Cloud cluster requires address and port of at least one server in the cluster, as well as username and password of a user.

For your first connection, use the following default user credentials:

  • Username: admin

  • Password: password

Make sure to change the password for the admin account on your first login. A TypeDB Cloud deployment will deny all other operations until the password is changed from its default value.

  • Studio

  • Console

Run Studio and follow instructions below:

  1. Click Connect to TypeDB on the right side of the top toolbar.

  2. Switch the Server field drop-down to TypeDB Cloud.

  3. Click Manage Cloud Addresses button.

  4. Add address and port for at least one server from your TypeDB Cloud deployment. Close the Address management window.

  5. Fill in the Username and Password fields with valid user credentials.

  6. Turn on the Enable TLS option and leave the CA Certificate field empty.
    For self-hosted deployments, encryption parameters may vary.

  7. Click Connect.

On your first login you will be asked to change the password for the admin account. A TypeDB Cloud deployment will refuse queries until the password is changed from its default value.

Run TypeDB Console using the --cloud argument to set a list of addresses and ports to connect to:

Connect to TypeDB Cloud
$ typedb console --cloud=<server-address> --username=<username> --password --tls-enabled=true

You will be prompted for a password.

On your first login, change the password for the admin account. A TypeDB Cloud deployment will refuse queries until the password is changed from its default value.

For programmatic access, use one of the TypeDB drivers via native API:

Drivers
  • Rust

  • Python

  • Java

  • Node.js

  • C++

Connect to TypeDB Cloud
let driver = Connection::new_cloud(&["127.0.0.1:1729"], Credential::with_tls("admin", "password", None)?)?;

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Cloud
driver = TypeDB.cloud_driver("127.0.0.1:1729", TypeDBCredential("admin", "password", tls_enabled=True))

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Cloud
TypeDBDriver driver = TypeDB.cloudDriver("127.0.0.1:1729", new TypeDBCredential("admin", "password", true ));

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Cloud
let cloudDriver = await TypeDB.cloudDriver("127.0.0.1:1729", new TypeDBCredential("admin","password"));

Where 127.0.0.1:1729 is the address and port to connect to.

Connect to TypeDB Cloud
TypeDB::Driver driver = TypeDB::Driver::cloudDriver({"127.0.0.1:1729"}, TypeDB::Credential("admin", "password", true));

Where 127.0.0.1:1729 is the address and port to connect to.

Learn more

See how to create a new database in TypeDB.

See how to manage sessions in TypeDB.

Provide Feedback