Passing Variables to Python for IF Statements within Procedures

I would like to create a script with the following logic …

IF (PowerShell command output is x)
{ Trigger iTarian Alert }

In order to accomplish this, I need two things …

A way to determine what the output of a powershell command is and pass that variable or create a variable with that data.

I also need a way to create an IF statement in Python and give it that variable. Can I get some help with this?

hi @ProfoundIT

I have forwarded your request to the concern team to look into it and get back to you.

thank you

Hi @ProfoundIT ,

Your script request has been shared with the script developer and an internal script task CS-55843 is created for your reference.

Kind Regards,
PremJK

Hi @ProfoundIT ,

Please check your inbox for the private message where we shared our script developer feedback and test python script for your reference.

Kind Regards,
PremJK