Example 1
Example 1
import { env, waitUntil } from 'cloudflare:workers'; import { createApplication } from '@setu-ts/kernel'; import { RuntimePlugin } from '@setu-ts/runtime'; import { CloudflarePlugin } from '@setu-ts/cloudflare-plugin'; const app = createApplication({ plugins: [ RuntimePlugin({ env }), CloudflarePlugin({ env, waitUntil, cache: { binding: 'CACHE_KV', prefix: 'cache:' } }), ], }); await app.start(); export default { fetch: app.fetch };
A binding the configuration names is absent from the Worker's env, or is
present with the wrong shape.
-
absent(): CloudflareBindingMissingErrorbinding: string,available: readonly string[]
Builds the error for a binding that is absent entirely.
-
name: string
Discriminating name for
instanceof-free checks. -
wrongShape(): CloudflareBindingMissingErrorbinding: string,expected: string
Builds the error for a binding that is present with the wrong shape.
An R2 object read found nothing.
-
name: string
Discriminating name for
instanceof-free checks.
A responder threw, and its failure was relayed to the caller.
-
name: string
Discriminating name for
instanceof-free checks.
A brokered request received no reply within its budget.
-
name: string
Discriminating name for
instanceof-free checks.
The requested operation has no counterpart on the Cloudflare binding.
-
name: string
Discriminating name for
instanceof-free checks.
A database backend over a Cloudflare D1 binding.
- beginTransaction(options?: TransactionOptions): Promise<IAdapterTransaction>
- connect(): Promise<void>
- createDataSource(entity: string): IDataSource
- disconnect(): Promise<void>
- isReady(): boolean
-
rawQuery<T>(): Promise<T[]>sql: string,params?: unknown[]
-
transactionIsolationLevels: readonly TransactionIsolationLevel[]
D1's deferred batch transaction has no isolation-level surface.
Serializes lock acquisition for one key.
-
fetch(request: Request): Promise<Response>
Routes one lock operation.
Carries RealtimeFrames between replicas over one WebSocket to a
Durable Object.
-
close(): Promise<void>
Closes the socket and drops every handler.
-
connect(): Promise<void>
Opens the socket to the Durable Object. Idempotent and concurrency-safe.
-
origin: string
This instance's identity, stamped onto every frame it publishes.
-
publish(frame: RealtimeFrame): Promise<void>
Publishes a frame to every other subscribed replica.
-
subscribe(handler: RealtimeFrameHandler): Promise<() => void>
Registers a handler for frames arriving from other replicas.
A distributed lock backed by one Durable Object per key.
-
acquire(): Promise<string | null>key: string,ttlMs: number
Attempts to acquire the lock.
-
release(): Promise<void>key: string,token: string
Releases a previously acquired lock.
A cache store backed by Workers KV.
-
clear(): Promise<void>
Removes every key this store owns.
-
delete(key: string): Promise<boolean>
Removes a cached value.
-
get<T>(key: string): Promise<T | null>
Reads a cached value.
-
has(key: string): Promise<boolean>
Reports whether a live entry exists.
-
set<T>(): Promise<void>key: string,value: T,ttlSeconds?: number
Stores a value.
A session store backed by Workers KV.
-
destroy(id: string): Promise<boolean>
Removes a stored session.
-
read(id: string): Promise<SessionData | null>
Reads a stored session payload.
-
write(): Promise<void>id: string,data: SessionData,ttlMs: number
Writes a session payload, replacing any existing one.
Object storage backed by Cloudflare R2.
-
delete(path: string): Promise<boolean>
Deletes an object.
-
exists(path: string): Promise<boolean>
Reports whether an object exists.
-
get(path: string): Promise<Uint8Array>
Retrieves an object.
-
getSignedUrl(): Promise<string>path: string,_options: SignedUrlOptions
Always throws — R2 bindings cannot presign.
-
getStream(path: string): Promise<ReadableStream<Uint8Array>>
Streams an object without buffering it.
-
put(): Promise<void>path: string,data: Uint8Array,options?: PutObjectOptions
Writes an object, translating
PutObjectOptionsinto R2's own spelling: the content type lives underhttpMetadata, user metadata undercustomMetadata. Without this every object was served asapplication/octet-stream(X8-6).
Fans one replica's broadcast out to every other connected replica.
-
fetch(request: Request): Promise<Response>
Answers a replica's WebSocket upgrade.
-
webSocketClose(): voidsocket: IDurableObjectWebSocket,code: number,reason: string
Handles a replica disconnecting.
-
webSocketError(socket: IDurableObjectWebSocket): void
Handles a socket error.
-
webSocketMessage(): voidsender: IDurableObjectWebSocket,message: string | ArrayBuffer
Re-broadcasts one replica's message to every other connected replica.
Delivers RPC replies to the caller waiting on them.
-
fetch(request: Request): Promise<Response>
Serves both halves of the inbox.
-
webSocketClose(): voidsocket: IDurableObjectWebSocket,code: number,reason: string
Handles the caller disconnecting.
-
webSocketError(socket: IDurableObjectWebSocket): void
Handles a socket error.
A message broker backed by Cloudflare Queues.
-
connect(): Promise<void>
No-op: a producer binding is ready as soon as the Worker has its
env, and there is no connection to open. -
disconnect(): Promise<void>
Closes the reply inbox, rejects every in-flight request, and drops every subscription.
-
dispatch(batch: IQueueMessageBatch): Promise<void>
Dispatches one delivered batch into the registered subscribers and responders.
-
publish<T>(): Promise<void>topic: string,message: T
Publishes a message to a topic.
-
request<TReq, TRes>(): Promise<TRes>topic: string,message: TReq,options?: RequestOptions
Sends a request and awaits its single correlated reply.
-
respond<TReq, TRes>(): Promise<ISubscription>topic: string,handler: RequestHandler<TReq, TRes>,options?: SubscribeOptions
Registers a responder for a request topic.
-
subscribe<T>(): Promise<ISubscription>topic: string,handler: MessageHandler<T>,options?: SubscribeOptions
Subscribes to a topic.
A registry of Cron Trigger handlers, keyed by cron expression.
-
dispatch(controller: IScheduledController): Promise<void>
Runs every handler registered for the firing trigger's expression.
-
expressions(): readonly string[]
Every expression that has at least one handler.
-
on(): thisexpression: string,handler: CronHandler
Registers a handler for a cron expression.
A background job queue backed by Cloudflare Queues.
-
add<T>(): Promise<string>name: string,data: T,options?: AddJobOptions
Enqueues a job.
-
addRecurring<T>(): Promise<void>name: string,_data: T,options: RecurringOptions
Not supported on Cloudflare Queues.
-
dispatch(batch: IQueueMessageBatch): Promise<void>
Dispatches one delivered batch into the registered processors.
-
process<T>(): voidname: string,processor: JobProcessor<T>,options?: ProcessOptions
Registers a processor for a job name.
Lists every reason the edge cache would refuse this response.
Narrows a Durable Object stub's response to one carrying a socket.
Caches responses in the Cloudflare edge cache.
Creates the Cloudflare Workers plugin.
Builds the default host from the real Workers global.
Builds the handler an application exports as queue to consume messages.
Builds the handler an application exports as queue.
Builds the handler an application exports as scheduled.
Reports whether a binding is D1-shaped.
Reports whether a binding is Durable-Object-namespace-shaped.
Reports whether a binding is KV-shaped.
Reports whether a binding is Queues-producer-shaped.
Reports whether a binding is R2-shaped.
The runtime capabilities this broker needs. IRuntimeServices
satisfies it.
-
clearTimeout(handle: TimerHandle): void
Cancels a reply timeout.
-
now(): number
Wall-clock milliseconds, for
MessageMetadata.timestamp. -
setTimeout(): TimerHandlefn: () => void,ms: number
Schedules a reply timeout.
-
uuid(): string
A fresh unique id, for message ids, correlation ids, and inbox addresses.
What assessCacheability needs to decide.
-
cacheableStatuses: readonly number[]
Statuses the caller considers cacheable.
-
headers: Headers
The response headers.
-
method: string
The request method.
-
status: number
The response status.
Options for cacheApiMiddleware.
-
bypass: (ctx: IRequestContext) => boolean
Returning
trueskips the cache entirely for this request. -
cache: ICacheApi
The cache handle. Omitted resolves
caches.defaultfrom the global scope; when that is also absent — every runtime other than Cloudflare Workers — the middleware passes through instead of throwing. -
cacheableStatuses: readonly number[]
Statuses worth caching. Defaults to
[200]. Does not override the platform's unconditional refusal of 206. -
key: (ctx: IRequestContext) => string
Builds the cache key from the request. Omitted uses the full request URL, which is what the platform's own cache keys on.
-
ttlSeconds: number
Adds
Cache-Control: public, max-age=<n>to the stored copy when the response carries noCache-Controlof its own. The edge honors the stored response's own directive, so without one an entry has no freshness lifetime and is of little use. The client's response is left untouched.
The clock shape this store needs. IRuntimeServices satisfies it.
-
now(): number
Current wall-clock time.
Options for CloudflarePlugin.
-
cache: KvCacheOptions
Serve
CAPABILITIES.CACHEfrom a KV namespace. Omitted registers nothing. -
durableObject: DurableObjectArm
Serve
CAPABILITIES.REALTIME_BACKPLANEfrom a Durable Object namespace. Omitted registers nothing. -
env: CloudflareWorkerEnv
The Worker's
env, fromimport { env } from 'cloudflare:workers'. -
messaging: WorkersMessagingArm
Serve
CAPABILITIES.MESSAGINGfrom a Queues producer binding. Omitted registers nothing. -
queue: WorkersQueueArm
Serve
CAPABILITIES.QUEUEfrom a Queues producer binding. Omitted registers nothing. -
requireBindings: readonly string[]
Bindings that must be present.
register()throws naming every absent one, so a missingwrangler.tomlstanza fails at startup instead of on the first request that needs it. -
storage: R2StorageArm
Serve
CAPABILITIES.STORAGEfrom an R2 bucket. Omitted registers nothing. -
waitUntil: WaitUntilHost
The platform's background-work sink, from
import { waitUntil } from 'cloudflare:workers'(available from compatibility date 2025-08-08).
Options for D1Adapter.
-
tables: Readonly<Record<string, D1EntityMapping>>
Per-entity table and primary-key overrides, keyed by the entity name passed to
getRepository().
How one entity name maps onto a physical D1 table.
-
primaryKey: string | readonly string[]
The primary-key column(s). A scalar name keeps today's single-column behaviour; an array enables a composite key whose columns are matched in declaration order. Defaults to
['id']. -
table: string
The table name. Defaults to the entity name itself, so
getRepository('users')needs no mapping at all.
A D1 statement result.
-
results: readonly T[]
The returned rows; empty for a write.
-
success: boolean
Whether the statement succeeded.
Options for DistributedLockObjectCore.
-
now: () => number
Wall-clock source, in epoch milliseconds. Defaults to
Date.now.
Wires a Durable Object namespace up as the application's
IRealtimeBackplane under CAPABILITIES.REALTIME_BACKPLANE, so
WebSocket rooms and SSE channels reach clients on other replicas.
-
binding: string
The Durable Object namespace binding name from
wrangler.toml. -
name: string
Instance name.
'default'(the default) claims the barerealtime-backplanetoken; anything else derivesrealtime-backplane.<name>. -
topic: string
The object name every replica shares, passed to
idFromName.
Options for DurableObjectBackplane.
-
binding: string
The Durable Object binding name, used only in error messages.
-
logger: () => ILogger | undefined
Logger accessor for reporting a transport failure.
-
origin: string
This instance's identity, stamped on every published frame.
-
topic: string
The object name every replica shares, from
idFromName.
Options for DurableObjectLock.
-
binding: string
The Durable Object binding name, used only in error messages.
-
keyPrefix: string
Prefix applied to every lock key before deriving the object name.
-
runtime: IRuntimeServices
Runtime services, for minting the lock token.
One message arriving on a Durable Object WebSocket.
-
data: string | ArrayBuffer
The payload, as the runtime delivered it.
A Durable Object stub's response to a WebSocket upgrade.
-
status: number
Always
101 Switching Protocolson a successful upgrade. -
webSocket: IDurableObjectClientSocket
The client half of the connection.
Supplies the socket pair a Durable Object upgrade needs.
-
createPair(): DurableObjectWebSocketPair
Creates a linked client/server socket pair.
A created WebSocketPair.
-
client: IDurableObjectClientSocket
Handed back to the connecting replica in the 101 response.
-
server: IDurableObjectWebSocket
Retained by the Durable Object and accepted for hibernation.
The subset of the platform's Cache this package calls.
-
delete(request: Request | string): Promise<boolean>
Removes a cached response.
-
match(request: Request | string): Promise<Response | undefined>
Looks up a cached response.
-
put(): Promise<void>request: Request | string,response: Response
Stores a response.
Typed access to a Cloudflare Worker's platform bindings.
-
d1(name: string): ID1Database
A D1 database binding.
-
durableObject(name: string): IDurableObjectNamespace
A Durable Object namespace binding.
-
get<T>(name: string): T
A binding of a type this package has no facade for — Hyperdrive, Vectorize, Workers AI, Analytics Engine, and anything Cloudflare ships next.
-
has(name: string): boolean
Reports whether a binding of that name is present.
-
kv(name: string): IKvNamespace
A KV namespace binding.
-
names(): readonly string[]
Every binding name the Worker carries, sorted.
-
queue(name: string): IQueueProducer
A Queues producer binding.
-
r2(name: string): IR2Bucket
An R2 bucket binding.
-
service(name: string): IServiceBinding
A service binding to another Worker.
-
vars(): Readonly<Record<string, string>>
The Worker's string variables and secrets.
-
waitUntil(promise: Promise<unknown>): void
Keeps the invocation alive until the promise settles, so work can outlive the response.
A D1 database binding.
-
batch<T = Record<string, unknown>>(statements: readonly ID1PreparedStatement[]): Promise<readonly D1Result<T>[]>
Runs several statements as one atomic transaction. D1 exposes no imperative
BEGIN/COMMIT, so this is its unit of atomicity. -
prepare(query: string): ID1PreparedStatement
Prepares a statement.
A prepared D1 statement.
-
all<T = Record<string, unknown>>(): Promise<D1Result<T>>
Runs the statement and returns every row.
-
bind(...values: readonly unknown[]): ID1PreparedStatement
Binds ordered parameters. D1 supports
?and?NNN, not named parameters. -
first<T = Record<string, unknown>>(): Promise<T | null>
Runs the statement and returns the first row.
-
run<T = Record<string, unknown>>(): Promise<D1Result<T>>
Runs the statement for its effect.
The client half of a WebSocketPair, or the socket a Worker gets back from a
Durable Object upgrade.
-
accept(): void
Begins handling the socket in this isolate.
-
addEventListener(): voidtype: "message" | "close" | "error",listener: (event: DurableObjectMessageEvent) => void
Subscribes to a socket event.
-
close(): voidcode?: number,reason?: string
Closes the connection.
-
send(message: string | ArrayBuffer): void
Sends one frame to the peer.
A Durable Object namespace binding.
-
get(id: unknown): IServiceBinding
Returns a stub for the object with this id.
-
idFromName(name: string): unknown
Derives a stable object id from a name.
The DurableObjectState (ctx) members this package calls.
-
acceptWebSocket(ws: IDurableObjectWebSocket): void
Accepts a socket as hibernatable.
-
getWebSockets(): IDurableObjectWebSocket[]
Returns every currently connected socket.
-
storage: IDurableObjectStorage
Durable, transactional key/value storage scoped to this object.
The subset of DurableObjectStorage the lock object uses.
-
delete(key: string): Promise<boolean>
Removes one value.
-
get<T>(key: string): Promise<T | undefined>
Reads one persisted value.
-
put<T>(): Promise<void>key: string,value: T
Writes one value.
A WebSocket held by a Durable Object, as the hibernation API hands it back.
-
close(): voidcode?: number,reason?: string
Closes the connection.
-
send(message: string | ArrayBuffer): void
Sends one frame to the peer.
A Workers KV namespace binding.
-
delete(key: string): Promise<void>
Removes a value. Succeeds whether or not the key existed.
-
get(key: string): Promise<string | null>
Reads a value as text.
-
list(options?: KvListOptions): Promise<KvListResult>
Lists keys, one page at a time.
-
put(): Promise<void>key: string,value: string,options?: KvPutOptions
Writes a value.
One message delivered to a Queues consumer.
-
ack(): void
Marks the message processed. It is not redelivered.
-
attempts: number
Delivery attempt, 1 on first delivery — the same base as
IJob. -
body: unknown
The message body, as the producer sent it.
-
id: string
The platform-assigned message id.
-
retry(options?: { readonly delaySeconds?: number; }): void
Returns the message for redelivery, subject to the queue's configured
max_retriesand dead-letter queue.
A batch of messages delivered to a Queues consumer.
-
messages: readonly IQueueMessage[]
The messages in the batch.
-
queue: string
The name of the queue this batch came from.
A Cloudflare Queues producer binding.
-
send(): Promise<void>body: unknown,options?: QueueSendOptions
Enqueues one message, at most 128 KB.
-
sendBatch(messages: readonly { readonly body: unknown; readonly contentType?: string; }[]): Promise<void>
Enqueues up to 100 messages, at most 256 KB in total.
-
delete(key: string): Promise<void>
Removes an object. Succeeds whether or not it existed, and reports nothing about what was removed — which is why
R2Storage.deleteheads first to honor its committedPromise<boolean>. -
get(key: string): Promise<IR2ObjectBody | null>
Reads an object.
-
head(key: string): Promise<IR2Object | null>
Reads object metadata without transferring the body.
-
put(): Promise<IR2Object | null>key: string,value: ArrayBuffer | ArrayBufferView,options?: R2PutOptions
Writes an object.
Metadata common to every R2 object.
-
etag: string
The object's entity tag.
-
key: string
The object key.
-
size: number
Object size in bytes.
An R2 object together with its body.
-
arrayBuffer(): Promise<ArrayBuffer>
Reads the whole body into memory.
-
body: ReadableStream<Uint8Array>
The object body as a stream — the zero-copy download path.
The controller handed to a Cron Trigger's scheduled handler.
-
cron: string
The cron expression that fired, exactly as written in
wrangler.toml. -
scheduledTime: number
When the trigger was scheduled to fire, in epoch milliseconds.
A service binding to another Worker — a fetch-shaped RPC channel.
-
fetch(): Promise<Response>input: Request | string,init?: RequestInit
Invokes the bound Worker.
The id source this queue needs. IRuntimeServices satisfies it.
-
uuid(): string
A fresh unique id.
Wires a KV namespace up as the application's ICacheStore under
CAPABILITIES.CACHE.
-
binding: string
The KV namespace binding name from
wrangler.toml. -
defaultTtlSeconds: number
TTL in seconds applied when
setomits one. Omitted means no expiry. -
name: string
Instance name.
'default'(the default) claims the barecachetoken; anything else derivescache.<name>, matchingCachePlugin's convention so several caches can coexist. -
prefix: string
Prefix applied to every cache key. Required to call
clear(), and recommended whenever the namespace is shared.
Options for KvCacheStore.
-
defaultTtlSeconds: number
TTL in seconds applied when
setomits one. Omitted means no expiry. -
prefix: string
Prefix applied to every key. Required for
KvCacheStore.clear, which otherwise has no way to tell this store's keys from anything else sharing the namespace.
Options for IKvNamespace.list.
-
cursor: string
Continuation cursor from a previous page.
-
limit: number
Page size. The platform default and maximum are both 1000.
-
prefix: string
Return only keys starting with this prefix.
One page of IKvNamespace.list results.
-
cursor: string
Cursor for the next page; absent on the last page.
-
keys: readonly { readonly name: string; }[]
The keys in this page.
-
list_complete: boolean
truewhen this page is the last one.
Options for IKvNamespace.put.
-
expirationTtl: number
Seconds until KV removes the entry. The platform minimum is 60; a smaller value is rejected, which is why
physicalTtlSecondsfloors it and a logical expiry is carried inside the value.
Options for KvSessionStore.
-
prefix: string
Prefix applied to every session key. Defaults to
'session:', so sharing one namespace with a cache store is safe by default.
Options for createMessagingHandler.
-
name: string
Which broker instance to dispatch into, matching
CloudflarePluginOptions.messaging.name. Omitted resolves the bareCAPABILITIES.MESSAGINGtoken.
Options for createQueueHandler.
-
name: string
Which queue instance to dispatch into, matching
CloudflarePluginOptions.queue.name. Omitted resolves the bareCAPABILITIES.QUEUEtoken.
Options for IQueueProducer.send.
-
contentType: "json" | "text" | "bytes" | "v8"
How the body is serialized. Defaults to
'json'. -
delaySeconds: number
Delivery delay in seconds, from 0 to 86400.
The subset of R2's put options this package writes.
-
customMetadata: Readonly<Record<string, string>>
Arbitrary user metadata stored alongside the object.
-
httpMetadata: { readonly contentType?: string; }
HTTP metadata stored on the object; R2 serves
contentTypeback on GET.
Wires an R2 bucket up as the application's IStorage under
CAPABILITIES.STORAGE.
-
binding: string
The R2 bucket binding name from
wrangler.toml. -
name: string
Instance name.
'default'(the default) claims the barestoragetoken; anything else derivesstorage.<name>. -
prefix: string
Prefix applied to every object key.
Options for R2Storage.
-
prefix: string
Prefix applied to every object key, so one bucket can host several uses.
Options for RealtimeBackplaneObjectCore.
-
createPair: DurableObjectWebSocketHost
Supplies the
WebSocketPairan upgrade needs.
The Durable Object namespace serving reply inboxes, plus its binding name.
-
binding: string
The binding name, for error messages.
-
defaultTimeoutMs: number
Reply budget when
RequestOptions.timeoutMsis omitted. -
namespace: IDurableObjectNamespace
The Durable Object namespace binding.
Options for ReplyInboxObjectCore.
-
createPair: DurableObjectWebSocketHost
Supplies the
WebSocketPairan upgrade needs.
Options for WorkersBroker.
-
logger: LoggerSource
Resolves the logger at the moment a dispatch path needs it.
-
replyInbox: ReplyInboxBinding
Enables
request/respond. Omitted, both throwCloudflareUnsupportedErrornaming the arm to add.
Options for WorkersCron.
-
logger: ILogger
Reports the two paths that would otherwise be silent: a trigger firing with no handler registered for its expression, and a handler that rejects. Omitted leaves both silent.
Wires a Cloudflare Queues producer binding up as the application's
IMessageBroker under CAPABILITIES.MESSAGING.
-
binding: string
The Queues producer binding name from
wrangler.toml. -
name: string
Instance name.
'default'(the default) claims the baremessagingtoken; anything else derivesmessaging.<name>, whichMessagingHandlerOptions.namemust then match. -
rpc: WorkersMessagingRpcArm
Enable
request/respond. Omitted, both throwCloudflareUnsupportedErrornaming this arm.
Enables brokered request-reply on a WorkersMessagingArm.
-
binding: string
The Durable Object namespace binding name from
wrangler.toml. -
defaultTimeoutMs: number
Reply budget applied when
RequestOptions.timeoutMsis omitted.
Wires a Cloudflare Queues producer binding up as the application's
IQueue under CAPABILITIES.QUEUE.
-
binding: string
The Queues producer binding name from
wrangler.toml. -
maxDelaySeconds: number
Largest accepted
AddJobOptions.delayMs, in seconds. Defaults to 86400, the platform maximum; a larger delay throws rather than being silently truncated. -
name: string
Instance name.
'default'(the default) claims the barequeuetoken; anything else derivesqueue.<name>, whichQueueHandlerOptions.namemust then match.
Options for WorkersQueue.
-
logger: LoggerSource
Resolves the logger at the moment a dispatch path needs it, reporting on the four cases that would otherwise be silent: a message whose name has no processor, an unreadable body, a processor that threw, and a job that exhausted its attempts.
-
maxDelaySeconds: number
Largest
delayMsthis queue will accept, in seconds. Defaults to 86400, the platform maximum. A larger delay throws rather than being silently truncated by the platform.
| "status"
| "partial-content"
| "vary-star"
| "set-cookie"
Why the edge cache would refuse a response.
The Worker env record, as import { env } from 'cloudflare:workers'
provides it: a mix of string variables and object bindings.
Invoked when a Cron Trigger fires.
Resolves the logger at the moment a background task fails.
The queue export's shape, as Cloudflare invokes it.
The queue export's shape, as Cloudflare invokes it.
The scheduled export's shape, as Cloudflare invokes it.
A sink that keeps a Worker alive until the promise settles.
Usage
import * as Cloudflare_Workers_platform_bindings_for_Setu_TS___The_framework_has_served_traffic_on_Workers_since_the_Hono_migration__but_had_no_way_to_reach_the_platform_s_own_primitives___CloudflarePlugin__publishes_a_Worker_s_bindings_under__CAPABILITIES_CLOUDFLARE___and_optionally_serves_the_committed_cache_and_storage_capabilities_from_KV_and_R2___Zero_npm_dependencies__and_nothing_here_imports__cloudflare_workers____the_application_passes__env___and__waitUntil___in__which_keeps_the_package_type_checkable_on_every_runtime_and_trivially_testable___Every_export_is_documented_in_PUBLIC_API_md__ from "cloudflare-plugin/src/index.ts";