Video API, gRPC: ThumbnailService
Written by
Updated at April 4, 2024
Thumbnail management service.
Call | Description |
---|---|
List | List thumbnails for channel. |
Create | Create thumbnail. |
BatchGenerateDownloadURLs | Generate urls for download images. |
GenerateUploadURL | Generate url for upload image. |
Calls ThumbnailService
List
List thumbnails for channel.
rpc List (ListThumbnailRequest) returns (ListThumbnailResponse)
ListThumbnailRequest
Field | Description |
---|---|
channel_id | string ID of the channel. |
page_size | int64 The maximum number of the results per page to return. Default value: 100. |
page_token | string Page token for getting the next page of the result. |
ListThumbnailResponse
Field | Description |
---|---|
thumbnails[] | Thumbnail List of thumbnails. |
next_page_token | string Token for getting the next page. |
Thumbnail
Field | Description |
---|---|
id | string ID of the thumbnail. |
channel_id | string ID of the channel where the thumbnail was created. |
created_at | google.protobuf.Timestamp Time when thumbnail was created. |
Create
Create thumbnail.
rpc Create (CreateThumbnailRequest) returns (operation.Operation)
Metadata and response of Operation:
Operation.metadata:CreateThumbnailMetadata
Operation.response:Thumbnail
CreateThumbnailRequest
Field | Description |
---|---|
channel_id | string ID of the channel. |
Operation
Field | Description |
---|---|
id | string ID of the operation. |
description | string Description of the operation. 0-256 characters long. |
created_at | google.protobuf.Timestamp Creation timestamp. |
created_by | string ID of the user or service account who initiated the operation. |
modified_at | google.protobuf.Timestamp The time when the Operation resource was last modified. |
done | bool If the value is false , it means the operation is still in progress. If true , the operation is completed, and either error or response is available. |
metadata | google.protobuf.Any Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any. |
result | oneof: error or response The operation result. If done == false and there was no failure detected, neither error nor response is set. If done == false and there was a failure detected, error is set. If done == true , exactly one of error or response is set. |
error | google.rpc.Status The error result of the operation in case of failure or cancellation. |
response | google.protobuf.Any if operation finished successfully. |
CreateThumbnailMetadata
Field | Description |
---|---|
thumbnail_id | string ID of the thumbnail. |
Thumbnail
Field | Description |
---|---|
id | string ID of the thumbnail. |
channel_id | string ID of the channel where the thumbnail was created. |
created_at | google.protobuf.Timestamp Time when thumbnail was created. |
BatchGenerateDownloadURLs
Generate urls for download images.
rpc BatchGenerateDownloadURLs (BatchGenerateDownloadURLsRequest) returns (BatchGenerateDownloadURLsResponse)
BatchGenerateDownloadURLsRequest
Field | Description |
---|---|
channel_id | string ID of the channel. |
thumbnail_ids[] | string List of thumbnails IDs. |
BatchGenerateDownloadURLsResponse
Field | Description |
---|---|
download_urls[] | ThumbnailDownloadURL List of download urls. |
ThumbnailDownloadURL
Field | Description |
---|---|
thumbnail_id | string ID of the thumbnail. |
download_url | string Download url. |
GenerateUploadURL
Generate url for upload image.
rpc GenerateUploadURL (GenerateThumbnailUploadURLRequest) returns (GenerateThumbnailUploadURLResponse)
GenerateThumbnailUploadURLRequest
Field | Description |
---|---|
thumbnail_id | string ID of the thumbnail. |
GenerateThumbnailUploadURLResponse
Field | Description |
---|---|
upload_url | string Upload url. |