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

# List a deal’s documents

> Documents on the deal, newest first, with type and processing status. Presigned uploads that were never finalized are not included. Use `GET /documents/{id}` for a download URL.



## OpenAPI

````yaml /openapi/public-v1.json get /v1/deals/{dealId}/documents
openapi: 3.0.0
info:
  title: NextLevel MCA Public API
  description: >-
    REST API for the NextLevel MCA deal platform. Objects flow Businesses →
    People → Deals → Submissions → Offers → Advances.


    **Authentication.** Send `Authorization: Bearer <key>` with an API key
    (`nlmca_live_…`, created in Settings → Developers) or an OAuth access token.
    Keys are scoped to one location.


    **Conventions.** JSON only. Cursor pagination (`limit` ≤ 100, `cursor` from
    `meta.next_cursor`). Every success is `{ data, meta }`; every error is `{
    error: { type, message, code, param, request_id } }`. POST endpoints accept
    `Idempotency-Key` (24h replay). Rate limit 300 requests/min per credential
    (`X-RateLimit-*` headers).


    **Scopes.** Keys with no scopes have all of them. Otherwise:

    - `businesses:read` — Read businesses and their notes, tasks and activity

    - `businesses:write` — Create and update businesses, notes and tasks

    - `people:read` — Read people (contacts and owners)

    - `people:write` — Create and update people

    - `deals:read` — Read deals, submissions and the pipeline

    - `deals:write` — Create and update deals, move stages

    - `documents:read` — Read documents and statement analysis

    - `documents:write` — Upload documents and request documents from merchants

    - `lenders:read` — Read lenders, criteria and lender matches

    - `lenders:write` — Create and update lenders and criteria

    - `submissions:write` — Submit deals to lenders and withdraw submissions

    - `offers:read` — Read offers

    - `offers:write` — Log and update offers, set the primary offer

    - `advances:read` — Read funded advances and renewal flags

    - `advances:write` — Update advances

    - `portal:send` — Generate and send merchant portal links

    - `webhooks:manage` — Manage webhook subscriptions
  version: '1.0'
  contact: {}
servers:
  - url: https://api.nextlevelmca.com
    description: Production
security:
  - bearer: []
tags:
  - name: Businesses
    description: Merchant businesses and their notes, tasks and activity
  - name: People
    description: Contacts and owners. Phone lookups normalise to E.164.
  - name: Deals
    description: Deals, stage moves, renewals and the pipeline
  - name: Documents
    description: Documents, presigned uploads, document requests and statement analysis
  - name: Lenders
    description: Lenders and their criteria
  - name: Lender matches
    description: Criteria-driven lender matching for a deal
  - name: Submissions
    description: Sending deals to lenders
  - name: Offers
    description: Lender offers and the primary offer
  - name: Advances
    description: Funded advances and renewal readiness
  - name: Merchant portal
    description: Magic links for the merchant portal
  - name: Webhooks
    description: Outbound event subscriptions
paths:
  /v1/deals/{dealId}/documents:
    get:
      tags:
        - Documents
      summary: List a deal’s documents
      description: >-
        Documents on the deal, newest first, with type and processing status.
        Presigned uploads that were never finalized are not included. Use `GET
        /documents/{id}` for a download URL.
      operationId: documents_list
      parameters:
        - name: dealId
          required: true
          in: path
          description: Deal id
          schema:
            type: string
        - name: limit
          required: false
          in: query
          description: Page size (1–100).
          schema:
            minimum: 1
            maximum: 100
            default: 25
            type: number
        - name: cursor
          required: false
          in: query
          description: Opaque cursor from a previous response’s `meta.next_cursor`.
          schema:
            type: string
        - name: type
          required: false
          in: query
          description: Only documents of this type.
          schema:
            type: string
            enum:
              - application
              - bank-statement
              - tax-return
              - voided-check
              - contract
              - drivers-license
              - ach-authorization
              - business-license
              - proof-of-ownership
              - utility-bill
              - other
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                  - meta
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/DocumentDto'
                  meta:
                    $ref: '#/components/schemas/ListMetaDto'
        '401':
          description: Missing, invalid, expired or revoked credential.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelopeDto'
        '403':
          description: Credential lacks the scope, or the role lacks the permission.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelopeDto'
        '404':
          description: Resource not found in this location.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelopeDto'
        '429':
          description: Rate limit exceeded. See `X-RateLimit-*` and `Retry-After`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelopeDto'
      security:
        - bearer: []
