swagger: "2.0"
info:
  title: FunnelFlux Reporting API
  description: >-
    FunnelFlux Reporting API endpoints for creating drilldown reports, raw event
    reports, and visitor or hit lookups.


    Use these APIs to inspect reporting attributes, query postback logs, submit
    conversion and cost updates, and run scoped data resets.
  version: 1.0.0
host: api.funnelflux.pro
basePath: /v1
schemes:
  - https
consumes:
  - application/json
produces:
  - application/json
securityDefinitions:
  Bearer:
    type: apiKey
    name: Authorization
    in: header
    description: "All requests must pass a valid header of `Authorization: Bearer TOKEN`"
security:
  - Bearer: []
tags:
  - name: Reporting
    description: Drilldown, raw event, and attribute reporting endpoints
  - name: Updates
    description: Conversion, cost, and reset update endpoints
  - name: Logs
    description: Postback log endpoints
  - name: Explorer
    description: Visitor and hit lookup endpoints
paths:
  /reporting/attributes/:
    get:
      tags:
        - Reporting
      description: Returns the list of available attributes
      summary: List available attributes
      responses:
        "200":
          description: The attributes list as a string array
          schema:
            type: array
            items:
              $ref: "#/definitions/Attribute"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/drilldown/:
    post:
      tags:
        - Reporting
      description: Create and run a new drilldown report. If you would like a report
        to use unique visitor counts, pass returnUniqueVisitors = true and
        include Visitors in the restrictToMetrics array.
      summary: Create a drilldown report
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/DrilldownReportParams"
      responses:
        "200":
          description: The requested report
          schema:
            $ref: "#/definitions/DrilldownReport"
        "400":
          description: Invalid request — for example a grouping attribute that is not one
            of the values returned by GET /reporting/attributes/.
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        "503":
          description: Maintenance Mode
          headers:
            Retry-After:
              type: integer
          schema:
            type: string
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/hits/:
    post:
      tags:
        - Reporting
      description: Create and run a new hit-level report
      summary: Create a raw event report
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/HitReportParams"
      responses:
        "200":
          description: The requested report
          schema:
            $ref: "#/definitions/HitReport"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/postbacks:
    post:
      tags:
        - Logs
      description: Returns postback log for specified criteria.
      summary: Get postback log
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/PostbackLogParams"
      responses:
        "200":
          description: The requested report
          schema:
            $ref: "#/definitions/PostbackLogReport"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/webhooks/summary:
    post:
      tags:
        - Logs
      description: Returns current webhook config assets merged with webhook delivery
        log aggregates.
      summary: Get webhook asset summary
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/WebhookSummaryParams"
      responses:
        "200":
          description: The requested summary
          schema:
            $ref: "#/definitions/WebhookSummaryReport"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "422":
          description: Validation error
          schema:
            $ref: "#/definitions/Error"
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/middleware/summary:
    post:
      tags:
        - Logs
      description: Returns current middleware config assets merged with middleware
        execution log aggregates.
      summary: Get middleware asset summary
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/MiddlewareSummaryParams"
      responses:
        "200":
          description: The requested summary
          schema:
            $ref: "#/definitions/MiddlewareSummaryReport"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "422":
          description: Validation error
          schema:
            $ref: "#/definitions/Error"
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/incoming-postbacks:
    post:
      tags:
        - Logs
      description: Returns incoming postback request logs (server-to-server requests
        received on /pb/ and /pb/cevent).
      summary: Get incoming postback logs
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/IncomingPostbackLogParams"
      responses:
        "200":
          description: The requested report
          schema:
            $ref: "#/definitions/IncomingPostbackLogReport"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "422":
          description: Validation error
          schema:
            $ref: "#/definitions/Error"
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/integrations:
    post:
      tags:
        - Logs
      description: Returns integration logs (conversion delivery and connection_auth)
        for specified criteria. Each row includes outcome (queued, delivered,
        skipped, failed, or unknown when the stored outcome is empty) and
        outcomeReason. Outcome filter values are queued, delivered, skipped,
        failed, and unknown. unknown matches a stored empty outcome. There is no
        default exclusion.
      summary: Get integration logs
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/IntegrationLogParams"
      responses:
        "200":
          description: The requested report
          schema:
            $ref: "#/definitions/IntegrationLogReport"
        "400":
          description: Invalid request format
          schema:
            $ref: "#/definitions/Error"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
          schema:
            $ref: "#/definitions/Error"
        "422":
          description: Validation error
          schema:
            $ref: "#/definitions/Error"
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/logs/integrations/queue:
    post:
      tags:
        - Logs
      description: >
        Returns delayed integration queue rows for the authenticated owner.
        Read-only. There is no retry, cancel, or delete.

        Time bounds filter updated_at in UTC. Display timestamps use the
        timeStart offset.

        status=completed means the delayed-work row closed. It is not a
        delivery. statusLabel is Completed, never Delivered.

        status=held is labeled Held. An expired held row is status=failed with
        lastError exactly "expired". There is no resolution field.

        Each row carries transactionId and destinationEvent as strings, empty
        when unset. The response never includes owner, conversionData, workerId,
        leaseUntil, or a platform label.

        lastError is redacted at response time.
      summary: Get integration queue rows
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/IntegrationQueueLogParams"
      responses:
        "200":
          description: The requested queue page. Empty success is rows [] plus metadata,
            never null.
          schema:
            $ref: "#/definitions/IntegrationQueueLogReport"
        "400":
          description: Invalid request format
          schema:
            $ref: "#/definitions/Error"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
          schema:
            $ref: "#/definitions/Error"
        "422":
          description: Validation error. Semantic and filter failures use code 606.
          schema:
            $ref: "#/definitions/Error"
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/update/conversions/:
    put:
      tags:
        - Updates
      description: >-
        Add new conversions or correct existing ones on explicit hit IDs.
        Updates are queued and processed

        asynchronously.


        A conversion is identified by its hit ID and transaction ID. When the
        hit already has a conversion with

        the same transaction ID, the result depends on the time since the
        previous accepted conversion for that

        pair. The time is measured between the two conversion times; a hit
        without conversionTime uses the time

        FunnelFlux receives the request.


        - Up to 5 minutes: the upload is ignored as a duplicate, whatever its
        revenue, unless the revenue is
          negative. Nothing is sent.
        - More than 5 minutes, up to 3 hours (the correction window): an upload
        with the same revenue is ignored.
          An upload with different revenue replaces the revenue and keeps the original conversion time. Traffic
          source postback URLs and webhooks are not called again unless forcePostbacks is true. Traffic source
          integrations receive an adjustment:
          Google Ads applies it; Meta, TikTok, and Microsoft Ads do not support adjustments, so nothing is sent
          to them.
        - More than 3 hours: the upload replaces the existing conversion, keeps
        the original conversion time, and is
          delivered again to postback URLs, webhooks, and integrations. Set disablePostbacks to true when a
          correction must not reach the traffic source again.

        A negative revenue deletes the existing conversion at any time,
        including within 5 minutes of the previous

        upload. Google Ads receives a retraction; postback URLs and webhooks are
        called only when forcePostbacks is

        true. Meta, TikTok, and Microsoft Ads support neither adjustments nor
        retractions, so a deletion sends

        nothing to them.


        disablePostbacks, or postbackCalls set to none, stops all outbound
        delivery for the request and takes

        precedence over forcePostbacks. Reporting is updated either way.
      summary: Submit a conversion update
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/ConversionsUpdateParams"
      responses:
        "200":
          description: Update queued for processing
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        "503":
          description: Maintenance Mode
          headers:
            Retry-After:
              type: string
          schema:
            type: string
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/update/customevents/:
    put:
      tags:
        - Updates
      description: >-
        Add custom events 1-10 from explicit hit IDs. The full batch is rejected
        on validation errors; invalid rows

        are not skipped. Updates are queued and processed asynchronously.


        Custom events are not deduplicated by the conversion time windows. Each
        accepted upload is processed as a

        new custom event and is sent to traffic source postback URLs, webhooks,
        Meta, and TikTok, including when the

        same event was uploaded before. Google Ads and Microsoft Ads receive a
        custom event only once per hit and

        event number; a later upload of the same event is not sent to them
        again. Set disablePostbacks to true, or

        postbackCalls to none, to record the events without sending them.
        Negative revenue is rejected, so a custom

        event cannot be corrected or deleted by uploading it again.
      summary: Submit a custom event update
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/CustomEventsUpdateParams"
      responses:
        "200":
          description: Update queued for processing
        "400":
          description: Invalid custom event upload
          schema:
            $ref: "#/definitions/Error"
        "401":
          description: Missing owner context
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        "503":
          description: Maintenance Mode
          headers:
            Retry-After:
              type: string
          schema:
            type: string
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/update/cost/:
    put:
      tags:
        - Updates
      description: Update the cost of specific traffic segments over an inclusive
        window. Both times are required and nonzero; timeEnd must be strictly
        after timeStart. timeStart must be on or after 2020-01-01T00:00:00Z;
        timeEnd must not exceed timeStart's UTC 12-calendar-month anniversary
        (the 1-year data period). Exact limits are accepted.
      summary: Submit a cost update
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/CostUpdateParams"
      responses:
        "200":
          description: Cost updates accepted for asynchronous processing. Matching
            segments are queued; zero-entrance segments complete as no-ops.
            Warehouse application completes later and is not part of this
            response.
        "400":
          description: Invalid request, rejected before preflight or enqueue. Examples
            include "timeStart is required", "timeEnd must be strictly after
            timeStart" (including equal bounds), "timeStart must be on or after
            2020-01-01T00:00:00Z", and "timeEnd must be within the
            12-calendar-month / 1-year data-period limit from timeStart".
            Restriction errors name the device/connection field and accepted
            values or required includeProxyHostingTraffic opt-in, or the
            unknown/empty/blank-only tracking-field restriction.
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        "503":
          description: Maintenance Mode
          headers:
            Retry-After:
              type: string
          schema:
            type: string
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/update/reset/:
    delete:
      tags:
        - Updates
      summary: Perform a data reset
      description: Reset stats of specific traffic segments over an inclusive window.
        Both times must be nonzero, timeEnd strictly after timeStart, timeStart
        on or after 2020-01-01T00:00:00Z, and timeEnd at most the UTC
        12-calendar-month anniversary (1-year data period). Exact limits are
        accepted. At least one non-blank restriction besides time is required,
        and blank restrictToFunnelIDs entries are rejected. Scope is checked
        before the window; invalid requests reach neither counting nor deletion.
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/ResetUpdateParams"
      responses:
        "200":
          description: Reset queued for processing
        "400":
          description: Invalid reset parameters. Missing restriction is reported first for
            an empty request. Other examples include unknown or empty/blank-only
            restrictToTrackingFields, "timeStart is required", "timeEnd must be
            strictly after timeStart", "timeStart must be on or after
            2020-01-01T00:00:00Z", and "timeEnd must be within the
            12-calendar-month / 1-year data-period limit from timeStart".
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
    post:
      tags:
        - Updates
      description: Count hits matching the reset settings and inclusive window. Both
        times must be nonzero, timeEnd strictly after timeStart, timeStart on or
        after 2020-01-01T00:00:00Z, and timeEnd at most the UTC
        12-calendar-month anniversary (1-year data period). Exact limits are
        accepted. At least one non-blank restriction besides time is required,
        and blank restrictToFunnelIDs entries are rejected. Scope is checked
        before the window, before counting.
      summary: Validate a data reset
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/ResetUpdateParams"
      responses:
        "200":
          description: The number of would-be impacted hits
          schema:
            $ref: "#/definitions/IntegerValue"
        "400":
          description: Invalid reset parameters. Missing restriction is reported first for
            an empty request. Other examples include unknown or empty/blank-only
            restrictToTrackingFields, "timeStart is required", "timeEnd must be
            strictly after timeStart", "timeStart must be on or after
            2020-01-01T00:00:00Z", and "timeEnd must be within the
            12-calendar-month / 1-year data-period limit from timeStart".
          schema:
            $ref: "#/definitions/Error"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /logs/postbacks/:
    post:
      tags:
        - Logs
      description: Returns postback log for specified criteria.
      summary: Get postback log
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/PostbackLogCriteria"
      responses:
        "200":
          description: The postback log
          schema:
            $ref: "#/definitions/PostbackLog"
        "403":
          description: Not authorized
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/explorer/visitor:
    post:
      tags:
        - Explorer
      description: |-
        Look up a visitor's session and hit history. Provide either a visitorId
        (with timeStart/timeEnd) or a hitId to find the visitor.
      summary: Look up a visitor
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/ExplorerVisitorRequest"
      responses:
        "200":
          description: The visitor info and their hit list
          schema:
            $ref: "#/definitions/ExplorerVisitorResponse"
        "400":
          description: Invalid request format
        "401":
          description: Missing owner context
        "403":
          description: Not authorized
        "422":
          description: Validation error (visitorId or hitId required; timeStart/timeEnd
            required with visitorId)
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
  /reporting/explorer/hit:
    post:
      tags:
        - Explorer
      description: |-
        Look up full details for a single hit by its ID. Returns all event,
        device, geo, connection, and tracking data for the hit.
      summary: Look up a single hit
      parameters:
        - name: body
          required: true
          in: body
          schema:
            $ref: "#/definitions/ExplorerHitRequest"
      responses:
        "200":
          description: The full hit detail
          schema:
            $ref: "#/definitions/ExplorerHitResponse"
        "400":
          description: Invalid request format
        "401":
          description: Missing owner context
        "403":
          description: Not authorized
        "422":
          description: Validation error (hitId is required)
        "429":
          $ref: "#/responses/RateLimited"
        default:
          description: Unexpected error
          schema:
            $ref: "#/definitions/Error"
