Skip to main content
GET
/
sip_registration_status
JavaScript
import Telnyx from 'telnyx';

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

const sipRegistrationStatus = await client.sipRegistrationStatus.retrieve({
  credential_type: 'uac_external_credential',
});

console.log(sipRegistrationStatus.connection_id);
import os
from telnyx import Telnyx

client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
sip_registration_status = client.sip_registration_status.retrieve(
credential_type="uac_external_credential",
)
print(sip_registration_status.connection_id)
package main

import (
"context"
"fmt"

"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)

func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
sipRegistrationStatus, err := client.SipRegistrationStatus.Get(context.TODO(), telnyx.SipRegistrationStatusGetParams{
CredentialType: telnyx.SipRegistrationStatusGetParamsCredentialTypeUacExternalCredential,
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", sipRegistrationStatus.ConnectionID)
}
package com.telnyx.sdk.example;

import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.sipregistrationstatus.SipRegistrationStatusRetrieveParams;
import com.telnyx.sdk.models.sipregistrationstatus.SipRegistrationStatusRetrieveResponse;

public final class Main {
private Main() {}

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

SipRegistrationStatusRetrieveParams params = SipRegistrationStatusRetrieveParams.builder()
.credentialType(SipRegistrationStatusRetrieveParams.CredentialType.UAC_EXTERNAL_CREDENTIAL)
.build();
SipRegistrationStatusRetrieveResponse sipRegistrationStatus = client.sipRegistrationStatus().retrieve(params);
}
}
require "telnyx"

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

sip_registration_status = telnyx.sip_registration_status.retrieve(credential_type: :uac_external_credential)

puts(sip_registration_status)
<?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 {
$sipRegistrationStatus = $client->sipRegistrationStatus->retrieve(
credentialType: 'uac_external_credential',
connectionID: 'connection_id',
username: 'username',
);

var_dump($sipRegistrationStatus);
} catch (APIException $e) {
echo $e->getMessage();
}
telnyx sip-registration-status retrieve \
--api-key 'My API Key' \
--credential-type uac_external_credential
curl --request GET \
--url https://api.telnyx.com/v2/sip_registration_status \
--header 'Authorization: Bearer <token>'
{
  "connection_id": "1234567890",
  "connection_name": "FreePBX UAC 1002",
  "credential_type": "uac_external_credential",
  "credential_username": "useralice12345",
  "registered": true,
  "sip_registration_status": "registered",
  "last_registration_response": "200 OK",
  "sip_registration_details": {
    "auth_retries": 0,
    "expires": 1780404431,
    "uptime": 1780401551699908,
    "next_action_at": 1780414482,
    "failures": 0,
    "sip_uri_user_host": "1002@192.0.2.10"
  }
}

Authorizations

Authorization
string
header
required

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

Query Parameters

credential_type
enum<string>
required

The kind of credential to look up. uac_external_credential is keyed by connection_id; telephony_credential is keyed by username.

Available options:
uac_external_credential,
telephony_credential
connection_id
string

Identifier of the UAC connection to look up. Required when credential_type is uac_external_credential.

username
string

SIP username of the telephony credential to look up. Required when credential_type is telephony_credential.

Response

Registration status payload

connection_id
string

Identifier of the connection associated with the credential.

connection_name
string

Human-readable connection name.

credential_type
enum<string>

The credential type that was looked up.

Available options:
uac_external_credential,
telephony_credential
credential_username
string

SIP username used for the registration.

registered
boolean

True if the endpoint is currently registered.

sip_registration_status
enum<string>

Human-readable registration status derived from the registrar state.

Available options:
unregistering,
connection_disabled,
standby,
failed,
trying,
registered,
unknown
last_registration_response
string

SIP response from the last registration attempt.

Example:

"200 OK"

sip_registration_details
object

Detailed registration information reported by the registrar. The populated fields depend on credential_type.