Skip to content

Added script to automate fetching Tinybird tokens#14

Merged
jloh merged 3 commits into
mainfrom
analytics-service-token-updates
Jul 15, 2025
Merged

Added script to automate fetching Tinybird tokens#14
jloh merged 3 commits into
mainfrom
analytics-service-token-updates

Conversation

@cmraible
Copy link
Copy Markdown
Contributor

@cmraible cmraible commented Jul 9, 2025

Currently the setup steps for Tinybird are quite tedious and manual, requiring the user to copy/paste multiple values from the CLI and/or Tinybird Workspace UI.

This commit adds a simple script that grabs these values from the .tinyb file that's generated when authenticating with the tb CLI and from Tinybird's tokens API. The script outputs all the values in a format that's ready to be copy/pasted into a .env file, removing a couple of the more tedious and error prone steps from the setup instructions.

Comment thread compose.yml
@jloh jloh force-pushed the analytics-service-token-updates branch from 138544d to 0bfb32c Compare July 14, 2025 07:20
@jloh
Copy link
Copy Markdown
Member

jloh commented Jul 14, 2025

@cmraible I've taken this for a spin today and it worked really well! I've tweaked it and updated the instructions so that it greatly simplifies the initial setup. Are you able to have a look and see what you think and if you're happy to merge?

Comment thread TINYBIRD.md Outdated
@cmraible cmraible marked this pull request as ready for review July 14, 2025 20:54
@cmraible
Copy link
Copy Markdown
Contributor Author

@jloh LGTM! Left a tiny optional comment based on something new I learned today. Github won't let me approve the PR since I'm the author, but it all looks good (and worked for me) from my end.

@cmraible cmraible changed the title Added experimental script to automate fetching Tinybird tokens Added script to automate fetching Tinybird tokens Jul 14, 2025
cmraible and others added 2 commits July 15, 2025 11:29
no ref

- By outputting the tokens in the format the `.env` file expects this greatly simplifies the initial setup by just makign it copy -> paste able
- This will mean users don't need to load up the UI and copy/paste tokens at all and can do the whole setup (after they've signed up for TB) from the CLI
@jloh jloh force-pushed the analytics-service-token-updates branch from 7c4c1b6 to ebe9c30 Compare July 15, 2025 01:29
no ref

- As Chris notes this isn't actually required when doing the initial setup/mentioning the specific container you want to deploy
- This standardises us in just doing the `--rm run` command for all of them to keep everything nice and neat
@jloh jloh merged commit b76e2a9 into main Jul 15, 2025
1 check passed
@jloh jloh deleted the analytics-service-token-updates branch July 15, 2025 01:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants