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
-
#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.
-
#comment_case(case_id, body, opts = {}) ⇒ Object
Comment case.
-
#comment_case_with_http_info(case_id, body, opts = {}) ⇒ Array<(TimelineResponse, Integer, Hash)>
Comment case.
-
#create_case(body, opts = {}) ⇒ Object
Create a case.
-
#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_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_with_http_info(body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Create a case.
-
#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_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_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.
-
#get_case(case_id, opts = {}) ⇒ Object
Get the details of a case.
-
#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.
-
#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.
-
#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.
-
#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.
-
#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_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_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_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.
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
#archive_case(case_id, body, opts = {}) ⇒ Object
Archive case.
29 30 31 32 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 29 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
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 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.
101 102 103 104 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 101 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
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 164 165 166 167 168 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 114 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 |
#comment_case(case_id, body, opts = {}) ⇒ Object
Comment case.
173 174 175 176 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 173 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
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 236 237 238 239 240 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 186 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 |
#create_case(body, opts = {}) ⇒ Object
Create a case.
245 246 247 248 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 245 def create_case(body, opts = {}) data, _status_code, _headers = create_case_with_http_info(body, opts) data end |
#create_case_jira_issue(case_id, body, opts = {}) ⇒ Object
Create Jira issue for case.
312 313 314 315 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 312 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
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 375 376 377 378 379 380 381 382 383 384 385 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 325 def create_case_jira_issue_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.create_case_jira_issue".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_case_jira_issue") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_case_jira_issue")) end 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_notebook(case_id, body, opts = {}) ⇒ Object
Create investigation notebook for case.
390 391 392 393 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 390 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
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 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 403 def create_case_notebook_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.create_case_notebook".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_case_notebook") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_case_notebook")) end 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.
468 469 470 471 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 468 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
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 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 481 def create_case_service_now_ticket_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.create_case_service_now_ticket".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_case_service_now_ticket") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_case_service_now_ticket")) end 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_with_http_info(body, opts = {}) ⇒ Array<(CaseResponse, Integer, Hash)>
Create a case.
Create a Case
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 257 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_project(body, opts = {}) ⇒ Object
Create a project.
546 547 548 549 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 546 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.
613 614 615 616 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 613 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.
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 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 626 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.
558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 558 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_comment(case_id, cell_id, opts = {}) ⇒ Object
Delete case comment.
685 686 687 688 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 685 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
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 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 698 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.
755 756 757 758 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 755 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
768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 768 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_project(project_id, opts = {}) ⇒ Object
Remove a project.
825 826 827 828 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 825 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.
890 891 892 893 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 890 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.
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 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 903 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.
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 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 837 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 |
#get_case(case_id, opts = {}) ⇒ Object
Get the details of a case.
960 961 962 963 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 960 def get_case(case_id, opts = {}) data, _status_code, _headers = get_case_with_http_info(case_id, opts) data 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
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 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 972 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.
1025 1026 1027 1028 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1025 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.
1090 1091 1092 1093 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1090 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.
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 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1102 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.
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 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1037 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.
1155 1156 1157 1158 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1155 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.
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 1208 1209 1210 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1166 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.
1215 1216 1217 1218 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1215 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
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 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1228 def link_incident_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.link_incident".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.link_incident") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.link_incident")) end 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.
1293 1294 1295 1296 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1293 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
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 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1306 def link_jira_issue_to_case_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.link_jira_issue_to_case".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.link_jira_issue_to_case") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.link_jira_issue_to_case")) end 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 |
#move_case_to_project(case_id, body, opts = {}) ⇒ Object
Update case project.
1371 1372 1373 1374 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1371 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
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 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1384 def move_case_to_project_with_http_info(case_id, body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.move_case_to_project".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.move_case_to_project") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.move_case_to_project")) end 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 |
#search_cases(opts = {}) ⇒ Object
Search cases.
1449 1450 1451 1452 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1449 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.
1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1465 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 }
1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1527 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, 0) 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", 0) + 1) end end |
#unarchive_case(case_id, body, opts = {}) ⇒ Object
Unarchive case.
1545 1546 1547 1548 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1545 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
1558 1559 1560 1561 1562 1563 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 1558 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.
1617 1618 1619 1620 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1617 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
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 1678 1679 1680 1681 1682 1683 1684 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1630 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 |
#unlink_jira_issue(case_id, opts = {}) ⇒ Object
Remove Jira issue link from case.
1689 1690 1691 1692 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1689 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
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 1748 1749 1750 1751 1752 1753 1754 1755 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1701 def unlink_jira_issue_with_http_info(case_id, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.unlink_jira_issue".to_sym] if unstable_enabled @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.unlink_jira_issue") else raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.unlink_jira_issue")) end 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 |
#update_attributes(case_id, body, opts = {}) ⇒ Object
Update case attributes.
1760 1761 1762 1763 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1760 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
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 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1773 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_custom_attribute(case_id, custom_attribute_key, body, opts = {}) ⇒ Object
Update case custom attribute.
1832 1833 1834 1835 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1832 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
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 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1846 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.
1909 1910 1911 1912 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1909 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
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 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1922 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_title(case_id, body, opts = {}) ⇒ Object
Update case title.
1981 1982 1983 1984 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1981 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
1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 1994 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_priority(case_id, body, opts = {}) ⇒ Object
Update case priority.
2053 2054 2055 2056 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2053 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
2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2066 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.
2125 2126 2127 2128 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2125 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.
2197 2198 2199 2200 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2197 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.
2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 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 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2211 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.
2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2138 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.
2274 2275 2276 2277 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2274 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
2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 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 |
# File 'lib/datadog_api_client/v2/api/case_management_api.rb', line 2287 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 |