> ## 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.

# Retrieve regulatory requirements



## OpenAPI

````yaml https://telnyx-openapi-ng.s3.us-east-1.amazonaws.com/numbers-identity/regulatory.yml get /regulatory_requirements
openapi: 3.1.0
info:
  title: Telnyx Regulatory Requirements API
  version: 2.0.0
  description: API for Regulatory requirements.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
security:
  - bearerAuth: []
paths:
  /regulatory_requirements:
    get:
      tags:
        - Regulatory Requirements
      summary: Retrieve regulatory requirements
      operationId: ListRegulatoryRequirements
      parameters:
        - name: filter
          in: query
          style: deepObject
          explode: true
          description: >-
            Consolidated filter parameter (deepObject style). Originally:
            filter[phone_number], filter[requirement_group_id],
            filter[country_code], filter[phone_number_type], filter[action]
          schema:
            type: object
            properties:
              phone_number:
                type: string
                example: '+41215470622'
                description: Phone number to check requirements for
              requirement_group_id:
                type: string
                example: d4c0b4a6-7bd2-40c5-a3b9-2acd99e212b2
                description: ID of requirement group to check requirements for
              country_code:
                type: string
                example: DE
                description: Country code(iso2) to check requirements for
              phone_number_type:
                type: string
                enum:
                  - local
                  - toll_free
                  - mobile
                  - national
                  - shared_cost
                description: Phone number type to check requirements for
              action:
                type: string
                enum:
                  - ordering
                  - porting
                  - action
                description: Action to check requirements for
      responses:
        '200':
          $ref: '#/components/responses/listRegulatoryRequirements'
        '400':
          $ref: '#/components/responses/numbers_BadRequestResponse'
        '401':
          $ref: '#/components/responses/numbers_UnauthorizedResponse'
        '404':
          $ref: '#/components/responses/numbers_NotFoundResponse'
        '422':
          $ref: '#/components/responses/numbers_UnprocessableEntity'
        '500':
          $ref: '#/components/responses/numbers_GenericErrorResponse'
      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
            });


            const regulatoryRequirement = await
            client.regulatoryRequirements.retrieve();


            console.log(regulatoryRequirement.data);
        - 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
            )
            regulatory_requirement = client.regulatory_requirements.retrieve()
            print(regulatory_requirement.data)
        - 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\tregulatoryRequirement, err := client.RegulatoryRequirements.Get(context.TODO(), telnyx.RegulatoryRequirementGetParams{})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", regulatoryRequirement.Data)\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.regulatoryrequirements.RegulatoryRequirementRetrieveParams;

            import
            com.telnyx.sdk.models.regulatoryrequirements.RegulatoryRequirementRetrieveResponse;


            public final class Main {
                private Main() {}

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

                    RegulatoryRequirementRetrieveResponse regulatoryRequirement = client.regulatoryRequirements().retrieve();
                }
            }
        - lang: Ruby
          source: |-
            require "telnyx"

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

            regulatory_requirement = telnyx.regulatory_requirements.retrieve

            puts(regulatory_requirement)
        - lang: CLI
          source: |-
            telnyx regulatory-requirements retrieve \
              --api-key 'My API Key'
components:
  responses:
    listRegulatoryRequirements:
      description: An array of Regulatory Requirements Responses
      content:
        application/json:
          schema:
            type: object
            properties:
              data:
                type: array
                items:
                  $ref: '#/components/schemas/RegulatoryRequirements'
    numbers_BadRequestResponse:
      description: >-
        Bad request, the request was unacceptable, often due to missing a
        required parameter.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/numbers_Errors'
    numbers_UnauthorizedResponse:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/numbers_Errors'
          examples:
            Authentication Failed:
              value:
                errors:
                  - code: '10009'
                    title: Authentication failed
                    detail: Could not understand the provided credentials.
                    meta:
                      url: https://developers.telnyx.com/docs/overview/errors/10009
    numbers_NotFoundResponse:
      description: The requested resource doesn't exist.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/numbers_Errors'
    numbers_UnprocessableEntity:
      description: Unprocessable entity. Check the 'detail' field in response for details.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/numbers_Errors'
    numbers_GenericErrorResponse:
      description: Unexpected error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/numbers_Errors'
  schemas:
    RegulatoryRequirements:
      properties:
        country_code:
          type: string
          example: DE
          readOnly: true
        phone_number_type:
          type: string
          example: local
          readOnly: true
        action:
          type: string
          example: ordering
          readOnly: true
        regulatory_requirements:
          type: array
          items:
            type: object
            properties:
              description:
                type: string
                example: >-
                  Address matching the DID area code (street, building number,
                  postal code, city and country)
                readOnly: true
              id:
                type: string
                format: uuid
                example: 12ade33a-21c0-473b-b055-b3c836e1c292
                readOnly: true
              example:
                type: string
                example: 600 Congress Avenue, 14th Floor, Austin, TX 78701
                readOnly: true
              name:
                type: string
                example: Address matching the DID area code
              field_type:
                type: string
                example: address_id
              acceptance_criteria:
                type: object
                properties:
                  locality_limit:
                    type: string
                    example: Identical locality as the numbers desired
                  time_limit:
                    type: string
                    example: Less than 5 months old
                  regex:
                    type: string
                    example: regex field value must match
                  case_sensitive:
                    type: string
                    example: Whether field value is case sensitive
                  acceptable_characters:
                    type: string
                    example: Characters that can be included in field value
                  acceptable_values:
                    type: array
                    items:
                      type: string
                  max_length:
                    type: string
                    example: '10'
                  min_length:
                    type: string
                    example: '5'
      type: object
    numbers_Errors:
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/numbers_Error'
      type: object
    numbers_Error:
      properties:
        code:
          type: string
          example: '10007'
        title:
          type: string
          example: Unexpected error
        detail:
          type: string
          example: An unexpected error occured.
        source:
          type: object
          properties:
            pointer:
              description: JSON pointer (RFC6901) to the offending entity.
              type: string
              example: /base
            parameter:
              description: Indicates which query parameter caused the error.
              type: string
        meta:
          type: object
          properties:
            url:
              type: string
              description: URL with additional information on the error.
              example: https://developers.telnyx.com/docs/overview/errors/10015
      type: object
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````