Data sources
A data source is a saved connection to a database. You create it once, then pick it when you create a project: the API reads from and writes to that database.
The same data source can be used by several projects. You can also create one directly from the project wizard, with Add New Source (see Create a project).
Supported databases
| Family | Database | Connection |
|---|---|---|
| Relational (SQL) | MySQL, MariaDB, PostgreSQL, SQL Server | Host, port, database |
| Document (NoSQL) | MongoDB | Free database, host and port, or URI |
| Document (NoSQL) | Elasticsearch | Host, port, database |
| Document (NoSQL) | Couchbase | Host, bucket |
| Document (NoSQL) | BigQuery | Google account or service account file |
The data source list
In the left menu, click Data sources. Each data source is shown as a card with its name, its Type (the database engine) and its Last update date.
To find a data source:
- type part of its name in Search Datasource ...;
- filter by engine with All types;
- sort by Creation date, Update date, Name (A-Z) or Grouped by type.
Reset filters clears the list filters. Data sources are shown 9 per page.
Click a card, or View, to open the data source's detail page.
Create a data source
Click New Data Source. The wizard has four steps.
1. Select Database Type
Choose the database family: the "Relational (SQL)" card or the "Document (NoSQL)" card. Click Next.
2. Select provider
Click the card of your database, then Next.
For MongoDB, also choose the Connection Mode:
| Mode | Use |
|---|---|
| Free | Grizzly creates and hosts a MongoDB database for you. Ideal to get started. |
| On-Premise | You connect to your own MongoDB server with its host and port. |
| Cloud | You connect with a connection URI, for example the one from MongoDB Atlas. |
3. Fill connection
The fields depend on the database you chose.
MySQL, MariaDB, PostgreSQL, SQL Server, Elasticsearch, MongoDB (On-Premise)
- Connection Name: letters, numbers,
_and-, no spaces. - Database: the name of the database to use.
- Host: the server address, for example
db.example.com. - Port: pre-filled with the default port (3306 for MySQL and MariaDB, 5432 for PostgreSQL, 1433 for SQL Server, 27017 for MongoDB). For Elasticsearch, type it in.
- Perform Authentication: turn this on if the database requires credentials, then fill in the Username and Password. For MongoDB, also fill in the Authentication Database (
adminby default).
Couchbase
- Connection Name: letters, numbers,
_and-, no spaces. - Database: not used by Couchbase, repeat the bucket name.
- Host: the cluster address, without a port. For Couchbase Capella, copy the connection string from the Connect tab, for example
couchbases://cb.xxxx.cloud.couchbase.com. - Bucket Name: the bucket to use.
- Perform Authentication: fill in the Username and Password of a cluster access. On Capella, create it in Settings > Access Control with read and write rights on the bucket, and allow your IP address in Settings > Allowed IP Addresses.
MongoDB (Cloud): fill in the data source name and the connection URI.
MongoDB (Free): just give the data source a name. Grizzly creates the database.
BigQuery: choose the authentication mode.
- Google Account: click Google Connection and allow access to BigQuery.
- Service Account: click File Upload and select the JSON key file of your Google Cloud service account.
Then choose the project (Choose Your Project) and the dataset (Choose Your Dataset). The data source takes the dataset's name.
Test before saving
Click Test connection to check the parameters. Grizzly shows Connection Succeeded ! or a failure message. The test is optional, but it keeps you from saving a connection that doesn't work.
Click Next.
4. Review
Check the summary: name, connection endpoint, engine, authentication method, connection mode and Test Status (Verified, Failed or Not tested). Passwords are not shown.
Click Save, or Create Database for a free MongoDB database. The data source appears in the list.
Unique name
A data source name must be unique. Otherwise, the message "Datasource name is not unique!" is shown: go back and change the name.
Free plan limit
With the free plan (Community or Self-hosted), you can create up to 3 data sources (see Manage your projects). Beyond that, New Data Source opens the "You've reached the limit for creating datasources" window instead of the wizard. Delete a data source you no longer need, or contact us at contact@grizzly-api.com to move to the Pro plan.
View a data source
A data source's detail page shows:
- its status, Connected or not;
- the Exposed Tables: the tables or collections found in the database;
- the Connection Details: host, port, user and database name (or the dataset for BigQuery).
For a MongoDB data source, the Upload CSV button loads a CSV file into a collection:
- Choose the collection, or click Add to create one.
- Check the data replacement option if you want to replace the collection's content with the file's content.
- Pick the file's separator (comma or semicolon), choose the file, then click Confirm.
Edit a data source
On the card, click ⋮, or click Edit on the detail page. The wizard opens with the current settings: change what you need, test the connection, then click Save at the Review step.
Delete a data source
- On the data source's card, in the list, click the trash icon.
- In the Delete data source window, click Confirm.
Before deleting
- Projects that use this data source lose access to their database: their endpoints can no longer read or write the data.
- For a Free MongoDB database, the database hosted by Grizzly is deleted with all its data.
Let Grizzly reach your database
Grizzly connects to your database from its own servers, not from your computer. If the connection test fails:
- use an address that can be reached from the Internet, not
localhostor a private network address; - check that your firewall or your host's network rules allow incoming connections on the database port;
- check that the user has access rights on the database you entered.
Self-hosted edition
If Grizzly is installed on your servers, the database must be reachable from the server where Grizzly runs.
What's next?
- Create a project on your data source.
- Add endpoints to expose your tables and collections.
- Let the AI agent generate a complete API.
