API endpoint - https://“company name”.zoom.us/v2/chat/users/:userId/messages
Description
Trying to send message to either a channel or a contact in my ORG, but consistently getting the;
{“code”: 300, “message”: “Must provide either to_contact or to_channel parameter.” } in Postman.
Hi @tiaan.schulz
Thanks for reaching out to the Zoom Developer Forum and welcome to our community.
Please allow me some time to do some testing on my end and I will come back with an update shortly.
Best,
Elisa
Hi @tiaan.schulz
Thank you for your patience.
I am not able to replicate this behavior on my end.
I am able to send a message either to a channel or directly to a contact.
Here is the request body I am sending:
{
“message”: “Hello this is a test and it is working”,
“to_contact” : “elisa@mail.com”,
“at_items” : [
{
“at_contact”: “elisa@mail.com”,
“at_type” : 1,
“end_position” : 8,
“start_position” : 0
}
],
“rich_text” : [
{
“start_position” : 0,
“end_position” : 1,
“format_type” : “Paragraph”,
“format_attr” : “h1”
}
]
}
If I change the to_contact for to_channel, I send the message to a channel instead of directly to the contact.
Could you make sure that you are passing the same email address on the fields “to_conatc” and “at_contact” ?