emass_client 1.0.1 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (149) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +152 -1124
  3. data/Rakefile +2 -0
  4. data/lib/emass_client/api/artifacts_api.rb +124 -97
  5. data/lib/emass_client/api/artifacts_export_api.rb +28 -19
  6. data/lib/emass_client/api/cac_api.rb +50 -31
  7. data/lib/emass_client/api/cloud_resources_api.rb +96 -0
  8. data/lib/emass_client/api/cmmc_assessments_api.rb +20 -11
  9. data/lib/emass_client/api/containers_api.rb +96 -0
  10. data/lib/emass_client/api/controls_api.rb +53 -34
  11. data/lib/emass_client/api/milestones_api.rb +138 -92
  12. data/lib/emass_client/api/pac_api.rb +50 -31
  13. data/lib/emass_client/api/poam_api.rb +132 -86
  14. data/lib/emass_client/api/registration_api.rb +30 -18
  15. data/lib/emass_client/api/static_code_scans_api.rb +38 -26
  16. data/lib/emass_client/api/system_roles_api.rb +48 -29
  17. data/lib/emass_client/api/systems_api.rb +57 -39
  18. data/lib/emass_client/api/test_api.rb +20 -11
  19. data/lib/emass_client/api/test_results_api.rb +53 -34
  20. data/lib/emass_client/api/workflow_definitions_api.rb +23 -14
  21. data/lib/emass_client/api/workflow_instances_api.rb +58 -53
  22. data/lib/emass_client/api_client.rb +59 -57
  23. data/lib/emass_client/api_error.rb +5 -5
  24. data/lib/emass_client/configuration.rb +93 -16
  25. data/lib/emass_client/models/artifacts_get.rb +54 -31
  26. data/lib/emass_client/models/{artifacts_delete_inner.rb → artifacts_request_delete_body_inner.rb} +29 -16
  27. data/lib/emass_client/models/artifacts_response_del.rb +27 -14
  28. data/lib/emass_client/models/{artifacts_response_del_data.rb → artifacts_response_del_data_inner.rb} +31 -18
  29. data/lib/emass_client/models/artifacts_response_get.rb +27 -14
  30. data/lib/emass_client/models/artifacts_response_put_post.rb +27 -14
  31. data/lib/emass_client/models/artifacts_response_put_post_data_inner.rb +265 -0
  32. data/lib/emass_client/models/cac_get.rb +82 -50
  33. data/lib/emass_client/models/cac_response_get.rb +27 -14
  34. data/lib/emass_client/models/cac_response_post.rb +27 -14
  35. data/lib/emass_client/models/{cac_response_post_data.rb → cac_response_post_data_inner.rb} +61 -21
  36. data/lib/emass_client/models/{pac_request_post_body.rb → cloud_resources_post.rb} +73 -69
  37. data/lib/emass_client/models/cloud_resources_response_post.rb +230 -0
  38. data/lib/emass_client/models/cmmc_get.rb +53 -63
  39. data/lib/emass_client/models/cmmc_response_get.rb +27 -14
  40. data/lib/emass_client/models/connectivity_ccsd.rb +29 -14
  41. data/lib/emass_client/models/containers_resources_post.rb +265 -0
  42. data/lib/emass_client/models/containers_response_post.rb +230 -0
  43. data/lib/emass_client/models/controls_get.rb +103 -66
  44. data/lib/emass_client/models/controls_put.rb +58 -18
  45. data/lib/emass_client/models/controls_response_get.rb +28 -14
  46. data/lib/emass_client/models/controls_response_put.rb +27 -14
  47. data/lib/emass_client/models/definition_transitions.rb +32 -62
  48. data/lib/emass_client/models/instances_transitions.rb +37 -88
  49. data/lib/emass_client/models/milestone_response_get.rb +27 -14
  50. data/lib/emass_client/models/milestone_response_get_milestone.rb +228 -0
  51. data/lib/emass_client/models/milestone_response_post.rb +27 -14
  52. data/lib/emass_client/models/milestone_response_put.rb +27 -14
  53. data/lib/emass_client/models/milestones_get.rb +33 -20
  54. data/lib/emass_client/models/milestones_put_post_delete.rb +60 -20
  55. data/lib/emass_client/models/{delete_milestone.rb → milestones_request_delete_body_inner.rb} +29 -21
  56. data/lib/emass_client/models/milestones_required_post.rb +27 -14
  57. data/lib/emass_client/models/milestones_required_put.rb +28 -15
  58. data/lib/emass_client/models/pac_get.rb +39 -22
  59. data/lib/emass_client/models/pac_post.rb +60 -20
  60. data/lib/emass_client/models/pac_response_get.rb +28 -14
  61. data/lib/emass_client/models/pac_response_post.rb +27 -14
  62. data/lib/emass_client/models/poam_get.rb +114 -77
  63. data/lib/emass_client/models/poam_post_put_del.rb +59 -19
  64. data/lib/emass_client/models/{delete_poam.rb → poam_request_delete_body_inner.rb} +29 -21
  65. data/lib/emass_client/models/poam_response_delete.rb +27 -14
  66. data/lib/emass_client/models/poam_response_get_poams.rb +228 -0
  67. data/lib/emass_client/models/{static_code_required_post.rb → poam_response_get_systems.rb} +42 -29
  68. data/lib/emass_client/models/poam_response_post.rb +27 -14
  69. data/lib/emass_client/models/poam_response_put.rb +27 -14
  70. data/lib/emass_client/models/register.rb +27 -14
  71. data/lib/emass_client/models/register_data.rb +26 -13
  72. data/lib/emass_client/models/register_user_request_post_body.rb +26 -13
  73. data/lib/emass_client/models/{model_200.rb → response200.rb} +53 -16
  74. data/lib/emass_client/models/{model_400.rb → response201.rb} +29 -16
  75. data/lib/emass_client/models/{model_201_meta.rb → response201_meta.rb} +54 -17
  76. data/lib/emass_client/models/{model_400_response.rb → response400.rb} +29 -16
  77. data/lib/emass_client/models/{model_400_meta.rb → response400_meta.rb} +54 -17
  78. data/lib/emass_client/models/{model_401.rb → response401.rb} +29 -16
  79. data/lib/emass_client/models/{model_401_meta.rb → response401_meta.rb} +54 -17
  80. data/lib/emass_client/models/{model_201.rb → response403.rb} +29 -16
  81. data/lib/emass_client/models/{model_403_meta.rb → response403_meta.rb} +54 -17
  82. data/lib/emass_client/models/{model_404.rb → response404.rb} +54 -17
  83. data/lib/emass_client/models/response405.rb +219 -0
  84. data/lib/emass_client/models/{model_405_meta.rb → response405_meta.rb} +54 -17
  85. data/lib/emass_client/models/response411.rb +219 -0
  86. data/lib/emass_client/models/{model_411_meta.rb → response411_meta.rb} +54 -17
  87. data/lib/emass_client/models/response490.rb +219 -0
  88. data/lib/emass_client/models/{model_490_meta.rb → response490_meta.rb} +54 -17
  89. data/lib/emass_client/models/response500.rb +219 -0
  90. data/lib/emass_client/models/{model_500_meta.rb → response500_meta.rb} +54 -17
  91. data/lib/emass_client/models/role_category.rb +32 -50
  92. data/lib/emass_client/models/roles.rb +29 -61
  93. data/lib/emass_client/models/ssps.rb +32 -16
  94. data/lib/emass_client/models/stage.rb +30 -49
  95. data/lib/emass_client/models/static_code_application.rb +34 -33
  96. data/lib/emass_client/models/static_code_post.rb +275 -0
  97. data/lib/emass_client/models/static_code_request_post_body.rb +47 -14
  98. data/lib/emass_client/models/{static_code_required_post_application.rb → static_code_request_post_body_application.rb} +30 -17
  99. data/lib/emass_client/models/static_code_response_post.rb +230 -0
  100. data/lib/emass_client/models/success200_response.rb +27 -14
  101. data/lib/emass_client/models/{error.rb → success200_response_data_inner.rb} +57 -36
  102. data/lib/emass_client/models/system_response.rb +28 -17
  103. data/lib/emass_client/models/system_roles_category_response.rb +28 -14
  104. data/lib/emass_client/models/system_roles_response.rb +27 -14
  105. data/lib/emass_client/models/{system_roles_response_data.rb → system_roles_response_data_inner.rb} +30 -17
  106. data/lib/emass_client/models/systems.rb +218 -191
  107. data/lib/emass_client/models/{poam_response_get.rb → systems_response.rb} +30 -17
  108. data/lib/emass_client/models/test.rb +27 -14
  109. data/lib/emass_client/models/test_data.rb +26 -13
  110. data/lib/emass_client/models/test_results_get.rb +39 -35
  111. data/lib/emass_client/models/test_results_post.rb +58 -18
  112. data/lib/emass_client/models/test_results_response_get.rb +27 -14
  113. data/lib/emass_client/models/test_results_response_post.rb +27 -14
  114. data/lib/emass_client/models/users.rb +28 -15
  115. data/lib/emass_client/models/workflow_definition_get.rb +63 -68
  116. data/lib/emass_client/models/workflow_definition_response_get.rb +27 -14
  117. data/lib/emass_client/models/workflow_instance_get.rb +331 -0
  118. data/lib/emass_client/models/workflow_instance_response_get.rb +230 -0
  119. data/lib/emass_client/models/workflow_instances_get.rb +107 -133
  120. data/lib/emass_client/models/workflow_instances_response_get.rb +39 -17
  121. data/lib/emass_client/models/workflow_instances_response_get_pagination.rb +246 -0
  122. data/lib/emass_client/version.rb +6 -5
  123. data/lib/emass_client.rb +47 -54
  124. metadata +60 -89
  125. data/lib/emass_client/models/artifacts_delete.rb +0 -201
  126. data/lib/emass_client/models/artifacts_request_put_body.rb +0 -363
  127. data/lib/emass_client/models/cac_request_post_body.rb +0 -217
  128. data/lib/emass_client/models/controls_request_put_body.rb +0 -606
  129. data/lib/emass_client/models/empty200_response.rb +0 -197
  130. data/lib/emass_client/models/milestones_delete.rb +0 -197
  131. data/lib/emass_client/models/milestones_post.rb +0 -197
  132. data/lib/emass_client/models/milestones_put.rb +0 -197
  133. data/lib/emass_client/models/milestones_request_post_body.rb +0 -242
  134. data/lib/emass_client/models/milestones_request_put_body.rb +0 -242
  135. data/lib/emass_client/models/model_403.rb +0 -206
  136. data/lib/emass_client/models/model_404_response.rb +0 -206
  137. data/lib/emass_client/models/model_405.rb +0 -206
  138. data/lib/emass_client/models/model_411.rb +0 -206
  139. data/lib/emass_client/models/model_490.rb +0 -206
  140. data/lib/emass_client/models/model_500.rb +0 -206
  141. data/lib/emass_client/models/poam_delete.rb +0 -197
  142. data/lib/emass_client/models/poam_post.rb +0 -197
  143. data/lib/emass_client/models/poam_put.rb +0 -197
  144. data/lib/emass_client/models/poam_request_post_body.rb +0 -197
  145. data/lib/emass_client/models/poam_request_put_body.rb +0 -197
  146. data/lib/emass_client/models/poam_required_post.rb +0 -564
  147. data/lib/emass_client/models/poam_required_put.rb +0 -594
  148. data/lib/emass_client/models/system_id_artifacts_body.rb +0 -284
  149. data/lib/emass_client/models/test_results_request_post_body.rb +0 -306
