Tokens¶
Tinybird uses tokens to authenticate CLI and API requests. Tokens protect access to your resources. Any operation to manage your resources using the CLI or REST API requires a valid token with the necessary permissions.
There are two types of tokens:
- Static tokens: Use them to perform operations on your account, like importing data, creating data sources, or publishing APIs using the CLI or REST API. Use them to read data as well, just be mindful of their permanent nature.
- JSON Web tokens: Use them to read from published endpoints that expose your data to an application, when you want to implement filtering per user via fixed parameters (RBAC) or to apply rate limiting for different end users of Tinybird endpoints.
Authenticate from local¶
When working with Tinybird Local, you can authenticate by running tb login
. For example:
tb login
The command opens a browser window where you can sign in. See tb login.
Credentials are stored in the .tinyb
file. See .tinyb file.