Microsoft Purview · Arazzo Workflow

Microsoft Purview Define a Data Quality Rule and Scan

Version 1.0.0

Create a data quality rule, confirm it, then run a quality scan that evaluates it.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub ComplianceData CatalogData ClassificationData GovernanceData Loss PreventionInformation ProtectionArazzoWorkflows

Provider

microsoft-purview

Workflows

define-rule-and-scan-quality
Create a data quality rule and run a scan that evaluates it.
Creates a data quality rule, confirms it by reading it back, and runs a data quality scan against the target asset using that rule.
3 steps inputs: apiVersion, assetId, authorization, expression, ruleName, ruleType, severity outputs: ruleId, scanId, scanStatus
1
createRule
Create the data quality rule targeting the asset.
2
confirmRule
Read the rule back by its identifier to confirm it was stored.
3
runScan
Run a data quality scan that evaluates the rule against the asset.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Microsoft Purview Define a Data Quality Rule and Scan
  summary: Create a data quality rule, confirm it, then run a quality scan that evaluates it.
  description: >-
    Operationalizes data quality monitoring in the Purview Data Quality service.
    The workflow creates a data quality rule targeting an asset, reads it back
    to confirm it was stored, and runs a data quality scan that evaluates that
    rule against the asset. Every step spells out its request inline — including
    the inline OAuth2 bearer token and the required api-version query parameter
    — so the flow can be read and executed without opening the underlying
    OpenAPI description.
  version: 1.0.0
  x-realizes-capability-ids:
  - BC-610.30
  x-capability-derivation:
    method: 'deterministic join: sourceDescriptions -> per-tag OpenAPI -> tag/capability edge. No classification at this step.'
    min_confidence: 0.7
    sources:
    - capability_id: BC-610.30
      capability_name: Data Quality Management
      spec: microsoft-purview-data-quality-scans-api-openapi.yml
      confidence: 0.9
    model: Turbo EA Capabilities by Vincent Verdet — Turbo EA, https://github.com/vincentmakes/turbo-ea-capabilities, CC BY 4.0
sourceDescriptions:
- name: dataQualityRulesApi
  url: ../openapi/microsoft-purview-data-quality-rules-api-openapi.yml
  type: openapi
- name: dataQualityScansApi
  url: ../openapi/microsoft-purview-data-quality-scans-api-openapi.yml
  type: openapi
workflows:
- workflowId: define-rule-and-scan-quality
  summary: Create a data quality rule and run a scan that evaluates it.
  description: >-
    Creates a data quality rule, confirms it by reading it back, and runs a data
    quality scan against the target asset using that rule.
  inputs:
    type: object
    required:
    - authorization
    - ruleName
    - ruleType
    - assetId
    properties:
      authorization:
        type: string
        description: The OAuth2 bearer token value, e.g. "Bearer eyJ0...".
      apiVersion:
        type: string
        description: The Data Quality API version.
        default: '2024-03-01-preview'
      ruleName:
        type: string
        description: The name for the new data quality rule.
      ruleType:
        type: string
        description: The rule type (Completeness, Uniqueness, Freshness, Accuracy, Consistency, or Validity).
      expression:
        type: string
        description: The rule expression evaluated against the asset.
      severity:
        type: string
        description: The rule severity (Low, Medium, High, or Critical).
        default: Medium
      assetId:
        type: string
        description: The data asset identifier the rule targets and the scan evaluates.
  steps:
  - stepId: createRule
    description: Create the data quality rule targeting the asset.
    operationId: createDataQualityRule
    parameters:
    - name: Authorization
      in: header
      value: $inputs.authorization
    - name: api-version
      in: query
      value: $inputs.apiVersion
    requestBody:
      contentType: application/json
      payload:
        name: $inputs.ruleName
        ruleType: $inputs.ruleType
        expression: $inputs.expression
        severity: $inputs.severity
        isEnabled: true
        targetAssets:
        - $inputs.assetId
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      ruleId: $response.body#/id
  - stepId: confirmRule
    description: Read the rule back by its identifier to confirm it was stored.
    operationId: getDataQualityRule
    parameters:
    - name: Authorization
      in: header
      value: $inputs.authorization
    - name: ruleId
      in: path
      value: $steps.createRule.outputs.ruleId
    - name: api-version
      in: query
      value: $inputs.apiVersion
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      ruleId: $response.body#/id
  - stepId: runScan
    description: Run a data quality scan that evaluates the rule against the asset.
    operationId: runDataQualityScan
    parameters:
    - name: Authorization
      in: header
      value: $inputs.authorization
    - name: api-version
      in: query
      value: $inputs.apiVersion
    requestBody:
      contentType: application/json
      payload:
        assetIds:
        - $inputs.assetId
        ruleIds:
        - $steps.confirmRule.outputs.ruleId
    successCriteria:
    - condition: $statusCode == 202
    outputs:
      scanId: $response.body#/scanId
      scanStatus: $response.body#/status
  outputs:
    ruleId: $steps.confirmRule.outputs.ruleId
    scanId: $steps.runScan.outputs.scanId
    scanStatus: $steps.runScan.outputs.scanStatus

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/microsoft-purview-define-rule-and-scan-quality-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.