@@ -1,14 +1,17 @@
1
1
  =begin
2
2
  #Enterprise Mission Assurance Support Service (eMASS)
3
3
 
4
- #The Enterprise Mission Assurance Support Service (eMASS) Representational State Transfer (REST) Application Programming Interface (API) enables users to perform assessments and complete actions associated with system records. The `emasser` is a command-line interface (CLI) tool that implements all of the eMASS endpoints defined in the eMASS REST API v3.2, dated October 21, 2021.</br><br> <strong>Register CLI</strong></br> New users will need to register an API key with the eMASS development team prior to accessing the site for the first time. The eMASS REST API requires a client certificate (SSL/TLS, DoD PKI only) where {url}/api/register (POST) is used to register the client certificate.</br></br> Every call to the eMASS REST API will require the use of the agreed upon public key certificate and API key. The API key must be provided in the request header for all endpoint calls (api-key). If the service receives an untrusted certificate or API key, a 401 error response code will be returned along with an error message.</br></br> <strong>Available Request Headers:</strong></br> <table> <tr> <th align=left>key</th> <th align=left>Example Value</th> <th align=left>Description</th> </tr> <tr> <td>`api-key`</td> <td>api-key-provided-by-emass</td> <td>This API key must be provided in the request header for all endpoint calls</td> </tr> <tr> <td>`user-uid`</td> <td>USER.UID.KEY</td> <td>This User unique identifier key must be provided in the request header for all PUT, POST, and DELETE endpoint calls</td> </tr> <tr> <td></td><td></td> <td> Note: For DoD users this is the DoD ID Number (EIDIPI) on their DoD CAC </td> </tr> </table> </br><strong>Approve API Client for Actionable Requests</strong></br> Users are required to log-in to eMASS and grant permissions for a client to update data within eMASS on their behalf. This is only required for actionable requests (PUT, POST, DELETE). The Registration Endpoint and all GET requests can be accessed without completing this process with the correct permissions. Please note that leaving a field parameter blank (for PUT/POST requests) has the potential to clear information in the active eMASS records. To establish an account with eMASS and/or acquire an api-key/user-uid, contact one of the listed POC:
4
+ #The Enterprise Mission Assurance Support Service (eMASS) Representational State Transfer (REST) Application Programming Interface (API) enables users to perform assessments and complete actions associated with system records. <strong>Register External Application (that use the eMASS API)</strong></br> New users will need to [register](https://nisp.emass.apps.mil/Content/Help/jobaids/eMASS_OT_NewUser_Job_Aid.pdf) an API key with the eMASS development team prior to accessing the site for the first time. The eMASS REST API requires a client certificate (SSL/TLS, DoD PKI only). Use the `Registration` endpoint to register the client certificate.</br></br> Every call to the eMASS REST API will require the use of the agreed upon public key certificate and API key. The API key must be provided in the request header for all endpoint calls (api-key). If the service receives an untrusted certificate or API key, a 401 error response code will be returned along with an error message.</br></br> <strong>Available Request Headers</strong></br> <table> <tr> <th align=left>key</th> <th align=left>Example Value</th> <th align=left>Description</th> </tr> <tr> <td>`api-key`</td> <td>api-key-provided-by-emass</td> <td>This API key must be provided in the request header for all endpoint calls</td> </tr> <tr> <td>`user-uid`</td> <td>USER.UID.KEY</td> <td>This User unique identifier key must be provided in the request header for all PUT, POST, and DELETE endpoint calls</td> </tr> <tr> <td></td><td></td> <td> Note: For DoD users this is the DoD ID Number (EIDIPI) on their DoD CAC </td> </tr> </table> </br><strong>Approve API Client for Actionable Requests</strong></br> Users are required to log-in to eMASS and grant permissions for a client to update data within eMASS on their behalf. This is only required for actionable requests (PUT, POST, DELETE). The Registration Endpoint and all GET requests can be accessed without completing this process with the correct permissions. Please note that leaving a field parameter blank (for PUT/POST requests) has the potential to clear information in the active eMASS records. To establish an account with eMASS and/or acquire an api-key/user-uid, contact one of the listed POC:
5
5
 
