Prediction

Events raised as a Channel Points Prediction starts, takes predictions, locks and resolves.

View as markdown
Provide feedback for this page

Channel Prediction Begin

The channel.prediction.begin subscription type sends a notification when a Prediction begins on the specified channel.

Subscription

Type
channel.prediction.begin
Version
1

Authorization

Requires one of the following:

  • A user access token that includes the channel:read:predictions or channel:manage:predictions scope.
  • An app access token.The application, through prior authorization, must have been granted:
    • The channel:read:predictions or channel:manage:predictions scope for the user represented by the broadcaster_user_id event condition.

Subscription Request Body

  • typeStringRequired
    The subscription type name: channel.prediction.begin.
  • versionStringRequired
    The subscription type version: 1.
  • conditionObjectRequired
    Subscription-specific parameters. Pass in the broadcaster user ID for the channel you want to receive prediction begin notifications for.
    Hide child attributesShow child attributes
    • condition.broadcaster_user_idStringRequired
      The broadcaster user ID of the channel for which "prediction begin" notifications will be received.
  • transportObjectRequired
    Transport-specific parameters.
    Hide child attributesShow child attributes
    • transport.methodStringRequired
      The transport method for EventSub.

      Possible values

      • webhook
      • websocket
      • conduit
    • transport.callbackString

      The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

      Specify this field only if method is set to webhook.

      NOTE: Redirects are not followed.

    • transport.secretString

      The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

      Specify this field only if the method is set to webhook.

    • transport.session_idString

      An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

      Specify this field only if the method is set to websocket.

    • transport.conduit_idString

      An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

      Specify this field only if the method is set to conduit.

Event Payload

  • subscriptionObject
    Metadata about the subscription.
    Hide child attributesShow child attributes
    • subscription.idString
      The Subscription ID of the subscription.
    • subscription.typeString
      The notification's subscription type.
    • subscription.versionString
      The version of the subscription.
    • subscription.statusString
      The status of the subscription.
    • subscription.costInteger
      How much the subscription counts against your limit. See Subscription Limits for more information.
    • subscription.conditionObject
      Subscription-specific parameters.
      Hide child attributesShow child attributes
      • subscription.condition.broadcaster_user_idString
        The broadcaster user ID of the channel for which "prediction begin" notifications will be received.
    • subscription.created_atString
      The time the notification was created.
    • subscription.transportObject
      Transport-specific parameters.
      Hide child attributesShow child attributes
      • subscription.transport.methodString
        The transport method for EventSub.

        Possible values

        • webhook
        • websocket
        • conduit
      • subscription.transport.callbackString

        The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

        Specify this field only if method is set to webhook.

        NOTE: Redirects are not followed.

      • subscription.transport.secretString

        The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

        Specify this field only if the method is set to webhook.

      • subscription.transport.session_idString

        An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

        Specify this field only if the method is set to websocket.

      • subscription.transport.conduit_idString

        An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

        Specify this field only if the method is set to conduit.

  • eventObject
    The event information.
    Hide child attributesShow child attributes
    • event.idString
      Channel Points Prediction ID.
    • event.broadcaster_user_idString
      The requested broadcaster ID.
    • event.broadcaster_user_loginString
      The requested broadcaster login.
    • event.broadcaster_user_nameString
      The requested broadcaster display name.
    • event.titleString
      Title for the Channel Points Prediction.
    • event.outcomesObject[]
      An array of outcomes for the Channel Points Prediction.
      Hide child attributesShow child attributes
      • event.outcomes.idString
        The outcome ID.
      • event.outcomes.titleString
        The outcome title.
      • event.outcomes.colorString
        The color for the outcome. Valid values are pink and blue.
      • event.outcomes.usersInteger
        The number of users who used Channel Points on this outcome.
      • event.outcomes.channel_pointsInteger
        The total number of Channel Points used on this outcome.
      • event.outcomes.top_predictorsObject[]
        An array of users who used the most Channel Points on this outcome.
        Hide child attributesShow child attributes
        • event.outcomes.top_predictors.user_idString
          The ID of the user.
        • event.outcomes.top_predictors.user_loginString
          The login of the user.
        • event.outcomes.top_predictors.user_nameString
          The display name of the user.
        • event.outcomes.top_predictors.channel_points_wonIntegerNullable
          The number of Channel Points won. This value is always null in the event payload for Prediction progress and Prediction lock. This value is 0 if the outcome did not win or if the Prediction was canceled and Channel Points were refunded.
        • event.outcomes.top_predictors.channel_points_usedInteger
          The number of Channel Points used to participate in the Prediction.
    • event.started_atString
      The time the Channel Points Prediction started.
    • event.locks_atString
      The time the Channel Points Prediction will automatically lock.
