unsubscribeFromWebhookEvent

This method allows broadcasters to unsubscribe from a webhook topic that they subscribed to using the subscribeToWebhookEvent() or 3.1 webhook method.

If a broadcaster calls this method for a topic that they don’t subscribe, the method will succeed, however the removedEntries field value will equal 0.

For the list of available webhook topics, please see this article.

Parameters

Name

Type

Description

*publisherToken

string

Your publisher token

topic*

string

Name of one of the available webhook event topics that the broadcaster is subscribed to

Result Parameters

Name

Type

Description

success

boolean

True if the call succeeded, absent if it failed.

removedEntries

integer

Number of subscriptions removed

error

string

Only returned when an error occurred.

API Request/Response

Request

{
    "method": "unsubscribeFromWebhookEvent",
    "params": {
        "publisherToken": "some_publisher_token",
        "topic": "subscriptionReadyForPaymentAuthorisation"
    },
    "jsonrpc": "2.0",
    "id": 1
}

Response

{
    "result": {
        "success": true,
        "removedEntries": 1
    },
    "id": "1",
    "jsonrpc": "2.0"
}