This is the API V2 documentation. To switch out of beta revert back to our API V1.

Open SidemenuAPI Reference
API Reference
Close Sidemenu

Connections

List all ConnectionsfindAllConnections

get https://api.telnyx.com/v2/connections

Returns a list of your connections irrespective of type.

curl -X GET \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --globoff "https://api.telnyx.com/v2/connections?page[number]=1&page[size]=20"
Parameters
In query
page[number]
integer (1)
optional

The page number to load

Default: 1
page[size]
integer (1 - 250)
optional

The size of the page

Default: 20
filter[connection_name][contains]
string
optional

If present, connections with connection_name containing the given value will be returned. Matching is not case-sensitive. Requires at least three characters.

Default: "null"
filter[outbound_voice_profile_id]
string (int64)
optional

Identifies the associated outbound voice profile.

Example: "1293384261075731499"
sort
string
optional

Specifies the sort order for results. By default sorting direction is ascending. To have the results sorted in descending order add the - prefix.

That is:

  • connection_name: sorts the result by the connection_name field in ascending order.
  • -connection_name: sorts the result by the connection_name field in descending order.

If not given, results are sorted by created_at in descending order.

Default: "created_at"
Example: "connection_name"
Options: [ "created_at", "connection_name", "active" ]
Responses
200

Successful response

400

Bad request

401

Unauthorized

404

Resource not found

Success Response
{
  "data": [
    {
      "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"
    }
  ],
  "meta": {
    "page_number": 2,
    "page_size": 25,
    "total_pages": 3,
    "total_results": 55
  }
}

Retrieve a ConnectiongetConnection

get https://api.telnyx.com/v2/connections/{id}

Retrieves the high-level details of an existing connection. To retrieve specific authentication information, use the endpoint for the specific connection type.

curl -X GET \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --globoff "https://api.telnyx.com/v2/connections/{id}"
Parameters
In path
id
string
required

IP Connection ID

Responses
200

Successful response

401

Unauthorized

404

Resource not found

422

Bad request

Success Response
{
  "data": {
    "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"
  }
}

Was this section helpful?was-this-page-helpful