Dev & Engineering ✓ Microsoft · Official azure-content-safetycontent-moderationtypescriptrest-sdkblocklist-managementharm-detection

Azure AI Content Safety for TypeScript

Add text and image harm detection with customizable blocklists to TypeScript applications.

FollowSkills review · FSRS-2.0
Use with care
50/ 100 5-point scale 2.5 / 5
1 2 3 4 5 6
1Trust14 / 25 · 2.8/5

The skill exposes the API key, credential, endpoint, base64 image content, and Blob URL data flows, and its operations are generally scoped to content analysis and blocklists. However, it provides no user-confirmation requirement for creating, modifying, or deleting blocklists, and does not explain sensitive-content privacy, retention, log redaction, access isolation, or recovery. MIT licensing and Microsoft provenance provide limited attribution evidence but do not replace safety controls.

2Reliability7 / 20 · 1.8/5

The examples are mostly internally consistent, correctly identifying ContentSafetyClient as a function and repeatedly using isUnexpected(). However, there are no skill-specific tests, compatibility verification, retry/timeout guidance, input constraints, or diagnostic failure messages; the delete example also omits error checking. Because static review caps this dimension at10, the score remains conservative.

3Adaptability10 / 15 · 3.3/5

The audience, input types, and main operations are reasonably clear, covering text, images, harm categories, and blocklists. Boundaries are incomplete: non-fit cases, regional/network prerequisites, Chinese-language handling, and mainland-China reachability are not stated, and semantic trigger conditions are not precise enough.

4Convention9 / 15 · 3.0/5

The document includes installation, environment variables, authentication, operation examples, types, endpoints, severity levels, and best practices, with MIT, author, and 1.0.0 metadata. It lacks a changelog, explicit maintenance owner and update path, troubleshooting, pinned SDK compatibility guidance, privacy limitations, and FAQs; progressive disclosure is also limited.

5Effectiveness6 / 15 · 2.0/5

The examples cover the core analysis and blocklist tasks, and the moderation helper returns a directly usable structured result. However, executability is not verified, and empty text, oversized input, unsupported image formats, network failures, empty analysis results, and policy differences are not fully handled. The static-review cap is7, so the score is intentionally limited.

6Verifiability4 / 10 · 2.0/5

The skill supplies auditable code, endpoint mappings, type names, and version metadata; the repository also shows generic CI and test infrastructure. There are no skill-specific tests, real execution results, or independent third-party corroboration, and the generic harness files do not establish coverage of this skill's key paths. Because static review caps this dimension at5, no higher score is warranted.

Evidence confidence:Low Reviewed Jul 20, 2026 Reviewed revision 9ccaf7c3704a
Before you use it
  • Do not place CONTENT_SAFETY_KEY in source code, logs, or prompts; prefer managed identity with least-privilege access.
  • Add human confirmation, auditing, and recoverable backups before creating, updating, or deleting production blocklists.
  • Treat user text and images as sensitive data and document Azure region, cross-border transfer, retention, redaction, and access controls.
  • Add real CI/integration tests before adoption to verify SDK compatibility, severity thresholds, empty input, oversized text, image formats, and network failures.
  • Confirm actual reachability of the target Azure service endpoint for the intended user regions, including mainland-China network conditions.
See the full review method →

What does this skill do, and when should you use it?

This skill teaches coding agents how to use the Azure AI Content Safety REST SDK for TypeScript. It covers text and image analysis for hate, sexual, violence, and self-harm categories, with configurable severity output. It also documents creating, updating, listing, and deleting custom text blocklists. It fits TypeScript applications that need moderation guidance for user-generated content.

Installs and configures @azure-rest/ai-content-safety, @azure/identity, and @azure/core-auth; creates the ContentSafetyClient function with an API key or DefaultAzureCredential; calls /text:analyze for text and /image:analyze for Base64 image content or a Blob URL; manages text blocklists and their items; checks category severity and blocklist matches; and uses isUnexpected() for error handling.

  1. A TypeScript community application developer needs to screen user comments for hate, sexual, violent, or self-harm content.
  2. A content-platform engineer needs to analyze uploaded images and choose allow, warn, or block actions from severity results.
  3. An enterprise application developer needs custom blocklists for domain-specific prohibited terms.
  4. An engineering team supporting compliance needs to record moderation decisions, category severity, and blocklist matches.

What are this skill's strengths and limitations?

Pros
  • Covers both text and image moderation.
  • Documents API-key and DefaultAzureCredential authentication.
  • Includes core create, update, list, and delete blocklist examples.
  • Provides guidance on severity thresholds, error handling, and moderation logging.
Limitations
  • Requires an Azure Content Safety endpoint, credentials, and network access.
  • Targets the TypeScript REST SDK and does not provide implementations for other languages.
  • The source does not document pricing, quotas, regional availability, or a complete test suite.
  • The image example reads a local file, so that implementation requires filesystem access.

