openlayer 0.14.1 → 0.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (231) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +34 -0
  3. data/README.md +1 -1
  4. data/lib/openlayer/client.rb +8 -0
  5. data/lib/openlayer/models/background_task_retrieve_params.rb +20 -0
  6. data/lib/openlayer/models/background_task_retrieve_response.rb +81 -0
  7. data/lib/openlayer/models/governance/framework_create_params.rb +143 -0
  8. data/lib/openlayer/models/governance/framework_create_response.rb +407 -0
  9. data/lib/openlayer/models/governance/framework_export_params.rb +31 -0
  10. data/lib/openlayer/models/governance/framework_export_response.rb +32 -0
  11. data/lib/openlayer/models/governance/framework_list_params.rb +148 -0
  12. data/lib/openlayer/models/governance/framework_list_project_rule_stats_params.rb +74 -0
  13. data/lib/openlayer/models/governance/framework_list_project_rule_stats_response.rb +277 -0
  14. data/lib/openlayer/models/governance/framework_list_projects_params.rb +39 -0
  15. data/lib/openlayer/models/governance/framework_list_projects_response.rb +315 -0
  16. data/lib/openlayer/models/governance/framework_list_response.rb +418 -0
  17. data/lib/openlayer/models/governance/framework_list_rules_params.rb +39 -0
  18. data/lib/openlayer/models/governance/framework_list_rules_response.rb +656 -0
  19. data/lib/openlayer/models/governance/framework_retrieve_params.rb +22 -0
  20. data/lib/openlayer/models/governance/framework_retrieve_response.rb +407 -0
  21. data/lib/openlayer/models/governance/framework_update_params.rb +200 -0
  22. data/lib/openlayer/models/governance/framework_update_response.rb +407 -0
  23. data/lib/openlayer/models/governance/frameworks/document_list_params.rb +41 -0
  24. data/lib/openlayer/models/governance/frameworks/document_list_response.rb +572 -0
  25. data/lib/openlayer/models/governance/frameworks/document_retrieve_params.rb +30 -0
  26. data/lib/openlayer/models/governance/frameworks/document_retrieve_response.rb +561 -0
  27. data/lib/openlayer/models/governance/frameworks/section_list_rules_params.rb +96 -0
  28. data/lib/openlayer/models/governance/frameworks/section_list_rules_response.rb +660 -0
  29. data/lib/openlayer/models/governance/frameworks/subsection_list_rules_params.rb +88 -0
  30. data/lib/openlayer/models/governance/frameworks/subsection_list_rules_response.rb +660 -0
  31. data/lib/openlayer/models/governance/rule_create_params.rb +164 -0
  32. data/lib/openlayer/models/governance/rule_create_response.rb +638 -0
  33. data/lib/openlayer/models/governance/rule_delete_params.rb +22 -0
  34. data/lib/openlayer/models/governance/rule_list_params.rb +231 -0
  35. data/lib/openlayer/models/governance/rule_list_response.rb +654 -0
  36. data/lib/openlayer/models/governance/rule_result_create_evidence_params.rb +68 -0
  37. data/lib/openlayer/models/governance/rule_result_create_evidence_response.rb +90 -0
  38. data/lib/openlayer/models/governance/rule_result_list_evidence_params.rb +39 -0
  39. data/lib/openlayer/models/governance/rule_result_list_evidence_response.rb +101 -0
  40. data/lib/openlayer/models/governance/rule_result_list_params.rb +149 -0
  41. data/lib/openlayer/models/governance/rule_result_list_response.rb +255 -0
  42. data/lib/openlayer/models/governance/rule_result_retrieve_params.rb +22 -0
  43. data/lib/openlayer/models/governance/rule_result_retrieve_response.rb +243 -0
  44. data/lib/openlayer/models/governance/rule_result_update_params.rb +140 -0
  45. data/lib/openlayer/models/governance/rule_result_update_response.rb +242 -0
  46. data/lib/openlayer/models/governance/rule_retrieve_params.rb +22 -0
  47. data/lib/openlayer/models/governance/rule_retrieve_response.rb +642 -0
  48. data/lib/openlayer/models/governance/rule_stat_retrieve_params.rb +39 -0
  49. data/lib/openlayer/models/governance/rule_stat_retrieve_response.rb +504 -0
  50. data/lib/openlayer/models/governance/rule_tag_list_params.rb +39 -0
  51. data/lib/openlayer/models/governance/rule_tag_list_response.rb +88 -0
  52. data/lib/openlayer/models/governance/rule_update_params.rb +77 -0
  53. data/lib/openlayer/models/governance/rule_update_response.rb +638 -0
  54. data/lib/openlayer/models/inference_pipeline_retrieve_response.rb +38 -2
  55. data/lib/openlayer/models/inference_pipeline_update_response.rb +37 -2
  56. data/lib/openlayer/models/project_create_params.rb +37 -1
  57. data/lib/openlayer/models/project_create_response.rb +37 -2
  58. data/lib/openlayer/models/project_list_response.rb +37 -2
  59. data/lib/openlayer/models/project_update_params.rb +73 -0
  60. data/lib/openlayer/models/project_update_response.rb +297 -0
  61. data/lib/openlayer/models/projects/inference_pipeline_create_params.rb +38 -2
  62. data/lib/openlayer/models/projects/inference_pipeline_create_response.rb +38 -2
  63. data/lib/openlayer/models/projects/inference_pipeline_list_response.rb +41 -2
  64. data/lib/openlayer/models/storage/presigned_url_retrieve_params.rb +24 -0
  65. data/lib/openlayer/models/storage/presigned_url_retrieve_response.rb +19 -0
  66. data/lib/openlayer/models.rb +6 -0
  67. data/lib/openlayer/resources/background_tasks.rb +38 -0
  68. data/lib/openlayer/resources/governance/frameworks/documents.rb +80 -0
  69. data/lib/openlayer/resources/governance/frameworks/sections.rb +72 -0
  70. data/lib/openlayer/resources/governance/frameworks/subsections.rb +69 -0
  71. data/lib/openlayer/resources/governance/frameworks.rb +344 -0
  72. data/lib/openlayer/resources/governance/rule_results.rb +212 -0
  73. data/lib/openlayer/resources/governance/rule_stats.rb +47 -0
  74. data/lib/openlayer/resources/governance/rule_tags.rb +47 -0
  75. data/lib/openlayer/resources/governance/rules.rb +241 -0
  76. data/lib/openlayer/resources/governance.rb +34 -0
  77. data/lib/openlayer/resources/projects.rb +49 -1
  78. data/lib/openlayer/resources/storage/presigned_url.rb +32 -0
  79. data/lib/openlayer/version.rb +1 -1
  80. data/lib/openlayer.rb +63 -0
  81. data/rbi/openlayer/client.rbi +6 -0
  82. data/rbi/openlayer/models/background_task_retrieve_params.rbi +38 -0
  83. data/rbi/openlayer/models/background_task_retrieve_response.rbi +102 -0
  84. data/rbi/openlayer/models/governance/framework_create_params.rbi +298 -0
  85. data/rbi/openlayer/models/governance/framework_create_response.rbi +730 -0
  86. data/rbi/openlayer/models/governance/framework_export_params.rbi +54 -0
  87. data/rbi/openlayer/models/governance/framework_export_response.rbi +48 -0
  88. data/rbi/openlayer/models/governance/framework_list_params.rbi +310 -0
  89. data/rbi/openlayer/models/governance/framework_list_project_rule_stats_params.rbi +178 -0
  90. data/rbi/openlayer/models/governance/framework_list_project_rule_stats_response.rbi +440 -0
  91. data/rbi/openlayer/models/governance/framework_list_projects_params.rbi +68 -0
  92. data/rbi/openlayer/models/governance/framework_list_projects_response.rbi +498 -0
  93. data/rbi/openlayer/models/governance/framework_list_response.rbi +771 -0
  94. data/rbi/openlayer/models/governance/framework_list_rules_params.rbi +68 -0
  95. data/rbi/openlayer/models/governance/framework_list_rules_response.rbi +1298 -0
  96. data/rbi/openlayer/models/governance/framework_retrieve_params.rbi +40 -0
  97. data/rbi/openlayer/models/governance/framework_retrieve_response.rbi +730 -0
  98. data/rbi/openlayer/models/governance/framework_update_params.rbi +425 -0
  99. data/rbi/openlayer/models/governance/framework_update_response.rbi +730 -0
  100. data/rbi/openlayer/models/governance/frameworks/document_list_params.rbi +70 -0
  101. data/rbi/openlayer/models/governance/frameworks/document_list_response.rbi +1012 -0
  102. data/rbi/openlayer/models/governance/frameworks/document_retrieve_params.rbi +50 -0
  103. data/rbi/openlayer/models/governance/frameworks/document_retrieve_response.rbi +968 -0
  104. data/rbi/openlayer/models/governance/frameworks/section_list_rules_params.rbi +193 -0
  105. data/rbi/openlayer/models/governance/frameworks/section_list_rules_response.rbi +1302 -0
  106. data/rbi/openlayer/models/governance/frameworks/subsection_list_rules_params.rbi +182 -0
  107. data/rbi/openlayer/models/governance/frameworks/subsection_list_rules_response.rbi +1302 -0
  108. data/rbi/openlayer/models/governance/rule_create_params.rbi +276 -0
  109. data/rbi/openlayer/models/governance/rule_create_response.rbi +1253 -0
  110. data/rbi/openlayer/models/governance/rule_delete_params.rbi +40 -0
  111. data/rbi/openlayer/models/governance/rule_list_params.rbi +486 -0
  112. data/rbi/openlayer/models/governance/rule_list_response.rbi +1294 -0
  113. data/rbi/openlayer/models/governance/rule_result_create_evidence_params.rbi +88 -0
  114. data/rbi/openlayer/models/governance/rule_result_create_evidence_response.rbi +108 -0
  115. data/rbi/openlayer/models/governance/rule_result_list_evidence_params.rbi +68 -0
  116. data/rbi/openlayer/models/governance/rule_result_list_evidence_response.rbi +151 -0
  117. data/rbi/openlayer/models/governance/rule_result_list_params.rbi +322 -0
  118. data/rbi/openlayer/models/governance/rule_result_list_response.rbi +567 -0
  119. data/rbi/openlayer/models/governance/rule_result_retrieve_params.rbi +43 -0
  120. data/rbi/openlayer/models/governance/rule_result_retrieve_response.rbi +524 -0
  121. data/rbi/openlayer/models/governance/rule_result_update_params.rbi +373 -0
  122. data/rbi/openlayer/models/governance/rule_result_update_response.rbi +524 -0
  123. data/rbi/openlayer/models/governance/rule_retrieve_params.rbi +40 -0
  124. data/rbi/openlayer/models/governance/rule_retrieve_response.rbi +1253 -0
  125. data/rbi/openlayer/models/governance/rule_stat_retrieve_params.rbi +68 -0
  126. data/rbi/openlayer/models/governance/rule_stat_retrieve_response.rbi +874 -0
  127. data/rbi/openlayer/models/governance/rule_tag_list_params.rbi +68 -0
  128. data/rbi/openlayer/models/governance/rule_tag_list_response.rbi +139 -0
  129. data/rbi/openlayer/models/governance/rule_update_params.rbi +106 -0
  130. data/rbi/openlayer/models/governance/rule_update_response.rbi +1253 -0
  131. data/rbi/openlayer/models/inference_pipeline_retrieve_response.rbi +37 -8
  132. data/rbi/openlayer/models/inference_pipeline_update_response.rbi +37 -8
  133. data/rbi/openlayer/models/project_create_params.rbi +34 -0
  134. data/rbi/openlayer/models/project_create_response.rbi +39 -8
  135. data/rbi/openlayer/models/project_list_response.rbi +39 -8
  136. data/rbi/openlayer/models/project_update_params.rbi +94 -0
  137. data/rbi/openlayer/models/project_update_response.rbi +432 -0
  138. data/rbi/openlayer/models/projects/inference_pipeline_create_params.rbi +37 -8
  139. data/rbi/openlayer/models/projects/inference_pipeline_create_response.rbi +37 -8
  140. data/rbi/openlayer/models/projects/inference_pipeline_list_response.rbi +37 -8
  141. data/rbi/openlayer/models/storage/presigned_url_retrieve_params.rbi +45 -0
  142. data/rbi/openlayer/models/storage/presigned_url_retrieve_response.rbi +32 -0
  143. data/rbi/openlayer/models.rbi +6 -0
  144. data/rbi/openlayer/resources/background_tasks.rbi +30 -0
  145. data/rbi/openlayer/resources/governance/frameworks/documents.rbi +65 -0
  146. data/rbi/openlayer/resources/governance/frameworks/sections.rbi +60 -0
  147. data/rbi/openlayer/resources/governance/frameworks/subsections.rbi +56 -0
  148. data/rbi/openlayer/resources/governance/frameworks.rbi +314 -0
  149. data/rbi/openlayer/resources/governance/rule_results.rbi +193 -0
  150. data/rbi/openlayer/resources/governance/rule_stats.rbi +38 -0
  151. data/rbi/openlayer/resources/governance/rule_tags.rbi +38 -0
  152. data/rbi/openlayer/resources/governance/rules.rbi +233 -0
  153. data/rbi/openlayer/resources/governance.rbi +27 -0
  154. data/rbi/openlayer/resources/projects.rbi +46 -0
  155. data/rbi/openlayer/resources/storage/presigned_url.rbi +23 -0
  156. data/sig/openlayer/client.rbs +4 -0
  157. data/sig/openlayer/models/background_task_retrieve_params.rbs +23 -0
  158. data/sig/openlayer/models/background_task_retrieve_response.rbs +55 -0
  159. data/sig/openlayer/models/governance/framework_create_params.rbs +124 -0
  160. data/sig/openlayer/models/governance/framework_create_response.rbs +293 -0
  161. data/sig/openlayer/models/governance/framework_export_params.rbs +30 -0
  162. data/sig/openlayer/models/governance/framework_export_response.rbs +21 -0
  163. data/sig/openlayer/models/governance/framework_list_params.rbs +145 -0
  164. data/sig/openlayer/models/governance/framework_list_project_rule_stats_params.rbs +87 -0
  165. data/sig/openlayer/models/governance/framework_list_project_rule_stats_response.rbs +232 -0
  166. data/sig/openlayer/models/governance/framework_list_projects_params.rbs +38 -0
  167. data/sig/openlayer/models/governance/framework_list_projects_response.rbs +248 -0
  168. data/sig/openlayer/models/governance/framework_list_response.rbs +314 -0
  169. data/sig/openlayer/models/governance/framework_list_rules_params.rbs +38 -0
  170. data/sig/openlayer/models/governance/framework_list_rules_response.rbs +547 -0
  171. data/sig/openlayer/models/governance/framework_retrieve_params.rbs +25 -0
  172. data/sig/openlayer/models/governance/framework_retrieve_response.rbs +293 -0
  173. data/sig/openlayer/models/governance/framework_update_params.rbs +175 -0
  174. data/sig/openlayer/models/governance/framework_update_response.rbs +293 -0
  175. data/sig/openlayer/models/governance/frameworks/document_list_params.rbs +40 -0
  176. data/sig/openlayer/models/governance/frameworks/document_list_response.rbs +435 -0
  177. data/sig/openlayer/models/governance/frameworks/document_retrieve_params.rbs +32 -0
  178. data/sig/openlayer/models/governance/frameworks/document_retrieve_response.rbs +418 -0
  179. data/sig/openlayer/models/governance/frameworks/section_list_rules_params.rbs +102 -0
  180. data/sig/openlayer/models/governance/frameworks/section_list_rules_response.rbs +549 -0
  181. data/sig/openlayer/models/governance/frameworks/subsection_list_rules_params.rbs +95 -0
  182. data/sig/openlayer/models/governance/frameworks/subsection_list_rules_response.rbs +549 -0
  183. data/sig/openlayer/models/governance/rule_create_params.rbs +120 -0
  184. data/sig/openlayer/models/governance/rule_create_response.rbs +530 -0
  185. data/sig/openlayer/models/governance/rule_delete_params.rbs +25 -0
  186. data/sig/openlayer/models/governance/rule_list_params.rbs +228 -0
  187. data/sig/openlayer/models/governance/rule_list_response.rbs +547 -0
  188. data/sig/openlayer/models/governance/rule_result_create_evidence_params.rbs +53 -0
  189. data/sig/openlayer/models/governance/rule_result_create_evidence_response.rbs +62 -0
  190. data/sig/openlayer/models/governance/rule_result_list_evidence_params.rbs +38 -0
  191. data/sig/openlayer/models/governance/rule_result_list_evidence_response.rbs +79 -0
  192. data/sig/openlayer/models/governance/rule_result_list_params.rbs +156 -0
  193. data/sig/openlayer/models/governance/rule_result_list_response.rbs +252 -0
  194. data/sig/openlayer/models/governance/rule_result_retrieve_params.rbs +26 -0
  195. data/sig/openlayer/models/governance/rule_result_retrieve_response.rbs +235 -0
  196. data/sig/openlayer/models/governance/rule_result_update_params.rbs +165 -0
  197. data/sig/openlayer/models/governance/rule_result_update_response.rbs +235 -0
  198. data/sig/openlayer/models/governance/rule_retrieve_params.rbs +25 -0
  199. data/sig/openlayer/models/governance/rule_retrieve_response.rbs +530 -0
  200. data/sig/openlayer/models/governance/rule_stat_retrieve_params.rbs +38 -0
  201. data/sig/openlayer/models/governance/rule_stat_retrieve_response.rbs +434 -0
  202. data/sig/openlayer/models/governance/rule_tag_list_params.rbs +38 -0
  203. data/sig/openlayer/models/governance/rule_tag_list_response.rbs +74 -0
  204. data/sig/openlayer/models/governance/rule_update_params.rbs +62 -0
  205. data/sig/openlayer/models/governance/rule_update_response.rbs +530 -0
  206. data/sig/openlayer/models/inference_pipeline_retrieve_response.rbs +24 -5
  207. data/sig/openlayer/models/inference_pipeline_update_response.rbs +24 -5
  208. data/sig/openlayer/models/project_create_params.rbs +21 -1
  209. data/sig/openlayer/models/project_create_response.rbs +24 -5
  210. data/sig/openlayer/models/project_list_response.rbs +24 -5
  211. data/sig/openlayer/models/project_update_params.rbs +58 -0
  212. data/sig/openlayer/models/project_update_response.rbs +229 -0
  213. data/sig/openlayer/models/projects/inference_pipeline_create_params.rbs +24 -5
  214. data/sig/openlayer/models/projects/inference_pipeline_create_response.rbs +24 -5
  215. data/sig/openlayer/models/projects/inference_pipeline_list_response.rbs +24 -5
  216. data/sig/openlayer/models/storage/presigned_url_retrieve_params.rbs +25 -0
  217. data/sig/openlayer/models/storage/presigned_url_retrieve_response.rbs +15 -0
  218. data/sig/openlayer/models.rbs +6 -0
  219. data/sig/openlayer/resources/background_tasks.rbs +12 -0
  220. data/sig/openlayer/resources/governance/frameworks/documents.rbs +24 -0
  221. data/sig/openlayer/resources/governance/frameworks/sections.rbs +23 -0
  222. data/sig/openlayer/resources/governance/frameworks/subsections.rbs +22 -0
  223. data/sig/openlayer/resources/governance/frameworks.rbs +88 -0
  224. data/sig/openlayer/resources/governance/rule_results.rbs +57 -0
  225. data/sig/openlayer/resources/governance/rule_stats.rbs +16 -0
  226. data/sig/openlayer/resources/governance/rule_tags.rbs +16 -0
  227. data/sig/openlayer/resources/governance/rules.rbs +68 -0
  228. data/sig/openlayer/resources/governance.rbs +17 -0
  229. data/sig/openlayer/resources/projects.rbs +15 -0
  230. data/sig/openlayer/resources/storage/presigned_url.rbs +5 -0
  231. metadata +191 -2
