I am building a ticketing system with Power Automate, where someone can send an email to a shared mailbox and it creates a ticket in a SharePoint List and then sends them an email stating the ticket has been received. Unfortunately, if you reply to the shared mailbox message then it creates another ticket into the SharePoint List. I am trying to have the workflow read the Ticket ID in the Subject line of the 'When a new email arrives in a shared mailbox (V2)' action, I am using the ID that comes with SharePoint List since it is unique and auto increments, and if it sees the Ticket ID not to create a new item in the list. The purpose if for people to be able to reply and talk on that same ticket if necessary.
This is my flow so far, in my condition I tried to deconstruct this code:
@greaterOrEquals(
indexOf(
coalesce(triggerOutputs()?['body/subject'], ''),
concat('[Ticket ', string(variables('ID')), ']')
),
0
)
and plug it in above. Afterwards it caused that error message above the flow. If anyone knows how to make this flow work above, I would greatly appreciate the help! I am also going to try and go to support for help on this, if I find the answer I will make sure to post on here.