SharePoint alert me fuctionality in SPFx
What type of issue is this?
Question
What SharePoint development model, framework, SDK or API is this about?
💥 SharePoint Framework
Target SharePoint environment
SharePoint Online
What browser(s) / client(s) have you tested
- [ ] 💥 Internet Explorer
- [ ] 💥 Microsoft Edge
- [ ] 💥 Google Chrome
- [ ] 💥 FireFox
- [ ] 💥 Safari
- [ ] mobile (iOS/iPadOS)
- [ ] mobile (Android)
- [ ] not applicable
- [ ] other (enter in the "Additional environment details" area below)
Additional environment details
- browser version
- SPFx version
- Node.js version
- etc React
Issue description
I am trying to create List alert using react in SPO SPFx solution. Basically I need to create a webpart with button control. When user click on the button user alert needs to be created for the list.
Could you please help to build it.
Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.
You could use SharePoint rest api to create the alert: _api/web/Alerts/Add(...)/. Refer to: https://s-kainet.github.io/sp-rest-explorer/#/_api/web/Alerts/Add
Here is a similar question: https://sharepoint.stackexchange.com/questions/262556/create-list-alert-using-rest
Michael Han Microsoft SharePoint Community Support
I gone through the article https://sharepoint.stackexchange.com/questions/262556/create-list-alert-using-rest,. still Iam not getting it worked. Could you please advice.
Sreeraj R
You could try this jsom code to add the alert: https://gist.github.com/beckettkev/6f3389963294aa1b566a59fde48dc245
This has been solved here: https://github.com/SharePoint/sp-dev-docs/issues/4883
Thank you for your submission. As explained in our wiki (Issue List: What doesn't belong in the issue list), this issue list is for SharePoint developer/development issues. All capability question/discussion questions, or topics related to SharePoint administration & end-user topics should be reported through the support user interface available in the tenant admin settings. You can also have a discussion and ask questions at the SharePoint TechCommunity forum. You can learn more about this in our wiki: type:invalid-not-dev-issue