Chilkat Online Tools

DataFlex / Zoom API / Update options

Back to Collection Items

Use ChilkatAx-win32.pkg

Procedure Test
    Handle hoHttp
    Boolean iSuccess
    Variant vReq
    Handle hoReq
    Variant vResp
    Handle hoResp
    String sTemp1
    Integer iTemp1
    Boolean bTemp1

    // This example assumes the Chilkat API to have been previously unlocked.
    // See Global Unlock Sample for sample code.

    Get Create (RefClass(cComChilkatHttp)) To hoHttp
    If (Not(IsComObjectCreated(hoHttp))) Begin
        Send CreateComObject of hoHttp
    End

    Get Create (RefClass(cComChilkatHttpRequest)) To hoReq
    If (Not(IsComObjectCreated(hoReq))) Begin
        Send CreateComObject of hoReq
    End
    Set ComHttpVerb Of hoReq To "PATCH"
    Set ComPath Of hoReq To "/v2/accounts/:accountId/options"
    Set ComContentType Of hoReq To "multipart/form-data"
    Send ComAddParam To hoReq "share_rc" "false"

    Send ComAddParam To hoReq "room_connector_list" 'false["cillum qui adipisicing cupidatat","nisi officia nulla"]'

    Send ComAddParam To hoReq "share_mc" 'false["cillum qui adipisicing cupidatat","nisi officia nulla"]false'

    Send ComAddParam To hoReq "meeting_connector_list" 'false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]'

    Send ComAddParam To hoReq "pay_mode" 'false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]master'

    Send ComAddParam To hoReq "billing_auto_renew" 'false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]mastertrue'

    Send ComAddHeader To hoReq "Authorization" "Bearer <access_token>"

    Get pvComObject of hoReq to vReq
    Get ComSynchronousRequest Of hoHttp "api.zoom.us" 443 True vReq To vResp
    If (IsComObject(vResp)) Begin
        Get Create (RefClass(cComChilkatHttpResponse)) To hoResp
        Set pvComObject Of hoResp To vResp
    End
    Get ComLastMethodSuccess Of hoHttp To bTemp1
    If (bTemp1 = False) Begin
        Get ComLastErrorText Of hoHttp To sTemp1
        Showln sTemp1
        Procedure_Return
    End

    Get ComStatusCode Of hoResp To iTemp1
    Showln iTemp1
    Get ComBodyStr Of hoResp To sTemp1
    Showln sTemp1
    Send Destroy of hoResp


End_Procedure

Curl Command

curl -X PATCH
	-H "Authorization: Bearer <access_token>"
	-H "Content-Type: multipart/form-data"
	--form 'share_rc=false'
	--form 'room_connector_list=false["cillum qui adipisicing cupidatat","nisi officia nulla"]'
	--form 'share_mc=false["cillum qui adipisicing cupidatat","nisi officia nulla"]false'
	--form 'meeting_connector_list=false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]'
	--form 'pay_mode=false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]master'
	--form 'billing_auto_renew=false["cillum qui adipisicing cupidatat","nisi officia nulla"]false["sed velit Excepteur","nisi"]mastertrue'
https://api.zoom.us/v2/accounts/:accountId/options

Postman Collection Item JSON

