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

# Get data export run

> Retrieve the status and download URL for a data export run.

Poll this endpoint after [creating a data export run](/api-reference/data-exports/create-data-export) until
the status reaches `Completed` or `Failed`.

When the run completes successfully, the response includes `fileUri` — a URL to the exported JSON file.
The `activityFrom` and `activityTo` fields match the activity window written to the export file metadata.


## OpenAPI

````yaml GET /b2b/data-exports/{id}
openapi: 3.0.3
info:
  title: Wealthyhood Data Exports API
  version: 1.0.0
  description: >
    Partner-level endpoints for initiating and monitoring data export runs. Each
    completed run produces a

    JSON file containing portfolio snapshots and financial activity for a
    configurable time window.


    All requests require a bearer access token with the `wealthyhood:nbg` scope.
    These endpoints do not

    require an `x-user-id` header — exports cover all users for the
    authenticated partner.


    See the [Data Export](/data-exports/data-export) guide for the export file
    schema and integration details.
servers:
  - url: https://{host}
    variables:
      host:
        default: api.wealthyhood.com
        description: Wealthyhood API host name.
security:
  - bearerAuth: []
tags:
  - name: Data Exports
    description: Initiate and monitor partner data export runs.
paths:
  /b2b/data-exports/{id}:
    get:
      tags:
        - Data Exports
      summary: Get data export run
      description: >
        Returns the status and metadata for a data export run. When the run is
        `Completed`, the response

        includes `fileUri` pointing to the exported JSON file.


        The `activityFrom` and `activityTo` fields reflect the resolved activity
        window for this run —

        the same bounds written to the export file's `metadata` section.
      parameters:
        - $ref: '#/components/parameters/ExportRunId'
      responses:
        '200':
          description: Export run retrieved successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataExportRun'
              examples:
                pending:
                  summary: Run in progress
                  value:
                    id: 674a1b2c3d4e5f6789012345
                    status: Pending
                    initiatedAt: '2025-01-16T01:00:00.000Z'
                    schemaVersion: 1.1.1
                    activityFrom: '2025-01-15T10:00:00.000Z'
                    activityTo: '2025-01-16T01:00:00.000Z'
                completed:
                  summary: Completed run with download URL
                  value:
                    id: 674a1b2c3d4e5f6789012345
                    status: Completed
                    initiatedAt: '2025-01-16T01:00:00.000Z'
                    exportedAt: '2025-01-16T02:00:00.000Z'
                    fileUri: >-
                      https://data-exports.wealthyhood.cloud/nbg/2026/01/16/export.json
                    schemaVersion: 1.1.1
                    activityFrom: '2025-01-15T10:00:00.000Z'
                    activityTo: '2025-01-16T01:00:00.000Z'
                failed:
                  summary: Failed run
                  value:
                    id: 674a1b2c3d4e5f6789012345
                    status: Failed
                    initiatedAt: '2025-01-16T01:00:00.000Z'
                    schemaVersion: 1.1.1
                    activityTo: '2025-01-16T01:00:00.000Z'
                    error: Unknown error during data export
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '403':
          $ref: '#/components/responses/ForbiddenError'
        '404':
          description: Export run not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorResponse'
              example:
                status: 404
                error:
                  message: Export run not found
components:
  parameters:
    ExportRunId:
      name: id
      in: path
      required: true
      description: Unique identifier of the data export run.
      schema:
        type: string
        example: 674a1b2c3d4e5f6789012345
  schemas:
    DataExportRun:
      type: object
      required:
        - id
        - status
        - initiatedAt
        - schemaVersion
        - activityTo
      properties:
        id:
          type: string
          description: Unique identifier for the export run.
          example: 674a1b2c3d4e5f6789012345
        status:
          type: string
          description: Current processing status of the export run.
          enum:
            - Pending
            - InProgress
            - Completed
            - Failed
          example: Pending
        initiatedAt:
          type: string
          format: date-time
          description: ISO 8601 timestamp when the export run was initiated.
          example: '2025-01-16T01:00:00.000Z'
        exportedAt:
          type: string
          format: date-time
          description: >-
            ISO 8601 timestamp when the export completed. Present when status is
            `Completed`.
          example: '2025-01-16T02:00:00.000Z'
        fileUri:
          type: string
          format: uri
          description: >-
            URL to download the exported JSON file. Present when status is
            `Completed`.
          example: https://data-exports.wealthyhood.cloud/nbg/2026/01/16/export.json
        schemaVersion:
          type: string
          description: Schema version used for the export file (semantic versioning).
          example: 1.1.1
        error:
          type: string
          description: Error message when status is `Failed`.
          example: Unknown error during data export
        activityFrom:
          type: string
          format: date-time
          description: >
            Resolved lower bound (exclusive) for activity in this export.
            Omitted on the first incremental

            run when no previous completed export exists.
          example: '2025-01-15T10:00:00.000Z'
        activityTo:
          type: string
          format: date-time
          description: >
            Resolved upper bound (inclusive) for activity in this export.
            Defaults to the run's initiation

            time when not explicitly requested.
          example: '2025-01-16T01:00:00.000Z'
      additionalProperties: false
    ApiErrorResponse:
      type: object
      properties:
        status:
          type: integer
        error:
          type: object
          properties:
            message:
              type: string
            description:
              type: string
              nullable: true
        responseId:
          type: string
          format: uuid
  responses:
    UnauthorizedError:
      description: Missing or invalid bearer token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorResponse'
          example:
            status: 401
            error:
              message: Unauthorized - Invalid or missing authentication token
            responseId: 145f2b0d-1d5b-4e91-8d0d-7af0ae9ad13a
    ForbiddenError:
      description: Authenticated client lacks the required scope.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorResponse'
          example:
            status: 403
            error:
              message: Access denied
            responseId: 5e467f79-c62c-4d83-9810-7a0f8529fd76
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Auth0-issued access token that includes the `wealthyhood:nbg` scope.

````