Subscription Request Body Example
{
  "type": "channel.prediction.begin",
  "version": "1",
  "condition": {
    "broadcaster_user_id": "1337"
  },
  "transport": {
    "method": "webhook",
    "callback": "https://example.com/webhooks/callback",
    "secret": "s3cRe7"
  }
}
Event Payload Example
{
    "subscription": {
        "id": "f1c2a387-161a-49f9-a165-0f21d7a4e1c4",
        "type": "channel.prediction.begin",
        "version": "1",
        "status": "enabled",
        "cost": 0,
        "condition": {
            "broadcaster_user_id": "1337"
        },
         "transport": {
            "method": "webhook",
            "callback": "https://example.com/webhooks/callback"
        },
        "created_at": "2019-11-16T10:11:12.634234626Z"
    },
    "event": {
        "id": "1243456",
        "broadcaster_user_id": "1337",
        "broadcaster_user_login": "cool_user",
        "broadcaster_user_name": "Cool_User",
        "title": "Aren't shoes just really hard socks?",
        "outcomes": [
            {"id": "1243456", "title": "Yeah!", "color": "blue"},
            {"id": "2243456", "title": "No!", "color": "pink"}
        ],
        "started_at": "2020-07-15T17:16:03.17106713Z",
        "locks_at": "2020-07-15T17:21:03.17106713Z"
    }
}

Channel Prediction End

The channel.prediction.end subscription type sends a notification when a Prediction ends on the specified channel.

Subscription

Type
channel.prediction.end
Version
1

Authorization

Requires one of the following:

  • A user access token that includes the channel:read:predictions or channel:manage:predictions scope.
  • An app access token.The application, through prior authorization, must have been granted:
    • The channel:read:predictions or channel:manage:predictions scope for the user represented by the broadcaster_user_id event condition.

Subscription Request Body

  • typeStringRequired
    The subscription type name: channel.prediction.end.
  • versionStringRequired
    The subscription type version: 1.
  • conditionObjectRequired
    Subscription-specific parameters. Pass in the broadcaster user ID for the channel you want to receive prediction lock notifications for.
    Hide child attributesShow child attributes
    • condition.broadcaster_user_idStringRequired
      The broadcaster user ID of the channel for which "prediction end" notifications will be received.
  • transportObjectRequired
    Transport-specific parameters.
    Hide child attributesShow child attributes
    • transport.methodStringRequired
      The transport method for EventSub.

      Possible values

      • webhook
      • websocket
      • conduit
    • transport.callbackString

      The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

      Specify this field only if method is set to webhook.

      NOTE: Redirects are not followed.

    • transport.secretString

      The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

      Specify this field only if the method is set to webhook.

    • transport.session_idString

      An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

      Specify this field only if the method is set to websocket.

    • transport.conduit_idString

      An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

      Specify this field only if the method is set to conduit.

