Config files¶
Tinybird projects use configuration files for two different jobs:
tinybird.config.jsondefines project settings, such as which files to include and whether development runs in Cloud Branches or Tinybird Local..tinybstores local authentication and Workspace context created bytb login.
Commit tinybird.config.json to version control. Don't commit .tinyb because it can contain authentication tokens.
tinybird.config.json¶
Use tinybird.config.json to tell Tinybird where your project resources live. The development mode controls the default build target. Use branch for Cloud Branches or local for Tinybird Local.
tinybird.config.json
{
"dev_mode": "branch",
"include": [
"tinybird"
]
}
For development mode setup, see Local development and Using Cloud Branches.
.tinyb¶
The .tinyb file contains the Tinybird project configuration, including the authentication token obtained by running tb login.
Running commands requires a valid .tinyb file in the root of your project. If you don't have one, create one by running tb login.
Location¶
You can place the .tinyb file in the root of your app repository or keep it together with your Tinybird datafiles. Tinybird looks for the .tinyb file in all parent folders until it reaches the home directory.
If your Tinybird files and folders are located in a subdirectory, such as tinybird/, add a cwd field to specify the relative path to that directory.
File structure¶
The following is a sample .tinyb file:
.tinyb
{
"host": "<tinybird-host>",
"id": "<workspace-id>",
"name": "<workspace-name>",
"scope": "user",
"token": "<authentication-token>",
"tokens": {
"<tinybird-host>": "<authentication-token>",
"<another-tinybird-host>": "<authentication-token>"
},
"cwd": "<optional-path-to-your-tinybird-folder>",
"user_email": "<user-email>",
"user_id": "<user-id>",
"user_token": "<authentication-token>",
"version": "<tinybird-version>"
}