Skip to main content
GET
/
moderation
/
keywords
List keywords
curl --request GET \
  --url https://{appId}.api-{region}.cometchat.io/v3/moderation/keywords
import requests

url = "https://{appId}.api-{region}.cometchat.io/v3/moderation/keywords"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://{appId}.api-{region}.cometchat.io/v3/moderation/keywords', 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://{appId}.api-{region}.cometchat.io/v3/moderation/keywords",
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://{appId}.api-{region}.cometchat.io/v3/moderation/keywords"

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://{appId}.api-{region}.cometchat.io/v3/moderation/keywords")
.asString();
require 'uri'
require 'net/http'

url = URI("https://{appId}.api-{region}.cometchat.io/v3/moderation/keywords")

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
{
  "data": [
    {
      "_id": "66857afdb4bf371ddfba853b",
      "id": "profane-word-list-1",
      "appId": "253179cf5f665257",
      "name": "profane word list",
      "description": "Profane word list",
      "category": "word",
      "isCSV": true,
      "searchTerms": [
        "\"a\"",
        "\"b\"",
        "\"c\""
      ],
      "createdAt": 1720023805,
      "updatedAt": 1720023805,
      "revisionId": "253179cf5f665257_profane-word-list-1_1",
      "active": true,
      "__v": 0
    },
    {
      "_id": "666c01eccfe97336757fb611",
      "id": "profanity-list",
      "name": "Profane Words",
      "category": "word",
      "isCSV": false,
      "searchTerms": [
        "fuck",
        "nigger",
        "fuck",
        "nigger",
        "wanker",
        "cunt",
        "damn",
        "shit",
        "fag",
        "shithead",
        "jizz",
        "hellbitch",
        "retard",
        "cocksucker",
        "cock",
        "kill",
        "cunt",
        "kike",
        "twat",
        "bastard",
        "death",
        "asshole",
        "wop",
        "scumbag",
        "penis",
        "murder",
        "dick",
        "gook",
        "vagina",
        "rape",
        "bastard",
        "spic",
        "spunk",
        "beat"
      ],
      "createdAt": 1718354412,
      "updatedAt": 1718354412,
      "revisionId": "253157108b5294c4_profanity-list_1",
      "active": true,
      "__v": 0,
      "default": true,
      "appId": "default"
    }
  ],
  "meta": {
    "current": {
      "limit": 10,
      "count": 2
    }
  }
}

Response

200 - application/json

List Keywords

data
object
meta
object