Fairmarkit Data Exports API

The Data Exports API from Fairmarkit — 3 operation(s) for data exports.

OpenAPI Specification

fairmarkit-data-exports-api-openapi.yml Raw ↑
openapi: 3.1.1
info:
  title: BUYER PUBLIC Business Units Data Exports API
  version: '3'
  description: The Fairmarkit Buyer API is a RESTful API that uses HTTP requests to allow you to access and use your Fairmarkit data. It has predictable resource-oriented URLs that use standard HTTP response codes, authentication, and verbs. See the Fairmarkit API developer portal for more information.
  termsOfService: https://www.fairmarkit.com/terms-of-service
  contact:
    name: Fairmarkit Support
    url: https://fmkt.zendesk.com/hc/en-us
    email: support@fairmarkit.com
servers:
- url: https://staging.fairmarkit.com/
tags:
- name: Data Exports
paths:
  /services/self-service/api/v4/data-exports/available:
    get:
      tags:
      - Data Exports
      summary: List Available Data Exports
      operationId: DataExportApi_list_available_data_exports_services_self_service_api_v4_data_exports_available_get
      parameters:
      - required: false
        schema:
          type: string
          title: X-Fm-Api-Key
        name: X-FM-API-KEY
        in: header
      responses:
        '200':
          description: Successful Response
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/DataExportAvailableResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /services/self-service/api/v4/data-exports/{job_id}:
    get:
      tags:
      - Data Exports
      summary: Get Data Export
      operationId: DataExportApi_get_data_export_services_self_service_api_v4_data_exports__job_id__get
      parameters:
      - required: true
        schema:
          type: string
          format: uuid
          title: Job Id
        name: job_id
        in: path
      - required: false
        schema:
          type: string
          title: X-Fm-Api-Key
        name: X-FM-API-KEY
        in: header
      responses:
        '200':
          description: Successful Response
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/DataExportRetrieve'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /services/self-service/api/v4/data-exports/:
    post:
      tags:
      - Data Exports
      summary: Create Data Export
      operationId: DataExportApi_create_data_export_services_self_service_api_v4_data_exports__post
      parameters:
      - required: false
        schema:
          type: string
          title: X-Fm-Api-Key
        name: X-FM-API-KEY
        in: header
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DataExportCreateRequest'
        required: true
      responses:
        '202':
          description: Successful Response
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/DataExportCreateResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    DataExportAvailableResponse:
      properties:
        models:
          items:
            $ref: '#/components/schemas/DataExportAvailableModel'
          type: array
          title: Models
      type: object
      required:
      - models
      title: DataExportAvailableResponse
    DataExportRetrieve:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        status:
          type: string
          title: Status
        initiator:
          type: string
          title: Initiator
        selections:
          items:
            $ref: '#/components/schemas/DataExportSelection'
          type: array
          title: Selections
        date_range:
          $ref: '#/components/schemas/DataExportDateRange'
        row_count:
          type: integer
          title: Row Count
        result_url:
          type: string
          title: Result Url
        error:
          type: string
          title: Error
        error_code:
          type: string
          title: Error Code
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        finished_at:
          type: string
          format: date-time
          title: Finished At
        expired_at:
          type: string
          format: date-time
          title: Expired At
      type: object
      required:
      - id
      - status
      - selections
      - date_range
      title: DataExportRetrieve
    DataExportAvailableModel:
      properties:
        name:
          type: string
          title: Name
        title:
          type: string
          title: Title
        fields:
          items:
            $ref: '#/components/schemas/DataExportAvailableField'
          type: array
          title: Fields
      type: object
      required:
      - name
      - fields
      title: DataExportAvailableModel
    HTTPValidationError:
      title: HTTPValidationError
      type: object
      description: Validation error response.
      properties:
        detail:
          title: Detail
          type: array
          description: Details about a specific error to display in error response.
          items:
            $ref: '#/components/schemas/ValidationError'
    ValidationError:
      title: ValidationError
      required:
      - loc
      - msg
      - type
      type: object
      description: Details for a validation error.
      properties:
        loc:
          title: Location
          type: array
          description: Error location
          items:
            anyOf:
            - type: string
            - type: integer
        msg:
          title: Message
          type: string
          description: Human readable explanation of the error.
        type:
          title: Error Type
          type: string
          description: Computer-readable identifier of the error type.
    DataExportSelection:
      properties:
        model:
          type: string
          title: Model
        fields:
          items:
            type: string
          type: array
          title: Fields
      type: object
      required:
      - model
      - fields
      title: DataExportSelection
    DataExportAvailableField:
      properties:
        name:
          type: string
          title: Name
        label:
          type: string
          title: Label
        type:
          type: string
          title: Type
      type: object
      required:
      - name
      - label
      - type
      title: DataExportAvailableField
    DataExportCreateRequest:
      properties:
        external_reporting_id:
          type: string
          maxLength: 64
          minLength: 1
          title: External Reporting Id
        selections:
          items:
            $ref: '#/components/schemas/DataExportSelection'
          type: array
          title: Selections
        date_range:
          $ref: '#/components/schemas/DataExportDateRange'
      type: object
      required:
      - external_reporting_id
      - selections
      - date_range
      title: DataExportCreateRequest
    DataExportCreateResponse:
      properties:
        id:
          type: string
          format: uuid
          title: Id
      type: object
      required:
      - id
      title: DataExportCreateResponse
    DataExportDateRange:
      properties:
        start:
          type: string
          format: date
          title: Start
        end:
          type: string
          format: date
          title: End
      type: object
      required:
      - start
      - end
      title: DataExportDateRange