instana-client 1.0.0__py3-none-any.whl

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 (515) hide show
  1. instana_client/__init__.py +534 -0
  2. instana_client/api/__init__.py +58 -0
  3. instana_client/api/action_catalog_api.py +1380 -0
  4. instana_client/api/action_history_api.py +1793 -0
  5. instana_client/api/apdex_report_api.py +338 -0
  6. instana_client/api/apdex_settings_api.py +1353 -0
  7. instana_client/api/api_token_api.py +1370 -0
  8. instana_client/api/application_alert_configuration_api.py +2865 -0
  9. instana_client/api/application_analyze_api.py +2017 -0
  10. instana_client/api/application_catalog_api.py +885 -0
  11. instana_client/api/application_metrics_api.py +1211 -0
  12. instana_client/api/application_resources_api.py +1487 -0
  13. instana_client/api/application_settings_api.py +7261 -0
  14. instana_client/api/application_topology_api.py +354 -0
  15. instana_client/api/audit_log_api.py +635 -0
  16. instana_client/api/authentication_api.py +1008 -0
  17. instana_client/api/business_monitoring_api.py +2177 -0
  18. instana_client/api/custom_dashboards_api.py +1930 -0
  19. instana_client/api/event_settings_api.py +14613 -0
  20. instana_client/api/events_api.py +1654 -0
  21. instana_client/api/global_application_alert_configuration_api.py +2606 -0
  22. instana_client/api/groups_api.py +4078 -0
  23. instana_client/api/health_api.py +527 -0
  24. instana_client/api/host_agent_api.py +2120 -0
  25. instana_client/api/infrastructure_alert_configuration_api.py +2524 -0
  26. instana_client/api/infrastructure_analyze_api.py +1141 -0
  27. instana_client/api/infrastructure_catalog_api.py +1822 -0
  28. instana_client/api/infrastructure_metrics_api.py +331 -0
  29. instana_client/api/infrastructure_resources_api.py +1880 -0
  30. instana_client/api/infrastructure_topology_api.py +595 -0
  31. instana_client/api/log_alert_configuration_api.py +2524 -0
  32. instana_client/api/maintenance_configuration_api.py +2683 -0
  33. instana_client/api/mobile_app_analyze_api.py +613 -0
  34. instana_client/api/mobile_app_catalog_api.py +825 -0
  35. instana_client/api/mobile_app_configuration_api.py +2847 -0
  36. instana_client/api/mobile_app_metrics_api.py +892 -0
  37. instana_client/api/policies_api.py +1755 -0
  38. instana_client/api/releases_api.py +1408 -0
  39. instana_client/api/service_levels_alert_configuration_api.py +2577 -0
  40. instana_client/api/service_levels_objective_slo_configurations_api.py +1825 -0
  41. instana_client/api/service_levels_objective_slo_report_api.py +335 -0
  42. instana_client/api/session_settings_api.py +801 -0
  43. instana_client/api/sli_report_api.py +352 -0
  44. instana_client/api/sli_settings_api.py +2677 -0
  45. instana_client/api/synthetic_alert_configuration_api.py +2606 -0
  46. instana_client/api/synthetic_calls_api.py +789 -0
  47. instana_client/api/synthetic_catalog_api.py +543 -0
  48. instana_client/api/synthetic_metrics_api.py +322 -0
  49. instana_client/api/synthetic_settings_api.py +5144 -0
  50. instana_client/api/synthetic_test_playback_results_api.py +2142 -0
  51. instana_client/api/usage_api.py +1404 -0
  52. instana_client/api/user_api.py +2404 -0
  53. instana_client/api/website_analyze_api.py +619 -0
  54. instana_client/api/website_catalog_api.py +832 -0
  55. instana_client/api/website_configuration_api.py +3745 -0
  56. instana_client/api/website_metrics_api.py +889 -0
  57. instana_client/api_client.py +798 -0
  58. instana_client/api_response.py +21 -0
  59. instana_client/configuration.py +616 -0
  60. instana_client/exceptions.py +217 -0
  61. instana_client/models/__init__.py +464 -0
  62. instana_client/models/abstract_integration.py +155 -0
  63. instana_client/models/abstract_rule.py +124 -0
  64. instana_client/models/access_log_entry.py +105 -0
  65. instana_client/models/access_log_response.py +98 -0
  66. instana_client/models/access_rule.py +107 -0
  67. instana_client/models/action.py +135 -0
  68. instana_client/models/action_configuration.py +104 -0
  69. instana_client/models/action_instance.py +185 -0
  70. instana_client/models/action_instance_metadata_entry.py +90 -0
  71. instana_client/models/action_instance_parameter.py +94 -0
  72. instana_client/models/action_instance_request.py +108 -0
  73. instana_client/models/action_instance_request_parameters.py +92 -0
  74. instana_client/models/action_match.py +98 -0
  75. instana_client/models/action_search_space.py +94 -0
  76. instana_client/models/adaptive_baseline.py +92 -0
  77. instana_client/models/adaptive_threshold_rule.py +91 -0
  78. instana_client/models/adjusted_timeframe.py +91 -0
  79. instana_client/models/agent_configuration_update.py +93 -0
  80. instana_client/models/alerting_configuration.py +113 -0
  81. instana_client/models/alerting_configuration_with_last_updated.py +115 -0
  82. instana_client/models/alerting_time_window.py +109 -0
  83. instana_client/models/apdex_configuration.py +99 -0
  84. instana_client/models/apdex_configuration_input.py +95 -0
  85. instana_client/models/apdex_entity.py +119 -0
  86. instana_client/models/apdex_report.py +94 -0
  87. instana_client/models/api_create_group.py +104 -0
  88. instana_client/models/api_group.py +107 -0
  89. instana_client/models/api_member.py +90 -0
  90. instana_client/models/api_permission_set.py +178 -0
  91. instana_client/models/api_restricted_application_filter.py +108 -0
  92. instana_client/models/api_token.py +250 -0
  93. instana_client/models/app_data_metric_configuration.py +105 -0
  94. instana_client/models/application.py +104 -0
  95. instana_client/models/application_alert_config.py +203 -0
  96. instana_client/models/application_alert_config_with_metadata.py +213 -0
  97. instana_client/models/application_alert_rule.py +135 -0
  98. instana_client/models/application_apdex_entity.py +111 -0
  99. instana_client/models/application_config.py +131 -0
  100. instana_client/models/application_event_result.py +108 -0
  101. instana_client/models/application_item.py +94 -0
  102. instana_client/models/application_metric_result.py +109 -0
  103. instana_client/models/application_node.py +106 -0
  104. instana_client/models/application_result.py +102 -0
  105. instana_client/models/application_scope.py +89 -0
  106. instana_client/models/application_scope_with_metadata.py +90 -0
  107. instana_client/models/application_sli_entity.py +103 -0
  108. instana_client/models/application_slo_entity.py +112 -0
  109. instana_client/models/application_time_threshold.py +115 -0
  110. instana_client/models/audit_log_entry.py +102 -0
  111. instana_client/models/audit_log_ui_response.py +98 -0
  112. instana_client/models/author.py +100 -0
  113. instana_client/models/availability_blueprint_indicator.py +106 -0
  114. instana_client/models/availability_sli_entity.py +138 -0
  115. instana_client/models/available_metrics.py +96 -0
  116. instana_client/models/available_plugins.py +88 -0
  117. instana_client/models/backend_trace_reference.py +88 -0
  118. instana_client/models/binary_operator_dto.py +107 -0
  119. instana_client/models/browser_script_configuration.py +127 -0
  120. instana_client/models/built_in_event_specification.py +123 -0
  121. instana_client/models/built_in_event_specification_with_last_updated.py +125 -0
  122. instana_client/models/business_activity.py +132 -0
  123. instana_client/models/business_perspective_config.py +99 -0
  124. instana_client/models/call_groups_item.py +95 -0
  125. instana_client/models/call_groups_result.py +111 -0
  126. instana_client/models/call_relation.py +100 -0
  127. instana_client/models/change_summary.py +101 -0
  128. instana_client/models/cloudfoundry_physical_context.py +104 -0
  129. instana_client/models/condition.py +88 -0
  130. instana_client/models/config_version.py +101 -0
  131. instana_client/models/crash_mobile_app_alert_rule.py +90 -0
  132. instana_client/models/cursor_paginated_business_activity_item.py +96 -0
  133. instana_client/models/cursor_pagination.py +93 -0
  134. instana_client/models/cursor_pagination_infra_explore_cursor.py +90 -0
  135. instana_client/models/custom_blueprint_indicator.py +104 -0
  136. instana_client/models/custom_dashboard.py +111 -0
  137. instana_client/models/custom_dashboard_preview.py +103 -0
  138. instana_client/models/custom_email_subject_prefix.py +94 -0
  139. instana_client/models/custom_event_mobile_app_alert_rule.py +92 -0
  140. instana_client/models/custom_event_specification.py +133 -0
  141. instana_client/models/custom_event_specification_with_last_updated.py +143 -0
  142. instana_client/models/custom_event_website_alert_rule.py +92 -0
  143. instana_client/models/custom_payload_configuration.py +97 -0
  144. instana_client/models/custom_payload_field.py +112 -0
  145. instana_client/models/custom_payload_with_last_updated.py +99 -0
  146. instana_client/models/dashboard_api_token.py +90 -0
  147. instana_client/models/database_integration.py +90 -0
  148. instana_client/models/deprecated_tag_filter.py +111 -0
  149. instana_client/models/dns_action_configuration.py +134 -0
  150. instana_client/models/dns_action_filter_query_time.py +99 -0
  151. instana_client/models/dns_action_filter_target_value.py +106 -0
  152. instana_client/models/duration.py +98 -0
  153. instana_client/models/dynamic_field.py +95 -0
  154. instana_client/models/dynamic_field_value.py +90 -0
  155. instana_client/models/dynamic_parameter.py +94 -0
  156. instana_client/models/edit_user.py +88 -0
  157. instana_client/models/email_integration.py +98 -0
  158. instana_client/models/empty_configuration.py +92 -0
  159. instana_client/models/endpoint.py +131 -0
  160. instana_client/models/endpoint_config.py +112 -0
  161. instana_client/models/endpoint_event_result.py +112 -0
  162. instana_client/models/endpoint_item.py +94 -0
  163. instana_client/models/endpoint_metric_result.py +109 -0
  164. instana_client/models/endpoint_node.py +91 -0
  165. instana_client/models/endpoint_result.py +102 -0
  166. instana_client/models/endpoint_simple.py +102 -0
  167. instana_client/models/entity_count_rule.py +100 -0
  168. instana_client/models/entity_count_verification_rule.py +114 -0
  169. instana_client/models/entity_health_info.py +99 -0
  170. instana_client/models/entity_id.py +92 -0
  171. instana_client/models/entity_verification_rule.py +105 -0
  172. instana_client/models/error_budget_alert_rule.py +97 -0
  173. instana_client/models/errors_application_alert_rule.py +90 -0
  174. instana_client/models/event.py +127 -0
  175. instana_client/models/event_filtering_configuration.py +106 -0
  176. instana_client/models/event_result.py +145 -0
  177. instana_client/models/event_specification_info.py +114 -0
  178. instana_client/models/extended_service.py +123 -0
  179. instana_client/models/failure_synthetic_alert_rule.py +90 -0
  180. instana_client/models/fixed_http_path_segment_matching_rule.py +90 -0
  181. instana_client/models/fixed_time_window.py +93 -0
  182. instana_client/models/full_trace.py +97 -0
  183. instana_client/models/generic_infra_alert_rule.py +93 -0
  184. instana_client/models/geo_location_configuration.py +106 -0
  185. instana_client/models/geo_mapping_rule.py +120 -0
  186. instana_client/models/geo_subdivision.py +91 -0
  187. instana_client/models/get_activities.py +115 -0
  188. instana_client/models/get_application_metrics.py +112 -0
  189. instana_client/models/get_applications.py +150 -0
  190. instana_client/models/get_available_metrics_query.py +103 -0
  191. instana_client/models/get_available_plugins_query.py +98 -0
  192. instana_client/models/get_call_groups.py +141 -0
  193. instana_client/models/get_combined_metrics.py +103 -0
  194. instana_client/models/get_dynamic_parameter_values.py +100 -0
  195. instana_client/models/get_endpoints.py +150 -0
  196. instana_client/models/get_infrastructure_groups_query.py +127 -0
  197. instana_client/models/get_infrastructure_query.py +127 -0
  198. instana_client/models/get_metrics_result.py +128 -0
  199. instana_client/models/get_mobile_app_beacon_groups.py +146 -0
  200. instana_client/models/get_mobile_app_beacons.py +118 -0
  201. instana_client/models/get_mobile_app_metrics.py +122 -0
  202. instana_client/models/get_mobile_app_metrics_v2.py +118 -0
  203. instana_client/models/get_payload_keys_result.py +88 -0
  204. instana_client/models/get_services.py +147 -0
  205. instana_client/models/get_snapshots_query.py +95 -0
  206. instana_client/models/get_test_result.py +139 -0
  207. instana_client/models/get_test_result_base.py +120 -0
  208. instana_client/models/get_test_result_list.py +125 -0
  209. instana_client/models/get_test_summary_result.py +130 -0
  210. instana_client/models/get_trace_download_result_item.py +114 -0
  211. instana_client/models/get_trace_groups.py +141 -0
  212. instana_client/models/get_traces.py +125 -0
  213. instana_client/models/get_website_beacon_groups.py +146 -0
  214. instana_client/models/get_website_beacons.py +118 -0
  215. instana_client/models/get_website_metrics.py +122 -0
  216. instana_client/models/get_website_metrics_v2.py +118 -0
  217. instana_client/models/global_application_alert_config_with_metadata.py +205 -0
  218. instana_client/models/global_applications_alert_config.py +191 -0
  219. instana_client/models/google_chat_integration.py +92 -0
  220. instana_client/models/graph_edge.py +102 -0
  221. instana_client/models/graph_node.py +100 -0
  222. instana_client/models/group.py +100 -0
  223. instana_client/models/group_by_tag.py +90 -0
  224. instana_client/models/group_mapping.py +95 -0
  225. instana_client/models/health_state.py +100 -0
  226. instana_client/models/historic_baseline.py +105 -0
  227. instana_client/models/host_availability_rule.py +100 -0
  228. instana_client/models/http_action_configuration.py +127 -0
  229. instana_client/models/http_endpoint_config.py +103 -0
  230. instana_client/models/http_endpoint_rule.py +101 -0
  231. instana_client/models/http_path_segment_matching_rule.py +124 -0
  232. instana_client/models/http_script_configuration.py +113 -0
  233. instana_client/models/hyper_param.py +111 -0
  234. instana_client/models/identity_provider_patch.py +88 -0
  235. instana_client/models/infra_alert_config.py +166 -0
  236. instana_client/models/infra_alert_config_with_metadata.py +176 -0
  237. instana_client/models/infra_alert_rule.py +133 -0
  238. instana_client/models/infra_event_result.py +109 -0
  239. instana_client/models/infra_metric_configuration.py +115 -0
  240. instana_client/models/infra_time_threshold.py +109 -0
  241. instana_client/models/infrastructure_entities_result.py +109 -0
  242. instana_client/models/infrastructure_group.py +92 -0
  243. instana_client/models/infrastructure_groups_result.py +109 -0
  244. instana_client/models/infrastructure_item.py +104 -0
  245. instana_client/models/infrastructure_metric_result.py +96 -0
  246. instana_client/models/instana_version_info.py +92 -0
  247. instana_client/models/integration_overview.py +94 -0
  248. instana_client/models/invitation.py +94 -0
  249. instana_client/models/invitation_response.py +96 -0
  250. instana_client/models/invitation_result.py +100 -0
  251. instana_client/models/ip_masking_configuration.py +95 -0
  252. instana_client/models/js_stack_trace_line.py +99 -0
  253. instana_client/models/kubernetes_physical_context.py +107 -0
  254. instana_client/models/latency_blueprint_indicator.py +106 -0
  255. instana_client/models/location_status.py +96 -0
  256. instana_client/models/log_alert_config.py +154 -0
  257. instana_client/models/log_alert_config_with_metadata.py +164 -0
  258. instana_client/models/log_alert_rule.py +120 -0
  259. instana_client/models/log_count_alert_rule.py +90 -0
  260. instana_client/models/log_entry_actor.py +101 -0
  261. instana_client/models/log_event_result.py +107 -0
  262. instana_client/models/log_time_threshold.py +109 -0
  263. instana_client/models/logs_application_alert_rule.py +122 -0
  264. instana_client/models/maintenance_config.py +103 -0
  265. instana_client/models/maintenance_config_scheduling.py +118 -0
  266. instana_client/models/maintenance_config_v2.py +111 -0
  267. instana_client/models/maintenance_config_v2_with_state_and_occurrence.py +131 -0
  268. instana_client/models/maintenance_config_with_last_updated.py +105 -0
  269. instana_client/models/maintenance_window.py +93 -0
  270. instana_client/models/manual_alerting_channel_configuration.py +99 -0
  271. instana_client/models/manual_close_info.py +99 -0
  272. instana_client/models/manual_service_config.py +103 -0
  273. instana_client/models/match_all_http_path_segment_matching_rule.py +88 -0
  274. instana_client/models/match_expression_dto.py +111 -0
  275. instana_client/models/meta_data.py +96 -0
  276. instana_client/models/metric_api_result.py +94 -0
  277. instana_client/models/metric_config.py +99 -0
  278. instana_client/models/metric_configuration.py +103 -0
  279. instana_client/models/metric_description.py +116 -0
  280. instana_client/models/metric_instance.py +105 -0
  281. instana_client/models/metric_item.py +102 -0
  282. instana_client/models/metric_metadata.py +132 -0
  283. instana_client/models/metric_pattern.py +101 -0
  284. instana_client/models/metrics_result.py +96 -0
  285. instana_client/models/metrics_result_item.py +100 -0
  286. instana_client/models/metrics_test_result_item.py +102 -0
  287. instana_client/models/mobile_app.py +91 -0
  288. instana_client/models/mobile_app_alert_config.py +162 -0
  289. instana_client/models/mobile_app_alert_rule.py +129 -0
  290. instana_client/models/mobile_app_beacon_groups_item.py +95 -0
  291. instana_client/models/mobile_app_beacon_groups_result.py +111 -0
  292. instana_client/models/mobile_app_beacon_result.py +111 -0
  293. instana_client/models/mobile_app_beacon_tag_group.py +100 -0
  294. instana_client/models/mobile_app_beacons_item.py +94 -0
  295. instana_client/models/mobile_app_event_result.py +108 -0
  296. instana_client/models/mobile_app_metric_result.py +88 -0
  297. instana_client/models/mobile_app_monitoring_beacon.py +259 -0
  298. instana_client/models/mobile_app_monitoring_metric_description.py +123 -0
  299. instana_client/models/mobile_app_monitoring_metrics_configuration.py +105 -0
  300. instana_client/models/mobile_app_time_threshold.py +115 -0
  301. instana_client/models/model_field.py +96 -0
  302. instana_client/models/monitoring_state.py +92 -0
  303. instana_client/models/multiple_scripts_configuration.py +90 -0
  304. instana_client/models/new_application_config.py +129 -0
  305. instana_client/models/new_business_perspective_config.py +97 -0
  306. instana_client/models/new_manual_service_config.py +100 -0
  307. instana_client/models/occurrence.py +91 -0
  308. instana_client/models/office365_integration.py +92 -0
  309. instana_client/models/one_time_maintenance_window.py +94 -0
  310. instana_client/models/opsgenie_integration.py +105 -0
  311. instana_client/models/order.py +99 -0
  312. instana_client/models/pagerduty_integration.py +92 -0
  313. instana_client/models/paginated_result.py +95 -0
  314. instana_client/models/pagination.py +91 -0
  315. instana_client/models/parameter.py +102 -0
  316. instana_client/models/parameter_value.py +90 -0
  317. instana_client/models/path_parameter_http_path_segment_matching_rule.py +90 -0
  318. instana_client/models/physical_context.py +119 -0
  319. instana_client/models/plugin_result.py +90 -0
  320. instana_client/models/policy.py +113 -0
  321. instana_client/models/policy_runnable.py +103 -0
  322. instana_client/models/post_snapshots_result.py +98 -0
  323. instana_client/models/problem.py +95 -0
  324. instana_client/models/prometheus_webhook_integration.py +94 -0
  325. instana_client/models/recurrent_maintenance_window.py +98 -0
  326. instana_client/models/release.py +111 -0
  327. instana_client/models/release_scope.py +94 -0
  328. instana_client/models/release_with_metadata.py +125 -0
  329. instana_client/models/rolling_time_window.py +90 -0
  330. instana_client/models/rule_input.py +98 -0
  331. instana_client/models/rule_with_threshold_application_alert_rule.py +116 -0
  332. instana_client/models/rule_with_threshold_infra_alert_rule.py +116 -0
  333. instana_client/models/rule_with_threshold_log_alert_rule.py +116 -0
  334. instana_client/models/rule_with_threshold_mobile_app_alert_rule.py +116 -0
  335. instana_client/models/rule_with_threshold_website_alert_rule.py +116 -0
  336. instana_client/models/run_configuration.py +96 -0
  337. instana_client/models/salesforce_integration.py +98 -0
  338. instana_client/models/scope_binding.py +91 -0
  339. instana_client/models/search_field_result.py +116 -0
  340. instana_client/models/service.py +116 -0
  341. instana_client/models/service_config.py +107 -0
  342. instana_client/models/service_event_result.py +110 -0
  343. instana_client/models/service_item.py +94 -0
  344. instana_client/models/service_level_indicator.py +172 -0
  345. instana_client/models/service_level_objective_alert_rule.py +100 -0
  346. instana_client/models/service_level_objective_configuration.py +118 -0
  347. instana_client/models/service_levels_alert_config.py +133 -0
  348. instana_client/models/service_levels_alert_rule.py +111 -0
  349. instana_client/models/service_levels_burn_rate_time_windows.py +97 -0
  350. instana_client/models/service_levels_time_threshold.py +90 -0
  351. instana_client/models/service_levelse_alert_config_with_metadata.py +143 -0
  352. instana_client/models/service_map.py +106 -0
  353. instana_client/models/service_map_connection.py +97 -0
  354. instana_client/models/service_matching_rule.py +90 -0
  355. instana_client/models/service_metric_result.py +109 -0
  356. instana_client/models/service_node.py +106 -0
  357. instana_client/models/service_now_enhanced_integration.py +116 -0
  358. instana_client/models/service_now_integration.py +98 -0
  359. instana_client/models/service_result.py +102 -0
  360. instana_client/models/service_scope.py +95 -0
  361. instana_client/models/service_scope_with_metadata.py +96 -0
  362. instana_client/models/service_scoped_to.py +97 -0
  363. instana_client/models/service_scoped_to_with_metadata.py +97 -0
  364. instana_client/models/service_simple.py +90 -0
  365. instana_client/models/session_settings.py +91 -0
  366. instana_client/models/slack_integration.py +98 -0
  367. instana_client/models/sli_configuration.py +105 -0
  368. instana_client/models/sli_configuration_with_last_updated.py +107 -0
  369. instana_client/models/sli_entity.py +117 -0
  370. instana_client/models/sli_report.py +100 -0
  371. instana_client/models/slo_entity.py +119 -0
  372. instana_client/models/slo_report.py +112 -0
  373. instana_client/models/slowness_application_alert_rule.py +90 -0
  374. instana_client/models/slowness_website_alert_rule.py +90 -0
  375. instana_client/models/snapshot_item.py +102 -0
  376. instana_client/models/snapshot_preview.py +97 -0
  377. instana_client/models/snapshot_result.py +96 -0
  378. instana_client/models/software_user.py +94 -0
  379. instana_client/models/software_version.py +124 -0
  380. instana_client/models/source_map_file_blob.py +92 -0
  381. instana_client/models/source_map_file_meta.py +115 -0
  382. instana_client/models/source_map_upload_config.py +106 -0
  383. instana_client/models/span.py +156 -0
  384. instana_client/models/span_excerpt.py +132 -0
  385. instana_client/models/span_relation.py +114 -0
  386. instana_client/models/specific_js_errors_website_alert_rule.py +101 -0
  387. instana_client/models/splunk_integration.py +94 -0
  388. instana_client/models/ssl_certificate_configuration.py +99 -0
  389. instana_client/models/stack_trace_item.py +92 -0
  390. instana_client/models/stack_trace_line.py +99 -0
  391. instana_client/models/static_baseline_threshold_rule.py +102 -0
  392. instana_client/models/static_string_field.py +91 -0
  393. instana_client/models/static_threshold.py +94 -0
  394. instana_client/models/static_threshold_rule.py +91 -0
  395. instana_client/models/status_code_application_alert_rule.py +95 -0
  396. instana_client/models/status_code_mobile_app_alert_rule.py +101 -0
  397. instana_client/models/status_code_website_alert_rule.py +101 -0
  398. instana_client/models/synthetic_alert_config.py +127 -0
  399. instana_client/models/synthetic_alert_config_with_metadata.py +137 -0
  400. instana_client/models/synthetic_alert_rule.py +120 -0
  401. instana_client/models/synthetic_call_config.py +99 -0
  402. instana_client/models/synthetic_call_rule.py +99 -0
  403. instana_client/models/synthetic_call_with_defaults_config.py +108 -0
  404. instana_client/models/synthetic_credential.py +111 -0
  405. instana_client/models/synthetic_datacenter.py +117 -0
  406. instana_client/models/synthetic_datacenter_configuration.py +88 -0
  407. instana_client/models/synthetic_geo_point.py +94 -0
  408. instana_client/models/synthetic_location.py +129 -0
  409. instana_client/models/synthetic_location_configuration.py +102 -0
  410. instana_client/models/synthetic_metric_configuration.py +99 -0
  411. instana_client/models/synthetic_metric_tag_group.py +100 -0
  412. instana_client/models/synthetic_playback_capabilities.py +98 -0
  413. instana_client/models/synthetic_slo_entity.py +95 -0
  414. instana_client/models/synthetic_test.py +149 -0
  415. instana_client/models/synthetic_time_threshold.py +110 -0
  416. instana_client/models/synthetic_type_configuration.py +141 -0
  417. instana_client/models/synthetics_event_result.py +110 -0
  418. instana_client/models/system_rule.py +91 -0
  419. instana_client/models/system_rule_label.py +90 -0
  420. instana_client/models/tag.py +123 -0
  421. instana_client/models/tag_catalog.py +106 -0
  422. instana_client/models/tag_filter.py +113 -0
  423. instana_client/models/tag_filter_expression.py +106 -0
  424. instana_client/models/tag_filter_expression_element.py +111 -0
  425. instana_client/models/tag_matcher_dto.py +110 -0
  426. instana_client/models/tag_tree_level.py +109 -0
  427. instana_client/models/tag_tree_node.py +113 -0
  428. instana_client/models/tag_tree_tag.py +103 -0
  429. instana_client/models/test_common_properties.py +136 -0
  430. instana_client/models/test_result.py +105 -0
  431. instana_client/models/test_result_common_properties.py +108 -0
  432. instana_client/models/test_result_detail_data.py +112 -0
  433. instana_client/models/test_result_item.py +106 -0
  434. instana_client/models/test_result_list_item.py +94 -0
  435. instana_client/models/test_result_list_result.py +103 -0
  436. instana_client/models/test_result_metadata.py +94 -0
  437. instana_client/models/test_result_subtransaction.py +90 -0
  438. instana_client/models/threshold.py +122 -0
  439. instana_client/models/threshold_config_rule.py +114 -0
  440. instana_client/models/threshold_rule.py +125 -0
  441. instana_client/models/throughput_application_alert_rule.py +90 -0
  442. instana_client/models/throughput_mobile_app_alert_rule.py +90 -0
  443. instana_client/models/throughput_website_alert_rule.py +90 -0
  444. instana_client/models/time_frame.py +91 -0
  445. instana_client/models/time_window.py +120 -0
  446. instana_client/models/topology.py +106 -0
  447. instana_client/models/trace.py +109 -0
  448. instana_client/models/trace_activity_tree_node_details.py +139 -0
  449. instana_client/models/trace_download_result.py +111 -0
  450. instana_client/models/trace_groups_item.py +95 -0
  451. instana_client/models/trace_groups_result.py +111 -0
  452. instana_client/models/trace_impact_application_time_threshold.py +92 -0
  453. instana_client/models/trace_item.py +94 -0
  454. instana_client/models/trace_result.py +111 -0
  455. instana_client/models/traffic_blueprint_indicator.py +104 -0
  456. instana_client/models/trigger.py +99 -0
  457. instana_client/models/type_configuration.py +107 -0
  458. instana_client/models/unsupported_http_path_segment_matching_rule.py +90 -0
  459. instana_client/models/updated_business_perspective_config.py +97 -0
  460. instana_client/models/usage_result.py +98 -0
  461. instana_client/models/usage_result_items.py +90 -0
  462. instana_client/models/user_basic_result.py +92 -0
  463. instana_client/models/user_impact_mobile_app_time_threshold.py +103 -0
  464. instana_client/models/user_impact_website_time_threshold.py +103 -0
  465. instana_client/models/user_result.py +98 -0
  466. instana_client/models/users_result.py +106 -0
  467. instana_client/models/validated_alerting_channel_input_info.py +123 -0
  468. instana_client/models/validated_alerting_configuration.py +121 -0
  469. instana_client/models/validated_maintenance_config_v2_with_state_and_occurrence.py +135 -0
  470. instana_client/models/validated_maintenance_config_with_status.py +116 -0
  471. instana_client/models/victor_ops_integration.py +94 -0
  472. instana_client/models/violations_in_period_application_time_threshold.py +92 -0
  473. instana_client/models/violations_in_period_mobile_app_time_threshold.py +92 -0
  474. instana_client/models/violations_in_period_website_time_threshold.py +92 -0
  475. instana_client/models/violations_in_sequence_application_time_threshold.py +89 -0
  476. instana_client/models/violations_in_sequence_infra_time_threshold.py +89 -0
  477. instana_client/models/violations_in_sequence_log_time_threshold.py +89 -0
  478. instana_client/models/violations_in_sequence_mobile_app_time_threshold.py +89 -0
  479. instana_client/models/violations_in_sequence_synthetic_time_threshold.py +89 -0
  480. instana_client/models/violations_in_sequence_website_time_threshold.py +89 -0
  481. instana_client/models/watson_ai_ops_webhook_integration.py +94 -0
  482. instana_client/models/webex_teams_webhook_integration.py +92 -0
  483. instana_client/models/webhook_integration.py +94 -0
  484. instana_client/models/webpage_action_configuration.py +109 -0
  485. instana_client/models/webpage_script_configuration.py +109 -0
  486. instana_client/models/website.py +92 -0
  487. instana_client/models/website_alert_config.py +166 -0
  488. instana_client/models/website_alert_config_with_metadata.py +176 -0
  489. instana_client/models/website_alert_rule.py +132 -0
  490. instana_client/models/website_apdex_entity.py +107 -0
  491. instana_client/models/website_beacon_groups_item.py +95 -0
  492. instana_client/models/website_beacon_groups_result.py +111 -0
  493. instana_client/models/website_beacon_result.py +111 -0
  494. instana_client/models/website_beacon_tag_group.py +100 -0
  495. instana_client/models/website_beacons_item.py +94 -0
  496. instana_client/models/website_event_based_sli_entity.py +110 -0
  497. instana_client/models/website_event_result.py +108 -0
  498. instana_client/models/website_metric_result.py +88 -0
  499. instana_client/models/website_monitoring_beacon.py +301 -0
  500. instana_client/models/website_monitoring_metric_description.py +123 -0
  501. instana_client/models/website_monitoring_metrics_configuration.py +99 -0
  502. instana_client/models/website_slo_entity.py +104 -0
  503. instana_client/models/website_time_based_sli_entity.py +105 -0
  504. instana_client/models/website_time_threshold.py +115 -0
  505. instana_client/models/widget.py +103 -0
  506. instana_client/models/with_metadata.py +172 -0
  507. instana_client/models/with_resolved_name.py +102 -0
  508. instana_client/models/z_chat_ops_integration.py +97 -0
  509. instana_client/py.typed +0 -0
  510. instana_client/rest.py +258 -0
  511. instana_client-1.0.0.dist-info/METADATA +25 -0
  512. instana_client-1.0.0.dist-info/RECORD +515 -0
  513. instana_client-1.0.0.dist-info/WHEEL +5 -0
  514. instana_client-1.0.0.dist-info/licenses/LICENSE +202 -0
  515. instana_client-1.0.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,4078 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Instana REST API documentation
