Videos
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
視訊
JSON 表示法
|
{
"url": string,
"source": enum (Source ),
"id": string,
"videoProperties": {
object (VideoProperties )
}
}
|
欄位
|
url
|
string
影片網址。只要來源影片存在,且分享設定未變更,網址就會有效。
|
source
|
enum (Source )
影片來源。
|
id
|
string
影片來源的專屬 ID。
|
videoProperties
|
object (VideoProperties )
影片的屬性。
|
來源
列舉
|
SOURCE_UNSPECIFIED
|
未指定影片來源。 |
YOUTUBE
|
影片來源為 YouTube。
|
DRIVE
|
影片來源為 Google 雲端硬碟。
|
VideoProperties
JSON 表示法
|
{
"outline": {
object (Outline )
},
"autoPlay": boolean,
"start": integer,
"end": integer,
"mute": boolean
}
|
欄位
|
outline
|
object (Outline )
影片大綱。針對簡報編輯器中新建的影片,預設大綱會與預設大綱相符。
|
autoPlay
|
boolean
是否要在以呈現模式顯示網頁時啟用影片自動播放功能。預設值為 false。
|
start
|
integer
要開始播放的時間點 (從影片開頭開始計算,以秒為單位)。如果已設定,開始時間應早於結束時間。如果這個值超過影片長度 (以秒為單位),系統就會從最後 1 秒開始播放影片。如未設定,影片會從開頭播放。
|
end
|
integer
結束播放的時間 (從影片開頭開始計算,以秒為單位)。如果已設定,結束時間應晚於開始時間。如果未設定,或設為超過影片長度的值,影片將播放到最後為止。
|
mute
|
boolean
是否要在影片播放期間將音訊設為靜音。預設值為 false。
|
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-03-21 (世界標準時間)。
[null,null,["上次更新時間:2025-03-21 (世界標準時間)。"],[],[],null,["# Videos\n\n### Video\n\n\nA\n[PageElement](/workspace/slides/api/reference/rest/v1/presentations.pages#Page.PageElement)\nkind representing a video.\n\n| JSON representation |\n|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"url\": string, \"source\": enum (/workspace/slides/api/reference/rest/v1/presentations.pages/videos#Page.Source), \"id\": string, \"videoProperties\": { object (/workspace/slides/api/reference/rest/v1/presentations.pages/videos#Page.VideoProperties) } } ``` |\n\n| Fields ||\n|-------------------|------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `url` | `string` An URL to a video. The URL is valid as long as the source video exists and sharing settings do not change. |\n| `source` | `enum (`[Source](/workspace/slides/api/reference/rest/v1/presentations.pages/videos#Page.Source)`)` The video source. |\n| `id` | `string` The video source's unique identifier for this video. |\n| `videoProperties` | `object (`[VideoProperties](/workspace/slides/api/reference/rest/v1/presentations.pages/videos#Page.VideoProperties)`)` The properties of the video. |\n\n### Source\n\n\nThe video sources.\n\n| Enums ||\n|----------------------|-----------------------------------|\n| `SOURCE_UNSPECIFIED` | The video source is unspecified. |\n| `YOUTUBE` | The video source is YouTube. |\n| `DRIVE` | The video source is Google Drive. |\n\n### VideoProperties\n\n\nThe properties of the\n[Video](/workspace/slides/api/reference/rest/v1/presentations.pages/videos#Page.Video).\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"outline\": { object (/workspace/slides/api/reference/rest/v1/presentations.pages/other#Page.Outline) }, \"autoPlay\": boolean, \"start\": integer, \"end\": integer, \"mute\": boolean } ``` |\n\n| Fields ||\n|------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `outline` | `object (`[Outline](/workspace/slides/api/reference/rest/v1/presentations.pages/other#Page.Outline)`)` The outline of the video. The default outline matches the defaults for new videos created in the Slides editor. |\n| `autoPlay` | `boolean` Whether to enable video autoplay when the page is displayed in present mode. Defaults to false. |\n| `start` | `integer` The time at which to start playback, measured in seconds from the beginning of the video. If set, the start time should be before the end time. If you set this to a value that exceeds the video's length in seconds, the video will be played from the last second. If not set, the video will be played from the beginning. |\n| `end` | `integer` The time at which to end playback, measured in seconds from the beginning of the video. If set, the end time should be after the start time. If not set or if you set this to a value that exceeds the video's length, the video will be played until its end. |\n| `mute` | `boolean` Whether to mute the audio during video playback. Defaults to false. |"]]