> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dataframer.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Anonymization Run

> Retrieve an anonymization run by ID. Also use this endpoint to poll for completion.



## OpenAPI

````yaml GET /api/dataframer/anonymization-runs/{run_id}/
openapi: 3.0.0
info:
  title: DataFramer API
  version: 0.1.0
  description: ''
  termsOfService: https://www.aimon.ai/docs/privacy-policy.pdf
  contact:
    name: DataFramer Support
    email: info@dataframer.ai
  license:
    name: Proprietary
  x-logo:
    url: https://dataframer.ai/logo.png
    altText: DataFramer AI
  x-stainless:
    package-name: aimon-dataframer
    namespace:
      - aimon
      - dataframer
servers:
  - url: https://df-api.dataframer.ai
    description: Production server
security:
  - BearerAuth: []
tags:
  - name: Seed Datasets
    description: Manage seed datasets for generation
  - name: Specs
    description: Data specifications for sample generation
  - name: Runs
    description: Generation runs and results
  - name: Evaluations
    description: Evaluate generated sample quality
  - name: Red Teaming
    description: Security testing and adversarial prompts
  - name: Spec Creation
    description: Create specs from datasets or from scratch (seedless)
  - name: Generation
    description: Synthetic data generation
  - name: API Keys
    description: API key management and rotation
  - name: Health
    description: Health check endpoints
  - name: Models
    description: Available AI models
externalDocs:
  description: Complete API Guide
  url: https://docs.dataframer.ai/dataframer
paths:
  /api/dataframer/anonymization-runs/{run_id}/:
    get:
      tags:
        - DataFramer - Data Anonymization
      summary: Get an anonymization run
      description: >-
        Retrieve an anonymization run by ID. Use this endpoint to poll for
        completion while status is `PENDING` or `PROCESSING`.
      operationId: api_dataframer_anonymization_runs_retrieve
      parameters:
        - name: run_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: UUID of the anonymization run.
      responses:
        '200':
          description: Anonymization run details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AnonymizationRun'
        '401':
          description: Unauthorized
        '404':
          description: Anonymization run not found
      security:
        - BearerAuth: []
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Dataframer from 'dataframer';


            const client = new Dataframer({
              apiKey: process.env['DATAFRAMER_API_KEY'], // This is the default and can be omitted
            });


            const anonymizationRun = await
            client.dataframer.anonymizationRuns.retrieve(
              '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
            );


            console.log(anonymizationRun.id);
        - lang: Python
          source: |-
            import os
            from dataframer import Dataframer

            client = Dataframer(
                api_key=os.environ.get("DATAFRAMER_API_KEY"),  # This is the default and can be omitted
            )
            anonymization_run = client.dataframer.anonymization_runs.retrieve(
                "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            )
            print(anonymization_run.id)
components:
  schemas:
    AnonymizationRun:
      type: object
      description: A PII/PHI anonymization run.
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier for the anonymization run.
        status:
          type: string
          enum:
            - PENDING
            - PROCESSING
            - SUCCEEDED
            - FAILED
          description: Current status of the anonymization run.
        dataset_id:
          type: string
          format: uuid
          nullable: true
          description: UUID of the seed dataset being anonymized.
        dataset_name:
          type: string
          nullable: true
          description: Name of the seed dataset.
        pii_types:
          type: array
          items:
            type: string
          description: List of PII/PHI entity types being detected.
        detection_method:
          type: string
          description: Entity detection method used.
        llm_model_name:
          type: string
          nullable: true
          description: LLM model name (when detection_method includes `llm`).
        created_by_email:
          type: string
          format: email
          nullable: true
          description: Email of the user who created this run.
        duration_seconds:
          type: integer
          nullable: true
          description: Time taken to complete the run in seconds. Null until completed.
        results:
          type: object
          nullable: true
          description: Anonymization results once the run completes.
          properties:
            entity_summary:
              type: object
              description: Aggregated entity counts by type across all samples.
            samples_processed:
              type: integer
              description: Total number of samples processed.
            entities_found:
              type: array
              items:
                type: object
                properties:
                  start:
                    type: integer
                  end:
                    type: integer
                  label:
                    type: string
                  score:
                    type: number
              description: Flat list of all entities detected across all samples.
            error:
              type: string
              description: Error message if the run failed.
        anonymized_files:
          type: array
          description: List of anonymized output files produced by the run.
          items:
            type: object
            properties:
              id:
                type: string
                description: File ID. Pass this as `file_id` to the download-file endpoint.
              path:
                type: string
                description: Original file path/name.
              size_in_bytes:
                type: integer
                description: Size of the anonymized file content in bytes.
              content_type:
                type: string
                description: MIME type of the file.
        completed_at:
          type: string
          format: date-time
          nullable: true
          description: When the run completed (succeeded or failed).
        created_at:
          type: string
          format: date-time
          description: When the run was created.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: 'API Key authentication. Format: "Bearer YOUR_API_KEY"'

````