responses:
  RateLimited:
    description: The API gateway refuses the request because the account's
      per-minute limit for customer API keys and legacy Auth0 API tokens is
      exhausted. The operation was not performed.
    headers:
      Retry-After:
        type: integer
        description: Seconds to wait before retrying.
    schema:
      $ref: "#/definitions/RateLimitError"
definitions:
  RateLimitError:
    type: object
    description: The API gateway returns this error when the account's per-minute
      API rate limit is exhausted.
    required:
      - code
      - message
    properties:
      code:
        type: string
        enum:
          - API_RATE_LIMITED
      message:
        type: string
  DrilldownReportParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - attributes
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
        x-order: 1
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
        x-order: 2
      useEntranceTime:
        type: boolean
        x-nullable: false
        default: false
        x-order: 3
      attributes:
        type: array
        items:
          $ref: "#/definitions/AttributeData"
        x-nullable: false
        x-order: 4
      filters:
        type: array
        items:
          $ref: "#/definitions/AttributeData"
        x-nullable: false
        x-order: 5
      showFilteredTraffic:
        type: boolean
        default: false
        x-nullable: false
        x-order: 6
      includeAssetsWithoutTraffic:
        type: boolean
        default: false
        x-nullable: false
        x-order: 7
      returnUniqueVisitors:
        type: boolean
        default: false
        x-nullable: false
        x-order: 8
      restrictToMetrics:
        type: array
        description: |-
          If empty (and calculatedMetrics is empty), returns the default metric
          set: every metric below except CustomEvent1-10, AverageTimeOnPage and
          BounceRate, which are opt-in and only returned when named explicitly
          here. Unsupported names are ignored; a request naming only
          unsupported metrics returns rows with no metrics, never all metrics.
          Names match regardless of case, surrounding whitespace, and
          underscores, spaces, hyphens or colons (average_time_on_page names
          AverageTimeOnPage).
          Can restrict the response to any combination of the following metrics:
            * Visits
            * Visitors
            * Cost
            * NodeViews
            * NodeViewsUnique
            * LanderViews
            * LanderViewsUnique
            * LanderClicks
            * LanderClicksUnique
            * OfferViews
            * OfferViewsUnique
            * OfferClicks
            * OfferClicksUnique
            * Conversions
            * Revenue
            * TotalRevenue
            * CustomEvent1
            * CustomEvent2
            * CustomEvent3
            * CustomEvent4
            * CustomEvent5
            * CustomEvent6
            * CustomEvent7
            * CustomEvent8
            * CustomEvent9
            * CustomEvent10
            * PageViews
            * PageViewsUnique
            * PageClicks
            * PageClicksUnique
            * AverageTimeOnPage
            * BounceRate
        items:
          type: string
        x-nullable: true
        x-order: 9
      calculatedMetrics:
        type: array
        description: |-
          Can get the following calculated metrics:
            * lander_ctr
            * offer_ctr
            * unique_lander_ctr
            * unique_offer_ctr
            * lander_ctr_unique (alias for unique_lander_ctr)
            * offer_ctr_unique (alias for unique_offer_ctr)
            * ctr (general click-through rate)
            * unique_ctr (unique combined CTR)
            * conversion_per_lander_click
            * conversion_per_lander_view
            * conversion_per_offer_click
            * conversion_per_offer_view
            * conversion_per_unique_lander_click
            * conversion_per_unique_lander_view
            * conversion_per_unique_offer_click
            * conversion_per_unique_offer_view
            * conversion_per_unique_visitor
            * conversion_per_visit
            * custom_event_x_per_visit
            * cost_per_conversion
            * cost_per_event_x
            * cost_per_lander_click
            * cost_per_lander_view
            * cost_per_offer_click
            * cost_per_offer_view
            * cost_per_unique_lander_click
            * cost_per_unique_lander_view
            * cost_per_unique_offer_click
            * cost_per_unique_offer_view
            * cost_per_unique_visitor
            * cost_per_visit
            * cost_per_visitor
            * uniqueness
            * profit_and_loss
            * roi
            * epv (earnings per visit)
            * epc (earnings per click)
            * revenue_per_conversion
            * revenue_per_event_x
            * revenue_per_lander_click
            * revenue_per_lander_view
            * revenue_per_offer_click
            * revenue_per_offer_view
            * revenue_per_unique_lander_click
            * revenue_per_unique_lander_view
            * revenue_per_unique_offer_click
            * revenue_per_unique_offer_view
            * revenue_per_unique_visitor
            * revenue_per_visit
            * revenue_per_visitor
            * revenue_per_page_view
            * revenue_per_page_click
            * cost_per_page_view
            * cost_per_page_click
            * conversion_per_page_view
            * conversion_per_page_click
            * rollup_visitors (journey tree internal)
            * rollup_conversions (journey tree internal)
            * rollup_revenue (journey tree internal)

          Any other name, including a base, duration or custom-event metric,
          is ignored and adds no metric to the rows; name those in
          restrictToMetrics. An ignored name still counts as naming metrics,
          so the default metric set does not apply.
        items:
          type: string
        x-nullable: true
        x-order: 10
      sortByAttributes:
        type: array
        default: []
        x-nullable: false
        items:
          type: string
        x-order: 11
      statusFilter:
        description: >-
          Filters zero-traffic assets by status when includeAssetsWithoutTraffic
          is true.

          Only effective with includeAssetsWithoutTraffic=true; ignored
          otherwise.

          Values: "active" (only active assets), "archived" (only archived
          assets),

          "not-deleted" or empty (all non-deleted assets, the default).
        type: string
        enum:
          - active
          - archived
          - not-deleted
        x-nullable: false
        x-order: 12
      returnAssetURL:
        description: |-
          When true, includes offerURL, offerPayout, and landerURL fields on
          applicable row attributes. Requires additional asset metadata lookups.
        type: boolean
        default: false
        x-nullable: false
        x-order: 13
      campaignIDs:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 14
      funnelIDs:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 15
      trafficSourceIDs:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 16
      pageIDs:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 17
      offerSourceIDs:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 18
      subCampaigns:
        description: DEPRECATED
        type: array
        items:
          type: string
        default: []
        x-nullable: false
        x-order: 19
  DrilldownReport:
    type: object
    required:
      - columns
      - rows
    properties:
      columns:
        $ref: "#/definitions/DrilldownReportColumns"
      rows:
        type: array
        items:
          $ref: "#/definitions/DrilldownReportRow"
        x-nullable: false
      rootRows:
        description: >-
          Root-level rows for journey tree reports. Only present for
          journey-mode reports.

          Contains the top-level funnel entries before tree expansion.
        type: array
        items:
          $ref: "#/definitions/DrilldownReportRow"
        x-nullable: true
      entities:
        description: >-
          DEPRECATED in V2. Category and offer source metadata is now embedded
          directly

          on each row attribute via categoryID and offerSourceID fields.

          This field is omitted from V2 responses.
        $ref: "#/definitions/DrilldownReportEntities"
        x-nullable: true
      journeyData:
        description: >-
          Aggregate totals for journey tree reports. Only present for
          journey-mode reports.

          Omitted (absent from JSON) when not applicable, rather than null.
        x-nullable: true
        $ref: "#/definitions/DrilldownReportRow"
  DrilldownReportColumns:
    type: object
    x-nullable: false
    required:
      - attributes
    properties:
      attributes:
        type: array
        items:
          $ref: "#/definitions/Attribute"
        x-nullable: false
  DrilldownReportCustomEventMetric:
    x-nullable: false
    type: object
    required:
      - count
      - revenue
    properties:
      count:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      revenue:
        $ref: "#/definitions/Decimal"
  DrilldownReportRow:
    type: object
    required:
      - attributes
      - visitors
      - visits
      - cost
      - nodeViews
      - nodeViewsUnique
      - landerViews
      - landerViewsUnique
      - landerClicks
      - landerClicksUnique
      - offerViews
      - offerViewsUnique
      - offerClicks
      - offerClicksUnique
      - conversions
      - revenue
      - totalRevenue
    properties:
      attributes:
        type: array
        items:
          $ref: "#/definitions/DrilldownReportRowAttribute"
        x-nullable: false
      visitors:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      visits:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      cost:
        $ref: "#/definitions/Decimal"
      nodeViews:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      nodeViewsUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      landerViews:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      landerViewsUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      landerClicks:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      landerClicksUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      offerViews:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      offerViewsUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      offerClicks:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      offerClicksUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      pageViews:
        type: number
        format: int64
        minimum: 0
        x-nullable: true
      pageViewsUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: true
      pageClicks:
        type: number
        format: int64
        minimum: 0
        x-nullable: true
      pageClicksUnique:
        type: number
        format: int64
        minimum: 0
        x-nullable: true
      conversions:
        type: number
        format: int64
        minimum: 0
        x-nullable: false
      revenue:
        $ref: "#/definitions/Decimal"
      totalRevenue:
        $ref: "#/definitions/Decimal"
      averageTimeOnPage:
        description: >-
          Average visible time on page, in seconds, carrying decimals. Derived
          from EventType 6 beacon rows, which store the duration as milliseconds
          quantised to a 100ms grid.

          Opt-in: this metric is NOT part of the default metric set, so it is
          returned only when "averageTimeOnPage" is listed explicitly in
          restrictToMetrics.

          Omitted whenever nothing was measured: the metric was not requested,
          the row is a node type that cannot hold a page duration (rotator,
          condition, external URL, action row, funnel root), or the row is an
          eligible page that received no beacons at all. A returned value is
          always a real measurement — a returned 0 means beacons landed and
          averaged to zero, which is a different claim from "no data". Render
          the absent case as "no data", never as 0.
        type: number
        format: double
        minimum: 0
        x-nullable: true
      bounceRate:
        description: >-
          Share of measured page views, as a percentage from 0 to 100, that
          ended in under 3000 ms. The threshold is fixed and not configurable,
          so the metric is comparable across owners and across time.

          The denominator is MEASURED page views (EventType 6 beacon rows), not
          all page views. A page view with no beacon appears in neither the
          numerator nor the denominator, so bounceRate only describes JS-tracked
          traffic. Beacons whose duration rounds to zero on the 100ms
          quantisation grid are discarded at the edge, so the metric slightly
          under-reports the very fastest exits.

          Opt-in: this metric is NOT part of the default metric set, so it is
          returned only when "bounceRate" is listed explicitly in
          restrictToMetrics; either duration metric can be requested alone. It
          shares averageTimeOnPage's denominator and eligibility rule, so when
          both are requested they appear and disappear together, and a request
          naming only one never receives the other. A returned 0 means beacons
          landed and none of them bounced.
        type: number
        format: double
        minimum: 0
        maximum: 100
        x-nullable: true
      calculatedMetrics:
        $ref: "#/definitions/DrilldownReportRowCalculatedMetrics"
        x-nullable: false
      customEvent1:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent2:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent3:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent4:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent5:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent6:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent7:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent8:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent9:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      customEvent10:
        type: object
        x-nullable: true
        properties:
          count:
            type: number
            format: int64
            minimum: 0
            x-nullable: false
          revenue:
            $ref: "#/definitions/Decimal"
      children:
        type: object
        x-nullable: true
        additionalProperties:
          x-nullable: true
          $ref: "#/definitions/DrilldownReportRow"
      index:
        type: number
        format: int64
        minimum: 1
        x-nullable: false
  DrilldownReportEntities:
    type: object
    x-nullable: false
    properties:
      categories:
        type: array
        items:
          $ref: "#/definitions/Category"
        x-nullable: false
      offerSources:
        type: array
        items:
          $ref: "#/definitions/OfferSource"
        x-nullable: false
  DrilldownReportRowAttribute:
    type: object
    required:
      - attribute
      - id
      - value
      - status
    properties:
      attribute:
        type: string
        x-nullable: false
      id:
        type: string
        x-nullable: false
      value:
        type: string
        x-nullable: false
      info:
        type: string
        x-nullable: false
      status:
        $ref: "#/definitions/Status"
        x-nullable: false
      nodeID:
        description: Journey tree node identifier. Only present for journey-mode reports.
        type: string
        x-nullable: false
      categoryID:
        type: string
        x-nullable: false
      offerSourceID:
        type: string
        x-nullable: false
      offerURL:
        description: Offer destination URL. Only present when returnAssetURL is true in
          the request.
        type: string
        x-nullable: false
      offerPayout:
        description: Offer default payout. Only present when returnAssetURL is true in
          the request.
        type: string
        x-nullable: false
      landerURL:
        description: Lander destination URL. Only present when returnAssetURL is true in
          the request.
        type: string
        x-nullable: false
  DrilldownReportRowCalculatedMetrics:
    type: object
    properties:
      lander_ctr:
        type: number
        format: float64
        x-nullable: true
      offer_ctr:
        type: number
        format: float64
        x-nullable: true
      unique_lander_ctr:
        type: number
        format: float64
        x-nullable: true
      unique_offer_ctr:
        type: number
        format: float64
        x-nullable: true
      conversion_per_lander_click:
        type: number
        format: float64
        x-nullable: true
      conversion_per_lander_view:
        type: number
        format: float64
        x-nullable: true
      conversion_per_offer_click:
        type: number
        format: float64
        x-nullable: true
      conversion_per_offer_view:
        type: number
        format: float64
        x-nullable: true
      conversion_per_unique_lander_click:
        type: number
        format: float64
        x-nullable: true
      conversion_per_unique_lander_view:
        type: number
        format: float64
        x-nullable: true
      conversion_per_unique_offer_click:
        type: number
        format: float64
        x-nullable: true
      conversion_per_unique_offer_view:
        type: number
        format: float64
        x-nullable: true
      conversion_per_unique_visitor:
        type: number
        format: float64
        x-nullable: true
      conversion_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_1_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_2_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_3_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_4_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_5_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_6_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_7_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_8_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_9_per_visit:
        type: number
        format: float64
        x-nullable: true
      custom_event_10_per_visit:
        type: number
        format: float64
        x-nullable: true
      cost_per_conversion:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_1:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_2:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_3:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_4:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_5:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_6:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_7:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_8:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_9:
        type: number
        format: float64
        x-nullable: true
      cost_per_event_10:
        type: number
        format: float64
        x-nullable: true
      cost_per_lander_click:
        type: number
        format: float64
        x-nullable: true
      cost_per_lander_view:
        type: number
        format: float64
        x-nullable: true
      cost_per_offer_click:
        type: number
        format: float64
        x-nullable: true
      cost_per_offer_view:
        type: number
        format: float64
        x-nullable: true
      cost_per_unique_lander_click:
        type: number
        format: float64
        x-nullable: true
      cost_per_unique_lander_view:
        type: number
        format: float64
        x-nullable: true
      cost_per_unique_offer_click:
        type: number
        format: float64
        x-nullable: true
      cost_per_unique_offer_view:
        type: number
        format: float64
        x-nullable: true
      cost_per_unique_visitor:
        type: number
        format: float64
        x-nullable: true
      cost_per_visit:
        type: number
        format: float64
        x-nullable: true
      cost_per_visitor:
        type: number
        format: float64
        x-nullable: true
      uniqueness:
        type: number
        format: float64
        x-nullable: true
      profit_and_loss:
        type: number
        format: float64
        x-nullable: true
      roi:
        type: number
        format: float64
        x-nullable: true
      revenue_per_conversion:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_1:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_2:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_3:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_4:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_5:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_6:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_7:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_8:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_9:
        type: number
        format: float64
        x-nullable: true
      revenue_per_event_10:
        type: number
        format: float64
        x-nullable: true
      revenue_per_lander_click:
        type: number
        format: float64
        x-nullable: true
      revenue_per_lander_view:
        type: number
        format: float64
        x-nullable: true
      revenue_per_offer_click:
        type: number
        format: float64
        x-nullable: true
      revenue_per_offer_view:
        type: number
        format: float64
        x-nullable: true
      revenue_per_unique_lander_click:
        type: number
        format: float64
        x-nullable: true
      revenue_per_unique_lander_view:
        type: number
        format: float64
        x-nullable: true
      revenue_per_unique_offer_click:
        type: number
        format: float64
        x-nullable: true
      revenue_per_unique_offer_view:
        type: number
        format: float64
        x-nullable: true
      revenue_per_unique_visitor:
        type: number
        format: float64
        x-nullable: true
      revenue_per_visit:
        type: number
        format: float64
        x-nullable: true
      revenue_per_visitor:
        type: number
        format: float64
        x-nullable: true
      lander_ctr_unique:
        description: Alias for unique_lander_ctr
        type: number
        format: float64
        x-nullable: true
      offer_ctr_unique:
        description: Alias for unique_offer_ctr
        type: number
        format: float64
        x-nullable: true
      ctr:
        description: General click-through rate
        type: number
        format: float64
        x-nullable: true
      unique_ctr:
        description: Combined unique click-through rate
        type: number
        format: float64
        x-nullable: true
      revenue_per_page_view:
        type: number
        format: float64
        x-nullable: true
      revenue_per_page_click:
        type: number
        format: float64
        x-nullable: true
      cost_per_page_view:
        type: number
        format: float64
        x-nullable: true
      cost_per_page_click:
        type: number
        format: float64
        x-nullable: true
      conversion_per_page_view:
        type: number
        format: float64
        x-nullable: true
      conversion_per_page_click:
        type: number
        format: float64
        x-nullable: true
      epv:
        description: Earnings per visit
        type: number
        format: float64
        x-nullable: true
      epc:
        description: Earnings per click
        type: number
        format: float64
        x-nullable: true
      rollup_visitors:
        description: Journey tree rollup - total visitors through this path
        type: number
        format: float64
        x-nullable: true
      rollup_conversions:
        description: Journey tree rollup - total conversions through this path
        type: number
        format: float64
        x-nullable: true
      rollup_revenue:
        description: Journey tree rollup - total revenue through this path
        type: number
        format: float64
        x-nullable: true
  AttributeData:
    type: object
    properties:
      attribute:
        $ref: "#/definitions/Attribute"
      whitelistFilters:
        description: >-
          If not empty, then only rows where at least one of the specified
          filters is true will be returned.

          For asset-related groupings like 'traffic source', 'campaign',
          'lander' etc, a filter must be the asset's id.

          For Connection: Connection Type, Device: Device Type, and Filtered
          Status, a filter accepts

          a display label (case-insensitive) or the numeric id string returned
          by drilldown rows.

          Connection Type: the empty id "" and the Connection data not available
          label (case-insensitive) select NULL rows only; "0" selects id 0 only.

          Device Type: the empty id "" and the Unknown label select id 0 and
          NULL rows; "0" selects id 0 only.

          Filtered Status: the empty id "" and Not Filtered select id 0; there
          is no NULL selector.

          An unknown label or id, or any value containing '*', returns HTTP 400
          on these three groupings.

          Other groupings accept case-insensitive strings such as 'Malaysia';
          filters containing '*' use wildcard matching there.
        type: array
        items:
          type: string
      blacklistFilters:
        description: >-
          If not empty, then only rows where all the specified filters are false
          will be returned.

          For asset-related groupings like 'traffic source', 'campaign',
          'lander' etc, a filter must be the asset's id.

          For Connection: Connection Type, Device: Device Type, and Filtered
          Status, a filter accepts

          a display label (case-insensitive) or the numeric id string returned
          by drilldown rows.

          Connection Type: the empty id "" and the Connection data not available
          label (case-insensitive) exclude NULL rows only; "0" excludes id 0
          only.

          Device Type: the empty id "" and the Unknown label exclude id 0 and
          NULL rows; "0" excludes id 0 only.

          Filtered Status: the empty id "" and Not Filtered exclude id 0; there
          is no NULL selector.

          Blacklists retain NULL rows unless a value that selects NULL is
          blacklisted.

          An unknown label or id, or any value containing '*', returns HTTP 400
          on these three groupings.

          Other groupings accept case-insensitive strings such as 'Malaysia';
          filters containing '*' use wildcard matching there.
        type: array
        items:
          type: string
      trackingFieldSlot:
        description: "For URL Tracking Field: which column to group by (campaign,
          c1-c20). Replaces the legacy wildcard pattern."
        type: string
  PostbackLogAttributeData:
    type: object
    properties:
      attribute:
        $ref: "#/definitions/PostbackLogAttribute"
      whitelistFilters:
        description: If not empty, then only rows where at least one of the specified
          filters is true will be returned.
        type: array
        items:
          type: string
      blacklistFilters:
        description: If not empty, then only rows where all the specified filters are
          false will be returned.
        type: array
        items:
          type: string
  Category:
    type: object
    required:
      - id
      - name
      - type
      - status
    properties:
      id:
        type: string
        x-nullable: false
      name:
        type: string
        x-nullable: false
      type:
        type: string
        enum:
          - offer
          - lander
          - offersources
          - trafficsources
          - condition
        x-nullable: false
      status:
        $ref: "#/definitions/Status"
        x-nullable: false
  OfferSource:
    type: object
    required:
      - id
      - name
      - categoryID
      - status
    properties:
      id:
        type: string
        x-nullable: false
      name:
        type: string
        x-nullable: false
      categoryID:
        type: string
        x-nullable: false
      status:
        $ref: "#/definitions/Status"
        x-nullable: false
  Attribute:
    type: string
    enum:
      - URL Tracking Field
      - Tracking Field List
      - Tracking Field Values
      - "Element: Campaign"
      - "Element: Funnel Group"
      - "Element: Funnel"
      - "Element: Lander"
      - "Element: Lander Group"
      - "Element: Global Lander Group"
      - "Element: Global Lander Group Category"
      - "Element: Offer"
      - "Element: Offer Group"
      - "Element: Global Offer Group"
      - "Element: Global Offer Group Category"
      - "Element: Lander Category"
      - "Element: Offer Category"
      - "Element: Node ID"
      - "Element: Node Name"
      - "Insight: Visitor Journey"
      - "Insight: Visitor Journey (Lander-Offer Groups)"
      - "Insight: Visitor Journey (All Nodes)"
      - "Insight: Visitor Journey (All Nodes w/ Actions)"
      - "Insight: Visitor Journey (Pages w/ Actions)"
      - "Insight: MVT Combination"
      - "Insight: MVT Key-Value Pairs"
      - "Insight: Time on Page Segments"
      - "Insight: Time to Conversion Segments"
      - "Third Parties: Traffic Source"
      - "Third Parties: Traffic Source Category"
      - "Third Parties: Offer Source"
      - "Third Parties: Offer Source Category"
      - "Traffic: Tracking Domain"
      - "Traffic: Visitor Tag"
      - "Traffic: Filtered Status"
      - "Insight: Action Number"
      - "Insight: Page > Action Number"
      - "Conversion: Transaction ID"
      - "Event: Custom Data 1"
      - "Event: Custom Data 2"
      - "Device: Device Type"
      - "Device: Brand"
      - "Device: Model"
      - "Device: Model Name"
      - "Device: OS"
      - "Device: OS Version"
      - "Device: Browser"
      - "Device: Browser Version"
      - "Device: Main Language"
      - "Connection: Connection Type"
      - "Connection: ISP"
      - "Connection: Mobile Carrier"
      - "Connection: Referrer"
      - "Connection: Referrer Domain"
      - "Connection: Type + Carrier + ISP"
      - "Location: Continent"
      - "Location: Country"
      - "Location: Region"
      - "Location: City"
      - "Location: Timezone"
      - "Time: Date"
      - "Time: Week-Parting"
      - "Time: Day-Parting"
      - "Time: 10-Minute Blocks"
      - "Time: 30-Minute Blocks"
      - "Time: 1-Hour Blocks"
      - "Time: 3-Hour Blocks"
      - Week of Year
  PostbackLogAttribute:
    type: string
    enum:
      - Time
      - URL
      - Owner
      - FunnelID
      - TrafficSourceID
      - HitID
      - ConversionID
      - TransactionID
      - EventNumber
      - Payout
      - Error
      - ResponseStatusCode
      - ResponseBody
      - Try
      - LastTry
      - IsIntegration
      - IntegrationId
      - QueryString
      - PageID
      - HasPiiEmail
      - HasPiiPhone
      - HasPiiZipcode
      - HasDedupeEventId
  HitReportParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - pagingLength
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
        x-order: 1
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
        x-order: 2
      filters:
        type: array
        items:
          $ref: "#/definitions/AttributeData"
        x-nullable: false
        x-order: 3
      includeHits:
        type: boolean
        default: true
        x-nullable: false
        x-order: 4
      includeClicks:
        type: boolean
        default: true
        x-nullable: false
        x-order: 5
      includeConversions:
        type: boolean
        default: true
        x-nullable: false
        x-order: 6
      includeCustomEvents:
        type: array
        items:
          type: string
        x-nullable: false
        x-order: 7
      sortBy:
        description: |-
          Column to sort results by. Defaults to 'eventTime' if not specified.
          Available sort columns:
            * eventTime - Time when the event occurred (default)
            * hitTime - Time when the original hit/entrance occurred
            * hitID - The unique hit identifier
            * visitorID - The visitor identifier
        type: string
        enum:
          - eventTime
          - hitTime
          - hitID
          - visitorID
        default: eventTime
        x-nullable: false
        x-order: 8
      sortDirection:
        description: Sort direction - ascending or descending
        type: string
        enum:
          - asc
          - desc
        default: desc
        x-nullable: false
        x-order: 9
      sort:
        description: "DEPRECATED: Use sortDirection instead. Sort direction for results."
        type: string
        enum:
          - asc
          - desc
        default: desc
        x-nullable: false
        x-order: 10
      visitorID:
        description: |-
          Filter results to a specific visitor ID. When provided, only events
          for this visitor will be returned. This is useful for investigating
          a specific user's journey through funnels.
        type: string
        default: ""
        x-nullable: false
        x-order: 11
      hitID:
        description: |-
          Filter results to a specific hit ID. When provided, only events
          for this hit will be returned. This is useful for investigating
          a specific tracking hit and all its associated events (clicks,
          conversions, custom events).
        type: string
        default: ""
        x-nullable: false
        x-order: 12
      pagingStart:
        type: integer
        format: int32
        minimum: 0
        default: 0
        x-nullable: false
        x-order: 13
      pagingLength:
        type: integer
        format: int32
        minimum: 1
        maximum: 10000
        x-nullable: false
        x-order: 14
      restrictToMetrics:
        description: >-
          If empty, returns default metrics. Can restrict the response to any
          combination of the following metrics (note a limit of 20 total metrics
          is imposed):
            * EventType
            * EventTime
            * HitTime
            * FunnelID
            * TrafficSourceID
            * External
            * NodeID
            * NodeType
            * NodeName
            * HitID
            * VisitorID
            * VisitorIP
            * ClickID
            * ConversionID
            * ConversionTransaction
            * Revenue
            * TotalRevenue
            * Cost
            * TrackingDomain
            * FunnelGroupID
            * OfferSourceID
            * PageID
            * PageCategoryID
            * PageGroupID
            * LocationContinent
            * LocationCountry
            * LocationRegion
            * LocationCity
            * ConnectionISP
            * ConnectionMobileCarrier
            * ConnectionType
            * ConnectionReferrerPath
            * ConnectionReferrerDomain
            * DeviceType
            * DeviceBrand
            * DeviceModel
            * DeviceModelName
            * DeviceOS
            * DeviceOSVersion
            * DeviceBrowser
            * DeviceBrowserVersion
            * DeviceMainLanguage
            * DeviceUserAgent
            * SubCampaign
            * TrackingField1
            * TrackingField2
            * TrackingField3
            * TrackingField4
            * TrackingField5
            * TrackingField6
            * TrackingField7
            * TrackingField8
            * TrackingField9
            * TrackingField10
            * TrackingField11
            * TrackingField12
            * TrackingField13
            * TrackingField14
            * TrackingField15
            * TrackingField16
            * TrackingField17
            * TrackingField18
            * TrackingField19
            * TrackingField20
            * CustomEvent1
            * CustomEvent2
            * CustomEvent3
            * CustomEvent4
            * CustomEvent5
            * CustomEvent6
            * CustomEvent7
            * CustomEvent8
            * CustomEvent9
            * CustomEvent10
            * EventData1
            * EventData2
            * FunnelName
            * TrafficSourceName
            * PageName
            * PageGroupName
            * FunnelGroupName
            * OfferSourceName
            * CategoryName
        type: array
        items:
          type: string
        x-nullable: true
        x-order: 15
  HitReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/HitReportRow"
        x-nullable: false
  HitReportRow:
    type: object
    properties:
      eventType:
        type: string
        enum:
          - hit
          - click
          - conversion
          - customEvent1
          - customEvent2
          - customEvent3
          - customEvent4
          - customEvent5
          - customEvent6
          - customEvent7
          - customEvent8
          - customEvent9
          - customEvent10
        x-nullable: false
        x-order: 1
      eventTime:
        type: string
        x-nullable: false
        x-order: 2
      hitTime:
        type: string
        x-nullable: false
        x-order: 3
      funnelID:
        type: string
        x-nullable: false
        x-order: 4
      trafficSourceID:
        type: string
        x-nullable: false
        x-order: 5
      external:
        type: string
        x-nullable: false
        x-order: 6
      nodeID:
        type: string
        x-nullable: false
        x-order: 7
      hitID:
        type: string
        x-nullable: false
        x-order: 8
      visitorID:
        type: string
        x-nullable: false
        x-order: 9
      visitorIP:
        type: string
        x-nullable: false
        x-order: 10
      clickID:
        type: string
        x-nullable: false
        x-order: 11
      conversionID:
        type: string
        x-nullable: false
        x-order: 12
      conversionTransaction:
        type: string
        x-nullable: false
        x-order: 13
      revenue:
        type: string
        x-nullable: false
        x-order: 14
      cost:
        type: string
        x-nullable: false
        x-order: 15
      trackingDomain:
        type: string
        x-nullable: false
        x-order: 16
      funnelGroupID:
        type: string
        x-nullable: false
        x-order: 17
      offerSourceID:
        type: string
        x-nullable: false
        x-order: 18
      pageID:
        type: string
        x-nullable: false
        x-order: 19
      pageCategoryID:
        type: string
        x-nullable: false
        x-order: 20
      pageGroupID:
        type: string
        x-nullable: false
        x-order: 21
      continent:
        type: string
        x-nullable: false
        x-order: 22
      country:
        type: string
        x-nullable: false
        x-order: 23
      region:
        type: string
        x-nullable: false
        x-order: 24
      city:
        type: string
        x-nullable: false
        x-order: 25
      connectionMobileCarrier:
        type: string
        x-nullable: false
        x-order: 26
      connectionType:
        type: string
        x-nullable: false
        x-order: 27
      connectionReferrerPath:
        type: string
        x-nullable: false
        x-order: 28
      connectionReferrerDomain:
        type: string
        x-nullable: false
        x-order: 29
      deviceType:
        type: string
        x-nullable: false
        x-order: 30
      deviceBrand:
        type: string
        x-nullable: false
        x-order: 31
      deviceModel:
        type: string
        x-nullable: false
        x-order: 32
      deviceModelName:
        type: string
        x-nullable: false
        x-order: 33
      deviceOS:
        type: string
        x-nullable: false
        x-order: 34
      deviceOSVersion:
        type: string
        x-nullable: false
        x-order: 35
      deviceBrowser:
        type: string
        x-nullable: false
        x-order: 36
      deviceBrowserVersion:
        type: string
        x-nullable: false
        x-order: 37
      deviceMainLanguage:
        type: string
        x-nullable: false
        x-order: 38
      deviceUserAgent:
        type: string
        x-nullable: false
        x-order: 39
      subCampaign:
        type: string
        x-nullable: false
        x-order: 40
      totalRevenue:
        type: string
        x-nullable: false
        x-order: 41
      trackingField1:
        type: string
        x-nullable: false
        x-order: 42
      trackingField2:
        type: string
        x-nullable: false
        x-order: 43
      trackingField3:
        type: string
        x-nullable: false
        x-order: 44
      trackingField4:
        type: string
        x-nullable: false
        x-order: 45
      trackingField5:
        type: string
        x-nullable: false
        x-order: 46
      trackingField6:
        type: string
        x-nullable: false
        x-order: 47
      trackingField7:
        type: string
        x-nullable: false
        x-order: 48
      trackingField8:
        type: string
        x-nullable: false
        x-order: 49
      trackingField9:
        type: string
        x-nullable: false
        x-order: 50
      trackingField10:
        type: string
        x-nullable: false
        x-order: 51
      trackingField11:
        type: string
        x-nullable: false
        x-order: 52
      trackingField12:
        type: string
        x-nullable: false
        x-order: 53
      trackingField13:
        type: string
        x-nullable: false
        x-order: 54
      trackingField14:
        type: string
        x-nullable: false
        x-order: 55
      trackingField15:
        type: string
        x-nullable: false
        x-order: 56
      trackingField16:
        type: string
        x-nullable: false
        x-order: 57
      trackingField17:
        type: string
        x-nullable: false
        x-order: 58
      trackingField18:
        type: string
        x-nullable: false
        x-order: 59
      trackingField19:
        type: string
        x-nullable: false
        x-order: 60
      trackingField20:
        type: string
        x-nullable: false
        x-order: 61
      nodeType:
        type: string
        enum:
          - rotator
          - lander
          - offer
          - landerGroup
          - offerGroup
          - externalURL
          - condition
          - visitorTag
        x-nullable: false
        x-order: 62
      nodeName:
        type: string
        x-nullable: false
        x-order: 63
      connectionISP:
        type: string
        x-nullable: false
        x-order: 64
      eventData1:
        type: string
        description: Custom event data field 1 for conversions and custom events
        x-nullable: false
        x-order: 65
      eventData2:
        type: string
        description: Custom event data field 2 for conversions and custom events
        x-nullable: false
        x-order: 66
      funnelName:
        type: string
        description: Resolved funnel name from asset JOIN
        x-nullable: false
        x-order: 67
      trafficSourceName:
        type: string
        description: Resolved traffic source name from asset JOIN
        x-nullable: false
        x-order: 68
      pageName:
        type: string
        description: Resolved page name from asset JOIN
        x-nullable: false
        x-order: 69
      pageGroupName:
        type: string
        description: Resolved page group (lander/offer group) name from asset JOIN
        x-nullable: false
        x-order: 70
      funnelGroupName:
        type: string
        description: Resolved funnel group (campaign) name from asset JOIN
        x-nullable: false
        x-order: 71
      offerSourceName:
        type: string
        description: Resolved offer source name from asset JOIN
        x-nullable: false
        x-order: 72
      categoryName:
        type: string
        description: Resolved page category name from asset JOIN
        x-nullable: false
        x-order: 73
  PostbackLogParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - pagingLength
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
        x-order: 1
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
        x-order: 2
      filters:
        type: array
        items:
          $ref: "#/definitions/PostbackLogAttributeData"
        x-nullable: false
        x-order: 3
      sort:
        type: string
        enum:
          - asc
          - desc
        default: desc
        x-nullable: false
        x-order: 4
      pagingStart:
        type: integer
        format: int32
        minimum: 0
        default: 0
        x-nullable: false
        x-order: 5
      pagingLength:
        type: integer
        format: int32
        minimum: 1
        maximum: 10000
        x-nullable: false
        x-order: 6
      restrictToMetrics:
        description: >-
          If empty, returns default metrics. Can restrict the response to any
          combination of the following metrics:
            * Time
            * URL
            * Owner
            * FunnelID
            * TrafficSourceID
            * HitID
            * ConversionID
            * TransactionID
            * EventNumber
            * Payout
            * Error
            * ResponseStatusCode
            * ResponseBody
            * Try
            * LastTry
            * IsIntegration
            * IntegrationId
            * QueryString
            * FunnelName
            * TrafficSourceName
            * PageID
            * PageName
            * PageCategoryName
            * OfferSourceName
            * HasPiiEmail
            * HasPiiPhone
            * HasPiiZipcode
            * HasDedupeEventId
        type: array
        items:
          type: string
        x-nullable: true
        x-order: 7
  PostbackLogReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/PostbackLogReportRow"
        x-nullable: false
  PostbackLogReportRow:
    type: object
    properties:
      time:
        type: string
        format: date-time
        x-nullable: false
        x-order: 1
      url:
        type: string
        x-nullable: false
        x-order: 2
      owner:
        type: string
        x-nullable: false
        x-order: 3
      funnelID:
        type: string
        x-nullable: false
        x-order: 4
      trafficSourceID:
        type: string
        x-nullable: false
        x-order: 5
      hitID:
        type: string
        x-nullable: false
        x-order: 6
      conversionID:
        type: string
        x-nullable: false
        x-order: 7
      transactionID:
        type: string
        x-nullable: false
        x-order: 8
      eventNumber:
        type: number
        format: int64
        x-nullable: false
        x-order: 9
      payout:
        type: number
        format: float64
        x-nullable: false
        x-order: 10
      error:
        type: string
        x-nullable: false
        x-order: 11
      responseStatusCode:
        type: number
        format: int32
        x-nullable: false
        x-order: 12
      responseBody:
        type: string
        x-nullable: false
        x-order: 13
      try:
        type: number
        format: int64
        x-nullable: false
        x-order: 14
      lastTry:
        type: number
        format: int64
        x-nullable: false
        x-order: 15
      isIntegration:
        type: string
        x-nullable: false
        x-order: 16
      integrationId:
        type: string
        x-nullable: false
        x-order: 17
      queryString:
        type: string
        x-nullable: false
        x-order: 18
      funnelName:
        type: string
        x-nullable: false
        x-order: 19
      trafficSourceName:
        type: string
        x-nullable: false
        x-order: 20
      pageID:
        type: string
        x-nullable: false
        x-order: 21
      pageName:
        type: string
        x-nullable: false
        x-order: 22
      pageCategoryName:
        type: string
        x-nullable: false
        x-order: 23
      offerSourceName:
        type: string
        x-nullable: false
        x-order: 24
      hasPiiEmail:
        type: boolean
        description: Whether the conversion has a PII email address
        x-nullable: false
        x-order: 25
      hasPiiPhone:
        type: boolean
        description: Whether the conversion has a PII phone number
        x-nullable: false
        x-order: 26
      hasPiiZipcode:
        type: boolean
        description: Whether the conversion has a PII zipcode
        x-nullable: false
        x-order: 27
      hasDedupeEventId:
        type: boolean
        description: Whether the conversion has a deduplication event ID
        x-nullable: false
        x-order: 28
  WebhookSummaryParams:
    type: object
    required:
      - timeStart
      - timeEnd
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
      statusFilter:
        type: string
        enum:
          - active
          - archived
          - deleted
          - not-deleted
          - all
        default: not-deleted
        x-nullable: false
      groupBy:
        type: array
        items:
          type: string
          enum:
            - webhookConfig
            - category
            - targetType
        x-nullable: true
      idWebhookConfigs:
        type: array
        items:
          type: string
        x-nullable: true
      idCategories:
        type: array
        items:
          type: string
        x-nullable: true
      targetTypes:
        type: array
        items:
          type: string
          enum:
            - custom
            - zapier
            - make
            - pipedream
            - pipedrive
            - n8n
            - tray_io
            - ifttt
            - aws_lambda
            - google_cloud_functions
            - azure_functions
            - cloudflare_workers
            - vercel_functions
            - netlify_functions
            - supabase_edge_functions
            - fastly_compute
            - inngest
            - qstash
            - webhook_site
            - slack
            - discord
            - telegram_bot_api
        x-nullable: true
      includeAssetsWithoutTraffic:
        type: boolean
        default: false
        x-nullable: false
  WebhookSummaryReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/WebhookSummaryReportRow"
        x-nullable: false
  WebhookSummaryReportRow:
    type: object
    properties:
      idWebhookConfig:
        type: string
        x-nullable: true
      webhookConfigName:
        type: string
        x-nullable: true
      idCategory:
        type: string
        x-nullable: true
      categoryName:
        type: string
        x-nullable: true
      targetType:
        type: string
        enum:
          - custom
          - zapier
          - make
          - pipedream
          - pipedrive
          - n8n
          - tray_io
          - ifttt
          - aws_lambda
          - google_cloud_functions
          - azure_functions
          - cloudflare_workers
          - vercel_functions
          - netlify_functions
          - supabase_edge_functions
          - fastly_compute
          - inngest
          - qstash
          - webhook_site
          - slack
          - discord
          - telegram_bot_api
        x-nullable: true
      status:
        type: string
        enum:
          - active
          - archived
          - deleted
        x-nullable: true
      enabled:
        type: boolean
        x-nullable: true
      executionCount:
        type: integer
        format: int64
        x-nullable: false
      successCount:
        type: integer
        format: int64
        x-nullable: false
      failureCount:
        type: integer
        format: int64
        x-nullable: false
      nodeExecutionCount:
        type: integer
        format: int64
        x-nullable: false
      onActionCount:
        type: integer
        format: int64
        x-nullable: false
      conversionTriggeredCount:
        type: integer
        format: int64
        x-nullable: false
      customEventTriggeredCount:
        type: integer
        format: int64
        x-nullable: false
  MiddlewareSummaryParams:
    type: object
    required:
      - timeStart
      - timeEnd
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
      statusFilter:
        type: string
        enum:
          - active
          - archived
          - disabled
          - deleted
          - not-deleted
          - all
        default: not-deleted
        x-nullable: false
      groupBy:
        type: array
        items:
          type: string
          enum:
            - middlewareConfig
            - category
            - destinationType
        x-nullable: true
      idMiddlewareConfigs:
        type: array
        items:
          type: string
        x-nullable: true
      idCategories:
        type: array
        items:
          type: string
        x-nullable: true
      destinationTypes:
        type: array
        items:
          type: string
          enum:
            - custom
            - zapier
            - make
            - pipedream
            - pipedrive
            - n8n
            - tray_io
            - ifttt
            - aws_lambda
            - google_cloud_functions
            - azure_functions
            - cloudflare_workers
            - vercel_functions
            - netlify_functions
            - supabase_edge_functions
            - fastly_compute
            - inngest
            - qstash
            - webhook_site
            - slack
            - discord
            - telegram_bot_api
        x-nullable: true
      includeAssetsWithoutTraffic:
        type: boolean
        default: false
        x-nullable: false
  MiddlewareSummaryReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/MiddlewareSummaryReportRow"
        x-nullable: false
  MiddlewareSummaryReportRow:
    type: object
    properties:
      idMiddlewareConfig:
        type: string
        x-nullable: true
      middlewareConfigName:
        type: string
        x-nullable: true
      idCategory:
        type: string
        x-nullable: true
      categoryName:
        type: string
        x-nullable: true
      destinationType:
        type: string
        enum:
          - custom
          - zapier
          - make
          - pipedream
          - pipedrive
          - n8n
          - tray_io
          - ifttt
          - aws_lambda
          - google_cloud_functions
          - azure_functions
          - cloudflare_workers
          - vercel_functions
          - netlify_functions
          - supabase_edge_functions
          - fastly_compute
          - inngest
          - qstash
          - webhook_site
          - slack
          - discord
          - telegram_bot_api
        x-nullable: true
      status:
        type: string
        enum:
          - active
          - archived
          - disabled
          - deleted
        x-nullable: true
      executionCount:
        type: integer
        format: int64
        x-nullable: false
      successCount:
        type: integer
        format: int64
        x-nullable: false
      failureCount:
        type: integer
        format: int64
        x-nullable: false
      timeoutCount:
        type: integer
        format: int64
        x-nullable: false
      successRate:
        type: number
        format: double
        x-nullable: false
      failureRate:
        type: number
        format: double
        x-nullable: false
      averageLatencyMs:
        type: number
        format: double
        description: Average middleware execution latency in milliseconds across rows
          with recorded latency.
        x-nullable: false
  IncomingPostbackLogParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - pagingLength
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
      filters:
        type: array
        items:
          $ref: "#/definitions/IncomingPostbackLogAttributeData"
        x-nullable: true
      sort:
        type: string
        enum:
          - asc
          - desc
        default: desc
        x-nullable: false
      pagingStart:
        type: integer
        format: int32
        minimum: 0
        default: 0
        x-nullable: false
      pagingLength:
        type: integer
        format: int32
        minimum: 1
        maximum: 10000
        x-nullable: false
      restrictToMetrics:
        type: array
        description: Optional requested row fields. When set, the response and SQL
          projection contain only these fields. Valid values are Time, Owner,
          RequestID, Domain, Path, Method, PostbackType, Status, ErrorCode,
          ErrorMessage, ResponseStatusCode, ClientIP, UserAgent, Referer, HitID,
          EventNumber, Revenue, TransactionID, EventData1, EventData2,
          ConversionTime, RevShare, DisablePostbacks, ForcePostbacks,
          HasPiiEmail, HasPiiPhone, HasPiiZipcode, HasDedupeEventId.
        items:
          type: string
          enum:
            - Time
            - Owner
            - RequestID
            - Domain
            - Path
            - Method
            - PostbackType
            - Status
            - ErrorCode
            - ErrorMessage
            - ResponseStatusCode
            - ClientIP
            - UserAgent
            - Referer
            - HitID
            - EventNumber
            - Revenue
            - TransactionID
            - EventData1
            - EventData2
            - ConversionTime
            - RevShare
            - DisablePostbacks
            - ForcePostbacks
            - HasPiiEmail
            - HasPiiPhone
            - HasPiiZipcode
            - HasDedupeEventId
        x-nullable: true
  IncomingPostbackLogAttributeData:
    type: object
    properties:
      attribute:
        type: string
        description: One of RequestID, Domain, Path, Method, PostbackType, Status,
          ErrorCode, ResponseStatusCode, ClientIP, UserAgent, HitID,
          EventNumber, TransactionID, HasPiiEmail, HasPiiPhone, HasPiiZipcode,
          HasDedupeEventId.
      whitelistFilters:
        type: array
        items:
          type: string
      blacklistFilters:
        type: array
        items:
          type: string
  IncomingPostbackLogReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/IncomingPostbackLogReportRow"
        x-nullable: false
  IncomingPostbackLogReportRow:
    type: object
    properties:
      time:
        type: string
        x-nullable: false
      owner:
        type: string
        x-nullable: false
      requestID:
        type: string
        x-nullable: false
      domain:
        type: string
        x-nullable: false
      path:
        type: string
        x-nullable: false
      method:
        type: string
        x-nullable: false
      postbackType:
        type: string
        description: conversion or custom_event.
        x-nullable: false
      status:
        type: string
        description: valid, invalid, or server_error.
        x-nullable: false
      errorCode:
        type: string
        description: Error taxonomy code, for example missing_hit, invalid_hit,
          invalid_custom_event_number, negative_revenue.
        x-nullable: false
      errorMessage:
        type: string
        x-nullable: false
      responseStatusCode:
        type: integer
        format: int32
        x-nullable: false
      clientIP:
        type: string
        x-nullable: false
      userAgent:
        type: string
        x-nullable: false
      referer:
        type: string
        x-nullable: false
      hitID:
        type: string
        x-nullable: false
      eventNumber:
        type: integer
        format: int32
        description: Custom-event number; null for conversion postbacks.
        x-nullable: true
      revenue:
        type: string
        x-nullable: false
      transactionID:
        type: string
        x-nullable: false
      eventData1:
        type: string
        x-nullable: false
      eventData2:
        type: string
        x-nullable: false
      conversionTime:
        type: string
        x-nullable: false
      revShare:
        type: string
        x-nullable: false
      disablePostbacks:
        type: string
        x-nullable: false
      forcePostbacks:
        type: string
        x-nullable: false
      hasPiiEmail:
        type: boolean
        x-nullable: false
      hasPiiPhone:
        type: boolean
        x-nullable: false
      hasPiiZipcode:
        type: boolean
        x-nullable: false
      hasDedupeEventId:
        type: boolean
        x-nullable: false
  IntegrationLogParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - pagingLength
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
      filters:
        type: array
        items:
          $ref: "#/definitions/IntegrationLogAttributeData"
        x-nullable: true
      sort:
        type: string
        enum:
          - asc
          - desc
        default: desc
        x-nullable: false
      pagingStart:
        type: integer
        format: int32
        minimum: 0
        default: 0
        x-nullable: false
      pagingLength:
        type: integer
        format: int32
        minimum: 1
        maximum: 10000
        x-nullable: false
  IntegrationLogAttributeData:
    type: object
    properties:
      attribute:
        type: string
        enum:
          - IntegrationID
          - TrafficSourceID
          - Platform
          - Intent
          - EventType
          - EventNumber
          - HitID
          - ConversionID
          - TransactionID
          - DestinationEvent
          - StatusCode
          - Success
          - Error
          - Outcome
      whitelistFilters:
        type: array
        items:
          type: string
      blacklistFilters:
        type: array
        items:
          type: string
  IntegrationLogReport:
    type: object
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/IntegrationLogReportRow"
        x-nullable: false
  IntegrationLogReportRow:
    type: object
    required:
      - time
      - owner
      - integrationId
      - trafficSourceId
      - platform
      - intent
      - eventType
      - eventNumber
      - hitId
      - conversionId
      - transactionId
      - destinationEvent
      - requestSummary
      - statusCode
      - responseBody
      - error
      - success
      - latencyMs
      - outcome
      - outcomeReason
    properties:
      time:
        type: string
        description: Log timestamp rendered in the request timezone offset derived from
          timeStart (format YYYY-MM-DD HH:MM:SS)
        x-nullable: false
      owner:
        type: string
        x-nullable: false
      integrationId:
        type: string
        x-nullable: false
      trafficSourceId:
        type: string
        x-nullable: false
      platform:
        type: string
        x-nullable: false
      intent:
        type: string
        x-nullable: false
      eventType:
        type: string
        x-nullable: false
      eventNumber:
        type: integer
        format: int64
        x-nullable: false
      hitId:
        type: string
        x-nullable: false
      conversionId:
        type: string
        x-nullable: false
      transactionId:
        type: string
        x-nullable: false
      destinationEvent:
        type: string
        x-nullable: false
      requestSummary:
        type: string
        x-nullable: false
      statusCode:
        type: integer
        format: int32
        x-nullable: false
      responseBody:
        type: string
        x-nullable: false
      error:
        type: string
        x-nullable: false
      success:
        type: boolean
        x-nullable: false
      latencyMs:
        type: integer
        format: int64
        x-nullable: false
      outcome:
        type: string
        description: Delivery outcome. queued, delivered, skipped, or failed on
          postbacks rows. unknown when the stored outcome is empty, including
          integrations-service connection_auth rows.
        enum:
          - queued
          - delivered
          - skipped
          - failed
          - unknown
        x-nullable: false
      outcomeReason:
        type: string
        description: Reason paired with outcome. Empty on legacy rows that stored no
          reason. queued uses inserted, coalesced, or released (a held row the
          sweep put back to pending). delivered uses accepted or duplicate.
          skipped uses dropped_stale, noop_completed, cancelled_pending,
          adjustment_unsupported, delivery_disabled, integration_removed
          (integration or traffic source missing, deleted, or unlinked),
          not_mapped, integration_inactive, integration_misconfigured, or
          credentials_invalid. failed uses queue_unavailable, expired,
          unsupported_platform, or the adapter error class.
        x-nullable: false
  IntegrationQueueLogParams:
    type: object
    required:
      - timeStart
      - timeEnd
      - pagingLength
    properties:
      timeStart:
        type: string
        format: date-time
        description: Inclusive start. Required. Bounds updated_at in UTC.
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        description: Inclusive end. Required and must be greater than or equal to timeStart.
        x-nullable: false
      filters:
        type: array
        items:
          $ref: "#/definitions/IntegrationQueueLogAttributeData"
        x-nullable: true
      sort:
        type: string
        enum:
          - asc
          - desc
        description: Order of updated_at, integration_id, and conversion_id. Defaults to
          desc.
      pagingStart:
        type: integer
        format: int32
        x-nullable: false
      pagingLength:
        type: integer
        format: int32
        description: Page size from 1 to 10000. The server fetches one extra row to set
          metadata.hasMore.
        x-nullable: false
  IntegrationQueueLogAttributeData:
    type: object
    properties:
      attribute:
        type: string
        description: Closed allowlist. HoldReason values are integration_inactive,
          integration_misconfigured, and credentials_invalid. Status accepts
          pending, processing, held, completed, and failed.
        enum:
          - IntegrationID
          - TrafficSourceID
          - Platform
          - Intent
          - EventType
          - EventNumber
          - HitID
          - ConversionID
          - TransactionID
          - DestinationEvent
          - Status
          - HoldReason
      whitelistFilters:
        type: array
        items:
          type: string
      blacklistFilters:
        type: array
        items:
          type: string
  IntegrationQueueLogReport:
    type: object
    required:
      - rows
      - metadata
    properties:
      rows:
        type: array
        items:
          $ref: "#/definitions/IntegrationQueueLogReportRow"
        x-nullable: false
      metadata:
        $ref: "#/definitions/IntegrationQueueLogMetadata"
  IntegrationQueueLogMetadata:
    type: object
    required:
      - rowsReturned
      - hasMore
    properties:
      rowsReturned:
        type: integer
        format: int32
        description: Rows in this page, after the extra sentinel row is trimmed.
        x-nullable: false
      hasMore:
        type: boolean
        description: True when another row exists beyond this page.
        x-nullable: false
  IntegrationQueueLogReportRow:
    type: object
    required:
      - activityTime
      - queueId
      - integrationId
      - integrationName
      - integrationType
      - platform
      - accountId
      - loginCustomerId
      - trafficSourceId
      - trafficSourceName
      - intent
      - eventType
      - hitId
      - conversionId
      - transactionId
      - destinationEvent
      - status
      - statusLabel
      - attempts
      - holdReason
      - lastError
      - clickTime
      - nextAttemptAt
      - createdAt
      - updatedAt
    properties:
      activityTime:
        type: string
        description: updated_at rendered in the request timezone offset (YYYY-MM-DD
          HH:MM:SS).
        x-nullable: false
      queueId:
        type: string
        x-nullable: false
      integrationId:
        type: string
        x-nullable: false
      integrationName:
        type: string
        description: Current asset_integrations.name. Empty when the asset join misses.
          Not replaced with the ID.
        x-nullable: false
      integrationType:
        type: string
        description: Current asset_integrations.type. Empty when the asset join misses.
        x-nullable: false
      platform:
        type: string
        description: Write-time platform. No server-side platform label.
        x-nullable: false
      accountId:
        type: string
        x-nullable: false
      loginCustomerId:
        type: string
        x-nullable: false
      trafficSourceId:
        type: string
        x-nullable: false
      trafficSourceName:
        type: string
        description: Current asset_traffic_sources.name. Empty when the asset join misses.
        x-nullable: false
      intent:
        type: string
        x-nullable: false
      eventType:
        type: string
        x-nullable: false
      eventNumber:
        type: integer
        format: int64
        x-nullable: true
      hitId:
        type: string
        x-nullable: false
      conversionId:
        type: string
        x-nullable: false
      transactionId:
        type: string
        x-nullable: false
      destinationEvent:
        type: string
        x-nullable: false
      status:
        type: string
        description: pending, processing, held, completed, or failed. An expired row is
          failed with lastError exactly expired. There is no resolution field.
        enum:
          - pending
          - processing
          - held
          - completed
          - failed
        x-nullable: false
      statusLabel:
        type: string
        description: Scheduled, Retry scheduled, Queued, Processing, Held, Completed, or
          Failed. Completed is not Delivered. Held is status=held.
        x-nullable: false
      attempts:
        type: integer
        format: int64
        x-nullable: false
      holdReason:
        type: string
        description: integration_inactive, integration_misconfigured,
          credentials_invalid, or empty when the row is not held.
        x-nullable: false
      lastError:
        type: string
        description: Redacted diagnostic. An expired held row stores exactly expired. A
          row held for a provider configuration error stores config_error
          <provider code>; it is re-sent hourly and fails with the same
          lastError once attempts reach the budget. completed rows are normally
          empty because completion clears the stored error.
        x-nullable: false
      clickTime:
        type: string
        x-nullable: false
      nextAttemptAt:
        type: string
        description: earliest_upload_at in the request timezone offset.
        x-nullable: false
      completedAt:
        type: string
        description: Null when the row has not completed.
        x-nullable: true
      createdAt:
        type: string
        x-nullable: false
      updatedAt:
        type: string
        x-nullable: false
  ExplorerVisitorRequest:
    type: object
    properties:
      visitorId:
        type: string
        description: Visitor ID to look up. Requires timeStart and timeEnd when used.
      hitId:
        type: string
        description: Hit ID to find the visitor for. Alternative to visitorId.
      timeStart:
        type: string
        format: date-time
        description: Start of time range (RFC3339). Required when using visitorId.
      timeEnd:
        type: string
        format: date-time
        description: End of time range (RFC3339). Required when using visitorId.
  ExplorerHitRequest:
    type: object
    required:
      - hitId
    properties:
      hitId:
        type: string
        description: The hit ID to look up
        x-nullable: false
      timeStart:
        type: string
        format: date-time
        description: Optional date hint for partition elimination when hit ID parsing fails
  ExplorerVisitorResponse:
    type: object
    properties:
      visitor:
        $ref: "#/definitions/VisitorInfo"
        x-nullable: true
      hits:
        type: array
        items:
          $ref: "#/definitions/ExplorerHitRow"
        x-nullable: false
      hasMore:
        type: boolean
        description: True if there are more hits beyond the returned set
        x-nullable: false
  ExplorerHitResponse:
    type: object
    properties:
      events:
        type: array
        description: All events for this hit ID — the original hit event, plus any
          conversion, customEvent1–10 events that reference it. Ordered by
          eventTime ASC.
        items:
          $ref: "#/definitions/ExplorerHitDetail"
        x-nullable: false
  VisitorInfo:
    type: object
    description: Visitor session summary derived from the entrance hit
    properties:
      visitorId:
        type: string
        x-nullable: false
      ip:
        type: string
        x-nullable: false
      country:
        type: string
        x-nullable: false
      region:
        type: string
        x-nullable: false
      city:
        type: string
        x-nullable: false
      isp:
        type: string
        x-nullable: false
      connectionType:
        type: string
        x-nullable: false
      mobileCarrier:
        type: string
        x-nullable: false
      deviceType:
        type: string
        x-nullable: false
      deviceBrand:
        type: string
        x-nullable: false
      deviceModel:
        type: string
        x-nullable: false
      deviceModelName:
        type: string
        x-nullable: false
      deviceOS:
        type: string
        x-nullable: false
      deviceOSVersion:
        type: string
        x-nullable: false
      browser:
        type: string
        x-nullable: false
      browserVersion:
        type: string
        x-nullable: false
      language:
        type: string
        x-nullable: false
      userAgent:
        type: string
        x-nullable: false
      firstSeen:
        type: string
        description: Timestamp of earliest hit in the queried range
        x-nullable: false
      lastSeen:
        type: string
        description: Timestamp of latest hit in the queried range
        x-nullable: false
      totalHits:
        type: number
        format: int64
        description: Number of hits returned in this response (capped at 100). Use
          hasMore to detect truncation.
        x-nullable: false
  ExplorerHitRow:
    type: object
    description: Compact hit row returned in visitor hit lists
    properties:
      hitId:
        type: string
        x-nullable: false
      eventType:
        type: string
        x-nullable: false
      eventTime:
        type: string
        x-nullable: false
      funnelId:
        type: string
        x-nullable: false
      funnelName:
        type: string
        x-nullable: false
      nodeId:
        type: string
        x-nullable: false
      nodeName:
        type: string
        x-nullable: false
      nodeType:
        type: string
        x-nullable: false
      trafficSourceId:
        type: string
        x-nullable: false
      trafficSourceName:
        type: string
        x-nullable: false
      pageId:
        type: string
        x-nullable: false
      pageName:
        type: string
        x-nullable: false
      pageGroupId:
        type: string
        x-nullable: false
      pageGroupName:
        type: string
        x-nullable: false
      funnelGroupId:
        type: string
        x-nullable: false
      funnelGroupName:
        type: string
        x-nullable: false
      offerSourceId:
        type: string
        x-nullable: false
      offerSourceName:
        type: string
        x-nullable: false
      categoryId:
        type: string
        x-nullable: false
      categoryName:
        type: string
        x-nullable: false
      cost:
        type: number
        format: float64
        x-nullable: false
      revenue:
        type: number
        format: float64
        x-nullable: false
      totalRevenue:
        type: number
        format: float64
        x-nullable: false
      clickId:
        type: string
        x-nullable: false
      conversionId:
        type: string
        x-nullable: false
      conversionTransaction:
        type: string
        x-nullable: false
      trackingDomain:
        type: string
        x-nullable: false
      externalId:
        type: string
        x-nullable: false
      subCampaign:
        type: string
        x-nullable: false
      t1:
        type: string
        x-nullable: false
      t2:
        type: string
        x-nullable: false
      t3:
        type: string
        x-nullable: false
      t4:
        type: string
        x-nullable: false
      t5:
        type: string
        x-nullable: false
      t6:
        type: string
        x-nullable: false
      t7:
        type: string
        x-nullable: false
      t8:
        type: string
        x-nullable: false
      t9:
        type: string
        x-nullable: false
      t10:
        type: string
        x-nullable: false
      t11:
        type: string
        x-nullable: false
      t12:
        type: string
        x-nullable: false
      t13:
        type: string
        x-nullable: false
      t14:
        type: string
        x-nullable: false
      t15:
        type: string
        x-nullable: false
      t16:
        type: string
        x-nullable: false
      t17:
        type: string
        x-nullable: false
      t18:
        type: string
        x-nullable: false
      t19:
        type: string
        x-nullable: false
      t20:
        type: string
        x-nullable: false
      eventData1:
        type: string
        x-nullable: false
      eventData2:
        type: string
        x-nullable: false
  ExplorerHitDetail:
    type: object
    description: >-
      Complete hit dump for single-hit lookup.

      Superset of ExplorerHitRow — adds device, geo, connection, referrer
      fields.
    properties:
      hitId:
        type: string
        x-nullable: false
      visitorId:
        type: string
        x-nullable: false
      eventType:
        type: string
        x-nullable: false
      eventTime:
        type: string
        x-nullable: false
      hitTime:
        type: string
        x-nullable: false
      funnelId:
        type: string
        x-nullable: false
      funnelName:
        type: string
        x-nullable: false
      nodeId:
        type: string
        x-nullable: false
      nodeName:
        type: string
        x-nullable: false
      nodeType:
        type: string
        x-nullable: false
      trafficSourceId:
        type: string
        x-nullable: false
      trafficSourceName:
        type: string
        x-nullable: false
      pageId:
        type: string
        x-nullable: false
      pageName:
        type: string
        x-nullable: false
      pageGroupId:
        type: string
        x-nullable: false
      pageGroupName:
        type: string
        x-nullable: false
      funnelGroupId:
        type: string
        x-nullable: false
      funnelGroupName:
        type: string
        x-nullable: false
      offerSourceId:
        type: string
        x-nullable: false
      offerSourceName:
        type: string
        x-nullable: false
      categoryId:
        type: string
        x-nullable: false
      categoryName:
        type: string
        x-nullable: false
      ip:
        type: string
        x-nullable: false
      ipv6:
        type: string
        x-nullable: false
      country:
        type: string
        x-nullable: false
      continent:
        type: string
        x-nullable: false
      region:
        type: string
        x-nullable: false
      city:
        type: string
        x-nullable: false
      isp:
        type: string
        x-nullable: false
      connectionType:
        type: string
        x-nullable: false
      mobileCarrier:
        type: string
        x-nullable: false
      referrerDomain:
        type: string
        x-nullable: false
      referrerPath:
        type: string
        x-nullable: false
      deviceType:
        type: string
        x-nullable: false
      deviceBrand:
        type: string
        x-nullable: false
      deviceModel:
        type: string
        x-nullable: false
      deviceModelName:
        type: string
        x-nullable: false
      deviceOS:
        type: string
        x-nullable: false
      deviceOSVersion:
        type: string
        x-nullable: false
      browser:
        type: string
        x-nullable: false
      browserVersion:
        type: string
        x-nullable: false
      language:
        type: string
        x-nullable: false
      userAgent:
        type: string
        x-nullable: false
      cost:
        type: number
        format: float64
        x-nullable: false
      revenue:
        type: number
        format: float64
        x-nullable: false
      totalRevenue:
        type: number
        format: float64
        x-nullable: false
      trackingDomain:
        type: string
        x-nullable: false
      externalId:
        type: string
        x-nullable: false
      clickId:
        type: string
        x-nullable: false
      conversionId:
        type: string
        x-nullable: false
      conversionTransaction:
        type: string
        x-nullable: false
      subCampaign:
        type: string
        x-nullable: false
      t1:
        type: string
        x-nullable: false
      t2:
        type: string
        x-nullable: false
      t3:
        type: string
        x-nullable: false
      t4:
        type: string
        x-nullable: false
      t5:
        type: string
        x-nullable: false
      t6:
        type: string
        x-nullable: false
      t7:
        type: string
        x-nullable: false
      t8:
        type: string
        x-nullable: false
      t9:
        type: string
        x-nullable: false
      t10:
        type: string
        x-nullable: false
      t11:
        type: string
        x-nullable: false
      t12:
        type: string
        x-nullable: false
      t13:
        type: string
        x-nullable: false
      t14:
        type: string
        x-nullable: false
      t15:
        type: string
        x-nullable: false
      t16:
        type: string
        x-nullable: false
      t17:
        type: string
        x-nullable: false
      t18:
        type: string
        x-nullable: false
      t19:
        type: string
        x-nullable: false
      t20:
        type: string
        x-nullable: false
      eventData1:
        type: string
        x-nullable: false
      eventData2:
        type: string
        x-nullable: false
  ConvertedHit:
    required:
      - id
    properties:
      id:
        description: Hit ID
        type: string
        x-nullable: false
      transaction:
        description: The optional transaction id
        type: string
        default: ""
        x-nullable: false
      revenue:
        description: >-
          An optional revenue amount. When not specified, the default revenue
          from the converted offer is used.

          If set to -1, then this hit is set as non-converted.
        $ref: "#/definitions/NullableDecimal"
        default: null
      piiEmail:
        description: An optional email address
        type: string
        default: ""
        x-nullable: true
      piiPhone:
        description: An optional phone number
        type: string
        default: ""
        x-nullable: true
      piiZipcode:
        description: An optional zipcode passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      dedupeEventId:
        description: Optional external dedupe ID passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      conversionTime:
        type: string
        default: ""
        description: The time when the conversion occurred. Accepts Unix timestamps,
          timezone-aware RFC formats, and the Raw Events display format
          YYYY-MM-DD HH:mm:ss. Raw Events values use timezone when supplied,
          otherwise UTC.
      timezone:
        type: string
        default: ""
        description: Optional UTC offset for conversionTime in the zone-less Raw Events
          format, written as UTC or UTC+/-HH[:MM]. Ignored when conversionTime
          is a Unix timestamp or contains an intrinsic timezone.
      eventData1:
        description: Optional conversion event data field 1
        type: string
        default: ""
        x-nullable: true
      eventData2:
        description: Optional conversion event data field 2
        type: string
        default: ""
        x-nullable: true
  ConversionsUpdateParams:
    required:
      - hits
    properties:
      hits:
        type: array
        items:
          $ref: "#/definitions/ConvertedHit"
        x-nullable: false
      postbackCalls:
        description: >-
          Set to 'none' to stop all outbound delivery for this request, the same
          as disablePostbacks: true.

          'onlyOnce' and 'all' are accepted for compatibility but have no
          effect, and an absent value does not stop

          delivery. In particular, 'onlyOnce' does not stop a re-upload from
          being delivered again; see the endpoint

          description for when that happens, and use 'none' or disablePostbacks
          to prevent it.
        type: string
        enum:
          - none
          - onlyOnce
          - all
        default: none
        x-nullable: false
      overridePayout:
        $ref: "#/definitions/NullableDecimal"
        default: null
      disablePostbacks:
        description: >-
          When true, FunnelFlux records the conversions but sends nothing to
          traffic source postback URLs, webhooks,

          or integrations for this request. Takes precedence over
          forcePostbacks. Use it for corrections that the

          traffic source must not receive again.
        type: boolean
        default: false
      forcePostbacks:
        description: >-
          When true, postback URLs and webhooks are also called for revenue
          corrections inside the correction window

          described for the endpoint, and for negative-revenue deletions at any
          time; neither is sent there otherwise.

          It does not resend an upload ignored as a duplicate and does not
          change what integrations receive. Ignored

          when disablePostbacks is true or postbackCalls is 'none'.
        type: boolean
        default: false
  CustomEventUploadHit:
    required:
      - id
      - eventNumber
    properties:
      id:
        description: Hit ID
        type: string
        x-nullable: false
      eventNumber:
        description: Custom event number, from 1 through 10
        type: integer
        minimum: 1
        maximum: 10
        x-nullable: false
      revenue:
        description: Optional non-negative custom event revenue
        $ref: "#/definitions/NullableDecimal"
        default: null
      piiEmail:
        description: An optional email address passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      piiPhone:
        description: An optional phone number passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      piiZipcode:
        description: An optional zipcode passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      dedupeEventId:
        description: Optional external dedupe ID passed through to postbacks
        type: string
        default: ""
        x-nullable: true
      conversionTime:
        type: string
        default: ""
        description: The time when the custom event occurred. Accepts Unix timestamps,
          timezone-aware RFC formats, and the Raw Events display format
          YYYY-MM-DD HH:mm:ss. Raw Events values use timezone when supplied,
          otherwise UTC.
      timezone:
        type: string
        default: ""
        description: Optional UTC offset for conversionTime in the zone-less Raw Events
          format, written as UTC or UTC+/-HH[:MM]. Ignored when conversionTime
          is a Unix timestamp or contains an intrinsic timezone.
      eventData1:
        description: Optional custom event data field 1
        type: string
        default: ""
        x-nullable: true
      eventData2:
        description: Optional custom event data field 2
        type: string
        default: ""
        x-nullable: true
  CustomEventsUpdateParams:
    required:
      - hits
    properties:
      hits:
        type: array
        items:
          $ref: "#/definitions/CustomEventUploadHit"
        minItems: 1
        maxItems: 10
        x-nullable: false
      postbackCalls:
        description: "Set to 'none' to stop all outbound delivery for this request, the
          same as disablePostbacks: true. Other values have no effect; custom
          events have no force option."
        type: string
        enum:
          - none
          - onlyOnce
          - all
        x-nullable: false
      disablePostbacks:
        description: When true, FunnelFlux records the custom events but sends nothing
          to traffic source postback URLs, webhooks, or integrations for this
          request.
        type: boolean
        default: false
  CostSegment:
    properties:
      cost:
        $ref: "#/definitions/Decimal"
        x-nullable: false
      costType:
        type: string
        enum:
          - wholeSegment
          - perEntrance
        default: wholeSegment
        x-nullable: false
      restrictToDeviceType:
        description: If set, then update cost of traffic that comes from this device
          type only. Unknown also matches entrances with no device data, as the
          drilldown report does. Accepts the label or its numeric id.
        type: string
        enum:
          - Unknown
          - Console
          - Desktop
          - EReader
          - MediaHub
          - Mobile
          - SmallScreen
          - SmartPhone
          - SmartWatch
          - Tablet
          - TV
          - Bot
      restrictToConnectionType:
        description: If set, then update cost of traffic that comes from this connection
          type only. Known Proxy and Hosting Provider require
          includeProxyHostingTraffic=true; otherwise the request is rejected
          with 400. Accepts the label or its numeric id.
        type: string
        enum:
          - Unknown
          - Mobile
          - Wired
          - Known Proxy
          - Hosting Provider
      restrictToBrowser:
        description: If set, then update cost of traffic that comes from this browser only
        type: string
        default: ""
      restrictToCountryCode:
        description: If set, then update cost of traffic that comes from this country only
        type: string
        default: ""
      restrictToTrackingFields:
        description: If set, then update cost of traffic that have these tracking
          fields' keys/values only. Keys are case-insensitive and must be
          campaign, external, or a tracking field slot 1-20 written as cN, tN,
          trackingfieldN, or tracking_field_N; any other key is rejected with
          400. A key with an empty value list or only blank values is rejected
          with 400; omit the key to leave tracking fields unrestricted.
        type: object
        additionalProperties:
          type: array
          items:
            type: string
        x-nullable: false
  CostUpdateParams:
    required:
      - funnelIDs
      - trafficSourceIDs
      - timeStart
      - timeEnd
      - costSegments
    properties:
      includeFilteredTraffic:
        description: Include filtered entrances when assigning cost. Defaults to false;
          excluded entrances are left out of the update and keep their existing
          cost.
        type: boolean
        default: false
      includeProxyHostingTraffic:
        description: Include Known Proxy and Hosting Provider entrances when assigning
          cost. Defaults to false; excluded entrances are left out of the update
          and keep their existing cost.
        type: boolean
        default: false
      funnelIDs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      trafficSourceIDs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      timeStart:
        description: Required nonzero inclusive start, on or after 2020-01-01T00:00:00Z.
          UTC instants are compared; offsets are accepted. No future-date
          restriction.
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        description: Required nonzero inclusive end, strictly after timeStart and no
          later than timeStart.UTC().AddDate(0, 12, 0). This is 12 calendar
          months (1-year data period), not 365 days; February 29 normalizes to
          March 1 in a non-leap year. Exact anniversary is accepted.
        type: string
        format: date-time
        x-nullable: false
      costSegments:
        type: array
        items:
          $ref: "#/definitions/CostSegment"
        x-nullable: false
  ResetUpdateParams:
    description: Estimate or execute a reset with at least one non-blank restriction
      beyond its bounded time window. Scope validation precedes time-window
      validation; execute inherits the same checks as estimate.
    required:
      - timeStart
      - timeEnd
    properties:
      timeStart:
        description: Required nonzero inclusive start, on or after 2020-01-01T00:00:00Z.
          UTC instants are compared; offsets are accepted. No future-date
          restriction.
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        description: Required nonzero inclusive end, strictly after timeStart and no
          later than timeStart.UTC().AddDate(0, 12, 0). This is 12 calendar
          months (1-year data period), not 365 days; February 29 normalizes to
          March 1 in a non-leap year. Exact anniversary is accepted.
        type: string
        format: date-time
        x-nullable: false
      restrictToCampaignIDs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      restrictToFunnelIDs:
        type: array
        items:
          type: string
          minLength: 1
          pattern: \S
        default: []
        x-nullable: false
      restrictToTrafficSourceIDs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      restrictToCountryCodes:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      restrictToVisitorIDs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      restrictToIPs:
        type: array
        items:
          type: string
        default: []
        x-nullable: false
      restrictToTrackingFields:
        description: If set, then reset only traffic that has these tracking fields'
          keys/values. Keys are case-insensitive and must be campaign, external,
          or a tracking field slot 1-20 written as cN, tN, trackingfieldN, or
          tracking_field_N; any other key is rejected with 400. A key with an
          empty value list or only blank values is rejected with 400; omit the
          key to leave tracking fields unrestricted.
        type: object
        additionalProperties:
          type: array
          items:
            type: string
        x-nullable: false
  PostbackLogCriteria:
    type: object
    required:
      - timeStart
      - timeEnd
    properties:
      timeStart:
        type: string
        format: date-time
        x-nullable: false
      timeEnd:
        type: string
        format: date-time
        x-nullable: false
      idFunnel:
        type: string
        default: ""
        x-nullable: false
      offset:
        type: integer
        format: int32
        default: 0
        x-nullable: false
      count:
        type: integer
        format: int32
        default: 100
        x-nullable: false
  PostbackLog:
    type: object
    required:
      - total
      - entries
    properties:
      total:
        type: integer
        format: int32
        x-nullable: false
      entries:
        type: array
        items:
          $ref: "#/definitions/PostbackLogEntry"
        x-nullable: false
  PostbackLogEntry:
    type: object
    x-nullable: false
    required:
      - time
      - url
      - idFunnel
      - idTrafficSource
      - idHit
      - idConversion
      - idTransaction
      - payout
      - error
      - responseStatusCode
      - responseBody
      - try
      - lastTry
    properties:
      time:
        type: string
        format: date-time
        x-nullable: false
      url:
        type: string
        x-nullable: false
      idFunnel:
        type: string
        x-nullable: false
      idTrafficSource:
        type: string
        x-nullable: false
      idHit:
        type: string
        x-nullable: false
      idConversion:
        type: string
        x-nullable: false
      idTransaction:
        type: string
        x-nullable: false
      payout:
        type: string
        x-nullable: false
        description: can be empty string if revenue payout is not specified
      error:
        type: string
        x-nullable: false
      responseStatusCode:
        type: integer
        format: int32
        minimum: 0
        x-nullable: false
      responseBody:
        type: string
        x-nullable: false
      try:
        type: integer
        format: int32
        minimum: 1
        x-nullable: false
      lastTry:
        type: boolean
        x-nullable: false
  IntegerValue:
    type: object
    required:
      - value
    properties:
      value:
        type: integer
        format: int64
        x-nullable: false
  Error:
    type: object
    required:
      - code
      - message
    properties:
      code:
        type: integer
        format: int32
        x-nullable: false
      message:
        type: string
        x-nullable: false
  Decimal:
    type: string
    x-nullable: false
    x-go-type:
      type: Decimal
      import:
        package: github.com/funnelflux/flux-saas-runtime/core/util/decimal
  NullableDecimal:
    type: string
    x-nullable: true
    x-go-type:
      type: NullableDecimal
      import:
        package: github.com/funnelflux/flux-saas-runtime/core/util/decimal
  Status:
    type: string
    enum:
      - active
      - archived
      - deleted
    default: active
    x-nullable: false
