The Extract Inappropriate Words API is designed to identify, analyze, and censor offensive or inappropriate language within texts. Its main purpose is to ensure safer, more respectful, and appropriate digital environments for all types of audiences, especially on platforms where users generate content, such as social networks, forums, chats, video games, or educational applications.
This API works by performing a semantic and contextual analysis of the text. When a string of content is sent, the system examines it word by word, detecting matches with an updated database of offensive expressions in different languages and spelling variations. The result includes detailed information, such as the total number of inappropriate words found, their exact position within the text, any spelling deviations, and the severity level of each term.
In addition to analysis, the API offers automatic censorship functionality by generating a field called censored_content, which replaces detected words with symbols (e.g., “****”). This allows developers to easily integrate the filtered version of the text without disrupting the flow of communication or exposing sensitive content.
Another advantage is customization: it is possible to adapt the level of sensitivity according to the context or target audience, expanding or reducing the list of censored words. It can also be integrated with automatic moderation systems, administration panels, or artificial intelligence for safe language learning.
In short, this API not only acts as a profanity filter, but as a complete linguistic moderation system. Its implementation contributes to improving digital coexistence, reducing online harassment, and protecting the reputation of the platforms that use it, offering a balance between freedom of expression and respectful communication.
Detects and censors offensive language in texts, returning detailed analysis with the number, position, and replacement of inappropriate words for automatic moderation.
Censure - Endpoint Features
| Object | Description |
|---|---|
Request Body |
[Required] Json |
{"content": "shit", "bad_words_total": 1, "bad_words_list": [{"original": "shit", "word": "shit", "deviations": 0, "info": 2, "start": 0, "end": 4, "replacedLen": 4}], "censored_content": "****"}
curl --location --request POST 'https://zylalabs.com/api/11026/extract+inappropriate+words+api/20771/censure' --header 'Authorization: Bearer YOUR_API_KEY'
--data-raw 'shit'
| Header | Description |
|---|---|
Authorization
|
[Required] Should be Bearer access_key. See "Your API Access Key" above when you are subscribed. |
No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.
The Censure endpoint returns a JSON object containing the original content, the total number of offensive words detected, a list of those words with their details, and a censored version of the content. This allows developers to understand the extent of inappropriate language and provide a filtered output.
Key fields in the response include `content` (original text), `bad_words_total` (count of offensive words), `bad_words_list` (details of each detected word), and `censored_content` (text with offensive words replaced). These fields provide comprehensive insights for moderation.
The response data is structured as a JSON object. It includes a main object with fields for the original content, total bad words, a list of detected words (with details), and the censored version. This organization facilitates easy parsing and integration into applications.
The Censure endpoint accepts parameters such as the text to be analyzed and optional settings for sensitivity levels. Users can customize their requests by specifying the context or audience to adjust the filtering criteria according to their needs.
Users can utilize the returned data by analyzing the `bad_words_list` to understand which terms were flagged and their severity. The `censored_content` can be directly used to display filtered text, ensuring respectful communication while maintaining context.
Typical use cases include moderating user-generated content on social media, forums, and chat applications, as well as ensuring appropriate language in educational tools and video games. It helps maintain a respectful environment across various platforms.
Data accuracy is maintained through continuous updates to the database of offensive words, which includes various languages and spelling variations. Regular reviews and community feedback help ensure the list remains relevant and effective in detecting inappropriate language.
Standard data patterns include a clear identification of offensive words, their positions within the text, and the severity levels assigned to each term. Users can expect consistent formatting in the response, making it easy to integrate and analyze the results.
To obtain your API key, you first need to sign in to your account and subscribe to the API you want to use. Once subscribed, go to your Profile, open the Subscription section, and select the specific API. Your API key will be available there and can be used to authenticate your requests.
You can’t switch APIs during the free trial. If you subscribe to a different API, your trial will end and the new subscription will start as a paid plan.
If you don’t cancel before the 7th day, your free trial will end automatically and your subscription will switch to a paid plan under the same plan you originally subscribed to, meaning you will be charged and gain access to the API calls included in that plan.
The free trial ends when you reach 50 API requests or after 7 days, whichever comes first.
No, the free trial is available only once, so we recommend using it on the API that interests you the most. Most of our APIs offer a free trial, but some may not include this option.
Yes, we offer a 7-day free trial that allows you to make up to 50 API calls at no cost, so you can test our APIs without any commitment.
Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.
Service Level:
100%
Response Time:
324ms
Service Level:
100%
Response Time:
264ms
Service Level:
100%
Response Time:
5,657ms
Service Level:
100%
Response Time:
332ms
Service Level:
100%
Response Time:
111ms
Service Level:
100%
Response Time:
21ms
Service Level:
100%
Response Time:
10,171ms
Service Level:
100%
Response Time:
1,350ms
Service Level:
100%
Response Time:
2,201ms
Service Level:
100%
Response Time:
716ms