6
- OpenAPI spec version: v3.2
6
+ The version of the OpenAPI document: v3.3
7
7
  Contact: disa.meade.id.mbx.emass-tier-iii-support@mail.mil
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 3.0.26
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.0.1-SNAPSHOT
10
+
10
11
  =end
11
12
 
13
+ require 'cgi'
14
+
12
15
  module EmassClient
13
16
  class MilestonesApi
14
17
  attr_accessor :api_client
@@ -18,31 +21,27 @@ module EmassClient
18
21
  end
19
22
  # Add milestones to one or many POA&M items in a system
20
23
  # Adds a milestone for given `systemId` and `poamId` path parameters **Request Body Required Fields** - `description` - `scheduledCompletionDate`
21
- # @param body Update an existing milestone
22
- # @param system_id **System Id**: The unique system record identifier.
23
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
24
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
25
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
26
+ # @param request_body [Array<Object>] Add milestones to an existing system poam
24
27
  # @param [Hash] opts the optional parameters
25
28
  # @return [MilestoneResponsePost]
26
- def add_milestone_by_system_id_and_poam_id(body, system_id, poam_id, opts = {})
27
- data, _status_code, _headers = add_milestone_by_system_id_and_poam_id_with_http_info(body, system_id, poam_id, opts)
29
+ def add_milestone_by_system_id_and_poam_id(system_id, poam_id, request_body, opts = {})
30
+ data, _status_code, _headers = add_milestone_by_system_id_and_poam_id_with_http_info(system_id, poam_id, request_body, opts)
28
31
  data
