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

# Get mandate history

> Accepted cases (Aktenzeichen).

Main-case-centric: the list returns **main cases only**.
Sub-cases are reachable through the main case detail representation and
direct detail/subresource URLs, not a flat list expansion. Tenant-scoped by
the authenticated company.

Sub-resources of one mandate:

  * payments — the reported, non-ignored payments
  * documents — claim-document metadata and a proxy-stream download
  * history — published client activity, related resources, and attachments.
    A main case includes its subcases; a subcase includes only itself.

The sub-resource operations resolve the mandate **including sub-cases** —
unlike the list, which hides sub-cases — so an individually-addressable
sub-case's own track stays reachable. These public mandate operations are
reads.



## OpenAPI

````yaml /api-docs/case-management-api/openapi.json get /v2/mandates/{id}/history/
openapi: 3.0.3
info:
  description: >-
    Submit orders and manage their complete lifecycle through the current API at
    the `/v2/` HTTP path.
  title: paywise Case Management API
  version: current
servers:
  - description: Production environment
    url: https://api.paywise.de
  - description: Sandbox environment
    url: https://api-sandbox.paywise.de
security: []
tags:
  - description: Submit orders and manage them until acceptance.
    name: Orders
  - description: Stable claim resources and their current relationships.
    name: Claims
  - description: 'Accepted cases: state, published history and documents.'
    name: Mandates
  - description: Debtor master data reused across orders.
    name: Debtors
  - description: Payments reported by you and booked by paywise.
    name: Payments
  - description: Files attached to claims and other resources.
    name: Documents
  - description: Collective statements (Sammelabrechnungen).
    name: Statements
  - description: Per-case statements (Aktenabrechnungen).
    name: Single mandate statements
  - description: Webhook endpoints and their signing secrets.
    name: Webhooks
  - description: Delivery log and redelivery of webhook events.
    name: Webhook deliveries
  - description: Ordered feed of the events webhooks deliver.
    name: Events
  - description: Reference catalog of legal forms.
    name: Legal forms
  - description: The authenticated credential and its context.
    name: Info
  - description: Rate-limit headroom of the credential.
    name: Usage
  - description: Availability of the API.
    name: Health
externalDocs:
  url: https://docs.paywise.de/api-docs/case-management-api/introduction
paths:
  /v2/mandates/{id}/history/:
    get:
      tags:
        - Mandates
      summary: Get mandate history
      description: >-
        Accepted cases (Aktenzeichen).


        Main-case-centric: the list returns **main cases only**.

        Sub-cases are reachable through the main case detail representation and

        direct detail/subresource URLs, not a flat list expansion. Tenant-scoped
        by

        the authenticated company.


        Sub-resources of one mandate:

          * payments — the reported, non-ignored payments
          * documents — claim-document metadata and a proxy-stream download
          * history — published client activity, related resources, and attachments.
            A main case includes its subcases; a subcase includes only itself.

        The sub-resource operations resolve the mandate **including sub-cases**
        —

        unlike the list, which hides sub-cases — so an individually-addressable

        sub-case's own track stays reachable. These public mandate operations
        are

        reads.
      operationId: get-mandate-history
      parameters:
        - description: >-
            Required when a Partner key calls the Case Management API; rejected
            for direct Case keys. Contains the entitled paywise company UUID.
          in: header
          name: X-On-Behalf-Of-Company
          schema:
            format: uuid
            type: string
        - description: >-
            Opaque continuation cursor for incremental synchronization, taken
            from the `next` URL of a previous page. Only valid together with
            `updated_since`: with `updated_since` set the list is ordered by
            change time and then id and pages by this cursor instead of
            `offset`, so a row that changes while you page is returned again
            later instead of pushing another row out of the result. Rows changed
            less than 60 seconds ago are held back until they are settled; use
            the largest `updated_at` you received as the next `updated_since`.
          in: query
          name: cursor
          schema:
            type: string
        - description: Embed the typed related resource body.
          in: query
          name: expand
          schema:
            enum:
              - history.related_resources
            type: string
        - description: UUID of the accepted case in this request.
          in: path
          name: id
          required: true
          schema:
            format: uuid
            type: string
        - description: Number of results to return (maximum 100).
          in: query
          name: limit
          schema:
            default: 10
            maximum: 100
            minimum: 1
            type: integer
        - description: Zero-based result offset.
          in: query
          name: offset
          schema:
            default: 0
            minimum: 0
            type: integer
        - description: >-
            Return entries changed at or after this timezone-aware RFC 3339
            timestamp (inclusive). With it set, results are ordered by change
            time and then id instead of newest first, page by `cursor` instead
            of `offset`, and entries changed less than a minute ago are held
            back.
          in: query
          name: updated_since
          schema:
            format: date-time
            type: string
      responses:
        '200':
          content:
            application/json:
              examples:
                mandate-history:
                  value:
                    count: 1
                    next: null
                    previous: null
                    results:
                      - advance_type: null
                        attachments: []
                        description: Please confirm the outstanding amount.
                        id: b0000000-0000-4000-8000-000000000001
                        is_advance_request: false
                        occurred_at: '2026-07-18T11:05:00Z'
                        related_resources:
                          - body:
                              allowed_answer_types: yes-no-freetext-on-no
                              answer: null
                              answered: false
                              answered_at: null
                              created_at: '2026-07-18T11:05:00Z'
                              description: We need your confirmation before continuing.
                              href: >-
                                https://api.paywise.de/v2/mandates/50000000-0000-4000-8000-000000000001/requests-to-client/80000000-0000-4000-8000-000000000001/
                              id: 80000000-0000-4000-8000-000000000001
                              mandate:
                                href: >-
                                  https://api.paywise.de/v2/mandates/50000000-0000-4000-8000-000000000001/
                                id: 50000000-0000-4000-8000-000000000001
                                reference_number: PW-2026-000123
                              question_attachments: []
                              title: Please confirm the outstanding amount
                              updated_at: '2026-07-18T11:05:00Z'
                            id: 80000000-0000-4000-8000-000000000001
                            type: request_to_client
                            url: >-
                              https://api.paywise.de/v2/mandates/50000000-0000-4000-8000-000000000001/requests-to-client/80000000-0000-4000-8000-000000000001/
                        source_mandate:
                          id: 50000000-0000-4000-8000-000000000001
                          reference_number: PW-2026-000123
                          relation: main_case
                        state:
                          legal_stage:
                            code: extrajudicial
                            label: Außergerichtlich
                            label_key: mandate.state.legal_stage.extrajudicial
                          payment:
                            code: unpaid
                            label: Unbezahlt
                            label_key: mandate.state.payment.unpaid
                          processing:
                            code: in_progress
                            label: Laufend
                            label_key: mandate.state.processing.in_progress
                        text: Please confirm the outstanding amount.
                        title: Additional information required
                        type: status_update
                        updated_at: '2026-07-18T11:05:00Z'
              schema:
                $ref: '#/components/schemas/MandateHistoryPage'
          description: ''
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '400':
          content:
            application/json:
              examples:
                validation-error:
                  value:
                    code: validation_error
                    detail: The request contains invalid data.
                    errors:
                      - code: invalid
                        field: claims[0].due_date
                        message: Due date must not precede the document date.
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '401':
          content:
            application/json:
              examples:
                authentication-error:
                  value:
                    code: not_authenticated
                    detail: Authentication credentials were not provided.
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '404':
          content:
            application/json:
              examples:
                not-found-error:
                  value:
                    code: not_found
                    detail: The requested resource was not found.
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            Retry-After:
              description: Integer seconds to wait before retrying a throttled request.
              schema:
                minimum: 1
                type: integer
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Standard error response.
          headers:
            Cache-Control:
              description: >-
                Cacheability directive. Authenticated responses use `private,
                no-store`; the legal-form catalog may use `private,
                max-age=86400`.
              schema:
                type: string
            X-Paywise-Environment:
              description: Environment that produced the response.
              schema:
                enum:
                  - production
                  - sandbox
                type: string
            X-Paywise-Request-Id:
              description: >-
                Fresh server-assigned correlation id for this response.
                Caller-provided request ids are ignored.
              schema:
                format: uuid
                type: string
      security:
        - caseBearerAuth: []
        - partnerBearerAuth: []
