cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Vale_2290
Frequent Visitor

Teams - Create a chat action error: Exception has been thrown by the target of an invocation.

Hi everyone,

 

i'm having a huge problem with a flow, the one you see in the image:

Vale_2290_0-1637934836161.png

 

When I add a member (using a variable or writing the email address) and start the flow it always gives me this error in the Create a chat action:

 

Vale_2290_1-1637934947842.png

 

 

Anyone know how to fix?

 

Thank you so much!!

 

18 REPLIES 18
muralidharan
Resolver III
Resolver III

Hi @Vale_2290 
* The user email address is from your organization or outside of your organization?

* What happens, if you set user email address as your email address?

* Have you tried with Manual trigger rather than triggering it from PowerApps?

 

Thanks,

Murali

 

Hi Murali,

 

the email address in from my organization.
I've altready tried all your suggestions but i always have the same error.

 

 

I tried quickly as you mentioned and it works fine for me. 

The test chat message also posted in the Teams. 

I used Manual trigger and you've used PowerApps trigger. 

Is that possible for you to export the Power Automate and share?

 

 

muralidharan_0-1637939432155.png

 

Thanks

Murali

 

In my development environment it works, I exported the flow to a customer's environment and i have that error.
I tried to post a message as a Bot Flow and it works form my customer. As user it doesn't.
Could it be an authorization error?

 

I can't export the flow right now. 

Hi @Vale_2290 ,

While importing the Flow into another environment, how you have configured the connection property for Teams?

Please try to create new connection and try . 

 

muralidharan_0-1637939966969.png

 

 

Thanks,

Murali.

Vale_2290
Frequent Visitor

I've tried but always got the same error.

federico_franco
New Member

Dear all,

I'm experiencing the same problem and I didn't find any solution. Any update?

Eizo
New Member

Same problem I am facing, no solution ? maybe how to input email address ???

 

CeeRiL
New Member

Same issue on my side as well, looks like there's a bug with "Create a chat".

cjplow
New Member

I'm having the same issue.  Tried testing it in different flows.  Any solutions?

Hi. 

I was having exactly the same issue but I managed to fix it. Basically I have a Flow that pulls in a Column of Email Addresses from a Share Point List and then, using a Compose action, creates a long string of the email addresses separated by a semi-colon. The 'Outputs' from the Compose action is then added to the 'Create a Chat' action within the 'Members to add' field;

 

FlowError.PNG

This kept failing until I took a closer look at the Share Point List I was getting the data from;

qrr.png

 

Turns out there was a semi colon at the end of one of the email addresses. This meant 2 of the email addresses were separated by ';;' rather than just ';'. When I removed semi colon the Flow worked. Could there possibly be a character somewhere that is affecting your Flow?

Lincz
New Member

Any update? Same issue here..

LoganInTexas
Frequent Visitor

I was seeing the same issue today. Here's what I found:

1. Don't include the email address of the connection you're using. For instance if your account is Bob@Company.com,  then make sure Bob@Company.com is NOT in the list of email addresses.

2. Don't include an extra semi-colon at the end of the list of invitees. This most likely happens when your concatonating a list of values together to generate an email address string. Update your flow to either NOT add the semi-colon every time, or remove it after you've found everything you want to find.

How to remove email address of the connection from the list of email addresses ?

 

My case, it's than when I'm in the @To of a typology of mail, i must create a conversation with all people on the @TO 

Thanks by advance

 

ChadOlson
New Member

Our issue was the "Members to add" input needed to be the User Principal Name (UPN) instead of their email address. In our organization they are different. We used the "Get User Profile (V2)" action to retrieve the UPN and used that output to create the chat in the 'Members to add' input.

Thanks, this solved the problem

I was having the same issue as well and it was frustratingly difficult to resolve

But for the sake of other users, I shall attempt to explain.

Depending on your organization's policy, there could be differences in the UPN and email address. 

For the sake of illustration, I'll call

Names as Baba Yaga

Company domain JohnDoeltd

Email: baba.yaga@johndoeltd.com

Username: byaga

UPN: byaga@johndoeltd.com

Many of us have been using email and username but UPN (User Principal Name) works

 

muralidharan
Resolver III
Resolver III

Thanks for sharing  and definitely it will be helpful for someone. 

v-mpalanivel
Microsoft
Microsoft

Hi Guys Please remove your name (whose trigger the flow) then try it is working

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (4,126)