5
+
6
+ Searching for answers and best pratices? Check our [IBM Instana Community](https://community.ibm.com/community/user/aiops/communities/community-home?CommunityKey=58f324a3-3104-41be-9510-5b7c413cc48f). ## Overview The Instana REST API provides programmatic access to the Instana platform. It can be used to retrieve data available through the Instana UI Dashboard -- metrics, events, traces, etc -- and also to automate configuration tasks such as user management. ### Navigating the API documentation The API endpoints are grouped by product area and functionality. This generally maps to how our UI Dashboard is organized, hopefully making it easier to locate which endpoints you'd use to fetch the data you see visualized in our UI. The [UI sections](https://www.ibm.com/docs/en/instana-observability/current?topic=working-user-interface#navigation-menu) include: - Websites & Mobile Apps - Applications - Infrastructure - Synthetic Monitoring - Events - Automation - Service Levels - Settings - etc ### Rate Limiting A rate limit is applied to API usage. Up to 5,000 calls per hour can be made. How many remaining calls can be made and when this call limit resets, can inspected via three headers that are part of the responses of the API server. - **X-RateLimit-Limit:** Shows the maximum number of calls that may be executed per hour. - **X-RateLimit-Remaining:** How many calls may still be executed within the current hour. - **X-RateLimit-Reset:** Time when the remaining calls will be reset to the limit. For compatibility reasons with other rate limited APIs, this date is not the date in milliseconds, but instead in seconds since 1970-01-01T00:00:00+00:00. ### Further Reading We provide additional documentation for our REST API in our [product documentation](https://www.ibm.com/docs/en/instana-observability/current?topic=apis-web-rest-api). Here you'll also find some common queries for retrieving data and configuring Instana. ## Getting Started with the REST API ### API base URL The base URL for an specific instance of Instana can be determined using the tenant and unit information. - `base`: This is the base URL of a tenant unit, e.g. `https://test-example.instana.io`. This is the same URL that is used to access the Instana user interface. - `apiToken`: Requests against the Instana API require valid API tokens. An initial API token can be generated via the Instana user interface. Any additional API tokens can be generated via the API itself. ### Curl Example Here is an Example to use the REST API with Curl. First lets get all the available metrics with possible aggregations with a GET call. ```bash curl --request GET \\ --url https://test-instana.instana.io/api/application-monitoring/catalog/metrics \\ --header 'authorization: apiToken xxxxxxxxxxxxxxxx' ``` Next we can get every call grouped by the endpoint name that has an error count greater then zero. As a metric we could get the mean error rate for example. ```bash curl --request POST \\ --url https://test-instana.instana.io/api/application-monitoring/analyze/call-groups \\ --header 'authorization: apiToken xxxxxxxxxxxxxxxx' \\ --header 'content-type: application/json' \\ --data '{ \"group\":{ \"groupbyTag\":\"endpoint.name\" }, \"tagFilters\":[ { \"name\":\"call.error.count\", \"value\":\"0\", \"operator\":\"GREATER_THAN\" } ], \"metrics\":[ { \"metric\":\"errors\", \"aggregation\":\"MEAN\" } ] }' ``` ### Generating REST API clients The API is specified using the [OpenAPI v3](https://github.com/OAI/OpenAPI-Specification) (previously known as Swagger) format. You can download the current specification at our [GitHub API documentation](https://instana.github.io/openapi/openapi.yaml). OpenAPI tries to solve the issue of ever-evolving APIs and clients lagging behind. Please make sure that you always use the latest version of the generator, as a number of improvements are regularly made. To generate a client library for your language, you can use the [OpenAPI client generators](https://github.com/OpenAPITools/openapi-generator). #### Go For example, to generate a client library for Go to interact with our backend, you can use the following script; mind replacing the values of the `UNIT_NAME` and `TENANT_NAME` environment variables using those for your tenant unit: ```bash #!/bin/bash ### This script assumes you have the `java` and `wget` commands on the path export UNIT_NAME='myunit' # for example: prod export TENANT_NAME='mytenant' # for example: awesomecompany //Download the generator to your current working directory: wget https://repo1.maven.org/maven2/org/openapitools/openapi-generator-cli/4.3.1/openapi-generator-cli-4.3.1.jar -O openapi-generator-cli.jar --server-variables \"tenant=${TENANT_NAME},unit=${UNIT_NAME}\" //generate a client library that you can vendor into your repository java -jar openapi-generator-cli.jar generate -i https://instana.github.io/openapi/openapi.yaml -g go \\ -o pkg/instana/openapi \\ --skip-validate-spec //(optional) format the Go code according to the Go code standard gofmt -s -w pkg/instana/openapi ``` The generated clients contain comprehensive READMEs, and you can start right away using the client from the example above: ```go import instana \"./pkg/instana/openapi\" // readTags will read all available application monitoring tags along with their type and category func readTags() { configuration := instana.NewConfiguration() configuration.Host = \"tenant-unit.instana.io\" configuration.BasePath = \"https://tenant-unit.instana.io\" client := instana.NewAPIClient(configuration) auth := context.WithValue(context.Background(), instana.ContextAPIKey, instana.APIKey{ Key: apiKey, Prefix: \"apiToken\", }) tags, _, err := client.ApplicationCatalogApi.GetApplicationTagCatalog(auth) if err != nil { fmt.Fatalf(\"Error calling the API, aborting.\") } for _, tag := range tags { fmt.Printf(\"%s (%s): %s\\n\", tag.Category, tag.Type, tag.Name) } } ``` #### Java Follow the instructions provided in the official documentation from [OpenAPI Tools](https://github.com/OpenAPITools) to download the [openapi-generator-cli.jar](https://github.com/OpenAPITools/openapi-generator?tab=readme-ov-file#13---download-jar). Depending on your environment, use one of the following java http client implementations which will create a valid client for our OpenAPI specification: ``` //Nativ Java HTTP Client java -jar openapi-generator-cli.jar generate -i https://instana.github.io/openapi/openapi.yaml -g java -o pkg/instana/openapi --skip-validate-spec -p dateLibrary=java8 --library native //Spring WebClient java -jar openapi-generator-cli.jar generate -i https://instana.github.io/openapi/openapi.yaml -g java -o pkg/instana/openapi --skip-validate-spec -p dateLibrary=java8,hideGenerationTimestamp=true --library webclient //Spring RestTemplate java -jar openapi-generator-cli.jar generate -i https://instana.github.io/openapi/openapi.yaml -g java -o pkg/instana/openapi --skip-validate-spec -p dateLibrary=java8,hideGenerationTimestamp=true --library resttemplate ```
7
+
8
+ The version of the OpenAPI document: 1.291.1002
9
+ Contact: support@instana.com
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+ import warnings
16
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
17
+ from typing import Any, Dict, List, Optional, Tuple, Union
18
+ from typing_extensions import Annotated
19
+
20
+ from pydantic import Field, StrictStr
21
+ from typing import List
22
+ from typing_extensions import Annotated
23
+ from instana_client.models.api_create_group import ApiCreateGroup
24
+ from instana_client.models.api_group import ApiGroup
25
+ from instana_client.models.group_mapping import GroupMapping
26
+ from instana_client.models.identity_provider_patch import IdentityProviderPatch
27
+
28
+ from instana_client.api_client import ApiClient, RequestSerialized
29
+ from instana_client.api_response import ApiResponse
30
+ from instana_client.rest import RESTResponseType
31
+
32
+
33
+ class GroupsApi:
34
+ """NOTE: This class is auto generated by OpenAPI Generator
35
+ Ref: https://openapi-generator.tech
36
+
37
+ Do not edit the class manually.
38
+ """
39
+
40
+ def __init__(self, api_client=None) -> None:
41
+ if api_client is None:
42
+ api_client = ApiClient.get_default()
43
+ self.api_client = api_client
44
+
45
+
46
+ @validate_call
47
+ def add_permissions_on_group(
48
+ self,
49
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add permissions")],
50
+ request_body: List[StrictStr],
51
+ _request_timeout: Union[
52
+ None,
53
+ Annotated[StrictFloat, Field(gt=0)],
54
+ Tuple[
55
+ Annotated[StrictFloat, Field(gt=0)],
56
+ Annotated[StrictFloat, Field(gt=0)]
57
+ ]
58
+ ] = None,
59
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
60
+ _content_type: Optional[StrictStr] = None,
61
+ _headers: Optional[Dict[StrictStr, Any]] = None,
62
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
63
+ ) -> ApiGroup:
64
+ """Add permissions to group
65
+
66
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
67
+
68
+ :param group_id: Id of the group to add permissions (required)
69
+ :type group_id: str
70
+ :param request_body: (required)
71
+ :type request_body: List[str]
72
+ :param _request_timeout: timeout setting for this request. If one
73
+ number provided, it will be total request
74
+ timeout. It can also be a pair (tuple) of
75
+ (connection, read) timeouts.
76
+ :type _request_timeout: int, tuple(int, int), optional
77
+ :param _request_auth: set to override the auth_settings for an a single
78
+ request; this effectively ignores the
79
+ authentication in the spec for a single request.
80
+ :type _request_auth: dict, optional
81
+ :param _content_type: force content-type for the request.
82
+ :type _content_type: str, Optional
83
+ :param _headers: set to override the headers for a single
84
+ request; this effectively ignores the headers
85
+ in the spec for a single request.
86
+ :type _headers: dict, optional
87
+ :param _host_index: set to override the host_index for a single
88
+ request; this effectively ignores the host_index
89
+ in the spec for a single request.
90
+ :type _host_index: int, optional
91
+ :return: Returns the result object.
92
+ """ # noqa: E501
93
+
94
+ _param = self._add_permissions_on_group_serialize(
95
+ group_id=group_id,
96
+ request_body=request_body,
97
+ _request_auth=_request_auth,
98
+ _content_type=_content_type,
99
+ _headers=_headers,
100
+ _host_index=_host_index
101
+ )
102
+
103
+ _response_types_map: Dict[str, Optional[str]] = {
104
+ '200': "ApiGroup",
105
+ }
106
+ response_data = self.api_client.call_api(
107
+ *_param,
108
+ _request_timeout=_request_timeout
109
+ )
110
+ response_data.read()
111
+ return self.api_client.response_deserialize(
112
+ response_data=response_data,
113
+ response_types_map=_response_types_map,
114
+ ).data
115
+
116
+
117
+ @validate_call
118
+ def add_permissions_on_group_with_http_info(
119
+ self,
120
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add permissions")],
121
+ request_body: List[StrictStr],
122
+ _request_timeout: Union[
123
+ None,
124
+ Annotated[StrictFloat, Field(gt=0)],
125
+ Tuple[
126
+ Annotated[StrictFloat, Field(gt=0)],
127
+ Annotated[StrictFloat, Field(gt=0)]
128
+ ]
129
+ ] = None,
130
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
131
+ _content_type: Optional[StrictStr] = None,
132
+ _headers: Optional[Dict[StrictStr, Any]] = None,
133
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
134
+ ) -> ApiResponse[ApiGroup]:
135
+ """Add permissions to group
136
+
137
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
138
+
139
+ :param group_id: Id of the group to add permissions (required)
140
+ :type group_id: str
141
+ :param request_body: (required)
142
+ :type request_body: List[str]
143
+ :param _request_timeout: timeout setting for this request. If one
144
+ number provided, it will be total request
145
+ timeout. It can also be a pair (tuple) of
146
+ (connection, read) timeouts.
147
+ :type _request_timeout: int, tuple(int, int), optional
148
+ :param _request_auth: set to override the auth_settings for an a single
149
+ request; this effectively ignores the
150
+ authentication in the spec for a single request.
151
+ :type _request_auth: dict, optional
152
+ :param _content_type: force content-type for the request.
153
+ :type _content_type: str, Optional
154
+ :param _headers: set to override the headers for a single
155
+ request; this effectively ignores the headers
156
+ in the spec for a single request.
157
+ :type _headers: dict, optional
158
+ :param _host_index: set to override the host_index for a single
159
+ request; this effectively ignores the host_index
160
+ in the spec for a single request.
161
+ :type _host_index: int, optional
162
+ :return: Returns the result object.
163
+ """ # noqa: E501
164
+
165
+ _param = self._add_permissions_on_group_serialize(
166
+ group_id=group_id,
167
+ request_body=request_body,
168
+ _request_auth=_request_auth,
169
+ _content_type=_content_type,
170
+ _headers=_headers,
171
+ _host_index=_host_index
172
+ )
173
+
174
+ _response_types_map: Dict[str, Optional[str]] = {
175
+ '200': "ApiGroup",
176
+ }
177
+ response_data = self.api_client.call_api(
178
+ *_param,
179
+ _request_timeout=_request_timeout
180
+ )
181
+ response_data.read()
182
+ return self.api_client.response_deserialize(
183
+ response_data=response_data,
184
+ response_types_map=_response_types_map,
185
+ )
186
+
187
+
188
+ @validate_call
189
+ def add_permissions_on_group_without_preload_content(
190
+ self,
191
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add permissions")],
192
+ request_body: List[StrictStr],
193
+ _request_timeout: Union[
194
+ None,
195
+ Annotated[StrictFloat, Field(gt=0)],
196
+ Tuple[
197
+ Annotated[StrictFloat, Field(gt=0)],
198
+ Annotated[StrictFloat, Field(gt=0)]
199
+ ]
200
+ ] = None,
201
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
202
+ _content_type: Optional[StrictStr] = None,
203
+ _headers: Optional[Dict[StrictStr, Any]] = None,
204
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
205
+ ) -> RESTResponseType:
206
+ """Add permissions to group
207
+
208
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
209
+
210
+ :param group_id: Id of the group to add permissions (required)
211
+ :type group_id: str
212
+ :param request_body: (required)
213
+ :type request_body: List[str]
214
+ :param _request_timeout: timeout setting for this request. If one
215
+ number provided, it will be total request
216
+ timeout. It can also be a pair (tuple) of
217
+ (connection, read) timeouts.
218
+ :type _request_timeout: int, tuple(int, int), optional
219
+ :param _request_auth: set to override the auth_settings for an a single
220
+ request; this effectively ignores the
221
+ authentication in the spec for a single request.
222
+ :type _request_auth: dict, optional
223
+ :param _content_type: force content-type for the request.
224
+ :type _content_type: str, Optional
225
+ :param _headers: set to override the headers for a single
226
+ request; this effectively ignores the headers
227
+ in the spec for a single request.
228
+ :type _headers: dict, optional
229
+ :param _host_index: set to override the host_index for a single
230
+ request; this effectively ignores the host_index
231
+ in the spec for a single request.
232
+ :type _host_index: int, optional
233
+ :return: Returns the result object.
234
+ """ # noqa: E501
235
+
236
+ _param = self._add_permissions_on_group_serialize(
237
+ group_id=group_id,
238
+ request_body=request_body,
239
+ _request_auth=_request_auth,
240
+ _content_type=_content_type,
241
+ _headers=_headers,
242
+ _host_index=_host_index
243
+ )
244
+
245
+ _response_types_map: Dict[str, Optional[str]] = {
246
+ '200': "ApiGroup",
247
+ }
248
+ response_data = self.api_client.call_api(
249
+ *_param,
250
+ _request_timeout=_request_timeout
251
+ )
252
+ return response_data.response
253
+
254
+
255
+ def _add_permissions_on_group_serialize(
256
+ self,
257
+ group_id,
258
+ request_body,
259
+ _request_auth,
260
+ _content_type,
261
+ _headers,
262
+ _host_index,
263
+ ) -> RequestSerialized:
264
+
265
+ _host = None
266
+
267
+ _collection_formats: Dict[str, str] = {
268
+ 'request_body': '',
269
+ }
270
+
271
+ _path_params: Dict[str, str] = {}
272
+ _query_params: List[Tuple[str, str]] = []
273
+ _header_params: Dict[str, Optional[str]] = _headers or {}
274
+ _form_params: List[Tuple[str, str]] = []
275
+ _files: Dict[
276
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
277
+ ] = {}
278
+ _body_params: Optional[bytes] = None
279
+
280
+ # process the path parameters
281
+ if group_id is not None:
282
+ _path_params['groupId'] = group_id
283
+ # process the query parameters
284
+ # process the header parameters
285
+ # process the form parameters
286
+ # process the body parameter
287
+ if request_body is not None:
288
+ _body_params = request_body
289
+
290
+
291
+ # set the HTTP header `Accept`
292
+ if 'Accept' not in _header_params:
293
+ _header_params['Accept'] = self.api_client.select_header_accept(
294
+ [
295
+ 'application/json'
296
+ ]
297
+ )
298
+
299
+ # set the HTTP header `Content-Type`
300
+ if _content_type:
301
+ _header_params['Content-Type'] = _content_type
302
+ else:
303
+ _default_content_type = (
304
+ self.api_client.select_header_content_type(
305
+ [
306
+ 'application/json'
307
+ ]
308
+ )
309
+ )
310
+ if _default_content_type is not None:
311
+ _header_params['Content-Type'] = _default_content_type
312
+
313
+ # authentication setting
314
+ _auth_settings: List[str] = [
315
+ 'ApiKeyAuth'
316
+ ]
317
+
318
+ return self.api_client.param_serialize(
319
+ method='PUT',
320
+ resource_path='/api/settings/rbac/groups/{groupId}/permissions',
321
+ path_params=_path_params,
322
+ query_params=_query_params,
323
+ header_params=_header_params,
324
+ body=_body_params,
325
+ post_params=_form_params,
326
+ files=_files,
327
+ auth_settings=_auth_settings,
328
+ collection_formats=_collection_formats,
329
+ _host=_host,
330
+ _request_auth=_request_auth
331
+ )
332
+
333
+
334
+
335
+
336
+ @validate_call
337
+ def add_users_to_group(
338
+ self,
339
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add users")],
340
+ request_body: List[StrictStr],
341
+ _request_timeout: Union[
342
+ None,
343
+ Annotated[StrictFloat, Field(gt=0)],
344
+ Tuple[
345
+ Annotated[StrictFloat, Field(gt=0)],
346
+ Annotated[StrictFloat, Field(gt=0)]
347
+ ]
348
+ ] = None,
349
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
350
+ _content_type: Optional[StrictStr] = None,
351
+ _headers: Optional[Dict[StrictStr, Any]] = None,
352
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
353
+ ) -> ApiGroup:
354
+ """Add users to group
355
+
356
+ Add one or more users to a group. The array contains the ids of the users to be added.
357
+
358
+ :param group_id: Id of the group to add users (required)
359
+ :type group_id: str
360
+ :param request_body: (required)
361
+ :type request_body: List[str]
362
+ :param _request_timeout: timeout setting for this request. If one
363
+ number provided, it will be total request
364
+ timeout. It can also be a pair (tuple) of
365
+ (connection, read) timeouts.
366
+ :type _request_timeout: int, tuple(int, int), optional
367
+ :param _request_auth: set to override the auth_settings for an a single
368
+ request; this effectively ignores the
369
+ authentication in the spec for a single request.
370
+ :type _request_auth: dict, optional
371
+ :param _content_type: force content-type for the request.
372
+ :type _content_type: str, Optional
373
+ :param _headers: set to override the headers for a single
374
+ request; this effectively ignores the headers
375
+ in the spec for a single request.
376
+ :type _headers: dict, optional
377
+ :param _host_index: set to override the host_index for a single
378
+ request; this effectively ignores the host_index
379
+ in the spec for a single request.
380
+ :type _host_index: int, optional
381
+ :return: Returns the result object.
382
+ """ # noqa: E501
383
+
384
+ _param = self._add_users_to_group_serialize(
385
+ group_id=group_id,
386
+ request_body=request_body,
387
+ _request_auth=_request_auth,
388
+ _content_type=_content_type,
389
+ _headers=_headers,
390
+ _host_index=_host_index
391
+ )
392
+
393
+ _response_types_map: Dict[str, Optional[str]] = {
394
+ '200': "ApiGroup",
395
+ }
396
+ response_data = self.api_client.call_api(
397
+ *_param,
398
+ _request_timeout=_request_timeout
399
+ )
400
+ response_data.read()
401
+ return self.api_client.response_deserialize(
402
+ response_data=response_data,
403
+ response_types_map=_response_types_map,
404
+ ).data
405
+
406
+
407
+ @validate_call
408
+ def add_users_to_group_with_http_info(
409
+ self,
410
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add users")],
411
+ request_body: List[StrictStr],
412
+ _request_timeout: Union[
413
+ None,
414
+ Annotated[StrictFloat, Field(gt=0)],
415
+ Tuple[
416
+ Annotated[StrictFloat, Field(gt=0)],
417
+ Annotated[StrictFloat, Field(gt=0)]
418
+ ]
419
+ ] = None,
420
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
421
+ _content_type: Optional[StrictStr] = None,
422
+ _headers: Optional[Dict[StrictStr, Any]] = None,
423
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
424
+ ) -> ApiResponse[ApiGroup]:
425
+ """Add users to group
426
+
427
+ Add one or more users to a group. The array contains the ids of the users to be added.
428
+
429
+ :param group_id: Id of the group to add users (required)
430
+ :type group_id: str
431
+ :param request_body: (required)
432
+ :type request_body: List[str]
433
+ :param _request_timeout: timeout setting for this request. If one
434
+ number provided, it will be total request
435
+ timeout. It can also be a pair (tuple) of
436
+ (connection, read) timeouts.
437
+ :type _request_timeout: int, tuple(int, int), optional
438
+ :param _request_auth: set to override the auth_settings for an a single
439
+ request; this effectively ignores the
440
+ authentication in the spec for a single request.
441
+ :type _request_auth: dict, optional
442
+ :param _content_type: force content-type for the request.
443
+ :type _content_type: str, Optional
444
+ :param _headers: set to override the headers for a single
445
+ request; this effectively ignores the headers
446
+ in the spec for a single request.
447
+ :type _headers: dict, optional
448
+ :param _host_index: set to override the host_index for a single
449
+ request; this effectively ignores the host_index
450
+ in the spec for a single request.
451
+ :type _host_index: int, optional
452
+ :return: Returns the result object.
453
+ """ # noqa: E501
454
+
455
+ _param = self._add_users_to_group_serialize(
456
+ group_id=group_id,
457
+ request_body=request_body,
458
+ _request_auth=_request_auth,
459
+ _content_type=_content_type,
460
+ _headers=_headers,
461
+ _host_index=_host_index
462
+ )
463
+
464
+ _response_types_map: Dict[str, Optional[str]] = {
465
+ '200': "ApiGroup",
466
+ }
467
+ response_data = self.api_client.call_api(
468
+ *_param,
469
+ _request_timeout=_request_timeout
470
+ )
471
+ response_data.read()
472
+ return self.api_client.response_deserialize(
473
+ response_data=response_data,
474
+ response_types_map=_response_types_map,
475
+ )
476
+
477
+
478
+ @validate_call
479
+ def add_users_to_group_without_preload_content(
480
+ self,
481
+ group_id: Annotated[StrictStr, Field(description="Id of the group to add users")],
482
+ request_body: List[StrictStr],
483
+ _request_timeout: Union[
484
+ None,
485
+ Annotated[StrictFloat, Field(gt=0)],
486
+ Tuple[
487
+ Annotated[StrictFloat, Field(gt=0)],
488
+ Annotated[StrictFloat, Field(gt=0)]
489
+ ]
490
+ ] = None,
491
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
492
+ _content_type: Optional[StrictStr] = None,
493
+ _headers: Optional[Dict[StrictStr, Any]] = None,
494
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
495
+ ) -> RESTResponseType:
496
+ """Add users to group
497
+
498
+ Add one or more users to a group. The array contains the ids of the users to be added.
499
+
500
+ :param group_id: Id of the group to add users (required)
501
+ :type group_id: str
502
+ :param request_body: (required)
503
+ :type request_body: List[str]
504
+ :param _request_timeout: timeout setting for this request. If one
505
+ number provided, it will be total request
506
+ timeout. It can also be a pair (tuple) of
507
+ (connection, read) timeouts.
508
+ :type _request_timeout: int, tuple(int, int), optional
509
+ :param _request_auth: set to override the auth_settings for an a single
510
+ request; this effectively ignores the
511
+ authentication in the spec for a single request.
512
+ :type _request_auth: dict, optional
513
+ :param _content_type: force content-type for the request.
514
+ :type _content_type: str, Optional
515
+ :param _headers: set to override the headers for a single
516
+ request; this effectively ignores the headers
517
+ in the spec for a single request.
518
+ :type _headers: dict, optional
519
+ :param _host_index: set to override the host_index for a single
520
+ request; this effectively ignores the host_index
521
+ in the spec for a single request.
522
+ :type _host_index: int, optional
523
+ :return: Returns the result object.
524
+ """ # noqa: E501
525
+
526
+ _param = self._add_users_to_group_serialize(
527
+ group_id=group_id,
528
+ request_body=request_body,
529
+ _request_auth=_request_auth,
530
+ _content_type=_content_type,
531
+ _headers=_headers,
532
+ _host_index=_host_index
533
+ )
534
+
535
+ _response_types_map: Dict[str, Optional[str]] = {
536
+ '200': "ApiGroup",
537
+ }
538
+ response_data = self.api_client.call_api(
539
+ *_param,
540
+ _request_timeout=_request_timeout
541
+ )
542
+ return response_data.response
543
+
544
+
545
+ def _add_users_to_group_serialize(
546
+ self,
547
+ group_id,
548
+ request_body,
549
+ _request_auth,
550
+ _content_type,
551
+ _headers,
552
+ _host_index,
553
+ ) -> RequestSerialized:
554
+
555
+ _host = None
556
+
557
+ _collection_formats: Dict[str, str] = {
558
+ 'request_body': '',
559
+ }
560
+
561
+ _path_params: Dict[str, str] = {}
562
+ _query_params: List[Tuple[str, str]] = []
563
+ _header_params: Dict[str, Optional[str]] = _headers or {}
564
+ _form_params: List[Tuple[str, str]] = []
565
+ _files: Dict[
566
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
567
+ ] = {}
568
+ _body_params: Optional[bytes] = None
569
+
570
+ # process the path parameters
571
+ if group_id is not None:
572
+ _path_params['groupId'] = group_id
573
+ # process the query parameters
574
+ # process the header parameters
575
+ # process the form parameters
576
+ # process the body parameter
577
+ if request_body is not None:
578
+ _body_params = request_body
579
+
580
+
581
+ # set the HTTP header `Accept`
582
+ if 'Accept' not in _header_params:
583
+ _header_params['Accept'] = self.api_client.select_header_accept(
584
+ [
585
+ 'application/json'
586
+ ]
587
+ )
588
+
589
+ # set the HTTP header `Content-Type`
590
+ if _content_type:
591
+ _header_params['Content-Type'] = _content_type
592
+ else:
593
+ _default_content_type = (
594
+ self.api_client.select_header_content_type(
595
+ [
596
+ 'application/json'
597
+ ]
598
+ )
599
+ )
600
+ if _default_content_type is not None:
601
+ _header_params['Content-Type'] = _default_content_type
602
+
603
+ # authentication setting
604
+ _auth_settings: List[str] = [
605
+ 'ApiKeyAuth'
606
+ ]
607
+
608
+ return self.api_client.param_serialize(
609
+ method='PUT',
610
+ resource_path='/api/settings/rbac/groups/{groupId}/users',
611
+ path_params=_path_params,
612
+ query_params=_query_params,
613
+ header_params=_header_params,
614
+ body=_body_params,
615
+ post_params=_form_params,
616
+ files=_files,
617
+ auth_settings=_auth_settings,
618
+ collection_formats=_collection_formats,
619
+ _host=_host,
620
+ _request_auth=_request_auth
621
+ )
622
+
623
+
624
+
625
+
626
+ @validate_call
627
+ def create_group(
628
+ self,
629
+ api_create_group: ApiCreateGroup,
630
+ _request_timeout: Union[
631
+ None,
632
+ Annotated[StrictFloat, Field(gt=0)],
633
+ Tuple[
634
+ Annotated[StrictFloat, Field(gt=0)],
635
+ Annotated[StrictFloat, Field(gt=0)]
636
+ ]
637
+ ] = None,
638
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
639
+ _content_type: Optional[StrictStr] = None,
640
+ _headers: Optional[Dict[StrictStr, Any]] = None,
641
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
642
+ ) -> ApiGroup:
643
+ """Create group
644
+
645
+ Creates a group on the tenant. Each group entry also needs a `Permission Set` per unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. Possible access permissions values are: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE` The `id` value for the group is ignored, a new id is generated. The `scopeRoleId` is ignored, the id corresponding to the area is used. The `scopeId` is the id for the corresponding resource.
646
+
647
+ :param api_create_group: (required)
648
+ :type api_create_group: ApiCreateGroup
649
+ :param _request_timeout: timeout setting for this request. If one
650
+ number provided, it will be total request
651
+ timeout. It can also be a pair (tuple) of
652
+ (connection, read) timeouts.
653
+ :type _request_timeout: int, tuple(int, int), optional
654
+ :param _request_auth: set to override the auth_settings for an a single
655
+ request; this effectively ignores the
656
+ authentication in the spec for a single request.
657
+ :type _request_auth: dict, optional
658
+ :param _content_type: force content-type for the request.
659
+ :type _content_type: str, Optional
660
+ :param _headers: set to override the headers for a single
661
+ request; this effectively ignores the headers
662
+ in the spec for a single request.
663
+ :type _headers: dict, optional
664
+ :param _host_index: set to override the host_index for a single
665
+ request; this effectively ignores the host_index
666
+ in the spec for a single request.
667
+ :type _host_index: int, optional
668
+ :return: Returns the result object.
669
+ """ # noqa: E501
670
+
671
+ _param = self._create_group_serialize(
672
+ api_create_group=api_create_group,
673
+ _request_auth=_request_auth,
674
+ _content_type=_content_type,
675
+ _headers=_headers,
676
+ _host_index=_host_index
677
+ )
678
+
679
+ _response_types_map: Dict[str, Optional[str]] = {
680
+ '200': "ApiGroup",
681
+ }
682
+ response_data = self.api_client.call_api(
683
+ *_param,
684
+ _request_timeout=_request_timeout
685
+ )
686
+ response_data.read()
687
+ return self.api_client.response_deserialize(
688
+ response_data=response_data,
689
+ response_types_map=_response_types_map,
690
+ ).data
691
+
692
+
693
+ @validate_call
694
+ def create_group_with_http_info(
695
+ self,
696
+ api_create_group: ApiCreateGroup,
697
+ _request_timeout: Union[
698
+ None,
699
+ Annotated[StrictFloat, Field(gt=0)],
700
+ Tuple[
701
+ Annotated[StrictFloat, Field(gt=0)],
702
+ Annotated[StrictFloat, Field(gt=0)]
703
+ ]
704
+ ] = None,
705
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
706
+ _content_type: Optional[StrictStr] = None,
707
+ _headers: Optional[Dict[StrictStr, Any]] = None,
708
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
709
+ ) -> ApiResponse[ApiGroup]:
710
+ """Create group
711
+
712
+ Creates a group on the tenant. Each group entry also needs a `Permission Set` per unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. Possible access permissions values are: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE` The `id` value for the group is ignored, a new id is generated. The `scopeRoleId` is ignored, the id corresponding to the area is used. The `scopeId` is the id for the corresponding resource.
713
+
714
+ :param api_create_group: (required)
715
+ :type api_create_group: ApiCreateGroup
716
+ :param _request_timeout: timeout setting for this request. If one
717
+ number provided, it will be total request
718
+ timeout. It can also be a pair (tuple) of
719
+ (connection, read) timeouts.
720
+ :type _request_timeout: int, tuple(int, int), optional
721
+ :param _request_auth: set to override the auth_settings for an a single
722
+ request; this effectively ignores the
723
+ authentication in the spec for a single request.
724
+ :type _request_auth: dict, optional
725
+ :param _content_type: force content-type for the request.
726
+ :type _content_type: str, Optional
727
+ :param _headers: set to override the headers for a single
728
+ request; this effectively ignores the headers
729
+ in the spec for a single request.
730
+ :type _headers: dict, optional
731
+ :param _host_index: set to override the host_index for a single
732
+ request; this effectively ignores the host_index
733
+ in the spec for a single request.
734
+ :type _host_index: int, optional
735
+ :return: Returns the result object.
736
+ """ # noqa: E501
737
+
738
+ _param = self._create_group_serialize(
739
+ api_create_group=api_create_group,
740
+ _request_auth=_request_auth,
741
+ _content_type=_content_type,
742
+ _headers=_headers,
743
+ _host_index=_host_index
744
+ )
745
+
746
+ _response_types_map: Dict[str, Optional[str]] = {
747
+ '200': "ApiGroup",
748
+ }
749
+ response_data = self.api_client.call_api(
750
+ *_param,
751
+ _request_timeout=_request_timeout
752
+ )
753
+ response_data.read()
754
+ return self.api_client.response_deserialize(
755
+ response_data=response_data,
756
+ response_types_map=_response_types_map,
757
+ )
758
+
759
+
760
+ @validate_call
761
+ def create_group_without_preload_content(
762
+ self,
763
+ api_create_group: ApiCreateGroup,
764
+ _request_timeout: Union[
765
+ None,
766
+ Annotated[StrictFloat, Field(gt=0)],
767
+ Tuple[
768
+ Annotated[StrictFloat, Field(gt=0)],
769
+ Annotated[StrictFloat, Field(gt=0)]
770
+ ]
771
+ ] = None,
772
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
773
+ _content_type: Optional[StrictStr] = None,
774
+ _headers: Optional[Dict[StrictStr, Any]] = None,
775
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
776
+ ) -> RESTResponseType:
777
+ """Create group
778
+
779
+ Creates a group on the tenant. Each group entry also needs a `Permission Set` per unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. Possible access permissions values are: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE` The `id` value for the group is ignored, a new id is generated. The `scopeRoleId` is ignored, the id corresponding to the area is used. The `scopeId` is the id for the corresponding resource.
780
+
781
+ :param api_create_group: (required)
782
+ :type api_create_group: ApiCreateGroup
783
+ :param _request_timeout: timeout setting for this request. If one
784
+ number provided, it will be total request
785
+ timeout. It can also be a pair (tuple) of
786
+ (connection, read) timeouts.
787
+ :type _request_timeout: int, tuple(int, int), optional
788
+ :param _request_auth: set to override the auth_settings for an a single
789
+ request; this effectively ignores the
790
+ authentication in the spec for a single request.
791
+ :type _request_auth: dict, optional
792
+ :param _content_type: force content-type for the request.
793
+ :type _content_type: str, Optional
794
+ :param _headers: set to override the headers for a single
795
+ request; this effectively ignores the headers
796
+ in the spec for a single request.
797
+ :type _headers: dict, optional
798
+ :param _host_index: set to override the host_index for a single
799
+ request; this effectively ignores the host_index
800
+ in the spec for a single request.
801
+ :type _host_index: int, optional
802
+ :return: Returns the result object.
803
+ """ # noqa: E501
804
+
805
+ _param = self._create_group_serialize(
806
+ api_create_group=api_create_group,
807
+ _request_auth=_request_auth,
808
+ _content_type=_content_type,
809
+ _headers=_headers,
810
+ _host_index=_host_index
811
+ )
812
+
813
+ _response_types_map: Dict[str, Optional[str]] = {
814
+ '200': "ApiGroup",
815
+ }
816
+ response_data = self.api_client.call_api(
817
+ *_param,
818
+ _request_timeout=_request_timeout
819
+ )
820
+ return response_data.response
821
+
822
+
823
+ def _create_group_serialize(
824
+ self,
825
+ api_create_group,
826
+ _request_auth,
827
+ _content_type,
828
+ _headers,
829
+ _host_index,
830
+ ) -> RequestSerialized:
831
+
832
+ _host = None
833
+
834
+ _collection_formats: Dict[str, str] = {
835
+ }
836
+
837
+ _path_params: Dict[str, str] = {}
838
+ _query_params: List[Tuple[str, str]] = []
839
+ _header_params: Dict[str, Optional[str]] = _headers or {}
840
+ _form_params: List[Tuple[str, str]] = []
841
+ _files: Dict[
842
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
843
+ ] = {}
844
+ _body_params: Optional[bytes] = None
845
+
846
+ # process the path parameters
847
+ # process the query parameters
848
+ # process the header parameters
849
+ # process the form parameters
850
+ # process the body parameter
851
+ if api_create_group is not None:
852
+ _body_params = api_create_group
853
+
854
+
855
+ # set the HTTP header `Accept`
856
+ if 'Accept' not in _header_params:
857
+ _header_params['Accept'] = self.api_client.select_header_accept(
858
+ [
859
+ 'application/json'
860
+ ]
861
+ )
862
+
863
+ # set the HTTP header `Content-Type`
864
+ if _content_type:
865
+ _header_params['Content-Type'] = _content_type
866
+ else:
867
+ _default_content_type = (
868
+ self.api_client.select_header_content_type(
869
+ [
870
+ 'application/json'
871
+ ]
872
+ )
873
+ )
874
+ if _default_content_type is not None:
875
+ _header_params['Content-Type'] = _default_content_type
876
+
877
+ # authentication setting
878
+ _auth_settings: List[str] = [
879
+ 'ApiKeyAuth'
880
+ ]
881
+
882
+ return self.api_client.param_serialize(
883
+ method='POST',
884
+ resource_path='/api/settings/rbac/groups',
885
+ path_params=_path_params,
886
+ query_params=_query_params,
887
+ header_params=_header_params,
888
+ body=_body_params,
889
+ post_params=_form_params,
890
+ files=_files,
891
+ auth_settings=_auth_settings,
892
+ collection_formats=_collection_formats,
893
+ _host=_host,
894
+ _request_auth=_request_auth
895
+ )
896
+
897
+
898
+
899
+
900
+ @validate_call
901
+ def create_group_mapping(
902
+ self,
903
+ group_mapping: GroupMapping,
904
+ _request_timeout: Union[
905
+ None,
906
+ Annotated[StrictFloat, Field(gt=0)],
907
+ Tuple[
908
+ Annotated[StrictFloat, Field(gt=0)],
909
+ Annotated[StrictFloat, Field(gt=0)]
910
+ ]
911
+ ] = None,
912
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
913
+ _content_type: Optional[StrictStr] = None,
914
+ _headers: Optional[Dict[StrictStr, Any]] = None,
915
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
916
+ ) -> GroupMapping:
917
+ """Create group mapping
918
+
919
+ Creates a mapping between a group from the IdP (LDAP, OIDC, SAML) and an Instana group. If the IdP is configured and mappings are enabled, the `key` `value` pairs a user sent by the idp will be evaluated every time this user logs in. If they match the mapping, the user will be assigned to the group corresponding to the `groupId`. Inside the payload, the `id` for the mapping is ignored, and instead, Instana generates a new id.
920
+
921
+ :param group_mapping: (required)
922
+ :type group_mapping: GroupMapping
923
+ :param _request_timeout: timeout setting for this request. If one
924
+ number provided, it will be total request
925
+ timeout. It can also be a pair (tuple) of
926
+ (connection, read) timeouts.
927
+ :type _request_timeout: int, tuple(int, int), optional
928
+ :param _request_auth: set to override the auth_settings for an a single
929
+ request; this effectively ignores the
930
+ authentication in the spec for a single request.
931
+ :type _request_auth: dict, optional
932
+ :param _content_type: force content-type for the request.
933
+ :type _content_type: str, Optional
934
+ :param _headers: set to override the headers for a single
935
+ request; this effectively ignores the headers
936
+ in the spec for a single request.
937
+ :type _headers: dict, optional
938
+ :param _host_index: set to override the host_index for a single
939
+ request; this effectively ignores the host_index
940
+ in the spec for a single request.
941
+ :type _host_index: int, optional
942
+ :return: Returns the result object.
943
+ """ # noqa: E501
944
+
945
+ _param = self._create_group_mapping_serialize(
946
+ group_mapping=group_mapping,
947
+ _request_auth=_request_auth,
948
+ _content_type=_content_type,
949
+ _headers=_headers,
950
+ _host_index=_host_index
951
+ )
952
+
953
+ _response_types_map: Dict[str, Optional[str]] = {
954
+ '200': "GroupMapping",
955
+ }
956
+ response_data = self.api_client.call_api(
957
+ *_param,
958
+ _request_timeout=_request_timeout
959
+ )
960
+ response_data.read()
961
+ return self.api_client.response_deserialize(
962
+ response_data=response_data,
963
+ response_types_map=_response_types_map,
964
+ ).data
965
+
966
+
967
+ @validate_call
968
+ def create_group_mapping_with_http_info(
969
+ self,
970
+ group_mapping: GroupMapping,
971
+ _request_timeout: Union[
972
+ None,
973
+ Annotated[StrictFloat, Field(gt=0)],
974
+ Tuple[
975
+ Annotated[StrictFloat, Field(gt=0)],
976
+ Annotated[StrictFloat, Field(gt=0)]
977
+ ]
978
+ ] = None,
979
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
980
+ _content_type: Optional[StrictStr] = None,
981
+ _headers: Optional[Dict[StrictStr, Any]] = None,
982
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
983
+ ) -> ApiResponse[GroupMapping]:
984
+ """Create group mapping
985
+
986
+ Creates a mapping between a group from the IdP (LDAP, OIDC, SAML) and an Instana group. If the IdP is configured and mappings are enabled, the `key` `value` pairs a user sent by the idp will be evaluated every time this user logs in. If they match the mapping, the user will be assigned to the group corresponding to the `groupId`. Inside the payload, the `id` for the mapping is ignored, and instead, Instana generates a new id.
987
+
988
+ :param group_mapping: (required)
989
+ :type group_mapping: GroupMapping
990
+ :param _request_timeout: timeout setting for this request. If one
991
+ number provided, it will be total request
992
+ timeout. It can also be a pair (tuple) of
993
+ (connection, read) timeouts.
994
+ :type _request_timeout: int, tuple(int, int), optional
995
+ :param _request_auth: set to override the auth_settings for an a single
996
+ request; this effectively ignores the
997
+ authentication in the spec for a single request.
998
+ :type _request_auth: dict, optional
999
+ :param _content_type: force content-type for the request.
1000
+ :type _content_type: str, Optional
1001
+ :param _headers: set to override the headers for a single
1002
+ request; this effectively ignores the headers
1003
+ in the spec for a single request.
1004
+ :type _headers: dict, optional
1005
+ :param _host_index: set to override the host_index for a single
1006
+ request; this effectively ignores the host_index
1007
+ in the spec for a single request.
1008
+ :type _host_index: int, optional
1009
+ :return: Returns the result object.
1010
+ """ # noqa: E501
1011
+
1012
+ _param = self._create_group_mapping_serialize(
1013
+ group_mapping=group_mapping,
1014
+ _request_auth=_request_auth,
1015
+ _content_type=_content_type,
1016
+ _headers=_headers,
1017
+ _host_index=_host_index
1018
+ )
1019
+
1020
+ _response_types_map: Dict[str, Optional[str]] = {
1021
+ '200': "GroupMapping",
1022
+ }
1023
+ response_data = self.api_client.call_api(
1024
+ *_param,
1025
+ _request_timeout=_request_timeout
1026
+ )
1027
+ response_data.read()
1028
+ return self.api_client.response_deserialize(
1029
+ response_data=response_data,
1030
+ response_types_map=_response_types_map,
1031
+ )
1032
+
1033
+
1034
+ @validate_call
1035
+ def create_group_mapping_without_preload_content(
1036
+ self,
1037
+ group_mapping: GroupMapping,
1038
+ _request_timeout: Union[
1039
+ None,
1040
+ Annotated[StrictFloat, Field(gt=0)],
1041
+ Tuple[
1042
+ Annotated[StrictFloat, Field(gt=0)],
1043
+ Annotated[StrictFloat, Field(gt=0)]
1044
+ ]
1045
+ ] = None,
1046
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1047
+ _content_type: Optional[StrictStr] = None,
1048
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1049
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1050
+ ) -> RESTResponseType:
1051
+ """Create group mapping
1052
+
1053
+ Creates a mapping between a group from the IdP (LDAP, OIDC, SAML) and an Instana group. If the IdP is configured and mappings are enabled, the `key` `value` pairs a user sent by the idp will be evaluated every time this user logs in. If they match the mapping, the user will be assigned to the group corresponding to the `groupId`. Inside the payload, the `id` for the mapping is ignored, and instead, Instana generates a new id.
1054
+
1055
+ :param group_mapping: (required)
1056
+ :type group_mapping: GroupMapping
1057
+ :param _request_timeout: timeout setting for this request. If one
1058
+ number provided, it will be total request
1059
+ timeout. It can also be a pair (tuple) of
1060
+ (connection, read) timeouts.
1061
+ :type _request_timeout: int, tuple(int, int), optional
1062
+ :param _request_auth: set to override the auth_settings for an a single
1063
+ request; this effectively ignores the
1064
+ authentication in the spec for a single request.
1065
+ :type _request_auth: dict, optional
1066
+ :param _content_type: force content-type for the request.
1067
+ :type _content_type: str, Optional
1068
+ :param _headers: set to override the headers for a single
1069
+ request; this effectively ignores the headers
1070
+ in the spec for a single request.
1071
+ :type _headers: dict, optional
1072
+ :param _host_index: set to override the host_index for a single
1073
+ request; this effectively ignores the host_index
1074
+ in the spec for a single request.
1075
+ :type _host_index: int, optional
1076
+ :return: Returns the result object.
1077
+ """ # noqa: E501
1078
+
1079
+ _param = self._create_group_mapping_serialize(
1080
+ group_mapping=group_mapping,
1081
+ _request_auth=_request_auth,
1082
+ _content_type=_content_type,
1083
+ _headers=_headers,
1084
+ _host_index=_host_index
1085
+ )
1086
+
1087
+ _response_types_map: Dict[str, Optional[str]] = {
1088
+ '200': "GroupMapping",
1089
+ }
1090
+ response_data = self.api_client.call_api(
1091
+ *_param,
1092
+ _request_timeout=_request_timeout
1093
+ )
1094
+ return response_data.response
1095
+
1096
+
1097
+ def _create_group_mapping_serialize(
1098
+ self,
1099
+ group_mapping,
1100
+ _request_auth,
1101
+ _content_type,
1102
+ _headers,
1103
+ _host_index,
1104
+ ) -> RequestSerialized:
1105
+
1106
+ _host = None
1107
+
1108
+ _collection_formats: Dict[str, str] = {
1109
+ }
1110
+
1111
+ _path_params: Dict[str, str] = {}
1112
+ _query_params: List[Tuple[str, str]] = []
1113
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1114
+ _form_params: List[Tuple[str, str]] = []
1115
+ _files: Dict[
1116
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1117
+ ] = {}
1118
+ _body_params: Optional[bytes] = None
1119
+
1120
+ # process the path parameters
1121
+ # process the query parameters
1122
+ # process the header parameters
1123
+ # process the form parameters
1124
+ # process the body parameter
1125
+ if group_mapping is not None:
1126
+ _body_params = group_mapping
1127
+
1128
+
1129
+ # set the HTTP header `Accept`
1130
+ if 'Accept' not in _header_params:
1131
+ _header_params['Accept'] = self.api_client.select_header_accept(
1132
+ [
1133
+ 'application/json'
1134
+ ]
1135
+ )
1136
+
1137
+ # set the HTTP header `Content-Type`
1138
+ if _content_type:
1139
+ _header_params['Content-Type'] = _content_type
1140
+ else:
1141
+ _default_content_type = (
1142
+ self.api_client.select_header_content_type(
1143
+ [
1144
+ 'application/json'
1145
+ ]
1146
+ )
1147
+ )
1148
+ if _default_content_type is not None:
1149
+ _header_params['Content-Type'] = _default_content_type
1150
+
1151
+ # authentication setting
1152
+ _auth_settings: List[str] = [
1153
+ 'ApiKeyAuth'
1154
+ ]
1155
+
1156
+ return self.api_client.param_serialize(
1157
+ method='POST',
1158
+ resource_path='/api/settings/rbac/mappings',
1159
+ path_params=_path_params,
1160
+ query_params=_query_params,
1161
+ header_params=_header_params,
1162
+ body=_body_params,
1163
+ post_params=_form_params,
1164
+ files=_files,
1165
+ auth_settings=_auth_settings,
1166
+ collection_formats=_collection_formats,
1167
+ _host=_host,
1168
+ _request_auth=_request_auth
1169
+ )
1170
+
1171
+
1172
+
1173
+
1174
+ @validate_call
1175
+ def delete_group(
1176
+ self,
1177
+ id: Annotated[StrictStr, Field(description="Id of the group to delete")],
1178
+ _request_timeout: Union[
1179
+ None,
1180
+ Annotated[StrictFloat, Field(gt=0)],
1181
+ Tuple[
1182
+ Annotated[StrictFloat, Field(gt=0)],
1183
+ Annotated[StrictFloat, Field(gt=0)]
1184
+ ]
1185
+ ] = None,
1186
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1187
+ _content_type: Optional[StrictStr] = None,
1188
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1189
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1190
+ ) -> None:
1191
+ """Delete group
1192
+
1193
+ Delete the group data.
1194
+
1195
+ :param id: Id of the group to delete (required)
1196
+ :type id: str
1197
+ :param _request_timeout: timeout setting for this request. If one
1198
+ number provided, it will be total request
1199
+ timeout. It can also be a pair (tuple) of
1200
+ (connection, read) timeouts.
1201
+ :type _request_timeout: int, tuple(int, int), optional
1202
+ :param _request_auth: set to override the auth_settings for an a single
1203
+ request; this effectively ignores the
1204
+ authentication in the spec for a single request.
1205
+ :type _request_auth: dict, optional
1206
+ :param _content_type: force content-type for the request.
1207
+ :type _content_type: str, Optional
1208
+ :param _headers: set to override the headers for a single
1209
+ request; this effectively ignores the headers
1210
+ in the spec for a single request.
1211
+ :type _headers: dict, optional
1212
+ :param _host_index: set to override the host_index for a single
1213
+ request; this effectively ignores the host_index
1214
+ in the spec for a single request.
1215
+ :type _host_index: int, optional
1216
+ :return: Returns the result object.
1217
+ """ # noqa: E501
1218
+
1219
+ _param = self._delete_group_serialize(
1220
+ id=id,
1221
+ _request_auth=_request_auth,
1222
+ _content_type=_content_type,
1223
+ _headers=_headers,
1224
+ _host_index=_host_index
1225
+ )
1226
+
1227
+ _response_types_map: Dict[str, Optional[str]] = {
1228
+ }
1229
+ response_data = self.api_client.call_api(
1230
+ *_param,
1231
+ _request_timeout=_request_timeout
1232
+ )
1233
+ response_data.read()
1234
+ return self.api_client.response_deserialize(
1235
+ response_data=response_data,
1236
+ response_types_map=_response_types_map,
1237
+ ).data
1238
+
1239
+
1240
+ @validate_call
1241
+ def delete_group_with_http_info(
1242
+ self,
1243
+ id: Annotated[StrictStr, Field(description="Id of the group to delete")],
1244
+ _request_timeout: Union[
1245
+ None,
1246
+ Annotated[StrictFloat, Field(gt=0)],
1247
+ Tuple[
1248
+ Annotated[StrictFloat, Field(gt=0)],
1249
+ Annotated[StrictFloat, Field(gt=0)]
1250
+ ]
1251
+ ] = None,
1252
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1253
+ _content_type: Optional[StrictStr] = None,
1254
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1255
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1256
+ ) -> ApiResponse[None]:
1257
+ """Delete group
1258
+
1259
+ Delete the group data.
1260
+
1261
+ :param id: Id of the group to delete (required)
1262
+ :type id: str
1263
+ :param _request_timeout: timeout setting for this request. If one
1264
+ number provided, it will be total request
1265
+ timeout. It can also be a pair (tuple) of
1266
+ (connection, read) timeouts.
1267
+ :type _request_timeout: int, tuple(int, int), optional
1268
+ :param _request_auth: set to override the auth_settings for an a single
1269
+ request; this effectively ignores the
1270
+ authentication in the spec for a single request.
1271
+ :type _request_auth: dict, optional
1272
+ :param _content_type: force content-type for the request.
1273
+ :type _content_type: str, Optional
1274
+ :param _headers: set to override the headers for a single
1275
+ request; this effectively ignores the headers
1276
+ in the spec for a single request.
1277
+ :type _headers: dict, optional
1278
+ :param _host_index: set to override the host_index for a single
1279
+ request; this effectively ignores the host_index
1280
+ in the spec for a single request.
1281
+ :type _host_index: int, optional
1282
+ :return: Returns the result object.
1283
+ """ # noqa: E501
1284
+
1285
+ _param = self._delete_group_serialize(
1286
+ id=id,
1287
+ _request_auth=_request_auth,
1288
+ _content_type=_content_type,
1289
+ _headers=_headers,
1290
+ _host_index=_host_index
1291
+ )
1292
+
1293
+ _response_types_map: Dict[str, Optional[str]] = {
1294
+ }
1295
+ response_data = self.api_client.call_api(
1296
+ *_param,
1297
+ _request_timeout=_request_timeout
1298
+ )
1299
+ response_data.read()
1300
+ return self.api_client.response_deserialize(
1301
+ response_data=response_data,
1302
+ response_types_map=_response_types_map,
1303
+ )
1304
+
1305
+
1306
+ @validate_call
1307
+ def delete_group_without_preload_content(
1308
+ self,
1309
+ id: Annotated[StrictStr, Field(description="Id of the group to delete")],
1310
+ _request_timeout: Union[
1311
+ None,
1312
+ Annotated[StrictFloat, Field(gt=0)],
1313
+ Tuple[
1314
+ Annotated[StrictFloat, Field(gt=0)],
1315
+ Annotated[StrictFloat, Field(gt=0)]
1316
+ ]
1317
+ ] = None,
1318
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1319
+ _content_type: Optional[StrictStr] = None,
1320
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1321
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1322
+ ) -> RESTResponseType:
1323
+ """Delete group
1324
+
1325
+ Delete the group data.
1326
+
1327
+ :param id: Id of the group to delete (required)
1328
+ :type id: str
1329
+ :param _request_timeout: timeout setting for this request. If one
1330
+ number provided, it will be total request
1331
+ timeout. It can also be a pair (tuple) of
1332
+ (connection, read) timeouts.
1333
+ :type _request_timeout: int, tuple(int, int), optional
1334
+ :param _request_auth: set to override the auth_settings for an a single
1335
+ request; this effectively ignores the
1336
+ authentication in the spec for a single request.
1337
+ :type _request_auth: dict, optional
1338
+ :param _content_type: force content-type for the request.
1339
+ :type _content_type: str, Optional
1340
+ :param _headers: set to override the headers for a single
1341
+ request; this effectively ignores the headers
1342
+ in the spec for a single request.
1343
+ :type _headers: dict, optional
1344
+ :param _host_index: set to override the host_index for a single
1345
+ request; this effectively ignores the host_index
1346
+ in the spec for a single request.
1347
+ :type _host_index: int, optional
1348
+ :return: Returns the result object.
1349
+ """ # noqa: E501
1350
+
1351
+ _param = self._delete_group_serialize(
1352
+ id=id,
1353
+ _request_auth=_request_auth,
1354
+ _content_type=_content_type,
1355
+ _headers=_headers,
1356
+ _host_index=_host_index
1357
+ )
1358
+
1359
+ _response_types_map: Dict[str, Optional[str]] = {
1360
+ }
1361
+ response_data = self.api_client.call_api(
1362
+ *_param,
1363
+ _request_timeout=_request_timeout
1364
+ )
1365
+ return response_data.response
1366
+
1367
+
1368
+ def _delete_group_serialize(
1369
+ self,
1370
+ id,
1371
+ _request_auth,
1372
+ _content_type,
1373
+ _headers,
1374
+ _host_index,
1375
+ ) -> RequestSerialized:
1376
+
1377
+ _host = None
1378
+
1379
+ _collection_formats: Dict[str, str] = {
1380
+ }
1381
+
1382
+ _path_params: Dict[str, str] = {}
1383
+ _query_params: List[Tuple[str, str]] = []
1384
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1385
+ _form_params: List[Tuple[str, str]] = []
1386
+ _files: Dict[
1387
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1388
+ ] = {}
1389
+ _body_params: Optional[bytes] = None
1390
+
1391
+ # process the path parameters
1392
+ if id is not None:
1393
+ _path_params['id'] = id
1394
+ # process the query parameters
1395
+ # process the header parameters
1396
+ # process the form parameters
1397
+ # process the body parameter
1398
+
1399
+
1400
+ # set the HTTP header `Accept`
1401
+ if 'Accept' not in _header_params:
1402
+ _header_params['Accept'] = self.api_client.select_header_accept(
1403
+ [
1404
+ 'application/json'
1405
+ ]
1406
+ )
1407
+
1408
+
1409
+ # authentication setting
1410
+ _auth_settings: List[str] = [
1411
+ 'ApiKeyAuth'
1412
+ ]
1413
+
1414
+ return self.api_client.param_serialize(
1415
+ method='DELETE',
1416
+ resource_path='/api/settings/rbac/groups/{id}',
1417
+ path_params=_path_params,
1418
+ query_params=_query_params,
1419
+ header_params=_header_params,
1420
+ body=_body_params,
1421
+ post_params=_form_params,
1422
+ files=_files,
1423
+ auth_settings=_auth_settings,
1424
+ collection_formats=_collection_formats,
1425
+ _host=_host,
1426
+ _request_auth=_request_auth
1427
+ )
1428
+
1429
+
1430
+
1431
+
1432
+ @validate_call
1433
+ def delete_group_mapping(
1434
+ self,
1435
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to delete")],
1436
+ _request_timeout: Union[
1437
+ None,
1438
+ Annotated[StrictFloat, Field(gt=0)],
1439
+ Tuple[
1440
+ Annotated[StrictFloat, Field(gt=0)],
1441
+ Annotated[StrictFloat, Field(gt=0)]
1442
+ ]
1443
+ ] = None,
1444
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1445
+ _content_type: Optional[StrictStr] = None,
1446
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1447
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1448
+ ) -> None:
1449
+ """Delete group mapping
1450
+
1451
+
1452
+ :param id: Id of the group mapping to delete (required)
1453
+ :type id: str
1454
+ :param _request_timeout: timeout setting for this request. If one
1455
+ number provided, it will be total request
1456
+ timeout. It can also be a pair (tuple) of
1457
+ (connection, read) timeouts.
1458
+ :type _request_timeout: int, tuple(int, int), optional
1459
+ :param _request_auth: set to override the auth_settings for an a single
1460
+ request; this effectively ignores the
1461
+ authentication in the spec for a single request.
1462
+ :type _request_auth: dict, optional
1463
+ :param _content_type: force content-type for the request.
1464
+ :type _content_type: str, Optional
1465
+ :param _headers: set to override the headers for a single
1466
+ request; this effectively ignores the headers
1467
+ in the spec for a single request.
1468
+ :type _headers: dict, optional
1469
+ :param _host_index: set to override the host_index for a single
1470
+ request; this effectively ignores the host_index
1471
+ in the spec for a single request.
1472
+ :type _host_index: int, optional
1473
+ :return: Returns the result object.
1474
+ """ # noqa: E501
1475
+
1476
+ _param = self._delete_group_mapping_serialize(
1477
+ id=id,
1478
+ _request_auth=_request_auth,
1479
+ _content_type=_content_type,
1480
+ _headers=_headers,
1481
+ _host_index=_host_index
1482
+ )
1483
+
1484
+ _response_types_map: Dict[str, Optional[str]] = {
1485
+ }
1486
+ response_data = self.api_client.call_api(
1487
+ *_param,
1488
+ _request_timeout=_request_timeout
1489
+ )
1490
+ response_data.read()
1491
+ return self.api_client.response_deserialize(
1492
+ response_data=response_data,
1493
+ response_types_map=_response_types_map,
1494
+ ).data
1495
+
1496
+
1497
+ @validate_call
1498
+ def delete_group_mapping_with_http_info(
1499
+ self,
1500
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to delete")],
1501
+ _request_timeout: Union[
1502
+ None,
1503
+ Annotated[StrictFloat, Field(gt=0)],
1504
+ Tuple[
1505
+ Annotated[StrictFloat, Field(gt=0)],
1506
+ Annotated[StrictFloat, Field(gt=0)]
1507
+ ]
1508
+ ] = None,
1509
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1510
+ _content_type: Optional[StrictStr] = None,
1511
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1512
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1513
+ ) -> ApiResponse[None]:
1514
+ """Delete group mapping
1515
+
1516
+
1517
+ :param id: Id of the group mapping to delete (required)
1518
+ :type id: str
1519
+ :param _request_timeout: timeout setting for this request. If one
1520
+ number provided, it will be total request
1521
+ timeout. It can also be a pair (tuple) of
1522
+ (connection, read) timeouts.
1523
+ :type _request_timeout: int, tuple(int, int), optional
1524
+ :param _request_auth: set to override the auth_settings for an a single
1525
+ request; this effectively ignores the
1526
+ authentication in the spec for a single request.
1527
+ :type _request_auth: dict, optional
1528
+ :param _content_type: force content-type for the request.
1529
+ :type _content_type: str, Optional
1530
+ :param _headers: set to override the headers for a single
1531
+ request; this effectively ignores the headers
1532
+ in the spec for a single request.
1533
+ :type _headers: dict, optional
1534
+ :param _host_index: set to override the host_index for a single
1535
+ request; this effectively ignores the host_index
1536
+ in the spec for a single request.
1537
+ :type _host_index: int, optional
1538
+ :return: Returns the result object.
1539
+ """ # noqa: E501
1540
+
1541
+ _param = self._delete_group_mapping_serialize(
1542
+ id=id,
1543
+ _request_auth=_request_auth,
1544
+ _content_type=_content_type,
1545
+ _headers=_headers,
1546
+ _host_index=_host_index
1547
+ )
1548
+
1549
+ _response_types_map: Dict[str, Optional[str]] = {
1550
+ }
1551
+ response_data = self.api_client.call_api(
1552
+ *_param,
1553
+ _request_timeout=_request_timeout
1554
+ )
1555
+ response_data.read()
1556
+ return self.api_client.response_deserialize(
1557
+ response_data=response_data,
1558
+ response_types_map=_response_types_map,
1559
+ )
1560
+
1561
+
1562
+ @validate_call
1563
+ def delete_group_mapping_without_preload_content(
1564
+ self,
1565
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to delete")],
1566
+ _request_timeout: Union[
1567
+ None,
1568
+ Annotated[StrictFloat, Field(gt=0)],
1569
+ Tuple[
1570
+ Annotated[StrictFloat, Field(gt=0)],
1571
+ Annotated[StrictFloat, Field(gt=0)]
1572
+ ]
1573
+ ] = None,
1574
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1575
+ _content_type: Optional[StrictStr] = None,
1576
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1577
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1578
+ ) -> RESTResponseType:
1579
+ """Delete group mapping
1580
+
1581
+
1582
+ :param id: Id of the group mapping to delete (required)
1583
+ :type id: str
1584
+ :param _request_timeout: timeout setting for this request. If one
1585
+ number provided, it will be total request
1586
+ timeout. It can also be a pair (tuple) of
1587
+ (connection, read) timeouts.
1588
+ :type _request_timeout: int, tuple(int, int), optional
1589
+ :param _request_auth: set to override the auth_settings for an a single
1590
+ request; this effectively ignores the
1591
+ authentication in the spec for a single request.
1592
+ :type _request_auth: dict, optional
1593
+ :param _content_type: force content-type for the request.
1594
+ :type _content_type: str, Optional
1595
+ :param _headers: set to override the headers for a single
1596
+ request; this effectively ignores the headers
1597
+ in the spec for a single request.
1598
+ :type _headers: dict, optional
1599
+ :param _host_index: set to override the host_index for a single
1600
+ request; this effectively ignores the host_index
1601
+ in the spec for a single request.
1602
+ :type _host_index: int, optional
1603
+ :return: Returns the result object.
1604
+ """ # noqa: E501
1605
+
1606
+ _param = self._delete_group_mapping_serialize(
1607
+ id=id,
1608
+ _request_auth=_request_auth,
1609
+ _content_type=_content_type,
1610
+ _headers=_headers,
1611
+ _host_index=_host_index
1612
+ )
1613
+
1614
+ _response_types_map: Dict[str, Optional[str]] = {
1615
+ }
1616
+ response_data = self.api_client.call_api(
1617
+ *_param,
1618
+ _request_timeout=_request_timeout
1619
+ )
1620
+ return response_data.response
1621
+
1622
+
1623
+ def _delete_group_mapping_serialize(
1624
+ self,
1625
+ id,
1626
+ _request_auth,
1627
+ _content_type,
1628
+ _headers,
1629
+ _host_index,
1630
+ ) -> RequestSerialized:
1631
+
1632
+ _host = None
1633
+
1634
+ _collection_formats: Dict[str, str] = {
1635
+ }
1636
+
1637
+ _path_params: Dict[str, str] = {}
1638
+ _query_params: List[Tuple[str, str]] = []
1639
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1640
+ _form_params: List[Tuple[str, str]] = []
1641
+ _files: Dict[
1642
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1643
+ ] = {}
1644
+ _body_params: Optional[bytes] = None
1645
+
1646
+ # process the path parameters
1647
+ if id is not None:
1648
+ _path_params['id'] = id
1649
+ # process the query parameters
1650
+ # process the header parameters
1651
+ # process the form parameters
1652
+ # process the body parameter
1653
+
1654
+
1655
+ # set the HTTP header `Accept`
1656
+ if 'Accept' not in _header_params:
1657
+ _header_params['Accept'] = self.api_client.select_header_accept(
1658
+ [
1659
+ 'application/json'
1660
+ ]
1661
+ )
1662
+
1663
+
1664
+ # authentication setting
1665
+ _auth_settings: List[str] = [
1666
+ 'ApiKeyAuth'
1667
+ ]
1668
+
1669
+ return self.api_client.param_serialize(
1670
+ method='DELETE',
1671
+ resource_path='/api/settings/rbac/mappings/{id}',
1672
+ path_params=_path_params,
1673
+ query_params=_query_params,
1674
+ header_params=_header_params,
1675
+ body=_body_params,
1676
+ post_params=_form_params,
1677
+ files=_files,
1678
+ auth_settings=_auth_settings,
1679
+ collection_formats=_collection_formats,
1680
+ _host=_host,
1681
+ _request_auth=_request_auth
1682
+ )
1683
+
1684
+
1685
+
1686
+
1687
+ @validate_call
1688
+ def get_group(
1689
+ self,
1690
+ id: Annotated[StrictStr, Field(description="Id of the group for retrieval")],
1691
+ _request_timeout: Union[
1692
+ None,
1693
+ Annotated[StrictFloat, Field(gt=0)],
1694
+ Tuple[
1695
+ Annotated[StrictFloat, Field(gt=0)],
1696
+ Annotated[StrictFloat, Field(gt=0)]
1697
+ ]
1698
+ ] = None,
1699
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1700
+ _content_type: Optional[StrictStr] = None,
1701
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1702
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1703
+ ) -> ApiGroup:
1704
+ """Get group
1705
+
1706
+ Returns group data, including the `Permission set`. See [get groups](#operation/getGroups) for more details.
1707
+
1708
+ :param id: Id of the group for retrieval (required)
1709
+ :type id: str
1710
+ :param _request_timeout: timeout setting for this request. If one
1711
+ number provided, it will be total request
1712
+ timeout. It can also be a pair (tuple) of
1713
+ (connection, read) timeouts.
1714
+ :type _request_timeout: int, tuple(int, int), optional
1715
+ :param _request_auth: set to override the auth_settings for an a single
1716
+ request; this effectively ignores the
1717
+ authentication in the spec for a single request.
1718
+ :type _request_auth: dict, optional
1719
+ :param _content_type: force content-type for the request.
1720
+ :type _content_type: str, Optional
1721
+ :param _headers: set to override the headers for a single
1722
+ request; this effectively ignores the headers
1723
+ in the spec for a single request.
1724
+ :type _headers: dict, optional
1725
+ :param _host_index: set to override the host_index for a single
1726
+ request; this effectively ignores the host_index
1727
+ in the spec for a single request.
1728
+ :type _host_index: int, optional
1729
+ :return: Returns the result object.
1730
+ """ # noqa: E501
1731
+
1732
+ _param = self._get_group_serialize(
1733
+ id=id,
1734
+ _request_auth=_request_auth,
1735
+ _content_type=_content_type,
1736
+ _headers=_headers,
1737
+ _host_index=_host_index
1738
+ )
1739
+
1740
+ _response_types_map: Dict[str, Optional[str]] = {
1741
+ '200': "ApiGroup",
1742
+ }
1743
+ response_data = self.api_client.call_api(
1744
+ *_param,
1745
+ _request_timeout=_request_timeout
1746
+ )
1747
+ response_data.read()
1748
+ return self.api_client.response_deserialize(
1749
+ response_data=response_data,
1750
+ response_types_map=_response_types_map,
1751
+ ).data
1752
+
1753
+
1754
+ @validate_call
1755
+ def get_group_with_http_info(
1756
+ self,
1757
+ id: Annotated[StrictStr, Field(description="Id of the group for retrieval")],
1758
+ _request_timeout: Union[
1759
+ None,
1760
+ Annotated[StrictFloat, Field(gt=0)],
1761
+ Tuple[
1762
+ Annotated[StrictFloat, Field(gt=0)],
1763
+ Annotated[StrictFloat, Field(gt=0)]
1764
+ ]
1765
+ ] = None,
1766
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1767
+ _content_type: Optional[StrictStr] = None,
1768
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1769
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1770
+ ) -> ApiResponse[ApiGroup]:
1771
+ """Get group
1772
+
1773
+ Returns group data, including the `Permission set`. See [get groups](#operation/getGroups) for more details.
1774
+
1775
+ :param id: Id of the group for retrieval (required)
1776
+ :type id: str
1777
+ :param _request_timeout: timeout setting for this request. If one
1778
+ number provided, it will be total request
1779
+ timeout. It can also be a pair (tuple) of
1780
+ (connection, read) timeouts.
1781
+ :type _request_timeout: int, tuple(int, int), optional
1782
+ :param _request_auth: set to override the auth_settings for an a single
1783
+ request; this effectively ignores the
1784
+ authentication in the spec for a single request.
1785
+ :type _request_auth: dict, optional
1786
+ :param _content_type: force content-type for the request.
1787
+ :type _content_type: str, Optional
1788
+ :param _headers: set to override the headers for a single
1789
+ request; this effectively ignores the headers
1790
+ in the spec for a single request.
1791
+ :type _headers: dict, optional
1792
+ :param _host_index: set to override the host_index for a single
1793
+ request; this effectively ignores the host_index
1794
+ in the spec for a single request.
1795
+ :type _host_index: int, optional
1796
+ :return: Returns the result object.
1797
+ """ # noqa: E501
1798
+
1799
+ _param = self._get_group_serialize(
1800
+ id=id,
1801
+ _request_auth=_request_auth,
1802
+ _content_type=_content_type,
1803
+ _headers=_headers,
1804
+ _host_index=_host_index
1805
+ )
1806
+
1807
+ _response_types_map: Dict[str, Optional[str]] = {
1808
+ '200': "ApiGroup",
1809
+ }
1810
+ response_data = self.api_client.call_api(
1811
+ *_param,
1812
+ _request_timeout=_request_timeout
1813
+ )
1814
+ response_data.read()
1815
+ return self.api_client.response_deserialize(
1816
+ response_data=response_data,
1817
+ response_types_map=_response_types_map,
1818
+ )
1819
+
1820
+
1821
+ @validate_call
1822
+ def get_group_without_preload_content(
1823
+ self,
1824
+ id: Annotated[StrictStr, Field(description="Id of the group for retrieval")],
1825
+ _request_timeout: Union[
1826
+ None,
1827
+ Annotated[StrictFloat, Field(gt=0)],
1828
+ Tuple[
1829
+ Annotated[StrictFloat, Field(gt=0)],
1830
+ Annotated[StrictFloat, Field(gt=0)]
1831
+ ]
1832
+ ] = None,
1833
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1834
+ _content_type: Optional[StrictStr] = None,
1835
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1836
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1837
+ ) -> RESTResponseType:
1838
+ """Get group
1839
+
1840
+ Returns group data, including the `Permission set`. See [get groups](#operation/getGroups) for more details.
1841
+
1842
+ :param id: Id of the group for retrieval (required)
1843
+ :type id: str
1844
+ :param _request_timeout: timeout setting for this request. If one
1845
+ number provided, it will be total request
1846
+ timeout. It can also be a pair (tuple) of
1847
+ (connection, read) timeouts.
1848
+ :type _request_timeout: int, tuple(int, int), optional
1849
+ :param _request_auth: set to override the auth_settings for an a single
1850
+ request; this effectively ignores the
1851
+ authentication in the spec for a single request.
1852
+ :type _request_auth: dict, optional
1853
+ :param _content_type: force content-type for the request.
1854
+ :type _content_type: str, Optional
1855
+ :param _headers: set to override the headers for a single
1856
+ request; this effectively ignores the headers
1857
+ in the spec for a single request.
1858
+ :type _headers: dict, optional
1859
+ :param _host_index: set to override the host_index for a single
1860
+ request; this effectively ignores the host_index
1861
+ in the spec for a single request.
1862
+ :type _host_index: int, optional
1863
+ :return: Returns the result object.
1864
+ """ # noqa: E501
1865
+
1866
+ _param = self._get_group_serialize(
1867
+ id=id,
1868
+ _request_auth=_request_auth,
1869
+ _content_type=_content_type,
1870
+ _headers=_headers,
1871
+ _host_index=_host_index
1872
+ )
1873
+
1874
+ _response_types_map: Dict[str, Optional[str]] = {
1875
+ '200': "ApiGroup",
1876
+ }
1877
+ response_data = self.api_client.call_api(
1878
+ *_param,
1879
+ _request_timeout=_request_timeout
1880
+ )
1881
+ return response_data.response
1882
+
1883
+
1884
+ def _get_group_serialize(
1885
+ self,
1886
+ id,
1887
+ _request_auth,
1888
+ _content_type,
1889
+ _headers,
1890
+ _host_index,
1891
+ ) -> RequestSerialized:
1892
+
1893
+ _host = None
1894
+
1895
+ _collection_formats: Dict[str, str] = {
1896
+ }
1897
+
1898
+ _path_params: Dict[str, str] = {}
1899
+ _query_params: List[Tuple[str, str]] = []
1900
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1901
+ _form_params: List[Tuple[str, str]] = []
1902
+ _files: Dict[
1903
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1904
+ ] = {}
1905
+ _body_params: Optional[bytes] = None
1906
+
1907
+ # process the path parameters
1908
+ if id is not None:
1909
+ _path_params['id'] = id
1910
+ # process the query parameters
1911
+ # process the header parameters
1912
+ # process the form parameters
1913
+ # process the body parameter
1914
+
1915
+
1916
+ # set the HTTP header `Accept`
1917
+ if 'Accept' not in _header_params:
1918
+ _header_params['Accept'] = self.api_client.select_header_accept(
1919
+ [
1920
+ 'application/json'
1921
+ ]
1922
+ )
1923
+
1924
+
1925
+ # authentication setting
1926
+ _auth_settings: List[str] = [
1927
+ 'ApiKeyAuth'
1928
+ ]
1929
+
1930
+ return self.api_client.param_serialize(
1931
+ method='GET',
1932
+ resource_path='/api/settings/rbac/groups/{id}',
1933
+ path_params=_path_params,
1934
+ query_params=_query_params,
1935
+ header_params=_header_params,
1936
+ body=_body_params,
1937
+ post_params=_form_params,
1938
+ files=_files,
1939
+ auth_settings=_auth_settings,
1940
+ collection_formats=_collection_formats,
1941
+ _host=_host,
1942
+ _request_auth=_request_auth
1943
+ )
1944
+
1945
+
1946
+
1947
+
1948
+ @validate_call
1949
+ def get_group_mappings(
1950
+ self,
1951
+ _request_timeout: Union[
1952
+ None,
1953
+ Annotated[StrictFloat, Field(gt=0)],
1954
+ Tuple[
1955
+ Annotated[StrictFloat, Field(gt=0)],
1956
+ Annotated[StrictFloat, Field(gt=0)]
1957
+ ]
1958
+ ] = None,
1959
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1960
+ _content_type: Optional[StrictStr] = None,
1961
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1962
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1963
+ ) -> List[GroupMapping]:
1964
+ """Get all group mappings
1965
+
1966
+ If mappings between groups on the identity provider (LDAP, OIDC, SAML) and Instana groups where configured, this will return a list of those mappings. This can be configured through the [api](#operation/createGroupMapping) or on Instana graphical user interface at Settings > Authentication > IDENTITY PROVIDERS > Group Mapping.
1967
+
1968
+ :param _request_timeout: timeout setting for this request. If one
1969
+ number provided, it will be total request
1970
+ timeout. It can also be a pair (tuple) of
1971
+ (connection, read) timeouts.
1972
+ :type _request_timeout: int, tuple(int, int), optional
1973
+ :param _request_auth: set to override the auth_settings for an a single
1974
+ request; this effectively ignores the
1975
+ authentication in the spec for a single request.
1976
+ :type _request_auth: dict, optional
1977
+ :param _content_type: force content-type for the request.
1978
+ :type _content_type: str, Optional
1979
+ :param _headers: set to override the headers for a single
1980
+ request; this effectively ignores the headers
1981
+ in the spec for a single request.
1982
+ :type _headers: dict, optional
1983
+ :param _host_index: set to override the host_index for a single
1984
+ request; this effectively ignores the host_index
1985
+ in the spec for a single request.
1986
+ :type _host_index: int, optional
1987
+ :return: Returns the result object.
1988
+ """ # noqa: E501
1989
+
1990
+ _param = self._get_group_mappings_serialize(
1991
+ _request_auth=_request_auth,
1992
+ _content_type=_content_type,
1993
+ _headers=_headers,
1994
+ _host_index=_host_index
1995
+ )
1996
+
1997
+ _response_types_map: Dict[str, Optional[str]] = {
1998
+ '200': "List[GroupMapping]",
1999
+ '404': None,
2000
+ }
2001
+ response_data = self.api_client.call_api(
2002
+ *_param,
2003
+ _request_timeout=_request_timeout
2004
+ )
2005
+ response_data.read()
2006
+ return self.api_client.response_deserialize(
2007
+ response_data=response_data,
2008
+ response_types_map=_response_types_map,
2009
+ ).data
2010
+
2011
+
2012
+ @validate_call
2013
+ def get_group_mappings_with_http_info(
2014
+ self,
2015
+ _request_timeout: Union[
2016
+ None,
2017
+ Annotated[StrictFloat, Field(gt=0)],
2018
+ Tuple[
2019
+ Annotated[StrictFloat, Field(gt=0)],
2020
+ Annotated[StrictFloat, Field(gt=0)]
2021
+ ]
2022
+ ] = None,
2023
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2024
+ _content_type: Optional[StrictStr] = None,
2025
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2026
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2027
+ ) -> ApiResponse[List[GroupMapping]]:
2028
+ """Get all group mappings
2029
+
2030
+ If mappings between groups on the identity provider (LDAP, OIDC, SAML) and Instana groups where configured, this will return a list of those mappings. This can be configured through the [api](#operation/createGroupMapping) or on Instana graphical user interface at Settings > Authentication > IDENTITY PROVIDERS > Group Mapping.
2031
+
2032
+ :param _request_timeout: timeout setting for this request. If one
2033
+ number provided, it will be total request
2034
+ timeout. It can also be a pair (tuple) of
2035
+ (connection, read) timeouts.
2036
+ :type _request_timeout: int, tuple(int, int), optional
2037
+ :param _request_auth: set to override the auth_settings for an a single
2038
+ request; this effectively ignores the
2039
+ authentication in the spec for a single request.
2040
+ :type _request_auth: dict, optional
2041
+ :param _content_type: force content-type for the request.
2042
+ :type _content_type: str, Optional
2043
+ :param _headers: set to override the headers for a single
2044
+ request; this effectively ignores the headers
2045
+ in the spec for a single request.
2046
+ :type _headers: dict, optional
2047
+ :param _host_index: set to override the host_index for a single
2048
+ request; this effectively ignores the host_index
2049
+ in the spec for a single request.
2050
+ :type _host_index: int, optional
2051
+ :return: Returns the result object.
2052
+ """ # noqa: E501
2053
+
2054
+ _param = self._get_group_mappings_serialize(
2055
+ _request_auth=_request_auth,
2056
+ _content_type=_content_type,
2057
+ _headers=_headers,
2058
+ _host_index=_host_index
2059
+ )
2060
+
2061
+ _response_types_map: Dict[str, Optional[str]] = {
2062
+ '200': "List[GroupMapping]",
2063
+ '404': None,
2064
+ }
2065
+ response_data = self.api_client.call_api(
2066
+ *_param,
2067
+ _request_timeout=_request_timeout
2068
+ )
2069
+ response_data.read()
2070
+ return self.api_client.response_deserialize(
2071
+ response_data=response_data,
2072
+ response_types_map=_response_types_map,
2073
+ )
2074
+
2075
+
2076
+ @validate_call
2077
+ def get_group_mappings_without_preload_content(
2078
+ self,
2079
+ _request_timeout: Union[
2080
+ None,
2081
+ Annotated[StrictFloat, Field(gt=0)],
2082
+ Tuple[
2083
+ Annotated[StrictFloat, Field(gt=0)],
2084
+ Annotated[StrictFloat, Field(gt=0)]
2085
+ ]
2086
+ ] = None,
2087
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2088
+ _content_type: Optional[StrictStr] = None,
2089
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2090
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2091
+ ) -> RESTResponseType:
2092
+ """Get all group mappings
2093
+
2094
+ If mappings between groups on the identity provider (LDAP, OIDC, SAML) and Instana groups where configured, this will return a list of those mappings. This can be configured through the [api](#operation/createGroupMapping) or on Instana graphical user interface at Settings > Authentication > IDENTITY PROVIDERS > Group Mapping.
2095
+
2096
+ :param _request_timeout: timeout setting for this request. If one
2097
+ number provided, it will be total request
2098
+ timeout. It can also be a pair (tuple) of
2099
+ (connection, read) timeouts.
2100
+ :type _request_timeout: int, tuple(int, int), optional
2101
+ :param _request_auth: set to override the auth_settings for an a single
2102
+ request; this effectively ignores the
2103
+ authentication in the spec for a single request.
2104
+ :type _request_auth: dict, optional
2105
+ :param _content_type: force content-type for the request.
2106
+ :type _content_type: str, Optional
2107
+ :param _headers: set to override the headers for a single
2108
+ request; this effectively ignores the headers
2109
+ in the spec for a single request.
2110
+ :type _headers: dict, optional
2111
+ :param _host_index: set to override the host_index for a single
2112
+ request; this effectively ignores the host_index
2113
+ in the spec for a single request.
2114
+ :type _host_index: int, optional
2115
+ :return: Returns the result object.
2116
+ """ # noqa: E501
2117
+
2118
+ _param = self._get_group_mappings_serialize(
2119
+ _request_auth=_request_auth,
2120
+ _content_type=_content_type,
2121
+ _headers=_headers,
2122
+ _host_index=_host_index
2123
+ )
2124
+
2125
+ _response_types_map: Dict[str, Optional[str]] = {
2126
+ '200': "List[GroupMapping]",
2127
+ '404': None,
2128
+ }
2129
+ response_data = self.api_client.call_api(
2130
+ *_param,
2131
+ _request_timeout=_request_timeout
2132
+ )
2133
+ return response_data.response
2134
+
2135
+
2136
+ def _get_group_mappings_serialize(
2137
+ self,
2138
+ _request_auth,
2139
+ _content_type,
2140
+ _headers,
2141
+ _host_index,
2142
+ ) -> RequestSerialized:
2143
+
2144
+ _host = None
2145
+
2146
+ _collection_formats: Dict[str, str] = {
2147
+ }
2148
+
2149
+ _path_params: Dict[str, str] = {}
2150
+ _query_params: List[Tuple[str, str]] = []
2151
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2152
+ _form_params: List[Tuple[str, str]] = []
2153
+ _files: Dict[
2154
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2155
+ ] = {}
2156
+ _body_params: Optional[bytes] = None
2157
+
2158
+ # process the path parameters
2159
+ # process the query parameters
2160
+ # process the header parameters
2161
+ # process the form parameters
2162
+ # process the body parameter
2163
+
2164
+
2165
+ # set the HTTP header `Accept`
2166
+ if 'Accept' not in _header_params:
2167
+ _header_params['Accept'] = self.api_client.select_header_accept(
2168
+ [
2169
+ 'application/json'
2170
+ ]
2171
+ )
2172
+
2173
+
2174
+ # authentication setting
2175
+ _auth_settings: List[str] = [
2176
+ 'ApiKeyAuth'
2177
+ ]
2178
+
2179
+ return self.api_client.param_serialize(
2180
+ method='GET',
2181
+ resource_path='/api/settings/rbac/mappings',
2182
+ path_params=_path_params,
2183
+ query_params=_query_params,
2184
+ header_params=_header_params,
2185
+ body=_body_params,
2186
+ post_params=_form_params,
2187
+ files=_files,
2188
+ auth_settings=_auth_settings,
2189
+ collection_formats=_collection_formats,
2190
+ _host=_host,
2191
+ _request_auth=_request_auth
2192
+ )
2193
+
2194
+
2195
+
2196
+
2197
+ @validate_call
2198
+ def get_groups(
2199
+ self,
2200
+ _request_timeout: Union[
2201
+ None,
2202
+ Annotated[StrictFloat, Field(gt=0)],
2203
+ Tuple[
2204
+ Annotated[StrictFloat, Field(gt=0)],
2205
+ Annotated[StrictFloat, Field(gt=0)]
2206
+ ]
2207
+ ] = None,
2208
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2209
+ _content_type: Optional[StrictStr] = None,
2210
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2211
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2212
+ ) -> List[ApiGroup]:
2213
+ """Get groups
2214
+
2215
+ Retrieve the list of all groups on the tenant together with the `Permission Set` for the tenant unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. The areas are included inside the `permissionSet`. The scopeRoleId is a fixed value for each area type: | Area | value | | ----------------------- | ------------- | | applicationIds | -100 | | kubernetesClusterUUIDs | -200 | | kubernetesNamespaceUIDs | -300 | | websiteIds | -400 | | mobileAppIds | -500 | | infraDfqFilter | -600 | For example: ``` [ { \"id\": \"7hwdhtt7TU2CJDgYXgwwww\", \"name\": \"Scoped Group\", \"members\": [ { \"userId\": \"61892cfdfcffab03016b2950\", \"email\": \"jhon@example.com\" } ], \"permissionSet\": { \"permissions\": [ \"CAN_VIEW_LOGS\", \"CAN_VIEW_TRACE_DETAILS\", \"CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS\", \"ACCESS_APPLICATIONS\", \"LIMITED_APPLICATIONS_SCOPE\", \"ACCESS_KUBERNETES\", \"LIMITED_KUBERNETES_SCOPE\", \"ACCESS_INFRASTRUCTURE_APPS\", \"LIMITED_INFRASTRUCTURE_SCOPE\", \"LIMITED_WEBSITES_SCOPE\", ], \"applicationIds\": [ { \"scopeId\": \"1qvWgVfLTNqi9gGTcCaNUw\", \"scopeRoleId\": \"-100\" } ], \"kubernetesClusterUUIDs\": [ { \"scopeId\": \"induced\", \"scopeRoleId\": \"-200\" } ], \"kubernetesNamespaceUIDs\": [], \"websiteIds\": [], \"mobileAppIds\": [], \"infraDfqFilter\": { \"scopeId\": \"production\", \"scopeRoleId\": \"-600\" } } ] ``` In this case `Scoped Group` has no access to websites due to having `LIMITED_WEBSITES_SCOPE` but not `ACCESS_WEBSITES`. Also due to having `LIMITED_APPLICATIONS_SCOPE`, the only visible application is the one with this id: `1qvWgVfLTNqi9gGTcCaNUw`. Same applies to `kubernetesClusterUUIDs`, `kubernetesNamespaceUIDs` and `infraDfqFilter`, with the only difference is that `infraDfqFilter` uses a filter \"production\" instead of an id.
2216
+
2217
+ :param _request_timeout: timeout setting for this request. If one
2218
+ number provided, it will be total request
2219
+ timeout. It can also be a pair (tuple) of
2220
+ (connection, read) timeouts.
2221
+ :type _request_timeout: int, tuple(int, int), optional
2222
+ :param _request_auth: set to override the auth_settings for an a single
2223
+ request; this effectively ignores the
2224
+ authentication in the spec for a single request.
2225
+ :type _request_auth: dict, optional
2226
+ :param _content_type: force content-type for the request.
2227
+ :type _content_type: str, Optional
2228
+ :param _headers: set to override the headers for a single
2229
+ request; this effectively ignores the headers
2230
+ in the spec for a single request.
2231
+ :type _headers: dict, optional
2232
+ :param _host_index: set to override the host_index for a single
2233
+ request; this effectively ignores the host_index
2234
+ in the spec for a single request.
2235
+ :type _host_index: int, optional
2236
+ :return: Returns the result object.
2237
+ """ # noqa: E501
2238
+
2239
+ _param = self._get_groups_serialize(
2240
+ _request_auth=_request_auth,
2241
+ _content_type=_content_type,
2242
+ _headers=_headers,
2243
+ _host_index=_host_index
2244
+ )
2245
+
2246
+ _response_types_map: Dict[str, Optional[str]] = {
2247
+ '200': "List[ApiGroup]",
2248
+ '404': None,
2249
+ }
2250
+ response_data = self.api_client.call_api(
2251
+ *_param,
2252
+ _request_timeout=_request_timeout
2253
+ )
2254
+ response_data.read()
2255
+ return self.api_client.response_deserialize(
2256
+ response_data=response_data,
2257
+ response_types_map=_response_types_map,
2258
+ ).data
2259
+
2260
+
2261
+ @validate_call
2262
+ def get_groups_with_http_info(
2263
+ self,
2264
+ _request_timeout: Union[
2265
+ None,
2266
+ Annotated[StrictFloat, Field(gt=0)],
2267
+ Tuple[
2268
+ Annotated[StrictFloat, Field(gt=0)],
2269
+ Annotated[StrictFloat, Field(gt=0)]
2270
+ ]
2271
+ ] = None,
2272
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2273
+ _content_type: Optional[StrictStr] = None,
2274
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2275
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2276
+ ) -> ApiResponse[List[ApiGroup]]:
2277
+ """Get groups
2278
+
2279
+ Retrieve the list of all groups on the tenant together with the `Permission Set` for the tenant unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. The areas are included inside the `permissionSet`. The scopeRoleId is a fixed value for each area type: | Area | value | | ----------------------- | ------------- | | applicationIds | -100 | | kubernetesClusterUUIDs | -200 | | kubernetesNamespaceUIDs | -300 | | websiteIds | -400 | | mobileAppIds | -500 | | infraDfqFilter | -600 | For example: ``` [ { \"id\": \"7hwdhtt7TU2CJDgYXgwwww\", \"name\": \"Scoped Group\", \"members\": [ { \"userId\": \"61892cfdfcffab03016b2950\", \"email\": \"jhon@example.com\" } ], \"permissionSet\": { \"permissions\": [ \"CAN_VIEW_LOGS\", \"CAN_VIEW_TRACE_DETAILS\", \"CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS\", \"ACCESS_APPLICATIONS\", \"LIMITED_APPLICATIONS_SCOPE\", \"ACCESS_KUBERNETES\", \"LIMITED_KUBERNETES_SCOPE\", \"ACCESS_INFRASTRUCTURE_APPS\", \"LIMITED_INFRASTRUCTURE_SCOPE\", \"LIMITED_WEBSITES_SCOPE\", ], \"applicationIds\": [ { \"scopeId\": \"1qvWgVfLTNqi9gGTcCaNUw\", \"scopeRoleId\": \"-100\" } ], \"kubernetesClusterUUIDs\": [ { \"scopeId\": \"induced\", \"scopeRoleId\": \"-200\" } ], \"kubernetesNamespaceUIDs\": [], \"websiteIds\": [], \"mobileAppIds\": [], \"infraDfqFilter\": { \"scopeId\": \"production\", \"scopeRoleId\": \"-600\" } } ] ``` In this case `Scoped Group` has no access to websites due to having `LIMITED_WEBSITES_SCOPE` but not `ACCESS_WEBSITES`. Also due to having `LIMITED_APPLICATIONS_SCOPE`, the only visible application is the one with this id: `1qvWgVfLTNqi9gGTcCaNUw`. Same applies to `kubernetesClusterUUIDs`, `kubernetesNamespaceUIDs` and `infraDfqFilter`, with the only difference is that `infraDfqFilter` uses a filter \"production\" instead of an id.
2280
+
2281
+ :param _request_timeout: timeout setting for this request. If one
2282
+ number provided, it will be total request
2283
+ timeout. It can also be a pair (tuple) of
2284
+ (connection, read) timeouts.
2285
+ :type _request_timeout: int, tuple(int, int), optional
2286
+ :param _request_auth: set to override the auth_settings for an a single
2287
+ request; this effectively ignores the
2288
+ authentication in the spec for a single request.
2289
+ :type _request_auth: dict, optional
2290
+ :param _content_type: force content-type for the request.
2291
+ :type _content_type: str, Optional
2292
+ :param _headers: set to override the headers for a single
2293
+ request; this effectively ignores the headers
2294
+ in the spec for a single request.
2295
+ :type _headers: dict, optional
2296
+ :param _host_index: set to override the host_index for a single
2297
+ request; this effectively ignores the host_index
2298
+ in the spec for a single request.
2299
+ :type _host_index: int, optional
2300
+ :return: Returns the result object.
2301
+ """ # noqa: E501
2302
+
2303
+ _param = self._get_groups_serialize(
2304
+ _request_auth=_request_auth,
2305
+ _content_type=_content_type,
2306
+ _headers=_headers,
2307
+ _host_index=_host_index
2308
+ )
2309
+
2310
+ _response_types_map: Dict[str, Optional[str]] = {
2311
+ '200': "List[ApiGroup]",
2312
+ '404': None,
2313
+ }
2314
+ response_data = self.api_client.call_api(
2315
+ *_param,
2316
+ _request_timeout=_request_timeout
2317
+ )
2318
+ response_data.read()
2319
+ return self.api_client.response_deserialize(
2320
+ response_data=response_data,
2321
+ response_types_map=_response_types_map,
2322
+ )
2323
+
2324
+
2325
+ @validate_call
2326
+ def get_groups_without_preload_content(
2327
+ self,
2328
+ _request_timeout: Union[
2329
+ None,
2330
+ Annotated[StrictFloat, Field(gt=0)],
2331
+ Tuple[
2332
+ Annotated[StrictFloat, Field(gt=0)],
2333
+ Annotated[StrictFloat, Field(gt=0)]
2334
+ ]
2335
+ ] = None,
2336
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2337
+ _content_type: Optional[StrictStr] = None,
2338
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2339
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2340
+ ) -> RESTResponseType:
2341
+ """Get groups
2342
+
2343
+ Retrieve the list of all groups on the tenant together with the `Permission Set` for the tenant unit. The `Permission Set` object contains a set of permissions applied to the group. In case `permissions` include the entry e.g. `LIMITED_APPLICATIONS_SCOPE`, this group will have limited access to application area. The areas are included inside the `permissionSet`. The scopeRoleId is a fixed value for each area type: | Area | value | | ----------------------- | ------------- | | applicationIds | -100 | | kubernetesClusterUUIDs | -200 | | kubernetesNamespaceUIDs | -300 | | websiteIds | -400 | | mobileAppIds | -500 | | infraDfqFilter | -600 | For example: ``` [ { \"id\": \"7hwdhtt7TU2CJDgYXgwwww\", \"name\": \"Scoped Group\", \"members\": [ { \"userId\": \"61892cfdfcffab03016b2950\", \"email\": \"jhon@example.com\" } ], \"permissionSet\": { \"permissions\": [ \"CAN_VIEW_LOGS\", \"CAN_VIEW_TRACE_DETAILS\", \"CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS\", \"ACCESS_APPLICATIONS\", \"LIMITED_APPLICATIONS_SCOPE\", \"ACCESS_KUBERNETES\", \"LIMITED_KUBERNETES_SCOPE\", \"ACCESS_INFRASTRUCTURE_APPS\", \"LIMITED_INFRASTRUCTURE_SCOPE\", \"LIMITED_WEBSITES_SCOPE\", ], \"applicationIds\": [ { \"scopeId\": \"1qvWgVfLTNqi9gGTcCaNUw\", \"scopeRoleId\": \"-100\" } ], \"kubernetesClusterUUIDs\": [ { \"scopeId\": \"induced\", \"scopeRoleId\": \"-200\" } ], \"kubernetesNamespaceUIDs\": [], \"websiteIds\": [], \"mobileAppIds\": [], \"infraDfqFilter\": { \"scopeId\": \"production\", \"scopeRoleId\": \"-600\" } } ] ``` In this case `Scoped Group` has no access to websites due to having `LIMITED_WEBSITES_SCOPE` but not `ACCESS_WEBSITES`. Also due to having `LIMITED_APPLICATIONS_SCOPE`, the only visible application is the one with this id: `1qvWgVfLTNqi9gGTcCaNUw`. Same applies to `kubernetesClusterUUIDs`, `kubernetesNamespaceUIDs` and `infraDfqFilter`, with the only difference is that `infraDfqFilter` uses a filter \"production\" instead of an id.
2344
+
2345
+ :param _request_timeout: timeout setting for this request. If one
2346
+ number provided, it will be total request
2347
+ timeout. It can also be a pair (tuple) of
2348
+ (connection, read) timeouts.
2349
+ :type _request_timeout: int, tuple(int, int), optional
2350
+ :param _request_auth: set to override the auth_settings for an a single
2351
+ request; this effectively ignores the
2352
+ authentication in the spec for a single request.
2353
+ :type _request_auth: dict, optional
2354
+ :param _content_type: force content-type for the request.
2355
+ :type _content_type: str, Optional
2356
+ :param _headers: set to override the headers for a single
2357
+ request; this effectively ignores the headers
2358
+ in the spec for a single request.
2359
+ :type _headers: dict, optional
2360
+ :param _host_index: set to override the host_index for a single
2361
+ request; this effectively ignores the host_index
2362
+ in the spec for a single request.
2363
+ :type _host_index: int, optional
2364
+ :return: Returns the result object.
2365
+ """ # noqa: E501
2366
+
2367
+ _param = self._get_groups_serialize(
2368
+ _request_auth=_request_auth,
2369
+ _content_type=_content_type,
2370
+ _headers=_headers,
2371
+ _host_index=_host_index
2372
+ )
2373
+
2374
+ _response_types_map: Dict[str, Optional[str]] = {
2375
+ '200': "List[ApiGroup]",
2376
+ '404': None,
2377
+ }
2378
+ response_data = self.api_client.call_api(
2379
+ *_param,
2380
+ _request_timeout=_request_timeout
2381
+ )
2382
+ return response_data.response
2383
+
2384
+
2385
+ def _get_groups_serialize(
2386
+ self,
2387
+ _request_auth,
2388
+ _content_type,
2389
+ _headers,
2390
+ _host_index,
2391
+ ) -> RequestSerialized:
2392
+
2393
+ _host = None
2394
+
2395
+ _collection_formats: Dict[str, str] = {
2396
+ }
2397
+
2398
+ _path_params: Dict[str, str] = {}
2399
+ _query_params: List[Tuple[str, str]] = []
2400
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2401
+ _form_params: List[Tuple[str, str]] = []
2402
+ _files: Dict[
2403
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2404
+ ] = {}
2405
+ _body_params: Optional[bytes] = None
2406
+
2407
+ # process the path parameters
2408
+ # process the query parameters
2409
+ # process the header parameters
2410
+ # process the form parameters
2411
+ # process the body parameter
2412
+
2413
+
2414
+ # set the HTTP header `Accept`
2415
+ if 'Accept' not in _header_params:
2416
+ _header_params['Accept'] = self.api_client.select_header_accept(
2417
+ [
2418
+ 'application/json'
2419
+ ]
2420
+ )
2421
+
2422
+
2423
+ # authentication setting
2424
+ _auth_settings: List[str] = [
2425
+ 'ApiKeyAuth'
2426
+ ]
2427
+
2428
+ return self.api_client.param_serialize(
2429
+ method='GET',
2430
+ resource_path='/api/settings/rbac/groups',
2431
+ path_params=_path_params,
2432
+ query_params=_query_params,
2433
+ header_params=_header_params,
2434
+ body=_body_params,
2435
+ post_params=_form_params,
2436
+ files=_files,
2437
+ auth_settings=_auth_settings,
2438
+ collection_formats=_collection_formats,
2439
+ _host=_host,
2440
+ _request_auth=_request_auth
2441
+ )
2442
+
2443
+
2444
+
2445
+
2446
+ @validate_call
2447
+ def get_groups_by_user(
2448
+ self,
2449
+ email: Annotated[StrictStr, Field(description="Email of the user for retrieval")],
2450
+ _request_timeout: Union[
2451
+ None,
2452
+ Annotated[StrictFloat, Field(gt=0)],
2453
+ Tuple[
2454
+ Annotated[StrictFloat, Field(gt=0)],
2455
+ Annotated[StrictFloat, Field(gt=0)]
2456
+ ]
2457
+ ] = None,
2458
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2459
+ _content_type: Optional[StrictStr] = None,
2460
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2461
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2462
+ ) -> List[ApiGroup]:
2463
+ """Get groups of a single user
2464
+
2465
+ Returns a list of all groups a user belongs to. This includes data from these groups, the `members`, the `name` and the `Permission set`.
2466
+
2467
+ :param email: Email of the user for retrieval (required)
2468
+ :type email: str
2469
+ :param _request_timeout: timeout setting for this request. If one
2470
+ number provided, it will be total request
2471
+ timeout. It can also be a pair (tuple) of
2472
+ (connection, read) timeouts.
2473
+ :type _request_timeout: int, tuple(int, int), optional
2474
+ :param _request_auth: set to override the auth_settings for an a single
2475
+ request; this effectively ignores the
2476
+ authentication in the spec for a single request.
2477
+ :type _request_auth: dict, optional
2478
+ :param _content_type: force content-type for the request.
2479
+ :type _content_type: str, Optional
2480
+ :param _headers: set to override the headers for a single
2481
+ request; this effectively ignores the headers
2482
+ in the spec for a single request.
2483
+ :type _headers: dict, optional
2484
+ :param _host_index: set to override the host_index for a single
2485
+ request; this effectively ignores the host_index
2486
+ in the spec for a single request.
2487
+ :type _host_index: int, optional
2488
+ :return: Returns the result object.
2489
+ """ # noqa: E501
2490
+
2491
+ _param = self._get_groups_by_user_serialize(
2492
+ email=email,
2493
+ _request_auth=_request_auth,
2494
+ _content_type=_content_type,
2495
+ _headers=_headers,
2496
+ _host_index=_host_index
2497
+ )
2498
+
2499
+ _response_types_map: Dict[str, Optional[str]] = {
2500
+ '200': "List[ApiGroup]",
2501
+ '404': None,
2502
+ }
2503
+ response_data = self.api_client.call_api(
2504
+ *_param,
2505
+ _request_timeout=_request_timeout
2506
+ )
2507
+ response_data.read()
2508
+ return self.api_client.response_deserialize(
2509
+ response_data=response_data,
2510
+ response_types_map=_response_types_map,
2511
+ ).data
2512
+
2513
+
2514
+ @validate_call
2515
+ def get_groups_by_user_with_http_info(
2516
+ self,
2517
+ email: Annotated[StrictStr, Field(description="Email of the user for retrieval")],
2518
+ _request_timeout: Union[
2519
+ None,
2520
+ Annotated[StrictFloat, Field(gt=0)],
2521
+ Tuple[
2522
+ Annotated[StrictFloat, Field(gt=0)],
2523
+ Annotated[StrictFloat, Field(gt=0)]
2524
+ ]
2525
+ ] = None,
2526
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2527
+ _content_type: Optional[StrictStr] = None,
2528
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2529
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2530
+ ) -> ApiResponse[List[ApiGroup]]:
2531
+ """Get groups of a single user
2532
+
2533
+ Returns a list of all groups a user belongs to. This includes data from these groups, the `members`, the `name` and the `Permission set`.
2534
+
2535
+ :param email: Email of the user for retrieval (required)
2536
+ :type email: str
2537
+ :param _request_timeout: timeout setting for this request. If one
2538
+ number provided, it will be total request
2539
+ timeout. It can also be a pair (tuple) of
2540
+ (connection, read) timeouts.
2541
+ :type _request_timeout: int, tuple(int, int), optional
2542
+ :param _request_auth: set to override the auth_settings for an a single
2543
+ request; this effectively ignores the
2544
+ authentication in the spec for a single request.
2545
+ :type _request_auth: dict, optional
2546
+ :param _content_type: force content-type for the request.
2547
+ :type _content_type: str, Optional
2548
+ :param _headers: set to override the headers for a single
2549
+ request; this effectively ignores the headers
2550
+ in the spec for a single request.
2551
+ :type _headers: dict, optional
2552
+ :param _host_index: set to override the host_index for a single
2553
+ request; this effectively ignores the host_index
2554
+ in the spec for a single request.
2555
+ :type _host_index: int, optional
2556
+ :return: Returns the result object.
2557
+ """ # noqa: E501
2558
+
2559
+ _param = self._get_groups_by_user_serialize(
2560
+ email=email,
2561
+ _request_auth=_request_auth,
2562
+ _content_type=_content_type,
2563
+ _headers=_headers,
2564
+ _host_index=_host_index
2565
+ )
2566
+
2567
+ _response_types_map: Dict[str, Optional[str]] = {
2568
+ '200': "List[ApiGroup]",
2569
+ '404': None,
2570
+ }
2571
+ response_data = self.api_client.call_api(
2572
+ *_param,
2573
+ _request_timeout=_request_timeout
2574
+ )
2575
+ response_data.read()
2576
+ return self.api_client.response_deserialize(
2577
+ response_data=response_data,
2578
+ response_types_map=_response_types_map,
2579
+ )
2580
+
2581
+
2582
+ @validate_call
2583
+ def get_groups_by_user_without_preload_content(
2584
+ self,
2585
+ email: Annotated[StrictStr, Field(description="Email of the user for retrieval")],
2586
+ _request_timeout: Union[
2587
+ None,
2588
+ Annotated[StrictFloat, Field(gt=0)],
2589
+ Tuple[
2590
+ Annotated[StrictFloat, Field(gt=0)],
2591
+ Annotated[StrictFloat, Field(gt=0)]
2592
+ ]
2593
+ ] = None,
2594
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2595
+ _content_type: Optional[StrictStr] = None,
2596
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2597
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2598
+ ) -> RESTResponseType:
2599
+ """Get groups of a single user
2600
+
2601
+ Returns a list of all groups a user belongs to. This includes data from these groups, the `members`, the `name` and the `Permission set`.
2602
+
2603
+ :param email: Email of the user for retrieval (required)
2604
+ :type email: str
2605
+ :param _request_timeout: timeout setting for this request. If one
2606
+ number provided, it will be total request
2607
+ timeout. It can also be a pair (tuple) of
2608
+ (connection, read) timeouts.
2609
+ :type _request_timeout: int, tuple(int, int), optional
2610
+ :param _request_auth: set to override the auth_settings for an a single
2611
+ request; this effectively ignores the
2612
+ authentication in the spec for a single request.
2613
+ :type _request_auth: dict, optional
2614
+ :param _content_type: force content-type for the request.
2615
+ :type _content_type: str, Optional
2616
+ :param _headers: set to override the headers for a single
2617
+ request; this effectively ignores the headers
2618
+ in the spec for a single request.
2619
+ :type _headers: dict, optional
2620
+ :param _host_index: set to override the host_index for a single
2621
+ request; this effectively ignores the host_index
2622
+ in the spec for a single request.
2623
+ :type _host_index: int, optional
2624
+ :return: Returns the result object.
2625
+ """ # noqa: E501
2626
+
2627
+ _param = self._get_groups_by_user_serialize(
2628
+ email=email,
2629
+ _request_auth=_request_auth,
2630
+ _content_type=_content_type,
2631
+ _headers=_headers,
2632
+ _host_index=_host_index
2633
+ )
2634
+
2635
+ _response_types_map: Dict[str, Optional[str]] = {
2636
+ '200': "List[ApiGroup]",
2637
+ '404': None,
2638
+ }
2639
+ response_data = self.api_client.call_api(
2640
+ *_param,
2641
+ _request_timeout=_request_timeout
2642
+ )
2643
+ return response_data.response
2644
+
2645
+
2646
+ def _get_groups_by_user_serialize(
2647
+ self,
2648
+ email,
2649
+ _request_auth,
2650
+ _content_type,
2651
+ _headers,
2652
+ _host_index,
2653
+ ) -> RequestSerialized:
2654
+
2655
+ _host = None
2656
+
2657
+ _collection_formats: Dict[str, str] = {
2658
+ }
2659
+
2660
+ _path_params: Dict[str, str] = {}
2661
+ _query_params: List[Tuple[str, str]] = []
2662
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2663
+ _form_params: List[Tuple[str, str]] = []
2664
+ _files: Dict[
2665
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2666
+ ] = {}
2667
+ _body_params: Optional[bytes] = None
2668
+
2669
+ # process the path parameters
2670
+ if email is not None:
2671
+ _path_params['email'] = email
2672
+ # process the query parameters
2673
+ # process the header parameters
2674
+ # process the form parameters
2675
+ # process the body parameter
2676
+
2677
+
2678
+ # set the HTTP header `Accept`
2679
+ if 'Accept' not in _header_params:
2680
+ _header_params['Accept'] = self.api_client.select_header_accept(
2681
+ [
2682
+ 'application/json'
2683
+ ]
2684
+ )
2685
+
2686
+
2687
+ # authentication setting
2688
+ _auth_settings: List[str] = [
2689
+ 'ApiKeyAuth'
2690
+ ]
2691
+
2692
+ return self.api_client.param_serialize(
2693
+ method='GET',
2694
+ resource_path='/api/settings/rbac/groups/user/{email}',
2695
+ path_params=_path_params,
2696
+ query_params=_query_params,
2697
+ header_params=_header_params,
2698
+ body=_body_params,
2699
+ post_params=_form_params,
2700
+ files=_files,
2701
+ auth_settings=_auth_settings,
2702
+ collection_formats=_collection_formats,
2703
+ _host=_host,
2704
+ _request_auth=_request_auth
2705
+ )
2706
+
2707
+
2708
+
2709
+
2710
+ @validate_call
2711
+ def get_identity_provider_patch(
2712
+ self,
2713
+ _request_timeout: Union[
2714
+ None,
2715
+ Annotated[StrictFloat, Field(gt=0)],
2716
+ Tuple[
2717
+ Annotated[StrictFloat, Field(gt=0)],
2718
+ Annotated[StrictFloat, Field(gt=0)]
2719
+ ]
2720
+ ] = None,
2721
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2722
+ _content_type: Optional[StrictStr] = None,
2723
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2724
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2725
+ ) -> IdentityProviderPatch:
2726
+ """Check user restrictions for empty Idp group mapping
2727
+
2728
+ Returns `RestrictEmptyIdpGroups` value indicating if access is denied for empty Idp group mapping. `RestrictEmptyIdpGroups = true` indicates that the tenant is locked and only those users are allowed access that have at least one working mapping rule applied to them during the login process.
2729
+
2730
+ :param _request_timeout: timeout setting for this request. If one
2731
+ number provided, it will be total request
2732
+ timeout. It can also be a pair (tuple) of
2733
+ (connection, read) timeouts.
2734
+ :type _request_timeout: int, tuple(int, int), optional
2735
+ :param _request_auth: set to override the auth_settings for an a single
2736
+ request; this effectively ignores the
2737
+ authentication in the spec for a single request.
2738
+ :type _request_auth: dict, optional
2739
+ :param _content_type: force content-type for the request.
2740
+ :type _content_type: str, Optional
2741
+ :param _headers: set to override the headers for a single
2742
+ request; this effectively ignores the headers
2743
+ in the spec for a single request.
2744
+ :type _headers: dict, optional
2745
+ :param _host_index: set to override the host_index for a single
2746
+ request; this effectively ignores the host_index
2747
+ in the spec for a single request.
2748
+ :type _host_index: int, optional
2749
+ :return: Returns the result object.
2750
+ """ # noqa: E501
2751
+
2752
+ _param = self._get_identity_provider_patch_serialize(
2753
+ _request_auth=_request_auth,
2754
+ _content_type=_content_type,
2755
+ _headers=_headers,
2756
+ _host_index=_host_index
2757
+ )
2758
+
2759
+ _response_types_map: Dict[str, Optional[str]] = {
2760
+ '200': "IdentityProviderPatch",
2761
+ '404': None,
2762
+ }
2763
+ response_data = self.api_client.call_api(
2764
+ *_param,
2765
+ _request_timeout=_request_timeout
2766
+ )
2767
+ response_data.read()
2768
+ return self.api_client.response_deserialize(
2769
+ response_data=response_data,
2770
+ response_types_map=_response_types_map,
2771
+ ).data
2772
+
2773
+
2774
+ @validate_call
2775
+ def get_identity_provider_patch_with_http_info(
2776
+ self,
2777
+ _request_timeout: Union[
2778
+ None,
2779
+ Annotated[StrictFloat, Field(gt=0)],
2780
+ Tuple[
2781
+ Annotated[StrictFloat, Field(gt=0)],
2782
+ Annotated[StrictFloat, Field(gt=0)]
2783
+ ]
2784
+ ] = None,
2785
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2786
+ _content_type: Optional[StrictStr] = None,
2787
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2788
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2789
+ ) -> ApiResponse[IdentityProviderPatch]:
2790
+ """Check user restrictions for empty Idp group mapping
2791
+
2792
+ Returns `RestrictEmptyIdpGroups` value indicating if access is denied for empty Idp group mapping. `RestrictEmptyIdpGroups = true` indicates that the tenant is locked and only those users are allowed access that have at least one working mapping rule applied to them during the login process.
2793
+
2794
+ :param _request_timeout: timeout setting for this request. If one
2795
+ number provided, it will be total request
2796
+ timeout. It can also be a pair (tuple) of
2797
+ (connection, read) timeouts.
2798
+ :type _request_timeout: int, tuple(int, int), optional
2799
+ :param _request_auth: set to override the auth_settings for an a single
2800
+ request; this effectively ignores the
2801
+ authentication in the spec for a single request.
2802
+ :type _request_auth: dict, optional
2803
+ :param _content_type: force content-type for the request.
2804
+ :type _content_type: str, Optional
2805
+ :param _headers: set to override the headers for a single
2806
+ request; this effectively ignores the headers
2807
+ in the spec for a single request.
2808
+ :type _headers: dict, optional
2809
+ :param _host_index: set to override the host_index for a single
2810
+ request; this effectively ignores the host_index
2811
+ in the spec for a single request.
2812
+ :type _host_index: int, optional
2813
+ :return: Returns the result object.
2814
+ """ # noqa: E501
2815
+
2816
+ _param = self._get_identity_provider_patch_serialize(
2817
+ _request_auth=_request_auth,
2818
+ _content_type=_content_type,
2819
+ _headers=_headers,
2820
+ _host_index=_host_index
2821
+ )
2822
+
2823
+ _response_types_map: Dict[str, Optional[str]] = {
2824
+ '200': "IdentityProviderPatch",
2825
+ '404': None,
2826
+ }
2827
+ response_data = self.api_client.call_api(
2828
+ *_param,
2829
+ _request_timeout=_request_timeout
2830
+ )
2831
+ response_data.read()
2832
+ return self.api_client.response_deserialize(
2833
+ response_data=response_data,
2834
+ response_types_map=_response_types_map,
2835
+ )
2836
+
2837
+
2838
+ @validate_call
2839
+ def get_identity_provider_patch_without_preload_content(
2840
+ self,
2841
+ _request_timeout: Union[
2842
+ None,
2843
+ Annotated[StrictFloat, Field(gt=0)],
2844
+ Tuple[
2845
+ Annotated[StrictFloat, Field(gt=0)],
2846
+ Annotated[StrictFloat, Field(gt=0)]
2847
+ ]
2848
+ ] = None,
2849
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2850
+ _content_type: Optional[StrictStr] = None,
2851
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2852
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2853
+ ) -> RESTResponseType:
2854
+ """Check user restrictions for empty Idp group mapping
2855
+
2856
+ Returns `RestrictEmptyIdpGroups` value indicating if access is denied for empty Idp group mapping. `RestrictEmptyIdpGroups = true` indicates that the tenant is locked and only those users are allowed access that have at least one working mapping rule applied to them during the login process.
2857
+
2858
+ :param _request_timeout: timeout setting for this request. If one
2859
+ number provided, it will be total request
2860
+ timeout. It can also be a pair (tuple) of
2861
+ (connection, read) timeouts.
2862
+ :type _request_timeout: int, tuple(int, int), optional
2863
+ :param _request_auth: set to override the auth_settings for an a single
2864
+ request; this effectively ignores the
2865
+ authentication in the spec for a single request.
2866
+ :type _request_auth: dict, optional
2867
+ :param _content_type: force content-type for the request.
2868
+ :type _content_type: str, Optional
2869
+ :param _headers: set to override the headers for a single
2870
+ request; this effectively ignores the headers
2871
+ in the spec for a single request.
2872
+ :type _headers: dict, optional
2873
+ :param _host_index: set to override the host_index for a single
2874
+ request; this effectively ignores the host_index
2875
+ in the spec for a single request.
2876
+ :type _host_index: int, optional
2877
+ :return: Returns the result object.
2878
+ """ # noqa: E501
2879
+
2880
+ _param = self._get_identity_provider_patch_serialize(
2881
+ _request_auth=_request_auth,
2882
+ _content_type=_content_type,
2883
+ _headers=_headers,
2884
+ _host_index=_host_index
2885
+ )
2886
+
2887
+ _response_types_map: Dict[str, Optional[str]] = {
2888
+ '200': "IdentityProviderPatch",
2889
+ '404': None,
2890
+ }
2891
+ response_data = self.api_client.call_api(
2892
+ *_param,
2893
+ _request_timeout=_request_timeout
2894
+ )
2895
+ return response_data.response
2896
+
2897
+
2898
+ def _get_identity_provider_patch_serialize(
2899
+ self,
2900
+ _request_auth,
2901
+ _content_type,
2902
+ _headers,
2903
+ _host_index,
2904
+ ) -> RequestSerialized:
2905
+
2906
+ _host = None
2907
+
2908
+ _collection_formats: Dict[str, str] = {
2909
+ }
2910
+
2911
+ _path_params: Dict[str, str] = {}
2912
+ _query_params: List[Tuple[str, str]] = []
2913
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2914
+ _form_params: List[Tuple[str, str]] = []
2915
+ _files: Dict[
2916
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2917
+ ] = {}
2918
+ _body_params: Optional[bytes] = None
2919
+
2920
+ # process the path parameters
2921
+ # process the query parameters
2922
+ # process the header parameters
2923
+ # process the form parameters
2924
+ # process the body parameter
2925
+
2926
+
2927
+ # set the HTTP header `Accept`
2928
+ if 'Accept' not in _header_params:
2929
+ _header_params['Accept'] = self.api_client.select_header_accept(
2930
+ [
2931
+ 'application/json'
2932
+ ]
2933
+ )
2934
+
2935
+
2936
+ # authentication setting
2937
+ _auth_settings: List[str] = [
2938
+ 'ApiKeyAuth'
2939
+ ]
2940
+
2941
+ return self.api_client.param_serialize(
2942
+ method='GET',
2943
+ resource_path='/api/settings/rbac/mappings/identityProvider/restrictEmptyIdpGroups',
2944
+ path_params=_path_params,
2945
+ query_params=_query_params,
2946
+ header_params=_header_params,
2947
+ body=_body_params,
2948
+ post_params=_form_params,
2949
+ files=_files,
2950
+ auth_settings=_auth_settings,
2951
+ collection_formats=_collection_formats,
2952
+ _host=_host,
2953
+ _request_auth=_request_auth
2954
+ )
2955
+
2956
+
2957
+
2958
+
2959
+ @validate_call
2960
+ def remove_user_from_group(
2961
+ self,
2962
+ id: Annotated[StrictStr, Field(description="Id of the group to remove user from")],
2963
+ user_id: Annotated[StrictStr, Field(description="Id of the user to remove")],
2964
+ _request_timeout: Union[
2965
+ None,
2966
+ Annotated[StrictFloat, Field(gt=0)],
2967
+ Tuple[
2968
+ Annotated[StrictFloat, Field(gt=0)],
2969
+ Annotated[StrictFloat, Field(gt=0)]
2970
+ ]
2971
+ ] = None,
2972
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2973
+ _content_type: Optional[StrictStr] = None,
2974
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2975
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2976
+ ) -> None:
2977
+ """Remove user from group
2978
+
2979
+ Remove the user from a group.
2980
+
2981
+ :param id: Id of the group to remove user from (required)
2982
+ :type id: str
2983
+ :param user_id: Id of the user to remove (required)
2984
+ :type user_id: str
2985
+ :param _request_timeout: timeout setting for this request. If one
2986
+ number provided, it will be total request
2987
+ timeout. It can also be a pair (tuple) of
2988
+ (connection, read) timeouts.
2989
+ :type _request_timeout: int, tuple(int, int), optional
2990
+ :param _request_auth: set to override the auth_settings for an a single
2991
+ request; this effectively ignores the
2992
+ authentication in the spec for a single request.
2993
+ :type _request_auth: dict, optional
2994
+ :param _content_type: force content-type for the request.
2995
+ :type _content_type: str, Optional
2996
+ :param _headers: set to override the headers for a single
2997
+ request; this effectively ignores the headers
2998
+ in the spec for a single request.
2999
+ :type _headers: dict, optional
3000
+ :param _host_index: set to override the host_index for a single
3001
+ request; this effectively ignores the host_index
3002
+ in the spec for a single request.
3003
+ :type _host_index: int, optional
3004
+ :return: Returns the result object.
3005
+ """ # noqa: E501
3006
+
3007
+ _param = self._remove_user_from_group_serialize(
3008
+ id=id,
3009
+ user_id=user_id,
3010
+ _request_auth=_request_auth,
3011
+ _content_type=_content_type,
3012
+ _headers=_headers,
3013
+ _host_index=_host_index
3014
+ )
3015
+
3016
+ _response_types_map: Dict[str, Optional[str]] = {
3017
+ }
3018
+ response_data = self.api_client.call_api(
3019
+ *_param,
3020
+ _request_timeout=_request_timeout
3021
+ )
3022
+ response_data.read()
3023
+ return self.api_client.response_deserialize(
3024
+ response_data=response_data,
3025
+ response_types_map=_response_types_map,
3026
+ ).data
3027
+
3028
+
3029
+ @validate_call
3030
+ def remove_user_from_group_with_http_info(
3031
+ self,
3032
+ id: Annotated[StrictStr, Field(description="Id of the group to remove user from")],
3033
+ user_id: Annotated[StrictStr, Field(description="Id of the user to remove")],
3034
+ _request_timeout: Union[
3035
+ None,
3036
+ Annotated[StrictFloat, Field(gt=0)],
3037
+ Tuple[
3038
+ Annotated[StrictFloat, Field(gt=0)],
3039
+ Annotated[StrictFloat, Field(gt=0)]
3040
+ ]
3041
+ ] = None,
3042
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3043
+ _content_type: Optional[StrictStr] = None,
3044
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3045
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3046
+ ) -> ApiResponse[None]:
3047
+ """Remove user from group
3048
+
3049
+ Remove the user from a group.
3050
+
3051
+ :param id: Id of the group to remove user from (required)
3052
+ :type id: str
3053
+ :param user_id: Id of the user to remove (required)
3054
+ :type user_id: str
3055
+ :param _request_timeout: timeout setting for this request. If one
3056
+ number provided, it will be total request
3057
+ timeout. It can also be a pair (tuple) of
3058
+ (connection, read) timeouts.
3059
+ :type _request_timeout: int, tuple(int, int), optional
3060
+ :param _request_auth: set to override the auth_settings for an a single
3061
+ request; this effectively ignores the
3062
+ authentication in the spec for a single request.
3063
+ :type _request_auth: dict, optional
3064
+ :param _content_type: force content-type for the request.
3065
+ :type _content_type: str, Optional
3066
+ :param _headers: set to override the headers for a single
3067
+ request; this effectively ignores the headers
3068
+ in the spec for a single request.
3069
+ :type _headers: dict, optional
3070
+ :param _host_index: set to override the host_index for a single
3071
+ request; this effectively ignores the host_index
3072
+ in the spec for a single request.
3073
+ :type _host_index: int, optional
3074
+ :return: Returns the result object.
3075
+ """ # noqa: E501
3076
+
3077
+ _param = self._remove_user_from_group_serialize(
3078
+ id=id,
3079
+ user_id=user_id,
3080
+ _request_auth=_request_auth,
3081
+ _content_type=_content_type,
3082
+ _headers=_headers,
3083
+ _host_index=_host_index
3084
+ )
3085
+
3086
+ _response_types_map: Dict[str, Optional[str]] = {
3087
+ }
3088
+ response_data = self.api_client.call_api(
3089
+ *_param,
3090
+ _request_timeout=_request_timeout
3091
+ )
3092
+ response_data.read()
3093
+ return self.api_client.response_deserialize(
3094
+ response_data=response_data,
3095
+ response_types_map=_response_types_map,
3096
+ )
3097
+
3098
+
3099
+ @validate_call
3100
+ def remove_user_from_group_without_preload_content(
3101
+ self,
3102
+ id: Annotated[StrictStr, Field(description="Id of the group to remove user from")],
3103
+ user_id: Annotated[StrictStr, Field(description="Id of the user to remove")],
3104
+ _request_timeout: Union[
3105
+ None,
3106
+ Annotated[StrictFloat, Field(gt=0)],
3107
+ Tuple[
3108
+ Annotated[StrictFloat, Field(gt=0)],
3109
+ Annotated[StrictFloat, Field(gt=0)]
3110
+ ]
3111
+ ] = None,
3112
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3113
+ _content_type: Optional[StrictStr] = None,
3114
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3115
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3116
+ ) -> RESTResponseType:
3117
+ """Remove user from group
3118
+
3119
+ Remove the user from a group.
3120
+
3121
+ :param id: Id of the group to remove user from (required)
3122
+ :type id: str
3123
+ :param user_id: Id of the user to remove (required)
3124
+ :type user_id: str
3125
+ :param _request_timeout: timeout setting for this request. If one
3126
+ number provided, it will be total request
3127
+ timeout. It can also be a pair (tuple) of
3128
+ (connection, read) timeouts.
3129
+ :type _request_timeout: int, tuple(int, int), optional
3130
+ :param _request_auth: set to override the auth_settings for an a single
3131
+ request; this effectively ignores the
3132
+ authentication in the spec for a single request.
3133
+ :type _request_auth: dict, optional
3134
+ :param _content_type: force content-type for the request.
3135
+ :type _content_type: str, Optional
3136
+ :param _headers: set to override the headers for a single
3137
+ request; this effectively ignores the headers
3138
+ in the spec for a single request.
3139
+ :type _headers: dict, optional
3140
+ :param _host_index: set to override the host_index for a single
3141
+ request; this effectively ignores the host_index
3142
+ in the spec for a single request.
3143
+ :type _host_index: int, optional
3144
+ :return: Returns the result object.
3145
+ """ # noqa: E501
3146
+
3147
+ _param = self._remove_user_from_group_serialize(
3148
+ id=id,
3149
+ user_id=user_id,
3150
+ _request_auth=_request_auth,
3151
+ _content_type=_content_type,
3152
+ _headers=_headers,
3153
+ _host_index=_host_index
3154
+ )
3155
+
3156
+ _response_types_map: Dict[str, Optional[str]] = {
3157
+ }
3158
+ response_data = self.api_client.call_api(
3159
+ *_param,
3160
+ _request_timeout=_request_timeout
3161
+ )
3162
+ return response_data.response
3163
+
3164
+
3165
+ def _remove_user_from_group_serialize(
3166
+ self,
3167
+ id,
3168
+ user_id,
3169
+ _request_auth,
3170
+ _content_type,
3171
+ _headers,
3172
+ _host_index,
3173
+ ) -> RequestSerialized:
3174
+
3175
+ _host = None
3176
+
3177
+ _collection_formats: Dict[str, str] = {
3178
+ }
3179
+
3180
+ _path_params: Dict[str, str] = {}
3181
+ _query_params: List[Tuple[str, str]] = []
3182
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3183
+ _form_params: List[Tuple[str, str]] = []
3184
+ _files: Dict[
3185
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3186
+ ] = {}
3187
+ _body_params: Optional[bytes] = None
3188
+
3189
+ # process the path parameters
3190
+ if id is not None:
3191
+ _path_params['id'] = id
3192
+ if user_id is not None:
3193
+ _path_params['userId'] = user_id
3194
+ # process the query parameters
3195
+ # process the header parameters
3196
+ # process the form parameters
3197
+ # process the body parameter
3198
+
3199
+
3200
+ # set the HTTP header `Accept`
3201
+ if 'Accept' not in _header_params:
3202
+ _header_params['Accept'] = self.api_client.select_header_accept(
3203
+ [
3204
+ 'application/json'
3205
+ ]
3206
+ )
3207
+
3208
+
3209
+ # authentication setting
3210
+ _auth_settings: List[str] = [
3211
+ 'ApiKeyAuth'
3212
+ ]
3213
+
3214
+ return self.api_client.param_serialize(
3215
+ method='DELETE',
3216
+ resource_path='/api/settings/rbac/groups/{id}/user/{userId}',
3217
+ path_params=_path_params,
3218
+ query_params=_query_params,
3219
+ header_params=_header_params,
3220
+ body=_body_params,
3221
+ post_params=_form_params,
3222
+ files=_files,
3223
+ auth_settings=_auth_settings,
3224
+ collection_formats=_collection_formats,
3225
+ _host=_host,
3226
+ _request_auth=_request_auth
3227
+ )
3228
+
3229
+
3230
+
3231
+
3232
+ @validate_call
3233
+ def update_group(
3234
+ self,
3235
+ id: Annotated[StrictStr, Field(description="Id of the group to update")],
3236
+ api_group: ApiGroup,
3237
+ _request_timeout: Union[
3238
+ None,
3239
+ Annotated[StrictFloat, Field(gt=0)],
3240
+ Tuple[
3241
+ Annotated[StrictFloat, Field(gt=0)],
3242
+ Annotated[StrictFloat, Field(gt=0)]
3243
+ ]
3244
+ ] = None,
3245
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3246
+ _content_type: Optional[StrictStr] = None,
3247
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3248
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3249
+ ) -> ApiGroup:
3250
+ """Update group
3251
+
3252
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
3253
+
3254
+ :param id: Id of the group to update (required)
3255
+ :type id: str
3256
+ :param api_group: (required)
3257
+ :type api_group: ApiGroup
3258
+ :param _request_timeout: timeout setting for this request. If one
3259
+ number provided, it will be total request
3260
+ timeout. It can also be a pair (tuple) of
3261
+ (connection, read) timeouts.
3262
+ :type _request_timeout: int, tuple(int, int), optional
3263
+ :param _request_auth: set to override the auth_settings for an a single
3264
+ request; this effectively ignores the
3265
+ authentication in the spec for a single request.
3266
+ :type _request_auth: dict, optional
3267
+ :param _content_type: force content-type for the request.
3268
+ :type _content_type: str, Optional
3269
+ :param _headers: set to override the headers for a single
3270
+ request; this effectively ignores the headers
3271
+ in the spec for a single request.
3272
+ :type _headers: dict, optional
3273
+ :param _host_index: set to override the host_index for a single
3274
+ request; this effectively ignores the host_index
3275
+ in the spec for a single request.
3276
+ :type _host_index: int, optional
3277
+ :return: Returns the result object.
3278
+ """ # noqa: E501
3279
+
3280
+ _param = self._update_group_serialize(
3281
+ id=id,
3282
+ api_group=api_group,
3283
+ _request_auth=_request_auth,
3284
+ _content_type=_content_type,
3285
+ _headers=_headers,
3286
+ _host_index=_host_index
3287
+ )
3288
+
3289
+ _response_types_map: Dict[str, Optional[str]] = {
3290
+ '200': "ApiGroup",
3291
+ }
3292
+ response_data = self.api_client.call_api(
3293
+ *_param,
3294
+ _request_timeout=_request_timeout
3295
+ )
3296
+ response_data.read()
3297
+ return self.api_client.response_deserialize(
3298
+ response_data=response_data,
3299
+ response_types_map=_response_types_map,
3300
+ ).data
3301
+
3302
+
3303
+ @validate_call
3304
+ def update_group_with_http_info(
3305
+ self,
3306
+ id: Annotated[StrictStr, Field(description="Id of the group to update")],
3307
+ api_group: ApiGroup,
3308
+ _request_timeout: Union[
3309
+ None,
3310
+ Annotated[StrictFloat, Field(gt=0)],
3311
+ Tuple[
3312
+ Annotated[StrictFloat, Field(gt=0)],
3313
+ Annotated[StrictFloat, Field(gt=0)]
3314
+ ]
3315
+ ] = None,
3316
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3317
+ _content_type: Optional[StrictStr] = None,
3318
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3319
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3320
+ ) -> ApiResponse[ApiGroup]:
3321
+ """Update group
3322
+
3323
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
3324
+
3325
+ :param id: Id of the group to update (required)
3326
+ :type id: str
3327
+ :param api_group: (required)
3328
+ :type api_group: ApiGroup
3329
+ :param _request_timeout: timeout setting for this request. If one
3330
+ number provided, it will be total request
3331
+ timeout. It can also be a pair (tuple) of
3332
+ (connection, read) timeouts.
3333
+ :type _request_timeout: int, tuple(int, int), optional
3334
+ :param _request_auth: set to override the auth_settings for an a single
3335
+ request; this effectively ignores the
3336
+ authentication in the spec for a single request.
3337
+ :type _request_auth: dict, optional
3338
+ :param _content_type: force content-type for the request.
3339
+ :type _content_type: str, Optional
3340
+ :param _headers: set to override the headers for a single
3341
+ request; this effectively ignores the headers
3342
+ in the spec for a single request.
3343
+ :type _headers: dict, optional
3344
+ :param _host_index: set to override the host_index for a single
3345
+ request; this effectively ignores the host_index
3346
+ in the spec for a single request.
3347
+ :type _host_index: int, optional
3348
+ :return: Returns the result object.
3349
+ """ # noqa: E501
3350
+
3351
+ _param = self._update_group_serialize(
3352
+ id=id,
3353
+ api_group=api_group,
3354
+ _request_auth=_request_auth,
3355
+ _content_type=_content_type,
3356
+ _headers=_headers,
3357
+ _host_index=_host_index
3358
+ )
3359
+
3360
+ _response_types_map: Dict[str, Optional[str]] = {
3361
+ '200': "ApiGroup",
3362
+ }
3363
+ response_data = self.api_client.call_api(
3364
+ *_param,
3365
+ _request_timeout=_request_timeout
3366
+ )
3367
+ response_data.read()
3368
+ return self.api_client.response_deserialize(
3369
+ response_data=response_data,
3370
+ response_types_map=_response_types_map,
3371
+ )
3372
+
3373
+
3374
+ @validate_call
3375
+ def update_group_without_preload_content(
3376
+ self,
3377
+ id: Annotated[StrictStr, Field(description="Id of the group to update")],
3378
+ api_group: ApiGroup,
3379
+ _request_timeout: Union[
3380
+ None,
3381
+ Annotated[StrictFloat, Field(gt=0)],
3382
+ Tuple[
3383
+ Annotated[StrictFloat, Field(gt=0)],
3384
+ Annotated[StrictFloat, Field(gt=0)]
3385
+ ]
3386
+ ] = None,
3387
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3388
+ _content_type: Optional[StrictStr] = None,
3389
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3390
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3391
+ ) -> RESTResponseType:
3392
+ """Update group
3393
+
3394
+ Add a permission to a group. Permissions are strings associated with the group that some resources requires to fulfill requests. Examples of `Permissions`: - `ACCESS_APPLICATIONS` - `ACCESS_INFRASTRUCTURE` - `ACCESS_KUBERNETES` - `ACCESS_MOBILE_APPS` - `ACCESS_WEBSITES` - `CAN_CONFIGURE_AGENT_RUN_MODE` - `CAN_CONFIGURE_AGENTS` - `CAN_CONFIGURE_API_TOKENS` - `CAN_CONFIGURE_APPLICATIONS` - `CAN_CONFIGURE_AUTHENTICATION_METHODS` - `CAN_CONFIGURE_CUSTOM_ALERTS` - `CAN_CONFIGURE_EUM_APPLICATIONS` - `CAN_CONFIGURE_GLOBAL_ALERT_CONFIGS` - `CAN_CONFIGURE_GLOBAL_ALERT_PAYLOAD` - `CAN_CONFIGURE_INTEGRATIONS` - `CAN_CONFIGURE_LOG_MANAGEMENT` - `CAN_CONFIGURE_MOBILE_APP_MONITORING` - `CAN_CONFIGURE_PERSONAL_API_TOKENS` - `CAN_CONFIGURE_RELEASES` - `CAN_CONFIGURE_SERVICE_LEVEL_INDICATORS` - `CAN_CONFIGURE_SERVICE_MAPPING` - `CAN_CONFIGURE_SESSION_SETTINGS` - `CAN_CONFIGURE_TEAMS` - `CAN_CONFIGURE_USERS` - `CAN_CREATE_PUBLIC_CUSTOM_DASHBOARDS` - `CAN_EDIT_ALL_ACCESSIBLE_CUSTOM_DASHBOARDS` - `CAN_INSTALL_NEW_AGENTS` - `CAN_VIEW_ACCOUNT_AND_BILLING_INFORMATION` - `CAN_VIEW_AUDIT_LOG` - `CAN_VIEW_LOGS` - `CAN_VIEW_TRACE_DETAILS` - `LIMITED_APPLICATIONS_SCOPE` - `LIMITED_INFRASTRUCTURE_SCOPE` - `LIMITED_KUBERNETES_SCOPE` - `LIMITED_MOBILE_APPS_SCOPE` - `LIMITED_WEBSITES_SCOPE`
3395
+
3396
+ :param id: Id of the group to update (required)
3397
+ :type id: str
3398
+ :param api_group: (required)
3399
+ :type api_group: ApiGroup
3400
+ :param _request_timeout: timeout setting for this request. If one
3401
+ number provided, it will be total request
3402
+ timeout. It can also be a pair (tuple) of
3403
+ (connection, read) timeouts.
3404
+ :type _request_timeout: int, tuple(int, int), optional
3405
+ :param _request_auth: set to override the auth_settings for an a single
3406
+ request; this effectively ignores the
3407
+ authentication in the spec for a single request.
3408
+ :type _request_auth: dict, optional
3409
+ :param _content_type: force content-type for the request.
3410
+ :type _content_type: str, Optional
3411
+ :param _headers: set to override the headers for a single
3412
+ request; this effectively ignores the headers
3413
+ in the spec for a single request.
3414
+ :type _headers: dict, optional
3415
+ :param _host_index: set to override the host_index for a single
3416
+ request; this effectively ignores the host_index
3417
+ in the spec for a single request.
3418
+ :type _host_index: int, optional
3419
+ :return: Returns the result object.
3420
+ """ # noqa: E501
3421
+
3422
+ _param = self._update_group_serialize(
3423
+ id=id,
3424
+ api_group=api_group,
3425
+ _request_auth=_request_auth,
3426
+ _content_type=_content_type,
3427
+ _headers=_headers,
3428
+ _host_index=_host_index
3429
+ )
3430
+
3431
+ _response_types_map: Dict[str, Optional[str]] = {
3432
+ '200': "ApiGroup",
3433
+ }
3434
+ response_data = self.api_client.call_api(
3435
+ *_param,
3436
+ _request_timeout=_request_timeout
3437
+ )
3438
+ return response_data.response
3439
+
3440
+
3441
+ def _update_group_serialize(
3442
+ self,
3443
+ id,
3444
+ api_group,
3445
+ _request_auth,
3446
+ _content_type,
3447
+ _headers,
3448
+ _host_index,
3449
+ ) -> RequestSerialized:
3450
+
3451
+ _host = None
3452
+
3453
+ _collection_formats: Dict[str, str] = {
3454
+ }
3455
+
3456
+ _path_params: Dict[str, str] = {}
3457
+ _query_params: List[Tuple[str, str]] = []
3458
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3459
+ _form_params: List[Tuple[str, str]] = []
3460
+ _files: Dict[
3461
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3462
+ ] = {}
3463
+ _body_params: Optional[bytes] = None
3464
+
3465
+ # process the path parameters
3466
+ if id is not None:
3467
+ _path_params['id'] = id
3468
+ # process the query parameters
3469
+ # process the header parameters
3470
+ # process the form parameters
3471
+ # process the body parameter
3472
+ if api_group is not None:
3473
+ _body_params = api_group
3474
+
3475
+
3476
+ # set the HTTP header `Accept`
3477
+ if 'Accept' not in _header_params:
3478
+ _header_params['Accept'] = self.api_client.select_header_accept(
3479
+ [
3480
+ 'application/json'
3481
+ ]
3482
+ )
3483
+
3484
+ # set the HTTP header `Content-Type`
3485
+ if _content_type:
3486
+ _header_params['Content-Type'] = _content_type
3487
+ else:
3488
+ _default_content_type = (
3489
+ self.api_client.select_header_content_type(
3490
+ [
3491
+ 'application/json'
3492
+ ]
3493
+ )
3494
+ )
3495
+ if _default_content_type is not None:
3496
+ _header_params['Content-Type'] = _default_content_type
3497
+
3498
+ # authentication setting
3499
+ _auth_settings: List[str] = [
3500
+ 'ApiKeyAuth'
3501
+ ]
3502
+
3503
+ return self.api_client.param_serialize(
3504
+ method='PUT',
3505
+ resource_path='/api/settings/rbac/groups/{id}',
3506
+ path_params=_path_params,
3507
+ query_params=_query_params,
3508
+ header_params=_header_params,
3509
+ body=_body_params,
3510
+ post_params=_form_params,
3511
+ files=_files,
3512
+ auth_settings=_auth_settings,
3513
+ collection_formats=_collection_formats,
3514
+ _host=_host,
3515
+ _request_auth=_request_auth
3516
+ )
3517
+
3518
+
3519
+
3520
+
3521
+ @validate_call
3522
+ def update_group_mapping(
3523
+ self,
3524
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to update")],
3525
+ group_mapping: GroupMapping,
3526
+ _request_timeout: Union[
3527
+ None,
3528
+ Annotated[StrictFloat, Field(gt=0)],
3529
+ Tuple[
3530
+ Annotated[StrictFloat, Field(gt=0)],
3531
+ Annotated[StrictFloat, Field(gt=0)]
3532
+ ]
3533
+ ] = None,
3534
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3535
+ _content_type: Optional[StrictStr] = None,
3536
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3537
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3538
+ ) -> GroupMapping:
3539
+ """Update group mapping
3540
+
3541
+ See [creating group mapping](#operation/createGroupMapping)
3542
+
3543
+ :param id: Id of the group mapping to update (required)
3544
+ :type id: str
3545
+ :param group_mapping: (required)
3546
+ :type group_mapping: GroupMapping
3547
+ :param _request_timeout: timeout setting for this request. If one
3548
+ number provided, it will be total request
3549
+ timeout. It can also be a pair (tuple) of
3550
+ (connection, read) timeouts.
3551
+ :type _request_timeout: int, tuple(int, int), optional
3552
+ :param _request_auth: set to override the auth_settings for an a single
3553
+ request; this effectively ignores the
3554
+ authentication in the spec for a single request.
3555
+ :type _request_auth: dict, optional
3556
+ :param _content_type: force content-type for the request.
3557
+ :type _content_type: str, Optional
3558
+ :param _headers: set to override the headers for a single
3559
+ request; this effectively ignores the headers
3560
+ in the spec for a single request.
3561
+ :type _headers: dict, optional
3562
+ :param _host_index: set to override the host_index for a single
3563
+ request; this effectively ignores the host_index
3564
+ in the spec for a single request.
3565
+ :type _host_index: int, optional
3566
+ :return: Returns the result object.
3567
+ """ # noqa: E501
3568
+
3569
+ _param = self._update_group_mapping_serialize(
3570
+ id=id,
3571
+ group_mapping=group_mapping,
3572
+ _request_auth=_request_auth,
3573
+ _content_type=_content_type,
3574
+ _headers=_headers,
3575
+ _host_index=_host_index
3576
+ )
3577
+
3578
+ _response_types_map: Dict[str, Optional[str]] = {
3579
+ '200': "GroupMapping",
3580
+ }
3581
+ response_data = self.api_client.call_api(
3582
+ *_param,
3583
+ _request_timeout=_request_timeout
3584
+ )
3585
+ response_data.read()
3586
+ return self.api_client.response_deserialize(
3587
+ response_data=response_data,
3588
+ response_types_map=_response_types_map,
3589
+ ).data
3590
+
3591
+
3592
+ @validate_call
3593
+ def update_group_mapping_with_http_info(
3594
+ self,
3595
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to update")],
3596
+ group_mapping: GroupMapping,
3597
+ _request_timeout: Union[
3598
+ None,
3599
+ Annotated[StrictFloat, Field(gt=0)],
3600
+ Tuple[
3601
+ Annotated[StrictFloat, Field(gt=0)],
3602
+ Annotated[StrictFloat, Field(gt=0)]
3603
+ ]
3604
+ ] = None,
3605
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3606
+ _content_type: Optional[StrictStr] = None,
3607
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3608
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3609
+ ) -> ApiResponse[GroupMapping]:
3610
+ """Update group mapping
3611
+
3612
+ See [creating group mapping](#operation/createGroupMapping)
3613
+
3614
+ :param id: Id of the group mapping to update (required)
3615
+ :type id: str
3616
+ :param group_mapping: (required)
3617
+ :type group_mapping: GroupMapping
3618
+ :param _request_timeout: timeout setting for this request. If one
3619
+ number provided, it will be total request
3620
+ timeout. It can also be a pair (tuple) of
3621
+ (connection, read) timeouts.
3622
+ :type _request_timeout: int, tuple(int, int), optional
3623
+ :param _request_auth: set to override the auth_settings for an a single
3624
+ request; this effectively ignores the
3625
+ authentication in the spec for a single request.
3626
+ :type _request_auth: dict, optional
3627
+ :param _content_type: force content-type for the request.
3628
+ :type _content_type: str, Optional
3629
+ :param _headers: set to override the headers for a single
3630
+ request; this effectively ignores the headers
3631
+ in the spec for a single request.
3632
+ :type _headers: dict, optional
3633
+ :param _host_index: set to override the host_index for a single
3634
+ request; this effectively ignores the host_index
3635
+ in the spec for a single request.
3636
+ :type _host_index: int, optional
3637
+ :return: Returns the result object.
3638
+ """ # noqa: E501
3639
+
3640
+ _param = self._update_group_mapping_serialize(
3641
+ id=id,
3642
+ group_mapping=group_mapping,
3643
+ _request_auth=_request_auth,
3644
+ _content_type=_content_type,
3645
+ _headers=_headers,
3646
+ _host_index=_host_index
3647
+ )
3648
+
3649
+ _response_types_map: Dict[str, Optional[str]] = {
3650
+ '200': "GroupMapping",
3651
+ }
3652
+ response_data = self.api_client.call_api(
3653
+ *_param,
3654
+ _request_timeout=_request_timeout
3655
+ )
3656
+ response_data.read()
3657
+ return self.api_client.response_deserialize(
3658
+ response_data=response_data,
3659
+ response_types_map=_response_types_map,
3660
+ )
3661
+
3662
+
3663
+ @validate_call
3664
+ def update_group_mapping_without_preload_content(
3665
+ self,
3666
+ id: Annotated[StrictStr, Field(description="Id of the group mapping to update")],
3667
+ group_mapping: GroupMapping,
3668
+ _request_timeout: Union[
3669
+ None,
3670
+ Annotated[StrictFloat, Field(gt=0)],
3671
+ Tuple[
3672
+ Annotated[StrictFloat, Field(gt=0)],
3673
+ Annotated[StrictFloat, Field(gt=0)]
3674
+ ]
3675
+ ] = None,
3676
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3677
+ _content_type: Optional[StrictStr] = None,
3678
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3679
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3680
+ ) -> RESTResponseType:
3681
+ """Update group mapping
3682
+
3683
+ See [creating group mapping](#operation/createGroupMapping)
3684
+
3685
+ :param id: Id of the group mapping to update (required)
3686
+ :type id: str
3687
+ :param group_mapping: (required)
3688
+ :type group_mapping: GroupMapping
3689
+ :param _request_timeout: timeout setting for this request. If one
3690
+ number provided, it will be total request
3691
+ timeout. It can also be a pair (tuple) of
3692
+ (connection, read) timeouts.
3693
+ :type _request_timeout: int, tuple(int, int), optional
3694
+ :param _request_auth: set to override the auth_settings for an a single
3695
+ request; this effectively ignores the
3696
+ authentication in the spec for a single request.
3697
+ :type _request_auth: dict, optional
3698
+ :param _content_type: force content-type for the request.
3699
+ :type _content_type: str, Optional
3700
+ :param _headers: set to override the headers for a single
3701
+ request; this effectively ignores the headers
3702
+ in the spec for a single request.
3703
+ :type _headers: dict, optional
3704
+ :param _host_index: set to override the host_index for a single
3705
+ request; this effectively ignores the host_index
3706
+ in the spec for a single request.
3707
+ :type _host_index: int, optional
3708
+ :return: Returns the result object.
3709
+ """ # noqa: E501
3710
+
3711
+ _param = self._update_group_mapping_serialize(
3712
+ id=id,
3713
+ group_mapping=group_mapping,
3714
+ _request_auth=_request_auth,
3715
+ _content_type=_content_type,
3716
+ _headers=_headers,
3717
+ _host_index=_host_index
3718
+ )
3719
+
3720
+ _response_types_map: Dict[str, Optional[str]] = {
3721
+ '200': "GroupMapping",
3722
+ }
3723
+ response_data = self.api_client.call_api(
3724
+ *_param,
3725
+ _request_timeout=_request_timeout
3726
+ )
3727
+ return response_data.response
3728
+
3729
+
3730
+ def _update_group_mapping_serialize(
3731
+ self,
3732
+ id,
3733
+ group_mapping,
3734
+ _request_auth,
3735
+ _content_type,
3736
+ _headers,
3737
+ _host_index,
3738
+ ) -> RequestSerialized:
3739
+
3740
+ _host = None
3741
+
3742
+ _collection_formats: Dict[str, str] = {
3743
+ }
3744
+
3745
+ _path_params: Dict[str, str] = {}
3746
+ _query_params: List[Tuple[str, str]] = []
3747
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3748
+ _form_params: List[Tuple[str, str]] = []
3749
+ _files: Dict[
3750
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3751
+ ] = {}
3752
+ _body_params: Optional[bytes] = None
3753
+
3754
+ # process the path parameters
3755
+ if id is not None:
3756
+ _path_params['id'] = id
3757
+ # process the query parameters
3758
+ # process the header parameters
3759
+ # process the form parameters
3760
+ # process the body parameter
3761
+ if group_mapping is not None:
3762
+ _body_params = group_mapping
3763
+
3764
+
3765
+ # set the HTTP header `Accept`
3766
+ if 'Accept' not in _header_params:
3767
+ _header_params['Accept'] = self.api_client.select_header_accept(
3768
+ [
3769
+ 'application/json'
3770
+ ]
3771
+ )
3772
+
3773
+ # set the HTTP header `Content-Type`
3774
+ if _content_type:
3775
+ _header_params['Content-Type'] = _content_type
3776
+ else:
3777
+ _default_content_type = (
3778
+ self.api_client.select_header_content_type(
3779
+ [
3780
+ 'application/json'
3781
+ ]
3782
+ )
3783
+ )
3784
+ if _default_content_type is not None:
3785
+ _header_params['Content-Type'] = _default_content_type
3786
+
3787
+ # authentication setting
3788
+ _auth_settings: List[str] = [
3789
+ 'ApiKeyAuth'
3790
+ ]
3791
+
3792
+ return self.api_client.param_serialize(
3793
+ method='PUT',
3794
+ resource_path='/api/settings/rbac/mappings/{id}',
3795
+ path_params=_path_params,
3796
+ query_params=_query_params,
3797
+ header_params=_header_params,
3798
+ body=_body_params,
3799
+ post_params=_form_params,
3800
+ files=_files,
3801
+ auth_settings=_auth_settings,
3802
+ collection_formats=_collection_formats,
3803
+ _host=_host,
3804
+ _request_auth=_request_auth
3805
+ )
3806
+
3807
+
3808
+
3809
+
3810
+ @validate_call
3811
+ def update_identity_provider(
3812
+ self,
3813
+ identity_provider_patch: IdentityProviderPatch,
3814
+ _request_timeout: Union[
3815
+ None,
3816
+ Annotated[StrictFloat, Field(gt=0)],
3817
+ Tuple[
3818
+ Annotated[StrictFloat, Field(gt=0)],
3819
+ Annotated[StrictFloat, Field(gt=0)]
3820
+ ]
3821
+ ] = None,
3822
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3823
+ _content_type: Optional[StrictStr] = None,
3824
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3825
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3826
+ ) -> None:
3827
+ """Allow/Restrict users with empty Idp group mapping
3828
+
3829
+ Set the RestrictEmptyIdpGroups value as true/false. See [Check user restrictions for empty Idp group mapping](#operation/getIdentityProviderPatch) for more details.
3830
+
3831
+ :param identity_provider_patch: (required)
3832
+ :type identity_provider_patch: IdentityProviderPatch
3833
+ :param _request_timeout: timeout setting for this request. If one
3834
+ number provided, it will be total request
3835
+ timeout. It can also be a pair (tuple) of
3836
+ (connection, read) timeouts.
3837
+ :type _request_timeout: int, tuple(int, int), optional
3838
+ :param _request_auth: set to override the auth_settings for an a single
3839
+ request; this effectively ignores the
3840
+ authentication in the spec for a single request.
3841
+ :type _request_auth: dict, optional
3842
+ :param _content_type: force content-type for the request.
3843
+ :type _content_type: str, Optional
3844
+ :param _headers: set to override the headers for a single
3845
+ request; this effectively ignores the headers
3846
+ in the spec for a single request.
3847
+ :type _headers: dict, optional
3848
+ :param _host_index: set to override the host_index for a single
3849
+ request; this effectively ignores the host_index
3850
+ in the spec for a single request.
3851
+ :type _host_index: int, optional
3852
+ :return: Returns the result object.
3853
+ """ # noqa: E501
3854
+
3855
+ _param = self._update_identity_provider_serialize(
3856
+ identity_provider_patch=identity_provider_patch,
3857
+ _request_auth=_request_auth,
3858
+ _content_type=_content_type,
3859
+ _headers=_headers,
3860
+ _host_index=_host_index
3861
+ )
3862
+
3863
+ _response_types_map: Dict[str, Optional[str]] = {
3864
+ }
3865
+ response_data = self.api_client.call_api(
3866
+ *_param,
3867
+ _request_timeout=_request_timeout
3868
+ )
3869
+ response_data.read()
3870
+ return self.api_client.response_deserialize(
3871
+ response_data=response_data,
3872
+ response_types_map=_response_types_map,
3873
+ ).data
3874
+
3875
+
3876
+ @validate_call
3877
+ def update_identity_provider_with_http_info(
3878
+ self,
3879
+ identity_provider_patch: IdentityProviderPatch,
3880
+ _request_timeout: Union[
3881
+ None,
3882
+ Annotated[StrictFloat, Field(gt=0)],
3883
+ Tuple[
3884
+ Annotated[StrictFloat, Field(gt=0)],
3885
+ Annotated[StrictFloat, Field(gt=0)]
3886
+ ]
3887
+ ] = None,
3888
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3889
+ _content_type: Optional[StrictStr] = None,
3890
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3891
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3892
+ ) -> ApiResponse[None]:
3893
+ """Allow/Restrict users with empty Idp group mapping
3894
+
3895
+ Set the RestrictEmptyIdpGroups value as true/false. See [Check user restrictions for empty Idp group mapping](#operation/getIdentityProviderPatch) for more details.
3896
+
3897
+ :param identity_provider_patch: (required)
3898
+ :type identity_provider_patch: IdentityProviderPatch
3899
+ :param _request_timeout: timeout setting for this request. If one
3900
+ number provided, it will be total request
3901
+ timeout. It can also be a pair (tuple) of
3902
+ (connection, read) timeouts.
3903
+ :type _request_timeout: int, tuple(int, int), optional
3904
+ :param _request_auth: set to override the auth_settings for an a single
3905
+ request; this effectively ignores the
3906
+ authentication in the spec for a single request.
3907
+ :type _request_auth: dict, optional
3908
+ :param _content_type: force content-type for the request.
3909
+ :type _content_type: str, Optional
3910
+ :param _headers: set to override the headers for a single
3911
+ request; this effectively ignores the headers
3912
+ in the spec for a single request.
3913
+ :type _headers: dict, optional
3914
+ :param _host_index: set to override the host_index for a single
3915
+ request; this effectively ignores the host_index
3916
+ in the spec for a single request.
3917
+ :type _host_index: int, optional
3918
+ :return: Returns the result object.
3919
+ """ # noqa: E501
3920
+
3921
+ _param = self._update_identity_provider_serialize(
3922
+ identity_provider_patch=identity_provider_patch,
3923
+ _request_auth=_request_auth,
3924
+ _content_type=_content_type,
3925
+ _headers=_headers,
3926
+ _host_index=_host_index
3927
+ )
3928
+
3929
+ _response_types_map: Dict[str, Optional[str]] = {
3930
+ }
3931
+ response_data = self.api_client.call_api(
3932
+ *_param,
3933
+ _request_timeout=_request_timeout
3934
+ )
3935
+ response_data.read()
3936
+ return self.api_client.response_deserialize(
3937
+ response_data=response_data,
3938
+ response_types_map=_response_types_map,
3939
+ )
3940
+
3941
+
3942
+ @validate_call
3943
+ def update_identity_provider_without_preload_content(
3944
+ self,
3945
+ identity_provider_patch: IdentityProviderPatch,
3946
+ _request_timeout: Union[
3947
+ None,
3948
+ Annotated[StrictFloat, Field(gt=0)],
3949
+ Tuple[
3950
+ Annotated[StrictFloat, Field(gt=0)],
3951
+ Annotated[StrictFloat, Field(gt=0)]
3952
+ ]
3953
+ ] = None,
3954
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3955
+ _content_type: Optional[StrictStr] = None,
3956
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3957
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3958
+ ) -> RESTResponseType:
3959
+ """Allow/Restrict users with empty Idp group mapping
3960
+
3961
+ Set the RestrictEmptyIdpGroups value as true/false. See [Check user restrictions for empty Idp group mapping](#operation/getIdentityProviderPatch) for more details.
3962
+
3963
+ :param identity_provider_patch: (required)
3964
+ :type identity_provider_patch: IdentityProviderPatch
3965
+ :param _request_timeout: timeout setting for this request. If one
3966
+ number provided, it will be total request
3967
+ timeout. It can also be a pair (tuple) of
3968
+ (connection, read) timeouts.
3969
+ :type _request_timeout: int, tuple(int, int), optional
3970
+ :param _request_auth: set to override the auth_settings for an a single
3971
+ request; this effectively ignores the
3972
+ authentication in the spec for a single request.
3973
+ :type _request_auth: dict, optional
3974
+ :param _content_type: force content-type for the request.
3975
+ :type _content_type: str, Optional
3976
+ :param _headers: set to override the headers for a single
3977
+ request; this effectively ignores the headers
3978
+ in the spec for a single request.
3979
+ :type _headers: dict, optional
3980
+ :param _host_index: set to override the host_index for a single
3981
+ request; this effectively ignores the host_index
3982
+ in the spec for a single request.
3983
+ :type _host_index: int, optional
3984
+ :return: Returns the result object.
3985
+ """ # noqa: E501
3986
+
3987
+ _param = self._update_identity_provider_serialize(
3988
+ identity_provider_patch=identity_provider_patch,
3989
+ _request_auth=_request_auth,
3990
+ _content_type=_content_type,
3991
+ _headers=_headers,
3992
+ _host_index=_host_index
3993
+ )
3994
+
3995
+ _response_types_map: Dict[str, Optional[str]] = {
3996
+ }
3997
+ response_data = self.api_client.call_api(
3998
+ *_param,
3999
+ _request_timeout=_request_timeout
4000
+ )
4001
+ return response_data.response
4002
+
4003
+
4004
+ def _update_identity_provider_serialize(
4005
+ self,
4006
+ identity_provider_patch,
4007
+ _request_auth,
4008
+ _content_type,
4009
+ _headers,
4010
+ _host_index,
4011
+ ) -> RequestSerialized:
4012
+
4013
+ _host = None
4014
+
4015
+ _collection_formats: Dict[str, str] = {
4016
+ }
4017
+
4018
+ _path_params: Dict[str, str] = {}
4019
+ _query_params: List[Tuple[str, str]] = []
4020
+ _header_params: Dict[str, Optional[str]] = _headers or {}
4021
+ _form_params: List[Tuple[str, str]] = []
4022
+ _files: Dict[
4023
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
4024
+ ] = {}
4025
+ _body_params: Optional[bytes] = None
4026
+
4027
+ # process the path parameters
4028
+ # process the query parameters
4029
+ # process the header parameters
4030
+ # process the form parameters
4031
+ # process the body parameter
4032
+ if identity_provider_patch is not None:
4033
+ _body_params = identity_provider_patch
4034
+
4035
+
4036
+ # set the HTTP header `Accept`
4037
+ if 'Accept' not in _header_params:
4038
+ _header_params['Accept'] = self.api_client.select_header_accept(
4039
+ [
4040
+ 'application/json'
4041
+ ]
4042
+ )
4043
+
4044
+ # set the HTTP header `Content-Type`
4045
+ if _content_type:
4046
+ _header_params['Content-Type'] = _content_type
4047
+ else:
4048
+ _default_content_type = (
4049
+ self.api_client.select_header_content_type(
4050
+ [
4051
+ 'application/json'
4052
+ ]
4053
+ )
4054
+ )
4055
+ if _default_content_type is not None:
4056
+ _header_params['Content-Type'] = _default_content_type
4057
+
4058
+ # authentication setting
4059
+ _auth_settings: List[str] = [
4060
+ 'ApiKeyAuth'
4061
+ ]
4062
+
4063
+ return self.api_client.param_serialize(
4064
+ method='PUT',
4065
+ resource_path='/api/settings/rbac/mappings/identityProvider/restrictEmptyIdpGroups',
4066
+ path_params=_path_params,
4067
+ query_params=_query_params,
4068
+ header_params=_header_params,
4069
+ body=_body_params,
4070
+ post_params=_form_params,
4071
+ files=_files,
4072
+ auth_settings=_auth_settings,
4073
+ collection_formats=_collection_formats,
4074
+ _host=_host,
4075
+ _request_auth=_request_auth
4076
+ )
4077
+
4078
+