Returns the account-owned suppression identified by ID. Cross-account lookups and malformed IDs return 404 without exposing another account’s data.
GET
/
email_blocks
/
{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 EmailBlock = await client.emailBlocks.retrieve('id');console.log(EmailBlock.data);
import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
email_block = client.email_blocks.retrieve(
"id",
)
print(email_block.data)
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
var response = client.emailBlocks().retrieve("id");
}
}
require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
email_block = telnyx.email_blocks.retrieve("id")
puts(email_block)
<?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 {
$email_block = $client->emailBlocks->retrieve(
'id',
);
var_dump($email_block);
} catch (APIException $e) {
echo $e->getMessage();
}
telnyx email-blocks retrieve \
--api-key 'My API Key' \
--id id
Telnyx API key supplied as Authorization: Bearer <token>. In production, auth may be validated by the API gateway and forwarded via Telnyx auth headers.
Suppression record. Schema fields hidden by the view:
account_id, bounce_category, dsn_code, meta.
Show child attributes
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 EmailBlock = await client.emailBlocks.retrieve('id');console.log(EmailBlock.data);
import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
email_block = client.email_blocks.retrieve(
"id",
)
print(email_block.data)
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
var response = client.emailBlocks().retrieve("id");
}
}
require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
email_block = telnyx.email_blocks.retrieve("id")
puts(email_block)
<?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 {
$email_block = $client->emailBlocks->retrieve(
'id',
);
var_dump($email_block);
} catch (APIException $e) {
echo $e->getMessage();
}
telnyx email-blocks retrieve \
--api-key 'My API Key' \
--id id