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

# Reset compliance checks

> Starts a selection of invoice–agreement pairs over: cancels their unfinished checks, deletes their alerts, whoever created them, and marks them unchecked, so the next check evaluates them again. Alerts of a pair an open claim holds are kept. Completed compliance checks are retained. Nothing is started. A reset takes at most 50,000 pairs at once. An empty selection resets nothing and returns zeros. Repeating a reset deletes nothing more.



## OpenAPI

````yaml /openapi.json post /v1/checks/reset
openapi: 3.1.0
info:
  title: Watchdog API
  version: 1.0.0
  description: >-
    The Watchdog API is served from https://api.watchdog.no. Request bodies are
    limited to 2 MiB unless an endpoint says otherwise. Files are uploaded
    directly to storage, not through the API.
servers:
  - url: https://api.watchdog.no
    description: Watchdog API
security: []
paths:
  /v1/checks/reset:
    post:
      tags:
        - Compliance checks
      summary: Reset compliance checks
      description: >-
        Starts a selection of invoice–agreement pairs over: cancels their
        unfinished checks, deletes their alerts, whoever created them, and marks
        them unchecked, so the next check evaluates them again. Alerts of a pair
        an open claim holds are kept. Completed compliance checks are retained.
        Nothing is started. A reset takes at most 50,000 pairs at once. An empty
        selection resets nothing and returns zeros. Repeating a reset deletes
        nothing more.
      operationId: resetChecks
      parameters:
        - name: X-Organization-Id
          in: header
          required: false
          schema:
            type: string
          description: >-
            The organization to act in. Required for personal API keys; list the
            organizations you can access with GET /v1/organizations.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                scope:
                  oneOf:
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - invoices
                        invoice_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          minItems: 1
                          maxItems: 1000
                          description: >-
                            Up to 1,000 invoices. Every agreement matched to one
                            is in scope, and the purchase order accepted for
                            one.
                      required:
                        - type
                        - invoice_ids
                      additionalProperties: false
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - agreements
                        filter:
                          $ref: '#/components/schemas/AgreementFilter'
                        agreement_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 1000
                        excluded_agreement_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 1000
                          default: []
                      required:
                        - type
                      additionalProperties: false
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - topics
                        agreement_id:
                          type: string
                          format: uuid
                        topic_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 1000
                        include_uncategorized:
                          type: boolean
                          default: false
                      required:
                        - type
                        - agreement_id
                        - topic_ids
                      additionalProperties: false
                  description: >-
                    agreements: agreement_ids, or every agreement filter matches
                    (the whole collection, not a page), minus
                    excluded_agreement_ids; at most 1,000. topics: the invoices
                    behind some topics of one agreement, include_uncategorized
                    adding its alerts without a topic; a pair is handled as a
                    whole, so its alerts in other topics change too
                    (other_topic_alert_count).
                invoices:
                  oneOf:
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - all
                        excluded_invoice_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 5000
                          default: []
                          description: >-
                            Invoices left out of an otherwise complete
                            selection.
                      required:
                        - type
                      additionalProperties: false
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - sample
                        seed:
                          type: string
                          format: uuid
                        invoice_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 10
                          description: >-
                            Invoice IDs returned by the preview, pinned until
                            the user changes the selection.
                      required:
                        - type
                        - seed
                      additionalProperties: false
                    - type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - selected
                        invoice_ids:
                          type: array
                          items:
                            type: string
                            format: uuid
                          maxItems: 5000
                      required:
                        - type
                        - invoice_ids
                      additionalProperties: false
                  default:
                    type: all
                    excluded_invoice_ids: []
                  description: >-
                    Which of the scope’s invoices to take: all (minus
                    exclusions), a sample of ten, or a hand-picked set.
                issued_from:
                  type: string
                  format: date
                  description: Only invoices issued on or after this date.
                issued_through:
                  type: string
                  format: date
                  description: Only invoices issued on or before this date.
                company_ids:
                  type: array
                  items:
                    type: string
                    format: uuid
                  minItems: 1
                  maxItems: 1000
                  description: >-
                    Only these workspace companies: their invoices under
                    agreements covering them, as for a member with access to
                    just those companies. Omit for every company the caller can
                    access. An unknown or inaccessible company is 404.
                preview:
                  type: boolean
                  default: false
                  description: >-
                    true: return what the command would do and its fingerprint,
                    changing nothing.
                fingerprint:
                  type: string
                  minLength: 64
                  maxLength: 64
                  description: >-
                    The fingerprint of a preview. When sent, the command runs
                    only if the selection still resolves to exactly what was
                    previewed; omit it to act on the current state.
              required:
                - scope
              additionalProperties: false
      responses:
        '200':
          description: >-
            With preview: true, what a reset would change (CheckResetPreview).
            Otherwise what the reset changed (CheckReset).
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/CheckResetPreview'
                  - $ref: '#/components/schemas/CheckReset'
        '400':
          description: >-
            The request is invalid. details lists up to 20 field errors. Request
            bodies are limited to 2 MiB.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              example:
                error:
                  code: validation_error
                  message: >-
                    The request is invalid. details lists up to 20 field errors.
                    Request bodies are limited to 2 MiB.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_validation_error'
        '401':
          description: The bearer token is missing or invalid.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
            WWW-Authenticate:
              schema:
                type: string
              required: false
              description: Bearer authentication challenge, when supplied.
          content:
            application/json:
              example:
                error:
                  code: invalid_token
                  message: The bearer token is missing or invalid.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_invalid_token'
        '403':
          description: >-
            Access denied. The error code says why: forbidden, token_disabled,
            organization_required, insufficient_role or mfa_required.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              example:
                error:
                  code: forbidden
                  message: >-
                    Access denied. The error code says why: forbidden,
                    token_disabled, organization_required, insufficient_role or
                    mfa_required.
                  request_id: req_example
              schema:
                $ref: >-
                  #/components/schemas/Error_forbidden_token_disabled_organization_required_insufficient_role_mfa_required
        '404':
          description: The resource does not exist in the current organization.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              example:
                error:
                  code: not_found
                  message: The resource does not exist in the current organization.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_not_found'
        '409':
          description: >-
            The selection changed since the preview or while resetting, or it
            has more than 50,000 pairs. Nothing was changed.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              example:
                error:
                  code: conflict
                  message: >-
                    The selection changed since the preview or while resetting,
                    or it has more than 50,000 pairs. Nothing was changed.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_conflict'
        '429':
          description: Too many requests. Wait for the Retry-After delay before retrying.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
            Retry-After:
              schema:
                type: string
                example: '60'
              required: true
              description: Seconds to wait before retrying the request.
          content:
            application/json:
              example:
                error:
                  code: rate_limit_exceeded
                  message: >-
                    Too many requests. Wait for the Retry-After delay before
                    retrying.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_rate_limit_exceeded'
        '500':
          description: >-
            Unexpected server failure. Include the request ID when contacting
            support.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
          content:
            application/json:
              example:
                error:
                  code: internal_error
                  message: >-
                    Unexpected server failure. Include the request ID when
                    contacting support.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_internal_error'
        '503':
          description: >-
            Temporarily unavailable. Retry after the Retry-After delay, when
            provided.
          headers:
            X-Request-Id:
              schema:
                type: string
              required: true
              description: >-
                Request ID, also included in error bodies. Include it when
                contacting support.
            Cache-Control:
              schema:
                type: string
                enum:
                  - private, no-store
                  - private, no-store, no-transform
              required: false
              description: API responses are private and must not be cached.
            X-RateLimit-Limit:
              schema:
                type: string
                example: '500'
              required: false
              description: >-
                Requests allowed per minute for this credential, or failed API
                key attempts allowed per minute from this IP address.
            Retry-After:
              schema:
                type: string
                example: '60'
              required: true
              description: Seconds to wait before retrying the request.
          content:
            application/json:
              example:
                error:
                  code: service_unavailable
                  message: >-
                    Temporarily unavailable. Retry after the Retry-After delay,
                    when provided.
                  request_id: req_example
              schema:
                $ref: '#/components/schemas/Error_service_unavailable'
      security:
        - ApiKeyBearer: []
