Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info
This function is one of Plugins Operation.You can find the movie in ARGOS RPA+ video tutorial.
Image Removed

Web Extract

  • You can build a bot to extract data from websites (Web Scraping) using this tool.
  • In order to use this operation, you must have a knowledge about HTML and YAML.

Contents

  1. This operation is used after extracting the HTML source file from your browser. 
  2. The Parameters.
  3. A simple example below should help you build the web scraping bot.
  4. Below are the explanations of the Rule file construction (syntax).
  5. Use of xpath is also possible to specify the target area in the HTML source file like in an example below.
tip1

Anchor

tip1

1.

This operation is used after extracting the HTML source file from your browser. Image Removed

Need help?

Technical contact to tech@argos-labs.com

May you search all operations,

Anchortip2tip2

2. The Parameters.

Image Removed

1) Specify your HTML Source file here.

2) Specify your Rule file (YAML) here --- always check the check-box --- this file is mandatory.

3) If your data has many occurrences, you can limit the # of data to be extracted by setting the number here (0 means no limitation = default).

4) Define preferred encoding standard of your HTML file here – if your choice does not work Web Extract will go to auto-detect mode.

5) Define the HTML parsing standard here or leave it unchecked for auto detect mode.

6) Choose your output format (String, CSV, or File).

7) You must set your variable at Settings menu in the Main menu.

Anchortip3tip3

3. A simple example below should help you build the web scraping bot.

  • Below is your target website page.

Image Removed

  • And then below is the HTML source file.

Image Removed

  • Below is the Rule file (YAML).

Image Removed

  • And finally, the output file with extracted data.

Image Removed

  • The Rule file structure guide

Image Removed

Anchortip4tip4

4. Below are the explanations of the Rule file construction (syntax). 

Image Removed

1) Give explanations of the Rule file as comments.

2) Regardless of the desired final output format, always start with [csv].

3) [or] is used when you have more than just one type of HTML source returned from the website. It is optional.

4) [header] defines the labels of your output data table.

5) Rest of the YAML is to specify the data to be extracted. Use combinations of tag (name) and attribute (key+value) to identify the data. You may use multiple attributes if needed. Please note that the Rule file also includes “split” and “re-replace” for correcting the data.

Anchortip5tip5

5. Use of xpath is also possible to specify the target area in the HTML source file like in an example below. 

Image Removed

Additional explanations are provided below.

Image Removed

Image Removed  The Split command can take integer, or you can define separate as shown in this example.

Image Removed The re-replace command will replace the “from” value (regular expression) to “to” value (string).

Image Removed Global options can be added at the bottom of the Rule file.

In this example, it shows that when there is no result that data says “There is no Result (default is “No Result”) and skip-empty-row can take true/false parameter.

930.1927
1.930.1927

Include Page
1.930.1927
1.930.1927

Panel
titleColor#4178be
titleBGColor#e7f5ff
titleAll Plugins

Child pages (Children Display)
pagePlugins