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

# List documents

> Lists the documents in the key's workspace, newest first. Deleted documents are not included. Uses cursor pagination: pass the `nextCursor` from one response as `cursor` on the next request.



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/documents
openapi: 3.1.0
info:
  title: Suresign API
  version: 1.0.0
  description: >-
    Read the documents in your Suresign workspace and download their PDFs.
    Available on the Pro and Business plans.
servers:
  - url: https://suresign.si
    description: Suresign
security:
  - bearerAuth: []
tags:
  - name: Workspace
    description: Check which workspace a key opens.
  - name: Documents
    description: List, read and download documents.
paths:
  /api/v1/documents:
    get:
      tags:
        - Documents
      summary: List documents
      description: >-
        Lists the documents in the key's workspace, newest first. Deleted
        documents are not included. Uses cursor pagination: pass the
        `nextCursor` from one response as `cursor` on the next request.
      operationId: listDocuments
      parameters:
        - name: status
          in: query
          required: false
          description: Only return documents with this status.
          schema:
            type: string
            enum:
              - DRAFT
              - SENT
              - VIEWED
              - COMPLETED
              - DECLINED
              - CANCELLED
              - EXPIRED
        - name: limit
          in: query
          required: false
          description: How many documents to return, from 1 to 100.
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 25
        - name: cursor
          in: query
          required: false
          description: >-
            The `nextCursor` value from the previous page. Leave it out to get
            the first page.
          schema:
            type: string
      responses:
        '200':
          description: A page of documents.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Document'
                  nextCursor:
                    type:
                      - string
                      - 'null'
                    description: >-
                      Pass this as `cursor` to get the next page. `null` when
                      there are no more documents.
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/PlanRequired'
        '403':
          $ref: '#/components/responses/Forbidden'
        '429':
          $ref: '#/components/responses/RateLimited'
components:
  schemas:
    Document:
      type: object
      properties:
        id:
          type: string
        title:
          type: string
        status:
          type: string
          enum:
            - DRAFT
            - SENT
            - VIEWED
            - PARTIALLY_SIGNED
            - COMPLETED
            - DECLINED
            - EXPIRED
            - CANCELLED
        fileName:
          type: string
        pageCount:
          type: integer
        fileSize:
          type: integer
          description: Size in bytes.
        signingOrder:
          type: string
          enum:
            - PARALLEL
            - SEQUENTIAL
        createdAt:
          type: string
          format: date-time
        sentAt:
          type:
            - string
            - 'null'
          format: date-time
        completedAt:
          type:
            - string
            - 'null'
          format: date-time
        expiresAt:
          type:
            - string
            - 'null'
          format: date-time
        progress:
          type: object
          description: >-
            How many of the people asked to sign or approve have done so. CC and
            viewer recipients are not counted.
          properties:
            done:
              type: integer
            total:
              type: integer
        recipients:
          type: array
          items:
            $ref: '#/components/schemas/Recipient'
        links:
          type: object
          properties:
            self:
              type: string
              example: /api/v1/documents/doc_123
            download:
              type: string
              example: /api/v1/documents/doc_123/download
    Recipient:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        email:
          type: string
        role:
          type: string
          enum:
            - SIGNER
            - APPROVER
            - CC
            - VIEWER
        status:
          type: string
          enum:
            - PENDING
            - SENT
            - VIEWED
            - SIGNED
            - APPROVED
            - DECLINED
            - BOUNCED
        order:
          type: integer
          description: Position in the signing order.
        sentAt:
          type:
            - string
            - 'null'
          format: date-time
        viewedAt:
          type:
            - string
            - 'null'
          format: date-time
        completedAt:
          type:
            - string
            - 'null'
          format: date-time
          description: When this person signed or approved.
        declinedAt:
          type:
            - string
            - 'null'
          format: date-time
        declineReason:
          type:
            - string
            - 'null'
    Error:
      type: object
      properties:
        error:
          type: string
          description: A plain-language explanation of what went wrong.
  responses:
    BadRequest:
      description: A query parameter was not valid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: The key is missing, malformed, revoked or unknown.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: That key is not valid.
    PlanRequired:
      description: >-
        The key is valid, but the workspace's plan does not include the API. The
        key is kept and works again once the workspace is on Pro or Business.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
              details:
                type: object
                properties:
                  code:
                    type: string
                    example: plan_limit
                  upgrade:
                    type:
                      - string
                      - 'null'
                    example: pro
                  href:
                    type: string
                    description: Where to upgrade.
    Forbidden:
      description: The workspace is suspended, so its API keys are refused.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: This workspace is suspended, so its API keys are refused.
    RateLimited:
      description: More than 300 requests in a minute with this key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: Rate limit exceeded. Try again in 12 seconds.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Your workspace API key, which starts with `dtd_`. Send it as
        `Authorization: Bearer dtd_...`.

````

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