Scrape Gmail Email Body to Add to GSheets

I have a label set up in Gmail to match incoming filter. I need a new row to be created in a specified GSheet each time an email hits the inbox that matches the filter. The issue is, I need the info from the body of the email to be placed into the rows. I feel like the scrape feature may be able to accomplish this. I’m attaching a screenshot of an example of the incoming email.
The scraping would need to take “FName” from email and place into “FName” in GSheet. Repeat for each line through “Booksource”

I always have my email tab open - but would it be reliable to “scrape data on an active tab”? Or should I scrape data on URLs in the background for better reliability?

Should I do it as a single page or a list since I need it to technically pull 5 pieces of info from the one email?

If I go the right-click route, what specifically would I highlight to initiate the trigger? Would it be the label of the email? Would it be the sender’s email address? Or would it be the first piece of info in the email body I need it to scrape and transfer?

Hey @jamiemilam ,

Thanks for your message! You actually don’t need to use a scraper for this. You can use a native gmail when action and then follow it up by an add row action. Here is a quick demo:

ezgif.com-resize

Please let me know if you have any further questions

But I need to split up the parts of the body of the email.
For instance, I need “FName” in GSheets to match up to what comes after “FName” in the body of the email. Does that make sense?

Ok, I was able to set up the scraper, so it’s connected to add direct to GSheet if I’m on the active tab.
Now, I’m trying to set it up to also run in the background using that scrape model.
I thought maybe trigger could be “when receive email from @” then scrape data in the background… using scraper template… then add row to GSheets.
I’ve mapped my GSheets out, but where the trigger is failing is somewhere in the "Scrape from the _____ of “when email is received”…
How would I fix that?

Here is the autobook that is set up Shared Playbook | Bardeen

Here is the error code:
{
“clientErrorCode”: “ScraperMissingTargetPageError”,
“message”: “You did not select a page on which to run this Automation.”,
“trackError”: false,
“stack”: “Error: You did not select a page on which to run this Automation.\n at i.from (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/background.js:83:13923)\n at Object.from (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/background.js:90:4724)\n at WM.handle (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1369:23967)\n at async chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:89761\n at async pS.guard (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:71538)\n at async Gw.invokeFunction (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:89719)\n at async Gw.invokeSequence (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:80769)\n at async Gw.invokePlaybook (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:82321)\n at async Lf.execute (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:100219)\n at async Lf.executeWithResult (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:100748)”,
“clientErrorHistory”: [
{
“clientErrorCode”: “ScraperMissingTargetPageError”,
“message”: “You did not select a page on which to run this Automation.”,
“stack”: “Error: You did not select a page on which to run this Automation.\n at i.from (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/background.js:83:13923)\n at Object.from (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/background.js:90:4724)\n at WM.handle (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1369:23967)\n at async chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:89761\n at async pS.guard (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:71538)\n at async Gw.invokeFunction (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:89719)\n at async Gw.invokeSequence (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:80769)\n at async Gw.invokePlaybook (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:82321)\n at async Lf.execute (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:100219)\n at async Lf.executeWithResult (chrome-extension://ihhkmalpkhkoedlmcnilbbhhbhnicjga/348.js:1464:100748)”,
“fingerprint”: [
“ScraperMissingTargetPageError”
]
}
],
“fingerprint”: [
“ScraperMissingTargetPageError”
]

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.