29
32
  end
30
33
 
31
34
  # Add milestones to one or many POA&amp;M items in a system
32
35
  # Adds a milestone for given &#x60;systemId&#x60; and &#x60;poamId&#x60; path parameters **Request Body Required Fields** - &#x60;description&#x60; - &#x60;scheduledCompletionDate&#x60;
33
- # @param body Update an existing milestone
34
- # @param system_id **System Id**: The unique system record identifier.
35
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
36
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
37
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
38
+ # @param request_body [Array<Object>] Add milestones to an existing system poam
36
39
  # @param [Hash] opts the optional parameters
37
40
  # @return [Array<(MilestoneResponsePost, Integer, Hash)>] MilestoneResponsePost data, response status code and response headers
38
- def add_milestone_by_system_id_and_poam_id_with_http_info(body, system_id, poam_id, opts = {})
41
+ def add_milestone_by_system_id_and_poam_id_with_http_info(system_id, poam_id, request_body, opts = {})
39
42
  if @api_client.config.debugging
40
43
  @api_client.config.logger.debug 'Calling API: MilestonesApi.add_milestone_by_system_id_and_poam_id ...'
41
44
  end
42
- # verify the required parameter 'body' is set
43
- if @api_client.config.client_side_validation && body.nil?
44
- fail ArgumentError, "Missing the required parameter 'body' when calling MilestonesApi.add_milestone_by_system_id_and_poam_id"
45
- end
46
45
  # verify the required parameter 'system_id' is set
47
46
  if @api_client.config.client_side_validation && system_id.nil?
48
47
  fail ArgumentError, "Missing the required parameter 'system_id' when calling MilestonesApi.add_milestone_by_system_id_and_poam_id"
@@ -51,8 +50,12 @@ module EmassClient
51
50
  if @api_client.config.client_side_validation && poam_id.nil?
52
51
  fail ArgumentError, "Missing the required parameter 'poam_id' when calling MilestonesApi.add_milestone_by_system_id_and_poam_id"
53
52
  end
53
+ # verify the required parameter 'request_body' is set
54
+ if @api_client.config.client_side_validation && request_body.nil?
55
+ fail ArgumentError, "Missing the required parameter 'request_body' when calling MilestonesApi.add_milestone_by_system_id_and_poam_id"
56
+ end
54
57
  # resource path
55
- local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', system_id.to_s).sub('{' + 'poamId' + '}', poam_id.to_s)
58
+ local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', CGI.escape(system_id.to_s)).sub('{' + 'poamId' + '}', CGI.escape(poam_id.to_s))
56
59
 
57
60
  # query parameters
58
61
  query_params = opts[:query_params] || {}
@@ -62,57 +65,63 @@ module EmassClient
62
65
  # HTTP header 'Accept' (if needed)
63
66
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
64
67
  # HTTP header 'Content-Type'
65
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
68
+ content_type = @api_client.select_header_content_type(['application/json'])
69
+ if !content_type.nil?
70
+ header_params['Content-Type'] = content_type
71
+ end
66
72
 
67
73
  # form parameters
68
74
  form_params = opts[:form_params] || {}
69
75
 
70
76
  # http body (model)