@@ -0,0 +1,561 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Openlayer
4
+ module Models
5
+ module Governance
6
+ module Frameworks
7
+ # @see Openlayer::Resources::Governance::Frameworks::Documents#retrieve
8
+ class DocumentRetrieveResponse < Openlayer::Internal::Type::BaseModel
9
+ # @!attribute title
10
+ # The document title.
11
+ #
12
+ # @return [String]
13
+ required :title, String
14
+
15
+ response_only do
16
+ # @!attribute id
17
+ # The document id.
18
+ #
19
+ # @return [String]
20
+ required :id, String
21
+
22
+ # @!attribute date_created
23
+ # The creation date.
24
+ #
25
+ # @return [Time]
26
+ required :date_created, Time, api_name: :dateCreated
27
+
28
+ # @!attribute date_updated
29
+ # The last update date.
30
+ #
31
+ # @return [Time]
32
+ required :date_updated, Time, api_name: :dateUpdated
33
+
34
+ # @!attribute framework_id
35
+ # The framework the document belongs to.
36
+ #
37
+ # @return [String]
38
+ required :framework_id, String, api_name: :frameworkId
39
+
40
+ # @!attribute sections
41
+ # The document's sections, in display order. Only returned when retrieving a
42
+ # single document.
43
+ #
44
+ # @return [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section>, nil]
45
+ optional :sections,
46
+ -> { Openlayer::Internal::Type::ArrayOf[Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section] }
47
+ end
48
+
49
+ # @!method initialize(id:, date_created:, date_updated:, framework_id:, title:, sections: nil)
50
+ # Some parameter documentations has been truncated, see
51
+ # {Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse} for more
52
+ # details.
53
+ #
54
+ # @param id [String] The document id.
55
+ #
56
+ # @param date_created [Time] The creation date.
57
+ #
58
+ # @param date_updated [Time] The last update date.
59
+ #
60
+ # @param framework_id [String] The framework the document belongs to.
61
+ #
62
+ # @param title [String] The document title.
63
+ #
64
+ # @param sections [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section>] The document's sections, in display order. Only returned when retrieving a singl
65
+
66
+ class Section < Openlayer::Internal::Type::BaseModel
67
+ # @!attribute number
68
+ # The section number as it appears in the source standard.
69
+ #
70
+ # @return [String]
71
+ required :number, String
72
+
73
+ # @!attribute sort_order
74
+ # The position of the section within the document.
75
+ #
76
+ # @return [Integer]
77
+ required :sort_order, Integer, api_name: :sortOrder
78
+
79
+ # @!attribute title
80
+ # The section title.
81
+ #
82
+ # @return [String]
83
+ required :title, String
84
+
85
+ # @!attribute text
86
+ # The section text.
87
+ #
88
+ # @return [String, nil]
89
+ optional :text, String, nil?: true
90
+
91
+ response_only do
92
+ # @!attribute id
93
+ # The section id.
94
+ #
95
+ # @return [String]
96
+ required :id, String
97
+
98
+ # @!attribute document_id
99
+ # The document the section belongs to.
100
+ #
101
+ # @return [String]
102
+ required :document_id, String, api_name: :documentId
103
+
104
+ # @!attribute rule_count
105
+ # How many rules are linked to this section, including its subsections. Use it to
106
+ # decide whether to fetch the section's rules.
107
+ #
108
+ # @return [Integer, nil]
109
+ optional :rule_count, Integer, api_name: :ruleCount
110
+
111
+ # @!attribute rules
112
+ # The rules linked directly to this section.
113
+ #
114
+ # @return [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule>, nil]
115
+ optional :rules,
116
+ -> { Openlayer::Internal::Type::ArrayOf[Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule] }
117
+
118
+ # @!attribute subsections
119
+ # The section's subsections, in display order.
120
+ #
121
+ # @return [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection>, nil]
122
+ optional :subsections,
123
+ -> { Openlayer::Internal::Type::ArrayOf[Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection] }
124
+ end
125
+
126
+ # @!method initialize(id:, document_id:, number:, sort_order:, title:, rule_count: nil, rules: nil, subsections: nil, text: nil)
127
+ # Some parameter documentations has been truncated, see
128
+ # {Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section}
129
+ # for more details.
130
+ #
131
+ # @param id [String] The section id.
132
+ #
133
+ # @param document_id [String] The document the section belongs to.
134
+ #
135
+ # @param number [String] The section number as it appears in the source standard.
136
+ #
137
+ # @param sort_order [Integer] The position of the section within the document.
138
+ #
139
+ # @param title [String] The section title.
140
+ #
141
+ # @param rule_count [Integer] How many rules are linked to this section, including its subsections. Use it to
142
+ #
143
+ # @param rules [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule>] The rules linked directly to this section.
144
+ #
145
+ # @param subsections [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection>] The section's subsections, in display order.
146
+ #
147
+ # @param text [String, nil] The section text.
148
+
149
+ class Rule < Openlayer::Internal::Type::BaseModel
150
+ # @!attribute name
151
+ # The rule name.
152
+ #
153
+ # @return [String]
154
+ required :name, String
155
+
156
+ # @!attribute scope
157
+ # Whether the rule is evaluated once for the whole workspace, or once per project
158
+ # the rule's frameworks apply to.
159
+ #
160
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Scope]
161
+ required :scope,
162
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Scope }
163
+
164
+ # @!attribute type
165
+ # `platform` rules are evaluated automatically from the state of your Openlayer
166
+ # workspace. `evidence` rules are satisfied by attaching evidence.
167
+ #
168
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Type]
169
+ required :type,
170
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Type }
171
+
172
+ # @!attribute automation_params
173
+ # Configuration for the platform check, when the automation takes parameters.
174
+ #
175
+ # @return [Hash{Symbol=>Object}, nil]
176
+ optional :automation_params,
177
+ Openlayer::Internal::Type::HashOf[Openlayer::Internal::Type::Unknown],
178
+ api_name: :automationParams,
179
+ nil?: true
180
+
181
+ # @!attribute automation_type
182
+ # Which workspace signal a platform rule checks, for example
183
+ # `monitoring_mode_enabled`, `test_setup`, or `project_owner_set`. `null` for
184
+ # evidence rules.
185
+ #
186
+ # @return [String, nil]
187
+ optional :automation_type, String, api_name: :automationType, nil?: true
188
+
189
+ # @!attribute deactivated
190
+ # Whether the rule is excluded from compliance calculations.
191
+ #
192
+ # @return [Boolean, nil]
193
+ optional :deactivated, Openlayer::Internal::Type::Boolean
194
+
195
+ # @!attribute description
196
+ # What the rule requires.
197
+ #
198
+ # @return [String, nil]
199
+ optional :description, String, nil?: true
200
+
201
+ # @!attribute evidence_type
202
+ # The kind of evidence that satisfies the rule. `null` for platform rules.
203
+ #
204
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::EvidenceType, nil]
205
+ optional :evidence_type,
206
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::EvidenceType },
207
+ api_name: :evidenceType,
208
+ nil?: true
209
+
210
+ # @!attribute renewal_cadence_days
211
+ # How often evidence must be renewed, in days. Once evidence is older than this,
212
+ # the rule result becomes `due_soon` and then `failing`.
213
+ #
214
+ # @return [Integer, nil]
215
+ optional :renewal_cadence_days, Integer, api_name: :renewalCadenceDays, nil?: true
216
+
217
+ response_only do
218
+ # @!attribute id
219
+ # The rule id.
220
+ #
221
+ # @return [String]
222
+ required :id, String
223
+
224
+ # @!attribute date_created
225
+ # The creation date.
226
+ #
227
+ # @return [Time, nil]
228
+ optional :date_created, Time, api_name: :dateCreated
229
+
230
+ # @!attribute date_updated
231
+ # The last update date.
232
+ #
233
+ # @return [Time, nil]
234
+ optional :date_updated, Time, api_name: :dateUpdated
235
+
236
+ # @!attribute immutable
237
+ # Whether the rule is managed by Openlayer and cannot be edited.
238
+ #
239
+ # @return [Boolean, nil]
240
+ optional :immutable, Openlayer::Internal::Type::Boolean
241
+ end
242
+
243
+ # @!method initialize(id:, name:, scope:, type:, automation_params: nil, automation_type: nil, date_created: nil, date_updated: nil, deactivated: nil, description: nil, evidence_type: nil, immutable: nil, renewal_cadence_days: nil)
244
+ # Some parameter documentations has been truncated, see
245
+ # {Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule}
246
+ # for more details.
247
+ #
248
+ # @param id [String] The rule id.
249
+ #
250
+ # @param name [String] The rule name.
251
+ #
252
+ # @param scope [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Scope] Whether the rule is evaluated once for the whole workspace, or once per project
253
+ #
254
+ # @param type [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::Type] `platform` rules are evaluated automatically from the state of your Openlayer wo
255
+ #
256
+ # @param automation_params [Hash{Symbol=>Object}, nil] Configuration for the platform check, when the automation takes parameters.
257
+ #
258
+ # @param automation_type [String, nil] Which workspace signal a platform rule checks, for example `monitoring_mode_enab
259
+ #
260
+ # @param date_created [Time] The creation date.
261
+ #
262
+ # @param date_updated [Time] The last update date.
263
+ #
264
+ # @param deactivated [Boolean] Whether the rule is excluded from compliance calculations.
265
+ #
266
+ # @param description [String, nil] What the rule requires.
267
+ #
268
+ # @param evidence_type [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule::EvidenceType, nil] The kind of evidence that satisfies the rule. `null` for platform rules.
269
+ #
270
+ # @param immutable [Boolean] Whether the rule is managed by Openlayer and cannot be edited.
271
+ #
272
+ # @param renewal_cadence_days [Integer, nil] How often evidence must be renewed, in days. Once evidence is older than this, t
273
+
274
+ # Whether the rule is evaluated once for the whole workspace, or once per project
275
+ # the rule's frameworks apply to.
276
+ #
277
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule#scope
278
+ module Scope
279
+ extend Openlayer::Internal::Type::Enum
280
+
281
+ PROJECT = :project
282
+ WORKSPACE = :workspace
283
+
284
+ # @!method self.values
285
+ # @return [Array<Symbol>]
286
+ end
287
+
288
+ # `platform` rules are evaluated automatically from the state of your Openlayer
289
+ # workspace. `evidence` rules are satisfied by attaching evidence.
290
+ #
291
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule#type
292
+ module Type
293
+ extend Openlayer::Internal::Type::Enum
294
+
295
+ PLATFORM = :platform
296
+ EVIDENCE = :evidence
297
+
298
+ # @!method self.values
299
+ # @return [Array<Symbol>]
300
+ end
301
+
302
+ # The kind of evidence that satisfies the rule. `null` for platform rules.
303
+ #
304
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Rule#evidence_type
305
+ module EvidenceType
306
+ extend Openlayer::Internal::Type::Enum
307
+
308
+ DOCUMENT = :document
309
+ TEXT = :text
310
+ URL = :url
311
+ CATEGORY_VALUE = :categoryValue
312
+
313
+ # @!method self.values
314
+ # @return [Array<Symbol>]
315
+ end
316
+ end
317
+
318
+ class Subsection < Openlayer::Internal::Type::BaseModel
319
+ # @!attribute number
320
+ # The subsection number as it appears in the source standard.
321
+ #
322
+ # @return [String]
323
+ required :number, String
324
+
325
+ # @!attribute sort_order
326
+ # The position of the subsection within its section.
327
+ #
328
+ # @return [Integer]
329
+ required :sort_order, Integer, api_name: :sortOrder
330
+
331
+ # @!attribute title
332
+ # The subsection title.
333
+ #
334
+ # @return [String]
335
+ required :title, String
336
+
337
+ # @!attribute text
338
+ # The subsection text. This is the requirement your rules are mapped against.
339
+ #
340
+ # @return [String, nil]
341
+ optional :text, String, nil?: true
342
+
343
+ response_only do
344
+ # @!attribute id
345
+ # The subsection id.
346
+ #
347
+ # @return [String]
348
+ required :id, String
349
+
350
+ # @!attribute section_id
351
+ # The section the subsection belongs to.
352
+ #
353
+ # @return [String]
354
+ required :section_id, String, api_name: :sectionId
355
+
356
+ # @!attribute rule_count
357
+ # How many rules are linked to this subsection.
358
+ #
359
+ # @return [Integer, nil]
360
+ optional :rule_count, Integer, api_name: :ruleCount
361
+
362
+ # @!attribute rules
363
+ # The rules linked to this subsection.
364
+ #
365
+ # @return [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule>, nil]
366
+ optional :rules,
367
+ -> { Openlayer::Internal::Type::ArrayOf[Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule] }
368
+ end
369
+
370
+ # @!method initialize(id:, number:, section_id:, sort_order:, title:, rule_count: nil, rules: nil, text: nil)
371
+ # @param id [String] The subsection id.
372
+ #
373
+ # @param number [String] The subsection number as it appears in the source standard.
374
+ #
375
+ # @param section_id [String] The section the subsection belongs to.
376
+ #
377
+ # @param sort_order [Integer] The position of the subsection within its section.
378
+ #
379
+ # @param title [String] The subsection title.
380
+ #
381
+ # @param rule_count [Integer] How many rules are linked to this subsection.
382
+ #
383
+ # @param rules [Array<Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule>] The rules linked to this subsection.
384
+ #
385
+ # @param text [String, nil] The subsection text. This is the requirement your rules are mapped against.
386
+
387
+ class Rule < Openlayer::Internal::Type::BaseModel
388
+ # @!attribute name
389
+ # The rule name.
390
+ #
391
+ # @return [String]
392
+ required :name, String
393
+
394
+ # @!attribute scope
395
+ # Whether the rule is evaluated once for the whole workspace, or once per project
396
+ # the rule's frameworks apply to.
397
+ #
398
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Scope]
399
+ required :scope,
400
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Scope }
401
+
402
+ # @!attribute type
403
+ # `platform` rules are evaluated automatically from the state of your Openlayer
404
+ # workspace. `evidence` rules are satisfied by attaching evidence.
405
+ #
406
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Type]
407
+ required :type,
408
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Type }
409
+
410
+ # @!attribute automation_params
411
+ # Configuration for the platform check, when the automation takes parameters.
412
+ #
413
+ # @return [Hash{Symbol=>Object}, nil]
414
+ optional :automation_params,
415
+ Openlayer::Internal::Type::HashOf[Openlayer::Internal::Type::Unknown],
416
+ api_name: :automationParams,
417
+ nil?: true
418
+
419
+ # @!attribute automation_type
420
+ # Which workspace signal a platform rule checks, for example
421
+ # `monitoring_mode_enabled`, `test_setup`, or `project_owner_set`. `null` for
422
+ # evidence rules.
423
+ #
424
+ # @return [String, nil]
425
+ optional :automation_type, String, api_name: :automationType, nil?: true
426
+
427
+ # @!attribute deactivated
428
+ # Whether the rule is excluded from compliance calculations.
429
+ #
430
+ # @return [Boolean, nil]
431
+ optional :deactivated, Openlayer::Internal::Type::Boolean
432
+
433
+ # @!attribute description
434
+ # What the rule requires.
435
+ #
436
+ # @return [String, nil]
437
+ optional :description, String, nil?: true
438
+
439
+ # @!attribute evidence_type
440
+ # The kind of evidence that satisfies the rule. `null` for platform rules.
441
+ #
442
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::EvidenceType, nil]
443
+ optional :evidence_type,
444
+ enum: -> { Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::EvidenceType },
445
+ api_name: :evidenceType,
446
+ nil?: true
447
+
448
+ # @!attribute renewal_cadence_days
449
+ # How often evidence must be renewed, in days. Once evidence is older than this,
450
+ # the rule result becomes `due_soon` and then `failing`.
451
+ #
452
+ # @return [Integer, nil]
453
+ optional :renewal_cadence_days, Integer, api_name: :renewalCadenceDays, nil?: true
454
+
455
+ response_only do
456
+ # @!attribute id
457
+ # The rule id.
458
+ #
459
+ # @return [String]
460
+ required :id, String
461
+
462
+ # @!attribute date_created
463
+ # The creation date.
464
+ #
465
+ # @return [Time, nil]
466
+ optional :date_created, Time, api_name: :dateCreated
467
+
468
+ # @!attribute date_updated
469
+ # The last update date.
470
+ #
471
+ # @return [Time, nil]
472
+ optional :date_updated, Time, api_name: :dateUpdated
473
+
474
+ # @!attribute immutable
475
+ # Whether the rule is managed by Openlayer and cannot be edited.
476
+ #
477
+ # @return [Boolean, nil]
478
+ optional :immutable, Openlayer::Internal::Type::Boolean
479
+ end
480
+
481
+ # @!method initialize(id:, name:, scope:, type:, automation_params: nil, automation_type: nil, date_created: nil, date_updated: nil, deactivated: nil, description: nil, evidence_type: nil, immutable: nil, renewal_cadence_days: nil)
482
+ # Some parameter documentations has been truncated, see
483
+ # {Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule}
484
+ # for more details.
485
+ #
486
+ # @param id [String] The rule id.
487
+ #
488
+ # @param name [String] The rule name.
489
+ #
490
+ # @param scope [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Scope] Whether the rule is evaluated once for the whole workspace, or once per project
491
+ #
492
+ # @param type [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::Type] `platform` rules are evaluated automatically from the state of your Openlayer wo
493
+ #
494
+ # @param automation_params [Hash{Symbol=>Object}, nil] Configuration for the platform check, when the automation takes parameters.
495
+ #
496
+ # @param automation_type [String, nil] Which workspace signal a platform rule checks, for example `monitoring_mode_enab
497
+ #
498
+ # @param date_created [Time] The creation date.
499
+ #
500
+ # @param date_updated [Time] The last update date.
501
+ #
502
+ # @param deactivated [Boolean] Whether the rule is excluded from compliance calculations.
503
+ #
504
+ # @param description [String, nil] What the rule requires.
505
+ #
506
+ # @param evidence_type [Symbol, Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule::EvidenceType, nil] The kind of evidence that satisfies the rule. `null` for platform rules.
507
+ #
508
+ # @param immutable [Boolean] Whether the rule is managed by Openlayer and cannot be edited.
509
+ #
510
+ # @param renewal_cadence_days [Integer, nil] How often evidence must be renewed, in days. Once evidence is older than this, t
511
+
512
+ # Whether the rule is evaluated once for the whole workspace, or once per project
513
+ # the rule's frameworks apply to.
514
+ #
515
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule#scope
516
+ module Scope
517
+ extend Openlayer::Internal::Type::Enum
518
+
519
+ PROJECT = :project
520
+ WORKSPACE = :workspace
521
+
522
+ # @!method self.values
523
+ # @return [Array<Symbol>]
524
+ end
525
+
526
+ # `platform` rules are evaluated automatically from the state of your Openlayer
527
+ # workspace. `evidence` rules are satisfied by attaching evidence.
528
+ #
529
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule#type
530
+ module Type
531
+ extend Openlayer::Internal::Type::Enum
532
+
533
+ PLATFORM = :platform
534
+ EVIDENCE = :evidence
535
+
536
+ # @!method self.values
537
+ # @return [Array<Symbol>]
538
+ end
539
+
540
+ # The kind of evidence that satisfies the rule. `null` for platform rules.
541
+ #
542
+ # @see Openlayer::Models::Governance::Frameworks::DocumentRetrieveResponse::Section::Subsection::Rule#evidence_type
543
+ module EvidenceType
544
+ extend Openlayer::Internal::Type::Enum
545
+
546
+ DOCUMENT = :document
547
+ TEXT = :text
548
+ URL = :url
549
+ CATEGORY_VALUE = :categoryValue
550
+
551
+ # @!method self.values
552
+ # @return [Array<Symbol>]
553
+ end
554
+ end
555
+ end
556
+ end
557
+ end
558
+ end
559
+ end
560
+ end
561
+ end
@@ -0,0 +1,96 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Openlayer
4
+ module Models
5
+ module Governance
6
+ module Frameworks
7
+ # @see Openlayer::Resources::Governance::Frameworks::Sections#list_rules
8
+ class SectionListRulesParams < Openlayer::Internal::Type::BaseModel
9
+ extend Openlayer::Internal::Type::RequestParameters::Converter
10
+ include Openlayer::Internal::Type::RequestParameters
11
+
12
+ # @!attribute framework_id
13
+ #
14
+ # @return [String]
15
+ required :framework_id, String
16
+
17
+ # @!attribute section_id
18
+ #
19
+ # @return [String]
20
+ required :section_id, String
21
+
22
+ # @!attribute include_results
23
+ # Whether to include each rule's results inline, in a `results` array.
24
+ #
25
+ # @return [Boolean, nil]
26
+ optional :include_results, Openlayer::Internal::Type::Boolean
27
+
28
+ # @!attribute include_subsection_rules
29
+ # Whether to also include the rules mapped to the section's subsections.
30
+ #
31
+ # @return [Boolean, nil]
32
+ optional :include_subsection_rules, Openlayer::Internal::Type::Boolean
33
+
34
+ # @!attribute page
35
+ # The page to return in a paginated query.
36
+ #
37
+ # @return [Integer, nil]
38
+ optional :page, Integer
39
+
40
+ # @!attribute per_page
41
+ # Maximum number of items to return per page.
42
+ #
43
+ # @return [Integer, nil]
44
+ optional :per_page, Integer
45
+
46
+ # @!attribute project_id
47
+ # Only include items that apply to this project.
48
+ #
49
+ # @return [String, nil]
50
+ optional :project_id, String
51
+
52
+ # @!attribute status
53
+ # Only include items whose rule result has this compliance status.
54
+ #
55
+ # @return [Symbol, Openlayer::Models::Governance::Frameworks::SectionListRulesParams::Status, nil]
56
+ optional :status, enum: -> { Openlayer::Governance::Frameworks::SectionListRulesParams::Status }
57
+
58
+ # @!method initialize(framework_id:, section_id:, include_results: nil, include_subsection_rules: nil, page: nil, per_page: nil, project_id: nil, status: nil, request_options: {})
59
+ # @param framework_id [String]
60
+ #
61
+ # @param section_id [String]
62
+ #
63
+ # @param include_results [Boolean] Whether to include each rule's results inline, in a `results` array.
64
+ #
65
+ # @param include_subsection_rules [Boolean] Whether to also include the rules mapped to the section's subsections.
66
+ #
67
+ # @param page [Integer] The page to return in a paginated query.
68
+ #
69
+ # @param per_page [Integer] Maximum number of items to return per page.
70
+ #
71
+ # @param project_id [String] Only include items that apply to this project.
72
+ #
73
+ # @param status [Symbol, Openlayer::Models::Governance::Frameworks::SectionListRulesParams::Status] Only include items whose rule result has this compliance status.
74
+ #
75
+ # @param request_options [Openlayer::RequestOptions, Hash{Symbol=>Object}]
76
+
77
+ # Only include items whose rule result has this compliance status.
78
+ module Status
79
+ extend Openlayer::Internal::Type::Enum
80
+
81
+ RUNNING = :running
82
+ PASSING = :passing
83
+ FAILING = :failing
84
+ SKIPPED = :skipped
85
+ ERROR = :error
86
+ PENDING = :pending
87
+ DUE_SOON = :due_soon
88
+
89
+ # @!method self.values
90
+ # @return [Array<Symbol>]
91
+ end
92
+ end
93
+ end
94
+ end
95
+ end
96
+ end