Skip to content
Whats91

Change the board, keyword, match mode, priority, or status of an existing exclusion.

Update Keyword Exclusion

Summary

Change the board, keyword, match mode, priority, or status of an existing exclusion.

Prerequisites

  • Authorization: Bearer w91_live_xxx
  • Content-Type: application/json for JSON requests
PUT/api/v2/custom-boards/keyword-exclusions/{uid}

Update a keyword exclusion. The HTTP method is PATCH.

ParameterTypeRequiredDescription
uidstringRequiredKeyword exclusion UID.
boardUidstringOptionalNew board identifier.
keywordstringOptionalNew keyword or pattern.
matchModestringOptionalEXACT, CONTAINS, WHOLE_WORD, or REGEX.
priorityintegerOptionalNew evaluation priority.
statusstringOptionalACTIVE or INACTIVE.
cURL
curl -X PATCH "https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/cbke_abc123" \
  -H "Authorization: Bearer w91_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "senderId": "913614068784",
    "boardUid": "external-board-1",
    "keyword": "track rod",
    "matchMode": "WHOLE_WORD",
    "priority": 5,
    "status": "ACTIVE"
  }'
200 OK
{
  "success": true,
  "message": "Custom board keyword exclusion updated",
  "data": {
    "keywordExclusion": {
      "uid": "cbke_abc123",
      "keyword": "track rod",
      "normalizedKeyword": "track rod",
      "matchMode": "WHOLE_WORD",
      "priority": 5,
      "status": "ACTIVE",
      "updatedAt": "2026-06-28T09:10:00.000Z"
    }
  },
  "metadata": {
    "apiVersion": "v2",
    "requestId": "request-uuid"
  }
}

Note

This endpoint uses PATCH, not POST. Send Content-Type: application/json or the request fails with 415 UNSUPPORTED_CONTENT_TYPE.

SDK Examples

Use these examples as starting points for server-side implementations.

cURL
curl -X PUT "https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/{uid}" \
  -H "Authorization: Bearer w91_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
  "senderId": "913614068784",
  "boardUid": "external-board-1",
  "keyword": "track rod",
  "matchMode": "WHOLE_WORD",
  "priority": 5,
  "status": "ACTIVE"
}'
Node.js
const response = await fetch("https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/{uid}", {
  method: "PUT",
  headers: {
    "Authorization": "Bearer w91_live_xxx",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "senderId": "913614068784",
    "boardUid": "external-board-1",
    "keyword": "track rod",
    "matchMode": "WHOLE_WORD",
    "priority": 5,
    "status": "ACTIVE"
  })
});

const data = await response.json();
console.log(data);
PHP
$ch = curl_init("https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/{uid}");
curl_setopt_array($ch, [
  CURLOPT_CUSTOMREQUEST => "PUT",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer w91_live_xxx",
    "Content-Type: application/json"
  ],
  CURLOPT_POSTFIELDS => json_encode([
    "senderId" => "913614068784",
    "boardUid" => "external-board-1",
    "keyword" => "track rod",
    "matchMode" => "WHOLE_WORD",
    "priority" => 5,
    "status" => "ACTIVE"
  ])
]);

$response = curl_exec($ch);
curl_close($ch);
echo $response;
Python
import requests

response = requests.request(
    "PUT",
    "https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/{uid}",
    headers={
        "Authorization": "Bearer w91_live_xxx",
        "Content-Type": "application/json",
    },
    json={
        "senderId": "913614068784",
        "boardUid": "external-board-1",
        "keyword": "track rod",
        "matchMode": "WHOLE_WORD",
        "priority": 5,
        "status": "ACTIVE"
    }
)

print(response.json())
C#
using System.Text;

using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer w91_live_xxx");

var request = new HttpRequestMessage(HttpMethod.Put, "https://graph.whats91.com/api/v2/custom-boards/keyword-exclusions/{uid}");
request.Content = new StringContent(
  """
  {
    "senderId": "913614068784",
    "boardUid": "external-board-1",
    "keyword": "track rod",
    "matchMode": "WHOLE_WORD",
    "priority": 5,
    "status": "ACTIVE"
  }
  """,
  Encoding.UTF8,
  "application/json"
);

var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());

Related APIs