Document WebCrypto method of creating HMAC #66
Locked
mglikesbikes
started this conversation in
General
Replies: 1 comment
-
Thank you for the contribution, @mglikesbikes and glad to hear you love the product so far. We would love to say thank you - can you email operations@magicbell.io referencing this thread, and we will organise some swag for you. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there!
Had a hell of a google search trying to figure this out, so thought I'd share — for some serverless environments (eg. Cloudflare Workers), we have to use webcrypto instead of any NodeJS crypto libraries. That means all of the examples can't be used!
Here's what I found via a lovely Stack Overflow thread and updated to not use
btoa
. Seems to work just fine!Sample usage, in, say, a SvelteKit app on Cloudflare Workers:
Anyway, just started with MagicBell today and loving it so far. Thanks!!
Beta Was this translation helpful? Give feedback.
All reactions