Notifications
Notifications are used by monday.com to alert users of actions inside their workflows. They are sent in response to events such as due dates, updates, and more.
By default, a user will also receive an email when they receive a notification. This can be turned off and customized in the user’s profile settings.
Notifications mutations
Required scope: notifications:write
Create a notification
The create_notification
mutation triggers a notification within the platform (will also send out an email if the recipient's email preferences are set up accordingly). Please keep in mind that notifications are async
and you will not be able to query their IDs back after sending them out.
If you send a notification from a board view or widget using seamless authentication, it will come from the app and display its name and icon. The notification will appear to come from the user who installed the app on an account if you make the call with a personal API key.
mutation {
create_notification (user_id: 105939, target_id: 674387, text: "This is a notification", target_type: Project) {
text
}
}
let query = "mutation { create_notification (user_id: 105939, target_id: 674387, text: \"This is a notification\", target_type: project) { text } }";
fetch ("https://api.monday.com/v2", {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization' : 'YOUR_API_KEY_HERE'
},
body: JSON.stringify({
query : query
})
})
.then(res => res.json())
.then(res => console.log(JSON.stringify(res, null, 2)));
You can find the Postman request to create a notification here.
Arguments
The following arguments determine the notification's characteristics.
Argument | Description |
---|---|
text String! | The notification text. |
user_id Int! | The user's unique identifier. |
target_id Int! | The target's identifier. |
target_type NotificationTargetType! | The target's type: project or post. - Projects refers to items or boards. Use the item or board ID as the target ID. - Posts refers to updates posted to items as replies or new updates. Use the update or reply ID to send the notification related to this update. |
Have questions?
Join our developer community! You can share your questions and learn from fellow users and monday.com product experts.
Don’t forget to search before opening a new topic!
Updated 5 days ago