Class WebhooksApi


  • public class WebhooksApi
    extends Object
    • Constructor Detail

      • WebhooksApi

        public WebhooksApi​(ApiClient apiClient)
    • Method Detail

      • getApiClient

        public ApiClient getApiClient()
      • setApiClient

        public void setApiClient​(ApiClient apiClient)
      • delete

        public void delete​(String webhookId)
                    throws ApiException
        Delete a Webhook This endpoint will delete the indicated webhook.
        Parameters:
        webhookId - The webhook you wish to delete. (required)
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        204 No Content -
        404 Not Found -
      • deleteWithHttpInfo

        public ApiResponse<Void> deleteWithHttpInfo​(String webhookId)
                                             throws ApiException
        Delete a Webhook This endpoint will delete the indicated webhook.
        Parameters:
        webhookId - The webhook you wish to delete. (required)
        Returns:
        ApiResponse<Void>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        204 No Content -
        404 Not Found -
      • get

        public Webhook get​(String webhookId)
                    throws ApiException
        Show Webhook details This call provides the same JSON information provided on Webjhook creation.
        Parameters:
        webhookId - The unique webhook you wish to retreive details on. (required)
        Returns:
        Webhook
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 Success -
      • getWithHttpInfo

        public ApiResponse<Webhook> getWithHttpInfo​(String webhookId)
                                             throws ApiException
        Show Webhook details This call provides the same JSON information provided on Webjhook creation.
        Parameters:
        webhookId - The unique webhook you wish to retreive details on. (required)
        Returns:
        ApiResponse<Webhook>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        200 Success -
      • list

        public WebhooksApi.APIlistRequest list()
        List all webhooks Requests to this endpoint return a list of your webhooks (with all their details). You can filter what the webhook list that the API returns using the parameters described below.
        Returns:
        APIlistRequest
        Http Response Details:
        Status Code Description Response Headers
        200 Success -
      • create

        public Webhook create​(WebhooksCreationPayload webhooksCreationPayload)
                       throws ApiException
        Create Webhook Webhooks can push notifications to your server, rather than polling api.video for changes. We currently offer four events: * ```video.encoding.quality.completed``` When a new video is uploaded into your account, it will be encoded into several different HLS sizes/bitrates. When each version is encoded, your webhook will get a notification. It will look like ```{ \\\"type\\\": \\\"video.encoding.quality.completed\\\", \\\"emittedAt\\\": \\\"2021-01-29T16:46:25.217+01:00\\\", \\\"videoId\\\": \\\"viXXXXXXXX\\\", \\\"encoding\\\": \\\"hls\\\", \\\"quality\\\": \\\"720p\\\"} ```. This request says that the 720p HLS encoding was completed. * ```live-stream.broadcast.started``` When a livestream begins broadcasting, the broadcasting parameter changes from false to true, and this webhook fires. * ```live-stream.broadcast.ended``` This event fores when the livestream has finished broadcasting, and the broadcasting parameter flips from false to true. * ```video.source.recorded``` This event is similar to ```video.encoding.quality.completed```, but tells you if a livestream has been recorded as a VOD.
        Parameters:
        webhooksCreationPayload - (required)
        Returns:
        Webhook
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        201 Created -
        400 Bad Request -
      • createWithHttpInfo

        public ApiResponse<Webhook> createWithHttpInfo​(WebhooksCreationPayload webhooksCreationPayload)
                                                throws ApiException
        Create Webhook Webhooks can push notifications to your server, rather than polling api.video for changes. We currently offer four events: * ```video.encoding.quality.completed``` When a new video is uploaded into your account, it will be encoded into several different HLS sizes/bitrates. When each version is encoded, your webhook will get a notification. It will look like ```{ \\\"type\\\": \\\"video.encoding.quality.completed\\\", \\\"emittedAt\\\": \\\"2021-01-29T16:46:25.217+01:00\\\", \\\"videoId\\\": \\\"viXXXXXXXX\\\", \\\"encoding\\\": \\\"hls\\\", \\\"quality\\\": \\\"720p\\\"} ```. This request says that the 720p HLS encoding was completed. * ```live-stream.broadcast.started``` When a livestream begins broadcasting, the broadcasting parameter changes from false to true, and this webhook fires. * ```live-stream.broadcast.ended``` This event fores when the livestream has finished broadcasting, and the broadcasting parameter flips from false to true. * ```video.source.recorded``` This event is similar to ```video.encoding.quality.completed```, but tells you if a livestream has been recorded as a VOD.
        Parameters:
        webhooksCreationPayload - (required)
        Returns:
        ApiResponse<Webhook>
        Throws:
        ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
        Http Response Details:
        Status Code Description Response Headers
        201 Created -
        400 Bad Request -