@salesforce/b2c-tooling-sdk / operations/mrt / createNotification
Function: createNotification()
createNotification(
options,auth):Promise<object&object&object>
Defined in: packages/b2c-tooling-sdk/src/operations/mrt/notification.ts:218
Creates a notification for an MRT project.
Parameters
options
Create notification options
auth
Authentication strategy (ApiKeyStrategy)
Returns
Promise<object & object & object>
The created notification
Throws
Error if request fails
Example
typescript
import { ApiKeyStrategy } from '@salesforce/b2c-tooling-sdk/auth';
import { createNotification } from '@salesforce/b2c-tooling-sdk/operations/mrt';
const auth = new ApiKeyStrategy(process.env.MRT_API_KEY!, 'Authorization');
const notification = await createNotification({
projectSlug: 'my-storefront',
targets: ['staging', 'production'],
recipients: ['team@example.com'],
deploymentStart: true,
deploymentFailed: true
}, auth);