Class: ZoomUs::PhoneSite
- Inherits:
-
Object
- Object
- ZoomUs::PhoneSite
- Defined in:
- lib/zoom_us/phone_site.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#create_phone_site(opts = {}) ⇒ InlineResponse204
Create a Phone Site Sites allow you to organize Zoom Phone users in your organization.
-
#create_phone_site_with_http_info(opts = {}) ⇒ Array<(InlineResponse204, Fixnum, Hash)>
Create a Phone Site Sites allow you to organize Zoom Phone users in your organization.
-
#delete_phone_site(site_id, transfer_site_id, opts = {}) ⇒ Object
Delete a Phone Site Sites allow you to organize Zoom Phone users in your organization.
-
#delete_phone_site_with_http_info(site_id, transfer_site_id, opts = {}) ⇒ Array<(Object, Fixnum, Hash)>
Delete a Phone Site Sites allow you to organize Zoom Phone users in your organization.
-
#get_a_site(site_id, opts = {}) ⇒ InlineResponse2004
Get Phone Site Details Sites allow you to organize Zoom Phone users in your organization.
-
#get_a_site_with_http_info(site_id, opts = {}) ⇒ Array<(InlineResponse2004, Fixnum, Hash)>
Get Phone Site Details Sites allow you to organize Zoom Phone users in your organization.
-
#initialize(api_client = ApiClient.default) ⇒ PhoneSite
constructor
A new instance of PhoneSite.
-
#list_phone_sites(opts = {}) ⇒ InlineResponse2003
List Phone Sites Sites allow you to organize Zoom Phone users in your organization.
-
#list_phone_sites_with_http_info(opts = {}) ⇒ Array<(InlineResponse2003, Fixnum, Hash)>
List Phone Sites Sites allow you to organize Zoom Phone users in your organization.
-
#update_site_details(site_id, opts = {}) ⇒ Object
Update Phone Site Details Sites allow you to organize Zoom Phone users in your organization.
-
#update_site_details_with_http_info(site_id, opts = {}) ⇒ Array<(Object, Fixnum, Hash)>
Update Phone Site Details Sites allow you to organize Zoom Phone users in your organization.
Constructor Details
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/zoom_us/phone_site.rb', line 17 def api_client @api_client end |
Instance Method Details
#create_phone_site(opts = {}) ⇒ InlineResponse204
Create a Phone Site Sites allow you to organize Zoom Phone users in your organization. Use this API to create a [Site](support.zoom.us/hc/en-us/articles/360020809672).
Prerequisites:
* Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15). * Pro or a higher account with Zoom Phone enabled. Scope: ‘phone:write:admin`
27 28 29 30 |
# File 'lib/zoom_us/phone_site.rb', line 27 def create_phone_site(opts = {}) data, _status_code, _headers = create_phone_site_with_http_info(opts) data end |
#create_phone_site_with_http_info(opts = {}) ⇒ Array<(InlineResponse204, Fixnum, Hash)>
Create a Phone Site Sites allow you to organize Zoom Phone users in your organization. Use this API to create a [Site](support.zoom.us/hc/en-us/articles/360020809672).<br> Prerequisites:<br> * Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15). * Pro or a higher account with Zoom Phone enabled. Scope: `phone:write:admin`<br>
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
# File 'lib/zoom_us/phone_site.rb', line 37 def create_phone_site_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PhoneSiteApi.create_phone_site ...' end # resource path local_var_path = '/phone/sites' # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse204') if @api_client.config.debugging @api_client.config.logger.debug "API called: PhoneSiteApi#create_phone_site\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_phone_site(site_id, transfer_site_id, opts = {}) ⇒ Object
Delete a Phone Site Sites allow you to organize Zoom Phone users in your organization. Use this API to delete a specific [site](support.zoom.us/hc/en-us/articles/360020809672) in a Zoom account. To delete a site, in the query parameter, you must provide the Site ID of another site where the assets of current site (users, numbers and phones) can be transferred to. You cannot use this API to delete the main site. Prerequisites:
* Account must have a Pro or a higher plan with Zoom Phone license. * [Multiple Sites](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites) must be enabled.
Scope: ‘phone:write:admin`
78 79 80 81 |
# File 'lib/zoom_us/phone_site.rb', line 78 def delete_phone_site(site_id, transfer_site_id, opts = {}) data, _status_code, _headers = delete_phone_site_with_http_info(site_id, transfer_site_id, opts) data end |
#delete_phone_site_with_http_info(site_id, transfer_site_id, opts = {}) ⇒ Array<(Object, Fixnum, Hash)>
Delete a Phone Site Sites allow you to organize Zoom Phone users in your organization. Use this API to delete a specific [site](support.zoom.us/hc/en-us/articles/360020809672) in a Zoom account. To delete a site, in the query parameter, you must provide the Site ID of another site where the assets of current site (users, numbers and phones) can be transferred to. You cannot use this API to delete the main site. Prerequisites: <br> * Account must have a Pro or a higher plan with Zoom Phone license. * [Multiple Sites](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites) must be enabled.<br> Scope: `phone:write:admin` <br>
89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 |
# File 'lib/zoom_us/phone_site.rb', line 89 def delete_phone_site_with_http_info(site_id, transfer_site_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PhoneSiteApi.delete_phone_site ...' end # verify the required parameter 'site_id' is set if @api_client.config.client_side_validation && site_id.nil? fail ArgumentError, "Missing the required parameter 'site_id' when calling PhoneSiteApi.delete_phone_site" end # verify the required parameter 'transfer_site_id' is set if @api_client.config.client_side_validation && transfer_site_id.nil? fail ArgumentError, "Missing the required parameter 'transfer_site_id' when calling PhoneSiteApi.delete_phone_site" end # resource path local_var_path = '/phone/sites/{siteId}'.sub('{' + 'siteId' + '}', site_id.to_s) # query parameters query_params = {} query_params[:'transfer_site_id'] = transfer_site_id # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Object') if @api_client.config.debugging @api_client.config.logger.debug "API called: PhoneSiteApi#delete_phone_site\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_a_site(site_id, opts = {}) ⇒ InlineResponse2004
Get Phone Site Details Sites allow you to organize Zoom Phone users in your organization. Use this API to get information about a specific [site](support.zoom.us/hc/en-us/articles/360020809672). Prerequisites:
* Account must have a Pro or a higher plan with Zoom Phone license. * Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15).
Scope: ‘phone:read:admin`
138 139 140 141 |
# File 'lib/zoom_us/phone_site.rb', line 138 def get_a_site(site_id, opts = {}) data, _status_code, _headers = get_a_site_with_http_info(site_id, opts) data end |
#get_a_site_with_http_info(site_id, opts = {}) ⇒ Array<(InlineResponse2004, Fixnum, Hash)>
Get Phone Site Details Sites allow you to organize Zoom Phone users in your organization. Use this API to get information about a specific [site](support.zoom.us/hc/en-us/articles/360020809672). Prerequisites: <br> * Account must have a Pro or a higher plan with Zoom Phone license. * Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15).<br> Scope: `phone:read:admin`<br>
148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 |
# File 'lib/zoom_us/phone_site.rb', line 148 def get_a_site_with_http_info(site_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PhoneSiteApi.get_a_site ...' end # verify the required parameter 'site_id' is set if @api_client.config.client_side_validation && site_id.nil? fail ArgumentError, "Missing the required parameter 'site_id' when calling PhoneSiteApi.get_a_site" end # resource path local_var_path = '/phone/sites/{siteId}'.sub('{' + 'siteId' + '}', site_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2004') if @api_client.config.debugging @api_client.config.logger.debug "API called: PhoneSiteApi#get_a_site\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_phone_sites(opts = {}) ⇒ InlineResponse2003
List Phone Sites Sites allow you to organize Zoom Phone users in your organization. Use this API to list all the [sites](support.zoom.us/hc/en-us/articles/360020809672) that have been created for an account.
Prerequisites:
* Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15). * Pro or a higher account with Zoom Phone enabled. Scope: ‘phone:read:admin`
193 194 195 196 |
# File 'lib/zoom_us/phone_site.rb', line 193 def list_phone_sites(opts = {}) data, _status_code, _headers = list_phone_sites_with_http_info(opts) data end |
#list_phone_sites_with_http_info(opts = {}) ⇒ Array<(InlineResponse2003, Fixnum, Hash)>
List Phone Sites Sites allow you to organize Zoom Phone users in your organization. Use this API to list all the [sites](support.zoom.us/hc/en-us/articles/360020809672) that have been created for an account.<br> Prerequisites:<br> * Multiple Sites must be [enabled](support.zoom.us/hc/en-us/articles/360020809672-Managing-Multiple-Sites#h_05c88e35-1593-491f-b1a8-b7139a75dc15). * Pro or a higher account with Zoom Phone enabled. Scope: `phone:read:admin`<br>
204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 |
# File 'lib/zoom_us/phone_site.rb', line 204 def list_phone_sites_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PhoneSiteApi.list_phone_sites ...' end if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 300 fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling PhoneSiteApi.list_phone_sites, must be smaller than or equal to 300.' end # resource path local_var_path = '/phone/sites' # query parameters query_params = {} query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'next_page_token'] = opts[:'next_page_token'] if !opts[:'next_page_token'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2003') if @api_client.config.debugging @api_client.config.logger.debug "API called: PhoneSiteApi#list_phone_sites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_site_details(site_id, opts = {}) ⇒ Object
Update Phone Site Details Sites allow you to organize Zoom Phone users in your organization. Use this API to update information about a specific [site](support.zoom.us/hc/en-us/articles/360020809672). Prerequisites:
* Account must have a Pro or a higher plan with Zoom Phone license. * Scope: ‘phone:write:admin`
251 252 253 254 |
# File 'lib/zoom_us/phone_site.rb', line 251 def update_site_details(site_id, opts = {}) data, _status_code, _headers = update_site_details_with_http_info(site_id, opts) data end |
#update_site_details_with_http_info(site_id, opts = {}) ⇒ Array<(Object, Fixnum, Hash)>
Update Phone Site Details Sites allow you to organize Zoom Phone users in your organization. Use this API to update information about a specific [site](support.zoom.us/hc/en-us/articles/360020809672). Prerequisites: <br> * Account must have a Pro or a higher plan with Zoom Phone license. * Scope: `phone:write:admin`<br>
262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 |
# File 'lib/zoom_us/phone_site.rb', line 262 def update_site_details_with_http_info(site_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PhoneSiteApi.update_site_details ...' end # verify the required parameter 'site_id' is set if @api_client.config.client_side_validation && site_id.nil? fail ArgumentError, "Missing the required parameter 'site_id' when calling PhoneSiteApi.update_site_details" end # resource path local_var_path = '/phone/sites/{siteId}'.sub('{' + 'siteId' + '}', site_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Object') if @api_client.config.debugging @api_client.config.logger.debug "API called: PhoneSiteApi#update_site_details\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |