Skip to content
Dashboard

Block a contact

client.users.contacts.block(stringid, ContactBlockParams { featurebaseVersion } params?, RequestOptionsoptions?): ContactBlockResponse { id, blocked, object }
POST/v2/contacts/{id}/block

Blocks a contact by their Featurebase ID from the messenger/inbox.

Path Parameters

  • id - The Featurebase internal ID of the contact (MongoDB ObjectId)

Supported Contact Types

This endpoint blocks both:

  • Customers - Users with registered accounts
  • Leads - Anonymous or unregistered visitors

Blocking Behavior

When a contact is blocked:

  • The contact cannot send new messages via messenger
  • Existing conversations are not deleted but no new messages can be added by the blocked user
  • The block can be removed by unblocking the contact

Response

Returns a block confirmation object:

  • id - The ID of the blocked contact
  • object - Always “contact”
  • blocked - Always true

Example Response

{
  "id": "507f1f77bcf86cd799439011",
  "object": "contact",
  "blocked": true
}

Version Availability

This endpoint is only available in API version 2026-01-01.nova and newer.

ParametersExpand Collapse
id: string

Featurebase contact ID

params: ContactBlockParams { featurebaseVersion }
featurebaseVersion?: "2026-01-01.nova" | "2025-12-12.clover"

API version for this request. Defaults to your organization’s configured API version if not specified.

One of the following:
"2026-01-01.nova"
"2025-12-12.clover"
ReturnsExpand Collapse
ContactBlockResponse { id, blocked, object }
id: string

Unique identifier of the blocked contact

blocked: true

Indicates the contact was blocked

object: "contact"

Object type identifier

Block a contact

import Featurebase from 'featurebase-node';

const client = new Featurebase({
  apiKey: process.env['FEATUREBASE_API_KEY'], // This is the default and can be omitted
});

const response = await client.users.contacts.block('507f1f77bcf86cd799439011');

console.log(response.id);
{
  "id": "507f1f77bcf86cd799439011",
  "blocked": true,
  "object": "contact"
}
Returns Examples
{
  "id": "507f1f77bcf86cd799439011",
  "blocked": true,
  "object": "contact"
}