Skip to content
WhatSync/DocsAPI v1

List included or excluded numbers

List the people on this number's include or exclude list, one page at a time.

POST/api/v1/tools/list_number_filtersRead
Key permissions
Read chats and messages + Change saved chats and filters
Authentication
Authorization: Bearer $WHATSYNC_API_KEY
How keys work

How it works

The returned mode says whether it is a list of people to save (include) or to skip (exclude).

Body parameters

afterstringoptional

Lower date boundary or pagination value. Keep the same filters between pages.

limitintegeroptional

Maximum results per page. See the schema for bounds and defaults.

fromNumberstringoptional

Which of the account's WhatsApp numbers acts, with country code, as listed in whatsapp_numbers from get_account_context. Only matters when the account has several numbers. Omit for the account's first number.

Conditions and pagination

  • Pass the returned next_cursor (next_after for forms) as after. Stop when that value is null.

Response

HTTP 200 returns this tool's JSON directly, without an MCP content wrapper. Optional provider fields may be absent or null; check pagination and coverage before treating a page as complete.

Every response includes X-Request-Id. Errors use the shared error format and retry rules.

Schemas

Input JSON Schema
Input JSON Schema
{
  "type": "object",
  "properties": {
    "after": {
      "type": "string",
      "maxLength": 15
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    },
    "fromNumber": {
      "type": "string",
      "minLength": 7,
      "maxLength": 30,
      "description": "Which of the account's WhatsApp numbers acts, with country code, as listed in whatsapp_numbers from get_account_context. Only matters when the account has several numbers. Omit for the account's first number."
    }
  },
  "additionalProperties": false,
  "$schema": "http://json-schema.org/draft-07/schema#"
}
Response JSON Schema
Response JSON Schema
{
  "type": "object",
  "properties": {
    "numbers": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "phone_number": {
            "type": "string"
          },
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "reason": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [],
        "additionalProperties": true
      }
    },
    "next_cursor": {
      "type": [
        "string",
        "null"
      ]
    },
    "mode": {
      "type": "string"
    }
  },
  "required": [],
  "additionalProperties": true
}