ModifyCasterComponent
Modifies a production studio component.
Operation description
Modifies a production studio component. This operation currently supports text, image, and translated caption components.
Rate limit
The rate limit for this operation is 10 queries per second (QPS) per user. If the limit is exceeded, API calls are throttled, which may affect your services. Call this operation at a reasonable rate.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
live:ModifyCasterComponent |
update |
*Caster
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
No |
The region ID. |
cn-shanghai |
| CasterId |
string |
Yes |
The ID of the production studio.
Note
The name of the production studio in the production studio list on the Cloud Production Studio page is the production studio ID. |
LIVEPRODUCER_POST-cn-0pp1czt**** |
| ComponentId |
string |
Yes |
The ID of the component. If you added the component by calling the AddCasterComponent operation, obtain the value from the ComponentId response parameter. |
05ab713c-676e-49c0-96ce-cc408da1**** |
| ComponentName |
string |
No |
The name of the component. Default value: the component ID. |
text01 |
| ComponentType |
string |
No |
The type of the component. Valid values:
|
text |
| Effect |
string |
No |
The display effect of the component. Valid values:
|
animateV |
| ComponentLayer |
string |
No |
The size and layout information of the layer. The value is in JSON format. The elements are described as follows:
|
{"HeightNormalized":"1","PositionRefer":"topRight","WidthNormalized":"0","PositionNormalized":["0.1","0.2"]} |
| TextLayerContent |
string |
No |
The properties of the layer element. The value is in JSON format. The element properties are described as follows: Important This parameter is required when the ComponentType parameter is set to text.
|
{"BorderWidthNormalized":"1","SizeNormalized":"0.2","Color":"0x000000","FontName":"KaiTi","BorderColor":"0x000000","Text":"hello world!"} |
| ImageLayerContent |
string |
No |
The properties of the layer element. The value is in JSON format. Important This parameter is required when the ComponentType parameter is set to image.
MaterialId specifies the ID of the media asset. |
{"MaterialId":"6cf724c6ebfd4a59b5b3cec6f10d5ecf"} |
| CaptionLayerContent |
string |
No |
The properties of the layer element. The value is in JSON format. The element properties are described as follows: Important This parameter is required when the ComponentType parameter is set to caption.
|
{"BorderWidthNormalized":0.01,"SizeNormalized":0.05,"Color":"0x000000","LocationId":"RV01","SourceLan":"cn","FontName":"KaiTi","BorderColor":"0xffffff"} |
Production studio fonts
| Font | FontName value |
| KaiTi | KaiTi |
| Alibaba PuHuiTi Regular | AlibabaPuHuiTi-Regular |
| Alibaba PuHuiTi Bold | AlibabaPuHuiTi-Bold |
| Alibaba PuHuiTi Light | AlibabaPuHuiTi-Light |
| Noto Sans Hans Regular | NotoSansHans-Regular |
| Noto Sans Hans Bold | NotoSansHans-Bold |
| Noto Sans Hans Light | NotoSansHans-Light |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| ComponentId |
string |
The ID of the component. You can use this ID as a request parameter to query the list of production studio components. |
05ab713c-676e-49c0-96ce-cc408da1**** |
| RequestId |
string |
The ID of the request. |
16A96B9A-F203-4EC5-8E43-CB92E68F4CD8 |
Examples
Success response
JSON format
{
"ComponentId": "05ab713c-676e-49c0-96ce-cc408da1****",
"RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F4CD8"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidUserId.Malformed | %s, please check userId. | The userId passed in is invalid, please check. |
| 400 | InvalidCasterId.Malformed | %s, please check and try again later. | The parameter CasterId is invalid, please check and try again. |
| 400 | MissingParameter | %s. | Missing parameter |
| 400 | InvalidParameter.Malformed | There are invalid parameters: %s. | There are invalid parameters: %s. |
| 400 | InvalidPositionNormalized.Malformed | %s, please check and try again later. | The parameter PositionNormalized is invalid, please check and try again. |
| 401 | IllegalOperation | %s, please check and try again later. | Operation not allowed, please check and try again. |
| 500 | InternalError | %s, please try again later. | Internal error, please try again later. |
| 404 | InvalidCaster.NotFound | %s, please check and try again later. | The guide station does not exist, please check and try again. |
| 404 | InvalidComponent.NotFound | %s, please check and try again later. | The component to be operated does not exist. Please check and try again. |
| 404 | CanvasNotExist | %s, please check and try again later. | Canvas does not exist, please check and try again. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.