components:
  schemas:
    MandateHistoryPage:
      description: Limit/offset page of results.
      properties:
        count:
          description: Total number of matching resources.
          readOnly: true
          type: integer
        next:
          description: >-
            URL for the next page, or null when this is the last page. With
            `updated_since` it carries an opaque `cursor`.
          format: uri
          nullable: true
          readOnly: true
          type: string
        previous:
          description: >-
            URL for the previous page, or null when this is the first page.
            Always null with `updated_since`.
          format: uri
          nullable: true
          readOnly: true
          type: string
        results:
          description: History entries returned for the requested page.
          items:
            $ref: '#/components/schemas/MandateHistory'
          readOnly: true
          type: array
      required:
        - count
        - next
        - previous
        - results
      type: object
    Error:
      properties:
        code:
          description: Machine-readable error category.
          type: string
        detail:
          description: Short human-readable summary of the error.
          type: string
        errors:
          description: Field-level validation errors, when applicable.
          items:
            $ref: '#/components/schemas/ErrorItem'
          type: array
      required:
        - detail
        - code
      type: object
    MandateHistory:
      description: One published status and the resources it makes available to the client.
      properties:
        advance_type:
          description: Category of the requested advance, when applicable.
          nullable: true
          readOnly: true
          type: string
        attachments:
          description: Files explicitly published with this entry.
          items:
            $ref: '#/components/schemas/HistoryAttachment'
          readOnly: true
          type: array
        description:
          description: Plain-text explanation of the published event.
          nullable: true
          readOnly: true
          type: string
        id:
          description: Stable identifier of this history entry.
          format: uuid
          readOnly: true
          type: string
        is_advance_request:
          description: Whether this update requests an advance payment.
          readOnly: true
          type: boolean
        occurred_at:
          description: Time at which the published event occurred.
          format: date-time
          readOnly: true
          type: string
        related_resources:
          description: >-
            Resources published through this entry. Multiple resources may be
            linked; bodies are included only when explicitly expanded and
            authorized.
          items:
            $ref: '#/components/schemas/MandateHistoryRelatedResource'
          readOnly: true
          type: array
        source_mandate:
          allOf:
            - $ref: '#/components/schemas/HistorySourceMandate'
          description: Main case or subcase that produced the entry.
          readOnly: true
        state:
          allOf:
            - $ref: '#/components/schemas/MandateState'
          description: >-
            Workflow values recorded on this status. Blank dimensions were not
            recorded; this is not a complete state snapshot.
          readOnly: true
        text:
          description: Compatibility alias of the event description.
          nullable: true
          readOnly: true
          type: string
        title:
          description: Short title of the published event.
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/MandateHistoryTypeEnum'
          description: Business category of the history entry.
          readOnly: true
        updated_at:
          description: >-
            Latest change to this entry or its published related content; use
            for incremental synchronization.
          format: date-time
          readOnly: true
          type: string
      required:
        - advance_type
        - attachments
        - description
        - id
        - is_advance_request
        - occurred_at
        - related_resources
        - source_mandate
        - state
        - text
        - title
        - type
        - updated_at
      type: object
    ErrorItem:
      properties:
        code:
          description: Machine-readable field error code.
          type: string
        field:
          description: >-
            Path to the field that caused the error, using dots for objects and
            brackets for list indexes, for example `claims[0].amount`; null for
            an error without a field path.
          nullable: true
          type: string
        message:
          description: Human-readable explanation of the field error.
          type: string
      required:
        - field
        - code
        - message
      type: object
    HistoryAttachment:
      properties:
        download_url:
          description: >-
            Authenticated history attachment download URL, or null when no file
            is available.
          format: uri
          nullable: true
          readOnly: true
          type: string
        filename:
          description: Original filename of the published attachment.
          readOnly: true
          type: string
        id:
          description: Stable identifier of the published file.
          format: uuid
          readOnly: true
          type: string
        mime_type:
          description: Media type of the attachment.
          readOnly: true
          type: string
      required:
        - download_url
        - filename
        - id
        - mime_type
      type: object
    MandateHistoryRelatedResource:
      discriminator:
        mapping:
          email: '#/components/schemas/EmailHistoryRelatedResource'
          message: '#/components/schemas/MessageHistoryRelatedResource'
          request_to_client: '#/components/schemas/RequestToClientHistoryRelatedResource'
          single_mandate_statement: '#/components/schemas/StatementHistoryRelatedResource'
        propertyName: type
      oneOf:
        - $ref: '#/components/schemas/RequestToClientHistoryRelatedResource'
        - $ref: '#/components/schemas/MessageHistoryRelatedResource'
        - $ref: '#/components/schemas/EmailHistoryRelatedResource'
        - $ref: '#/components/schemas/StatementHistoryRelatedResource'
    HistorySourceMandate:
      properties:
        id:
          description: Identifier of the case that produced the entry.
          format: uuid
          readOnly: true
          type: string
        reference_number:
          description: paywise reference number of the source case.
          readOnly: true
          type: string
        relation:
          allOf:
            - $ref: '#/components/schemas/RelationEnum'
          description: |-
            Main-case or subcase attribution.

            * `main_case` - main_case
            * `subcase` - subcase
          readOnly: true
      required:
        - id
        - reference_number
        - relation
      type: object
    MandateState:
      properties:
        legal_stage:
          allOf:
            - $ref: '#/components/schemas/MandateStateValue'
          description: Current legal collection stage.
          readOnly: true
        payment:
          allOf:
            - $ref: '#/components/schemas/MandateStateValue'
          description: Current payment or settlement state.
          readOnly: true
        processing:
          allOf:
            - $ref: '#/components/schemas/MandateStateValue'
          description: Current operational processing state.
          readOnly: true
      required:
        - legal_stage
        - payment
        - processing
      type: object
    MandateHistoryTypeEnum:
      enum:
        - status_update
      type: string
    EmailHistoryRelatedResource:
      properties:
        body:
          allOf:
            - $ref: '#/components/schemas/HistoryEmailMetadata'
          description: >-
            Expanded email metadata. Text and attachments are read through
            `url`.
        id:
          description: Identifier of the related resource.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/EmailHistoryRelatedResourceTypeEnum'
          description: |-
            Related resource kind.

            * `email` - email
          readOnly: true
        url:
          description: >-
            Authenticated URL of the correspondence item that carries this
            email's text, PDF and attachments (`case:correspondence:read`); null
            when the email has no stored copy.
          format: uri
          nullable: true
          readOnly: true
          type: string
      required:
        - id
        - type
        - url
      title: Email
      type: object
    MessageHistoryRelatedResource:
      properties:
        body:
          allOf:
            - $ref: '#/components/schemas/MessageRead'
          description: Message, included when explicitly expanded and authorized.
        id:
          description: Identifier of the related resource.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/MessageHistoryRelatedResourceTypeEnum'
          description: |-
            Related resource kind.

            * `message` - message
          readOnly: true
        url:
          description: Authenticated API URL of the related resource.
          format: uri
          readOnly: true
          type: string
      required:
        - id
        - type
        - url
      title: Message
      type: object
    RequestToClientHistoryRelatedResource:
      properties:
        body:
          allOf:
            - $ref: '#/components/schemas/RequestToClientRead'
          description: >-
            Expanded client request, included only with
            `expand=history.related_resources` and the
            `case:requests_to_client:read` scope. On mandate detail, also set
            `history=true`.
        id:
          description: Identifier of the related resource.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: >-
                #/components/schemas/RequestToClientHistoryRelatedResourceTypeEnum
          description: |-
            Related resource kind.

            * `request_to_client` - request_to_client
          readOnly: true
        url:
          description: Authenticated API URL of the related resource.
          format: uri
          readOnly: true
          type: string
      required:
        - id
        - type
        - url
      title: Client request
      type: object
    StatementHistoryRelatedResource:
      properties:
        body:
          allOf:
            - $ref: '#/components/schemas/SingleMandateStatementRead'
          description: Case statement, included when explicitly expanded and authorized.
        id:
          description: Identifier of the related resource.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/StatementHistoryRelatedResourceTypeEnum'
          description: |-
            Related resource kind.

            * `single_mandate_statement` - single_mandate_statement
          readOnly: true
        url:
          description: Authenticated API URL of the related resource.
          format: uri
          readOnly: true
          type: string
      required:
        - id
        - type
        - url
      title: Case statement
      type: object
    RelationEnum:
      description: |-
        * `main_case` - main_case
        * `subcase` - subcase
      enum:
        - main_case
        - subcase
      type: string
    MandateStateValue:
      description: Stable machine code plus an i18n-ready label key and current label.
      properties:
        code:
          description: >-
            Stable machine-readable state code; an empty string when that state
            has not been set.
          readOnly: true
          type: string
        label:
          description: >-
            Current human-readable state label; an empty string when its code is
            unset.
          readOnly: true
          type: string
        label_key:
          description: >-
            Stable translation key for the state; an empty string when its code
            is unset.
          readOnly: true
          type: string
      required:
        - code
        - label
        - label_key
      type: object
    HistoryEmailMetadata:
      properties:
        correspondence_url:
          description: >-
            Authenticated URL of the full correspondence item (text, PDF,
            attachments); null when the email has no stored copy.
          format: uri
          nullable: true
          readOnly: true
          type: string
        date:
          description: Time the email record was created.
          format: date-time
          readOnly: true
          type: string
        direction:
          allOf:
            - $ref: '#/components/schemas/DirectionEnum'
          description: Whether paywise received or sent the email.
          readOnly: true
        subject:
          description: Subject of the email published through this history entry.
          nullable: true
          readOnly: true
          type: string
      required:
        - correspondence_url
        - date
        - direction
        - subject
      type: object
    EmailHistoryRelatedResourceTypeEnum:
      description: '* `email` - email'
      enum:
        - email
      type: string
    MessageRead:
      description: Resource representation with a native UUID `id`.
      properties:
        author:
          allOf:
            - $ref: '#/components/schemas/MessageAuthor'
          description: Channel through which the message was authored.
          readOnly: true
        body:
          description: Message content exchanged with paywise.
          nullable: true
          readOnly: true
          type: string
        created_at:
          description: Time at which the message was created.
          format: date-time
          readOnly: true
          type: string
        documents:
          description: Documents attached to the message.
          items:
            $ref: '#/components/schemas/DocumentRead'
          readOnly: true
          type: array
        editable:
          description: >-
            Whether this message can be edited through the API. True only for a
            client message created through current Case Management API for the
            calling company while it is under review and no review task has
            started.
          readOnly: true
          type: boolean
        href:
          description: API URL of this message.
          format: uri
          readOnly: true
          type: string
        id:
          description: Stable identifier for this resource.
          format: uuid
          readOnly: true
          type: string
        parent:
          allOf:
            - $ref: '#/components/schemas/MessageParent'
          description: Order or accepted case to which the message belongs.
          readOnly: true
        response_to:
          description: Message to which this message responds, when applicable.
          format: uuid
          nullable: true
          readOnly: true
          type: string
        sender:
          allOf:
            - $ref: '#/components/schemas/SenderEnum'
          description: Party that sent the message.
          readOnly: true
        state:
          allOf:
            - $ref: '#/components/schemas/StateEnum'
          description: >-
            Review/publication state: `under_review` for a client message
            awaiting review, `handled` after handling, or `published` for a
            published message. Check `editable` before offering edits.
          readOnly: true
        title:
          description: Short subject of the message.
          nullable: true
          readOnly: true
          type: string
        updated_at:
          description: Time at which the message was last updated.
          format: date-time
          readOnly: true
          type: string
      required:
        - author
        - body
        - created_at
        - documents
        - editable
        - href
        - id
        - parent
        - response_to
        - sender
        - state
        - title
        - updated_at
      type: object
    MessageHistoryRelatedResourceTypeEnum:
      description: '* `message` - message'
      enum:
        - message
      type: string
    RequestToClientRead:
      description: Published clarification request with its optional answer.
      properties:
        allowed_answer_types:
          allOf:
            - $ref: '#/components/schemas/AllowedAnswerTypesEnum'
          description: >-
            Answer format accepted by the answer endpoint. Choice formats use
            `text: yes` or `text: no`; `yes-no-dontknow` also permits
            `dontknow`. Formats ending in `freetext-on-no` require
            `additional_comment` for `no`; `yes-with-date-no-freetext-on-no`
            requires `booking_date` for `yes`. `freetext` requires text;
            `fileupload` accepts text, documents, or both.
          readOnly: true
        answer:
          allOf:
            - $ref: '#/components/schemas/AnswerRead'
          description: Submitted answer, or null while unanswered.
          nullable: true
          readOnly: true
        answered:
          description: Whether an answer has already been submitted.
          readOnly: true
          type: boolean
        answered_at:
          description: Time at which the answer was submitted, when answered.
          format: date-time
          nullable: true
          readOnly: true
          type: string
        created_at:
          description: Time at which the request was created.
          format: date-time
          readOnly: true
          type: string
        description:
          description: Question or explanation describing what paywise needs.
          nullable: true
          readOnly: true
          type: string
        href:
          description: API URL of this client request.
          format: uri
          readOnly: true
          type: string
        id:
          description: Stable identifier of this client request.
          format: uuid
          readOnly: true
          type: string
        mandate:
          allOf:
            - $ref: '#/components/schemas/RequestToClientMandateReference'
          description: Accepted case for which paywise needs information.
          readOnly: true
        question_attachments:
          description: Files paywise attached to the question.
          items:
            properties:
              download_url:
                description: >-
                  Authenticated API URL for downloading the question attachment;
                  null when no downloadable file is available.
                format: uri
                nullable: true
                type: string
              filename:
                description: Original filename of the attachment.
                nullable: true
                type: string
              id:
                description: Stable identifier of the attachment.
                format: uuid
                type: string
              mime_type:
                description: Media type of the attachment.
                nullable: true
                type: string
            type: object
          readOnly: true
          type: array
        title:
          description: Short subject of the requested information.
          readOnly: true
          type: string
        updated_at:
          description: Time at which the request was last updated.
          format: date-time
          readOnly: true
          type: string
      required:
        - allowed_answer_types
        - answer
        - answered
        - answered_at
        - created_at
        - description
        - href
        - id
        - mandate
        - question_attachments
        - title
        - updated_at
      type: object
    RequestToClientHistoryRelatedResourceTypeEnum:
      description: '* `request_to_client` - request_to_client'
      enum:
        - request_to_client
      type: string
    SingleMandateStatementRead:
      properties:
        booking_date:
          description: Date on which the case statement was booked.
          format: date
          readOnly: true
          type: string
        cancelled_at:
          description: Time at which the case statement was cancelled.
          format: date-time
          nullable: true
          readOnly: true
          type: string
        clearing_no:
          description: Clearing number of the case statement.
          readOnly: true
          type: string
        comment:
          description: Additional notes supplied with the case statement.
          nullable: true
          readOnly: true
          type: string
        created_at:
          description: Time at which the case statement was created.
          format: date-time
          readOnly: true
          type: string
        file:
          allOf:
            - $ref: '#/components/schemas/StatementFile'
          description: Downloadable statement document, when available.
          nullable: true
          readOnly: true
        financials:
          allOf:
            - $ref: '#/components/schemas/SingleMandateStatementFinancials'
          description: Principal claims, payment allocation, and settlement balance.
          readOnly: true
        id:
          description: Stable identifier of this case statement.
          format: uuid
          readOnly: true
          type: string
        invoice_no:
          description: Invoice number, when this settlement produces an invoice.
          nullable: true
          readOnly: true
          type: string
        mandate:
          allOf:
            - $ref: '#/components/schemas/SingleMandateStatementMandateReference'
          description: Accepted case settled by this statement, when still linked.
          nullable: true
          readOnly: true
        payout_method:
          allOf:
            - $ref: '#/components/schemas/PayoutMethodEnum'
          description: |-
            Whether the balance is settled by transfer or direct debit.

            * `transfer` - Überweisung
            * `direct_debit` - Lastschrift
          nullable: true
          readOnly: true
        period_end:
          description: End of the settled period.
          format: date
          readOnly: true
          type: string
        period_start:
          description: Start of the settled period, or null for the full case history.
          format: date
          nullable: true
          readOnly: true
          type: string
        pre_tax_deductible:
          description: Whether you may deduct input VAT for this settlement.
          readOnly: true
          type: boolean
        reference_number:
          description: paywise case-file reference number of the settled case.
          readOnly: true
          type: string
        statement_type:
          allOf:
            - $ref: '#/components/schemas/StatementTypeEnum'
          description: >-
            Kind of interim, final, expense, or monitoring settlement.


            * `interim` - Zwischenabrechnung

            * `final` - Endabrechnung

            * `expenses_invoice` - Auslagenrechnung

            * `transition_to_longtime_monitoring` - Übergabe
            Überwachungsverfahren

            * `negative_closing` - Negativabschluss
          readOnly: true
        status:
          allOf:
            - $ref: '#/components/schemas/CaseStatementStatusEnum'
          description: Whether the case statement is published or cancelled.
          readOnly: true
        updated_at:
          description: Time at which the case statement was last updated.
          format: date-time
          readOnly: true
          type: string
        your_reference:
          description: Your customer number for the debtor on the settled case.
          nullable: true
          readOnly: true
          type: string
      required:
        - booking_date
        - cancelled_at
        - clearing_no
        - comment
        - created_at
        - file
        - financials
        - id
        - invoice_no
        - mandate
        - payout_method
        - period_end
        - period_start
        - pre_tax_deductible
        - reference_number
        - statement_type
        - status
        - updated_at
        - your_reference
      type: object
    StatementHistoryRelatedResourceTypeEnum:
      description: '* `single_mandate_statement` - single_mandate_statement'
      enum:
        - single_mandate_statement
      type: string
    DirectionEnum:
      enum:
        - inbound
        - outbound
      type: string
    MessageAuthor:
      properties:
        type:
          allOf:
            - $ref: '#/components/schemas/MessageAuthorTypeEnum'
          description: >-
            Authorship channel: `api` for a client message created through
            current Case Management API, `user` for another client-authored
            message, or `paywise` for a message sent by paywise.
          readOnly: true
      required:
        - type
      type: object
    DocumentRead:
      description: Resource representation with a native UUID `id`.
      properties:
        created_at:
          description: Time at which the document was submitted.
          format: date-time
          readOnly: true
          type: string
        download_url:
          description: >-
            Authenticated API URL for downloading the document; null while its
            status is not `ready`.
          format: uri
          nullable: true
          readOnly: true
          type: string
        failure_reason:
          allOf:
            - $ref: '#/components/schemas/DocumentFailureReasonEnum'
          description: >-
            Why processing failed when status is `failed`; `null` otherwise.
            `page_limit_exceeded`: PDF above the 100-page ceiling; `encrypted`:
            password-protected PDF; `corrupt`: bytes could not be parsed;
            `unsupported`: content type not accepted; `processing_failed`: any
            other processing error.
          nullable: true
          readOnly: true
        filename:
          description: Original filename shown to users.
          readOnly: true
          type: string
        id:
          description: Stable identifier for this resource.
          format: uuid
          readOnly: true
          type: string
        mime_type:
          description: Detected media type of the document.
          nullable: true
          readOnly: true
          type: string
        parent:
          allOf:
            - $ref: '#/components/schemas/DocumentParent'
          description: Resource that owns the document.
          readOnly: true
        status:
          allOf:
            - $ref: '#/components/schemas/CaseDocumentStatusEnum'
          description: >-
            Document availability: `pending` while scanning or processing is
            incomplete; `ready` when processing permits download; `failed` when
            scanning or processing failed; `rejected` when the malware check
            rejected the file.
          readOnly: true
        type:
          allOf:
            - $ref: '#/components/schemas/CaseDocumentTypeEnum'
          description: Business purpose of the document.
          readOnly: true
        updated_at:
          description: Time at which document processing last changed.
          format: date-time
          readOnly: true
          type: string
      required:
        - created_at
        - download_url
        - failure_reason
        - filename
        - id
        - mime_type
        - parent
        - status
        - type
        - updated_at
      type: object
    MessageParent:
      properties:
        id:
          description: Identifier of the order or accepted case owning the message.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/MessageParentTypeEnum'
          description: >-
            Whether the message belongs to an order (`order`) or an accepted
            case (`mandate`).
          readOnly: true
      required:
        - id
        - type
      type: object
    SenderEnum:
      enum:
        - client
        - paywise
      type: string
    StateEnum:
      enum:
        - under_review
        - handled
        - published
      type: string
    AllowedAnswerTypesEnum:
      description: |-
        * `fileupload` - fileupload
        * `freetext` - freetext
        * `yes-no` - yes-no
        * `yes-no-dontknow` - yes-no-dontknow
        * `yes-no-freetext-on-no` - yes-no-freetext-on-no
        * `yes-with-date-no-freetext-on-no` - yes-with-date-no-freetext-on-no
      enum:
        - fileupload
        - freetext
        - yes-no
        - yes-no-dontknow
        - yes-no-freetext-on-no
        - yes-with-date-no-freetext-on-no
      type: string
    AnswerRead:
      properties:
        additional_comment:
          description: Additional context supplied with the answer.
          nullable: true
          readOnly: true
          type: string
        booking_date:
          description: Relevant booking date requested by the question, when applicable.
          format: date
          nullable: true
          readOnly: true
          type: string
        created_at:
          description: Time at which the answer was submitted.
          format: date-time
          readOnly: true
          type: string
        documents:
          description: Documents supplied with the answer.
          items:
            $ref: '#/components/schemas/DocumentRead'
          readOnly: true
          type: array
        id:
          description: Stable identifier of this answer.
          format: uuid
          readOnly: true
          type: string
        text:
          description: >-
            Selected choice (`yes`, `no`, or `dontknow`) or free-text answer.
            Empty for an API answer supplied with documents only; legacy answers
            may use null.
          nullable: true
          readOnly: true
          type: string
        updated_at:
          description: Time at which the answer was last updated.
          format: date-time
          readOnly: true
          type: string
      required:
        - additional_comment
        - booking_date
        - created_at
        - documents
        - id
        - text
        - updated_at
      type: object
    RequestToClientMandateReference:
      properties:
        href:
          description: API URL of the accepted case.
          format: uri
          nullable: true
          type: string
        id:
          description: Identifier of the accepted case.
          format: uuid
          type: string
        reference_number:
          description: paywise case-file reference number.
          nullable: true
          type: string
      type: object
    StatementFile:
      properties:
        download_url:
          description: Authenticated URL for downloading this file.
          format: uri
          readOnly: true
          type: string
        filename:
          description: Descriptive filename for this download.
          readOnly: true
          type: string
        media_type:
          description: Media type of this download.
          readOnly: true
          type: string
      required:
        - download_url
        - filename
        - media_type
      type: object
    SingleMandateStatementFinancials:
      properties:
        cost_burden:
          allOf:
            - $ref: '#/components/schemas/SingleMandateStatementCostBurden'
          description: What you owe paywise on this case, when applicable.
          nullable: true
          readOnly: true
        open_principal_claim:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Principal claim still open after this settlement.
          nullable: true
          readOnly: true
        principal_claims:
          description: Invoices settled by this statement.
          items:
            $ref: '#/components/schemas/SingleMandateStatementPrincipalClaim'
          readOnly: true
          type: array
        principal_claims_total:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Total of all principal claims settled by this statement.
          nullable: true
          readOnly: true
        total_balance:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: 'Settlement balance: positive pays you, negative is owed by you.'
          nullable: true
          readOnly: true
        vat_entries:
          description: Payments and their allocation grouped by VAT rate.
          items:
            $ref: '#/components/schemas/SingleMandateStatementVATEntry'
          readOnly: true
          type: array
      required:
        - cost_burden
        - open_principal_claim
        - principal_claims
        - principal_claims_total
        - total_balance
        - vat_entries
      type: object
    SingleMandateStatementMandateReference:
      properties:
        id:
          description: Identifier of the accepted case settled by this statement.
          format: uuid
          readOnly: true
          type: string
        reference_number:
          description: paywise case-file reference number.
          readOnly: true
          type: string
      required:
        - id
        - reference_number
      type: object
    PayoutMethodEnum:
      description: |-
        * `transfer` - Überweisung
        * `direct_debit` - Lastschrift
      enum:
        - transfer
        - direct_debit
      type: string
    StatementTypeEnum:
      description: |-
        * `interim` - Zwischenabrechnung
        * `final` - Endabrechnung
        * `expenses_invoice` - Auslagenrechnung
        * `transition_to_longtime_monitoring` - Übergabe Überwachungsverfahren
        * `negative_closing` - Negativabschluss
      enum:
        - interim
        - final
        - expenses_invoice
        - transition_to_longtime_monitoring
        - negative_closing
      type: string
    CaseStatementStatusEnum:
      enum:
        - published
        - cancelled
      type: string
    MessageAuthorTypeEnum:
      description: |-
        * `api` - api
        * `user` - user
        * `paywise` - paywise
      enum:
        - api
        - user
        - paywise
      type: string
    DocumentFailureReasonEnum:
      enum:
        - page_limit_exceeded
        - encrypted
        - corrupt
        - unsupported
        - processing_failed
      type: string
    DocumentParent:
      properties:
        id:
          description: Identifier of the resource that owns the document.
          format: uuid
          readOnly: true
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/DocumentParentTypeEnum'
          description: |-
            Kind of resource that owns the document.

            * `claim` - claim
            * `message` - message
            * `request_to_client_answer` - request_to_client_answer
            * `rental_agreement` - rental_agreement
            * `enforceable_title` - enforceable_title
          readOnly: true
      required:
        - id
        - type
      type: object
    CaseDocumentStatusEnum:
      enum:
        - pending
        - ready
        - failed
        - rejected
      type: string
    CaseDocumentTypeEnum:
      description: |-
        * `bank_statement` - bank_statement
        * `claim_statement` - claim_statement
        * `correspondence` - correspondence
        * `enforceable_title` - enforceable_title
        * `invoice` - invoice
        * `other` - other
        * `payment_proof` - payment_proof
        * `reminder` - reminder
        * `rental_agreement` - rental_agreement
      enum:
        - bank_statement
        - claim_statement
        - correspondence
        - enforceable_title
        - invoice
        - other
        - payment_proof
        - reminder
        - rental_agreement
      type: string
    MessageParentTypeEnum:
      description: |-
        * `order` - order
        * `mandate` - mandate
      enum:
        - order
        - mandate
      type: string
    SingleMandateStatementCostBurden:
      description: 'Kostenbelastung: what the client owes us on this case.'
      properties:
        fee:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Collection fee charged to you.
          nullable: true
          readOnly: true
        fee_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: VAT on the collection fee charged to you.
          nullable: true
          readOnly: true
        items:
          description: Itemized positions making up the cost burden.
          items:
            $ref: '#/components/schemas/SingleMandateStatementCostBurdenItem'
          readOnly: true
          type: array
        tax_free_expenses:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Tax-free expenses charged to you.
          nullable: true
          readOnly: true
        taxable_expenses:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Taxable expenses charged to you.
          nullable: true
          readOnly: true
        taxable_expenses_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: VAT on taxable expenses charged to you.
          nullable: true
          readOnly: true
        total_amount:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Total gross amount of the cost burden.
          nullable: true
          readOnly: true
        total_net:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Total net amount of the cost burden.
          nullable: true
          readOnly: true
        total_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Total VAT included in the cost burden.
          nullable: true
          readOnly: true
        vat_rate:
          description: >-
            VAT rate as a decimal fraction, for example 0.19 for 19%. Exact
            decimal string; parse it with a decimal type, never a binary float.
          pattern: ^-?[0-9]{1,3}(?:\.[0-9]{1,2})?$
          readOnly: true
          type: string
      required:
        - fee
        - fee_vat
        - items
        - tax_free_expenses
        - taxable_expenses
        - taxable_expenses_vat
        - total_amount
        - total_net
        - total_vat
        - vat_rate
      type: object
    StatementAmount:
      properties:
        currency:
          description: Currency of the amount.
          readOnly: true
          type: string
        value:
          description: >-
            Monetary value expressed with two decimal places. Exact decimal
            string; parse it with a decimal type, never a binary float.
          pattern: ^-?[0-9]{1,14}(?:\.[0-9]{1,2})?$
          readOnly: true
          type: string
      required:
        - currency
        - value
      type: object
    SingleMandateStatementPrincipalClaim:
      description: One invoice (Hauptforderung) settled by this Aktenabrechnung.
      properties:
        amount:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Invoiced amount of the principal claim.
          nullable: true
          readOnly: true
        voucher_date:
          description: Date of the invoice or voucher.
          format: date
          nullable: true
          readOnly: true
          type: string
        voucher_no:
          description: Your invoice or voucher number for the settled claim.
          nullable: true
          readOnly: true
          type: string
      required:
        - amount
        - voucher_date
        - voucher_no
      type: object
    SingleMandateStatementVATEntry:
      description: |-
        Payments and their allocation for one VAT rate.

        `vat_rate` is a decimal fraction (`0.19`) — the Aktenabrechnung
        convention, preserved verbatim. It deliberately differs from the percent
        representation on `/v2/statements/`: that resource inherited its shape
        from the Sammelabrechnung model, this one from the Aktenabrechnung.
      properties:
        allocation_to_client_costs:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to your costs.
          nullable: true
          readOnly: true
        allocation_to_client_expenses:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to your expenses.
          nullable: true
          readOnly: true
        allocation_to_default_interest:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to default interest.
          nullable: true
          readOnly: true
        allocation_to_fee:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to the collection fee.
          nullable: true
          readOnly: true
        allocation_to_fee_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to VAT on the collection fee.
          nullable: true
          readOnly: true
        allocation_to_main_claim:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to the principal claim.
          nullable: true
          readOnly: true
        allocation_to_overpayment:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to an overpayment.
          nullable: true
          readOnly: true
        allocation_to_success_commission:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to the success commission.
          nullable: true
          readOnly: true
        allocation_to_success_commission_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to VAT on the success commission.
          nullable: true
          readOnly: true
        allocation_to_tax_free_expenses:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to tax-free expenses.
          nullable: true
          readOnly: true
        allocation_to_taxable_expenses:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to taxable expenses.
          nullable: true
          readOnly: true
        allocation_to_taxable_expenses_vat:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Amount allocated to VAT on taxable expenses.
          nullable: true
          readOnly: true
        instalment_payments_to_client:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Instalment payments already passed on to you.
          nullable: true
          readOnly: true
        payments_to_client:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Debtor payments made directly to you.
          nullable: true
          readOnly: true
        payments_to_dca:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Debtor payments received by paywise.
          nullable: true
          readOnly: true
        payout:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Balance for this VAT rate.
          nullable: true
          readOnly: true
        total_payments:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Total debtor payments at this VAT rate.
          nullable: true
          readOnly: true
        vat_rate:
          description: >-
            VAT rate as a decimal fraction, for example 0.19 for 19%. Exact
            decimal string; parse it with a decimal type, never a binary float.
          pattern: ^-?[0-9]{1,3}(?:\.[0-9]{1,2})?$
          readOnly: true
          type: string
      required:
        - allocation_to_client_costs
        - allocation_to_client_expenses
        - allocation_to_default_interest
        - allocation_to_fee
        - allocation_to_fee_vat
        - allocation_to_main_claim
        - allocation_to_overpayment
        - allocation_to_success_commission
        - allocation_to_success_commission_vat
        - allocation_to_tax_free_expenses
        - allocation_to_taxable_expenses
        - allocation_to_taxable_expenses_vat
        - instalment_payments_to_client
        - payments_to_client
        - payments_to_dca
        - payout
        - total_payments
        - vat_rate
      type: object
    DocumentParentTypeEnum:
      description: |-
        * `claim` - claim
        * `message` - message
        * `request_to_client_answer` - request_to_client_answer
        * `rental_agreement` - rental_agreement
        * `enforceable_title` - enforceable_title
      enum:
        - claim
        - message
        - request_to_client_answer
        - rental_agreement
        - enforceable_title
      type: string
    SingleMandateStatementCostBurdenItem:
      description: One account line of a Kostenbelastung.
      properties:
        account_code:
          description: Account code of this cost position.
          readOnly: true
          type: string
        designation:
          description: Human-readable designation of the cost position.
          readOnly: true
          type: string
        gross_amount:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Gross amount of this cost position.
          nullable: true
          readOnly: true
        main_account_code:
          description: Main account into which this position is grouped.
          nullable: true
          readOnly: true
          type: string
        net_amount:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: Net amount of this cost position.
          nullable: true
          readOnly: true
        vat_amount:
          allOf:
            - $ref: '#/components/schemas/StatementAmount'
          description: VAT amount of this cost position.
          nullable: true
          readOnly: true
      required:
        - account_code
        - designation
        - gross_amount
        - main_account_code
        - net_amount
        - vat_amount
      type: object
  securitySchemes:
    caseBearerAuth:
      description: >-
        Company-bound Case Management API key — the standard credential for this
        API.
      scheme: bearer
      type: http
    partnerBearerAuth:
      description: >-
        Partner API key acting for one entitled company; every Case request must
        then also carry the X-On-Behalf-Of-Company header.
      scheme: bearer
      type: http

````

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