Disable Specific Notifications

Purpose

To disable notifications for the specified events in a channel.

Request Details

Request URL

{api-domain}/crm/{version}/actions/watch

Supported modules

Leads, Accounts, Contacts, Deals, Campaigns, Tasks, Cases, Meetings, Calls, Solutions, Products, Vendors, Price Books, Quotes, Sales Orders, Purchase Orders, Invoices, Appointments, Appointments Rescheduled History, Services, and Custom

Header

Authorization: Zoho-oauthtoken d92d4xxxxxxxxxxxxx15f52

Scope

scope=ZohoCRM.notifications.{operation_type}

Possible operation types

ALL - Full access to notification data
WRITE - Edit notification details
UPDATE - Update notification details

Sample Request

Copiedhttps://www.zohoapis.com/crm/v6/actions/watch"
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
-X PATCH
-d "@inputData.json"

In the request, "@inputData.json" contains the sample input data.

Input JSON Keys

  • _delete_eventsboolean, mandatory

    To specify whether to disable specific notifications.

  • channel_idlong, mandatory

    The given value is sent back in notification URL body to make sure that the notification is for a particular channel.
    Possible values: Channel ID. Example: 1000000068001

  • eventsJSONArray["{module_api_name}.{operation}", "{module_api_name}.{operation}"], mandatory

    To subscribe based on particular operations on selected modules.
    Possible values: JSON Array of the provided format. Example: ["Leads.create","Sales_Orders.edit","Contacts.delete"]. Possible operation types - create, delete, edit, all

  • notify_on_related_actionboolean, optional

    To enable or disable notification when there is any action on any associated records. The default value is TRUE.

Note

  • _delete_events key is mandatory to disable specific notifications. If "_delete_events": false or _delete_events key is not given in the input, instant notifications will not be disabled.
  • channel_id and events keys are also mandatory.

Sample Input

Copied{
    "watch": [
       {
            "channel_id": "10000",
            "events": [
                "Contacts.delete"
            ],
            "_delete_events": true
        }
    ]
}

Sample Response

Copied{
    "watch": [
        {
            "code": "SUCCESS",
            "details": {
                "events": [
                    {
                        "resource_uri": "https://www.zohoapis.com/crm/v2/Contacts",
                        "resource_id": "554023000000000129",
                        "resource_name": "Contacts",
                        "channel_id": "10000"
                    }
                ]
            },
            "message": "Successfully removed the subscribe details",
            "status": "success"
        }
    ]
}