Event Payload

  • subscriptionObject
    Metadata about the subscription.
    Hide child attributesShow child attributes
    • subscription.idString
      The Subscription ID of the subscription.
    • subscription.typeString
      The notification's subscription type.
    • subscription.versionString
      The version of the subscription.
    • subscription.statusString
      The status of the subscription.
    • subscription.costInteger
      How much the subscription counts against your limit. See Subscription Limits for more information.
    • subscription.conditionObject
      Subscription-specific parameters.
      Hide child attributesShow child attributes
      • subscription.condition.broadcaster_user_idString
        The broadcaster user ID of the channel for which "prediction end" notifications will be received.
    • subscription.created_atString
      The time the notification was created.
    • subscription.transportObject
      Transport-specific parameters.
      Hide child attributesShow child attributes
      • subscription.transport.methodString
        The transport method for EventSub.

        Possible values

        • webhook
        • websocket
        • conduit
      • subscription.transport.callbackString

        The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

        Specify this field only if method is set to webhook.

        NOTE: Redirects are not followed.

      • subscription.transport.secretString

        The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

        Specify this field only if the method is set to webhook.

      • subscription.transport.session_idString

        An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

        Specify this field only if the method is set to websocket.

      • subscription.transport.conduit_idString

        An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

        Specify this field only if the method is set to conduit.

  • eventObject
    The event information.
    Hide child attributesShow child attributes
    • event.idString
      Channel Points Prediction ID.
    • event.broadcaster_user_idString
      The requested broadcaster ID.
    • event.broadcaster_user_loginString
      The requested broadcaster login.
    • event.broadcaster_user_nameString
      The requested broadcaster display name.
    • event.titleString
      Title for the Channel Points Prediction.
    • event.winning_outcome_idString
      ID of the winning outcome.
    • event.outcomesObject[]
      An array of outcomes for the Channel Points Prediction. Includes top_predictors.
      Hide child attributesShow child attributes
      • event.outcomes.idString
        The outcome ID.
      • event.outcomes.titleString
        The outcome title.
      • event.outcomes.colorString
        The color for the outcome. Valid values are pink and blue.
      • event.outcomes.usersInteger
        The number of users who used Channel Points on this outcome.
      • event.outcomes.channel_pointsInteger
        The total number of Channel Points used on this outcome.
      • event.outcomes.top_predictorsObject[]
        An array of users who used the most Channel Points on this outcome.
        Hide child attributesShow child attributes
        • event.outcomes.top_predictors.user_idString
          The ID of the user.
        • event.outcomes.top_predictors.user_loginString
          The login of the user.
        • event.outcomes.top_predictors.user_nameString
          The display name of the user.
        • event.outcomes.top_predictors.channel_points_wonIntegerNullable
          The number of Channel Points won. This value is always null in the event payload for Prediction progress and Prediction lock. This value is 0 if the outcome did not win or if the Prediction was canceled and Channel Points were refunded.
        • event.outcomes.top_predictors.channel_points_usedInteger
          The number of Channel Points used to participate in the Prediction.
    • event.statusString
      The status of the Channel Points Prediction. Valid values are resolved and canceled.
    • event.started_atString
      The time the Channel Points Prediction started.
    • event.ended_atString
      The time the Channel Points Prediction ended.