components:
  schemas:
    AgreementFilter:
      type: object
      properties:
        view_ids:
          type: array
          items:
            type: string
        ids:
          type: array
          items:
            type: string
            format: uuid
        renewal_action_kinds:
          type: array
          items:
            type: string
            enum:
              - cancel_by
              - renew_by
              - automatic_notice
              - missing_details
              - none
          description: >-
            The next renewal action. cancel_by: renews unless cancelled by the
            deadline; renew_by: ends unless renewed by it; automatic_notice: no
            expiration date, ends with the notice period, so no deadline;
            missing_details: no deadline can be computed; none: no renewal left.
        renewal_deadline_from:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        renewal_deadline_through:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        upcoming_through:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
          description: >-
            A renewal deadline or expiration date from today (organization's
            timezone) through this date: what must be cancelled, renewed or will
            end soon.
        search:
          type: string
          minLength: 1
          maxLength: 200
          description: Agreement title or a supplier name.
        statuses:
          type: array
          items:
            type: string
            enum:
              - draft
              - active
              - archived
          description: >-
            draft: being set up; active: invoices are checked against it;
            archived: no longer checked. Says nothing about whether the term is
            in force: use valid_on for that.
        supplier_ids:
          type: array
          items:
            type: string
            format: uuid
        recipient_ids:
          type: array
          items:
            type: string
            format: uuid
          description: Includes agreements for any recipient.
        company_ids:
          type: array
          items:
            type: string
            format: uuid
          minItems: 1
          maxItems: 1000
          description: >-
            Agreements that cover any of these companies. A shared agreement
            appears once, with its alert numbers and counts for those companies'
            invoices only.
        tag_ids:
          type: array
          items:
            type: string
            format: uuid
        owner_user_ids:
          type: array
          items:
            type: string
            minLength: 1
            maxLength: 200
            pattern: ^[A-Za-z0-9_-]+$
          description: Case-sensitive.
        has_owner:
          type: boolean
          description: >-
            false: agreements with no owner; true: agreements with an owner.
            Removing a member unassigns their agreements. Combined with
            owner_user_ids, false matches nothing.
        auto_check_new_invoices:
          type: boolean
          description: >-
            true: agreements whose new matching invoices are checked
            automatically; false: those checked only when someone runs a check.
        has_alert_verdicts:
          type: array
          items:
            type: string
            enum:
              - pending
              - accepted
              - dismissed
              - skipped
          description: >-
            At least one alert with any of these verdicts; with
            has_alert_credited, on the same alert.
        has_alert_credited:
          type: boolean
          description: At least one alert (not) credited.
        review_status:
          type: string
          enum:
            - to_review
            - reviewed
          description: >-
            to_review: at least one live alert still to review (pending).
            reviewed: live alerts, every one of them confirmed, a false alarm or
            unsure. Agreements without live alerts match neither.
        effective_from:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
          description: Excludes agreements without one.
        effective_through:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        expiration_from:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
          description: Excludes agreements without one.
        expiration_through:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        valid_on:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
          description: >-
            In force on this date: effective on or before it and expiring on or
            after it. A missing date counts as open-ended.
        join_operator:
          type: string
          enum:
            - and
            - or
          description: or combines only supplier_ids and tag_ids.
        not:
          type: array
          items:
            type: string
            enum:
              - statuses
              - supplier_ids
              - recipient_ids
              - tag_ids
              - owner_user_ids
              - renewal_action_kinds
          description: List filters to invert.
      additionalProperties: false
    CheckResetPreview:
      type: object
      properties:
        fingerprint:
          type: string
        invoice_count:
          type: integer
          description: Invoices with a pair in scope.
        pair_count:
          type: integer
          description: Invoice–agreement pairs in scope.
        deletable_alert_count:
          type: integer
          description: Alerts the reset would delete.
        kept_alert_count:
          type: integer
          description: Alerts the reset would keep because a claim holds their pair.
        cancelled_check_count:
          type: integer
          description: Unfinished checks the reset would cancel.
        other_topic_alert_count:
          type: integer
          description: Deleted alerts that belong to topics outside a topic scope.
        exceeds_limit:
          type: boolean
        maximum_pairs:
          type: integer
      required:
        - fingerprint
        - invoice_count
        - pair_count
        - deletable_alert_count
        - kept_alert_count
        - cancelled_check_count
        - other_topic_alert_count
        - exceeds_limit
        - maximum_pairs
    CheckReset:
      type: object
      properties:
        deleted_alert_count:
          type: integer
          minimum: 0
        kept_alert_count:
          type: integer
          minimum: 0
          description: Alerts kept because a claim holds their invoice and agreement pair.
        cancelled_check_count:
          type: integer
          minimum: 0
          description: Unfinished checks that were cancelled.
      required:
        - deleted_alert_count
        - kept_alert_count
        - cancelled_check_count
    Error_validation_error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - validation_error
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_invalid_token:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - invalid_token
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_forbidden_token_disabled_organization_required_insufficient_role_mfa_required:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - forbidden
                - token_disabled
                - organization_required
                - insufficient_role
                - mfa_required
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_not_found:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - not_found
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_conflict:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - conflict
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_rate_limit_exceeded:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - rate_limit_exceeded
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_internal_error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - internal_error
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
    Error_service_unavailable:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - service_unavailable
            message:
              type: string
            request_id:
              type: string
            description:
              type: string
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  field:
                    type: string
                  message:
                    type: string
                required:
                  - code
                  - field
                  - message
              maxItems: 20
            workflow_run_id:
              type: string
              format: uuid
            import_id:
              type: string
              format: uuid
            existing_party:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - supplier
                    - recipient
                id:
                  type: string
                  format: uuid
              required:
                - type
                - id
          required:
            - code
            - message
            - request_id
      required:
        - error
  securitySchemes:
    ApiKeyBearer:
      type: http
      scheme: bearer
      description: >-
        Personal API key sent as a bearer token, together with
        X-Organization-Id. The key must have at least the access level the
        endpoint requires (read, write or admin).

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.