Dagster External Assets REST API

The Dagster External Assets REST API provides endpoints to report asset materializations, asset check evaluations, and asset observations for external assets back to Dagster. This allows you to notify Dagster that an external asset has been updated and include metadata about the event.

OpenAPI Specification

dagster-external-assets-rest-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Dagster External Assets REST API
  description: >-
    The Dagster External Assets REST API provides endpoints to report asset
    materializations, asset check evaluations, and asset observations for
    external assets back to Dagster. This allows you to notify Dagster that
    an external asset has been updated and include metadata about the event.
  version: '1.0'
  contact:
    name: Dagster
    url: https://dagster.io/
servers:
  - url: http://localhost:3000
    description: Local Dagster webserver
  - url: https://{org}.dagster.plus/{deployment}
    description: Dagster+ Cloud deployment
    variables:
      org:
        default: my-org
        description: Dagster+ organization slug
      deployment:
        default: prod
        description: Dagster+ deployment name
tags:
  - name: Materializations
    description: Report asset materialization events.
  - name: Checks
    description: Report asset check evaluations.
  - name: Observations
    description: Report asset observation events.
paths:
  /report_asset_materialization/:
    post:
      operationId: reportAssetMaterialization
      summary: Report asset materialization
      description: >-
        Records an asset materialization event for an external asset, with
        optional metadata, partition, data version, and description.
      tags:
        - Materializations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AssetMaterialization'
      responses:
        '200':
          description: Materialization recorded successfully
          content:
            application/json:
              schema:
                type: object
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /report_asset_check/:
    post:
      operationId: reportAssetCheck
      summary: Report asset check evaluation
      description: >-
        Records an asset check evaluation result with pass/fail status,
        check name, severity, and optional metadata.
      tags:
        - Checks
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AssetCheck'
      responses:
        '200':
          description: Check evaluation recorded
          content:
            application/json:
              schema:
                type: object
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /report_asset_observation/:
    post:
      operationId: reportAssetObservation
      summary: Report asset observation
      description: >-
        Records an asset observation event with optional metadata, partition,
        data version, and description for an external asset.
      tags:
        - Observations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AssetObservation'
      responses:
        '200':
          description: Observation recorded
          content:
            application/json:
              schema:
                type: object
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  securitySchemes:
    DagsterCloudToken:
      type: apiKey
      in: header
      name: Dagster-Cloud-Api-Token
      description: User token used to authenticate against Dagster+ deployments.
  schemas:
    AssetMaterialization:
      type: object
      required:
        - asset_key
      properties:
        asset_key:
          type: string
          description: The asset key being materialized.
        metadata:
          type: object
          description: Free-form key/value metadata about the materialization.
          additionalProperties: true
        data_version:
          type: string
          description: A user-supplied data version identifier.
        description:
          type: string
          description: A human-readable description of the materialization.
        partition:
          type: string
          description: The asset partition associated with the materialization.
    AssetCheck:
      type: object
      required:
        - asset_key
        - check_name
        - passed
      properties:
        asset_key:
          type: string
          description: The asset key the check applies to.
        check_name:
          type: string
          description: The identifier of the asset check.
        passed:
          type: boolean
          description: True if the check passed, false otherwise.
        severity:
          type: string
          description: Severity level for failed checks.
          enum:
            - WARN
            - ERROR
        metadata:
          type: object
          description: Free-form key/value metadata about the check evaluation.
          additionalProperties: true
    AssetObservation:
      type: object
      required:
        - asset_key
      properties:
        asset_key:
          type: string
          description: The asset key being observed.
        metadata:
          type: object
          description: Free-form key/value metadata about the observation.
          additionalProperties: true
        data_version:
          type: string
          description: A user-supplied data version identifier.
        description:
          type: string
          description: A human-readable description of the observation.
        partition:
          type: string
          description: The asset partition associated with the observation.
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message describing the failure.