How to get bearer token for user
Hi everyone, I want to make a function that pushes Bearer token that can be used for httpsAction auth to GitHub as a secret.
These secrets will be used in a CI/CD pipeline to call a webhook and run a mutation, thus they need to be authenticated.
What I can’t figure is where to actually find/get the bearer token that is used for autentication. I am using Clerk
2 Replies
Thanks for posting in <#1088161997662724167>.
Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets.
- Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.)
- Use search.convex.dev to search Docs, Stack, and Discord all at once.
- Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI.
- Avoid tagging staff unless specifically instructed.
Thank you!
The tokens from Clerk that you get in a user browser session only last for an hour by default, so you may want to use a different kind of token here instead
for clerk it's getToken from a browser
I'd use a public mutation or an http endpoint that accepted a different kind of auth, say a shared secret; add an environment variable to the GitHub CI/CD and add it to the Convex deployment, and compare them.