Skip to main content

Notifications

Community site session details

Community site session details

Session Id : v1ml9L91072S4V1T3+xXIo
Power Automate - General Discussion
Answered

Reply to helpdesk ticket in SharePoint list

Like (0) ShareShare
ReportReport
Posted on 11 Oct 2023 06:22:40 by 10

Hello,

 

I'm using the MS list template to capture and log IT tickets. I noticed that when I reply to the recipient it creates a new list item instead of updating the existing item. I searched for a resolution to resolve this, but I'm completely out of ideas. Below is the flow with the error message I'm running into. 

katkins_0-1697005340663.png

 

 

katkins_0-1697005162643.png

 

I'm using the following to split the title and subject in the email to update it, but it doesn't work.

 

last(split(triggerOutputs()?['bodyPreview/E_x002d_subject'],';'))

 

Does anyone have any insight into this?

  • v-jefferni Profile Picture
    on 12 Oct 2023 at 06:46:47
    Re: Reply to helpdesk ticket in SharePoint list

    Hi @katkins ,

     

    In Compose2 there are only blank values "" output, so in Get item action the Id the value is blank as well, which made it fail.

     

    Conclusively, you have to follow the steps in the thread you post:

    1. Compose:

    split(triggerOutputs()?['body/subject'],';')

     

    2. Compose2: (if the format of email subjects is like AAA;123;title)

    {
    "id": 'outputs('Compose')?[1]',
    "Title": 'outputs('Compose')?[2]'
    }

    then you will get the output:

    {
    "id": "123",
    "Title": "title"
    }

     

    3. Get item: Id parameter:

    int(body('Parse JSON')?['id'])

     

    Best regards,

  • katkins Profile Picture
    10 on 12 Oct 2023 at 06:30:41
    Re: Reply to helpdesk ticket in SharePoint list

    @v-jefferni Thanks, I removed the last function, and it was able to go through. Now I ran into the original problem, which is shown below. I'm not sure why it is saying the id parameter needs to be an integer/64. When I edit the JSON properties and changed the id type from string to integer it still gives me issues. As you can see I'm using the list ID default column which I'm assuming is an integer column but changing the properties doesn't help either. 

    katkins_5-1697091848930.png

     

     

    katkins_4-1697091599321.png

     

    katkins_1-1697091398146.png

    Error with ID= string

    katkins_2-1697091424167.png

    Error with ID= integer

    katkins_6-1697092221925.png

     

    What do you think might be the issue?

     

    Best,

     

     

  • v-jefferni Profile Picture
    on 12 Oct 2023 at 03:37:49
    Re: Reply to helpdesk ticket in SharePoint list

    Hi @katkins ,

     

    In that post, the solution is using split alone and output an array that divided by semicolon. For example, an income Email with subject A;B;C;D, the output of split(triggerOutputs()?['body/subject'],';') is

    ["A","B","C","D"]

    and output of last(split(triggerOutputs()?['body/subject'],';')) is "D", which cannot be selected by using [1] or [2] in expression, outputs('Compose')[1] means to get the SECOND item from output of Compose.

     

    If you want to get the array, don't use last function in that expression. Or you can share one subject and what you want to get, I would help you out with the expression.

     

    Best regards,

  • katkins Profile Picture
    10 on 12 Oct 2023 at 03:19:32
    Re: Reply to helpdesk ticket in SharePoint list

    @v-jefferni thanks for pointing this out, I was trying to update my MS list item for our helpdesk, when a reply is sent via email. I found this with the community, but it doesn't seem to work on my end.

     

    https://powerusers.microsoft.com/t5/Building-Flows/Update-a-sharepoint-list-item-via-email/td-p/1767561

     

    The goal is to keep all communication within the same list for a specific email request from staff.

  • v-jefferni Profile Picture
    on 12 Oct 2023 at 02:33:29
    Re: Reply to helpdesk ticket in SharePoint list

    Hi @katkins ,

     

    Output of Compose is of type string, which is the last part of subject that divided by semicolons. You can find it was a "test" in Compose in the run history. I don't understand what you would like to get from Compose.

     

    Best regards,

  • katkins Profile Picture
    10 on 11 Oct 2023 at 14:38:39
    Re: Reply to helpdesk ticket in SharePoint list

    @v-jefferni  thank you, that helped, question my flow keeps failing giving me the following error message below:

     

    katkins_0-1697034637067.png

     

    The goal is when a ticket request comes in and added to MS list, I would like to reply to the same email chain and have that be updated as well to the item created for this request.  I created the following flow to do that with some instructions online. However, I might be missing a step to this. 

     

    katkins_1-1697034930078.png

     

    These are the expressions in "composed 2" inputs:

     

    katkins_2-1697035010977.png

     

    katkins_3-1697035036852.png

     

    Do you have any idea if this flow will help accomplish my goal? I'd appreciate your insight to this. 

     

    Best

     

     

  • Verified answer
    v-jefferni Profile Picture
    on 11 Oct 2023 at 06:35:31
    Re: Reply to helpdesk ticket in SharePoint list

    Hi @katkins ,

     

    The issue is triggerOutputs()?['bodyPreview/E_x002d_subject'] is blank, which is odd. please try and use below expression instead:

    last(split(triggerOutputs()?['body/subject'],';'))

     

    Best regards,

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,776 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,093 Most Valuable Professional

Leaderboard