创建机型参数库,创建云手机时可从机型库里匹配一组预设参数。
下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。
| 参数 | 类型 | 是否必选 | 示例值 | 描述 |
|---|---|---|---|---|
| Action | String | 是 | AddPropertyRule | 接口名称。当前 API 的名称为 AddPropertyRule。 |
| Version | String | 是 | 2023-10-30 | 接口版本。当前 API 的版本为 2023-10-30。 |
| 参数 | 类型 | 是否必选 | 示例值 | 描述 |
|---|---|---|---|---|
| RuleName | String | 是 | Oppo1 | 机型参数规则名称,账户下规则名称唯一,长度不能超过 200 个字符。 |
| OverlayProperty | Array of SystemProperty | 否 | - | 实例 Settings 系统属性,非持久化,立即生效,重启实例后失效;详细信息,参考 SystemProperty定义。 |
| OverlayPersistProperty | Array of SystemProperty | 否 | - | 实例初始化系统属性,持久化,重启实例后生效;详细信息,参考 SystemProperty定义:适用于只读系统属性,或 AOSP 原生非持久化的系统属性的修改,如 ro.product.model。 |
| OverlaySettings | Array of Settings | 否 | - | 实例 Settings 属性列表;详细信息,参考 Settings定义。 |
| 参数 | 类型 | 是否必选 | 示例值 | 描述 |
|---|---|---|---|---|
| SystemPropertyName | String | 是 | ro.product.name | 属性名称,可修改的系统属性及属性值,参考 System Properties 属性列表。 |
SystemPropertyValue | String | 是 |
| 属性值。取值如下:
说明 当 |
SystemPropertyValueType | String | 是 |
| 属性值数据类型。取值如下:
|
| 参数 | 类型 | 是否必选 | 示例值 | 描述 |
|---|---|---|---|---|
| SettingsName | String | 是 | locale_language | 属性名称,可修改的 Settings 属性及属性值,参考 Settings 属性列表。 |
SettingsType | String | 是 |
| 设置类型,取值如下:
|
SettingsValueType | String | 是 |
| 属性值数据类型,取值如下:
|
SettingsValue | String | 是 |
| 属性值。各类型属性取值示例如下:
|
本接口无特有的返回参数。更多信息请见返回结构。
POST https://open.volcengineapi.com?Action=AddPropertyRule&Version=2023-10-30 { "RuleName": "Oppo1", "OverlayProperty": [ { "SystemPropertyName": "ro.product.name", "SystemPropertyValue": "samsung", "SystemPropertyValueType": "string" } ], "OverlayPersistProperty": [ { "SystemPropertyName": "ro.product.name", "SystemPropertyValue": "samsung", "SystemPropertyValueType": "string" } ], "OverlaySettings": [ { "SettingsName": "locale_language", "SettingsType": "global", "SettingsValue": "on", "SettingsValueType": "string" } ] }
{ "ResponseMetadata": { "Action": "AddPropertyRule", "Region": "cn-north-1", "Service": "ACEP", "Version": "2023-10-30", "RequestId": "20230604110420****100232280022D31" }, "Result": "success" }
您可访问公共错误码,获取更多错误码信息。