flickr-sdk icon indicating copy to clipboard operation
flickr-sdk copied to clipboard

Usage with WebCrypto instead of node's crypto

Open johtso opened this issue 2 years ago • 1 comments

I'm wanting to make requests to Flickr's api in a Cloudflare Worker, but it provides WebCrypto rather than node's crypto implementation.

This turns out to be causing a real headache especially as the WebCrypto API is asynchronous.

Any pointers gratefully received!

johtso avatar Apr 20 '22 10:04 johtso

Neat! So there are two main parts to our OAuth stuff: there's the OAuth class, which implements the OAuth signature algorithm, and the OAuth superagent plugin, which uses the OAuth class to sign the request. I would probably start out by making your own copies of both of those files and edit them to be async/use webcrypto, then use your plugin instead. Let us know how it turns out!

jeremyruppel avatar Apr 20 '22 19:04 jeremyruppel