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

# List additional documents

> Returns a list of additional documents for a porting order.



## OpenAPI

````yaml https://telnyx-openapi-ng.s3.us-east-1.amazonaws.com/numbers-identity/porting-documents.yml get /porting_orders/{id}/additional_documents
openapi: 3.1.0
info:
  title: Telnyx Porting Documents API
  version: 2.0.0
  description: API for LOA configurations, templates, and additional documents.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
security:
  - bearerAuth: []
paths:
  /porting_orders/{id}/additional_documents:
    get:
      tags:
        - Porting Orders
      summary: List additional documents
      description: Returns a list of additional documents for a porting order.
      operationId: ListAdditionalDocuments
      parameters:
        - $ref: '#/components/parameters/PathPortingOrderID'
        - $ref: '#/components/parameters/porting-order_PageConsolidated'
        - name: filter
          in: query
          style: deepObject
          explode: true
          description: >-
            Consolidated filter parameter (deepObject style). Originally:
            filter[document_type]
          schema:
            type: object
            properties:
              document_type:
                type: array
                items:
                  type: string
                  enum:
                    - loa
                    - invoice
                    - csr
                    - other
                  example: loa
                description: Filter additional documents by a list of document types
        - name: sort
          in: query
          style: deepObject
          explode: true
          description: >-
            Consolidated sort parameter (deepObject style). Originally:
            sort[value]
          schema:
            type: object
            properties:
              value:
                type: string
                enum:
                  - created_at
                  - '-created_at'
                example: created_at
                description: >-
                  Specifies the sort order for results. If not given, results
                  are sorted by created_at in descending order.
      responses:
        '200':
          $ref: '#/components/responses/ListPortingAdditionalDocuments'
        '401':
          description: Unauthorized
        '404':
          description: Resource not found
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Telnyx from 'telnyx';


            const client = new Telnyx({
              apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
            });


            // Automatically fetches more pages as needed.

            for await (const additionalDocumentListResponse of
            client.portingOrders.additionalDocuments.list(
              '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
            )) {
              console.log(additionalDocumentListResponse.id);
            }
        - lang: Python
          source: |-
            import os
            from telnyx import Telnyx

            client = Telnyx(
                api_key=os.environ.get("TELNYX_API_KEY"),  # This is the default and can be omitted
            )
            page = client.porting_orders.additional_documents.list(
                id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            )
            page = page.data[0]
            print(page.id)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/team-telnyx/telnyx-go\"\n\t\"github.com/team-telnyx/telnyx-go/option\"\n)\n\nfunc main() {\n\tclient := telnyx.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tpage, err := client.PortingOrders.AdditionalDocuments.List(\n\t\tcontext.TODO(),\n\t\t\"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e\",\n\t\ttelnyx.PortingOrderAdditionalDocumentListParams{},\n\t)\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", page)\n}\n"
        - lang: Java
          source: >-
            package com.telnyx.sdk.example;


            import com.telnyx.sdk.client.TelnyxClient;

            import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;

            import
            com.telnyx.sdk.models.portingorders.additionaldocuments.AdditionalDocumentListPage;

            import
            com.telnyx.sdk.models.portingorders.additionaldocuments.AdditionalDocumentListParams;


            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    TelnyxClient client = TelnyxOkHttpClient.fromEnv();

                    AdditionalDocumentListPage page = client.portingOrders().additionalDocuments().list("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e");
                }
            }
        - lang: Ruby
          source: >-
            require "telnyx"


            telnyx = Telnyx::Client.new(api_key: "My API Key")


            page =
            telnyx.porting_orders.additional_documents.list("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")


            puts(page)
        - lang: PHP
          source: >-
            <?php


            require_once dirname(__DIR__) . '/vendor/autoload.php';


            use Telnyx\Client;

            use Telnyx\Core\Exceptions\APIException;


            $client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API
            Key');


            try {
              $page = $client->portingOrders->additionalDocuments->list(
                '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
                filter: ['documentType' => ['loa']],
                pageNumber: 0,
                pageSize: 0,
                sort: ['value' => 'created_at'],
              );

              var_dump($page);
            } catch (APIException $e) {
              echo $e->getMessage();
            }
        - lang: CLI
          source: |-
            telnyx porting-orders:additional-documents list \
              --api-key 'My API Key' \
              --id 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e
components:
  parameters:
    PathPortingOrderID:
      name: id
      description: Porting Order id
      in: path
      required: true
      schema:
        type: string
        format: uuid
    porting-order_PageConsolidated:
      name: page
      in: query
      style: deepObject
      explode: true
      description: >-
        Consolidated page parameter (deepObject style). Originally: page[size],
        page[number]
      schema:
        type: object
        properties:
          size:
            type: integer
            minimum: 1
            maximum: 250
            default: 20
            description: The size of the page
          number:
            type: integer
            minimum: 1
            default: 1
            description: The page number to load
  responses:
    ListPortingAdditionalDocuments:
      description: Successful response
      content:
        application/json:
          schema:
            type: object
            properties:
              data:
                type: array
                items:
                  $ref: '#/components/schemas/PortingAdditionalDocument'
              meta:
                $ref: '#/components/schemas/PaginationMeta'
            example:
              data:
                - id: 2acd1061-33cb-49b8-8014-beb6dc3fedbf
                  document_id: 40bc547a-7f96-4cd5-926a-da4842671e88
                  document_type: loa
                  porting_order_id: 9d7b3b8e-4e67-4837-9c44-d110cd2c82a1
                  record_type: porting_additional_document
                  created_at: '2023-06-01T10:00:00.00000Z'
                  updated_at: '2023-06-01T10:00:00.00000Z'
              meta:
                total_pages: 1
                total_results: 1
                page_number: 1
                page_size: 25
  schemas:
    PortingAdditionalDocument:
      type: object
      properties:
        id:
          type: string
          description: Uniquely identifies this additional document
          format: uuid
          example: eef3340b-8903-4466-b445-89b697315a3a
        document_type:
          type: string
          description: Identifies the type of additional document
          enum:
            - loa
            - invoice
            - csr
            - other
          example: loa
        document_id:
          type: string
          format: uuid
          description: Identifies the associated document
          example: f1486bae-f067-460c-ad43-73a92848f902
        filename:
          type: string
          description: The filename of the related document.
          example: file.txt
        content_type:
          type: string
          description: The content type of the related document.
          example: text/plain
        porting_order_id:
          type: string
          format: uuid
          description: Identifies the associated porting order
          example: f1486bae-f067-460c-ad43-73a92848f902
        record_type:
          type: string
          example: porting_additional_document
          description: Identifies the type of the resource.
          readOnly: true
        created_at:
          type: string
          format: date-time
          description: ISO 8601 formatted date indicating when the resource was created.
          example: '2021-03-19T10:07:15.527000Z'
        updated_at:
          type: string
          format: date-time
          description: ISO 8601 formatted date indicating when the resource was updated.
          example: '2021-03-19T10:07:15.527000Z'
    PaginationMeta:
      type: object
      properties:
        total_pages:
          type: integer
          example: 3
        total_results:
          type: integer
          example: 55
        page_number:
          type: integer
          example: 2
        page_size:
          type: integer
          example: 25
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````