Skip to main content
Version: 1.x

createCloudflareSubscription()

createCloudflareSubscription<Env, Context, ContextParams, PubSubMap>(options): object

Type Parameters​

Type ParameterDefault type

Env

‐

Context

‐

ContextParams

‐

PubSubMap extends Record<string, any>

Record<string, any>

Parameters​

ParameterType

options

SubscriptionsOptions<Env, Context, ContextParams>

Returns​

object

NameType

createPublisher()

(env, execContext) => Publish<PubSubMap>

createSubscriber()

() => Subscribe<PubSubMap>

createWsConnectionsClass()

() => (state, env) => DurableObject

handleWS()

(request, env, execContext) => Promise<Response>