How do you install this skill?

Run npx skills add microsoft/skills and select this skill in the installation wizard. To use the SDK, run npm install @azure-rest/ai-content-safety @azure/identity @azure/core-auth. Set CONTENT_SAFETY_ENDPOINT and CONTENT_SAFETY_KEY; when using DefaultAzureCredential in production, also set AZURE_TOKEN_CREDENTIALS=prod or a specific credential value.

How do you use this skill?

Give the coding agent a request such as: Use azure-ai-contentsafety-ts to add text moderation for my TypeScript comment pipeline, including severity thresholds, a custom blocklist, and isUnexpected() error handling. The agent should follow the documented REST SDK patterns and handle category analysis and blocklist matches.

FAQ

Does this skill include the Azure service itself?
No. It is a SKILL.md for guiding coding agents through the SDK, and the source requires an existing Azure Content Safety endpoint and credentials.
How should API errors be handled?
Use the SDK's exported isUnexpected() type guard and throw result.body when the result is unexpected.
Can it enforce organization-specific blocked terms?
Yes. The skill shows how to create a blocklist, add items, pass blocklistNames during text analysis, and inspect matches.
Does the source specify usage costs?
No. The supplied materials do not state pricing for Azure Content Safety or for the skill.

More skills from this repository

All from microsoft/agent-skills

Dev & Engineering ✓ Microsoft · Official

Azure AI Content Safety for Java

Helps Java applications detect harmful text and images and manage custom blocklists.

Dev & Engineering ✓ Microsoft · Official

Azure AI Content Safety for Python

Guides Python applications in detecting harmful text and images and enforcing custom blocklists.

Dev & Engineering ✓ Microsoft · Official

Azure Identity for TypeScript

Configure secure, flexible Microsoft Entra ID authentication for TypeScript Azure applications.

Dev & Engineering ✓ Microsoft · Official

Azure Blob Storage for TypeScript

A practical guide for uploading, downloading, and managing Azure Blob Storage from TypeScript and JavaScript applications.

Dev & Engineering ✓ Microsoft · Official

Azure Document Intelligence for TypeScript

Extract document text, tables, and structured fields in TypeScript applications.

Dev & Engineering ✓ Microsoft · Official

Azure Translation for TypeScript

Build TypeScript applications for text translation, transliteration, language detection, and document translation.

Dev & Engineering ✓ Microsoft · Official

Azure AI Search for TypeScript

Build TypeScript search apps with vector, hybrid, and semantic retrieval patterns.

Dev & Engineering ✓ Microsoft · Official

Azure AI Projects for TypeScript

Practical TypeScript guidance for building Azure AI Foundry applications with project clients, agents, tools, and evaluations.

Dev & Engineering ✓ Microsoft · Official

MCP Server Development Guide

A practical guide to building clear, testable MCP servers that let LLMs work with external APIs.

Dev & Engineering ✓ Microsoft · Official

Azure Queue Storage TypeScript Skill

Build Azure Queue Storage workers that send, receive, inspect, and manage messages in TypeScript or JavaScript.

Dev & Engineering ✓ Microsoft · Official

Azure App Configuration for TypeScript

Build TypeScript apps with centralized settings, feature flags, and runtime configuration refresh.

Dev & Engineering ✓ Microsoft · Official

Azure Key Vault Secrets for TypeScript

Securely store and retrieve application secrets in Azure Key Vault while managing key lifecycles from Node.js.

Dev & Engineering ✓ Microsoft · Official

Azure Playwright Cloud Testing

Scale TypeScript Playwright tests on Azure-hosted browsers and publish results.

Dev & Engineering ✓ Microsoft · Official

Azure Cosmos DB TypeScript Skill

Gives TypeScript and JavaScript coding agents practical Cosmos DB data-access patterns.

Dev & Engineering ✓ Microsoft · Official

Azure Event Hubs TypeScript Skill

Build TypeScript event-streaming applications with batching, partition-aware consumers, checkpointing, and Azure identity authentication.

Dev & Engineering ✓ Microsoft · Official

Azure Service Bus for TypeScript

Build enterprise messaging workflows with Azure Service Bus.

Dev & Engineering ✓ Microsoft · Official

Typed Zustand Store Patterns

Build predictable, reactive Zustand stores with typed state, actions, and selective subscriptions.

Dev & Engineering ✓ Microsoft · Official

Azure PostgreSQL TypeScript Connector

A practical pg-based guide for secure, pooled Azure PostgreSQL access in Node.js and TypeScript.

Dev & Engineering ✓ Microsoft · Official

Azure File Share TypeScript Skill

Guides coding agents through Azure SMB file-share operations in TypeScript.

Dev & Engineering ✓ Microsoft · Official

Azure Web PubSub Real-Time Messaging

Build TypeScript WebSocket messaging, group communication, and live notification features with Azure Web PubSub.

Related skills