OpenAPI Specification
openapi: 3.1.0
info:
contact:
email: support@telnyx.com
description: Telnyx provides global communications and connectivity APIs for developers — including SIP trunking, programmable voice, SMS, MMS, WhatsApp Business Messaging, Call Control, Fax, Wireless (IoT & eSIM), Phone Numbers (DID provisioning & porting), Emergency Services, and Network APIs for private interconnects and edge connectivity. Build, scale, and manage voice, messaging, and data networks with Telnyx's carrier-grade global infrastructure and API-first platform.
title: Telnyx Access Tokens Connections API
version: 2.0.0
x-endpoint-cost: light
servers:
- description: Version 2.0.0 of the Telnyx API
url: https://api.telnyx.com/v2
security:
- bearerAuth: []
tags:
- description: Connections operations
name: Connections
paths:
/connections:
get:
description: Returns a list of your connections irrespective of type.
operationId: ListConnections
parameters:
- $ref: '#/components/parameters/connections_FilterConsolidated'
- $ref: '#/components/parameters/connections_PageConsolidated'
- $ref: '#/components/parameters/connections_SortConnection'
responses:
'200':
$ref: '#/components/responses/ListConnectionsResponse'
'400':
$ref: '#/components/responses/connections_BadRequestResponse'
'401':
$ref: '#/components/responses/UnauthenticatedResponse'
'403':
$ref: '#/components/responses/connections_UnauthorizedResponse'
summary: List connections
tags:
- Connections
x-endpoint-cost: medium
x-group-parameters: 'true'
x-latency-category: responsive
/connections/{id}:
get:
description: Retrieves the high-level details of an existing connection. To retrieve specific authentication information, use the endpoint for the specific connection type.
operationId: RetrieveConnection
parameters:
- description: IP Connection ID
in: path
name: id
required: true
schema:
type: string
responses:
'200':
$ref: '#/components/responses/ConnectionResponse'
'400':
$ref: '#/components/responses/connections_BadRequestResponse'
'401':
$ref: '#/components/responses/UnauthenticatedResponse'
'403':
$ref: '#/components/responses/connections_UnauthorizedResponse'
'404':
$ref: '#/components/responses/connections_NotFoundResponse'
summary: Retrieve a connection
tags:
- Connections
x-latency-category: responsive
components:
responses:
connections_BadRequestResponse:
content:
application/json:
examples:
missingParameter:
value:
errors:
- code: '10015'
detail: The request failed because it was not well-formed.
meta:
url: https://developers.telnyx.com/docs/overview/errors/10015
source:
pointer: /
title: Bad Request
schema:
$ref: '#/components/schemas/ErrorResponse'
description: Bad request, the request was unacceptable, often due to missing a required parameter.
connections_NotFoundResponse:
content:
application/json:
examples:
notFound:
value:
errors:
- code: '10005'
detail: The requested resource or URL could not be found.
meta:
url: https://developers.telnyx.com/docs/overview/errors/10005
source:
pointer: /
title: Resource not found
schema:
$ref: '#/components/schemas/ErrorResponse'
description: The requested resource doesn't exist.
connections_UnauthorizedResponse:
content:
application/json:
examples:
notAuthorized:
value:
errors:
- code: '10010'
detail: You are not authorized to access the requested resource.
meta:
url: https://developers.telnyx.com/docs/overview/errors/10010
source:
pointer: /
title: Not authorized
schema:
$ref: '#/components/schemas/ErrorResponse'
description: The user doesn't have the required permissions to perform the requested action.
UnauthenticatedResponse:
content:
application/json:
examples:
Authentication Failed:
value:
errors:
- code: '10009'
detail: Could not understand the provided credentials.
meta:
url: https://developers.telnyx.com/docs/overview/errors/10009
title: Authentication failed
schema:
$ref: '#/components/schemas/ErrorResponse'
description: Unauthorized
ListConnectionsResponse:
content:
application/json:
schema:
properties:
data:
items:
$ref: '#/components/schemas/Connection'
type: array
meta:
$ref: '#/components/schemas/connections_PaginationMeta'
title: List Connections Response
type: object
description: Successful response with a list of connections.
ConnectionResponse:
content:
application/json:
schema:
properties:
data:
$ref: '#/components/schemas/Connection'
title: Connection Response
type: object
description: Successful response with details about a connection.
parameters:
connections_FilterConsolidated:
description: 'Consolidated filter parameter (deepObject style). Originally: filter[connection_name], filter[fqdn], filter[outbound_voice_profile_id], filter[outbound.outbound_voice_profile_id]'
explode: true
in: query
name: filter
schema:
properties:
connection_name:
description: Filter by connection_name using nested operations
properties:
contains:
default: null
description: If present, connections with <code>connection_name</code> containing the given value will be returned. Matching is not case-sensitive. Requires at least three characters.
type: string
type: object
fqdn:
default: null
description: If present, connections with an `fqdn` that equals the given value will be returned. Matching is case-sensitive, and the full string must match.
type: string
outbound_voice_profile_id:
description: Identifies the associated outbound voice profile.
example: '1293384261075731499'
type: string
x-format: int64
type: object
style: deepObject
connections_SortConnection:
description: "Specifies the sort order for results. By default sorting direction is ascending. To have the results sorted in descending order add the <code> -</code> prefix.<br/><br/>\nThat is: <ul>\n <li>\n <code>connection_name</code>: sorts the result by the\n <code>connection_name</code> field in ascending order.\n </li>\n\n <li>\n <code>-connection_name</code>: sorts the result by the\n <code>connection_name</code> field in descending order.\n </li>\n</ul> <br/> If not given, results are sorted by <code>created_at</code> in descending order."
in: query
name: sort
schema:
default: created_at
enum:
- created_at
- connection_name
- active
example: connection_name
type: string
connections_PageConsolidated:
description: 'Consolidated page parameter (deepObject style). Originally: page[size], page[number]'
explode: true
in: query
name: page
schema:
properties:
number:
default: 1
description: The page number to load
minimum: 1
type: integer
size:
default: 250
description: The size of the page
maximum: 250
minimum: 1
type: integer
type: object
style: deepObject
schemas:
AnchorsiteOverride:
default: Latency
description: '`Latency` directs Telnyx to route media through the site with the lowest round-trip time to the user''s connection. Telnyx calculates this time using ICMP ping messages. This can be disabled by specifying a site to handle all media.'
enum:
- Latency
- Chicago, IL
- Ashburn, VA
- San Jose, CA
- Sydney, Australia
- Amsterdam, Netherlands
- London, UK
- Toronto, Canada
- Vancouver, Canada
- Frankfurt, Germany
example: Amsterdam, Netherlands
title: Anchorsite Override
type: string
ErrorResponse:
properties:
errors:
items:
properties:
code:
type: string
detail:
type: string
meta:
properties:
url:
format: uri
type: string
type: object
source:
properties:
pointer:
type: string
type: object
title:
type: string
type: object
type: array
type: object
connections_PaginationMeta:
properties:
page_number:
example: 2
type: integer
page_size:
example: 25
type: integer
total_pages:
example: 3
type: integer
total_results:
example: 55
type: integer
title: Pagination Meta
type: object
connections_OutboundVoiceProfileId:
description: Identifies the associated outbound voice profile.
example: '1293384261075731499'
title: Outbound Voice Profile ID
type: string
x-format: int64
Connection:
example:
active: true
anchorsite_override: Latency
connection_name: string
created_at: '2018-02-02T22:25:27.521Z'
id: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
outbound_voice_profile_id: '1293384261075731499'
record_type: ip_connection
updated_at: '2018-02-02T22:25:27.521Z'
webhook_api_version: '1'
webhook_event_failover_url: https://failover.example.com
webhook_event_url: https://example.com
properties:
active:
description: Defaults to true
example: true
type: boolean
anchorsite_override:
$ref: '#/components/schemas/AnchorsiteOverride'
connection_name:
example: string
type: string
created_at:
description: ISO 8601 formatted date indicating when the resource was created.
example: '2018-02-02T22:25:27.521Z'
type: string
id:
description: Identifies the specific resource.
example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
type: string
x-format: int64
outbound_voice_profile_id:
$ref: '#/components/schemas/connections_OutboundVoiceProfileId'
record_type:
description: Identifies the type of the resource.
example: ip_connection
type: string
tags:
description: Tags associated with the connection.
example:
- tag1
- tag2
items:
type: string
type: array
updated_at:
description: ISO 8601 formatted date indicating when the resource was updated.
example: '2018-02-02T22:25:27.521Z'
type: string
webhook_api_version:
default: '1'
description: Determines which webhook format will be used, Telnyx API v1 or v2.
enum:
- '1'
- '2'
example: '1'
type: string
webhook_event_failover_url:
default: ''
description: The failover URL where webhooks related to this connection will be sent if sending to the primary URL fails.
example: https://failover.example.com
format: uri
type:
- string
- 'null'
webhook_event_url:
default: null
description: The URL where webhooks related to this connection will be sent.
example: https://example.com
format: uri
type:
- string
- 'null'
title: Connection
type: object
securitySchemes:
bearerAuth:
scheme: bearer
type: http
branded-calling_bearerAuth:
description: API key passed as a Bearer token in the Authorization header
scheme: bearer
type: http
oauthClientAuth:
description: OAuth 2.0 authentication for Telnyx API and MCP integrations
flows:
authorizationCode:
authorizationUrl: https://api.telnyx.com/v2/oauth/authorize
refreshUrl: https://api.telnyx.com/v2/oauth/token
scopes:
admin: Administrative access to Telnyx resources
tokenUrl: https://api.telnyx.com/v2/oauth/token
clientCredentials:
scopes:
admin: Administrative access to Telnyx resources
tokenUrl: https://api.telnyx.com/v2/oauth/token
type: oauth2
outbound-voice-profiles_bearerAuth:
bearerFormat: JWT
scheme: bearer
type: http
pronunciation-dicts_bearerAuth:
description: Telnyx API v2 key. Obtain from https://portal.telnyx.com
scheme: bearer
type: http
stored-payment-transactions_bearerAuth:
bearerFormat: JWT
scheme: bearer
type: http