Subscription Request Body Example
{
  "type": "channel.prediction.end",
  "version": "1",
  "condition": {
    "broadcaster_user_id": "1337"
  },
  "transport": {
    "method": "webhook",
    "callback": "https://example.com/webhooks/callback",
    "secret": "s3cRe7"
  }
}
Event Payload Example
{
    "subscription": {
        "id": "f1c2a387-161a-49f9-a165-0f21d7a4e1c4",
        "type": "channel.prediction.end",
        "version": "1",
        "status": "enabled",
        "cost": 0,
        "condition": {
            "broadcaster_user_id": "1337"
        },
         "transport": {
            "method": "webhook",
            "callback": "https://example.com/webhooks/callback"
        },
        "created_at": "2019-11-16T10:11:12.634234626Z"
    },
    "event": {
        "id": "1243456",
        "broadcaster_user_id": "1337",
        "broadcaster_user_login": "cool_user",
        "broadcaster_user_name": "Cool_User",
        "title": "Aren't shoes just really hard socks?",
        "winning_outcome_id": "12345",
        "outcomes": [
            {
                "id": "12345",
                "title": "Yeah!",
                "color": "blue",
                "users": 2,
                "channel_points": 15000,
                "top_predictors": [
                    {
                        "user_name": "Cool_User",
                        "user_login": "cool_user",
                        "user_id": "1234",
                        "channel_points_won": 10000,
                        "channel_points_used": 500
                    },
                    {
                        "user_name": "Coolest_User",
                        "user_login": "coolest_user",
                        "user_id": "1236",
                        "channel_points_won": 5000,
                        "channel_points_used": 100
                    }
                ]
            },
            {
                "id": "22435",
                "title": "No!",
                "users": 2,
                "channel_points": 200,
                "color": "pink",
                "top_predictors": [
                    {
                        "user_name": "Cooler_User",
                        "user_login": "cooler_user",
                        "user_id": 12345,
                        "channel_points_won": null,
                        "channel_points_used": 100
                    },
                    {
                        "user_name": "Elite_User",
                        "user_login": "elite_user",
                        "user_id": 1337,
                        "channel_points_won": null,
                        "channel_points_used": 100
                    }
                ]
            }
        ],
        "status": "resolved",
        "started_at": "2020-07-15T17:16:03.17106713Z",
        "ended_at": "2020-07-15T17:16:11.17106713Z"
    }
}

Channel Prediction Lock

The channel.prediction.lock subscription type sends a notification when a Prediction is locked on the specified channel.

Subscription

Type
channel.prediction.lock
Version
1

Authorization

Requires one of the following:

  • A user access token that includes the channel:read:predictions or channel:manage:predictions scope.
  • An app access token.The application, through prior authorization, must have been granted:
    • The channel:read:predictions or channel:manage:predictions scope for the user represented by the broadcaster_user_id event condition.

Subscription Request Body

  • typeStringRequired
    The subscription type name: channel.prediction.lock.
  • versionStringRequired
    The subscription type version: 1.
  • conditionObjectRequired
    Subscription-specific parameters. Pass in the broadcaster user ID for the channel you want to receive prediction lock notifications for.
    Hide child attributesShow child attributes
    • condition.broadcaster_user_idStringRequired
      The broadcaster user ID of the channel for which "prediction lock" notifications will be received.
  • transportObjectRequired
    Transport-specific parameters.
    Hide child attributesShow child attributes
    • transport.methodStringRequired
      The transport method for EventSub.

      Possible values

      • webhook
      • websocket
      • conduit
    • transport.callbackString

      The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

      Specify this field only if method is set to webhook.

      NOTE: Redirects are not followed.

    • transport.secretString

      The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

      Specify this field only if the method is set to webhook.

    • transport.session_idString

      An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

      Specify this field only if the method is set to websocket.

    • transport.conduit_idString

      An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

      Specify this field only if the method is set to conduit.

