Clients - websub : SubscriptionClient

The HTTP based client for WebSub subscription and unsubscription.

Constructor

__init

(string url, ClientConfiguration? config)

  • url string
  • The URL to change subscription at

Remote Methods

subscribe

Sends a subscription request to a WebSub Hub.

unsubscribe

Sends an unsubscription request to a WebSub Hub.

subscribe

(SubscriptionChangeRequest subscriptionRequest)

returns SubscriptionChangeResponse | error

Sends a subscription request to a WebSub Hub.

Parameters

  • Return Type

    (SubscriptionChangeResponse | error)
  • SubscriptionChangeResponse indicating subscription details, if the request was successful else error if an error occurred with the subscription request

unsubscribe

(SubscriptionChangeRequest unsubscriptionRequest)

returns SubscriptionChangeResponse | error

Sends an unsubscription request to a WebSub Hub.

Parameters

  • Return Type

    (SubscriptionChangeResponse | error)
  • SubscriptionChangeResponse indicating unsubscription details, if the request was successful else error if an error occurred with the unsubscription request