class PureCloud::ContentManagementApi
Attributes
Public Class Methods
# File lib/purecloud/api/content_management_api.rb, line 23 def initialize(api_client = ApiClient.default) @api_client = api_client end
Public Instance Methods
Delete a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [BOOLEAN] :override Override any lock on the document @return [nil]
# File lib/purecloud/api/content_management_api.rb, line 33 def delete_documents_document_id(document_id, opts = {}) delete_documents_document_id_with_http_info(document_id, opts) return nil end
Delete a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [BOOLEAN] :override Override any lock on the document @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 44 def delete_documents_document_id_with_http_info(document_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#delete_documents_document_id ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling delete_documents_document_id" if document_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'override'] = opts[:'override'] if opts[:'override'] # 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: ContentManagementApi#delete_documents_document_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Cancel the command for this status
@param status_id Status ID @param [Hash] opts the optional parameters @return [nil]
# File lib/purecloud/api/content_management_api.rb, line 153 def delete_status_status_id(status_id, opts = {}) delete_status_status_id_with_http_info(status_id, opts) return nil end
Cancel the command for this status
@param status_id Status ID @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 163 def delete_status_status_id_with_http_info(status_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#delete_status_status_id ..." end # verify the required parameter 'status_id' is set fail "Missing the required parameter 'status_id' when calling delete_status_status_id" if status_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/status/{statusId}".sub('{format}','json').sub('{' + 'statusId' + '}', status_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(: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: ContentManagementApi#delete_status_status_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Delete a workspace
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :move_children_to_workspace_id New location for objects in deleted workspace. @return [nil]
# File lib/purecloud/api/content_management_api.rb, line 213 def delete_workspaces_workspace_id(workspace_id, opts = {}) delete_workspaces_workspace_id_with_http_info(workspace_id, opts) return nil end
Delete a member from a workspace
@param workspace_id Workspace
ID @param member_id Member ID @param [Hash] opts the optional parameters @return [nil]
# File lib/purecloud/api/content_management_api.rb, line 275 def delete_workspaces_workspace_id_members_member_id(workspace_id, member_id, opts = {}) delete_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, opts) return nil end
Delete a member from a workspace
@param workspace_id Workspace
ID @param member_id Member ID @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 286 def delete_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#delete_workspaces_workspace_id_members_member_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling delete_workspaces_workspace_id_members_member_id" if workspace_id.nil? # verify the required parameter 'member_id' is set fail "Missing the required parameter 'member_id' when calling delete_workspaces_workspace_id_members_member_id" if member_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/members/{memberId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'memberId' + '}', member_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(: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: ContentManagementApi#delete_workspaces_workspace_id_members_member_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Delete workspace tag Delete a tag from a workspace. Will remove this tag from all documents. @param workspace_id Workspace
ID @param tag_id Tag ID @param [Hash] opts the optional parameters @return [nil]
# File lib/purecloud/api/content_management_api.rb, line 339 def delete_workspaces_workspace_id_tagvalues_tag_id(workspace_id, tag_id, opts = {}) delete_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, opts) return nil end
Delete workspace tag Delete a tag from a workspace. Will remove this tag from all documents. @param workspace_id Workspace
ID @param tag_id Tag ID @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 350 def delete_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#delete_workspaces_workspace_id_tagvalues_tag_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling delete_workspaces_workspace_id_tagvalues_tag_id" if workspace_id.nil? # verify the required parameter 'tag_id' is set fail "Missing the required parameter 'tag_id' when calling delete_workspaces_workspace_id_tagvalues_tag_id" if tag_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues/{tagId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'tagId' + '}', tag_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(: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: ContentManagementApi#delete_workspaces_workspace_id_tagvalues_tag_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Delete a workspace
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :move_children_to_workspace_id New location for objects in deleted workspace. @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 224 def delete_workspaces_workspace_id_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#delete_workspaces_workspace_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling delete_workspaces_workspace_id" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'moveChildrenToWorkspaceId'] = opts[:'move_children_to_workspace_id'] if opts[:'move_children_to_workspace_id'] # 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: ContentManagementApi#delete_workspaces_workspace_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of documents.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :name Name @option opts [Array<String>] :expand Which fields, if any, to expand. @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [String] :sort_by name or dateCreated @option opts [String] :sort_order ascending or descending (default to ascending) @return [DocumentEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 408 def get_documents(workspace_id, opts = {}) data, status_code, headers = get_documents_with_http_info(workspace_id, opts) return data end
Get a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Document]
# File lib/purecloud/api/content_management_api.rb, line 482 def get_documents_document_id(document_id, opts = {}) data, status_code, headers = get_documents_document_id_with_http_info(document_id, opts) return data end
Get a list of audits for a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [String] :transaction_filter Transaction filter @option opts [String] :level level (default to USER) @option opts [String] :sort_by Sort by @option opts [String] :sort_order Sort order (default to ascending) @return [DocumentAuditEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 550 def get_documents_document_id_audits(document_id, opts = {}) data, status_code, headers = get_documents_document_id_audits_with_http_info(document_id, opts) return data end
Get a list of audits for a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [String] :transaction_filter Transaction filter @option opts [String] :level level @option opts [String] :sort_by Sort by @option opts [String] :sort_order Sort order @return [Array<(DocumentAuditEntityListing
, Fixnum, Hash)>] DocumentAuditEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 566 def get_documents_document_id_audits_with_http_info(document_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_documents_document_id_audits ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling get_documents_document_id_audits" if document_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}/audits".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'transactionFilter'] = opts[:'transaction_filter'] if opts[:'transaction_filter'] query_params[:'level'] = opts[:'level'] if opts[:'level'] 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 => 'DocumentAuditEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_documents_document_id_audits\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Download a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [String] :disposition Request how the content will be downloaded: a file attachment or inline. Default is attachment. @option opts [String] :content_type The requested format for the specified document. If supported, the document will be returned in that format. Example contentType=audio/wav @return [DownloadResponse]
# File lib/purecloud/api/content_management_api.rb, line 624 def get_documents_document_id_content(document_id, opts = {}) data, status_code, headers = get_documents_document_id_content_with_http_info(document_id, opts) return data end
Download a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [String] :disposition Request how the content will be downloaded: a file attachment or inline. Default is attachment. @option opts [String] :content_type The requested format for the specified document. If supported, the document will be returned in that format. Example contentType=audio/wav @return [Array<(DownloadResponse
, Fixnum, Hash)>] DownloadResponse
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 636 def get_documents_document_id_content_with_http_info(document_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_documents_document_id_content ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling get_documents_document_id_content" if document_id.nil? if opts[:'disposition'] && !['attachment', 'inline'].include?(opts[:'disposition']) fail 'invalid value for "disposition", must be one of attachment, inline' end # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}/content".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'disposition'] = opts[:'disposition'] if opts[:'disposition'] query_params[:'contentType'] = opts[:'content_type'] if opts[:'content_type'] # 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 => 'DownloadResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_documents_document_id_content\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a document.
@param document_id Document
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(Document
, Fixnum, Hash)>] Document
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 493 def get_documents_document_id_with_http_info(document_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_documents_document_id ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling get_documents_document_id" if document_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'Document') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_documents_document_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of documents.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :name Name @option opts [Array<String>] :expand Which fields, if any, to expand. @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [String] :sort_by name or dateCreated @option opts [String] :sort_order ascending or descending @return [Array<(DocumentEntityListing
, Fixnum, Hash)>] DocumentEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 424 def get_documents_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_documents ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_documents" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents".sub('{format}','json') # query parameters query_params = {} query_params[:'workspaceId'] = workspace_id query_params[:'name'] = opts[:'name'] if opts[:'name'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] 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 => 'DocumentEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_documents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Query content
@param query_phrase Phrase tokens are ANDed together over all searchable fields @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [String] :sort_by name or dateCreated (default to name) @option opts [String] :sort_order ascending or descending (default to ascending) @option opts [Array<String>] :expand Which fields, if any, to expand. @return [QueryResults]
# File lib/purecloud/api/content_management_api.rb, line 697 def get_query(query_phrase, opts = {}) data, status_code, headers = get_query_with_http_info(query_phrase, opts) return data end
Query content
@param query_phrase Phrase tokens are ANDed together over all searchable fields @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [String] :sort_by name or dateCreated @option opts [String] :sort_order ascending or descending @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(QueryResults
, Fixnum, Hash)>] QueryResults
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 712 def get_query_with_http_info(query_phrase, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_query ..." end # verify the required parameter 'query_phrase' is set fail "Missing the required parameter 'query_phrase' when calling get_query" if query_phrase.nil? # resource path local_var_path = "/api/v2/contentmanagement/query".sub('{format}','json') # query parameters query_params = {} query_params[:'queryPhrase'] = query_phrase query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'sortOrder'] = opts[:'sort_order'] if opts[:'sort_order'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'QueryResults') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_query\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a List of Security Profiles
@param [Hash] opts the optional parameters @return [SecurityProfileEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 767 def get_securityprofiles(opts = {}) data, status_code, headers = get_securityprofiles_with_http_info(opts) return data end
Get a Security Profile
@param security_profile_id Security Profile Id @param [Hash] opts the optional parameters @return [SecurityProfile]
# File lib/purecloud/api/content_management_api.rb, line 823 def get_securityprofiles_securityprofile_id(security_profile_id, opts = {}) data, status_code, headers = get_securityprofiles_securityprofile_id_with_http_info(security_profile_id, opts) return data end
Get a Security Profile
@param security_profile_id Security Profile Id @param [Hash] opts the optional parameters @return [Array<(SecurityProfile
, Fixnum, Hash)>] SecurityProfile
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 833 def get_securityprofiles_securityprofile_id_with_http_info(security_profile_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_securityprofiles_securityprofile_id ..." end # verify the required parameter 'security_profile_id' is set fail "Missing the required parameter 'security_profile_id' when calling get_securityprofiles_securityprofile_id" if security_profile_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/securityprofiles/{securityProfileId}".sub('{format}','json').sub('{' + 'securityProfileId' + '}', security_profile_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 => 'SecurityProfile') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_securityprofiles_securityprofile_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a List of Security Profiles
@param [Hash] opts the optional parameters @return [Array<(SecurityProfileEntityListing
, Fixnum, Hash)>] SecurityProfileEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 776 def get_securityprofiles_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_securityprofiles ..." end # resource path local_var_path = "/api/v2/contentmanagement/securityprofiles".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 = 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 => 'SecurityProfileEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_securityprofiles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of statuses for pending operations
@param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @return [CommandStatusEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 1094 def get_status(opts = {}) data, status_code, headers = get_status_with_http_info(opts) return data end
Get a status.
@param status_id Status ID @param [Hash] opts the optional parameters @return [CommandStatus]
# File lib/purecloud/api/content_management_api.rb, line 1154 def get_status_status_id(status_id, opts = {}) data, status_code, headers = get_status_status_id_with_http_info(status_id, opts) return data end
Get a status.
@param status_id Status ID @param [Hash] opts the optional parameters @return [Array<(CommandStatus
, Fixnum, Hash)>] CommandStatus
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1164 def get_status_status_id_with_http_info(status_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_status_status_id ..." end # verify the required parameter 'status_id' is set fail "Missing the required parameter 'status_id' when calling get_status_status_id" if status_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/status/{statusId}".sub('{format}','json').sub('{' + 'statusId' + '}', status_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 => 'CommandStatus') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_status_status_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of statuses for pending operations
@param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @return [Array<(CommandStatusEntityListing
, Fixnum, Hash)>] CommandStatusEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1105 def get_status_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_status ..." end # resource path local_var_path = "/api/v2/contentmanagement/status".sub('{format}','json') # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] # 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 => 'CommandStatusEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get usage details.
@param [Hash] opts the optional parameters @return [Usage]
# File lib/purecloud/api/content_management_api.rb, line 1213 def get_usage(opts = {}) data, status_code, headers = get_usage_with_http_info(opts) return data end
Get usage details.
@param [Hash] opts the optional parameters @return [Array<(Usage
, Fixnum, Hash)>] Usage
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1222 def get_usage_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_usage ..." end # resource path local_var_path = "/api/v2/contentmanagement/usage".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 = 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 => 'Usage') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_usage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of workspaces. Specifying 'content' access will return all workspaces the user has document access to, while 'admin' access will return all group workspaces the user has administrative rights to. @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [Array<String>] :access Requested access level. @option opts [Array<String>] :expand Which fields, if any, to expand. @return [WorkspaceEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 1272 def get_workspaces(opts = {}) data, status_code, headers = get_workspaces_with_http_info(opts) return data end
Get a list of workspaces. Specifying 'content' access will return all workspaces the user has document access to, while 'admin' access will return all group workspaces the user has administrative rights to. @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [Array<String>] :access Requested access level. @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(WorkspaceEntityListing
, Fixnum, Hash)>] WorkspaceEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1285 def get_workspaces_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces ..." end # resource path local_var_path = "/api/v2/contentmanagement/workspaces".sub('{format}','json') # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'access'] = @api_client.build_collection_param(opts[:'access'], :multi) if opts[:'access'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'WorkspaceEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a workspace.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Workspace]
# File lib/purecloud/api/content_management_api.rb, line 1337 def get_workspaces_workspace_id(workspace_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_with_http_info(workspace_id, opts) return data end
Get a list of documents.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [String] :sort_by name or dateCreated @option opts [String] :sort_order ascending or descending (default to ascending) @return [DocumentEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 1404 def get_workspaces_workspace_id_documents(workspace_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_documents_with_http_info(workspace_id, opts) return data end
Get a list of documents.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [String] :sort_by name or dateCreated @option opts [String] :sort_order ascending or descending @return [Array<(DocumentEntityListing
, Fixnum, Hash)>] DocumentEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1419 def get_workspaces_workspace_id_documents_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id_documents ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id_documents" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/documents".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] 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 => 'DocumentEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id_documents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list workspace members
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [Array<String>] :expand Which fields, if any, to expand. @return [WorkspaceMemberEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 1477 def get_workspaces_workspace_id_members(workspace_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_members_with_http_info(workspace_id, opts) return data end
Get a workspace member
@param workspace_id Workspace
ID @param member_id Member ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [WorkspaceMember]
# File lib/purecloud/api/content_management_api.rb, line 1545 def get_workspaces_workspace_id_members_member_id(workspace_id, member_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, opts) return data end
Get a workspace member
@param workspace_id Workspace
ID @param member_id Member ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(WorkspaceMember
, Fixnum, Hash)>] WorkspaceMember
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1557 def get_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id_members_member_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id_members_member_id" if workspace_id.nil? # verify the required parameter 'member_id' is set fail "Missing the required parameter 'member_id' when calling get_workspaces_workspace_id_members_member_id" if member_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/members/{memberId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'memberId' + '}', member_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'WorkspaceMember') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id_members_member_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list workspace members
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(WorkspaceMemberEntityListing
, Fixnum, Hash)>] WorkspaceMemberEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1490 def get_workspaces_workspace_id_members_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id_members ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id_members" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/members".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'WorkspaceMemberEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id_members\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of workspace tags
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :value filter the list of tags returned @option opts [Integer] :page_size Page
size (default to 25) @option opts [Integer] :page_number Page
number (default to 1) @option opts [Array<String>] :expand Which fields, if any, to expand. @return [TagValueEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 1615 def get_workspaces_workspace_id_tagvalues(workspace_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_tagvalues_with_http_info(workspace_id, opts) return data end
Get a workspace tag
@param workspace_id Workspace
ID @param tag_id Tag ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [TagValue]
# File lib/purecloud/api/content_management_api.rb, line 1685 def get_workspaces_workspace_id_tagvalues_tag_id(workspace_id, tag_id, opts = {}) data, status_code, headers = get_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, opts) return data end
Get a workspace tag
@param workspace_id Workspace
ID @param tag_id Tag ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(TagValue
, Fixnum, Hash)>] TagValue
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1697 def get_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id_tagvalues_tag_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id_tagvalues_tag_id" if workspace_id.nil? # verify the required parameter 'tag_id' is set fail "Missing the required parameter 'tag_id' when calling get_workspaces_workspace_id_tagvalues_tag_id" if tag_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues/{tagId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'tagId' + '}', tag_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'TagValue') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id_tagvalues_tag_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of workspace tags
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [String] :value filter the list of tags returned @option opts [Integer] :page_size Page
size @option opts [Integer] :page_number Page
number @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(TagValueEntityListing
, Fixnum, Hash)>] TagValueEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1629 def get_workspaces_workspace_id_tagvalues_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id_tagvalues ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id_tagvalues" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'value'] = opts[:'value'] if opts[:'value'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'TagValueEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id_tagvalues\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a workspace.
@param workspace_id Workspace
ID @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(Workspace
, Fixnum, Hash)>] Workspace
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1348 def get_workspaces_workspace_id_with_http_info(workspace_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#get_workspaces_workspace_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling get_workspaces_workspace_id" if workspace_id.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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 => 'Workspace') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#get_workspaces_workspace_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Query audits
@param body Allows for a filtered query returning facet information @param [Hash] opts the optional parameters @return [QueryResults]
# File lib/purecloud/api/content_management_api.rb, line 1751 def post_auditquery(body, opts = {}) data, status_code, headers = post_auditquery_with_http_info(body, opts) return data end
Query audits
@param body Allows for a filtered query returning facet information @param [Hash] opts the optional parameters @return [Array<(QueryResults
, Fixnum, Hash)>] QueryResults
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1761 def post_auditquery_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_auditquery ..." end # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_auditquery" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/auditquery".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(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 => 'QueryResults') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_auditquery\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Add a document.
@param body Document
@param [Hash] opts the optional parameters @option opts [String] :copy_source Copy a document within a workspace or to a new workspace. Provide a document ID as the copy source. @option opts [String] :move_source Move a document to a new workspace. Provide a document ID as the move source. @option opts [BOOLEAN] :override Override any lock on the source document @return [Document]
# File lib/purecloud/api/content_management_api.rb, line 1814 def post_documents(body, opts = {}) data, status_code, headers = post_documents_with_http_info(body, opts) return data end
Update a document.
@param document_id Document
ID @param body Document
@param [Hash] opts the optional parameters @option opts [String] :expand Expand some document fields @option opts [BOOLEAN] :override Override any lock on the document @return [Document]
# File lib/purecloud/api/content_management_api.rb, line 1883 def post_documents_document_id(document_id, body, opts = {}) data, status_code, headers = post_documents_document_id_with_http_info(document_id, body, opts) return data end
Replace the contents of a document.
@param document_id Document
ID @param body Replace Request @param [Hash] opts the optional parameters @option opts [BOOLEAN] :override Override any lock on the document @return [ReplaceResponse]
# File lib/purecloud/api/content_management_api.rb, line 1957 def post_documents_document_id_content(document_id, body, opts = {}) data, status_code, headers = post_documents_document_id_content_with_http_info(document_id, body, opts) return data end
Replace the contents of a document.
@param document_id Document
ID @param body Replace Request @param [Hash] opts the optional parameters @option opts [BOOLEAN] :override Override any lock on the document @return [Array<(ReplaceResponse
, Fixnum, Hash)>] ReplaceResponse
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1969 def post_documents_document_id_content_with_http_info(document_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_documents_document_id_content ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling post_documents_document_id_content" if document_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_documents_document_id_content" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}/content".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'override'] = opts[:'override'] if opts[:'override'] # 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(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 => 'ReplaceResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_documents_document_id_content\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update a document.
@param document_id Document
ID @param body Document
@param [Hash] opts the optional parameters @option opts [String] :expand Expand some document fields @option opts [BOOLEAN] :override Override any lock on the document @return [Array<(Document
, Fixnum, Hash)>] Document
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1896 def post_documents_document_id_with_http_info(document_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_documents_document_id ..." end # verify the required parameter 'document_id' is set fail "Missing the required parameter 'document_id' when calling post_documents_document_id" if document_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_documents_document_id" if body.nil? if opts[:'expand'] && !['acl'].include?(opts[:'expand']) fail 'invalid value for "expand", must be one of acl' end # resource path local_var_path = "/api/v2/contentmanagement/documents/{documentId}".sub('{format}','json').sub('{' + 'documentId' + '}', document_id.to_s) # query parameters query_params = {} query_params[:'expand'] = opts[:'expand'] if opts[:'expand'] query_params[:'override'] = opts[:'override'] if opts[:'override'] # 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(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 => 'Document') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_documents_document_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Add a document.
@param body Document
@param [Hash] opts the optional parameters @option opts [String] :copy_source Copy a document within a workspace or to a new workspace. Provide a document ID as the copy source. @option opts [String] :move_source Move a document to a new workspace. Provide a document ID as the move source. @option opts [BOOLEAN] :override Override any lock on the source document @return [Array<(Document
, Fixnum, Hash)>] Document
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 1827 def post_documents_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_documents ..." end # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_documents" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/documents".sub('{format}','json') # query parameters query_params = {} query_params[:'copySource'] = opts[:'copy_source'] if opts[:'copy_source'] query_params[:'moveSource'] = opts[:'move_source'] if opts[:'move_source'] query_params[:'override'] = opts[:'override'] if opts[:'override'] # 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(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 => 'Document') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_documents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Query content
@param body Allows for a filtered query returning facet information @param [Hash] opts the optional parameters @option opts [String] :expand Expand some document fields @return [QueryResults]
# File lib/purecloud/api/content_management_api.rb, line 2024 def post_query(body, opts = {}) data, status_code, headers = post_query_with_http_info(body, opts) return data end
Query content
@param body Allows for a filtered query returning facet information @param [Hash] opts the optional parameters @option opts [String] :expand Expand some document fields @return [Array<(QueryResults
, Fixnum, Hash)>] QueryResults
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2035 def post_query_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_query ..." end # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_query" if body.nil? if opts[:'expand'] && !['acl', 'workspace'].include?(opts[:'expand']) fail 'invalid value for "expand", must be one of acl, workspace' end # resource path local_var_path = "/api/v2/contentmanagement/query".sub('{format}','json') # query parameters query_params = {} query_params[:'expand'] = opts[:'expand'] if opts[:'expand'] # 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(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 => 'QueryResults') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_query\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create a group workspace
@param body Workspace
@param [Hash] opts the optional parameters @return [Workspace]
# File lib/purecloud/api/content_management_api.rb, line 2150 def post_workspaces(body, opts = {}) data, status_code, headers = post_workspaces_with_http_info(body, opts) return data end
Create a group workspace
@param body Workspace
@param [Hash] opts the optional parameters @return [Array<(Workspace
, Fixnum, Hash)>] Workspace
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2160 def post_workspaces_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_workspaces ..." end # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_workspaces" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces".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(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 => 'Workspace') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_workspaces\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create a workspace tag
@param workspace_id Workspace
ID @param body tag @param [Hash] opts the optional parameters @return [TagValue]
# File lib/purecloud/api/content_management_api.rb, line 2211 def post_workspaces_workspace_id_tagvalues(workspace_id, body, opts = {}) data, status_code, headers = post_workspaces_workspace_id_tagvalues_with_http_info(workspace_id, body, opts) return data end
Perform a prefix query on tags in the workspace
@param workspace_id Workspace
ID @param body query @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [TagValueEntityListing]
# File lib/purecloud/api/content_management_api.rb, line 2277 def post_workspaces_workspace_id_tagvalues_query(workspace_id, body, opts = {}) data, status_code, headers = post_workspaces_workspace_id_tagvalues_query_with_http_info(workspace_id, body, opts) return data end
Perform a prefix query on tags in the workspace
@param workspace_id Workspace
ID @param body query @param [Hash] opts the optional parameters @option opts [Array<String>] :expand Which fields, if any, to expand. @return [Array<(TagValueEntityListing
, Fixnum, Hash)>] TagValueEntityListing
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2289 def post_workspaces_workspace_id_tagvalues_query_with_http_info(workspace_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_workspaces_workspace_id_tagvalues_query ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling post_workspaces_workspace_id_tagvalues_query" if workspace_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_workspaces_workspace_id_tagvalues_query" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues/query".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s) # query parameters query_params = {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] # 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(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 => 'TagValueEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_workspaces_workspace_id_tagvalues_query\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Create a workspace tag
@param workspace_id Workspace
ID @param body tag @param [Hash] opts the optional parameters @return [Array<(TagValue
, Fixnum, Hash)>] TagValue
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2222 def post_workspaces_workspace_id_tagvalues_with_http_info(workspace_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#post_workspaces_workspace_id_tagvalues ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling post_workspaces_workspace_id_tagvalues" if workspace_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling post_workspaces_workspace_id_tagvalues" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_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(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 => 'TagValue') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#post_workspaces_workspace_id_tagvalues\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update a workspace
@param workspace_id Workspace
ID @param body Workspace
@param [Hash] opts the optional parameters @return [Workspace]
# File lib/purecloud/api/content_management_api.rb, line 2344 def put_workspaces_workspace_id(workspace_id, body, opts = {}) data, status_code, headers = put_workspaces_workspace_id_with_http_info(workspace_id, body, opts) return data end
Add a member to a workspace
@param workspace_id Workspace
ID @param member_id Member ID @param body Workspace
Member @param [Hash] opts the optional parameters @return [WorkspaceMember]
# File lib/purecloud/api/content_management_api.rb, line 2410 def put_workspaces_workspace_id_members_member_id(workspace_id, member_id, body, opts = {}) data, status_code, headers = put_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, body, opts) return data end
Add a member to a workspace
@param workspace_id Workspace
ID @param member_id Member ID @param body Workspace
Member @param [Hash] opts the optional parameters @return [Array<(WorkspaceMember
, Fixnum, Hash)>] WorkspaceMember
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2422 def put_workspaces_workspace_id_members_member_id_with_http_info(workspace_id, member_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#put_workspaces_workspace_id_members_member_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling put_workspaces_workspace_id_members_member_id" if workspace_id.nil? # verify the required parameter 'member_id' is set fail "Missing the required parameter 'member_id' when calling put_workspaces_workspace_id_members_member_id" if member_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling put_workspaces_workspace_id_members_member_id" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/members/{memberId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'memberId' + '}', member_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(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 => 'WorkspaceMember') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#put_workspaces_workspace_id_members_member_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update a workspace tag. Will update all documents with the new tag value.
@param workspace_id Workspace
ID @param tag_id Tag ID @param body Workspace
@param [Hash] opts the optional parameters @return [TagValue]
# File lib/purecloud/api/content_management_api.rb, line 2480 def put_workspaces_workspace_id_tagvalues_tag_id(workspace_id, tag_id, body, opts = {}) data, status_code, headers = put_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, body, opts) return data end
Update a workspace tag. Will update all documents with the new tag value.
@param workspace_id Workspace
ID @param tag_id Tag ID @param body Workspace
@param [Hash] opts the optional parameters @return [Array<(TagValue
, Fixnum, Hash)>] TagValue
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2492 def put_workspaces_workspace_id_tagvalues_tag_id_with_http_info(workspace_id, tag_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#put_workspaces_workspace_id_tagvalues_tag_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling put_workspaces_workspace_id_tagvalues_tag_id" if workspace_id.nil? # verify the required parameter 'tag_id' is set fail "Missing the required parameter 'tag_id' when calling put_workspaces_workspace_id_tagvalues_tag_id" if tag_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling put_workspaces_workspace_id_tagvalues_tag_id" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}/tagvalues/{tagId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_id.to_s).sub('{' + 'tagId' + '}', tag_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(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 => 'TagValue') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#put_workspaces_workspace_id_tagvalues_tag_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Update a workspace
@param workspace_id Workspace
ID @param body Workspace
@param [Hash] opts the optional parameters @return [Array<(Workspace
, Fixnum, Hash)>] Workspace
data, response status code and response headers
# File lib/purecloud/api/content_management_api.rb, line 2355 def put_workspaces_workspace_id_with_http_info(workspace_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: ContentManagementApi#put_workspaces_workspace_id ..." end # verify the required parameter 'workspace_id' is set fail "Missing the required parameter 'workspace_id' when calling put_workspaces_workspace_id" if workspace_id.nil? # verify the required parameter 'body' is set fail "Missing the required parameter 'body' when calling put_workspaces_workspace_id" if body.nil? # resource path local_var_path = "/api/v2/contentmanagement/workspaces/{workspaceId}".sub('{format}','json').sub('{' + 'workspaceId' + '}', workspace_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(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 => 'Workspace') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContentManagementApi#put_workspaces_workspace_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end