Event Payload

  • subscriptionObject
    Metadata about the subscription.
    Hide child attributesShow child attributes
    • subscription.idString
      The Subscription ID of the subscription.
    • subscription.typeString
      The notification's subscription type.
    • subscription.versionString
      The version of the subscription.
    • subscription.statusString
      The status of the subscription.
    • subscription.costInteger
      How much the subscription counts against your limit. See Subscription Limits for more information.
    • subscription.conditionObject
      Subscription-specific parameters.
      Hide child attributesShow child attributes
      • subscription.condition.broadcaster_user_idString
        The broadcaster user ID of the channel for which "prediction lock" notifications will be received.
    • subscription.created_atString
      The time the notification was created.
    • subscription.transportObject
      Transport-specific parameters.
      Hide child attributesShow child attributes
      • subscription.transport.methodString
        The transport method for EventSub.

        Possible values

        • webhook
        • websocket
        • conduit
      • subscription.transport.callbackString

        The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

        Specify this field only if method is set to webhook.

        NOTE: Redirects are not followed.

      • subscription.transport.secretString

        The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

        Specify this field only if the method is set to webhook.

      • subscription.transport.session_idString

        An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

        Specify this field only if the method is set to websocket.

      • subscription.transport.conduit_idString

        An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

        Specify this field only if the method is set to conduit.

  • eventObject
    The event information.
    Hide child attributesShow child attributes
    • event.idString
      Channel Points Prediction ID.
    • event.broadcaster_user_idString
      The requested broadcaster ID.
    • event.broadcaster_user_loginString
      The requested broadcaster login.
    • event.broadcaster_user_nameString
      The requested broadcaster display name.
    • event.titleString
      Title for the Channel Points Prediction.
    • event.outcomesObject[]
      An array of outcomes for the Channel Points Prediction. Includes top_predictors.
      Hide child attributesShow child attributes
      • event.outcomes.idString
        The outcome ID.
      • event.outcomes.titleString
        The outcome title.
      • event.outcomes.colorString
        The color for the outcome. Valid values are pink and blue.
      • event.outcomes.usersInteger
        The number of users who used Channel Points on this outcome.
      • event.outcomes.channel_pointsInteger
        The total number of Channel Points used on this outcome.
      • event.outcomes.top_predictorsObject[]
        An array of users who used the most Channel Points on this outcome.
        Hide child attributesShow child attributes
        • event.outcomes.top_predictors.user_idString
          The ID of the user.
        • event.outcomes.top_predictors.user_loginString
          The login of the user.
        • event.outcomes.top_predictors.user_nameString
          The display name of the user.
        • event.outcomes.top_predictors.channel_points_wonIntegerNullable
          The number of Channel Points won. This value is always null in the event payload for Prediction progress and Prediction lock. This value is 0 if the outcome did not win or if the Prediction was canceled and Channel Points were refunded.
        • event.outcomes.top_predictors.channel_points_usedInteger
          The number of Channel Points used to participate in the Prediction.
    • event.started_atString
      The time the Channel Points Prediction started.
    • event.locked_atString
      The time the Channel Points Prediction was locked.
Subscription Request Body Example
{
  "type": "channel.prediction.lock",
  "version": "1",
  "condition": {
    "broadcaster_user_id": "1337"
  },
  "transport": {
    "method": "webhook",
    "callback": "https://example.com/webhooks/callback",
    "secret": "s3cRe7"
  }
}
Event Payload Example
{
    "subscription": {
        "id": "f1c2a387-161a-49f9-a165-0f21d7a4e1c4",
        "type": "channel.prediction.lock",
        "version": "1",
        "status": "enabled",
        "cost": 0,
        "condition": {
            "broadcaster_user_id": "1337"
        },
         "transport": {
            "method": "webhook",
            "callback": "https://example.com/webhooks/callback"
        },
        "created_at": "2019-11-16T10:11:12.634234626Z"
    },
    "event": {
        "id": "1243456",
        "broadcaster_user_id": "1337",
        "broadcaster_user_login": "cool_user",
        "broadcaster_user_name": "Cool_User",
        "title": "Aren't shoes just really hard socks?",
        "outcomes": [
            {
                "id": "1243456",
                "title": "Yeah!",
                "color": "blue",
                "users": 10,
                "channel_points": 15000,
                "top_predictors": [
                    {
                        "user_name": "Cool_User",
                        "user_login": "cool_user",
                        "user_id": "1234",
                        "channel_points_won": null,
                        "channel_points_used": 500
                    },
                    {
                        "user_name": "Coolest_User",
                        "user_login": "coolest_user",
                        "user_id": "1236",
                        "channel_points_won": null,
                        "channel_points_used": 200
                    }
                ]
            },
            {
                "id": "2243456",
                "title": "No!",
                "color": "pink",
                "top_predictors": [
                    {
                        "user_name": "Cooler_User",
                        "user_login": "cooler_user",
                        "user_id": 12345,
                        "channel_points_won": null,
                        "channel_points_used": 5000
                    }
                ]
            }
        ],
        "started_at": "2020-07-15T17:16:03.17106713Z",
        "locked_at": "2020-07-15T17:21:03.17106713Z"
    }
}