71
- post_body = opts[:body] || @api_client.object_to_http_body(body)
77
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)
78
+
79
+ # return_type
80
+ return_type = opts[:debug_return_type] || 'MilestoneResponsePost'
72
81
 
73
- return_type = opts[:return_type] || 'MilestoneResponsePost'
82
+ # auth_names
83
+ auth_names = opts[:debug_auth_names] || ['apiKey', 'mockType', 'userId']
74
84
 
75
- auth_names = opts[:auth_names] || ['apikey', 'mockType', 'userid']
76
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
85
+ new_options = opts.merge(
86
+ :operation => :"MilestonesApi.add_milestone_by_system_id_and_poam_id",
77
87
  :header_params => header_params,
78
88
  :query_params => query_params,
79
89
  :form_params => form_params,
80
90
  :body => post_body,
81
91
  :auth_names => auth_names,
82
- :return_type => return_type)
92
+ :return_type => return_type
93
+ )
83
94
 
95
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
84
96
  if @api_client.config.debugging
85
97
  @api_client.config.logger.debug "API called: MilestonesApi#add_milestone_by_system_id_and_poam_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
86
98
  end
87
99
  return data, status_code, headers
88
100
  end
101
+
89
102
  # Remove milestones in a system for one or many POA&M items
90
- # Remove the POA&M matching `systemId` path parameter<br> **Notes**<br> To delete a milestone the record must be inactive by having the field isActive set to false (`isActive=false`).
91
- # @param body Delete the given Milestone Id
92
- # @param system_id **System Id**: The unique system record identifier.
93
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
103
+ # Remove the POA&M matching `systemId` and `poamId` for path parameters and `milstoneId` provide in the Requst Body **Notes**<br> To delete a milestone the record must be inactive by having the field isActive set to false (`isActive=false`).
104
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
105
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
106
+ # @param milestones_request_delete_body_inner [Array<MilestonesRequestDeleteBodyInner>] Delete the given Milestone Id
94
107
  # @param [Hash] opts the optional parameters
95
- # @return [Empty200Response]
96
- def delete_milestone(body, system_id, poam_id, opts = {})
97
- data, _status_code, _headers = delete_milestone_with_http_info(body, system_id, poam_id, opts)
108
+ # @return [MilestonesPutPostDelete]
109
+ def delete_milestone(system_id, poam_id, milestones_request_delete_body_inner, opts = {})
110
+ data, _status_code, _headers = delete_milestone_with_http_info(system_id, poam_id, milestones_request_delete_body_inner, opts)
98
111
  data
99
112
  end
100
113
 
101
114
  # Remove milestones in a system for one or many POA&amp;M items
102
- # Remove the POA&amp;M matching &#x60;systemId&#x60; path parameter&lt;br&gt; **Notes**&lt;br&gt; To delete a milestone the record must be inactive by having the field isActive set to false (&#x60;isActive&#x3D;false&#x60;).
103
- # @param body Delete the given Milestone Id
104
- # @param system_id **System Id**: The unique system record identifier.
105
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
115
+ # Remove the POA&amp;M matching &#x60;systemId&#x60; and &#x60;poamId&#x60; for path parameters and &#x60;milstoneId&#x60; provide in the Requst Body **Notes**&lt;br&gt; To delete a milestone the record must be inactive by having the field isActive set to false (&#x60;isActive&#x3D;false&#x60;).
116
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
117
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
118
+ # @param milestones_request_delete_body_inner [Array<MilestonesRequestDeleteBodyInner>] Delete the given Milestone Id
106
119
  # @param [Hash] opts the optional parameters
107
- # @return [Array<(Empty200Response, Integer, Hash)>] Empty200Response data, response status code and response headers
108
- def delete_milestone_with_http_info(body, system_id, poam_id, opts = {})
120
+ # @return [Array<(MilestonesPutPostDelete, Integer, Hash)>] MilestonesPutPostDelete data, response status code and response headers
121
+ def delete_milestone_with_http_info(system_id, poam_id, milestones_request_delete_body_inner, opts = {})
109
122
  if @api_client.config.debugging
110
123
  @api_client.config.logger.debug 'Calling API: MilestonesApi.delete_milestone ...'
111
124
  end
112
- # verify the required parameter 'body' is set
113
- if @api_client.config.client_side_validation && body.nil?
114
- fail ArgumentError, "Missing the required parameter 'body' when calling MilestonesApi.delete_milestone"
115
- end
116
125
  # verify the required parameter 'system_id' is set
117
126
  if @api_client.config.client_side_validation && system_id.nil?
118
127
  fail ArgumentError, "Missing the required parameter 'system_id' when calling MilestonesApi.delete_milestone"
@@ -121,8 +130,12 @@ module EmassClient
121
130
  if @api_client.config.client_side_validation && poam_id.nil?
122
131
  fail ArgumentError, "Missing the required parameter 'poam_id' when calling MilestonesApi.delete_milestone"
123
132
  end
133
+ # verify the required parameter 'milestones_request_delete_body_inner' is set
134
+ if @api_client.config.client_side_validation && milestones_request_delete_body_inner.nil?
135
+ fail ArgumentError, "Missing the required parameter 'milestones_request_delete_body_inner' when calling MilestonesApi.delete_milestone"
136
+ end
124
137
  # resource path