components:
  schemas:
    DocumentDto:
      type: object
      properties:
        id:
          type: string
          description: Document id.
        deal_id:
          type: string
          description: Deal the document belongs to.
        name:
          type: string
          description: File name as shown in the app.
        type:
          type: string
          enum:
            - application
            - bank-statement
            - tax-return
            - voided-check
            - contract
            - drivers-license
            - ach-authorization
            - business-license
            - proof-of-ownership
            - utility-bill
            - other
          nullable: true
          description: >-
            Document type. Bank statements (`bank-statement`) feed statement
            analysis.
        mime_type:
          type: string
          nullable: true
          description: MIME type, e.g. `application/pdf`.
        file_size:
          type: number
          nullable: true
          description: Size in bytes. Set on finalize for presigned uploads.
        upload_pending:
          type: boolean
          description: >-
            True while a presigned upload has been created but not finalized.
            Such documents are hidden from the app and from list endpoints.
        variant:
          type: string
          nullable: true
          enum:
            - original
            - watermarked
          description: >-
            `watermarked` rows are lender-facing copies generated from an
            `original`.
        source:
          type: string
          nullable: true
          description: 'How the file arrived: `manual`, `api`, `portal`, `email`, …'
        ocr_status:
          type: string
          nullable: true
          description: >-
            OCR / processing status when the document went through analysis:
            `pending`, `processing`, `completed`, `failed`.
        shared_with_merchant:
          type: boolean
          description: True when the document is visible in the merchant portal.
        uploaded_by_id:
          type: string
          nullable: true
          description: >-
            User id that uploaded the file (null for API keys without a creator
            or merchant uploads).
        uploaded_at:
          type: string
          nullable: true
          description: When the file was uploaded (ISO 8601).
        created_at:
          type: string
          description: Row creation time (ISO 8601).
        download_url:
          type: string
          nullable: true
          description: >-
            Signed download URL, valid for 15 minutes. Only present on `GET
            /documents/{id}` for finalized documents.
        download_url_expires_at:
          type: string
          nullable: true
          description: When `download_url` stops working (ISO 8601).
      required:
        - id
        - deal_id
        - name
        - type
        - mime_type
        - file_size
        - upload_pending
        - variant
        - source
        - ocr_status
        - shared_with_merchant
        - uploaded_by_id
        - uploaded_at
        - created_at
    ListMetaDto:
      type: object
      properties:
        next_cursor:
          type: string
          nullable: true
          description: Pass as `?cursor=` to fetch the next page. `null` on the last page.
        has_more:
          type: boolean
      required:
        - next_cursor
        - has_more
    ErrorEnvelopeDto:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/PublicErrorDto'
      required:
        - error
    PublicErrorDto:
      type: object
      properties:
        type:
          type: string
          enum:
            - validation_error
            - authentication_error
            - permission_error
            - not_found
            - conflict
            - rate_limit_error
            - api_error
        message:
          type: string
          description: Human-readable explanation, safe to show to an operator or an agent.
        code:
          type: string
          description: >-
            Stable machine-readable code, e.g. `missing_scope`,
            `duplicate_business`.
        param:
          type: string
          description: Request field the error refers to, when applicable.
        request_id:
          type: string
          description: Echo of the `X-Request-Id` header. Quote it when contacting support.
      required:
        - type
        - message
        - request_id
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: API key or JWT
      type: http
      description: API key (`nlmca_live_…`) or OAuth access token

````

## Related topics

- [List deals](/api-reference/deals/list-deals.md)
- [List deal notes](/api-reference/deals/list-deal-notes.md)
- [List deal tasks](/api-reference/deals/list-deal-tasks.md)
