How 2 Access Newly Created Document Data in Database Trigger Function for a Blog Newsletter System.
- 0
- Functions
- REST API
šš¼ I have a "blogs" collection in my production database "blogify"
šš¼ I want to write a function "sendNewsletter" which sends the newsletter immediately after someone wrote the blog and the audience subscribed to them.
šš¼ I would like to add an event to listen the "blogs" collection... and after some blog is created, this function should be executed.
šš¼ My Question is: In the context of a database trigger or event listener for new blog post creation, how can the "sendNewsletter" function access the details of the newly created blog post document? Specifically, what methods or techniques can be used to retrieve the content of the document that triggered the function, so that the function can identify the author and their subscribers?
PLEASE HELP ME OUT!
How 2 Access Newly Created Document Data in Database Trigger Function for a Blog Newsletter System.
Recommended threads
- Function domain not available
Hello, even tho in docs you clearly describe that every function has its domain, I can not see it anywhere in any of my projects. How do I reveal the url of th...
- Inquiry: How to Reduce Cold Start Durati...
Hey! I was using Python for the function runtime, but after reading that Go has the fastest runtime, I switched my code over to Go. However, I'm still seeing co...
- context deadline exceeded
Hi, in one of my projects i continuously receive context deadline exceeded when trying to reach users API from my local machine: https://fra.cloud.appwrite.io/v...