phpAx / Zoom API / Delete a webinar poll
Back to Collection Items
<?php
// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.
// For versions of Chilkat < 10.0.0, use new COM('Chilkat_9_5_0.Chilkat.Http')
$http = new COM("Chilkat.Http");
// Adds the "Authorization: Bearer <access_token>" header.
$http->AuthToken = '<access_token>';
// resp is a Chilkat.HttpResponse
$resp = $http->QuickRequest('DELETE','https://api.zoom.us/v2/webinars/:webinarId/polls/:pollId');
if ($http->LastMethodSuccess == 0) {
print $http->LastErrorText . "\n";
exit;
}
$respStatusCode = $resp->StatusCode;
print 'Response Status Code = ' . $respStatusCode . "\n";
if ($respStatusCode != 204) {
print 'Response Header:' . "\n";
print $resp->Header . "\n";
print 'Response Body:' . "\n";
print $resp->BodyStr . "\n";
print 'Failed.' . "\n";
exit;
}
print 'Success.' . "\n";
?>
Curl Command
curl -X DELETE
-H "Authorization: Bearer <access_token>"
https://api.zoom.us/v2/webinars/:webinarId/polls/:pollId
Postman Collection Item JSON
{
"name": "Delete a webinar poll",
"request": {
"auth": {
"type": "oauth2"
},
"method": "DELETE",
"header": [
],
"url": {
"raw": "{{baseUrl}}/webinars/:webinarId/polls/:pollId",
"host": [
"{{baseUrl}}"
],
"path": [
"webinars",
":webinarId",
"polls",
":pollId"
],
"variable": [
{
"key": "webinarId",
"value": "68423085",
"description": "(Required) The webinar's ID."
},
{
"key": "pollId",
"value": "quis officia in reprehenderit",
"description": "(Required) The poll ID"
}
]
},
"description": "Delete a webinar's [poll](https://support.zoom.us/hc/en-us/articles/203749865-Polling-for-Webinars).<br><br>\n**Scopes:** `webinar:write:admin` `webinar:write`<br>\n \n **[Rate Limit Label](https://marketplace.zoom.us/docs/api-reference/rate-limits#rate-limits):** `Light`<br>\n\n"
},
"response": [
{
"name": "**HTTP Status Code:** `204`<br>\nWebinar Poll deleted",
"originalRequest": {
"method": "DELETE",
"header": [
{
"description": "Added as a part of security scheme: oauth2",
"key": "Authorization",
"value": "<token>"
}
],
"url": {
"raw": "{{baseUrl}}/webinars/:webinarId/polls/:pollId",
"host": [
"{{baseUrl}}"
],
"path": [
"webinars",
":webinarId",
"polls",
":pollId"
],
"variable": [
{
"key": "webinarId",
"value": "68423085",
"description": "(Required) The webinar's ID."
},
{
"key": "pollId",
"value": "quis officia in reprehenderit",
"description": "(Required) The poll ID"
}
]
}
},
"status": "No Content",
"code": 204,
"_postman_previewlanguage": "text",
"header": [
{
"key": "Content-Type",
"value": "text/plain"
}
],
"cookie": [
],
"body": ""
},
{
"name": "**HTTP Status Code:** `400` **Bad Request** <br>\n **Error Code:** `4400` <br> Webinar polls disabled. To enable this feature, enable the \"Webinar Polls/Quizzes\" setting in the Zoom web portal's \"Settings\" interface.",
"originalRequest": {
"method": "DELETE",
"header": [
{
"description": "Added as a part of security scheme: oauth2",
"key": "Authorization",
"value": "<token>"
}
],
"url": {
"raw": "{{baseUrl}}/webinars/:webinarId/polls/:pollId",
"host": [
"{{baseUrl}}"
],
"path": [
"webinars",
":webinarId",
"polls",
":pollId"
],
"variable": [
{
"key": "webinarId",
"value": "68423085",
"description": "(Required) The webinar's ID."
},
{
"key": "pollId",
"value": "quis officia in reprehenderit",
"description": "(Required) The poll ID"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "text",
"header": [
{
"key": "Content-Type",
"value": "text/plain"
}
],
"cookie": [
],
"body": ""
},
{
"name": "**HTTP Status Code:** `404`<br>\nWebinar poll not found.<br>\n**Error Code:** `3001`<br>\nWebinar {webinarId} not found or has expired.<br>",
"originalRequest": {
"method": "DELETE",
"header": [
{
"description": "Added as a part of security scheme: oauth2",
"key": "Authorization",
"value": "<token>"
}
],
"url": {
"raw": "{{baseUrl}}/webinars/:webinarId/polls/:pollId",
"host": [
"{{baseUrl}}"
],
"path": [
"webinars",
":webinarId",
"polls",
":pollId"
],
"variable": [
{
"key": "webinarId",
"value": "68423085",
"description": "(Required) The webinar's ID."
},
{
"key": "pollId",
"value": "quis officia in reprehenderit",
"description": "(Required) The poll ID"
}
]
}
},
"status": "Not Found",
"code": 404,
"_postman_previewlanguage": "text",
"header": [
{
"key": "Content-Type",
"value": "text/plain"
}
],
"cookie": [
],
"body": ""
}
]
}