class PureCloud::ArchitectApi
Attributes
Public Class Methods
# File lib/purecloud/api/architect_api.rb, line 23 def initialize(api_client = ApiClient.default) @api_client = api_client end
Public Instance Methods
Batch-delete a list of prompts asynchronously Multiple IDs can be specified, in which case all specified prompts will be deleted. @param id List of Prompt
IDs @param [Hash] opts the optional parameters @return [Operation]
# File lib/purecloud/api/architect_api.rb, line 32 def delete_prompts(id, opts = {}) data, status_code, headers = delete_prompts_with_http_info(id, opts) return data end
Delete specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [BOOLEAN] :all_resources Whether or not to delete all the prompt resources @return [nil]
# File lib/purecloud/api/architect_api.rb, line 94 def delete_prompts_prompt_id(prompt_id, opts = {}) delete_prompts_prompt_id_with_http_info(prompt_id, opts) return nil end
Delete specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [nil]
# File lib/purecloud/api/architect_api.rb, line 156 def delete_prompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) delete_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return nil end
Delete specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 167 def delete_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#delete_prompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling delete_prompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling delete_prompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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: ArchitectApi#delete_prompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Delete specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [BOOLEAN] :all_resources Whether or not to delete all the prompt resources @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 105 def delete_prompts_prompt_id_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#delete_prompts_prompt_id ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling delete_prompts_prompt_id" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} query_params[:'allResources'] = opts[:'all_resources'] if opts[:'all_resources'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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: ArchitectApi#delete_prompts_prompt_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Batch-delete a list of prompts asynchronously Multiple IDs can be specified, in which case all specified prompts will be deleted. @param id List of Prompt
IDs @param [Hash] opts the optional parameters @return [Array<(Operation
, Fixnum, Hash)>] Operation
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 42 def delete_prompts_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#delete_prompts ..." end # verify the required parameter 'id' is set fail "Missing the required parameter 'id' when calling delete_prompts" if id.nil? # resource path local_var_path = "/api/v2/architect/prompts".sub('{format}','json') # query parameters query_params = {} query_params[:'id'] = @api_client.build_collection_param(id, :multi) # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'Operation') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#delete_prompts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Delete a system prompt resource override.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [String]
# File lib/purecloud/api/architect_api.rb, line 220 def delete_systemprompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) data, status_code, headers = delete_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return data end
Delete a system prompt resource override.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [Array<(String, Fixnum, Hash)>] String data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 231 def delete_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#delete_systemprompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling delete_systemprompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling delete_systemprompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'String') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#delete_systemprompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a pageable list of flows, filtered by query parameters Multiple IDs can be specified, in which case all matching flows will be returned, and no other parameters will be evaluated. @param type Type @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number (default to 1) @option opts [Integer] :page_size Page
size (default to 25) @option opts [String] :sort_by Sort by (default to id) @option opts [String] :sort_order Sort order (default to asc) @option opts [Array<String>] :id ID @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @option opts [String] :publish_version_id Publish version ID @option opts [String] :editable_by Editable by @option opts [String] :locked_by Locked by @option opts [String] :secure Secure @option opts [BOOLEAN] :deleted Include deleted (default to false) @option opts [BOOLEAN] :include_schemas Include variable schemas (default to false) @return [FlowEntityListing]
# File lib/purecloud/api/architect_api.rb, line 298 def get_flows(type, opts = {}) data, status_code, headers = get_flows_with_http_info(type, opts) return data end
Get a pageable list of flows, filtered by query parameters Multiple IDs can be specified, in which case all matching flows will be returned, and no other parameters will be evaluated. @param type Type @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number @option opts [Integer] :page_size Page
size @option opts [String] :sort_by Sort by @option opts [String] :sort_order Sort order @option opts [Array<String>] :id ID @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @option opts [String] :publish_version_id Publish version ID @option opts [String] :editable_by Editable by @option opts [String] :locked_by Locked by @option opts [String] :secure Secure @option opts [BOOLEAN] :deleted Include deleted @option opts [BOOLEAN] :include_schemas Include variable schemas @return [Array<(FlowEntityListing
, Fixnum, Hash)>] FlowEntityListing
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 322 def get_flows_with_http_info(type, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_flows ..." end # verify the required parameter 'type' is set fail "Missing the required parameter 'type' when calling get_flows" if type.nil? if opts[:'secure'] && !['any', 'checkedin', 'published'].include?(opts[:'secure']) fail 'invalid value for "secure", must be one of any, checkedin, published' end # resource path local_var_path = "/api/v2/flows".sub('{format}','json') # query parameters query_params = {} query_params[:'type'] = type query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'sortOrder'] = opts[:'sort_order'] if opts[:'sort_order'] query_params[:'id'] = @api_client.build_collection_param(opts[:'id'], :multi) if opts[:'id'] query_params[:'name'] = opts[:'name'] if opts[:'name'] query_params[:'description'] = opts[:'description'] if opts[:'description'] query_params[:'nameOrDescription'] = opts[:'name_or_description'] if opts[:'name_or_description'] query_params[:'publishVersionId'] = opts[:'publish_version_id'] if opts[:'publish_version_id'] query_params[:'editableBy'] = opts[:'editable_by'] if opts[:'editable_by'] query_params[:'lockedBy'] = opts[:'locked_by'] if opts[:'locked_by'] query_params[:'secure'] = opts[:'secure'] if opts[:'secure'] query_params[:'deleted'] = opts[:'deleted'] if opts[:'deleted'] query_params[:'includeSchemas'] = opts[:'include_schemas'] if opts[:'include_schemas'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'FlowEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_flows\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a pageable list of user prompts The returned list is pageable, and query parameters can be used for filtering. Multiple names can be specified, in which case all matching prompts will be returned, and no other filters will be evaluated. @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number (default to 1) @option opts [Integer] :page_size Page
size (default to 25) @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @return [PromptEntityListing]
# File lib/purecloud/api/architect_api.rb, line 395 def get_prompts(opts = {}) data, status_code, headers = get_prompts_with_http_info(opts) return data end
Get specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @return [Prompt]
# File lib/purecloud/api/architect_api.rb, line 461 def get_prompts_prompt_id(prompt_id, opts = {}) data, status_code, headers = get_prompts_prompt_id_with_http_info(prompt_id, opts) return data end
Get a pageable list of user prompt resources The returned list is pageable, and query parameters can be used for filtering. @param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number (default to 1) @option opts [Integer] :page_size Page
size (default to 25) @return [PromptAssetEntityListing]
# File lib/purecloud/api/architect_api.rb, line 523 def get_prompts_prompt_id_resources(prompt_id, opts = {}) data, status_code, headers = get_prompts_prompt_id_resources_with_http_info(prompt_id, opts) return data end
Get specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [PromptAsset]
# File lib/purecloud/api/architect_api.rb, line 588 def get_prompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) data, status_code, headers = get_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return data end
Get specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [Array<(PromptAsset
, Fixnum, Hash)>] PromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 599 def get_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_prompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_prompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling get_prompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'PromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_prompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a pageable list of user prompt resources The returned list is pageable, and query parameters can be used for filtering. @param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number @option opts [Integer] :page_size Page
size @return [Array<(PromptAssetEntityListing
, Fixnum, Hash)>] PromptAssetEntityListing
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 535 def get_prompts_prompt_id_resources_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_prompts_prompt_id_resources ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_prompts_prompt_id_resources" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}/resources".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'PromptAssetEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_prompts_prompt_id_resources\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @return [Array<(Prompt
, Fixnum, Hash)>] Prompt
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 471 def get_prompts_prompt_id_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_prompts_prompt_id ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_prompts_prompt_id" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'Prompt') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_prompts_prompt_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a pageable list of user prompts The returned list is pageable, and query parameters can be used for filtering. Multiple names can be specified, in which case all matching prompts will be returned, and no other filters will be evaluated. @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number @option opts [Integer] :page_size Page
size @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @return [Array<(PromptEntityListing
, Fixnum, Hash)>] PromptEntityListing
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 409 def get_prompts_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_prompts ..." end # resource path local_var_path = "/api/v2/architect/prompts".sub('{format}','json') # query parameters query_params = {} query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'name'] = opts[:'name'] if opts[:'name'] query_params[:'description'] = opts[:'description'] if opts[:'description'] query_params[:'nameOrDescription'] = opts[:'name_or_description'] if opts[:'name_or_description'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'PromptEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_prompts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get System Prompts
@param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number (default to 1) @option opts [Integer] :page_size Page
size (default to 25) @option opts [String] :sort_by Sort by (default to id) @option opts [String] :sort_order Sort order (default to asc) @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @return [SystemPromptEntityListing]
# File lib/purecloud/api/architect_api.rb, line 658 def get_systemprompts(opts = {}) data, status_code, headers = get_systemprompts_with_http_info(opts) return data end
Get a system prompt
@param prompt_id promptId @param [Hash] opts the optional parameters @return [SystemPrompt]
# File lib/purecloud/api/architect_api.rb, line 728 def get_systemprompts_prompt_id(prompt_id, opts = {}) data, status_code, headers = get_systemprompts_prompt_id_with_http_info(prompt_id, opts) return data end
Get IVR System Prompt
resources.
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number (default to 1) @option opts [Integer] :page_size Page
size (default to 25) @option opts [String] :sort_by Sort by (default to id) @option opts [String] :sort_order Sort order (default to asc) @return [SystemPromptAssetEntityListing]
# File lib/purecloud/api/architect_api.rb, line 792 def get_systemprompts_prompt_id_resources(prompt_id, opts = {}) data, status_code, headers = get_systemprompts_prompt_id_resources_with_http_info(prompt_id, opts) return data end
Get a system prompt resource.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [SystemPromptAsset]
# File lib/purecloud/api/architect_api.rb, line 861 def get_systemprompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) data, status_code, headers = get_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return data end
Get a system prompt resource.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @return [Array<(SystemPromptAsset
, Fixnum, Hash)>] SystemPromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 872 def get_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_systemprompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_systemprompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling get_systemprompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'SystemPromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_systemprompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get IVR System Prompt
resources.
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number @option opts [Integer] :page_size Page
size @option opts [String] :sort_by Sort by @option opts [String] :sort_order Sort order @return [Array<(SystemPromptAssetEntityListing
, Fixnum, Hash)>] SystemPromptAssetEntityListing
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 806 def get_systemprompts_prompt_id_resources_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_systemprompts_prompt_id_resources ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_systemprompts_prompt_id_resources" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}/resources".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'sortOrder'] = opts[:'sort_order'] if opts[:'sort_order'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'SystemPromptAssetEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_systemprompts_prompt_id_resources\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a system prompt
@param prompt_id promptId @param [Hash] opts the optional parameters @return [Array<(SystemPrompt
, Fixnum, Hash)>] SystemPrompt
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 738 def get_systemprompts_prompt_id_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_systemprompts_prompt_id ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling get_systemprompts_prompt_id" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'SystemPrompt') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_systemprompts_prompt_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get System Prompts
@param [Hash] opts the optional parameters @option opts [Integer] :page_number Page
number @option opts [Integer] :page_size Page
size @option opts [String] :sort_by Sort by @option opts [String] :sort_order Sort order @option opts [String] :name Name @option opts [String] :description Description @option opts [String] :name_or_description Name or description @return [Array<(SystemPromptEntityListing
, Fixnum, Hash)>] SystemPromptEntityListing
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 674 def get_systemprompts_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#get_systemprompts ..." end # resource path local_var_path = "/api/v2/architect/systemprompts".sub('{format}','json') # query parameters query_params = {} query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'sortOrder'] = opts[:'sort_order'] if opts[:'sort_order'] query_params[:'name'] = opts[:'name'] if opts[:'name'] query_params[:'description'] = opts[:'description'] if opts[:'description'] query_params[:'nameOrDescription'] = opts[:'name_or_description'] if opts[:'name_or_description'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'SystemPromptEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#get_systemprompts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create a new user prompt
@param [Hash] opts the optional parameters @option opts [Prompt] :body @return [Prompt]
# File lib/purecloud/api/architect_api.rb, line 925 def post_prompts(opts = {}) data, status_code, headers = post_prompts_with_http_info(opts) return data end
Create a new user prompt resource
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [PromptAssetCreate] :body @return [PromptAsset]
# File lib/purecloud/api/architect_api.rb, line 983 def post_prompts_prompt_id_resources(prompt_id, opts = {}) data, status_code, headers = post_prompts_prompt_id_resources_with_http_info(prompt_id, opts) return data end
Create a new user prompt resource
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [PromptAssetCreate] :body @return [Array<(PromptAsset
, Fixnum, Hash)>] PromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 994 def post_prompts_prompt_id_resources_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#post_prompts_prompt_id_resources ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling post_prompts_prompt_id_resources" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}/resources".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] 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 => 'PromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#post_prompts_prompt_id_resources\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create a new user prompt
@param [Hash] opts the optional parameters @option opts [Prompt] :body @return [Array<(Prompt
, Fixnum, Hash)>] Prompt
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 935 def post_prompts_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#post_prompts ..." end # resource path local_var_path = "/api/v2/architect/prompts".sub('{format}','json') # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] 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 => 'Prompt') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#post_prompts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create system prompt resource override.
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [SystemPromptAsset] :body @return [SystemPromptAsset]
# File lib/purecloud/api/architect_api.rb, line 1045 def post_systemprompts_prompt_id_resources(prompt_id, opts = {}) data, status_code, headers = post_systemprompts_prompt_id_resources_with_http_info(prompt_id, opts) return data end
Create system prompt resource override.
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [SystemPromptAsset] :body @return [Array<(SystemPromptAsset
, Fixnum, Hash)>] SystemPromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 1056 def post_systemprompts_prompt_id_resources_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#post_systemprompts_prompt_id_resources ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling post_systemprompts_prompt_id_resources" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}/resources".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] 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 => 'SystemPromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#post_systemprompts_prompt_id_resources\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Prompt] :body @return [Prompt]
# File lib/purecloud/api/architect_api.rb, line 1107 def put_prompts_prompt_id(prompt_id, opts = {}) data, status_code, headers = put_prompts_prompt_id_with_http_info(prompt_id, opts) return data end
Update specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @option opts [PromptAsset] :body @return [PromptAsset]
# File lib/purecloud/api/architect_api.rb, line 1170 def put_prompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) data, status_code, headers = put_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return data end
Update specified user prompt resource
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @option opts [PromptAsset] :body @return [Array<(PromptAsset
, Fixnum, Hash)>] PromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 1182 def put_prompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#put_prompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling put_prompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling put_prompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'PromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#put_prompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update specified user prompt
@param prompt_id Prompt
ID @param [Hash] opts the optional parameters @option opts [Prompt] :body @return [Array<(Prompt
, Fixnum, Hash)>] Prompt
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 1118 def put_prompts_prompt_id_with_http_info(prompt_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#put_prompts_prompt_id ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling put_prompts_prompt_id" if prompt_id.nil? # resource path local_var_path = "/api/v2/architect/prompts/{promptId}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Prompt') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#put_prompts_prompt_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Updates a system prompt resource override.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @option opts [SystemPromptAsset] :body @return [SystemPromptAsset]
# File lib/purecloud/api/architect_api.rb, line 1237 def put_systemprompts_prompt_id_resources_languagecode(prompt_id, language_code, opts = {}) data, status_code, headers = put_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts) return data end
Updates a system prompt resource override.
@param prompt_id Prompt
ID @param language_code Language
@param [Hash] opts the optional parameters @option opts [SystemPromptAsset] :body @return [Array<(SystemPromptAsset
, Fixnum, Hash)>] SystemPromptAsset
data, response status code and response headers
# File lib/purecloud/api/architect_api.rb, line 1249 def put_systemprompts_prompt_id_resources_languagecode_with_http_info(prompt_id, language_code, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ArchitectApi#put_systemprompts_prompt_id_resources_languagecode ..." end # verify the required parameter 'prompt_id' is set fail "Missing the required parameter 'prompt_id' when calling put_systemprompts_prompt_id_resources_languagecode" if prompt_id.nil? # verify the required parameter 'language_code' is set fail "Missing the required parameter 'language_code' when calling put_systemprompts_prompt_id_resources_languagecode" if language_code.nil? # resource path local_var_path = "/api/v2/architect/systemprompts/{promptId}/resources/{languageCode}".sub('{format}','json').sub('{' + 'promptId' + '}', prompt_id.to_s).sub('{' + 'languageCode' + '}', language_code.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'SystemPromptAsset') if @api_client.config.debugging @api_client.config.logger.debug "API called: ArchitectApi#put_systemprompts_prompt_id_resources_languagecode\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end