aws4fetch
aws4fetch copied to clipboard
Within scope to add support for R2?
Would it be possible to add R2 support to https://github.com/mhart/aws4fetch/blob/447d747ab99bd7cb58afbe1da9b1af88c787cae7/src/main.js#L376 to make things easier on R2 users? I know this is an AWS-focused library so it's OK if the answer is no. Happy to help in any way I can.
The guessed region should be auto
and the service
would be s3
for <account>.r2.cloudflarestorage.com
(or when using virtual bucket addressing, <bucket>.<account>.r2.cloudflarestorage.com
)
There's no need to access R2 in this manner; direct bucket-to-script bindings are here: https://developers.cloudflare.com/r2/runtime-apis/
Oh, nice! Thank you!