---
title: "List moderation policies"
method: GET
path: "/guardrails/policies/moderation"
tags: ["Guardrail Policies"]
---

# List moderation policies

`GET /guardrails/policies/moderation`

## Request

- Base URL: `https://openrouter.ai/api/v1`
- URL: `https://openrouter.ai/api/v1/guardrails/policies/moderation`
- Auth: HTTP bearer

List the moderation policies in a workspace. [Management key](/docs/guides/overview/auth/management-api-keys) required.

## Query parameters

- `offset` integer: Number of records to skip for pagination. When both offset and limit are omitted, the full list is returned
- `limit` integer: Maximum number of records to return (max 100). When both offset and limit are omitted, the full list is returned
- `workspace_id` string, uuid: Workspace the policy belongs to. Required for an organization management key; a workspace-scoped key defaults to its own workspace and gets 403 for any other.

## Response `200`

List of moderation policies

- ListModerationGuardrailPoliciesResponse
  - `data` ModerationGuardrailPolicySummary[], required
    - `api_key_count` integer, required
    - `config` GuardrailModerationPolicyConfig, required
      - `armor` object, nullable
        - `classifier_context` ArmorContext: The Armor context: Claude Code's `classifier_context` (v1), with `auto_mode.{hard_deny,soft_deny,allow}` rules as strings or `{ id, instructions, threshold? }` objects and `auto_mode.environment` entries as `"Name: value"` strings or `{ name, value }` objects. `threshold` applies when Armor evaluates; when the provider evaluates natively (Anthropic dangerous-tool-use beta) rules are judged at the provider's own boundary.
          - `auto_mode` ArmorAutoMode
            - `allow` union[]
              - …
            - `environment` union[]
              - …
            - `hard_deny` union[]
              - …
            - `soft_deny` union[]
              - …
          - `v` 1, required
        - `mode` 'enforce' | 'audit': `enforce` withholds blocked calls; `audit` evaluates and reports the same verdicts without withholding any calls, regardless of `on_error`. Default `enforce`.
        - `on_error` 'log' | 'block': When the classifier cannot answer (timeout, upstream error, context too long) the call is reported `unavailable`; `block` rejects it and `log` releases it. Default `block`.
        - `use_cc_style_default_rules` boolean: Prepend Claude Code's built-in auto-mode rule set (1 hard-deny, 72 soft-deny, 17 allow, 21 environment slots) ahead of every configured rule. Defaults to true on the Anthropic Messages API and false elsewhere.
      - `broadcast_model_armor_flagged_requests` boolean, nullable
      - `content_filter_blocks_requests` boolean
      - `content_filter_builtins` object[], nullable
        - `action` 'redact' | 'block' | 'flag', required
        - `label` string
        - `scan_scope` 'user_only' | 'all_messages'
        - `slug` 'email' | 'phone' | 'ssn' | 'credit-card' | 'ip-address' | 'secrets' | 'person-name' | 'address' | 'regex-prompt-injection', required
      - `content_filter_patterns` string[], nullable
      - `content_filters` object[], nullable
        - `action` 'redact' | 'block' | 'flag', required
        - `label` string, nullable
        - `pattern` string, required
      - `enable_model_armor_injection_protection` boolean, nullable
      - `lakera_injection_protection_mode` 'block' | 'flag' | 'null', nullable
      - `model_armor_injection_confidence_level` 'low' | 'medium' | 'high'
      - `model_armor_injection_protection_mode` 'block' | 'flag' | 'null', nullable
      - `pii_filters` object[], nullable
        - `action` 'redact' | 'block' | 'flag', required
        - `entity_type` string, required
        - `score_threshold` number
      - `platform_image_moderated_providers` string[], nullable
      - `platform_moderated_providers` string[], nullable
    - `id` string, uuid, required: Policy ID
    - `is_legacy_mapped` boolean: Whether the policy is kept in sync with a v1 guardrail
    - `is_workspace_default` boolean
    - `legacy_guardrail_ids` string[]: IDs of the v1 guardrails this policy was migrated from
    - `member_count` integer, required
    - `name` string, required: Policy name
    - `policy_type` 'moderation', required
    - `replaced_legacy_guardrail_ids` string[]: IDs of the v1 guardrails this policy replaced
    - `updated_at` string, nullable, required
  - `total_count` integer, required: Total number of policies

## Other responses

- `400`: Bad Request - Invalid request parameters or malformed input
- `401`: Unauthorized - Authentication required or invalid credentials
- `403`: Forbidden - Authentication successful but insufficient permissions
- `404`: Not Found - Resource does not exist
- `500`: Internal Server Error - Unexpected server error

## Changes

- **2026-11-11** `5aee117d1dca`: 1 info
  - the `query` request parameter `workspace_id` became optional
- **2026-11-06** `02121928ccaf`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/openrouterteam/apis/openrouter-api/changes/guardrails/policies/moderation/get.md)

---

[API](https://skmtc.dev/openrouterteam/apis/openrouter-api.md) - [All operations](https://skmtc.dev/openrouterteam/apis/openrouter-api/llms.txt) - [OpenAPI document](https://skmtc.dev/openrouterteam/apis/openrouter-api/revisions/f797e38f23b4?raw)
