cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
bai-simon
New Member

Error Posting Message to Dynamic Teams Channel

I built the following flow:

 

1. SQL STATEMENT

 

Result (dummy data):

CityText
AmsterdamThe temperature is 14 degrees celcius today
BerlinThe temperature is 11 degrees celcius today
CopenhagenThe temperature is 15 degrees celcius today

 

2. FOR EACH CONTAINER

 

2.1 CREATE TEAMS CHANNEL

Team: My Team

Channel: items('Apply_to_each')?'['City']

 

2.2 POST TO TEAMS CHANNEL

Team: My Team

Channel: items('Apply_to_each')?'['City']

Message: items('Apply_to_each')?'['Text']

 

ERROR 

"error": {
"code": "BadRequest",
"message": "Bad Request",
"innerError": {
"request-id": "",
"date": "2019-12-06T07:58:11"
}
 
Whatever I do or try, I get this error in step 2.2.
 
Do you have any idea what could solve this?
1 ACCEPTED SOLUTION

Accepted Solutions
v-litu-msft
Community Support
Community Support

Hi @bai-simon,

 

If post a message to Channel, the field *Channel should be Channel ID, it is a string of characters, not its display name:

Annotation 2019-12-09 092647.png

So, you should get the Channel ID according to the displayName by filter query, then use the Channel ID to put into the field *Channel to post massage.

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-litu-msft
Community Support
Community Support

Hi @bai-simon,

 

If post a message to Channel, the field *Channel should be Channel ID, it is a string of characters, not its display name:

Annotation 2019-12-09 092647.png

So, you should get the Channel ID according to the displayName by filter query, then use the Channel ID to put into the field *Channel to post massage.

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Thanks, that fixed it! It is interesting because if I put the name of the channel as a string, it works, but as a parameter, it needs the Id.

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Users online (1,219)