Stream Feeds

Integrating moderation in Activity Feeds is straightforward and requires minimal code changes. Once you configure a moderation policy, Stream automatically moderates activities and comments as they are created or updated. This guide walks you through setting up moderation and monitoring flagged content.

Configure Moderation Policy

A moderation policy defines how content should be moderated. You can configure your policy through the dashboard or via the API. Activity and comment custom is included in the moderation payload, so content custom-property rules match Feeds the same way they match Chat.

For Feeds v3, Stream uses a hierarchical config key lookup to find the right policy:

  1. feeds:{group_id}:{feed_id} -- most specific (individual feed)
  2. feeds:{group_id} -- feed group level
  3. feeds -- app-wide default

To set up an app-wide policy for all feeds content:

await client.Moderation.UpsertConfigAsync(new UpsertConfigRequest
{
    Key = "feeds",
    AiTextConfig = new AITextConfig
    {
        Rules = new List<AITextRule>
        {
            new() { Label = "SPAM", Action = "flag" },
            new() { Label = "HARASSMENT", Action = "remove" },
        },
    },
    BlockListConfig = new BlockListConfig
    {
        Rules = new List<BlockListRule>
        {
            new() { Name = "profanity_en", Action = "remove" },
        },
    },
    AiImageConfig = new AIImageConfig
    {
        Rules = new List<AIImageRule>
        {
            new() { Label = "Non-Explicit Nudity", Action = "flag" },
        },
    },
});

You can also configure policies per feed group (e.g., feeds:user for user feeds, feeds:timeline for timeline feeds) to apply different moderation rules to different feed types.

Auto-Moderation on Activities

Once the policy is configured, activities are automatically moderated when created or updated. No additional code is needed -- just add activities as you normally would.

Server-side requests skip moderation by default. Set force_moderation: true to moderate an activity or comment created from your backend.

Warning:

force_moderation is server-side only and ignored when sent from a client-side SDK.

When an activity contains content that violates your policy, Stream takes the configured action:

  • remove -- the activity is removed and appears in the review queue
  • flag -- the activity is published but flagged for review
  • bounce -- the activity is rejected entirely and not saved
  • shadow_block -- the activity is hidden from other users but visible to the creator

The API response includes a moderation object with details about the action taken:

{
  "id": "activity-123",
  "actor": "user-456",
  "verb": "post",
  "object": "...",
  "moderation": {
    "status": "complete",
    "recommended_action": "remove",
    "text_harms": ["harassment"],
    "blocklists_matched": ["profanity_en"]
  }
}
Field Type Description
status string Moderation status: complete or partial (if async checks pending)
recommended_action string Action taken: keep, flag, remove, bounce, shadow_block
text_harms string[] Labels from AI text analysis (e.g., ["harassment", "spam"])
image_harms string[] Labels from image moderation (e.g., ["nudity"])
blocklists_matched string[] Blocklists that matched (e.g., ["profanity_en"])

Auto-Moderation on Comments

Comments are also automatically moderated using the same policy. When a user adds a comment, Stream checks the content and applies the configured action.

If a comment is blocked, it will not be visible to other users. The response will indicate the moderation action:

{
  "id": "comment-789",
  "text": "...",
  "moderation": {
    "status": "complete",
    "recommended_action": "remove",
    "text_harms": ["toxicity"]
  }
}
Info:

Reactions (likes, etc.) are not auto-moderated, only activities and comments.

Monitoring Moderated Content

You can monitor all flagged or blocked content from the Stream dashboard. The dashboard provides three review queues:

Users Queue

Contains all users who were flagged or who have flagged content. Actions available:

  • Mark Reviewed -- acknowledge the user has been assessed
  • Permanently Ban User -- restrict the user from the platform
  • Temporarily Ban User -- restrict access for a specified period
  • Delete User -- remove the user account
  • Delete All Content -- remove all content from the user

Text Queue

Contains flagged or blocked text content. Actions available:

  • Mark Reviewed -- content doesn't require further action
  • Delete -- remove the content from the platform
  • Unblock -- restore content that was incorrectly blocked

Media Queue

Contains flagged or blocked images and videos. Same actions as the Text Queue are available.

User-Driven Actions

In addition to automated moderation, users can flag content or other users for review.

Flag a User

await client.Moderation.FlagAsync(new FlagRequest
{
    EntityType = "stream:user",
    EntityID = targetUserId,
    Reason = "harassment",
    UserID = reportingUserId,
});

Ban a User

await client.Moderation.BanAsync(new BanRequest
{
    TargetUserID = targetUserId,
    BannedByID = moderatorId,
    Reason = "Repeated violations",
});

Banned users are prevented from reading feeds and creating activities or reactions.

Next Steps

Add Chat to my app: getstream.io/SKILL.md

The fastest way to build with Stream. Start a new project or improve an existing one. Full CLI and documentation integration out of the box.


Ask your agent:

/stream Build me a Social App with Feeds and Moderation.
/stream Any livestream calls running?
/stream Moderation .NET: <Your Question>