Jaakko Hyttinen asked on Slack:
Hey everyone! I am pretty new to the Barden but can already see a lot of use cases for it.
Now I have faced a problem though:
I have a Google Sheets on Drive with links to the sites where I would like the Barden to collect the phonenumber, but since I am such a rookie I dont know how to build this
could someone give me a hint or two?
We exchanged some messages and the it was solved here is how you can do it too.
Steps to Scrape Phone Numbers from Websites using Google Sheets and Barden:
Create a Google Sheet: Set up a Google Sheet on Google Drive, organizing columns for website links and phone numbers.
Install Barden: Install the Barden extension for Google Chrome and open it.
Get Table: Use Barden’s “Get Table from Google Sheets” action to retrieve data from your Google Sheet, ensuring the correct sheet is selected.
Get Page as HTML: Extract the HTML content of the linked websites from your Google Sheet using Barden’s “Get Page as HTML” action.
Convert Text to HTML: Extract the Text from the HTML content of the linked websites from your Google Sheet using Barden’s “Convert Text to HTML” action.
Find Phone Numbers in Text: Apply Barden’s “Find Phone Numbers in Text” action, this action utilizes the power of regular expressions to search for phone numbers within the HTML content.
Add Rows to Google Sheet: Store the extracted phone numbers back in your Google Sheet using the “Add Rows to Google Sheet” action, specifying the appropriate sheet and column. Use both the site URL and Phone number. DO NOT USE “Update Google Sheets rows” as some websites might have multiple phones which will create an error.