Skip to main content

Documentation Index

Fetch the complete documentation index at: https://api.docs.onlydrams.app/llms.txt

Use this file to discover all available pages before exploring further.

Blocks a member from the community. Blocked status is stored in member metadata.

URL Parameters

community_id
integer
required
The ID of the community
id
integer
required
The ID of the community membership

Request Body

reason
string
Reason for blocking the member (optional)

Returns

Returns a success message and the updated member object.
curl -X POST https://api.onlydrams.app/odis/v1/communities/1/members/50/block \
     -H "Authorization: Bearer $ACCESS_TOKEN" \
     -H "Content-Type: application/json" \
     -d '{
       "reason": "Violated community guidelines"
     }'
{
  "message": "Member blocked successfully",
  "member": {
    "id": 50,
    "status": "active",
    "is_blocked": true,
    "block_reason": "Violated community guidelines",
    "metadata": {
      "blocked": true,
      "blocked_at": "2024-11-14T10:30:00Z",
      "blocked_by": 100,
      "block_reason": "Violated community guidelines"
    },
    "user": {
      "id": 200,
      "username": "whisky_lover"
    }
  }
}

Notes

  • Authorization: Community owner or admin only
  • Access Control: Blocked members cannot access community content
  • Subscription: Blocking doesn’t cancel the subscription automatically
  • Metadata: Block details stored in member metadata including timestamp and blocker ID
  • Reversible: Use the unblock endpoint to restore access