Parse Data from Gmail Body

Hey All,

New to make and I would like to do the following.

I am have a notification email that gets pushed to gmail every that I would like to parse data from.

Here is the body of the email:

Keboola
[https://ui.keboola-assets.com/misc-ui-assets/v0.15.0-0-g8323590/@keboola/indigo-ui/12.1.4/img/email-logo-blue.png]
[https://www.keboola.com]

Job #1093231080 succeeded in 14 sec

Configuration Manual data
[Keboola Connection | Keboola Connection] succeeded.
Please see below for more details.

Start time: 2024-03-01 09:03 UTC

End time: 2024-03-01 09:03 UTC

View Job Details
[Keboola Connection | Keboola Connection]

Questions? Email us at support@keboola.com [support@keboola.com]

Keboola
[https://ui.keboola-assets.com/misc-ui-assets/v0.15.0-0-g8323590/@keboola/indigo-ui/12.1.4/img/email-logo-blue-small.png]
[https://www.keboola.com]

Keboola.com [https://www.keboola.com]
Dělnická 27, 170 00, Prague 7, Czech Republic

I would like to pull out the following data:
Job #1093231080 succeeded in 14 sec

View Job Details
[Keboola Connection | Keboola Connection]

I tried to make a regex match but seems like theres “no match” so I may be doing something wrong

Can someone provide guidance?

Hi @ian.g.make
Try this regex:


Job #\d+ succeeded.*$

2 Likes

thanks, can you explain how you generate that regex?

Magic :rofl:



2 Likes

You can use This site to get regex explained

thanks! I will give this a look and use chatgpt next time lol


Tried this regex but not working, any thoughts?

nvm, found the answer.

The pattern will contain at least one capture group in parenthesis () for the output bundle to contain some items. If the pattern does not contain any capture groups, the output bundle will be empty:

3 Likes

Heya @ian.g.make :wave:

I just wanted to say congrats on figuring this out with the help of @Dorian_Ben_Haim :clap:

Also, thanks a lot for stepping back and sharing your insights here for the benefit of the community. We all totally appreciate it :pray:

FYI: I marked your last comment as a solution to keep the community organized and easy to look for answers.

1 Like