Page Scraping Analyzer avatar

Page Scraping Analyzer

Try for free

No credit card required

Go to Store
Page Scraping Analyzer

Page Scraping Analyzer

apify/page-analyzer
Try for free

No credit card required

Performs analysis of a webpage to figure out the best way how to scrape its data. Provide a URL and data points to find and get back a detailed dashboard showing how the data can be scraped. Works with initial and rendered HTML, JavaScript variables and dynamically loaded data.

Do you want to learn more about this Actor?

Get a demo

You can access the Page Scraping Analyzer programmatically from your own JavaScript applications by using the Apify API. You can also choose the language preference from below. To use the Apify API, you’ll need an Apify account and your API token, found in Integrations settings in Apify Console.

1import { ApifyClient } from 'apify-client';
2
3// Initialize the ApifyClient with your Apify API token
4// Replace the '<YOUR_API_TOKEN>' with your token
5const client = new ApifyClient({
6    token: '<YOUR_API_TOKEN>',
7});
8
9// Prepare Actor input
10const input = {
11    "url": "http://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html",
12    "keywords": [
13        "A Light in the Attic",
14        "51.77",
15        "In stock",
16        "22 available",
17        "a897fe39b1053632",
18        "It's hard to imagine a world without A Light in the Attic. This now-classic collection of poetry and drawings from Shel Silverstein celebrates its 20th anniversary with this special edition. Silverstein's humorous and creative verse can amuse the dowdiest of readers. Lemon-faced adults and fidgety kids sit still and read these rhythmic words and laugh and smile and love th It's hard to imagine a world without A Light in the Attic. This now-classic collection of poetry and drawings from Shel Silverstein celebrates its 20th anniversary with this special edition. Silverstein's humorous and creative verse can amuse the dowdiest of readers. Lemon-faced adults and fidgety kids sit still and read these rhythmic words and laugh and smile and love that Silverstein. Need proof of his genius? RockabyeRockabye baby, in the treetopDon't you know a treetopIs no safe place to rock?And who put you up there,And your cradle, too?Baby, I think someone down here'sGot it in for you. Shel, you never sounded so good. ...more"
19    ],
20    "proxyConfig": {
21        "useApifyProxy": true
22    }
23};
24
25// Run the Actor and wait for it to finish
26const run = await client.actor("apify/page-analyzer").call(input);
27
28// Fetch and print Actor results from the run's dataset (if any)
29console.log('Results from dataset');
30console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
31const { items } = await client.dataset(run.defaultDatasetId).listItems();
32items.forEach((item) => {
33    console.dir(item);
34});
35
36// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

Page Scraping Analyzer API in JavaScript

The Apify API client for JavaScript is the official library that allows you to use Page Scraping Analyzer API in JavaScript or TypeScript, providing convenience functions and automatic retries on errors.

Install the apify-client

npm install apify-client

Other API clients include:

Developer
Maintained by Apify

Actor Metrics

  • 14 monthly users

  • 10 stars

  • 97% runs succeeded

  • Created in Feb 2018

  • Modified 6 months ago