Skip to main content
DELETE
/
access_ip_address
/
{access_ip_address_id}
JavaScript
import Telnyx from 'telnyx';

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

const accessIPAddressResponse = await client.accessIPAddress.delete('access_ip_address_id');

console.log(accessIPAddressResponse.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
)
access_ip_address_response = client.access_ip_address.delete(
    "access_ip_address_id",
)
print(access_ip_address_response.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"),
	)
	accessIPAddressResponse, err := client.AccessIPAddress.Delete(context.TODO(), "access_ip_address_id")
	if err != nil {
		panic(err.Error())
	}
	fmt.Printf("%+v\n", accessIPAddressResponse.ID)
}
package com.telnyx.sdk.example;

import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.accessipaddress.AccessIpAddressDeleteParams;
import com.telnyx.sdk.models.accessipaddress.AccessIpAddressResponse;

public final class Main {
    private Main() {}

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

        AccessIpAddressResponse accessIpAddressResponse = client.accessIpAddress().delete("access_ip_address_id");
    }
}
require "telnyx"

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

access_ip_address_response = telnyx.access_ip_address.delete("access_ip_address_id")

puts(access_ip_address_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 {
  $accessIPAddressResponse = $client->accessIPAddress->delete(
    'access_ip_address_id'
  );

  var_dump($accessIPAddressResponse);
} catch (APIException $e) {
  echo $e->getMessage();
}
telnyx access-ip-address delete \
  --api-key 'My API Key' \
  --access-ip-address-id access_ip_address_id
curl --request DELETE \
  --url https://api.telnyx.com/v2/access_ip_address/{access_ip_address_id} \
  --header 'Authorization: Bearer <token>'
{
  "id": "<string>",
  "ip_address": "<string>",
  "source": "<string>",
  "user_id": "<string>",
  "description": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}
{
  "errors": [
    {
      "code": "<string>",
      "title": "<string>",
      "detail": "<string>",
      "source": {
        "pointer": "<string>",
        "parameter": "<string>"
      },
      "meta": {}
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Path Parameters

access_ip_address_id
string
required

Unique identifier of the access ip address.

Response

Successful Response

id
string
required
ip_address
string
required
source
string
required
status
enum<string>
required

An enumeration.

Available options:
pending,
added
user_id
string
required
description
string
created_at
string<date-time>
updated_at
string<date-time>