125
- local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', system_id.to_s).sub('{' + 'poamId' + '}', poam_id.to_s)
138
+ local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', CGI.escape(system_id.to_s)).sub('{' + 'poamId' + '}', CGI.escape(poam_id.to_s))
126
139
 
127
140
  # query parameters
128
141
  query_params = opts[:query_params] || {}
@@ -132,34 +145,44 @@ module EmassClient
132
145
  # HTTP header 'Accept' (if needed)
133
146
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
134
147
  # HTTP header 'Content-Type'
135
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
148
+ content_type = @api_client.select_header_content_type(['application/json'])
149
+ if !content_type.nil?
150
+ header_params['Content-Type'] = content_type
151
+ end
136
152
 
137
153
  # form parameters
138
154
  form_params = opts[:form_params] || {}
139
155
 
140
156
  # http body (model)
141
- post_body = opts[:body] || @api_client.object_to_http_body(body)
157
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(milestones_request_delete_body_inner)
158
+
159
+ # return_type
160
+ return_type = opts[:debug_return_type] || 'MilestonesPutPostDelete'
142
161
 
143
- return_type = opts[:return_type] || 'Empty200Response'
162
+ # auth_names
163
+ auth_names = opts[:debug_auth_names] || ['apiKey', 'mockType', 'userId']
144
164
 
145
- auth_names = opts[:auth_names] || ['apikey', 'mockType', 'userid']
146
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
165
+ new_options = opts.merge(
166
+ :operation => :"MilestonesApi.delete_milestone",
147
167
  :header_params => header_params,
148
168
  :query_params => query_params,
149
169
  :form_params => form_params,
150
170
  :body => post_body,
151
171
  :auth_names => auth_names,
152
- :return_type => return_type)
172
+ :return_type => return_type
173
+ )
153
174
 
175
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
154
176
  if @api_client.config.debugging
155
177
  @api_client.config.logger.debug "API called: MilestonesApi#delete_milestone\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
156
178
  end
157
179
  return data, status_code, headers
158
180
  end
181
+
159
182
  # Get milestones in one or many POA&M items in a system
160
183
  # Returns system containing milestones for matching parameters.
161
- # @param system_id **System Id**: The unique system record identifier.
162
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
184
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
185
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
163
186
  # @param [Hash] opts the optional parameters
164
187
  # @option opts [String] :scheduled_completion_date_start **Date Started**: Filter query by the scheduled completion start date (Unix date format).
165
188
  # @option opts [String] :scheduled_completion_date_end **Date Ended**: Filter query by the scheduled completion start date (Unix date format).
@@ -171,8 +194,8 @@ module EmassClient
171
194
 
172
195
  # Get milestones in one or many POA&amp;M items in a system
173
196
  # Returns system containing milestones for matching parameters.
174
- # @param system_id **System Id**: The unique system record identifier.
175
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
197
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
198
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
176
199
  # @param [Hash] opts the optional parameters
177
200
  # @option opts [String] :scheduled_completion_date_start **Date Started**: Filter query by the scheduled completion start date (Unix date format).
178
201
  # @option opts [String] :scheduled_completion_date_end **Date Ended**: Filter query by the scheduled completion start date (Unix date format).
@@ -190,7 +213,7 @@ module EmassClient
190
213
  fail ArgumentError, "Missing the required parameter 'poam_id' when calling MilestonesApi.get_system_milestones_by_poam_id"
191
214
  end
192
215
  # resource path
193
- local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', system_id.to_s).sub('{' + 'poamId' + '}', poam_id.to_s)
216
+ local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', CGI.escape(system_id.to_s)).sub('{' + 'poamId' + '}', CGI.escape(poam_id.to_s))
194
217
 
195
218
  # query parameters
196
219
  query_params = opts[:query_params] || {}
@@ -206,31 +229,38 @@ module EmassClient
206
229
  form_params = opts[:form_params] || {}
207
230
 
208
231
  # http body (model)
209
- post_body = opts[:body]
232
+ post_body = opts[:debug_body]
233
+
234
+ # return_type
235
+ return_type = opts[:debug_return_type] || 'MilestoneResponseGet'
210
236
 
211
- return_type = opts[:return_type] || 'MilestoneResponseGet'
237
+ # auth_names
238
+ auth_names = opts[:debug_auth_names] || ['apiKey', 'mockType', 'userId']
212
239
 
213
- auth_names = opts[:auth_names] || ['apikey', 'mockType', 'userid']
214
- data, status_code, headers = @api_client.call_api(:GET, local_var_path,
240
+ new_options = opts.merge(
241
+ :operation => :"MilestonesApi.get_system_milestones_by_poam_id",
215
242
  :header_params => header_params,
216
243
  :query_params => query_params,
217
244
  :form_params => form_params,
218
245
  :body => post_body,
219
246
  :auth_names => auth_names,
220
- :return_type => return_type)
247
+ :return_type => return_type
248
+ )
221
249
 
250
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
222
251
  if @api_client.config.debugging
