I’m trying to create a scheduled trigger to clear a collection weekly, but I am unable to get the service…
const collection = context.services.get('mongodb-atlas');
is returning undefined when I log it to console, and when I try and using it, it just says “Cannot access member ‘db’ of undefined”. I’ve also tried setting the service name to “Cluster0” and “mongodb-datalake”, neither of which worked.
If someone could lend a hand on what I’m doing wrong and how I’m meant to do this, that would be awesome. Thanks.