Channel Prediction Progress

The channel.prediction.progress subscription type sends a notification when users participate in a Prediction on the specified channel.

Subscription

Type
channel.prediction.progress
Version
1

Authorization

Requires one of the following:

  • A user access token that includes the channel:read:predictions or channel:manage:predictions scope.
  • An app access token.The application, through prior authorization, must have been granted:
    • The channel:read:predictions or channel:manage:predictions scope for the user represented by the broadcaster_user_id event condition.

Subscription Request Body

  • typeStringRequired
    The subscription type name: channel.prediction.progress.
  • versionStringRequired
    The subscription type version: 1.
  • conditionObjectRequired
    Subscription-specific parameters. Pass in the broadcaster user ID for the channel you want to receive prediction progress notifications for.
    Hide child attributesShow child attributes
    • condition.broadcaster_user_idStringRequired
      The broadcaster user ID of the channel for which "prediction progress" notifications will be received.
  • transportObjectRequired
    Transport-specific parameters.
    Hide child attributesShow child attributes
    • transport.methodStringRequired
      The transport method for EventSub.

      Possible values

      • webhook
      • websocket
      • conduit
    • transport.callbackString

      The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

      Specify this field only if method is set to webhook.

      NOTE: Redirects are not followed.

    • transport.secretString

      The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

      Specify this field only if the method is set to webhook.

    • transport.session_idString

      An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

      Specify this field only if the method is set to websocket.

    • transport.conduit_idString

      An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

      Specify this field only if the method is set to conduit.

Event Payload

  • subscriptionObject
    Metadata about the subscription.
    Hide child attributesShow child attributes
    • subscription.idString
      The Subscription ID of the subscription.
    • subscription.typeString
      The notification's subscription type.
    • subscription.versionString
      The version of the subscription.
    • subscription.statusString
      The status of the subscription.
    • subscription.costInteger
      How much the subscription counts against your limit. See Subscription Limits for more information.
    • subscription.conditionObject
      Subscription-specific parameters.
      Hide child attributesShow child attributes
      • subscription.condition.broadcaster_user_idString
        The broadcaster user ID of the channel for which "prediction progress" notifications will be received.
    • subscription.created_atString
      The time the notification was created.
    • subscription.transportObject
      Transport-specific parameters.
      Hide child attributesShow child attributes
      • subscription.transport.methodString
        The transport method for EventSub.

        Possible values

        • webhook
        • websocket
        • conduit
      • subscription.transport.callbackString

        The callback URL where notifications are sent. The URL must use the HTTPS protocol and port 443. See Processing an Event.

        Specify this field only if method is set to webhook.

        NOTE: Redirects are not followed.

      • subscription.transport.secretString

        The secret used to verify the signature. The secret must be an ASCII string that's a minimum of 10 characters long and a maximum of 100 characters long. For information about how the secret is used, see Verifying the event message.

        Specify this field only if the method is set to webhook.

      • subscription.transport.session_idString

        An ID that identifies the WebSocket to send notifications to. When you connect to EventSub using WebSockets, the server returns the ID in the Welcome message.

        Specify this field only if the method is set to websocket.

      • subscription.transport.conduit_idString

        An ID that identifies the conduit to send this notification to. When you create a conduit, the server returns the ID in the API response.

        Specify this field only if the method is set to conduit.

  • eventObject
    The event information.
    Hide child attributesShow child attributes
    • event.idString
      Channel Points Prediction ID.
    • event.broadcaster_user_idString
      The requested broadcaster ID.
    • event.broadcaster_user_loginString
      The requested broadcaster login.
    • event.broadcaster_user_nameString
      The requested broadcaster display name.
    • event.titleString
      Title for the Channel Points Prediction.
    • event.outcomesObject[]
      An array of outcomes for the Channel Points Prediction. Includes top_predictors.
      Hide child attributesShow child attributes
      • event.outcomes.idString
        The outcome ID.
      • event.outcomes.titleString
        The outcome title.
      • event.outcomes.colorString
        The color for the outcome. Valid values are pink and blue.
      • event.outcomes.usersInteger
        The number of users who used Channel Points on this outcome.
      • event.outcomes.channel_pointsInteger
        The total number of Channel Points used on this outcome.
      • event.outcomes.top_predictorsObject[]
        An array of users who used the most Channel Points on this outcome.
        Hide child attributesShow child attributes
        • event.outcomes.top_predictors.user_idString
          The ID of the user.
        • event.outcomes.top_predictors.user_loginString
          The login of the user.
        • event.outcomes.top_predictors.user_nameString
          The display name of the user.
        • event.outcomes.top_predictors.channel_points_wonIntegerNullable
          The number of Channel Points won. This value is always null in the event payload for Prediction progress and Prediction lock. This value is 0 if the outcome did not win or if the Prediction was canceled and Channel Points were refunded.
        • event.outcomes.top_predictors.channel_points_usedInteger
          The number of Channel Points used to participate in the Prediction.
    • event.started_atString
      The time the Channel Points Prediction started.
    • event.locks_atString
      The time the Channel Points Prediction will automatically lock.
