class ZoomUs::TSP

Attributes

api_client[RW]

Public Class Methods

new(api_client = ApiClient.default) click to toggle source
# File lib/zoom_us/tsp.rb, line 19
def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Public Instance Methods

tsp(opts = {}) click to toggle source

Get Account's TSP Information Get information on Telephony Service Provider on an account level.
Scopes: `tsp:read:admin` `tsp:read`
Prerequisites:
* A Pro or a higher plan. @param [Hash] opts the optional parameters @return [InlineResponse20045]

# File lib/zoom_us/tsp.rb, line 26
def tsp(opts = {})
  data, _status_code, _headers = tsp_with_http_info(opts)
  data
end
tsp_update(body, opts = {}) click to toggle source

Update account's TSP information Update information of the Telephony Service Provider set up on an account.
Prerequisites:
TSP account option should be enabled.
Scopes: `tsp:write:admin` `tsp:write`
@param body TSP Account @param [Hash] opts the optional parameters @return [nil]

# File lib/zoom_us/tsp.rb, line 75
def tsp_update(body, opts = {})
  tsp_update_with_http_info(body, opts)
  nil
end
tsp_update_with_http_info(body, opts = {}) click to toggle source

Update account&#39;s TSP information Update information of the Telephony Service Provider set up on an account.&lt;br&gt; Prerequisites:&lt;br&gt; TSP account option should be enabled.&lt;br&gt; Scopes: &#x60;tsp:write:admin&#x60; &#x60;tsp:write&#x60;&lt;br&gt; @param body TSP Account @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/zoom_us/tsp.rb, line 85
def tsp_update_with_http_info(body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.tsp_update ...'
  end
  # verify the required parameter 'body' is set
  if @api_client.config.client_side_validation && body.nil?
    fail ArgumentError, "Missing the required parameter 'body' when calling TSPApi.tsp_update"
  end
  # resource path
  local_var_path = '/tsp'

  # 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(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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#tsp_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
tsp_url_update(user_id, opts = {}) click to toggle source

Set Global Dial-in URL for a TSP User A global dial-in page can provide a list of global access numbers using which audio conferencing can be conducted. By calling this API, you can set the url for the global dial-in page of a user whose Zoom account has TSP and special TSP with third-party audio conferencing options enabled. <p></p> Scopes:`tsp:write:admin` `tsp:write`
@param user_id The userId or email address of the user. @param [Hash] opts the optional parameters @option opts [TSPGlobalDialInURLSetting] :body Global dial-in URL of the user. @return [nil]

# File lib/zoom_us/tsp.rb, line 129
def tsp_url_update(user_id, opts = {})
  tsp_url_update_with_http_info(user_id, opts)
  nil
end
tsp_url_update_with_http_info(user_id, opts = {}) click to toggle source

Set Global Dial-in URL for a TSP User A global dial-in page can provide a list of global access numbers using which audio conferencing can be conducted. By calling this API, you can set the url for the global dial-in page of a user whose Zoom account has TSP and special TSP with third-party audio conferencing options enabled. &lt;p&gt;&lt;/p&gt; Scopes:&#x60;tsp:write:admin&#x60; &#x60;tsp:write&#x60;&lt;br&gt; @param user_id The userId or email address of the user. @param [Hash] opts the optional parameters @option opts [TSPGlobalDialInURLSetting] :body Global dial-in URL of the user. @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/zoom_us/tsp.rb, line 140
def tsp_url_update_with_http_info(user_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.tsp_url_update ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.tsp_url_update"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp/settings'.sub('{' + 'userId' + '}', user_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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#tsp_url_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
tsp_with_http_info(opts = {}) click to toggle source

Get Account&#39;s TSP Information Get information on Telephony Service Provider on an account level.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:read:admin&#x60; &#x60;tsp:read&#x60;&lt;br&gt; Prerequisites:&lt;br&gt; * A Pro or a higher plan. @param [Hash] opts the optional parameters @return [Array<(InlineResponse20045, Fixnum, Hash)>] InlineResponse20045 data, response status code and response headers

# File lib/zoom_us/tsp.rb, line 35
def tsp_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.tsp ...'
  end
  # resource path
  local_var_path = '/tsp'

  # 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 => 'InlineResponse20045')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#tsp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
user_ts_ps(user_id, opts = {}) click to toggle source

List User's TSP accounts A user can have a maximum of two TSP accounts. Use this API to list all TSP accounts of a user.
Scopes: `tsp:read:admin` `tsp:read`
@param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param [Hash] opts the optional parameters @return [InlineResponse20050]

# File lib/zoom_us/tsp.rb, line 183
def user_ts_ps(user_id, opts = {})
  data, _status_code, _headers = user_ts_ps_with_http_info(user_id, opts)
  data
end
user_ts_ps_with_http_info(user_id, opts = {}) click to toggle source

List User&#39;s TSP accounts A user can have a maximum of two TSP accounts. Use this API to list all TSP accounts of a user.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:read:admin&#x60; &#x60;tsp:read&#x60;&lt;br&gt; @param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param [Hash] opts the optional parameters @return [Array<(InlineResponse20050, Fixnum, Hash)>] InlineResponse20050 data, response status code and response headers

# File lib/zoom_us/tsp.rb, line 193
def user_ts_ps_with_http_info(user_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.user_ts_ps ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.user_ts_ps"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp'.sub('{' + 'userId' + '}', user_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 => 'InlineResponse20050')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#user_ts_ps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
user_tsp(user_id, tsp_id, opts = {}) click to toggle source

Get a User's TSP Account Each user can have a maximum of two TSP accounts. Use this API to retrieve details of a specific TSP account enabled for a specific user.
Scopes: `tsp:read:admin` `tsp:read`
@param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param [Hash] opts the optional parameters @return [TSPAccount]

# File lib/zoom_us/tsp.rb, line 238
def user_tsp(user_id, tsp_id, opts = {})
  data, _status_code, _headers = user_tsp_with_http_info(user_id, tsp_id, opts)
  data
end
user_tsp_create(user_id, body, opts = {}) click to toggle source

Add a User's TSP Account Add a user's TSP account.
Scopes: `tsp:write:admin` `tsp:write`
@param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param body TSP account. @param [Hash] opts the optional parameters @return [TSPAccountsList2]

# File lib/zoom_us/tsp.rb, line 302
def user_tsp_create(user_id, body, opts = {})
  data, _status_code, _headers = user_tsp_create_with_http_info(user_id, body, opts)
  data
end
user_tsp_create_with_http_info(user_id, body, opts = {}) click to toggle source

Add a User&#39;s TSP Account Add a user&#39;s TSP account.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:write:admin&#x60; &#x60;tsp:write&#x60;&lt;br&gt; @param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param body TSP account. @param [Hash] opts the optional parameters @return [Array<(TSPAccountsList2, Fixnum, Hash)>] TSPAccountsList2 data, response status code and response headers

# File lib/zoom_us/tsp.rb, line 313
def user_tsp_create_with_http_info(user_id, body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.user_tsp_create ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.user_tsp_create"
  end
  # verify the required parameter 'body' is set
  if @api_client.config.client_side_validation && body.nil?
    fail ArgumentError, "Missing the required parameter 'body' when calling TSPApi.user_tsp_create"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp'.sub('{' + 'userId' + '}', user_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(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 => 'TSPAccountsList2')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#user_tsp_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
user_tsp_delete(user_id, tsp_id, opts = {}) click to toggle source

Delete a User's TSP Account Delete a user's TSP account.
Scopes: `tsp:write:admin` `tsp:write`
@param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param [Hash] opts the optional parameters @return [nil]

# File lib/zoom_us/tsp.rb, line 362
def user_tsp_delete(user_id, tsp_id, opts = {})
  user_tsp_delete_with_http_info(user_id, tsp_id, opts)
  nil
end
user_tsp_delete_with_http_info(user_id, tsp_id, opts = {}) click to toggle source

Delete a User&#39;s TSP Account Delete a user&#39;s TSP account.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:write:admin&#x60; &#x60;tsp:write&#x60;&lt;br&gt; @param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/zoom_us/tsp.rb, line 373
def user_tsp_delete_with_http_info(user_id, tsp_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.user_tsp_delete ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.user_tsp_delete"
  end
  # verify the required parameter 'tsp_id' is set
  if @api_client.config.client_side_validation && tsp_id.nil?
    fail ArgumentError, "Missing the required parameter 'tsp_id' when calling TSPApi.user_tsp_delete"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['1', '2'].include?(tsp_id)
    fail ArgumentError, "invalid value for 'tsp_id', must be one of 1, 2"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp/{tspId}'.sub('{' + 'userId' + '}', user_id.to_s).sub('{' + 'tspId' + '}', tsp_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(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#user_tsp_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
user_tsp_update(user_id, tsp_id, body, opts = {}) click to toggle source

Update a TSP Account Update a user's TSP account.
Scopes: `tsp:write:admin` `tsp:write`
@param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param body TSP account. @param [Hash] opts the optional parameters @return [nil]

# File lib/zoom_us/tsp.rb, line 426
def user_tsp_update(user_id, tsp_id, body, opts = {})
  user_tsp_update_with_http_info(user_id, tsp_id, body, opts)
  nil
end
user_tsp_update_with_http_info(user_id, tsp_id, body, opts = {}) click to toggle source

Update a TSP Account Update a user&#39;s TSP account.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:write:admin&#x60; &#x60;tsp:write&#x60;&lt;br&gt; @param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param body TSP account. @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/zoom_us/tsp.rb, line 438
def user_tsp_update_with_http_info(user_id, tsp_id, body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.user_tsp_update ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.user_tsp_update"
  end
  # verify the required parameter 'tsp_id' is set
  if @api_client.config.client_side_validation && tsp_id.nil?
    fail ArgumentError, "Missing the required parameter 'tsp_id' when calling TSPApi.user_tsp_update"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['1', '2'].include?(tsp_id)
    fail ArgumentError, "invalid value for 'tsp_id', must be one of 1, 2"
  end
  # verify the required parameter 'body' is set
  if @api_client.config.client_side_validation && body.nil?
    fail ArgumentError, "Missing the required parameter 'body' when calling TSPApi.user_tsp_update"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp/{tspId}'.sub('{' + 'userId' + '}', user_id.to_s).sub('{' + 'tspId' + '}', tsp_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(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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#user_tsp_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
user_tsp_with_http_info(user_id, tsp_id, opts = {}) click to toggle source

Get a User&#39;s TSP Account Each user can have a maximum of two TSP accounts. Use this API to retrieve details of a specific TSP account enabled for a specific user.&lt;br&gt;&lt;br&gt; Scopes: &#x60;tsp:read:admin&#x60; &#x60;tsp:read&#x60;&lt;br&gt; @param user_id The user ID or email address of the user. For user-level apps, pass &#x60;me&#x60; as the value for userId. @param tsp_id TSP account ID. @param [Hash] opts the optional parameters @return [Array<(TSPAccount, Fixnum, Hash)>] TSPAccount data, response status code and response headers

# File lib/zoom_us/tsp.rb, line 249
def user_tsp_with_http_info(user_id, tsp_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TSPApi.user_tsp ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling TSPApi.user_tsp"
  end
  # verify the required parameter 'tsp_id' is set
  if @api_client.config.client_side_validation && tsp_id.nil?
    fail ArgumentError, "Missing the required parameter 'tsp_id' when calling TSPApi.user_tsp"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['1', '2'].include?(tsp_id)
    fail ArgumentError, "invalid value for 'tsp_id', must be one of 1, 2"
  end
  # resource path
  local_var_path = '/users/{userId}/tsp/{tspId}'.sub('{' + 'userId' + '}', user_id.to_s).sub('{' + 'tspId' + '}', tsp_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 => 'TSPAccount')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TSPApi#user_tsp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end