Calls the ListQualityRules to retrieve the list of rules based on the partition expression.

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

Parameter Type Required Example Description
Action String Required ListQualityRules

The operation that you want to perform.

EntityId Long Yes 1234

The ID of the partition filter expression.

PageNumber Integer Yes 1

The number of the returned page.

PageSize Integer Yes 20

The size of the page.

ProjectName String Required autotest

The name of the database engine or data source.

RegionId String Required cn-shanghai

The ID of the region where your project resides.

Response parameters

Parameter Type Example Description
Data Struct

The list of rules.

PageNumber Integer 1

The number of the returned page.

PageSize Integer 20

The size of each page.

Rules Array

The details of the rule.

BlockType Integer 0

Rule strength: 0 indicates weak rules and 1 indicates strong rules.

CheckerId Integer 7

The checker ID.

Comment String Verify table rules

The description of the rule.

CriticalThreshold String 40

Red Alarm.

EntityId Integer 1234

The ID of the partition filter expression.

ExpectValue String 1000

The expected value of the checker.

FixCheck Boolean true

Indicates whether the rule is strong.

HistoryCriticalThreshold String history max:80%,history min:50%

The red threshold history.

HistoryWarningThreshold String history max:40%,history min:10%

The historical orange threshold.

Id Integer 1234

The ID of the rule.

MatchExpression String dt=$[yyyymmdd]

The partition expression.

MethodId Integer 21

The ID of the sampling method.

MethodName String count/table_count

The name of the sampling method.

OnDuty String 1912****

The person responsible for the rule.

ProjectName String autotest

The name of the database engine or data source.

Property String id

The name of the field to be sampled.

PropertyKey String table_count

Used to Data Quality front-end rule linkage. This element can be ignored.

RuleCheckerRelationId Integer 132323

The ID of the rule.

RuleType Integer 0

The rule type. A value of 0 indicates that a rule is created by the system, a value of 1 indicates that the rule is created by the user, and a value of 2 indicates that the rule is created by the project.

TableName String dual

The name of the table.

TemplateId Integer 7

The ID of the template.

TemplateName String Number of rows in an sql task table, 1-day, 7-day, and 30-day volatility monitoring

The name of the parameter template.

Trend String abs

The trend of the expected value.

WarningThreshold String 10

The warning threshold.

TotalCount Long 400

The total number of returned data records.

ErrorCode String 401

The error code.

ErrorMessage String You have no permission.

The returned message.

HttpStatusCode Integer 200

The HTTP status code.

RequestId String 38cbdef0-f6cf-49****

The ID of the request.

Success Boolean true

Indicates whether the call is successful.

Examples

Sample requests

http(s)://[Endpoint]/? Action=ListQualityRules
&EntityId=1234
&PageNumber=1
&PageSize=20
&ProjectName=autotest
&RegionId=cn-shanghai
&<Common request parameters>

Sample success responses

XML format

<RequestId>38cbdef0-f6cf-49****</RequestId>
<HttpStatusCode>200</HttpStatusCode>
<Data>
    <TotalCount>400</TotalCount>
    <PageSize>20</PageSize>
    <PageNumber>1</PageNumber>
    <Rules>
        <HistoryCriticalThreshold>history max:80%,history min:50%</HistoryCriticalThreshold>
        <Comment> verify table rules </Comment>
        <HistoryWarningThreshold>history max:40%,history min:10%</HistoryWarningThreshold>
        <RuleCheckerRelationId>132323</RuleCheckerRelationId>
        <CriticalThreshold>40</CriticalThreshold>
        <ProjectName>autotest</ProjectName>
        <ExpectValue>1000</ExpectValue>
        <WarningThreshold>10</WarningThreshold>
        <OnDuty>1912****</OnDuty>
        <Trend>abs</Trend>
        <RuleType>0</RuleType>
        <CheckerId>7</CheckerId>
        <MatchExpression>dt=$[yyyymmdd]</MatchExpression>
        <EntityId>1234</EntityId>
        <TableName>dual</TableName>
        <MethodId>21</MethodId>
        <FixCheck>true</FixCheck>
        <BlockType>0</BlockType>
        Number of rows in an <TemplateName> sql task table, 1-day, 7-day, and 30-day volatility monitoring </TemplateName>
        <Id>1234</Id>
        <MethodName>count/table_count</MethodName>
        <Property>id</Property>
        <TemplateId>7</TemplateId>
        <PropertyKey>table_count</PropertyKey>
    </Rules>
</Data>
<ErrorCode>401</ErrorCode>
<ErrorMessage>You have no permission. </ErrorMessage>
<Success>true</Success>

JSON format

{
    "RequestId": "38cbdef0-f6cf-49****",
    "HttpStatusCode": 200,
    "Data": {
        "TotalCount": 400,
        "PageSize": 20,
        "PageNumber": 1,
        "Rules": {
            "HistoryCriticalThreshold": "history max:80%,history min:50%",
            "Comment": "verify table rules",
            "HistoryWarningThreshold": "history max:40%,history min:10%",
            "RuleCheckerRelationId": 132323,
            "CriticalThreshold": 40,
            "ProjectName": "autotest",
            "ExpectValue": 1000,
            "WarningThreshold": 10,
            "OnDuty": "1912****",
            "Trend": "abs",
            "RuleType": 0,
            "CheckerId": 7,
            "MatchExpression": "dt=$[yyyymmdd]",
            "EntityId": 1234,
            "TableName": "dual",
            "MethodId": 21,
            "FixCheck": true,
            "BlockType": 0,
            "TemplateName": "number of rows in an sql task table, 1-day, 7-day, and 30-day volatility monitoring",
            "Id": 1234,
            "MethodName": "count/table_count",
            "Property": "id",
            "TemplateId": 7,
            "PropertyKey": "table_count"
        }
    },
    "ErrorCode": 401,
    "ErrorMessage": "You have no permission.",
    "Success": true
}

Errors

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