Get Brand SMS OTP Status
Query the status of an SMS OTP (One-Time Password) for Sole Proprietor brand verification.
This endpoint allows you to check the delivery and verification status of an OTP sent during the Sole Proprietor brand verification process. You can query by either:
referenceId- The reference ID returned when the OTP was initially triggeredbrandId- Query parameter for portal users to look up OTP status by Brand ID
The response includes delivery status, verification dates, and detailed delivery information.
GET
/
10dlc
/
brand
/
smsOtp
/
{referenceId}
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const response = await client.messaging10dlc.brand.getSMSOtpByReference('OTP4B2001');
console.log(response.brandId);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
response = client.messaging_10dlc.brand.get_sms_otp_by_reference(
reference_id="OTP4B2001",
)
print(response.brand_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"),
)
response, err := client.Messaging10dlc.Brand.GetSMSOtpByReference(
context.TODO(),
"OTP4B2001",
telnyx.Messaging10dlcBrandGetSMSOtpByReferenceParams{},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", response.BrandID)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.messaging10dlc.brand.BrandGetSmsOtpByReferenceParams;
import com.telnyx.sdk.models.messaging10dlc.brand.BrandGetSmsOtpByReferenceResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
BrandGetSmsOtpByReferenceResponse response = client.messaging10dlc().brand().getSmsOtpByReference("OTP4B2001");
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
response = telnyx.messaging_10dlc.brand.get_sms_otp_by_reference("OTP4B2001")
puts(response)<?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 {
$response = $client->messaging10dlc->brand->getSMSOtpByReference(
'OTP4B2001', brandID: 'B123ABC'
);
var_dump($response);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx messaging-10dlc:brand get-sms-otp-by-reference \
--api-key 'My API Key' \
--reference-id OTP4B2001curl --request GET \
--url https://api.telnyx.com/v2/10dlc/brand/smsOtp/{referenceId} \
--header 'Authorization: Bearer <token>'{
"brandId": "B123ABC",
"referenceId": "OTP4B2001",
"mobilePhone": "+11234567890",
"requestDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatus": "DELIVERED_HANDSET",
"verifyDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatusDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatusDetails": "Delivered to handset"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
}
}
]
}Authorizations
Path Parameters
Query Parameters
Response
Successful Response
Status information for an SMS OTP sent during Sole Proprietor brand verification
Was this page helpful?
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const response = await client.messaging10dlc.brand.getSMSOtpByReference('OTP4B2001');
console.log(response.brandId);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
response = client.messaging_10dlc.brand.get_sms_otp_by_reference(
reference_id="OTP4B2001",
)
print(response.brand_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"),
)
response, err := client.Messaging10dlc.Brand.GetSMSOtpByReference(
context.TODO(),
"OTP4B2001",
telnyx.Messaging10dlcBrandGetSMSOtpByReferenceParams{},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", response.BrandID)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.messaging10dlc.brand.BrandGetSmsOtpByReferenceParams;
import com.telnyx.sdk.models.messaging10dlc.brand.BrandGetSmsOtpByReferenceResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
BrandGetSmsOtpByReferenceResponse response = client.messaging10dlc().brand().getSmsOtpByReference("OTP4B2001");
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
response = telnyx.messaging_10dlc.brand.get_sms_otp_by_reference("OTP4B2001")
puts(response)<?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 {
$response = $client->messaging10dlc->brand->getSMSOtpByReference(
'OTP4B2001', brandID: 'B123ABC'
);
var_dump($response);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx messaging-10dlc:brand get-sms-otp-by-reference \
--api-key 'My API Key' \
--reference-id OTP4B2001curl --request GET \
--url https://api.telnyx.com/v2/10dlc/brand/smsOtp/{referenceId} \
--header 'Authorization: Bearer <token>'{
"brandId": "B123ABC",
"referenceId": "OTP4B2001",
"mobilePhone": "+11234567890",
"requestDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatus": "DELIVERED_HANDSET",
"verifyDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatusDate": "2024-12-03T17:12:33.560000+00:00",
"deliveryStatusDetails": "Delivered to handset"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
}
}
]
}