Unable to access secret-store in local dev

I have defined a couple of secrets in the Cloudflare secrets-store. I have created bindings in the wrangler.jsonc file. But when running the worker locally, I get an error that the secret is "not found". I have tried defining these in the .dev.vars file but to no avail. When running wrangler dev it does say:
- Secrets Store Secrets:
- instanceUrl: a0d7fd5ae3af4aad8c87bccb41323cac/TS_INSTANCE_URL [simulated locally]
- accessToken: a0d7fd5ae3af4aad8c87bccb41323cac/TS_ACCESS_TOKEN [simulated locally]
- Secrets Store Secrets:
- instanceUrl: a0d7fd5ae3af4aad8c87bccb41323cac/TS_INSTANCE_URL [simulated locally]
- accessToken: a0d7fd5ae3af4aad8c87bccb41323cac/TS_ACCESS_TOKEN [simulated locally]
But, when running the worker it says:
✘ [ERROR] Error: Secret "TS_ACCESS_TOKEN" not found
✘ [ERROR] Error: Secret "TS_ACCESS_TOKEN" not found
1 Reply
Ricky U
Ricky U17h ago
yes i get the same error, it doesnt work locally you will have to put --remote on nox wrangler dev --remote -- but you wont see any logs?! i still cant find a way to get serets store working locally with remote bindings well.

Did you find this page helpful?