REST Resource: systemapks.variants
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
資源:Variant
適合納入系統映像檔的 APK。SystemApksService 的資源。
欄位 |
variantId |
integer (uint32 format)
僅供輸出。先前建立的系統 APK 變化版本的 ID。
|
deviceSpec |
object (DeviceSpec )
用來產生 APK 的裝置規格。
|
options |
object (SystemApkOptions )
選用設定。套用至產生的 APK 的選項。
|
DeviceSpec
JSON 表示法 |
{
"supportedAbis": [
string
],
"supportedLocales": [
string
],
"screenDensity": integer
} |
欄位 |
supportedAbis[] |
string
依偏好順序提供支援 ABI 架構。這個值應為平台回報的字串,例如:「armeabi-v7a」、「x86_64」。
|
supportedLocales[] |
string
所有已安裝的地區,以 BCP-47 字串表示,例如「en-US」。
|
screenDensity |
integer (uint32 format)
螢幕 dpi。
|
SystemApkOptions
JSON 表示法 |
{
"uncompressedNativeLibraries": boolean,
"uncompressedDexFiles": boolean,
"rotated": boolean
} |
欄位 |
uncompressedNativeLibraries |
boolean
系統 APK 是否使用未壓縮的原生資料庫產生。
|
uncompressedDexFiles |
boolean
是否使用未壓縮 dex 檔案產生系統 APK。
|
rotated |
boolean
是否使用輪替金鑰簽署系統 APK。
|
方法 |
|
建立 APK,適合從已上傳的 Android App Bundle 中的系統映像檔中加入。 |
|
下載先前建立的系統 APK,以便納入系統映像檔。 |
|
傳回先前建立的系統 APK 變化版本。 |
|
傳回先前建立的系統 APK 變化版本清單。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-26 (世界標準時間)。
[null,null,["上次更新時間:2025-07-26 (世界標準時間)。"],[[["\u003cp\u003eSystem APK variants are APKs suitable for inclusion in a system image, customizable by device specifications and options.\u003c/p\u003e\n"],["\u003cp\u003eDevice specifications for system APKs include supported ABIs, locales, and screen density.\u003c/p\u003e\n"],["\u003cp\u003eSystem APK options can include uncompressed native libraries, dex files, and rotated key signing.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can create, download, retrieve information about, and list system APK variants using the provided methods.\u003c/p\u003e\n"]]],["System APK variants are defined by `variantId`, `deviceSpec`, and `options`. `DeviceSpec` includes supported ABIs, locales, and screen density. `SystemApkOptions` manage uncompressed native libraries, uncompressed dex files, and rotated keys. Key actions include `create` to generate a system APK from an app bundle, `download` to retrieve a created APK, `get` to fetch a specific variant, and `list` to retrieve all created variants. These methods are all actions related to system APKs.\n"],null,["# REST Resource: systemapks.variants\n\n- [Resource: Variant](#Variant)\n - [JSON representation](#Variant.SCHEMA_REPRESENTATION)\n- [DeviceSpec](#DeviceSpec)\n - [JSON representation](#DeviceSpec.SCHEMA_REPRESENTATION)\n- [SystemApkOptions](#SystemApkOptions)\n - [JSON representation](#SystemApkOptions.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: Variant\n-----------------\n\nAPK that is suitable for inclusion in a system image. The resource of SystemApksService.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"variantId\": integer, \"deviceSpec\": { object (/android-publisher/api-ref/rest/v3/systemapks.variants#DeviceSpec) }, \"options\": { object (/android-publisher/api-ref/rest/v3/systemapks.variants#SystemApkOptions) } } ``` |\n\n| Fields ||\n|--------------|----------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `variantId` | `integer (`[uint32](https://developers.google.com/discovery/v1/type-format)` format)` Output only. The ID of a previously created system APK variant. |\n| `deviceSpec` | `object (`[DeviceSpec](/android-publisher/api-ref/rest/v3/systemapks.variants#DeviceSpec)`)` The device spec used to generate the APK. |\n| `options` | `object (`[SystemApkOptions](/android-publisher/api-ref/rest/v3/systemapks.variants#SystemApkOptions)`)` Optional. Options applied to the generated APK. |\n\nDeviceSpec\n----------\n\nThe device spec used to generate a system APK.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------|\n| ``` { \"supportedAbis\": [ string ], \"supportedLocales\": [ string ], \"screenDensity\": integer } ``` |\n\n| Fields ||\n|----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `supportedAbis[]` | `string` Supported ABI architectures in the order of preference. The values should be the string as reported by the platform, e.g. \"armeabi-v7a\", \"x86_64\". |\n| `supportedLocales[]` | `string` All installed locales represented as BCP-47 strings, e.g. \"en-US\". |\n| `screenDensity` | `integer (`[uint32](https://developers.google.com/discovery/v1/type-format)` format)` Screen dpi. |\n\nSystemApkOptions\n----------------\n\nOptions for system APKs.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------|\n| ``` { \"uncompressedNativeLibraries\": boolean, \"uncompressedDexFiles\": boolean, \"rotated\": boolean } ``` |\n\n| Fields ||\n|-------------------------------|--------------------------------------------------------------------------------|\n| `uncompressedNativeLibraries` | `boolean` Whether system APK was generated with uncompressed native libraries. |\n| `uncompressedDexFiles` | `boolean` Whether system APK was generated with uncompressed dex files. |\n| `rotated` | `boolean` Whether to use the rotated key for signing the system APK. |\n\n| Methods ------- ||\n|---------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------|\n| ### [create](/android-publisher/api-ref/rest/v3/systemapks.variants/create) | Creates an APK which is suitable for inclusion in a system image from an already uploaded Android App Bundle. |\n| ### [download](/android-publisher/api-ref/rest/v3/systemapks.variants/download) | Downloads a previously created system APK which is suitable for inclusion in a system image. |\n| ### [get](/android-publisher/api-ref/rest/v3/systemapks.variants/get) | Returns a previously created system APK variant. |\n| ### [list](/android-publisher/api-ref/rest/v3/systemapks.variants/list) | Returns the list of previously created system APK variants. |"]]