223
252
  @api_client.config.logger.debug "API called: MilestonesApi#get_system_milestones_by_poam_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
224
253
  end
225
254
  return data, status_code, headers
226
255
  end
256
+
227
257
  # Get milestone by ID in POA&M item in a system
228
258
  # Returns systems containing milestones for matching parameters.
229
- # @param system_id **System Id**: The unique system record identifier.
230
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
231
- # @param milestone_id **Milestone Id**: The unique milestone record identifier.
259
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
260
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
261
+ # @param milestone_id [Integer] **Milestone Id**: The unique milestone record identifier.
232
262
  # @param [Hash] opts the optional parameters
233
- # @return [MilestoneResponseGet]
263
+ # @return [MilestoneResponseGetMilestone]
234
264
  def get_system_milestones_by_poam_id_and_milestone_id(system_id, poam_id, milestone_id, opts = {})
235
265
  data, _status_code, _headers = get_system_milestones_by_poam_id_and_milestone_id_with_http_info(system_id, poam_id, milestone_id, opts)
236
266
  data
@@ -238,11 +268,11 @@ module EmassClient
238
268
 
239
269
  # Get milestone by ID in POA&amp;M item in a system
240
270
  # Returns systems containing milestones for matching parameters.
241
- # @param system_id **System Id**: The unique system record identifier.
242
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
243
- # @param milestone_id **Milestone Id**: The unique milestone record identifier.
271
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
272
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
273
+ # @param milestone_id [Integer] **Milestone Id**: The unique milestone record identifier.
244
274
  # @param [Hash] opts the optional parameters
245
- # @return [Array<(MilestoneResponseGet, Integer, Hash)>] MilestoneResponseGet data, response status code and response headers
275
+ # @return [Array<(MilestoneResponseGetMilestone, Integer, Hash)>] MilestoneResponseGetMilestone data, response status code and response headers
246
276
  def get_system_milestones_by_poam_id_and_milestone_id_with_http_info(system_id, poam_id, milestone_id, opts = {})
247
277
  if @api_client.config.debugging
248
278
  @api_client.config.logger.debug 'Calling API: MilestonesApi.get_system_milestones_by_poam_id_and_milestone_id ...'
@@ -260,7 +290,7 @@ module EmassClient
260
290
  fail ArgumentError, "Missing the required parameter 'milestone_id' when calling MilestonesApi.get_system_milestones_by_poam_id_and_milestone_id"
261
291
  end
262
292
  # resource path
263
- local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones/{milestoneId}'.sub('{' + 'systemId' + '}', system_id.to_s).sub('{' + 'poamId' + '}', poam_id.to_s).sub('{' + 'milestoneId' + '}', milestone_id.to_s)
293
+ local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones/{milestoneId}'.sub('{' + 'systemId' + '}', CGI.escape(system_id.to_s)).sub('{' + 'poamId' + '}', CGI.escape(poam_id.to_s)).sub('{' + 'milestoneId' + '}', CGI.escape(milestone_id.to_s))
264
294
 
265
295
  # query parameters
266
296
  query_params = opts[:query_params] || {}
@@ -274,51 +304,54 @@ module EmassClient
274
304
  form_params = opts[:form_params] || {}
275
305
 
276
306
  # http body (model)
277
- post_body = opts[:body]
307
+ post_body = opts[:debug_body]
308
+
309
+ # return_type
310
+ return_type = opts[:debug_return_type] || 'MilestoneResponseGetMilestone'
278
311
 
279
- return_type = opts[:return_type] || 'MilestoneResponseGet'
312
+ # auth_names
313
+ auth_names = opts[:debug_auth_names] || ['apiKey', 'mockType', 'userId']
280
314
 
281
- auth_names = opts[:auth_names] || ['apikey', 'mockType', 'userid']
282
- data, status_code, headers = @api_client.call_api(:GET, local_var_path,
315
+ new_options = opts.merge(
316
+ :operation => :"MilestonesApi.get_system_milestones_by_poam_id_and_milestone_id",
283
317
  :header_params => header_params,
284
318
  :query_params => query_params,
285
319
  :form_params => form_params,
286
320
  :body => post_body,
287
321
  :auth_names => auth_names,
288
- :return_type => return_type)
322
+ :return_type => return_type
323
+ )
289
324
 
325
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
290
326
  if @api_client.config.debugging
291
327
  @api_client.config.logger.debug "API called: MilestonesApi#get_system_milestones_by_poam_id_and_milestone_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
292
328
  end
293
329
  return data, status_code, headers
294
330
  end
331
+
295
332
  # Update one or many POA&M items in a system
296
333
  # Updates a milestone for given `systemId` and `poamId` path parameters **Request Body Required Fields** - `milestoneId` - `description` - `scheduledCompletionDate`
297
- # @param body Update an existing control by Id
298
- # @param system_id **System Id**: The unique system record identifier.
299
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
334
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
335
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
336
+ # @param request_body [Array<Object>] Update milestones for an existing system poam
300
337
  # @param [Hash] opts the optional parameters
301
338
  # @return [MilestoneResponsePut]
