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

# Get a completed Databricks Metric View preview result

Returns 409 while the preview is still running or if it ended without a conversion result.


## OpenAPI

````yaml /api-reference/api.yaml get /api/v1/deployments/{deploymentId}/databricks-metric-view-previews/{previewId}/result
openapi: 3.1.0
info:
  title: Cube Platform API
  version: 1.0.0
  description: >-
    Programmatically manage Cube: deployments and everything scoped to them

    (environments, folders, reports, workbooks, notifications, workspace, and
    agents),

    plus account-level users, groups, policies, embedding, and AI settings.
    Data-model

    authoring, dev mode, branches, and uploads live under /build/api/v1 — same
    host and

    token, routed to the build pods.
servers:
  - url: https://{tenant}.cubecloud.dev
    description: Your tenant host. Replace the whole host if you use a custom domain.
    variables:
      tenant:
        default: your-tenant
        description: Your Cube tenant subdomain
security:
  - bearerAuth: []
tags:
  - name: Deployments
  - name: Deployment Creation
  - name: Environments
  - name: Env Variables
  - name: Regions
  - name: Data Model
  - name: Data Model Uploads
  - name: GitHub
  - name: GitHub Connection
  - name: dbt Sync
  - name: Databricks Metric View Publication
  - name: Databricks Metric View Integration
  - name: Folders
  - name: Reports
  - name: Workbooks
  - name: Dashboard Exports
  - name: Notifications
  - name: Workspace
  - name: Users
  - name: Users Admin
  - name: User Attributes
  - name: User Attribute Values
  - name: Tenant Settings
  - name: OAuth Integrations
  - name: User OAuth Tokens
  - name: OIDC Token Configs
  - name: App Theme
  - name: Embed
  - name: Embed Tenants
  - name: Dashboard Embed Access
  - name: Usage Analytics
  - name: OpenAPI Spec
paths:
  /api/v1/deployments/{deploymentId}/databricks-metric-view-previews/{previewId}/result:
    get:
      tags:
        - Databricks Metric View Publication
      summary: Get a completed Databricks Metric View preview result
      operationId: previewResult
      parameters:
        - in: path
          name: deploymentId
          required: true
          schema:
            type: integer
        - in: path
          name: previewId
          required: true
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/DatabricksMetricViewPublicationPreviewResultResponse
          description: ''
components:
  schemas:
    DatabricksMetricViewPublicationPreviewResultResponse:
      properties:
        buildJobId:
          type: integer
        commit:
          oneOf:
            - type: string
            - type: 'null'
        completedAt:
          pattern: \d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d.\d+Z?
          type: string
        dataSourceName:
          type: string
        deploymentId:
          type: integer
        durationMs:
          type: integer
        outcome:
          $ref: >-
            #/components/schemas/DatabricksMetricViewPublicationPreviewResultResponseOutcome
        previewId:
          type: string
        runtime:
          $ref: '#/components/schemas/DatabricksMetricViewPublicationRuntime'
        sourceSha256:
          type: string
        version:
          $ref: >-
            #/components/schemas/DatabricksMetricViewPublicationPreviewResultResponseVersion
        views:
          items:
            $ref: '#/components/schemas/DatabricksMetricViewPublicationViewResult'
          type: array
      required:
        - previewId
        - deploymentId
        - dataSourceName
        - buildJobId
        - completedAt
        - durationMs
        - version
        - outcome
        - sourceSha256
        - views
        - runtime
      type: object
    DatabricksMetricViewPublicationPreviewResultResponseOutcome:
      enum:
        - success
        - partial
        - failed
      type: string
    DatabricksMetricViewPublicationRuntime:
      properties:
        bridgeCommit:
          type: string
        bridgeVersion:
          type: string
        cubeConverterVersion:
          type: string
        databricksConverterVersion:
          type: string
        ossieCommit:
          type: string
        ossieCoreVersion:
          type: string
        policyVersion:
          type: integer
        runnerVersion:
          type: string
        templateName:
          type: string
      required:
        - bridgeCommit
        - bridgeVersion
        - ossieCommit
        - ossieCoreVersion
        - databricksConverterVersion
        - cubeConverterVersion
        - templateName
        - runnerVersion
        - policyVersion
      type: object
    DatabricksMetricViewPublicationPreviewResultResponseVersion:
      enum:
        - 2
      type: integer
    DatabricksMetricViewPublicationViewResult:
      properties:
        counts:
          $ref: '#/components/schemas/DatabricksMetricViewPublicationCounts'
        cubeViewName:
          type: string
        datasetSources:
          items:
            $ref: '#/components/schemas/DatabricksMetricViewPublicationDatasetSource'
          type: array
        eligibleForPublication:
          type: boolean
        issues:
          items:
            $ref: '#/components/schemas/DatabricksMetricViewPublicationIssue'
          type: array
        metricViewName:
          type: string
        metricViewSha256:
          oneOf:
            - type: string
            - type: 'null'
        metricViewYaml:
          oneOf:
            - type: string
            - type: 'null'
        outcome:
          $ref: >-
            #/components/schemas/DatabricksMetricViewPublicationViewResultOutcome
        source:
          oneOf:
            - type: string
            - type: 'null'
      required:
        - cubeViewName
        - metricViewName
        - outcome
        - eligibleForPublication
        - issues
        - datasetSources
        - counts
      type: object
    DatabricksMetricViewPublicationCounts:
      properties:
        dimensions:
          type: integer
        errors:
          type: integer
        joins:
          type: integer
        measures:
          type: integer
        warnings:
          type: integer
      required:
        - dimensions
        - measures
        - joins
        - warnings
        - errors
      type: object
    DatabricksMetricViewPublicationDatasetSource:
      properties:
        dataSource:
          type: string
        dataset:
          type: string
        originalSource:
          type: string
        resolvedSource:
          type: string
      required:
        - dataset
        - dataSource
        - originalSource
        - resolvedSource
      type: object
    DatabricksMetricViewPublicationIssue:
      properties:
        code:
          type: string
        element:
          oneOf:
            - type: string
            - type: 'null'
        message:
          type: string
        severity:
          $ref: '#/components/schemas/DatabricksMetricViewPublicationIssueSeverity'
        stage:
          $ref: '#/components/schemas/DatabricksMetricViewPublicationIssueStage'
      required:
        - code
        - severity
        - stage
        - message
      type: object
    DatabricksMetricViewPublicationViewResultOutcome:
      enum:
        - success
        - failed
      type: string
    DatabricksMetricViewPublicationIssueSeverity:
      enum:
        - ERROR
        - WARNING
      type: string
    DatabricksMetricViewPublicationIssueStage:
      enum:
        - INPUT
        - VIEW_PROJECTION
        - OSSIE_VALIDATION
        - OSSIE_TO_DATABRICKS
        - OUTPUT_VALIDATION
        - EXECUTION
      type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Token authentication. Send `Authorization: Bearer <YOUR_TOKEN>`.'

````