Get started with Tinybird¶
Tinybird gives you the tooling and infrastructure you need to ship analytics features in your application:
- An OLAP database
- An API gateway
- A real-time ingestion system
- An auth system
- Tooling to build, iterate, and deploy data projects
See Core concepts for an overview of Tinybird.
Follow these steps to install Tinybird Local and deploy your first data project to Tinybird Cloud.
Before you begin¶
To get started, you need the following:
- A free Tinybird account
- A container runtime, like Docker or Orbstack
- Linux or macOS
Quick start¶
Install and authenticate¶
To install the Tinybird CLI, run the following command:
curl -LsSf https://tbrd.co/fwd | sh
Then, authenticate with your Tinybird account using tb login
:
# Opens a browser window so that you can authenticate tb login
In the browser, create a new workspace or select an existing one.
GCP europe-west2 is currently the only region supported.
Run Tinybird Local¶
After you've authenticated, run tb local start
to start the Tinybird Local container.
# Start the container tb local start
See Local container for more information on the container.
Create a project¶
Pass an LLM prompt using the --prompt
flag to generate a customized starter project. For example:
tb create --prompt "I am developing the insights page for my app. I am tracking their usage and \ want to show them a line chart and a widget with the total amount of actions they did with time \ range filters. It is a multitenant app, so organization id is a required param for all endpoints"
The previous prompt creates a project with a structure like the following:
. ├── copies ├── datasources │ └── user_actions.datasource ├── endpoints │ ├── user_action_insights_line_chart.pipe │ └── user_action_insights_widget.pipe ├── fixtures ├── materializations ├── sinks └── tests
Generate test data¶
Generate some test data by running tb mock
with the name of the data source you want to test. For example:
tb mock user_actions
This creates fixture data in the fixtures
directory that you can use to test your project.
Build your project¶
Run tb dev
to build your project and watch for changes. Building your project ensures that your datafiles are valid and are ready for deployment.
tb dev
When you finish developing, you can exit the tb dev
session.
Deploy to Tinybird Cloud¶
Deploying a project validates and pushes the data project to your local or cloud environment.
To deploy to Tinybird Cloud, create a deployment using the --cloud
flag. This prepares all the resources in the cloud environment.
# Prepares all resources in Tinybird Cloud tb --cloud deploy
You can now access your new project in Tinybird Cloud. To view your deployment, go to Deployments.
You can also deploy to Tinybird Local by running tb deploy
without the --cloud
flag.
Next steps¶
- Familiarize yourself with Tinybird concepts. See Core concepts.
- Learn about datafiles, like .datasource and .pipe files. See Datafiles.
- Get data into Tinybird from a variety of sources. See Get data in.
- Browse the Tinybird CLI commands reference. See Commands reference.