Skip to main content Link Search Menu Expand Document (external link)

Cloudflare.ts overview

Since v1.0.0


Exports Grouped by Category


DurableObject

EventLogDurableObject (class)

Signature

declare class EventLogDurableObject {
  constructor(options: {
    readonly ctx: DurableObjectState
    readonly env: unknown
    readonly storageLayer: Layer.Layer<EventLogServer.Storage>
  })
}

Source

Since v1.0.0

webSocketMessage (method)

Signature

declare const webSocketMessage: (ws: WebSocket, message: string | ArrayBuffer) => Promise<void>

Source

Since v1.0.0

handleRequest (method)

Signature

declare const handleRequest: (ws: WebSocket, request: typeof EventLogRemote.ProtocolRequest.Type) => Promise<void>

Source

Since v1.0.0

encodeChanges (method)

Signature

declare const encodeChanges: (
  publicKey: string,
  entries: ReadonlyArray<EncryptedRemoteEntry>
) => ReadonlyArray<Uint8Array>

Source

Since v1.0.0

webSocketError (method)

Signature

declare const webSocketError: (_ws: WebSocket, error: Error) => void

Source

Since v1.0.0

webSocketClose (method)

Signature

declare const webSocketClose: (_ws: WebSocket, code: number, reason: string) => void

Source

Since v1.0.0

fetch (method)

Signature

declare const fetch: () => Promise<Response>

Source

Since v1.0.0

runtime (property)

Signature

readonly runtime: ManagedRuntime.ManagedRuntime<EventLogServer.Storage, never>

Source

Since v1.0.0