Update a webinar registrant’s status


#1

HI 

when i using the code below with “POST” method it works fine, but with “PUT”  i get  [code] => 300 [message] => Unsupported Content Type )

 

$PutFields=array(

“action”=>‘approve’,

“registrants”=>array(

“id”=>$this->userzoomid,

“email”=>$this->useremail

),

 

);

 

 

 

$PutFields=json_encode($PutFields);

print_r($PutFields);

 

$url=‘https://api.zoom.us/v2/webinars/’.$this->web.’/registrants/status’;

$ch = curl_init();

curl_setopt($ch, CURLOPT_HTTPHEADER, array(

'Authorization: Bearer '.$this->generateJWT().PHP_EOL.‘accept: application/json Content-Type: application/json’

)); 

 

curl_setopt($ch, CURLOPT_URL, $url);

curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); 

//curl_setopt($ch, CURLOPT_PUT, true);

curl_setopt($ch, CURLOPT_CUSTOMREQUEST, “PUT”);

curl_setopt($ch, CURLOPT_POSTFIELDS,$PutFields);                    

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);

$response_updateToapproved = curl_exec($ch);

 

 

can’t find what is the problem 

 


#2

This API should use PUT method.

And I can’t reproduce this issue, please test this API with postman tool.