違規內容
外掛程式可執行的功能受到一些限制。請避免這些陷阱,提升使用者的整體體驗。
一般限制
以下限制適用於所有外掛程式。請勿執行下列操作:
變更 Google Workspace 中的功能
外掛程式架構旨在強化 Google Workspace 應用程式,而非增加限制。因此,您無法變更現有功能或鎖定 Google Workspace 文件共用模式。
向使用者收取安裝費用
我們不會向使用者收取安裝外掛程式的費用,且外掛程式不得包含廣告。不過,您可以使用自己的付款系統,或呼叫現有的帳單資料庫。外掛程式可以連結向使用者收費的非 Google 服務。
偵測多個事件
除了特定觸發事件外,外掛程式無法得知使用者在外掛程式之外的行為。舉例來說,您無法偵測使用者點選主機應用程式工具列的時間。您可以透過側欄的用戶端程式碼,輪詢檔案內容是否有變更,但這會造成輕微延遲。
Google Workspace 外掛程式
下列限制僅適用於 Google Workspace 外掛程式和卡片服務的使用情形。請勿執行下列操作:
擴充所有 Google Workspace 應用程式
Google Workspace 外掛程式只能擴充 Gmail、日曆、雲端硬碟、Meet、文件、試算表和簡報。日後 Google Workspace 外掛程式將可擴充其他 Google Workspace 應用程式。
編輯器中的文件內容
Google Workspace 外掛程式尚不支援在編輯器中使用文件內容。也就是說,您無法使用 SpreadsheetApp.getActiveSpreadsheet()
等方法取得目前的文件。
使用 HTML/CSS 或用戶端指令碼
Google Workspace 外掛程式必須使用以卡片為基礎的介面。無法使用編輯器外掛程式支援的 HTML/CSS 介面。Google Workspace 外掛程式會使用以小工具為基礎的方法建構使用者介面。這樣一來,外掛程式就能在電腦和行動平台上正常運作,而您也不必為每個平台建立介面。
完整的行動裝置支援
目前,Google Workspace 外掛程式可在電腦網頁用戶端上運作。Gmail 行動應用程式也支援情境觸發功能 (也就是 Gmail 訊息閱讀功能)。Gmail、日曆或雲端硬碟行動應用程式目前尚未提供非情境首頁。Google Workspace 外掛程式無法在行動網頁瀏覽器中使用。
使用 Apps Script 觸發條件
您無法在 Google Workspace 外掛程式中建立或使用 Apps Script 簡易觸發條件。
使用可擴充向量圖形圖片
目前無法在資訊卡服務資訊卡和小工具中使用 SVG 圖片。
基於效能考量,您無法在資訊卡中加入超過 100 個小工具或 100 個資訊卡版面。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-01-30 (世界標準時間)。
[null,null,["上次更新時間:2025-01-30 (世界標準時間)。"],[[["Google Workspace add-ons enhance, but do not fundamentally change, existing Google Workspace features."],["Add-ons cannot directly charge users for installation or include ads but can integrate with external billing systems."],["Add-on functionality is limited in terms of event detection and contextual triggering within certain Google Workspace apps."],["Google Workspace add-ons use a card-based interface system, rather than traditional HTML, CSS, or client-side scripting."],["While add-ons are largely desktop-focused, some contextual triggering is supported within the Gmail mobile app."]]],["Add-ons are restricted from altering Google Workspace features, charging users for installation, or detecting user actions outside the add-on. Google Workspace add-ons are limited to Gmail, Calendar, Drive, Meet, Docs, Sheets, and Slides, and must use card-based interfaces, not HTML/CSS. They cannot access document context in editors or utilize Apps Script triggers. Additionally, SVG images and exceeding 100 widgets per card are prohibited. Full mobile support is also unavailable, and only desktop web clients are supported.\n"]]