Module: JPSClient::API::ToolCategory
- Defined in:
- lib/jpsclient/api/archived_outdated/tool_category.rb
Overview
ToolCategory 相关 API 自动生成的模块,处理 tool_category 相关接口
Instance Method Summary collapse
-
#create_tool_category(params: {}) ⇒ Hash
Create Tool Category.
-
#create_weights(params: {}) ⇒ Hash
Create Weights.
-
#delete_tool_category(categoryId:, params: {}) ⇒ Hash
Delete Tool Category.
-
#get_tool_categories(params: {}) ⇒ Hash
Get Tool Categories.
-
#update_tool_category(categoryId:, params: {}) ⇒ Hash
Update Tool Category.
Instance Method Details
#create_tool_category(params: {}) ⇒ Hash
Create Tool Category
39 40 41 42 43 44 45 46 |
# File 'lib/jpsclient/api/archived_outdated/tool_category.rb', line 39 def create_tool_category(params: {}) config = @request_config && @request_config["tool_category_tool_category"] raise JPSClient::ExceptionError, "Missing config for tool_category_tool_category" unless config && config["url"] path = config["url"] return request_with_auth(:post, path, body: params) end |
#create_weights(params: {}) ⇒ Hash
Create Weights
52 53 54 55 56 57 58 59 |
# File 'lib/jpsclient/api/archived_outdated/tool_category.rb', line 52 def create_weights(params: {}) config = @request_config && @request_config["tool_category_weights"] raise JPSClient::ExceptionError, "Missing config for tool_category_weights" unless config && config["url"] path = config["url"] return request_with_auth(:post, path, body: params) end |
#delete_tool_category(categoryId:, params: {}) ⇒ Hash
Delete Tool Category
25 26 27 28 29 30 31 32 33 |
# File 'lib/jpsclient/api/archived_outdated/tool_category.rb', line 25 def delete_tool_category(categoryId:, params: {}) config = @request_config && @request_config["tool_category_tool_category"] raise JPSClient::ExceptionError, "Missing config for tool_category_tool_category" unless config && config["url"] path = config["url"] path = path.gsub("{categoryId}", categoryId.to_s) return request_with_auth(:delete, path) end |
#get_tool_categories(params: {}) ⇒ Hash
Get Tool Categories
65 66 67 68 69 70 71 72 |
# File 'lib/jpsclient/api/archived_outdated/tool_category.rb', line 65 def get_tool_categories(params: {}) config = @request_config && @request_config["tool_category_tool_categories"] raise JPSClient::ExceptionError, "Missing config for tool_category_tool_categories" unless config && config["url"] path = config["url"] return request_with_auth(:get, path, params: params) end |
#update_tool_category(categoryId:, params: {}) ⇒ Hash
Update Tool Category
11 12 13 14 15 16 17 18 19 |
# File 'lib/jpsclient/api/archived_outdated/tool_category.rb', line 11 def update_tool_category(categoryId:, params: {}) config = @request_config && @request_config["tool_category_tool_category"] raise JPSClient::ExceptionError, "Missing config for tool_category_tool_category" unless config && config["url"] path = config["url"] path = path.gsub("{categoryId}", categoryId.to_s) return request_with_auth(:put, path, body: params) end |