Updates the name and description of a parser.

Usage notes

After you call the CreateParser operation to create a parser, you can update the name and description of the parser based on the return value of the ParserId parameter.

QPS limits

Each Alibaba Cloud account can run up to 10 queries per second (QPS).

Note The RAM users of an Alibaba Cloud account share the quota of the Alibaba Cloud account.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

ParameterTypeRequiredExampleDescription
ActionStringYesUpdateParser

The operation that you want to perform. Set the value to UpdateParser.

ParserIdLongYes1001

The ID of the parser. You can call the ListParser operation to query parsers and obtain the ID of the parser.

IotInstanceIdStringNoiot-8t***

The ID of the instance. You can view the ID of the instance on the Overview page in the IoT Platform console.

Important
  • If your instance has an ID, you must specify the ID for this parameter. Otherwise, the call fails.
  • If no Overview page or ID is generated for your instance, you do not need to configure this parameter.

For more information, see Overview.

DescriptionStringNoForward data.

The description of the parser.

NameStringNoDataParserTwo

The name of the parser. The name must be 1 to 30 characters in length, and can contain letters, digits, underscores (_), and hyphens (-).

In addition to the preceding operation-specific request parameters, you must configure common request parameters when you call this operation. For more information, see Common request parameters.

Response parameters

ParameterTypeExampleDescription
CodeStringiot.system.SystemException

The error code returned if the call fails. For more information, see Error codes.

ErrorMessageStringA system exception occurred.

The error message returned if the request fails.

RequestIdStringE4C0FF92-2A86-41DB-92D3-73B60310D25E

The ID of the request.

SuccessBooleantrue

Indicates whether the call was successful.

  • true: The call was successful.
  • false: The request failed.

Examples

Sample requests

http(s)://iot.cn-shanghai.aliyuncs.com/?Action=UpdateParser
&ParserId=1001
&Name=DataParserTwo
&<Common request parameters>

Sample success responses

XML format

<UpdateParserResponse>
  <RequestId>E4C0FF92-2A86-41DB-92D3-73B60310D25E</RequestId>
  <Success>true</Success>
</UpdateParserResponse>

JSON format

{
    "RequestId": "E4C0FF92-2A86-41DB-92D3-73B60310D25E",
    "Success": true
}

Error codes

HttpCodeError codeError messageDescription
400iot.system.SystemExceptionAn internal error occurred. Try again later.The error message returned because a system exception occurred.
400iot.common.InvalidFormattedParameterThe parameter format is invalid.The error message returned because the format of the parameter is invalid.
400iot.rule.UpdateRuleFailedAn error occurred while upgrading the rule.The error message returned because the system failed to update the rule.

For a list of error codes, visit the API Error Center.