Class: DatadogAPIClient::V2::CaseManagementAPI
- Inherits:
-
Object
- Object
- DatadogAPIClient::V2::CaseManagementAPI
- Defined in:
- lib/datadog_api_client/v2/api/case_management_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#add_case_insights(case_id, body, opts = {}) ⇒ Object
Add insights to a case.
-
#add_case_insights_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Add insights to a case.
-
#aggregate_cases(body, opts = {}) ⇒ Object
Aggregate cases.
-
#aggregate_cases_with_http_info(body, opts = {}) ⇒ Array<(CaseAggregateResponse, Integer, Hash)>
Aggregate cases.
-
#archive_case(case_id, body, opts = {}) ⇒ Object
Archive case.
-
#archive_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Archive case.
-
#assign_case(case_id, body, opts = {}) ⇒ Object
Assign case.
-
#assign_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Assign case.
-
#bulk_update_cases(body, opts = {}) ⇒ Object
Bulk update cases.
-
#bulk_update_cases_with_http_info(body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Bulk update cases.
-
#comment_case(case_id, body, opts = {}) ⇒ Object
Comment case.
-
#comment_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(TimelineResponse, Integer, Hash)>
Comment case.
-
#count_cases(opts = {}) ⇒ Object
Count cases.
-
#count_cases_with_http_info(opts = {}) ⇒ Array<(CaseCountResponse, Integer, Hash)>
Count cases.
-
#create_case(body, opts = {}) ⇒ Object
Create a case.
-
#create_case_automation_rule(project_id, body, opts = {}) ⇒ Object
Create an automation rule.
-
#create_case_automation_rule_with_http_info(project_id, body, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Create an automation rule.
-
#create_case_jira_issue(case_id, body, opts = {}) ⇒ Object
Create Jira issue for case.
-
#create_case_jira_issue_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create Jira issue for case.
-
#create_case_link(body, opts = {}) ⇒ Object
Create a case link.
-
#create_case_link_with_http_info(body, opts = {}) ⇒ Array<(CaseLinkResponse, Integer, Hash)>
Create a case link.
-
#create_case_notebook(case_id, body, opts = {}) ⇒ Object
Create investigation notebook for case.
-
#create_case_notebook_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create investigation notebook for case.
-
#create_case_service_now_ticket(case_id, body, opts = {}) ⇒ Object
Create ServiceNow ticket for case.
-
#create_case_service_now_ticket_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create ServiceNow ticket for case.
-
#create_case_view(body, opts = {}) ⇒ Object
Create a case view.
-
#create_case_view_with_http_info(body, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Create a case view.
-
#create_case_with_http_info(body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Create a case.
-
#create_maintenance_window(body, opts = {}) ⇒ Object
Create a maintenance window.
-
#create_maintenance_window_with_http_info(body, opts = {}) ⇒ Array<(MaintenanceWindowResponse, Integer, Hash)>
Create a maintenance window.
-
#create_project(body, opts = {}) ⇒ Object
Create a project.
-
#create_project_notification_rule(project_id, body, opts = {}) ⇒ Object
Create a notification rule.
-
#create_project_notification_rule_with_http_info(project_id, body, opts = {}) ⇒ Array<(CaseNotificationRuleResponse, Integer, Hash)>
Create a notification rule.
-
#create_project_with_http_info(body, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Create a project.
-
#delete_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Delete an automation rule.
-
#delete_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete an automation rule.
-
#delete_case_comment(case_id, cell_id, opts = {}) ⇒ Object
Delete case comment.
-
#delete_case_comment_with_http_info(case_id, cell_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete case comment.
-
#delete_case_custom_attribute(case_id, custom_attribute_key, opts = {}) ⇒ Object
Delete custom attribute from case.
-
#delete_case_custom_attribute_with_http_info(case_id, custom_attribute_key, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Delete custom attribute from case.
-
#delete_case_link(link_id, opts = {}) ⇒ Object
Delete a case link.
-
#delete_case_link_with_http_info(link_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a case link.
-
#delete_case_view(view_id, opts = {}) ⇒ Object
Delete a case view.
-
#delete_case_view_with_http_info(view_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a case view.
-
#delete_maintenance_window(maintenance_window_id, opts = {}) ⇒ Object
Delete a maintenance window.
-
#delete_maintenance_window_with_http_info(maintenance_window_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a maintenance window.
-
#delete_project(project_id, opts = {}) ⇒ Object
Remove a project.
-
#delete_project_notification_rule(project_id, notification_rule_id, opts = {}) ⇒ Object
Delete a notification rule.
-
#delete_project_notification_rule_with_http_info(project_id, notification_rule_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a notification rule.
-
#delete_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Remove a project.
-
#disable_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Disable an automation rule.
-
#disable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Disable an automation rule.
-
#enable_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Enable an automation rule.
-
#enable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Enable an automation rule.
-
#favorite_case_project(project_id, opts = {}) ⇒ Object
Favorite a project.
-
#favorite_case_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Favorite a project.
-
#get_case(case_id, opts = {}) ⇒ Object
Get the details of a case.
-
#get_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Get an automation rule.
-
#get_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Get an automation rule.
-
#get_case_view(view_id, opts = {}) ⇒ Object
Get a case view.
-
#get_case_view_with_http_info(view_id, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Get a case view.
-
#get_case_with_http_info(case_id, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Get the details of a case.
-
#get_project(project_id, opts = {}) ⇒ Object
Get the details of a project.
-
#get_project_notification_rules(project_id, opts = {}) ⇒ Object
Get notification rules.
-
#get_project_notification_rules_with_http_info(project_id, opts = {}) ⇒ Array<(CaseNotificationRulesResponse, Integer, Hash)>
Get notification rules.
-
#get_project_with_http_info(project_id, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Get the details of a project.
-
#get_projects(opts = {}) ⇒ Object
Get all projects.
-
#get_projects_with_http_info(opts = {}) ⇒ Array<(ProjectsResponse, Integer, Hash)>
Get all projects.
-
#initialize(api_client = DatadogAPIClient::APIClient.default) ⇒ CaseManagementAPI
constructor
A new instance of CaseManagementAPI.
-
#link_incident(case_id, body, opts = {}) ⇒ Object
Link incident to case.
-
#link_incident_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Link incident to case.
-
#link_jira_issue_to_case(case_id, body, opts = {}) ⇒ Object
Link existing Jira issue to case.
-
#link_jira_issue_to_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Link existing Jira issue to case.
-
#list_case_automation_rules(project_id, opts = {}) ⇒ Object
List automation rules.
-
#list_case_automation_rules_with_http_info(project_id, opts = {}) ⇒ Array<(AutomationRulesResponse, Integer, Hash)>
List automation rules.
-
#list_case_links(entity_type, entity_id, opts = {}) ⇒ Object
List case links.
-
#list_case_links_with_http_info(entity_type, entity_id, opts = {}) ⇒ Array<(CaseLinksResponse, Integer, Hash)>
List case links.
-
#list_case_timeline(case_id, opts = {}) ⇒ Object
Get case timeline.
-
#list_case_timeline_with_http_info(case_id, opts = {}) ⇒ Array<(TimelineResponse, Integer, Hash)>
Get case timeline.
-
#list_case_views(project_id, opts = {}) ⇒ Object
List case views.
-
#list_case_views_with_http_info(project_id, opts = {}) ⇒ Array<(CaseViewsResponse, Integer, Hash)>
List case views.
-
#list_case_watchers(case_id, opts = {}) ⇒ Object
List case watchers.
-
#list_case_watchers_with_http_info(case_id, opts = {}) ⇒ Array<(CaseWatchersResponse, Integer, Hash)>
List case watchers.
-
#list_maintenance_windows(opts = {}) ⇒ Object
List maintenance windows.
-
#list_maintenance_windows_with_http_info(opts = {}) ⇒ Array<(MaintenanceWindowsResponse, Integer, Hash)>
List maintenance windows.
-
#list_user_case_project_favorites(opts = {}) ⇒ Object
List project favorites.
-
#list_user_case_project_favorites_with_http_info(opts = {}) ⇒ Array<(ProjectFavoritesResponse, Integer, Hash)>
List project favorites.
-
#move_case_to_project(case_id, body, opts = {}) ⇒ Object
Update case project.
-
#move_case_to_project_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case project.
-
#remove_case_insights(case_id, body, opts = {}) ⇒ Object
Remove insights from a case.
-
#remove_case_insights_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Remove insights from a case.
-
#search_cases(opts = {}) ⇒ Object
Search cases.
-
#search_cases_with_http_info(opts = {}) ⇒ Array<(CasesResponse, Integer, Hash)>
Search cases.
-
#search_cases_with_pagination(opts = {}) {|Case| ... } ⇒ Object
Search cases.
-
#unarchive_case(case_id, body, opts = {}) ⇒ Object
Unarchive case.
-
#unarchive_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Unarchive case.
-
#unassign_case(case_id, body, opts = {}) ⇒ Object
Unassign case.
-
#unassign_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Unassign case.
-
#unfavorite_case_project(project_id, opts = {}) ⇒ Object
Unfavorite a project.
-
#unfavorite_case_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Unfavorite a project.
-
#unlink_jira_issue(case_id, opts = {}) ⇒ Object
Remove Jira issue link from case.
-
#unlink_jira_issue_with_http_info(case_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Remove Jira issue link from case.
-
#unwatch_case(case_id, user_uuid, opts = {}) ⇒ Object
Unwatch a case.
-
#unwatch_case_with_http_info(case_id, user_uuid, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Unwatch a case.
-
#update_attributes(case_id, body, opts = {}) ⇒ Object
Update case attributes.
-
#update_attributes_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case attributes.
-
#update_case_automation_rule(project_id, rule_id, body, opts = {}) ⇒ Object
Update an automation rule.
-
#update_case_automation_rule_with_http_info(project_id, rule_id, body, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Update an automation rule.
-
#update_case_comment(case_id, cell_id, body, opts = {}) ⇒ Object
Update case comment.
-
#update_case_comment_with_http_info(case_id, cell_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update case comment.
-
#update_case_custom_attribute(case_id, custom_attribute_key, body, opts = {}) ⇒ Object
Update case custom attribute.
-
#update_case_custom_attribute_with_http_info(case_id, custom_attribute_key, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case custom attribute.
-
#update_case_description(case_id, body, opts = {}) ⇒ Object
Update case description.
-
#update_case_description_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case description.
-
#update_case_due_date(case_id, body, opts = {}) ⇒ Object
Update case due date.
-
#update_case_due_date_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case due date.
-
#update_case_resolved_reason(case_id, body, opts = {}) ⇒ Object
Update case resolved reason.
-
#update_case_resolved_reason_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case resolved reason.
-
#update_case_title(case_id, body, opts = {}) ⇒ Object
Update case title.
-
#update_case_title_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case title.
-
#update_case_view(view_id, body, opts = {}) ⇒ Object
Update a case view.
-
#update_case_view_with_http_info(view_id, body, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Update a case view.
-
#update_maintenance_window(maintenance_window_id, body, opts = {}) ⇒ Object
Update a maintenance window.
-
#update_maintenance_window_with_http_info(maintenance_window_id, body, opts = {}) ⇒ Array<(MaintenanceWindowResponse, Integer, Hash)>
Update a maintenance window.
-
#update_priority(case_id, body, opts = {}) ⇒ Object
Update case priority.
-
#update_priority_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case priority.
-
#update_project(project_id, body, opts = {}) ⇒ Object
Update a project.
-
#update_project_notification_rule(project_id, notification_rule_id, body, opts = {}) ⇒ Object
Update a notification rule.
-
#update_project_notification_rule_with_http_info(project_id, notification_rule_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update a notification rule.
-
#update_project_with_http_info(project_id, body, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Update a project.
-
#update_status(case_id, body, opts = {}) ⇒ Object
Update case status.
-
#update_status_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case status.
-
#watch_case(case_id, user_uuid, opts = {}) ⇒ Object
Watch a case.
-
#watch_case_with_http_info(case_id, user_uuid, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Watch a case.
Constructor Details
#initialize(api_client = DatadogAPIClient::APIClient.default) ⇒ CaseManagementAPI
Returns a new instance of CaseManagementAPI.
22 23 24 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 22 def initialize(api_client = DatadogAPIClient::APIClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
20 21 22 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 20 def api_client @api_client end |
Instance Method Details
#add_case_insights(case_id, body, opts = {}) ⇒ Object
Add insights to a case.
29 30 31 32 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 29 def add_case_insights(case_id, body, opts = {}) data, _status_code, _headers = add_case_insights_with_http_info(case_id, body, opts) data end |
#add_case_insights_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Add insights to a case.
Adds one or more insights to a case. Insights are references to related Datadog resources (such as monitors, security signals, incidents, or error tracking issues) that provide investigative context. Up to 100 insights can be added per request. Each insight requires a type (see CaseInsightType for allowed values), a ref (URL path to the resource), and a resource_id.
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 42 def add_case_insights_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.add_case_insights ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.add_case_insights" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.add_case_insights" end # resource path local_var_path = '/api/v2/cases/{case_id}/insights'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :add_case_insights, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#add_case_insights\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#aggregate_cases(body, opts = {}) ⇒ Object
Aggregate cases.
101 102 103 104 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 101 def aggregate_cases(body, opts = {}) data, _status_code, _headers = aggregate_cases_with_http_info(body, opts) data end |
#aggregate_cases_with_http_info(body, opts = {}) ⇒ Array<(CaseAggregateResponse, Integer, Hash)>
Aggregate cases.
Performs an aggregation query over cases, grouping results by specified fields and returning counts per group along with a total. Useful for dashboards and analytics.
113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 113 def aggregate_cases_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.aggregate_cases ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.aggregate_cases" end # resource path local_var_path = '/api/v2/cases/aggregate' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseAggregateResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :aggregate_cases, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#aggregate_cases\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#archive_case(case_id, body, opts = {}) ⇒ Object
Archive case.
168 169 170 171 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 168 def archive_case(case_id, body, opts = {}) data, _status_code, _headers = archive_case_with_http_info(case_id, body, opts) data end |
#archive_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Archive case.
Archive case
181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 181 def archive_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.archive_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.archive_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.archive_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/archive'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :archive_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#archive_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#assign_case(case_id, body, opts = {}) ⇒ Object
Assign case.
240 241 242 243 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 240 def assign_case(case_id, body, opts = {}) data, _status_code, _headers = assign_case_with_http_info(case_id, body, opts) data end |
#assign_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Assign case.
Assign case to a user
253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 253 def assign_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.assign_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.assign_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.assign_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/assign'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :assign_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#assign_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#bulk_update_cases(body, opts = {}) ⇒ Object
Bulk update cases.
312 313 314 315 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 312 def bulk_update_cases(body, opts = {}) bulk_update_cases_with_http_info(body, opts) nil end |
#bulk_update_cases_with_http_info(body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Bulk update cases.
Applies a single action (such as changing priority, status, assignment, or archiving) to multiple cases at once. The list of case IDs and the action type with its payload are specified in the request body.
324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 324 def bulk_update_cases_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.bulk_update_cases ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.bulk_update_cases" end # resource path local_var_path = '/api/v2/cases/bulk' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :bulk_update_cases, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#bulk_update_cases\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#comment_case(case_id, body, opts = {}) ⇒ Object
Comment case.
379 380 381 382 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 379 def comment_case(case_id, body, opts = {}) data, _status_code, _headers = comment_case_with_http_info(case_id, body, opts) data end |
#comment_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(TimelineResponse, Integer, Hash)>
Comment case.
Comment case
392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 392 def comment_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.comment_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.comment_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.comment_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/comment'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'TimelineResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth] = opts.merge( :operation => :comment_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#comment_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#count_cases(opts = {}) ⇒ Object
Count cases.
451 452 453 454 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 451 def count_cases(opts = {}) data, _status_code, _headers = count_cases_with_http_info(opts) data end |
#count_cases_with_http_info(opts = {}) ⇒ Array<(CaseCountResponse, Integer, Hash)>
Count cases.
Returns case counts, optionally grouped by one or more fields (for example, status, priority). Supports a query filter to narrow the scope.
465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 465 def count_cases_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.count_cases ...' end # resource path local_var_path = '/api/v2/cases/count' # query parameters query_params = opts[:query_params] || {} query_params[:'query_filter'] = opts[:'query_filter'] if !opts[:'query_filter'].nil? query_params[:'group_bys'] = opts[:'group_bys'] if !opts[:'group_bys'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseCountResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :count_cases, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#count_cases\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case(body, opts = {}) ⇒ Object
Create a case.
517 518 519 520 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 517 def create_case(body, opts = {}) data, _status_code, _headers = create_case_with_http_info(body, opts) data end |
#create_case_automation_rule(project_id, body, opts = {}) ⇒ Object
Create an automation rule.
584 585 586 587 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 584 def create_case_automation_rule(project_id, body, opts = {}) data, _status_code, _headers = create_case_automation_rule_with_http_info(project_id, body, opts) data end |
#create_case_automation_rule_with_http_info(project_id, body, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Create an automation rule.
Creates an automation rule for a project. The rule defines a trigger event (for example, case created, status transitioned) and an action to execute.
597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 597 def create_case_automation_rule_with_http_info(project_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.create_case_automation_rule" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'AutomationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_jira_issue(case_id, body, opts = {}) ⇒ Object
Create Jira issue for case.
656 657 658 659 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 656 def create_case_jira_issue(case_id, body, opts = {}) create_case_jira_issue_with_http_info(case_id, body, opts) nil end |
#create_case_jira_issue_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create Jira issue for case.
Create a new Jira issue and link it to a case
669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 669 def create_case_jira_issue_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_jira_issue ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.create_case_jira_issue" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_jira_issue" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/jira_issues'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_jira_issue, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_jira_issue\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_link(body, opts = {}) ⇒ Object
Create a case link.
728 729 730 731 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 728 def create_case_link(body, opts = {}) data, _status_code, _headers = create_case_link_with_http_info(body, opts) data end |
#create_case_link_with_http_info(body, opts = {}) ⇒ Array<(CaseLinkResponse, Integer, Hash)>
Create a case link.
Creates a directional link between two cases (for example, case A blocks case B). The parent and child cases and their relationship type must be specified.
740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 740 def create_case_link_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_link ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_link" end # resource path local_var_path = '/api/v2/cases/link' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseLinkResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_link, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_notebook(case_id, body, opts = {}) ⇒ Object
Create investigation notebook for case.
795 796 797 798 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 795 def create_case_notebook(case_id, body, opts = {}) create_case_notebook_with_http_info(case_id, body, opts) nil end |
#create_case_notebook_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create investigation notebook for case.
Create a new investigation notebook and link it to a case
808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 808 def create_case_notebook_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_notebook ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.create_case_notebook" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_notebook" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/notebook'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_notebook, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_notebook\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_service_now_ticket(case_id, body, opts = {}) ⇒ Object
Create ServiceNow ticket for case.
867 868 869 870 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 867 def create_case_service_now_ticket(case_id, body, opts = {}) create_case_service_now_ticket_with_http_info(case_id, body, opts) nil end |
#create_case_service_now_ticket_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Create ServiceNow ticket for case.
Create a new ServiceNow incident ticket and link it to a case
880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 880 def create_case_service_now_ticket_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_service_now_ticket ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.create_case_service_now_ticket" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_service_now_ticket" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/servicenow_tickets'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_service_now_ticket, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_service_now_ticket\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_view(body, opts = {}) ⇒ Object
Create a case view.
939 940 941 942 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 939 def create_case_view(body, opts = {}) data, _status_code, _headers = create_case_view_with_http_info(body, opts) data end |
#create_case_view_with_http_info(body, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Create a case view.
Creates a new saved case view with a name, filter query, and associated project. Optionally, a notification rule can be linked to the view.
951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 951 def create_case_view_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case_view ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case_view" end # resource path local_var_path = '/api/v2/cases/views' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseViewResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case_view, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case_view\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_case_with_http_info(body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Create a case.
Create a Case
529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 529 def create_case_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_case ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_case" end # resource path local_var_path = '/api/v2/cases' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_maintenance_window(body, opts = {}) ⇒ Object
Create a maintenance window.
1006 1007 1008 1009 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1006 def create_maintenance_window(body, opts = {}) data, _status_code, _headers = create_maintenance_window_with_http_info(body, opts) data end |
#create_maintenance_window_with_http_info(body, opts = {}) ⇒ Array<(MaintenanceWindowResponse, Integer, Hash)>
Create a maintenance window.
Creates a maintenance window for event management cases with a name, case filter query, and time range (start and end).
1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1018 def create_maintenance_window_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_maintenance_window ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_maintenance_window" end # resource path local_var_path = '/api/v2/maintenance_windows' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'MaintenanceWindowResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_maintenance_window, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_maintenance_window\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_project(body, opts = {}) ⇒ Object
Create a project.
1073 1074 1075 1076 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1073 def create_project(body, opts = {}) data, _status_code, _headers = create_project_with_http_info(body, opts) data end |
#create_project_notification_rule(project_id, body, opts = {}) ⇒ Object
Create a notification rule.
1140 1141 1142 1143 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1140 def create_project_notification_rule(project_id, body, opts = {}) data, _status_code, _headers = create_project_notification_rule_with_http_info(project_id, body, opts) data end |
#create_project_notification_rule_with_http_info(project_id, body, opts = {}) ⇒ Array<(CaseNotificationRuleResponse, Integer, Hash)>
Create a notification rule.
Create a notification rule for a project.
1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1153 def create_project_notification_rule_with_http_info(project_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_project_notification_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.create_project_notification_rule" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_project_notification_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/notification_rules'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseNotificationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_project_notification_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_project_notification_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_project_with_http_info(body, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Create a project.
Create a project.
1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1085 def create_project_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.create_project ...' end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.create_project" end # resource path local_var_path = '/api/v2/cases/projects' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'ProjectResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :create_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#create_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Delete an automation rule.
1212 1213 1214 1215 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1212 def delete_case_automation_rule(project_id, rule_id, opts = {}) delete_case_automation_rule_with_http_info(project_id, rule_id, opts) nil end |
#delete_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete an automation rule.
Permanently deletes an automation rule from a project.
1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1225 def delete_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.delete_case_automation_rule" end # verify the required parameter 'rule_id' is set if @api_client.config.client_side_validation && rule_id.nil? fail ArgumentError, "Missing the required parameter 'rule_id' when calling CaseManagementAPI.delete_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules/{rule_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{rule_id}', CGI.escape(rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_case_comment(case_id, cell_id, opts = {}) ⇒ Object
Delete case comment.
1282 1283 1284 1285 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1282 def delete_case_comment(case_id, cell_id, opts = {}) delete_case_comment_with_http_info(case_id, cell_id, opts) nil end |
#delete_case_comment_with_http_info(case_id, cell_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete case comment.
Delete case comment
1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1295 def delete_case_comment_with_http_info(case_id, cell_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_case_comment ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.delete_case_comment" end # verify the required parameter 'cell_id' is set if @api_client.config.client_side_validation && cell_id.nil? fail ArgumentError, "Missing the required parameter 'cell_id' when calling CaseManagementAPI.delete_case_comment" end # resource path local_var_path = '/api/v2/cases/{case_id}/comment/{cell_id}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{cell_id}', CGI.escape(cell_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth] = opts.merge( :operation => :delete_case_comment, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_case_comment\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_case_custom_attribute(case_id, custom_attribute_key, opts = {}) ⇒ Object
Delete custom attribute from case.
1352 1353 1354 1355 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1352 def delete_case_custom_attribute(case_id, custom_attribute_key, opts = {}) data, _status_code, _headers = delete_case_custom_attribute_with_http_info(case_id, custom_attribute_key, opts) data end |
#delete_case_custom_attribute_with_http_info(case_id, custom_attribute_key, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Delete custom attribute from case.
Delete custom attribute from case
1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1365 def delete_case_custom_attribute_with_http_info(case_id, custom_attribute_key, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_case_custom_attribute ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.delete_case_custom_attribute" end # verify the required parameter 'custom_attribute_key' is set if @api_client.config.client_side_validation && custom_attribute_key.nil? fail ArgumentError, "Missing the required parameter 'custom_attribute_key' when calling CaseManagementAPI.delete_case_custom_attribute" end # resource path local_var_path = '/api/v2/cases/{case_id}/custom_attributes/{custom_attribute_key}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{custom_attribute_key}', CGI.escape(custom_attribute_key.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_case_custom_attribute, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_case_custom_attribute\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_case_link(link_id, opts = {}) ⇒ Object
Delete a case link.
1422 1423 1424 1425 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1422 def delete_case_link(link_id, opts = {}) delete_case_link_with_http_info(link_id, opts) nil end |
#delete_case_link_with_http_info(link_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a case link.
Deletes an existing link between cases by link ID.
1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1434 def delete_case_link_with_http_info(link_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_case_link ...' end # verify the required parameter 'link_id' is set if @api_client.config.client_side_validation && link_id.nil? fail ArgumentError, "Missing the required parameter 'link_id' when calling CaseManagementAPI.delete_case_link" end # resource path local_var_path = '/api/v2/cases/link/{link_id}'.sub('{link_id}', CGI.escape(link_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_case_link, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_case_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_case_view(view_id, opts = {}) ⇒ Object
Delete a case view.
1487 1488 1489 1490 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1487 def delete_case_view(view_id, opts = {}) delete_case_view_with_http_info(view_id, opts) nil end |
#delete_case_view_with_http_info(view_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a case view.
Permanently deletes a saved case view.
1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1499 def delete_case_view_with_http_info(view_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_case_view ...' end # verify the required parameter 'view_id' is set if @api_client.config.client_side_validation && view_id.nil? fail ArgumentError, "Missing the required parameter 'view_id' when calling CaseManagementAPI.delete_case_view" end # resource path local_var_path = '/api/v2/cases/views/{view_id}'.sub('{view_id}', CGI.escape(view_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_case_view, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_case_view\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_maintenance_window(maintenance_window_id, opts = {}) ⇒ Object
Delete a maintenance window.
1552 1553 1554 1555 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1552 def delete_maintenance_window(maintenance_window_id, opts = {}) delete_maintenance_window_with_http_info(maintenance_window_id, opts) nil end |
#delete_maintenance_window_with_http_info(maintenance_window_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a maintenance window.
Permanently deletes a maintenance window.
1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1564 def delete_maintenance_window_with_http_info(maintenance_window_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_maintenance_window ...' end # verify the required parameter 'maintenance_window_id' is set if @api_client.config.client_side_validation && maintenance_window_id.nil? fail ArgumentError, "Missing the required parameter 'maintenance_window_id' when calling CaseManagementAPI.delete_maintenance_window" end # resource path local_var_path = '/api/v2/maintenance_windows/{maintenance_window_id}'.sub('{maintenance_window_id}', CGI.escape(maintenance_window_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_maintenance_window, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_maintenance_window\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_project(project_id, opts = {}) ⇒ Object
Remove a project.
1617 1618 1619 1620 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1617 def delete_project(project_id, opts = {}) delete_project_with_http_info(project_id, opts) nil end |
#delete_project_notification_rule(project_id, notification_rule_id, opts = {}) ⇒ Object
Delete a notification rule.
1682 1683 1684 1685 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1682 def delete_project_notification_rule(project_id, notification_rule_id, opts = {}) delete_project_notification_rule_with_http_info(project_id, notification_rule_id, opts) nil end |
#delete_project_notification_rule_with_http_info(project_id, notification_rule_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a notification rule.
Delete a notification rule using the notification rule's id.
1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1695 def delete_project_notification_rule_with_http_info(project_id, notification_rule_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_project_notification_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.delete_project_notification_rule" end # verify the required parameter 'notification_rule_id' is set if @api_client.config.client_side_validation && notification_rule_id.nil? fail ArgumentError, "Missing the required parameter 'notification_rule_id' when calling CaseManagementAPI.delete_project_notification_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/notification_rules/{notification_rule_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{notification_rule_id}', CGI.escape(notification_rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_project_notification_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_project_notification_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Remove a project.
Remove a project using the project's id.
1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1629 def delete_project_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.delete_project ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.delete_project" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :delete_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#delete_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#disable_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Disable an automation rule.
1752 1753 1754 1755 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1752 def disable_case_automation_rule(project_id, rule_id, opts = {}) data, _status_code, _headers = disable_case_automation_rule_with_http_info(project_id, rule_id, opts) data end |
#disable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Disable an automation rule.
Disables an automation rule so it no longer triggers on case events. The rule configuration is preserved.
1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1765 def disable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.disable_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.disable_case_automation_rule" end # verify the required parameter 'rule_id' is set if @api_client.config.client_side_validation && rule_id.nil? fail ArgumentError, "Missing the required parameter 'rule_id' when calling CaseManagementAPI.disable_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules/{rule_id}/disable'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{rule_id}', CGI.escape(rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'AutomationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :disable_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#disable_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#enable_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Enable an automation rule.
1822 1823 1824 1825 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1822 def enable_case_automation_rule(project_id, rule_id, opts = {}) data, _status_code, _headers = enable_case_automation_rule_with_http_info(project_id, rule_id, opts) data end |
#enable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Enable an automation rule.
Enables a previously disabled automation rule so it triggers on matching case events.
1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1835 def enable_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.enable_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.enable_case_automation_rule" end # verify the required parameter 'rule_id' is set if @api_client.config.client_side_validation && rule_id.nil? fail ArgumentError, "Missing the required parameter 'rule_id' when calling CaseManagementAPI.enable_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules/{rule_id}/enable'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{rule_id}', CGI.escape(rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'AutomationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :enable_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#enable_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#favorite_case_project(project_id, opts = {}) ⇒ Object
Favorite a project.
1892 1893 1894 1895 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1892 def favorite_case_project(project_id, opts = {}) favorite_case_project_with_http_info(project_id, opts) nil end |
#favorite_case_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Favorite a project.
Marks a case project as a favorite for the current authenticated user.
1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1904 def favorite_case_project_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.favorite_case_project ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.favorite_case_project" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/favorites'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :favorite_case_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#favorite_case_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_case(case_id, opts = {}) ⇒ Object
Get the details of a case.
1957 1958 1959 1960 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1957 def get_case(case_id, opts = {}) data, _status_code, _headers = get_case_with_http_info(case_id, opts) data end |
#get_case_automation_rule(project_id, rule_id, opts = {}) ⇒ Object
Get an automation rule.
2022 2023 2024 2025 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2022 def get_case_automation_rule(project_id, rule_id, opts = {}) data, _status_code, _headers = get_case_automation_rule_with_http_info(project_id, rule_id, opts) data end |
#get_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Get an automation rule.
Returns a single automation rule identified by its UUID, including its trigger, action, and current state (enabled/disabled).
2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2035 def get_case_automation_rule_with_http_info(project_id, rule_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.get_case_automation_rule" end # verify the required parameter 'rule_id' is set if @api_client.config.client_side_validation && rule_id.nil? fail ArgumentError, "Missing the required parameter 'rule_id' when calling CaseManagementAPI.get_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules/{rule_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{rule_id}', CGI.escape(rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'AutomationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_case_view(view_id, opts = {}) ⇒ Object
Get a case view.
2092 2093 2094 2095 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2092 def get_case_view(view_id, opts = {}) data, _status_code, _headers = get_case_view_with_http_info(view_id, opts) data end |
#get_case_view_with_http_info(view_id, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Get a case view.
Returns a single saved case view identified by its UUID, including its query, associated project, and timestamps.
2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2104 def get_case_view_with_http_info(view_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_case_view ...' end # verify the required parameter 'view_id' is set if @api_client.config.client_side_validation && view_id.nil? fail ArgumentError, "Missing the required parameter 'view_id' when calling CaseManagementAPI.get_case_view" end # resource path local_var_path = '/api/v2/cases/views/{view_id}'.sub('{view_id}', CGI.escape(view_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseViewResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_case_view, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_case_view\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_case_with_http_info(case_id, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Get the details of a case.
Get the details of case by case_id
1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1969 def get_case_with_http_info(case_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.get_case" end # resource path local_var_path = '/api/v2/cases/{case_id}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_project(project_id, opts = {}) ⇒ Object
Get the details of a project.
2157 2158 2159 2160 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2157 def get_project(project_id, opts = {}) data, _status_code, _headers = get_project_with_http_info(project_id, opts) data end |
#get_project_notification_rules(project_id, opts = {}) ⇒ Object
Get notification rules.
2222 2223 2224 2225 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2222 def get_project_notification_rules(project_id, opts = {}) data, _status_code, _headers = get_project_notification_rules_with_http_info(project_id, opts) data end |
#get_project_notification_rules_with_http_info(project_id, opts = {}) ⇒ Array<(CaseNotificationRulesResponse, Integer, Hash)>
Get notification rules.
Get all notification rules for a project.
2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2234 def get_project_notification_rules_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_project_notification_rules ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.get_project_notification_rules" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/notification_rules'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseNotificationRulesResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_project_notification_rules, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_project_notification_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_project_with_http_info(project_id, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Get the details of a project.
Get the details of a project by project_id.
2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2169 def get_project_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_project ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.get_project" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ProjectResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_projects(opts = {}) ⇒ Object
Get all projects.
2287 2288 2289 2290 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2287 def get_projects(opts = {}) data, _status_code, _headers = get_projects_with_http_info(opts) data end |
#get_projects_with_http_info(opts = {}) ⇒ Array<(ProjectsResponse, Integer, Hash)>
Get all projects.
Get all projects.
2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2298 def get_projects_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.get_projects ...' end # resource path local_var_path = '/api/v2/cases/projects' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ProjectsResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :get_projects, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#get_projects\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#link_incident(case_id, body, opts = {}) ⇒ Object
Link incident to case.
2347 2348 2349 2350 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2347 def link_incident(case_id, body, opts = {}) data, _status_code, _headers = link_incident_with_http_info(case_id, body, opts) data end |
#link_incident_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Link incident to case.
Link an incident to a case
2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2360 def link_incident_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.link_incident ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.link_incident" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.link_incident" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/incidents'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :link_incident, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#link_incident\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#link_jira_issue_to_case(case_id, body, opts = {}) ⇒ Object
Link existing Jira issue to case.
2419 2420 2421 2422 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2419 def link_jira_issue_to_case(case_id, body, opts = {}) link_jira_issue_to_case_with_http_info(case_id, body, opts) nil end |
#link_jira_issue_to_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Link existing Jira issue to case.
Link an existing Jira issue to a case
2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2432 def link_jira_issue_to_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.link_jira_issue_to_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.link_jira_issue_to_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.link_jira_issue_to_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/jira_issues'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :link_jira_issue_to_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Patch, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#link_jira_issue_to_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_case_automation_rules(project_id, opts = {}) ⇒ Object
List automation rules.
2491 2492 2493 2494 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2491 def list_case_automation_rules(project_id, opts = {}) data, _status_code, _headers = list_case_automation_rules_with_http_info(project_id, opts) data end |
#list_case_automation_rules_with_http_info(project_id, opts = {}) ⇒ Array<(AutomationRulesResponse, Integer, Hash)>
List automation rules.
Returns all automation rules configured for a project. Automation rules allow automatic actions to be triggered by case events like creation, status transitions, or attribute changes.
2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2503 def list_case_automation_rules_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_case_automation_rules ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.list_case_automation_rules" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'AutomationRulesResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_case_automation_rules, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_case_automation_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_case_links(entity_type, entity_id, opts = {}) ⇒ Object
List case links.
2556 2557 2558 2559 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2556 def list_case_links(entity_type, entity_id, opts = {}) data, _status_code, _headers = list_case_links_with_http_info(entity_type, entity_id, opts) data end |
#list_case_links_with_http_info(entity_type, entity_id, opts = {}) ⇒ Array<(CaseLinksResponse, Integer, Hash)>
List case links.
Returns all links associated with a case. Links define relationships (for example, BLOCKS) between cases. Requires entity_type and entity_id query parameters.
2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2570 def list_case_links_with_http_info(entity_type, entity_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_case_links ...' end # verify the required parameter 'entity_type' is set if @api_client.config.client_side_validation && entity_type.nil? fail ArgumentError, "Missing the required parameter 'entity_type' when calling CaseManagementAPI.list_case_links" end # verify the required parameter 'entity_id' is set if @api_client.config.client_side_validation && entity_id.nil? fail ArgumentError, "Missing the required parameter 'entity_id' when calling CaseManagementAPI.list_case_links" end # resource path local_var_path = '/api/v2/cases/link' # query parameters query_params = opts[:query_params] || {} query_params[:'entity_type'] = entity_type query_params[:'entity_id'] = entity_id query_params[:'relationship'] = opts[:'relationship'] if !opts[:'relationship'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseLinksResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_case_links, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_case_links\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_case_timeline(case_id, opts = {}) ⇒ Object
Get case timeline.
2630 2631 2632 2633 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2630 def list_case_timeline(case_id, opts = {}) data, _status_code, _headers = list_case_timeline_with_http_info(case_id, opts) data end |
#list_case_timeline_with_http_info(case_id, opts = {}) ⇒ Array<(TimelineResponse, Integer, Hash)>
Get case timeline.
Returns the timeline of events for a case, including comments, status changes, and other activity. Supports pagination and sort order.
2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2645 def list_case_timeline_with_http_info(case_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_case_timeline ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.list_case_timeline" end # resource path local_var_path = '/api/v2/cases/{case_id}/timelines'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil? query_params[:'sort[ascending]'] = opts[:'sort_ascending'] if !opts[:'sort_ascending'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'TimelineResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_case_timeline, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_case_timeline\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_case_views(project_id, opts = {}) ⇒ Object
List case views.
2701 2702 2703 2704 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2701 def list_case_views(project_id, opts = {}) data, _status_code, _headers = list_case_views_with_http_info(project_id, opts) data end |
#list_case_views_with_http_info(project_id, opts = {}) ⇒ Array<(CaseViewsResponse, Integer, Hash)>
List case views.
Returns all saved case views for a given project. Views are saved search queries that allow quick access to filtered lists of cases.
2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2713 def list_case_views_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_case_views ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.list_case_views" end # resource path local_var_path = '/api/v2/cases/views' # query parameters query_params = opts[:query_params] || {} query_params[:'project_id'] = project_id # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseViewsResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_case_views, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_case_views\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_case_watchers(case_id, opts = {}) ⇒ Object
List case watchers.
2767 2768 2769 2770 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2767 def list_case_watchers(case_id, opts = {}) data, _status_code, _headers = list_case_watchers_with_http_info(case_id, opts) data end |
#list_case_watchers_with_http_info(case_id, opts = {}) ⇒ Array<(CaseWatchersResponse, Integer, Hash)>
List case watchers.
Returns the list of users who are watching a case. Watchers receive notifications about updates to the case.
2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2779 def list_case_watchers_with_http_info(case_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_case_watchers ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.list_case_watchers" end # resource path local_var_path = '/api/v2/cases/{case_id}/watchers'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CaseWatchersResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_case_watchers, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_case_watchers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_maintenance_windows(opts = {}) ⇒ Object
List maintenance windows.
2832 2833 2834 2835 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2832 def list_maintenance_windows(opts = {}) data, _status_code, _headers = list_maintenance_windows_with_http_info(opts) data end |
#list_maintenance_windows_with_http_info(opts = {}) ⇒ Array<(MaintenanceWindowsResponse, Integer, Hash)>
List maintenance windows.
Returns all configured maintenance windows for event management cases. Maintenance windows define time periods during which case notifications and automation rules are suppressed for cases matching a given query.
2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2843 def list_maintenance_windows_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_maintenance_windows ...' end # resource path local_var_path = '/api/v2/maintenance_windows' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'MaintenanceWindowsResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_maintenance_windows, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_maintenance_windows\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_user_case_project_favorites(opts = {}) ⇒ Object
List project favorites.
2892 2893 2894 2895 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2892 def list_user_case_project_favorites(opts = {}) data, _status_code, _headers = list_user_case_project_favorites_with_http_info(opts) data end |
#list_user_case_project_favorites_with_http_info(opts = {}) ⇒ Array<(ProjectFavoritesResponse, Integer, Hash)>
List project favorites.
Returns the list of case projects that the current authenticated user has marked as favorites.
2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2903 def list_user_case_project_favorites_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.list_user_case_project_favorites ...' end # resource path local_var_path = '/api/v2/cases/projects/favorites' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ProjectFavoritesResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :list_user_case_project_favorites, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#list_user_case_project_favorites\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#move_case_to_project(case_id, body, opts = {}) ⇒ Object
Update case project.
2952 2953 2954 2955 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2952 def move_case_to_project(case_id, body, opts = {}) data, _status_code, _headers = move_case_to_project_with_http_info(case_id, body, opts) data end |
#move_case_to_project_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case project.
Update the project associated with a case
2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2965 def move_case_to_project_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.move_case_to_project ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.move_case_to_project" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.move_case_to_project" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/project'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :move_case_to_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Patch, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#move_case_to_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#remove_case_insights(case_id, body, opts = {}) ⇒ Object
Remove insights from a case.
3024 3025 3026 3027 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3024 def remove_case_insights(case_id, body, opts = {}) data, _status_code, _headers = remove_case_insights_with_http_info(case_id, body, opts) data end |
#remove_case_insights_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Remove insights from a case.
Removes one or more previously added insights from a case by specifying their type and resource identifier in the request body.
3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3037 def remove_case_insights_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.remove_case_insights ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.remove_case_insights" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.remove_case_insights" end # resource path local_var_path = '/api/v2/cases/{case_id}/insights'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :remove_case_insights, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#remove_case_insights\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_cases(opts = {}) ⇒ Object
Search cases.
3096 3097 3098 3099 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3096 def search_cases(opts = {}) data, _status_code, _headers = search_cases_with_http_info(opts) data end |
#search_cases_with_http_info(opts = {}) ⇒ Array<(CasesResponse, Integer, Hash)>
Search cases.
Search cases.
3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3112 def search_cases_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.search_cases ...' end allowable_values = ['created_at', 'priority', 'status'] if @api_client.config.client_side_validation && opts[:'sort_field'] && !allowable_values.include?(opts[:'sort_field']) fail ArgumentError, "invalid value for \"sort_field\", must be one of #{allowable_values}" end # resource path local_var_path = '/api/v2/cases' # query parameters query_params = opts[:query_params] || {} query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil? query_params[:'sort[field]'] = opts[:'sort_field'] if !opts[:'sort_field'].nil? query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil? query_params[:'sort[asc]'] = opts[:'sort_asc'] if !opts[:'sort_asc'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'CasesResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :search_cases, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#search_cases\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_cases_with_pagination(opts = {}) {|Case| ... } ⇒ Object
Search cases.
Provide a paginated version of #search_cases, returning all items.
To use it you need to use a block: search_cases_with_pagination { |item| p item }
3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3174 def search_cases_with_pagination(opts = {}) api_version = "V2" page_size = @api_client.get_attribute_from_path(opts, "page_size", 10) @api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size) @api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, 1) while true do response = search_cases(opts) @api_client.get_attribute_from_path(response, "data").each { |item| yield(item) } if @api_client.get_attribute_from_path(response, "data").length < page_size break end @api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, @api_client.get_attribute_from_path(opts, "page_number", 1) + 1) end end |
#unarchive_case(case_id, body, opts = {}) ⇒ Object
Unarchive case.
3192 3193 3194 3195 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3192 def unarchive_case(case_id, body, opts = {}) data, _status_code, _headers = unarchive_case_with_http_info(case_id, body, opts) data end |
#unarchive_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Unarchive case.
Unarchive case
3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3205 def unarchive_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.unarchive_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.unarchive_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.unarchive_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/unarchive'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :unarchive_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#unarchive_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unassign_case(case_id, body, opts = {}) ⇒ Object
Unassign case.
3264 3265 3266 3267 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3264 def unassign_case(case_id, body, opts = {}) data, _status_code, _headers = unassign_case_with_http_info(case_id, body, opts) data end |
#unassign_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Unassign case.
Unassign case
3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3277 def unassign_case_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.unassign_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.unassign_case" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.unassign_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/unassign'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :unassign_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#unassign_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unfavorite_case_project(project_id, opts = {}) ⇒ Object
Unfavorite a project.
3336 3337 3338 3339 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3336 def unfavorite_case_project(project_id, opts = {}) unfavorite_case_project_with_http_info(project_id, opts) nil end |
#unfavorite_case_project_with_http_info(project_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Unfavorite a project.
Removes a case project from the current user's favorites list.
3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3348 def unfavorite_case_project_with_http_info(project_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.unfavorite_case_project ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.unfavorite_case_project" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/favorites'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :unfavorite_case_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#unfavorite_case_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unlink_jira_issue(case_id, opts = {}) ⇒ Object
Remove Jira issue link from case.
3401 3402 3403 3404 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3401 def unlink_jira_issue(case_id, opts = {}) unlink_jira_issue_with_http_info(case_id, opts) nil end |
#unlink_jira_issue_with_http_info(case_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Remove Jira issue link from case.
Remove the link between a Jira issue and a case
3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3413 def unlink_jira_issue_with_http_info(case_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.unlink_jira_issue ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.unlink_jira_issue" end # resource path local_var_path = '/api/v2/cases/{case_id}/relationships/jira_issues'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :unlink_jira_issue, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#unlink_jira_issue\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unwatch_case(case_id, user_uuid, opts = {}) ⇒ Object
Unwatch a case.
3466 3467 3468 3469 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3466 def unwatch_case(case_id, user_uuid, opts = {}) unwatch_case_with_http_info(case_id, user_uuid, opts) nil end |
#unwatch_case_with_http_info(case_id, user_uuid, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Unwatch a case.
Removes a user from the watchers list of a case. The user no longer receives notifications about updates to the case.
3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3479 def unwatch_case_with_http_info(case_id, user_uuid, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.unwatch_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.unwatch_case" end # verify the required parameter 'user_uuid' is set if @api_client.config.client_side_validation && user_uuid.nil? fail ArgumentError, "Missing the required parameter 'user_uuid' when calling CaseManagementAPI.unwatch_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/watchers/{user_uuid}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{user_uuid}', CGI.escape(user_uuid.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :unwatch_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#unwatch_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_attributes(case_id, body, opts = {}) ⇒ Object
Update case attributes.
3536 3537 3538 3539 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3536 def update_attributes(case_id, body, opts = {}) data, _status_code, _headers = update_attributes_with_http_info(case_id, body, opts) data end |
#update_attributes_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case attributes.
Update case attributes
3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3549 def update_attributes_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_attributes ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_attributes" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_attributes" end # resource path local_var_path = '/api/v2/cases/{case_id}/attributes'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_attributes, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_attributes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_automation_rule(project_id, rule_id, body, opts = {}) ⇒ Object
Update an automation rule.
3608 3609 3610 3611 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3608 def update_case_automation_rule(project_id, rule_id, body, opts = {}) data, _status_code, _headers = update_case_automation_rule_with_http_info(project_id, rule_id, body, opts) data end |
#update_case_automation_rule_with_http_info(project_id, rule_id, body, opts = {}) ⇒ Array<(AutomationRuleResponse, Integer, Hash)>
Update an automation rule.
Updates the trigger, action, name, or state of an existing automation rule.
3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3622 def update_case_automation_rule_with_http_info(project_id, rule_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_automation_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.update_case_automation_rule" end # verify the required parameter 'rule_id' is set if @api_client.config.client_side_validation && rule_id.nil? fail ArgumentError, "Missing the required parameter 'rule_id' when calling CaseManagementAPI.update_case_automation_rule" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_automation_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/rules/{rule_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{rule_id}', CGI.escape(rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'AutomationRuleResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_automation_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_automation_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_comment(case_id, cell_id, body, opts = {}) ⇒ Object
Update case comment.
3685 3686 3687 3688 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3685 def update_case_comment(case_id, cell_id, body, opts = {}) update_case_comment_with_http_info(case_id, cell_id, body, opts) nil end |
#update_case_comment_with_http_info(case_id, cell_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update case comment.
Updates the text content of an existing comment on a case timeline. The comment is identified by its cell ID.
3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3699 def update_case_comment_with_http_info(case_id, cell_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_comment ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_comment" end # verify the required parameter 'cell_id' is set if @api_client.config.client_side_validation && cell_id.nil? fail ArgumentError, "Missing the required parameter 'cell_id' when calling CaseManagementAPI.update_case_comment" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_comment" end # resource path local_var_path = '/api/v2/cases/{case_id}/comment/{cell_id}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{cell_id}', CGI.escape(cell_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_comment, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_comment\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_custom_attribute(case_id, custom_attribute_key, body, opts = {}) ⇒ Object
Update case custom attribute.
3762 3763 3764 3765 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3762 def update_case_custom_attribute(case_id, custom_attribute_key, body, opts = {}) data, _status_code, _headers = update_case_custom_attribute_with_http_info(case_id, custom_attribute_key, body, opts) data end |
#update_case_custom_attribute_with_http_info(case_id, custom_attribute_key, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case custom attribute.
Update case custom attribute
3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3776 def update_case_custom_attribute_with_http_info(case_id, custom_attribute_key, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_custom_attribute ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_custom_attribute" end # verify the required parameter 'custom_attribute_key' is set if @api_client.config.client_side_validation && custom_attribute_key.nil? fail ArgumentError, "Missing the required parameter 'custom_attribute_key' when calling CaseManagementAPI.update_case_custom_attribute" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_custom_attribute" end # resource path local_var_path = '/api/v2/cases/{case_id}/custom_attributes/{custom_attribute_key}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{custom_attribute_key}', CGI.escape(custom_attribute_key.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_custom_attribute, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_custom_attribute\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_description(case_id, body, opts = {}) ⇒ Object
Update case description.
3839 3840 3841 3842 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3839 def update_case_description(case_id, body, opts = {}) data, _status_code, _headers = update_case_description_with_http_info(case_id, body, opts) data end |
#update_case_description_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case description.
Update case description
3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3852 def update_case_description_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_description ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_description" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_description" end # resource path local_var_path = '/api/v2/cases/{case_id}/description'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_description, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_description\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_due_date(case_id, body, opts = {}) ⇒ Object
Update case due date.
3911 3912 3913 3914 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3911 def update_case_due_date(case_id, body, opts = {}) data, _status_code, _headers = update_case_due_date_with_http_info(case_id, body, opts) data end |
#update_case_due_date_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case due date.
Sets or updates the due date for a case. The due date is a calendar date (without a time component) indicating when the case should be resolved.
3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3924 def update_case_due_date_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_due_date ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_due_date" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_due_date" end # resource path local_var_path = '/api/v2/cases/{case_id}/due_date'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_due_date, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_due_date\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_resolved_reason(case_id, body, opts = {}) ⇒ Object
Update case resolved reason.
3983 3984 3985 3986 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3983 def update_case_resolved_reason(case_id, body, opts = {}) data, _status_code, _headers = update_case_resolved_reason_with_http_info(case_id, body, opts) data end |
#update_case_resolved_reason_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case resolved reason.
Sets the resolved reason for a security case (for example, FALSE_POSITIVE, TRUE_POSITIVE). Applicable to security-type cases.
3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 3996 def update_case_resolved_reason_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_resolved_reason ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_resolved_reason" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_resolved_reason" end # resource path local_var_path = '/api/v2/cases/{case_id}/resolved_reason'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_resolved_reason, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_resolved_reason\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_title(case_id, body, opts = {}) ⇒ Object
Update case title.
4055 4056 4057 4058 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4055 def update_case_title(case_id, body, opts = {}) data, _status_code, _headers = update_case_title_with_http_info(case_id, body, opts) data end |
#update_case_title_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case title.
Update case title
4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4068 def update_case_title_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_title ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_case_title" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_title" end # resource path local_var_path = '/api/v2/cases/{case_id}/title'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_title, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_title\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_case_view(view_id, body, opts = {}) ⇒ Object
Update a case view.
4127 4128 4129 4130 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4127 def update_case_view(view_id, body, opts = {}) data, _status_code, _headers = update_case_view_with_http_info(view_id, body, opts) data end |
#update_case_view_with_http_info(view_id, body, opts = {}) ⇒ Array<(CaseViewResponse, Integer, Hash)>
Update a case view.
Updates the name, query, or notification rule of an existing case view.
4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4140 def update_case_view_with_http_info(view_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_case_view ...' end # verify the required parameter 'view_id' is set if @api_client.config.client_side_validation && view_id.nil? fail ArgumentError, "Missing the required parameter 'view_id' when calling CaseManagementAPI.update_case_view" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_case_view" end # resource path local_var_path = '/api/v2/cases/views/{view_id}'.sub('{view_id}', CGI.escape(view_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseViewResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_case_view, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_case_view\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_maintenance_window(maintenance_window_id, body, opts = {}) ⇒ Object
Update a maintenance window.
4199 4200 4201 4202 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4199 def update_maintenance_window(maintenance_window_id, body, opts = {}) data, _status_code, _headers = update_maintenance_window_with_http_info(maintenance_window_id, body, opts) data end |
#update_maintenance_window_with_http_info(maintenance_window_id, body, opts = {}) ⇒ Array<(MaintenanceWindowResponse, Integer, Hash)>
Update a maintenance window.
Updates the name, query, start time, or end time of an existing maintenance window.
4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4212 def update_maintenance_window_with_http_info(maintenance_window_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_maintenance_window ...' end # verify the required parameter 'maintenance_window_id' is set if @api_client.config.client_side_validation && maintenance_window_id.nil? fail ArgumentError, "Missing the required parameter 'maintenance_window_id' when calling CaseManagementAPI.update_maintenance_window" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_maintenance_window" end # resource path local_var_path = '/api/v2/maintenance_windows/{maintenance_window_id}'.sub('{maintenance_window_id}', CGI.escape(maintenance_window_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'MaintenanceWindowResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_maintenance_window, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_maintenance_window\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_priority(case_id, body, opts = {}) ⇒ Object
Update case priority.
4271 4272 4273 4274 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4271 def update_priority(case_id, body, opts = {}) data, _status_code, _headers = update_priority_with_http_info(case_id, body, opts) data end |
#update_priority_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case priority.
Update case priority
4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4284 def update_priority_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_priority ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_priority" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_priority" end # resource path local_var_path = '/api/v2/cases/{case_id}/priority'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_priority, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_priority\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_project(project_id, body, opts = {}) ⇒ Object
Update a project.
4343 4344 4345 4346 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4343 def update_project(project_id, body, opts = {}) data, _status_code, _headers = update_project_with_http_info(project_id, body, opts) data end |
#update_project_notification_rule(project_id, notification_rule_id, body, opts = {}) ⇒ Object
Update a notification rule.
4415 4416 4417 4418 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4415 def update_project_notification_rule(project_id, notification_rule_id, body, opts = {}) update_project_notification_rule_with_http_info(project_id, notification_rule_id, body, opts) nil end |
#update_project_notification_rule_with_http_info(project_id, notification_rule_id, body, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update a notification rule.
Update a notification rule.
4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4429 def update_project_notification_rule_with_http_info(project_id, notification_rule_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_project_notification_rule ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.update_project_notification_rule" end # verify the required parameter 'notification_rule_id' is set if @api_client.config.client_side_validation && notification_rule_id.nil? fail ArgumentError, "Missing the required parameter 'notification_rule_id' when calling CaseManagementAPI.update_project_notification_rule" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_project_notification_rule" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}/notification_rules/{notification_rule_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')).sub('{notification_rule_id}', CGI.escape(notification_rule_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_project_notification_rule, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Put, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_project_notification_rule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_project_with_http_info(project_id, body, opts = {}) ⇒ Array<(ProjectResponse, Integer, Hash)>
Update a project.
Update a project.
4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4356 def update_project_with_http_info(project_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_project ...' end # verify the required parameter 'project_id' is set if @api_client.config.client_side_validation && project_id.nil? fail ArgumentError, "Missing the required parameter 'project_id' when calling CaseManagementAPI.update_project" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_project" end # resource path local_var_path = '/api/v2/cases/projects/{project_id}'.sub('{project_id}', CGI.escape(project_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'ProjectResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_project, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Patch, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_project\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_status(case_id, body, opts = {}) ⇒ Object
Update case status.
4492 4493 4494 4495 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4492 def update_status(case_id, body, opts = {}) data, _status_code, _headers = update_status_with_http_info(case_id, body, opts) data end |
#update_status_with_http_info(case_id, body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Update case status.
Update case status
4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4505 def update_status_with_http_info(case_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.update_status ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.update_status" end # verify the required parameter 'body' is set if @api_client.config.client_side_validation && body.nil? fail ArgumentError, "Missing the required parameter 'body' when calling CaseManagementAPI.update_status" end # resource path local_var_path = '/api/v2/cases/{case_id}/status'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type return_type = opts[:debug_return_type] || 'CaseResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :update_status, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#update_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#watch_case(case_id, user_uuid, opts = {}) ⇒ Object
Watch a case.
4564 4565 4566 4567 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4564 def watch_case(case_id, user_uuid, opts = {}) watch_case_with_http_info(case_id, user_uuid, opts) nil end |
#watch_case_with_http_info(case_id, user_uuid, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Watch a case.
Adds a user (identified by their UUID) as a watcher of a case. The user receives notifications about subsequent updates to the case.
4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 4577 def watch_case_with_http_info(case_id, user_uuid, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: CaseManagementAPI.watch_case ...' end # verify the required parameter 'case_id' is set if @api_client.config.client_side_validation && case_id.nil? fail ArgumentError, "Missing the required parameter 'case_id' when calling CaseManagementAPI.watch_case" end # verify the required parameter 'user_uuid' is set if @api_client.config.client_side_validation && user_uuid.nil? fail ArgumentError, "Missing the required parameter 'user_uuid' when calling CaseManagementAPI.watch_case" end # resource path local_var_path = '/api/v2/cases/{case_id}/watchers/{user_uuid}'.sub('{case_id}', CGI.escape(case_id.to_s).gsub('%2F', '/')).sub('{user_uuid}', CGI.escape(user_uuid.to_s).gsub('%2F', '/')) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] = opts.merge( :operation => :watch_case, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type, :api_version => "V2" ) data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: CaseManagementAPI#watch_case\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |