Update a Firmware
Updates a firmware, such as the firmware version, file, and remark. All fields are optional, and only the specified fields are updated.
Request URL
PUT {base_url}/uc-cautop/api/v1/firmwares/{id}
Request parameters
- Headers
-
Parameter Required Type Description Authorization Yes String The access token used for authentication. Format: Bearer
{access_token}.x-tenant-code Yes String The tenant name. Note: You can obtain tenant name using the Query Tenants interface.
- Path parameters
-
Parameter Required Type Description id Yes String The firmware ID. You can obtain the ID using the Search Firmwares interface.
- Body parameters
-
Parameter Required Type Description firmwareVersion No String The firmware version. If omitted, no change is made. fileName No String The original file name of the firmware file. If omitted, no change is made. fileResourceId No String The ID of the file in the resource service. 0means no change.fileSize No String The size of the file, in bytes. 0means no change.remark No String The remark of the firmware. If omitted, no change is made. An empty string clears the remark. assignTo No Object<Assign_To> The assignment configuration of the firmware.
- Assign_To
-
Parameter Required Type Description myTenantAssignment No Object<My_Tenant_Assignment> The assignment configuration for the tenants directly under the administrator. resellerAssignment No Object<Reseller_Assignment> The assignment configuration for resellers.
- My_Tenant_Assignment
-
Parameter Required Type Description enabled No Boolean Whether to assign the firmware to tenants. falseor omitted means not assigned.scope No String The assignment scope: - all: The firmware is visible to all the tenants directly under the administrator. - specific: The firmware is visible only to the specified tenants. tenantCodes No Array<String> The codes of the tenants. This parameter takes effect only when scopeisspecific.
- Reseller_Assignment
-
Parameter Required Type Description enabled No Boolean Whether to assign the firmware to resellers. falseor omitted means not assigned.scope No String The assignment scope: - all: The firmware is visible to all the resellers. - specific: The firmware is visible only to the specified resellers. resellers No Array<Reseller_Assign_Item> The list of reseller assignments. This parameter takes effect only when scopeisspecific.excludedResellerIds No Array<String> The IDs of the excluded resellers. This parameter takes effect only when scopeisall, and the excluded resellers cannot see the firmware.
- Reseller_Assign_Item
-
Parameter Required Type Description resellerId Yes String The user ID of the reseller. tenantScope No String The tenant scope under the reseller: - all: The firmware is visible to all the tenants of the reseller. - specific: The firmware is visible only to the specified tenants. - none: The firmware is visible only to the reseller itself. tenantCodes No Array<String> The codes of the tenants. This parameter takes effect only when tenantScopeisspecific.
Response parameters
| Parameter | Type | Description |
|---|---|---|
| requestId | String | The unique ID of the request, which can be used to quickly locate the request. |
| code | String | The HTTP status code of the request.
|
| message | String | The status message of the request. |
| detailMessage | String | The detailed error information. When the request is successful, this parameter returns empty. |
| result | Object<Firmware> | The updated firmware. |
- Firmware
-
Parameter Type Description id String The unique identifier of the firmware. ucId String The ID of the UC domain that the firmware belongs to. vendor String The vendor identifier of the phone, for example Yealink,Fanvil,Grandstream.model String The model of the phone, for example T54W,V65.firmwareVersion String The firmware version, for example 97.0.0.1.fileName String The original file name of the firmware file. fileResourceId String The ID of the file in the resource service. fileSize String The size of the file, in bytes. remark String The remark of the firmware. createdAt String The time when the firmware was created, in Unix timestamp format (seconds). updatedAt String The time when the firmware was last updated, in Unix timestamp format (seconds). ownerType String The owner type of the firmware: - admin: Administrator. - reseller: Reseller. ownerId String The ID of the owner. ownerEmail String The email address of the owner's primary account. assignTo Object<Assign_To> The assignment configuration of the firmware.