302
- def update_milestone_by_system_id_and_poam_id(body, system_id, poam_id, opts = {})
303
- data, _status_code, _headers = update_milestone_by_system_id_and_poam_id_with_http_info(body, system_id, poam_id, opts)
339
+ def update_milestone_by_system_id_and_poam_id(system_id, poam_id, request_body, opts = {})
340
+ data, _status_code, _headers = update_milestone_by_system_id_and_poam_id_with_http_info(system_id, poam_id, request_body, opts)
304
341
  data
305
342
  end
306
343
 
307
344
  # Update one or many POA&amp;M items in a system
308
345
  # Updates a milestone for given &#x60;systemId&#x60; and &#x60;poamId&#x60; path parameters **Request Body Required Fields** - &#x60;milestoneId&#x60; - &#x60;description&#x60; - &#x60;scheduledCompletionDate&#x60;
309
- # @param body Update an existing control by Id
310
- # @param system_id **System Id**: The unique system record identifier.
311
- # @param poam_id **POA&amp;M Id**: The unique POA&amp;M record identifier.
346
+ # @param system_id [Integer] **System Id**: The unique system record identifier.
347
+ # @param poam_id [Integer] **POA&amp;M Id**: The unique POA&amp;M record identifier.
348
+ # @param request_body [Array<Object>] Update milestones for an existing system poam
312
349
  # @param [Hash] opts the optional parameters
313
350
  # @return [Array<(MilestoneResponsePut, Integer, Hash)>] MilestoneResponsePut data, response status code and response headers
314
- def update_milestone_by_system_id_and_poam_id_with_http_info(body, system_id, poam_id, opts = {})
351
+ def update_milestone_by_system_id_and_poam_id_with_http_info(system_id, poam_id, request_body, opts = {})
315
352
  if @api_client.config.debugging
316
353
  @api_client.config.logger.debug 'Calling API: MilestonesApi.update_milestone_by_system_id_and_poam_id ...'
317
354
  end
318
- # verify the required parameter 'body' is set
319
- if @api_client.config.client_side_validation && body.nil?
320
- fail ArgumentError, "Missing the required parameter 'body' when calling MilestonesApi.update_milestone_by_system_id_and_poam_id"
321
- end
322
355
  # verify the required parameter 'system_id' is set
323
356
  if @api_client.config.client_side_validation && system_id.nil?
324
357
  fail ArgumentError, "Missing the required parameter 'system_id' when calling MilestonesApi.update_milestone_by_system_id_and_poam_id"
@@ -327,8 +360,12 @@ module EmassClient
327
360
  if @api_client.config.client_side_validation && poam_id.nil?
328
361
  fail ArgumentError, "Missing the required parameter 'poam_id' when calling MilestonesApi.update_milestone_by_system_id_and_poam_id"
329
362
  end
363
+ # verify the required parameter 'request_body' is set
364
+ if @api_client.config.client_side_validation && request_body.nil?
365
+ fail ArgumentError, "Missing the required parameter 'request_body' when calling MilestonesApi.update_milestone_by_system_id_and_poam_id"
366
+ end
330
367
  # resource path
331
- local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', system_id.to_s).sub('{' + 'poamId' + '}', poam_id.to_s)
368
+ local_var_path = '/api/systems/{systemId}/poams/{poamId}/milestones'.sub('{' + 'systemId' + '}', CGI.escape(system_id.to_s)).sub('{' + 'poamId' + '}', CGI.escape(poam_id.to_s))
332
369
 
333
370
  # query parameters
334
371
  query_params = opts[:query_params] || {}
@@ -338,25 +375,34 @@ module EmassClient
338
375
  # HTTP header 'Accept' (if needed)
339
376
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
340
377
  # HTTP header 'Content-Type'
341
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
378
+ content_type = @api_client.select_header_content_type(['application/json'])
379
+ if !content_type.nil?
380
+ header_params['Content-Type'] = content_type
381
+ end
342
382
 
343
383
  # form parameters
344
384
  form_params = opts[:form_params] || {}
345
385
 
346
386
  # http body (model)
347
- post_body = opts[:body] || @api_client.object_to_http_body(body)
387
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)
388
+
389
+ # return_type
390
+ return_type = opts[:debug_return_type] || 'MilestoneResponsePut'
348
391
 
349
- return_type = opts[:return_type] || 'MilestoneResponsePut'
392
+ # auth_names
393
+ auth_names = opts[:debug_auth_names] || ['apiKey', 'mockType', 'userId']
350
394
 
351
- auth_names = opts[:auth_names] || ['apikey', 'mockType', 'userid']
352
- data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
395
+ new_options = opts.merge(
396
+ :operation => :"MilestonesApi.update_milestone_by_system_id_and_poam_id",
353
397
  :header_params => header_params,
354
398
  :query_params => query_params,
355
399
  :form_params => form_params,
356
400
  :body => post_body,
357
401
  :auth_names => auth_names,
358
- :return_type => return_type)
402
+ :return_type => return_type
403
+ )
359
404
 
405
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
360
406
  if @api_client.config.debugging
361
407
  @api_client.config.logger.debug "API called: MilestonesApi#update_milestone_by_system_id_and_poam_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
362
408
  end