{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-C7AB61E0-9AD9-4512-ACA8-EDA284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": ["+1111111111", "+2222222222"],
"BlockedContacts": ["+3333333333"],
"KeywordFilter": "\"CustomKeywords\":[\"inappropriate\",\"banned\"],\"SystemKeywords\":{\"Profanity\":[\"word1\",\"word2\"],\"Violence\":[\"threat1\"]},\"SeverityMap\":{\"Word1\":\"HIGH\",\"Inappropriate\":\"MEDIUM\"}",
"NotificationPhones": ["+9999999999"],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}curl -X POST https://api.telegent.com/v1.0/subscribers/message-filter/update \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-C7AB61E0-9AD9-4512-ACA8-EDA284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": ["+1111111111", "+2222222222"],
"BlockedContacts": ["+3333333333"],
"NotificationPhones": ["+9999999999"],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}'import requests
url = "https://api.telegent.com/v1.0/subscribers/message-filter/update"
payload = {
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "<string>",
"Phone": "<string>",
"AllowedContacts": ["<string>"],
"BlockedContacts": ["<string>"],
"KeywordFilter": "<string>",
"NotificationPhones": ["<string>"],
"ApplyToOutbound": True,
"ApplyToInbound": True,
"BlockUnknownNumbers": True,
"BlockLinks": True,
"BlockMedia": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
FilterId: 'MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1',
SubscriberId: '<string>',
Phone: '<string>',
AllowedContacts: ['<string>'],
BlockedContacts: ['<string>'],
KeywordFilter: '<string>',
NotificationPhones: ['<string>'],
ApplyToOutbound: true,
ApplyToInbound: true,
BlockUnknownNumbers: true,
BlockLinks: true,
BlockMedia: true
})
};
fetch('https://api.telegent.com/v1.0/subscribers/message-filter/update', 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/subscribers/message-filter/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'FilterId' => 'MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1',
'SubscriberId' => '<string>',
'Phone' => '<string>',
'AllowedContacts' => [
'<string>'
],
'BlockedContacts' => [
'<string>'
],
'KeywordFilter' => '<string>',
'NotificationPhones' => [
'<string>'
],
'ApplyToOutbound' => true,
'ApplyToInbound' => true,
'BlockUnknownNumbers' => true,
'BlockLinks' => true,
'BlockMedia' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/subscribers/message-filter/update"
payload := strings.NewReader("{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.telegent.com/v1.0/subscribers/message-filter/update")
.header("Content-Type", "application/json")
.body("{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/subscribers/message-filter/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}"
response = http.request(request)
puts response.read_body{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-A1AB23C0-....-....-....-EBE284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": [
"+1111111111",
"+2222222222"
],
"BlockedContacts": [
"+3333333333"
],
"KeywordFilter": "\"CustomKeywords\":[\"inappropriate\",\"banned\"],\"SystemKeywords\":{\"Profanity\":[\"word1\",\"word2\"],\"Violence\":[\"threat1\"]},\"SeverityMap\":{\"Word1\":\"HIGH\",\"Inappropriate\":\"MEDIUM\"}",
"NotificationPhones": [
"+9999999999"
],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}Update Message Filter
Modify an existing message filter without deleting and recreating it.
Prerequisites:
- Bearer token —
POST /v1.0/oauth2/tokens - An existing
MessageFilterId(MFID-) — find one withGET /v1.0/subscribers/message-filter
What this does: Replaces the configuration of the specified filter. Use this to switch modes (e.g., MONITOR_ONLY → ACTIVE to start enforcing rules), update contact lists, adjust keyword settings, or toggle link/media/unknown-number restrictions. Changes take effect immediately.
Next steps:
- Verify the change —
GET /v1.0/subscribers/message-filter - Pause without deleting — set
FilterModetoINACTIVEand call this endpoint again - Permanently remove —
POST /v1.0/subscribers/message-filter/delete
{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-C7AB61E0-9AD9-4512-ACA8-EDA284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": ["+1111111111", "+2222222222"],
"BlockedContacts": ["+3333333333"],
"KeywordFilter": "\"CustomKeywords\":[\"inappropriate\",\"banned\"],\"SystemKeywords\":{\"Profanity\":[\"word1\",\"word2\"],\"Violence\":[\"threat1\"]},\"SeverityMap\":{\"Word1\":\"HIGH\",\"Inappropriate\":\"MEDIUM\"}",
"NotificationPhones": ["+9999999999"],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}curl -X POST https://api.telegent.com/v1.0/subscribers/message-filter/update \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-C7AB61E0-9AD9-4512-ACA8-EDA284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": ["+1111111111", "+2222222222"],
"BlockedContacts": ["+3333333333"],
"NotificationPhones": ["+9999999999"],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}'import requests
url = "https://api.telegent.com/v1.0/subscribers/message-filter/update"
payload = {
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "<string>",
"Phone": "<string>",
"AllowedContacts": ["<string>"],
"BlockedContacts": ["<string>"],
"KeywordFilter": "<string>",
"NotificationPhones": ["<string>"],
"ApplyToOutbound": True,
"ApplyToInbound": True,
"BlockUnknownNumbers": True,
"BlockLinks": True,
"BlockMedia": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
FilterId: 'MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1',
SubscriberId: '<string>',
Phone: '<string>',
AllowedContacts: ['<string>'],
BlockedContacts: ['<string>'],
KeywordFilter: '<string>',
NotificationPhones: ['<string>'],
ApplyToOutbound: true,
ApplyToInbound: true,
BlockUnknownNumbers: true,
BlockLinks: true,
BlockMedia: true
})
};
fetch('https://api.telegent.com/v1.0/subscribers/message-filter/update', 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/subscribers/message-filter/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'FilterId' => 'MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1',
'SubscriberId' => '<string>',
'Phone' => '<string>',
'AllowedContacts' => [
'<string>'
],
'BlockedContacts' => [
'<string>'
],
'KeywordFilter' => '<string>',
'NotificationPhones' => [
'<string>'
],
'ApplyToOutbound' => true,
'ApplyToInbound' => true,
'BlockUnknownNumbers' => true,
'BlockLinks' => true,
'BlockMedia' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/subscribers/message-filter/update"
payload := strings.NewReader("{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.telegent.com/v1.0/subscribers/message-filter/update")
.header("Content-Type", "application/json")
.body("{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/subscribers/message-filter/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"FilterId\": \"MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1\",\n \"SubscriberId\": \"<string>\",\n \"Phone\": \"<string>\",\n \"AllowedContacts\": [\n \"<string>\"\n ],\n \"BlockedContacts\": [\n \"<string>\"\n ],\n \"KeywordFilter\": \"<string>\",\n \"NotificationPhones\": [\n \"<string>\"\n ],\n \"ApplyToOutbound\": true,\n \"ApplyToInbound\": true,\n \"BlockUnknownNumbers\": true,\n \"BlockLinks\": true,\n \"BlockMedia\": true\n}"
response = http.request(request)
puts response.read_body{
"FilterId": "MFID-7435d672-a2d0-451e-ab62-45499f5bc7a1",
"SubscriberId": "SID-A1AB23C0-....-....-....-EBE284131441",
"Phone": "+1234567890",
"FilterMode": "MONITOR_ONLY",
"AllowedContacts": [
"+1111111111",
"+2222222222"
],
"BlockedContacts": [
"+3333333333"
],
"KeywordFilter": "\"CustomKeywords\":[\"inappropriate\",\"banned\"],\"SystemKeywords\":{\"Profanity\":[\"word1\",\"word2\"],\"Violence\":[\"threat1\"]},\"SeverityMap\":{\"Word1\":\"HIGH\",\"Inappropriate\":\"MEDIUM\"}",
"NotificationPhones": [
"+9999999999"
],
"ApplyToOutbound": true,
"ApplyToInbound": true,
"BlockUnknownNumbers": true,
"BlockLinks": true,
"BlockMedia": true
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}Body
Controls how the filter behaves. ACTIVE: rules are enforced — messages that violate the filter are blocked. MONITOR_ONLY: violations are logged and notifications are sent, but messages are still delivered. INACTIVE: filter is paused and has no effect.
ACTIVE, MONITOR_ONLY, INACTIVE Stringified JSON defining keyword rules. Structure: {"CustomKeywords":[...],"SystemKeywords":{"Profanity":[...],"Violence":[...]},"SeverityMap":{"keyword":"HIGH|MEDIUM|LOW"}}. CustomKeywords are user-added words; SystemKeywords are platform-provided categories; SeverityMap assigns a risk level to each term.
Response
Message Filter Updated
The response is of type object.