Quickstart
This guide walks you through registering a MySQL database, provisioning a ReflexDB instance, creating an API key, and running your first query.
-
Create an account
Sign up at app.reflexdb.cloud. Accept the Terms of Service on first login.
-
Register a database
From the dashboard, click New Connection, then New Database and fill in your MySQL connection details:
Field Description Host Hostname or IP of your database server Port Default 3306(MySQL),5432(PostgreSQL),1433(SQL Server)Database The database name to replicate User Database user (needs SELECTprivilege; CDC modes require additional grants — see below)Password Stored encrypted at rest — never written to the database Sync mode CDC mode (recommended) or pollfor periodic full reload -
Upload a schema config (optional)
By default, ReflexDB includes all tables. To include only specific tables or columns, upload a
reflexdb.yaml:version: 1tables:- name: userscolumns: [id, name, email, created_at]- name: postscolumns: [id, user_id, title, body, published_at]relations:include: [author]See the Schema Config reference for the full format.
-
Provision an instance
Click Provision on the database card. ReflexDB will:
- Compile a query engine for your schema (~3–5 min)
- Deploy a dedicated instance and register a
<id>.reflexdb.cloudsubdomain with TLS
The status progresses:
registered → building → deploying → running. -
Create an API key
Once the instance is
running, open the API Keys tab and click New Key. Copy the key — it’s shown only once.rxk_a1b2c3.aBcDeFgHiJkLmNoPqRsTuVwXyZ... -
Make your first query
Send a
POST /queryrequest to your instance endpoint:Terminal window curl https://<instance-id>.reflexdb.cloud/query \-H "Authorization: Bearer rxk_a1b2c3.aBcDeFgHiJkLmNoPqRsTuVwXyZ..." \-d 'users { id name email }'Response:
{"data": [{ "id": 1, "name": "Alice", "email": "alice@example.com" },{ "id": 2, "name": "Bob", "email": "bob@example.com" }],"meta": {"table": "users","query": { "fields": ["id", "name", "email"] },"pagination": { "count": 2, "total_matched": 2, "has_more": false },"timing_ms": 0.42}}
SSH tunnel setup
Section titled “SSH tunnel setup”If your MySQL server is not publicly accessible (e.g. in a private VPC or behind a firewall), ReflexDB can connect through an SSH bastion host.
Enable SSH in the connection form
Section titled “Enable SSH in the connection form”When registering a connection, expand the SSH tunnel section and fill in:
| Field | Description |
|---|---|
| Bastion host | Hostname or IP of your SSH jump host |
| Bastion port | Default 22 |
| SSH user | Username on the bastion host |
| Private key | RSA, Ed25519, or ECDSA key in OpenSSH format |
ReflexDB stores the private key encrypted at rest. The tunnel is established before each MySQL connection attempt — your database host and port are resolved from inside the bastion.
Key format requirements
Section titled “Key format requirements”- Format: OpenSSH PEM (generated with
ssh-keygen -t ed25519orssh-keygen -t rsa -b 4096) - Passphrase: not supported — generate without a passphrase or strip it with
ssh-keygen -p - Permissions: the bastion user must be able to open a TCP connection to the MySQL host on port 3306
Testing connectivity
Section titled “Testing connectivity”Use Test Connection on the connection card to verify the tunnel and MySQL credentials before provisioning. The test runs against your live database and reports any connection or authentication errors.
For troubleshooting, see the SSH tunnel runbook.
Next steps
Section titled “Next steps”- Query API reference — filters, aggregations, pagination, nested relations
- Schema Config reference — control exactly what’s included in your schema
- Sync Modes — CDC vs poll, batch windows, reconnect behaviour, freshness safety net
- Control Plane API — automate everything with management API keys
- Runbooks — operational guides for resizing, migration, and troubleshooting