Skip to main content
POST
/
enterprises
/
{enterprise_id}
/
dir
JavaScript
import Telnyx from 'telnyx';

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

const dir = await client.enterprises.dir.create('4a6192a4-573d-446d-b3ce-aff9117272a6', {
  authorizer_email: 'sam@acmeplumbing.example.com',
  authorizer_name: 'Sam Owner',
  certify_brand_is_accurate: true,
  certify_ip_ownership: true,
  certify_no_shaft_content: true,
  display_name: 'Acme Plumbing',
  call_reasons: ['Appointment reminders', 'Billing inquiries'],
});

console.log(dir.data);
{
  "data": {
    "id": "16635d38-75a6-4481-82e8-69af60e05011",
    "enterprise_id": "4a6192a4-573d-446d-b3ce-aff9117272a6",
    "display_name": "Acme Plumbing",
    "reselling": false,
    "certify_brand_is_accurate": true,
    "certify_no_shaft_content": true,
    "certify_ip_ownership": true,
    "authorizer_name": "Sam Owner",
    "authorizer_email": "sam@acmeplumbing.example.com",
    "logo_url": "https://acmeplumbing.example.com/logo-256.bmp",
    "call_reasons": [
      {
        "reason": "Appointment reminders",
        "created_at": "2026-04-26T18:06:51.940749Z"
      }
    ],
    "documents": [
      {
        "document_id": "2a7e8337-e803-4057-a4ae-26c40eb0bc6c",
        "document_type": "business_registration",
        "description": "Certificate of incorporation."
      }
    ],
    "rejection_reasons": [
      {
        "code": "documentation_incomplete",
        "title": "Documentation incomplete",
        "detail": "Provided documents do not establish business identity.",
        "message": "Please re-upload a clearer scan of the certificate."
      }
    ],
    "rejected_at": "2023-11-07T05:31:56Z",
    "created_at": "2026-04-26T18:06:51.940749Z",
    "updated_at": "2026-04-26T18:09:24.785211Z",
    "submitted_at": "2026-04-26T18:07:03.716411Z",
    "verified_at": "2026-04-26T18:07:29.537926Z",
    "expiring_at": "2027-04-26T18:07:29.537981Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

enterprise_id
string<uuid>
required

The enterprise id. Lowercase UUID.

Example:

"4a6192a4-573d-446d-b3ce-aff9117272a6"

Body

application/json
display_name
string
required

Name shown to call recipients. No emoji; not whitespace-only.

Required string length: 1 - 35
Example:

"Acme Plumbing"

certify_brand_is_accurate
enum<boolean>
required

Must be true.

Available options:
true
Example:

true

certify_no_shaft_content
enum<boolean>
required

Must be true. Confirms this DIR is not used for SHAFT content (Sex, Hate, Alcohol, Firearms, Tobacco) where prohibited.

Available options:
true
Example:

true

certify_ip_ownership
enum<boolean>
required

Must be true. Confirms ownership of any logos/trademarks shown.

Available options:
true
Example:

true

authorizer_name
string
required

Name of the person at your enterprise who is authorizing this DIR registration. Must be a real individual (used for audit and trademark-claim contests).

Maximum string length: 255
Example:

"Sam Owner"

authorizer_email
string<email>
required

Contact email of the authorizer. Telnyx may send verification or infringement-notice email here; use a monitored mailbox.

Example:

"sam@acmeplumbing.example.com"

reselling
boolean
default:false

Set to true if your organization places calls on behalf of other enterprises (BPO/reseller).

Example:

false

logo_url
string<uri>

Publicly accessible HTTPS URL (max 128 chars) to a 256x256 BMP logo (max 1 MB).

Maximum string length: 128
Example:

"https://acmeplumbing.example.com/logo-256.bmp"

call_reasons
string[]

1–10 reasons your business calls customers. Validate phrasing against POST /call_reasons/validate.

Required array length: 1 - 10 elements
Maximum string length: 64
Example:
[
"Appointment reminders",
"Billing inquiries"
]
documents
object[]

Supporting documents. Each document_id may appear at most once on a DIR.

Maximum array length: 20

Response

DIR created in draft status.

data
object
required