{
  "name": "Update options",
  "request": {
    "auth": {
      "type": "oauth2"
    },
    "method": "PATCH",
    "header": [
      {
        "key": "Content-Type",
        "value": "multipart/form-data"
      }
    ],
    "body": {
      "mode": "formdata",
      "formdata": [
        {
          "key": "share_rc",
          "value": "false",
          "description": "Enable/disable the option for a sub account to use shared [Virtual Room Connector(s)](https://support.zoom.us/hc/en-us/articles/202134758-Getting-Started-With-Virtual-Room-Connector) that are set up by the master account. Virtual Room Connectors can only be used by On-prem users.",
          "type": "text"
        },
        {
          "key": "room_connector_list",
          "value": "[\"cillum qui adipisicing cupidatat\",\"nisi officia nulla\"]",
          "description": "Specify the IP addresses of the Room Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Room Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_rc` is set to `true`.",
          "type": "text"
        },
        {
          "key": "share_mc",
          "value": "false",
          "description": "Enable/disable the option for a sub account to use shared [Meeting Connector(s)](https://support.zoom.us/hc/en-us/articles/201363093-Getting-Started-with-the-Meeting-Connector) that are set up by the master account. Meeting Connectors can only be used by On-prem users.",
          "type": "text"
        },
        {
          "key": "meeting_connector_list",
          "value": "[\"sed velit Excepteur\",\"nisi\"]",
          "description": "Specify the IP addresses of the Meeting Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Meeting Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_mc` is set to `true`.",
          "type": "text"
        },
        {
          "key": "pay_mode",
          "value": "master",
          "description": "Payee:<br>`master` - master account holder pays.<br>`sub` - Sub account holder pays. (This can only be one of master,sub)",
          "type": "text"
        },
        {
          "key": "billing_auto_renew",
          "value": "true",
          "description": "Toggle whether automatic billing renewal is on or off.",
          "type": "text"
        }
      ]
    },
    "url": {
      "raw": "{{baseUrl}}/accounts/:accountId/options",
      "host": [
        "{{baseUrl}}"
      ],
      "path": [
        "accounts",
        ":accountId",
        "options"
      ],
      "variable": [
        {
          "key": "accountId",
          "value": "quis officia in reprehenderit",
          "description": "(Required) The account's ID."
        }
      ]
    },
    "description": "Update a sub account's options under the master account.<br> <aside>Your account must be a master account in order to update the options for sub accounts. Zoom only assigns this privilege to trusted partners. </aside>\n\n**Prerequisites:**\n* Pro or a higher paid account with master account option enabled.\n* The account making this API request must be a [master account](https://marketplace.zoom.us/docs/api-reference/master-account-apis).<br><br>\n\n**Scope**: `account:write:admin`<br>\n**[Rate Limit Label](https://marketplace.zoom.us/docs/api-reference/rate-limits#rate-limits):** `Light`<br>\n\n\n "
  },
  "response": [
    {
      "name": "**Error Code:** `200`<br>\nThe pay mode cannot be updated for a sub account which already has an existing plan.",
      "originalRequest": {
        "method": "PATCH",
        "header": [
          {
            "description": "Added as a part of security scheme: oauth2",
            "key": "Authorization",
            "value": "<token>"
          }
        ],
        "body": {
          "mode": "formdata",
          "formdata": [
            {
              "key": "share_rc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Virtual Room Connector(s)](https://support.zoom.us/hc/en-us/articles/202134758-Getting-Started-With-Virtual-Room-Connector) that are set up by the master account. Virtual Room Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "room_connector_list",
              "value": "[\"officia dolor deserunt elit tempor\",\"dolor ullamco\"]",
              "description": "Specify the IP addresses of the Room Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Room Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_rc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "share_mc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Meeting Connector(s)](https://support.zoom.us/hc/en-us/articles/201363093-Getting-Started-with-the-Meeting-Connector) that are set up by the master account. Meeting Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "meeting_connector_list",
              "value": "[\"fugiat et nisi\",\"dolor officia aliquip sed\"]",
              "description": "Specify the IP addresses of the Meeting Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Meeting Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_mc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "pay_mode",
              "value": "master",
              "description": "Payee:<br>`master` - master account holder pays.<br>`sub` - Sub account holder pays. (This can only be one of master,sub)",
              "type": "text"
            },
            {
              "key": "billing_auto_renew",
              "value": "true",
              "description": "Toggle whether automatic billing renewal is on or off.",
              "type": "text"
            }
          ]
        },
        "url": {
          "raw": "{{baseUrl}}/accounts/:accountId/options",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "accounts",
            ":accountId",
            "options"
          ],
          "variable": [
            {
              "key": "accountId",
              "value": "quis officia in reprehenderit",
              "description": "(Required) The account's ID."
            }
          ]
        }
      },
      "status": "OK",
      "code": 200,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    },
    {
      "name": "**HTTP Status Code:** `204`<br>\nAccount options updated.",
      "originalRequest": {
        "method": "PATCH",
        "header": [
          {
            "description": "Added as a part of security scheme: oauth2",
            "key": "Authorization",
            "value": "<token>"
          }
        ],
        "body": {
          "mode": "formdata",
          "formdata": [
            {
              "key": "share_rc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Virtual Room Connector(s)](https://support.zoom.us/hc/en-us/articles/202134758-Getting-Started-With-Virtual-Room-Connector) that are set up by the master account. Virtual Room Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "room_connector_list",
              "value": "[\"officia dolor deserunt elit tempor\",\"dolor ullamco\"]",
              "description": "Specify the IP addresses of the Room Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Room Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_rc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "share_mc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Meeting Connector(s)](https://support.zoom.us/hc/en-us/articles/201363093-Getting-Started-with-the-Meeting-Connector) that are set up by the master account. Meeting Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "meeting_connector_list",
              "value": "[\"fugiat et nisi\",\"dolor officia aliquip sed\"]",
              "description": "Specify the IP addresses of the Meeting Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Meeting Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_mc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "pay_mode",
              "value": "master",
              "description": "Payee:<br>`master` - master account holder pays.<br>`sub` - Sub account holder pays. (This can only be one of master,sub)",
              "type": "text"
            },
            {
              "key": "billing_auto_renew",
              "value": "true",
              "description": "Toggle whether automatic billing renewal is on or off.",
              "type": "text"
            }
          ]
        },
        "url": {
          "raw": "{{baseUrl}}/accounts/:accountId/options",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "accounts",
            ":accountId",
            "options"
          ],
          "variable": [
            {
              "key": "accountId",
              "value": "quis officia in reprehenderit",
              "description": "(Required) The account's ID."
            }
          ]
        }
      },
      "status": "No Content",
      "code": 204,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Content-Type",
          "value": "application/json"
        }
      ],
      "cookie": [
      ],
      "body": "{\n \"share_rc\": \"boolean\",\n \"room_connectors\": \"string\",\n \"share_mc\": \"boolean\",\n \"meeting_connectors\": \"string\",\n \"pay_mode\": \"string\"\n}"
    },
    {
      "name": "**HTTP Status Code:** `400`<br>\n**Error Code:** `2100`<br> The collection method cannot be changed after the purchase is complete.",
      "originalRequest": {
        "method": "PATCH",
        "header": [
          {
            "description": "Added as a part of security scheme: oauth2",
            "key": "Authorization",
            "value": "<token>"
          }
        ],
        "body": {
          "mode": "formdata",
          "formdata": [
            {
              "key": "share_rc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Virtual Room Connector(s)](https://support.zoom.us/hc/en-us/articles/202134758-Getting-Started-With-Virtual-Room-Connector) that are set up by the master account. Virtual Room Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "room_connector_list",
              "value": "[\"officia dolor deserunt elit tempor\",\"dolor ullamco\"]",
              "description": "Specify the IP addresses of the Room Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Room Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_rc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "share_mc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Meeting Connector(s)](https://support.zoom.us/hc/en-us/articles/201363093-Getting-Started-with-the-Meeting-Connector) that are set up by the master account. Meeting Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "meeting_connector_list",
              "value": "[\"fugiat et nisi\",\"dolor officia aliquip sed\"]",
              "description": "Specify the IP addresses of the Meeting Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Meeting Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_mc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "pay_mode",
              "value": "master",
              "description": "Payee:<br>`master` - master account holder pays.<br>`sub` - Sub account holder pays. (This can only be one of master,sub)",
              "type": "text"
            },
            {
              "key": "billing_auto_renew",
              "value": "true",
              "description": "Toggle whether automatic billing renewal is on or off.",
              "type": "text"
            }
          ]
        },
        "url": {
          "raw": "{{baseUrl}}/accounts/:accountId/options",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "accounts",
            ":accountId",
            "options"
          ],
          "variable": [
            {
              "key": "accountId",
              "value": "quis officia in reprehenderit",
              "description": "(Required) The account's ID."
            }
          ]
        }
      },
      "status": "Bad Request",
      "code": 400,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    },
    {
      "name": "**HTTP Status Code:** `404`<br>\n**Error Code:** `2001`<br>\nAccount does not exist: $subAccountId.",
      "originalRequest": {
        "method": "PATCH",
        "header": [
          {
            "description": "Added as a part of security scheme: oauth2",
            "key": "Authorization",
            "value": "<token>"
          }
        ],
        "body": {
          "mode": "formdata",
          "formdata": [
            {
              "key": "share_rc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Virtual Room Connector(s)](https://support.zoom.us/hc/en-us/articles/202134758-Getting-Started-With-Virtual-Room-Connector) that are set up by the master account. Virtual Room Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "room_connector_list",
              "value": "[\"officia dolor deserunt elit tempor\",\"dolor ullamco\"]",
              "description": "Specify the IP addresses of the Room Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Room Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_rc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "share_mc",
              "value": "false",
              "description": "Enable/disable the option for a sub account to use shared [Meeting Connector(s)](https://support.zoom.us/hc/en-us/articles/201363093-Getting-Started-with-the-Meeting-Connector) that are set up by the master account. Meeting Connectors can only be used by On-prem users.",
              "type": "text"
            },
            {
              "key": "meeting_connector_list",
              "value": "[\"fugiat et nisi\",\"dolor officia aliquip sed\"]",
              "description": "Specify the IP addresses of the Meeting Connectors that you would like to share with the sub account. Multiple values can be separated by comma. If no value is provided in this field, all the Meeting Connectors of a master account will be shared with the sub account.\n\n\n**Note:** This option can only be used if the value of `share_mc` is set to `true`.",
              "type": "text"
            },
            {
              "key": "pay_mode",
              "value": "master",
              "description": "Payee:<br>`master` - master account holder pays.<br>`sub` - Sub account holder pays. (This can only be one of master,sub)",
              "type": "text"
            },
            {
              "key": "billing_auto_renew",
              "value": "true",
              "description": "Toggle whether automatic billing renewal is on or off.",
              "type": "text"
            }
          ]
        },
        "url": {
          "raw": "{{baseUrl}}/accounts/:accountId/options",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "accounts",
            ":accountId",
            "options"
          ],
          "variable": [
            {
              "key": "accountId",
              "value": "quis officia in reprehenderit",
              "description": "(Required) The account's ID."
            }
          ]
        }
      },
      "status": "Not Found",
      "code": 404,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    }
  ]
}