r2_public_beta_bindings sometime late next week (I'm not 100% sure when we'll allow such scripts - I'll keep you updated).R2Error stack is any instead of string (& in fact name/message/stack can probably be elided because of inheritance? not sure).R2Error code needs a documentation note. This code is the same code that the Cloudflare V4 API that will be documented.onlyIf needs a documentation note. The Headers it accepts require HTTP header names (IfModifiedSince/IfNotModifiedSince etc).R2Object writeHttpMetadata is missing a note. It writes out the headers from httpMetadata as you would expect (content-type, cache-control, etc)httpMetadata on put (i.e. cache-control -> cacheControl, expires -> cacheExpiry). Note that S3 uses the HTTP "Expires" name but I think that confuses people into thinking that has something to do with lifecycle. It does not. It's simply the cache expiry metadata you associate with an object.R2PutOptions has md5 and sha1 as optionals to specify the digest of the body, but those are mutually exclusive and the type needs to be reified to reflect that (the runtime enforces this, it's just not reflected in the type system).put it seems then - woot!ReadableStream must be known. For example, incoming request with a content-length and you're forwarding along the body. Or the response body of a fetch that has a content-length. Or the readable half of a FixedLengthStream transform stream.r2_public_beta_bindings is a compat flag right ok, makes senser2_public_beta_bindings is on by default but for those that need to upgrade the compat date but keep the old bindings, you can opt to the old bindings via r2_internal_beta_bindings. Anyone starting should use the public beta bindings. The old ones are not as complete and have edges.expirationTtl was never a thing and was never hooked up to anything IIRC (or maybe it was actually setting the cache expiry header? can't recall). There is a plan around it and we will reintroduce but we probably need to have object lifecycles comprehensively solved (although maybe we put in a hack before then - hard to say. we'll see how things develop). Talk to us internally if you absolutely need it but most likely our answer will be no.include field which is strange since it's R2 specific. This is what is should be instead:R2Object list will have a httpMetadata/customMetadata populated. The performance notes are very preliminary and I wouldn't take them too seriously. Design around what's easiest for now. The performance of the system will be changing drastically in the coming weeks.r2_public_beta_bindingsr2_public_beta_bindingsr2_public_beta_bindingsR2ErrorR2ErrorstackstackonlyIfHeadersIfModifiedSinceIfNotModifiedSinceR2ObjectR2ObjectwriteHttpMetadatacacheControlexpirescacheExpiryR2PutOptionsmd5sha1r2_internal_beta_bindingsexpirationTtl/**
* If you populate this array, then items returned will include this metadata.
* A tradeoff is that fewer results may be returned depending on how big this
* data is. For now the caps are TBD but expect the total memory usage for a list
* operation may need to be <1MB or even <128kb depending on how many list operations
* you are sending into one bucket. Make sure to look at `truncated` for the result
* rather than having logic like
* */
include: ("httpMetadata" | "customMetadata")[]customMetadata