workers builds can't access Secrets?

title here's the error in the log:
12:59:25.473
12:59:25.474 ✘ [ERROR] A request to the Cloudflare API (/accounts/**account id**/workers/scripts/fry-api/versions) failed.
12:59:25.474
12:59:25.474 failed to fetch secrets store binding due to authorization error - check deploy permissions and secret scopes [code: 10021]
12:59:25.475
12:59:25.475 If you think this is a bug, please open an issue at: https://github.com/cloudflare/workers-sdk/issues/new/choose
12:59:25.475
12:59:25.475
12:59:25.475
12:59:25.473
12:59:25.474 ✘ [ERROR] A request to the Cloudflare API (/accounts/**account id**/workers/scripts/fry-api/versions) failed.
12:59:25.474
12:59:25.474 failed to fetch secrets store binding due to authorization error - check deploy permissions and secret scopes [code: 10021]
12:59:25.475
12:59:25.475 If you think this is a bug, please open an issue at: https://github.com/cloudflare/workers-sdk/issues/new/choose
12:59:25.475
12:59:25.475
12:59:25.475
3 Replies
Walshy
Walshy6mo ago
Make sure your builds API token has access to secret store - you can see which one is being used here: https://dash.cloudflare.com/?to=/:account/workers/services/view/:worker/production/settings#builds and then make sure that token has the perms needed
lisekilis
lisekilisOP6mo ago
i just made a new token and it worked thx
Tamada
Tamada2mo ago
Hey @Walshy , I am getting the same error, but I don't understand/see where to see this API token when deploying a worker? I've already tried to logout and re-login again but still getting the same error when deploying a worker via wrangler.

Did you find this page helpful?