cURL
curl -X GET 'https://api.telegent.com/v1.0/numbers/e911address?PhoneNumber=%2B12345678901&AccountId=AID-xxxx' \
-H 'Authorization: Bearer YOUR_TOKEN'import requests
url = "https://api.telegent.com/v1.0/numbers/e911address"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.telegent.com/v1.0/numbers/e911address', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.telegent.com/v1.0/numbers/e911address",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/numbers/e911address"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.telegent.com/v1.0/numbers/e911address")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/numbers/e911address")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"PhoneNumber": "+13852217924",
"AccountId": "AID-eab92510-1040-45a5-bb9c-xxxx",
"E911Address": {
"Street1": "2701 N THANKSGIVING WAY",
"Street2": null,
"City": "LEHI",
"State": "UT",
"Zip": "84048-6330"
}
}{
"StatusCode": 400,
"Message": "Bad request: one or more required fields are missing or contain an invalid value."
}{
"StatusCode": 401,
"Message": "Unauthorized: Bearer token is missing, expired, or invalid. Re-authenticate via POST /v1.0/oauth2/tokens."
}{
"StatusCode": 403,
"Message": "Forbidden: your token does not have permission to access this resource. Check the ApiEndpoint scope."
}{
"StatusCode": 404,
"Message": "Not found: the requested resource does not exist or belongs to a different account."
}{
"StatusCode": 405,
"Message": "Method not allowed: verify the HTTP method required for this endpoint."
}{
"StatusCode": 408,
"Message": "Request timeout: the server did not receive a complete request within the allowed time. Retry with exponential backoff."
}{
"StatusCode": 429,
"Message": "Too many requests: rate limit exceeded. Slow your request cadence and retry after a short delay."
}{
"StatusCode": 500,
"Message": "Internal server error: an unexpected error occurred. If the problem persists contact support@telegent.com."
}{
"StatusCode": 503,
"Message": "Service unavailable: the API is temporarily unavailable. Retry after a short delay."
}{
"StatusCode": 504,
"Message": "Gateway timeout: an upstream service did not respond in time. Retry with exponential backoff."
}Numbers
Numbers - Get E911 Address
Retrieve the E911 emergency address registered to a specific phone number. Returns the street address on file that will be dispatched to emergency services when a 911 call is placed from this number.
What this does: Looks up the E911 address associated with the given phone number on your account.
Next steps:
- Update an E911 address —
POST /v1.0/numbers/e911address/update
GET
/
v1.0
/
numbers
/
e911address
cURL
curl -X GET 'https://api.telegent.com/v1.0/numbers/e911address?PhoneNumber=%2B12345678901&AccountId=AID-xxxx' \
-H 'Authorization: Bearer YOUR_TOKEN'import requests
url = "https://api.telegent.com/v1.0/numbers/e911address"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.telegent.com/v1.0/numbers/e911address', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.telegent.com/v1.0/numbers/e911address",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/numbers/e911address"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.telegent.com/v1.0/numbers/e911address")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/numbers/e911address")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"PhoneNumber": "+13852217924",
"AccountId": "AID-eab92510-1040-45a5-bb9c-xxxx",
"E911Address": {
"Street1": "2701 N THANKSGIVING WAY",
"Street2": null,
"City": "LEHI",
"State": "UT",
"Zip": "84048-6330"
}
}{
"StatusCode": 400,
"Message": "Bad request: one or more required fields are missing or contain an invalid value."
}{
"StatusCode": 401,
"Message": "Unauthorized: Bearer token is missing, expired, or invalid. Re-authenticate via POST /v1.0/oauth2/tokens."
}{
"StatusCode": 403,
"Message": "Forbidden: your token does not have permission to access this resource. Check the ApiEndpoint scope."
}{
"StatusCode": 404,
"Message": "Not found: the requested resource does not exist or belongs to a different account."
}{
"StatusCode": 405,
"Message": "Method not allowed: verify the HTTP method required for this endpoint."
}{
"StatusCode": 408,
"Message": "Request timeout: the server did not receive a complete request within the allowed time. Retry with exponential backoff."
}{
"StatusCode": 429,
"Message": "Too many requests: rate limit exceeded. Slow your request cadence and retry after a short delay."
}{
"StatusCode": 500,
"Message": "Internal server error: an unexpected error occurred. If the problem persists contact support@telegent.com."
}{
"StatusCode": 503,
"Message": "Service unavailable: the API is temporarily unavailable. Retry after a short delay."
}{
"StatusCode": 504,
"Message": "Gateway timeout: an upstream service did not respond in time. Retry with exponential backoff."
}⌘I