Subscription Request Body Example
{
  "type": "channel.prediction.progress",
  "version": "1",
  "condition": {
    "broadcaster_user_id": "1337"
  },
  "transport": {
    "method": "webhook",
    "callback": "https://example.com/webhooks/callback",
    "secret": "s3cRe7"
  }
}
Event Payload Example
{
    "subscription": {
        "id": "f1c2a387-161a-49f9-a165-0f21d7a4e1c4",
        "type": "channel.prediction.progress",
        "version": "1",
        "status": "enabled",
        "cost": 0,
        "condition": {
            "broadcaster_user_id": "1337"
        },
         "transport": {
            "method": "webhook",
            "callback": "https://example.com/webhooks/callback"
        },
        "created_at": "2019-11-16T10:11:12.634234626Z"
    },
    "event": {
        "id": "1243456",
        "broadcaster_user_id": "1337",
        "broadcaster_user_login": "cool_user",
        "broadcaster_user_name": "Cool_User",
        "title": "Aren't shoes just really hard socks?",
        "outcomes": [
            {
                "id": "1243456",
                "title": "Yeah!",
                "color": "blue",
                "users": 10,
                "channel_points": 15000,
                "top_predictors": [
                    {
                        "user_name": "Cool_User",
                        "user_login": "cool_user",
                        "user_id": "1234",
                        "channel_points_won": null,
                        "channel_points_used": 500
                    },
                    {
                        "user_name": "Coolest_User",
                        "user_login": "coolest_user",
                        "user_id": "1236",
                        "channel_points_won": null,
                        "channel_points_used": 200
                    }
                ]
            },
            {
                "id": "2243456",
                "title": "No!",
                "color": "pink",
                "top_predictors": [
                    {
                        "user_name": "Cooler_User",
                        "user_login": "cooler_user",
                        "user_id": 12345,
                        "channel_points_won": null,
                        "channel_points_used": 5000
                    }
                ]
            }
        ],
        "started_at": "2020-07-15T17:16:03.17106713Z",
        "locks_at": "2020-07-15T17:21:03.17106713Z"
    }
}