---
schema_version: "1"
id: 88fc0949b090b5b8ecc5b240732589a959aa60e2bab3ddfed33f3c4e179e5656
title: CustomNotificationType
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/api_meta/meta_customnotificationtype.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_customnotificationtype.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: b725fab6b208fa566fb1cb880dd9565f442159d4d98f8ae2bb578384ab89c143
description: Represents the metadata associated with a custom notification type.
---
# CustomNotificationType

Represents the metadata associated with a custom notification type.

![Important](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/images/icon_note_important.png)

#### Important

Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.

For more information about custom notifications, see Custom Notification Actions. This type extends the [Metadata](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/metadata.htm "The base class for all metadata types. You can’t edit this object. A component is an instance of a metadata type.") metadata type and inherits its fullName field.

## Declarative Metadata File Suffix and Directory Location

The file suffix is .notiftype for the notification type definition. Notification types are stored in the notificationtypes directory of the corresponding package directory.

## Version

CustomNotificationType components are available in API version 46.0 and later.

## Fields

| Field Name | Field Type | Description |
| --- | --- | --- |
| actionGroups (Beta) | [CustomNotificationActionGroup\[\]](#CustomNotificationActionGroup) | Optional. Indicates whether mobile action groups are enabled, allowing users to take actions directly from mobile notifications. |
| customNotifTypeName | string | Required. Specifies a notification type name. Maximum number of characters: 80. |
| description | string | Specifies a general description of the notification type, which is displayed with the notification type name. Maximum number of characters: 255. |
| desktop | boolean | Required. Indicates whether the desktop delivery channel is enabled (true) or not (false). |
| masterLabel | string | Required. Specifies the label for the notification type. |
| mobile | boolean | Required. Indicates whether the mobile delivery channel is enabled (true) or not (false). |
| slack | boolean | Reserved for future use. |

## CustomNotificationActionGroup

CustomNotificationActionGroup represents the action group.

| Field Name | Description |
| --- | --- |
| actions | 
Field Type

[CustomNotificationActionDefinition\[\]](#CustomNotificationActionDefinition)

Description

Represents the actions within a mobile action group.



 |
| groupName | 

Field Type

string

Description

Required.

Unique name of the mobile action group.



 |

## CustomNotificationActionDefinition

CustomNotificationActionDefinition represents the metadata that define an actionable notification.

| Field Name | Description |
| --- | --- |
| actionLabel | 
Field Type

string

Description

Required.

The name of the action seen in the push notification.



 |
| actionName | 

Field Type

string

Description

Required.

Unique identifier of the action in an action group.



 |
| actionTarget | 

Field Type

string

Description

The name of the Apex class where the action is implemented.



 |
| actionType | 

Field Type

NotificationActionType (enumeration of type string)

Description

Type of action.

Required.

Values are:

- NotificationApiAction: Server-side action where client needs to make action API call.
- Share: Client-side action where the app shares notification content to any channel.





 |

## Declarative Metadata Sample Definition

The following is a definition of a custom notification type that is enabled for desktop and mobile.

<CustomNotificationType xmlns="http://soap.sforce.com/2006/04/metadata">
    <customNotifTypeName\>Custom Notification</customNotifTypeName\>
    <desktop\>true</desktop\>
    <masterLabel\>Custom Notification</masterLabel\>
    <mobile\>true</mobile\>
</CustomNotificationType\>

## Wildcard Support in the Manifest File

This metadata type doesn’t support the wildcard character \* (asterisk) in the package.xml manifest file. For information about using the manifest file, see [Deploying and Retrieving Metadata with the Zip File](https://developer.salesforce.com/docs/atlas.en-us.264.0.api_meta.meta/api_meta/file_based_zip_file.htm).