Monitoring Checker Schema avatar
Monitoring Checker Schema
Try for free

No credit card required

View all Actors
Monitoring Checker Schema

Monitoring Checker Schema

apify/monitoring-checker-schema
Try for free

No credit card required

The monitoring checker schema is a part of the Apify Monitoring Suite (apify/monitoring). See its readme for more information and how to use this.

The code examples below show how to run the Actor and get its results. To run the code, you need to have an Apify account. Replace <YOUR_API_TOKEN> in the code with your API token, which you can find under Settings > Integrations in Apify Console. Learn more

1import { ApifyClient } from 'apify-client';
2
3// Initialize the ApifyClient with your Apify API token
4const client = new ApifyClient({
5    token: '<YOUR_API_TOKEN>',
6});
7
8// Prepare Actor input
9const input = {
10    "options": `/* global t */
11        // t variable definition because of type validation ... 
12         [{
13            schema: {
14                url: t.string.url,
15                date: t.string.date,
16                messages: t.array,
17            },
18        }, 
19        {
20            filter: 'eshop', // you can also use IDs definition as: Ids: ["id", "id"]
21            minItemCount: 100,  
22            maxItemCount: 1000
23        }]`
24};
25
26(async () => {
27    // Run the Actor and wait for it to finish
28    const run = await client.actor("apify/monitoring-checker-schema").call(input);
29
30    // Fetch and print Actor results from the run's dataset (if any)
31    console.log('Results from dataset');
32    console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
33    const { items } = await client.dataset(run.defaultDatasetId).listItems();
34    items.forEach((item) => {
35        console.dir(item);
36    });
37})();
38
39// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs
Developer
Maintained by Apify
Actor metrics
  • 10 monthly users
  • 8 stars
  • 99.9% runs succeeded
  • Created in Aug 2020
  • Modified 1 day ago
Categories