$npx skillfedfor your agent

azure-ai-contentsafety

Microsoft Azure AI Content Safety Client Library for Python

With conditionsPyPI Artificial IntelligenceReleased Dec 20231.1M downloads / moMIT LicensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — azure_ai_contentsafety-1.0.0-py3-none-any.whl
v1.0.0 · released 2023-12-12 · Python >=3.7 · 3 runtime deps: isodate, azure-core, typing-extensions

Yes, if you need content moderation and are already using Azure. The package is stable (1.0.0), actively maintained, has no known vulnerabilities, and integrates cleanly with Azure authentication patterns. However, you must have an Azure subscription and Content Safety resource; the client library alone does not provide moderation—it calls a cloud service. Evaluate Azure's pricing and API quotas for your use case before committing.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires an active Azure AI Content Safety resource and API key or Entra ID credentials; the service is cloud-hosted and cannot be used offline.
  • Low install friction with a pure-Python wheel distribution.
  • Actively maintained as of 2026-08-14 with no known vulnerabilities.

License · maintenance · safety

MIT License (permissive) — MIT License permits unrestricted use, modification, and distribution with minimal restrictions, making it suitable for both open-source and commercial projects.

last release 2023-12-12 (976 days) · last repo commit 2026-08-14 · 5,588 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 1,053,001 downloads/mo, #4,437 on PyPI

Verify before relying

pip install azure-ai-contentsafety

from azure.core.credentials import AzureKeyCredential
from azure.ai.contentsafety import ContentSafetyClient

endpoint = "https://<subdomain>.cognitiveservices.azure.com/"
credential = AzureKeyCredential("<api_key>")
client = ContentSafetyClient(endpoint, credential)
result = client.analyze_text(text="sample text to analyze")
  • Whether the service requires an active Azure subscription and incurs per-request costs beyond the client library itself.
  • Performance characteristics and latency expectations for text and image analysis at scale.
  • Whether custom blocklists persist across sessions or require reinitialization.
Same gist for agents: .md · .json

What it is and what it does

This package is a Python client for Azure AI Content Safety, a cloud-hosted service that classifies text and images for harmful content. It provides two main clients—ContentSafetyClient for analyzing content and BlocklistClient for managing custom term blocklists—and wraps REST calls to Azure's moderation APIs. The service recognizes four harm categories (hate, sexual, violence, self-harm) and returns severity ratings on a 0–7 scale; text supports full granularity while images return mapped levels (0, 2, 4, 6).

You authenticate using either an API key or Microsoft Entra ID credentials, then call analyze methods to scan text or image URLs. The package handles request serialization and response parsing, abstracting away HTTP details. It's designed for applications that need to filter user-generated or AI-generated content at scale—e.g., moderation workflows, safety compliance, or content filtering in multi-tenant platforms. The blocklist APIs let you supplement the default classifiers with domain-specific terms, useful when the built-in categories don't capture your use case.

Use it for

  • Moderate user-generated comments or posts in social platforms or forums before publishing.
  • Screen AI-generated text or images for harmful output in chatbot or generative AI applications.
  • Build compliance workflows that flag content for manual review based on severity thresholds.
  • Create custom blocklists for industry-specific harmful terms (e.g., medical misinformation, financial scams).
  • Analyze bulk content archives to identify and categorize harmful material across historical data.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need content moderation and are already using Azure.

The package is stable (1.0.0), actively maintained, has no known vulnerabilities, and integrates cleanly with Azure authentication patterns. However, you must have an Azure subscription and Content Safety resource; the client library alone does not provide moderation—it calls a cloud service. Evaluate Azure's pricing and API quotas for your use case before committing.

Install

azure-ai-contentsafety on PyPI

Before you install

Low install friction with a pure-Python wheel distribution. Actively maintained as of 2026-08-14 with no known vulnerabilities. Depends on three stable, widely-used packages: azure-core, isodate, and typing-extensions.

Requires an active Azure AI Content Safety resource and API key or Entra ID credentials; the service is cloud-hosted and cannot be used offline.

License in practice

MIT License permits unrestricted use, modification, and distribution with minimal restrictions, making it suitable for both open-source and commercial projects.

Quickstart

pip install azure-ai-contentsafety

from azure.core.credentials import AzureKeyCredential
from azure.ai.contentsafety import ContentSafetyClient

endpoint = "https://<subdomain>.cognitiveservices.azure.com/"
credential = AzureKeyCredential("<api_key>")
client = ContentSafetyClient(endpoint, credential)
result = client.analyze_text(text="sample text to analyze")

Verify before relying

  • Whether the service requires an active Azure subscription and incurs per-request costs beyond the client library itself.
  • Performance characteristics and latency expectations for text and image analysis at scale.
  • Whether custom blocklists persist across sessions or require reinitialization.

Package facts

LicenseMIT License permissive
Python supportSupports the current Python release >=3.7
Install frictionLow. Pure-Python wheel
Runtime dependencies
3 packages
isodateazure-coretyping-extensions
MaintenanceActively maintained 976 days since the last release
Last repo commit
First released
Downloads1,053,001 / month, #4,437 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableLicense :: OSI Approved :: MIT LicenseProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

Evidence: azure_ai_contentsafety-1.0.0-py3-none-any.whl

Tags

Capabilities
content moderation apitext and image safety detectionharmful content classificationazure content safetycontent blocklist managementhate violence sexual content detectionai content moderation
Topics
content-moderationazure-sdkharm-detection
PyPI keywords
azureazure sdk

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “content moderation api”

Give your agent the search over MCP, or paste the wish link into any chat.

More Artificial Intelligence packages

litellm With conditions
PyPI · Artificial Intelligence · released Aug 2026

LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.

Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.

MITcompiled wheel
682.8Mdownloads / mo
huggingface-hub Worth it
PyPI · Artificial Intelligence · released Aug 2026

Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.

Install it if you work with Hugging Face Hub models or datasets.

Apache-2.0pure Python · 3.10.0+
442.4Mdownloads / mo
langchain Worth it
PyPI · Python Modules · released Aug 2026

LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.

MITpure Python
315.4Mdownloads / mo
hf-xet With conditions
PyPI · Artificial Intelligence · released Aug 2026

hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.

Apache-2.0compiled wheel · 3.8+
258.4Mdownloads / mo
tokenizers Worth it
PyPI · Artificial Intelligence · released Apr 2026

Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.

Apache-2.0compiled wheel · 3.10+
222.9Mdownloads / mo
transformers Worth it
PyPI · Artificial Intelligence · released Aug 2026

Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.

Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.

permissive licensepure Python · 3.10.0+
186.6Mdownloads / mo

See also azure-ai-textanalytics · azure-ai-documentintelligence · azure-ai-vision-imageanalysis · azure-ai-formrecognizer · azure-ai-language-questionanswering · azure-ai-evaluation · azure-ai-inference · azure-ai-translation-text · azure-ai-language-conversations · detoxify

Further reading