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,3745 @@
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, StrictBytes, StrictStr
21
+ from typing import List, Optional, Tuple, Union
22
+ from typing_extensions import Annotated
23
+ from instana_client.models.geo_location_configuration import GeoLocationConfiguration
24
+ from instana_client.models.ip_masking_configuration import IpMaskingConfiguration
25
+ from instana_client.models.source_map_upload_config import SourceMapUploadConfig
26
+ from instana_client.models.website import Website
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 WebsiteConfigurationApi:
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 clear_source_map_upload_configuration(
48
+ self,
49
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
50
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
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
+ ) -> None:
64
+ """Clear source map files for source map upload configuration
65
+
66
+ API request to clear source map files for source map upload configuration.
67
+
68
+ :param website_id: Website ID (required)
69
+ :type website_id: str
70
+ :param source_map_config_id: Source Map Config ID (required)
71
+ :type source_map_config_id: 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._clear_source_map_upload_configuration_serialize(
95
+ website_id=website_id,
96
+ source_map_config_id=source_map_config_id,
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
+ '204': None,
105
+ '401': None,
106
+ '403': None,
107
+ '404': None,
108
+ '500': None,
109
+ }
110
+ response_data = self.api_client.call_api(
111
+ *_param,
112
+ _request_timeout=_request_timeout
113
+ )
114
+ response_data.read()
115
+ return self.api_client.response_deserialize(
116
+ response_data=response_data,
117
+ response_types_map=_response_types_map,
118
+ ).data
119
+
120
+
121
+ @validate_call
122
+ def clear_source_map_upload_configuration_with_http_info(
123
+ self,
124
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
125
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
126
+ _request_timeout: Union[
127
+ None,
128
+ Annotated[StrictFloat, Field(gt=0)],
129
+ Tuple[
130
+ Annotated[StrictFloat, Field(gt=0)],
131
+ Annotated[StrictFloat, Field(gt=0)]
132
+ ]
133
+ ] = None,
134
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
135
+ _content_type: Optional[StrictStr] = None,
136
+ _headers: Optional[Dict[StrictStr, Any]] = None,
137
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
138
+ ) -> ApiResponse[None]:
139
+ """Clear source map files for source map upload configuration
140
+
141
+ API request to clear source map files for source map upload configuration.
142
+
143
+ :param website_id: Website ID (required)
144
+ :type website_id: str
145
+ :param source_map_config_id: Source Map Config ID (required)
146
+ :type source_map_config_id: str
147
+ :param _request_timeout: timeout setting for this request. If one
148
+ number provided, it will be total request
149
+ timeout. It can also be a pair (tuple) of
150
+ (connection, read) timeouts.
151
+ :type _request_timeout: int, tuple(int, int), optional
152
+ :param _request_auth: set to override the auth_settings for an a single
153
+ request; this effectively ignores the
154
+ authentication in the spec for a single request.
155
+ :type _request_auth: dict, optional
156
+ :param _content_type: force content-type for the request.
157
+ :type _content_type: str, Optional
158
+ :param _headers: set to override the headers for a single
159
+ request; this effectively ignores the headers
160
+ in the spec for a single request.
161
+ :type _headers: dict, optional
162
+ :param _host_index: set to override the host_index for a single
163
+ request; this effectively ignores the host_index
164
+ in the spec for a single request.
165
+ :type _host_index: int, optional
166
+ :return: Returns the result object.
167
+ """ # noqa: E501
168
+
169
+ _param = self._clear_source_map_upload_configuration_serialize(
170
+ website_id=website_id,
171
+ source_map_config_id=source_map_config_id,
172
+ _request_auth=_request_auth,
173
+ _content_type=_content_type,
174
+ _headers=_headers,
175
+ _host_index=_host_index
176
+ )
177
+
178
+ _response_types_map: Dict[str, Optional[str]] = {
179
+ '204': None,
180
+ '401': None,
181
+ '403': None,
182
+ '404': None,
183
+ '500': None,
184
+ }
185
+ response_data = self.api_client.call_api(
186
+ *_param,
187
+ _request_timeout=_request_timeout
188
+ )
189
+ response_data.read()
190
+ return self.api_client.response_deserialize(
191
+ response_data=response_data,
192
+ response_types_map=_response_types_map,
193
+ )
194
+
195
+
196
+ @validate_call
197
+ def clear_source_map_upload_configuration_without_preload_content(
198
+ self,
199
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
200
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
201
+ _request_timeout: Union[
202
+ None,
203
+ Annotated[StrictFloat, Field(gt=0)],
204
+ Tuple[
205
+ Annotated[StrictFloat, Field(gt=0)],
206
+ Annotated[StrictFloat, Field(gt=0)]
207
+ ]
208
+ ] = None,
209
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
210
+ _content_type: Optional[StrictStr] = None,
211
+ _headers: Optional[Dict[StrictStr, Any]] = None,
212
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
213
+ ) -> RESTResponseType:
214
+ """Clear source map files for source map upload configuration
215
+
216
+ API request to clear source map files for source map upload configuration.
217
+
218
+ :param website_id: Website ID (required)
219
+ :type website_id: str
220
+ :param source_map_config_id: Source Map Config ID (required)
221
+ :type source_map_config_id: str
222
+ :param _request_timeout: timeout setting for this request. If one
223
+ number provided, it will be total request
224
+ timeout. It can also be a pair (tuple) of
225
+ (connection, read) timeouts.
226
+ :type _request_timeout: int, tuple(int, int), optional
227
+ :param _request_auth: set to override the auth_settings for an a single
228
+ request; this effectively ignores the
229
+ authentication in the spec for a single request.
230
+ :type _request_auth: dict, optional
231
+ :param _content_type: force content-type for the request.
232
+ :type _content_type: str, Optional
233
+ :param _headers: set to override the headers for a single
234
+ request; this effectively ignores the headers
235
+ in the spec for a single request.
236
+ :type _headers: dict, optional
237
+ :param _host_index: set to override the host_index for a single
238
+ request; this effectively ignores the host_index
239
+ in the spec for a single request.
240
+ :type _host_index: int, optional
241
+ :return: Returns the result object.
242
+ """ # noqa: E501
243
+
244
+ _param = self._clear_source_map_upload_configuration_serialize(
245
+ website_id=website_id,
246
+ source_map_config_id=source_map_config_id,
247
+ _request_auth=_request_auth,
248
+ _content_type=_content_type,
249
+ _headers=_headers,
250
+ _host_index=_host_index
251
+ )
252
+
253
+ _response_types_map: Dict[str, Optional[str]] = {
254
+ '204': None,
255
+ '401': None,
256
+ '403': None,
257
+ '404': None,
258
+ '500': None,
259
+ }
260
+ response_data = self.api_client.call_api(
261
+ *_param,
262
+ _request_timeout=_request_timeout
263
+ )
264
+ return response_data.response
265
+
266
+
267
+ def _clear_source_map_upload_configuration_serialize(
268
+ self,
269
+ website_id,
270
+ source_map_config_id,
271
+ _request_auth,
272
+ _content_type,
273
+ _headers,
274
+ _host_index,
275
+ ) -> RequestSerialized:
276
+
277
+ _host = None
278
+
279
+ _collection_formats: Dict[str, str] = {
280
+ }
281
+
282
+ _path_params: Dict[str, str] = {}
283
+ _query_params: List[Tuple[str, str]] = []
284
+ _header_params: Dict[str, Optional[str]] = _headers or {}
285
+ _form_params: List[Tuple[str, str]] = []
286
+ _files: Dict[
287
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
288
+ ] = {}
289
+ _body_params: Optional[bytes] = None
290
+
291
+ # process the path parameters
292
+ if website_id is not None:
293
+ _path_params['websiteId'] = website_id
294
+ if source_map_config_id is not None:
295
+ _path_params['sourceMapConfigId'] = source_map_config_id
296
+ # process the query parameters
297
+ # process the header parameters
298
+ # process the form parameters
299
+ # process the body parameter
300
+
301
+
302
+
303
+
304
+ # authentication setting
305
+ _auth_settings: List[str] = [
306
+ 'ApiKeyAuth'
307
+ ]
308
+
309
+ return self.api_client.param_serialize(
310
+ method='PUT',
311
+ resource_path='/api/website-monitoring/config/{websiteId}/sourcemap-upload/{sourceMapConfigId}/clear',
312
+ path_params=_path_params,
313
+ query_params=_query_params,
314
+ header_params=_header_params,
315
+ body=_body_params,
316
+ post_params=_form_params,
317
+ files=_files,
318
+ auth_settings=_auth_settings,
319
+ collection_formats=_collection_formats,
320
+ _host=_host,
321
+ _request_auth=_request_auth
322
+ )
323
+
324
+
325
+
326
+
327
+ @validate_call
328
+ def create_website(
329
+ self,
330
+ name: Optional[StrictStr] = None,
331
+ _request_timeout: Union[
332
+ None,
333
+ Annotated[StrictFloat, Field(gt=0)],
334
+ Tuple[
335
+ Annotated[StrictFloat, Field(gt=0)],
336
+ Annotated[StrictFloat, Field(gt=0)]
337
+ ]
338
+ ] = None,
339
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
340
+ _content_type: Optional[StrictStr] = None,
341
+ _headers: Optional[Dict[StrictStr, Any]] = None,
342
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
343
+ ) -> Website:
344
+ """Configure new website
345
+
346
+ API request to add new website.
347
+
348
+ :param name:
349
+ :type name: str
350
+ :param _request_timeout: timeout setting for this request. If one
351
+ number provided, it will be total request
352
+ timeout. It can also be a pair (tuple) of
353
+ (connection, read) timeouts.
354
+ :type _request_timeout: int, tuple(int, int), optional
355
+ :param _request_auth: set to override the auth_settings for an a single
356
+ request; this effectively ignores the
357
+ authentication in the spec for a single request.
358
+ :type _request_auth: dict, optional
359
+ :param _content_type: force content-type for the request.
360
+ :type _content_type: str, Optional
361
+ :param _headers: set to override the headers for a single
362
+ request; this effectively ignores the headers
363
+ in the spec for a single request.
364
+ :type _headers: dict, optional
365
+ :param _host_index: set to override the host_index for a single
366
+ request; this effectively ignores the host_index
367
+ in the spec for a single request.
368
+ :type _host_index: int, optional
369
+ :return: Returns the result object.
370
+ """ # noqa: E501
371
+
372
+ _param = self._create_website_serialize(
373
+ name=name,
374
+ _request_auth=_request_auth,
375
+ _content_type=_content_type,
376
+ _headers=_headers,
377
+ _host_index=_host_index
378
+ )
379
+
380
+ _response_types_map: Dict[str, Optional[str]] = {
381
+ '200': "Website",
382
+ '400': None,
383
+ '401': None,
384
+ '403': None,
385
+ '500': None,
386
+ }
387
+ response_data = self.api_client.call_api(
388
+ *_param,
389
+ _request_timeout=_request_timeout
390
+ )
391
+ response_data.read()
392
+ return self.api_client.response_deserialize(
393
+ response_data=response_data,
394
+ response_types_map=_response_types_map,
395
+ ).data
396
+
397
+
398
+ @validate_call
399
+ def create_website_with_http_info(
400
+ self,
401
+ name: Optional[StrictStr] = None,
402
+ _request_timeout: Union[
403
+ None,
404
+ Annotated[StrictFloat, Field(gt=0)],
405
+ Tuple[
406
+ Annotated[StrictFloat, Field(gt=0)],
407
+ Annotated[StrictFloat, Field(gt=0)]
408
+ ]
409
+ ] = None,
410
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
411
+ _content_type: Optional[StrictStr] = None,
412
+ _headers: Optional[Dict[StrictStr, Any]] = None,
413
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
414
+ ) -> ApiResponse[Website]:
415
+ """Configure new website
416
+
417
+ API request to add new website.
418
+
419
+ :param name:
420
+ :type name: str
421
+ :param _request_timeout: timeout setting for this request. If one
422
+ number provided, it will be total request
423
+ timeout. It can also be a pair (tuple) of
424
+ (connection, read) timeouts.
425
+ :type _request_timeout: int, tuple(int, int), optional
426
+ :param _request_auth: set to override the auth_settings for an a single
427
+ request; this effectively ignores the
428
+ authentication in the spec for a single request.
429
+ :type _request_auth: dict, optional
430
+ :param _content_type: force content-type for the request.
431
+ :type _content_type: str, Optional
432
+ :param _headers: set to override the headers for a single
433
+ request; this effectively ignores the headers
434
+ in the spec for a single request.
435
+ :type _headers: dict, optional
436
+ :param _host_index: set to override the host_index for a single
437
+ request; this effectively ignores the host_index
438
+ in the spec for a single request.
439
+ :type _host_index: int, optional
440
+ :return: Returns the result object.
441
+ """ # noqa: E501
442
+
443
+ _param = self._create_website_serialize(
444
+ name=name,
445
+ _request_auth=_request_auth,
446
+ _content_type=_content_type,
447
+ _headers=_headers,
448
+ _host_index=_host_index
449
+ )
450
+
451
+ _response_types_map: Dict[str, Optional[str]] = {
452
+ '200': "Website",
453
+ '400': None,
454
+ '401': None,
455
+ '403': None,
456
+ '500': None,
457
+ }
458
+ response_data = self.api_client.call_api(
459
+ *_param,
460
+ _request_timeout=_request_timeout
461
+ )
462
+ response_data.read()
463
+ return self.api_client.response_deserialize(
464
+ response_data=response_data,
465
+ response_types_map=_response_types_map,
466
+ )
467
+
468
+
469
+ @validate_call
470
+ def create_website_without_preload_content(
471
+ self,
472
+ name: Optional[StrictStr] = None,
473
+ _request_timeout: Union[
474
+ None,
475
+ Annotated[StrictFloat, Field(gt=0)],
476
+ Tuple[
477
+ Annotated[StrictFloat, Field(gt=0)],
478
+ Annotated[StrictFloat, Field(gt=0)]
479
+ ]
480
+ ] = None,
481
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
482
+ _content_type: Optional[StrictStr] = None,
483
+ _headers: Optional[Dict[StrictStr, Any]] = None,
484
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
485
+ ) -> RESTResponseType:
486
+ """Configure new website
487
+
488
+ API request to add new website.
489
+
490
+ :param name:
491
+ :type name: str
492
+ :param _request_timeout: timeout setting for this request. If one
493
+ number provided, it will be total request
494
+ timeout. It can also be a pair (tuple) of
495
+ (connection, read) timeouts.
496
+ :type _request_timeout: int, tuple(int, int), optional
497
+ :param _request_auth: set to override the auth_settings for an a single
498
+ request; this effectively ignores the
499
+ authentication in the spec for a single request.
500
+ :type _request_auth: dict, optional
501
+ :param _content_type: force content-type for the request.
502
+ :type _content_type: str, Optional
503
+ :param _headers: set to override the headers for a single
504
+ request; this effectively ignores the headers
505
+ in the spec for a single request.
506
+ :type _headers: dict, optional
507
+ :param _host_index: set to override the host_index for a single
508
+ request; this effectively ignores the host_index
509
+ in the spec for a single request.
510
+ :type _host_index: int, optional
511
+ :return: Returns the result object.
512
+ """ # noqa: E501
513
+
514
+ _param = self._create_website_serialize(
515
+ name=name,
516
+ _request_auth=_request_auth,
517
+ _content_type=_content_type,
518
+ _headers=_headers,
519
+ _host_index=_host_index
520
+ )
521
+
522
+ _response_types_map: Dict[str, Optional[str]] = {
523
+ '200': "Website",
524
+ '400': None,
525
+ '401': None,
526
+ '403': None,
527
+ '500': None,
528
+ }
529
+ response_data = self.api_client.call_api(
530
+ *_param,
531
+ _request_timeout=_request_timeout
532
+ )
533
+ return response_data.response
534
+
535
+
536
+ def _create_website_serialize(
537
+ self,
538
+ name,
539
+ _request_auth,
540
+ _content_type,
541
+ _headers,
542
+ _host_index,
543
+ ) -> RequestSerialized:
544
+
545
+ _host = None
546
+
547
+ _collection_formats: Dict[str, str] = {
548
+ }
549
+
550
+ _path_params: Dict[str, str] = {}
551
+ _query_params: List[Tuple[str, str]] = []
552
+ _header_params: Dict[str, Optional[str]] = _headers or {}
553
+ _form_params: List[Tuple[str, str]] = []
554
+ _files: Dict[
555
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
556
+ ] = {}
557
+ _body_params: Optional[bytes] = None
558
+
559
+ # process the path parameters
560
+ # process the query parameters
561
+ if name is not None:
562
+
563
+ _query_params.append(('name', name))
564
+
565
+ # process the header parameters
566
+ # process the form parameters
567
+ # process the body parameter
568
+
569
+
570
+ # set the HTTP header `Accept`
571
+ if 'Accept' not in _header_params:
572
+ _header_params['Accept'] = self.api_client.select_header_accept(
573
+ [
574
+ 'application/json'
575
+ ]
576
+ )
577
+
578
+
579
+ # authentication setting
580
+ _auth_settings: List[str] = [
581
+ 'ApiKeyAuth'
582
+ ]
583
+
584
+ return self.api_client.param_serialize(
585
+ method='POST',
586
+ resource_path='/api/website-monitoring/config',
587
+ path_params=_path_params,
588
+ query_params=_query_params,
589
+ header_params=_header_params,
590
+ body=_body_params,
591
+ post_params=_form_params,
592
+ files=_files,
593
+ auth_settings=_auth_settings,
594
+ collection_formats=_collection_formats,
595
+ _host=_host,
596
+ _request_auth=_request_auth
597
+ )
598
+
599
+
600
+
601
+
602
+ @validate_call
603
+ def delete_website(
604
+ self,
605
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
606
+ _request_timeout: Union[
607
+ None,
608
+ Annotated[StrictFloat, Field(gt=0)],
609
+ Tuple[
610
+ Annotated[StrictFloat, Field(gt=0)],
611
+ Annotated[StrictFloat, Field(gt=0)]
612
+ ]
613
+ ] = None,
614
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
615
+ _content_type: Optional[StrictStr] = None,
616
+ _headers: Optional[Dict[StrictStr, Any]] = None,
617
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
618
+ ) -> None:
619
+ """Remove website
620
+
621
+ API request to delete website.
622
+
623
+ :param website_id: websiteId (required)
624
+ :type website_id: str
625
+ :param _request_timeout: timeout setting for this request. If one
626
+ number provided, it will be total request
627
+ timeout. It can also be a pair (tuple) of
628
+ (connection, read) timeouts.
629
+ :type _request_timeout: int, tuple(int, int), optional
630
+ :param _request_auth: set to override the auth_settings for an a single
631
+ request; this effectively ignores the
632
+ authentication in the spec for a single request.
633
+ :type _request_auth: dict, optional
634
+ :param _content_type: force content-type for the request.
635
+ :type _content_type: str, Optional
636
+ :param _headers: set to override the headers for a single
637
+ request; this effectively ignores the headers
638
+ in the spec for a single request.
639
+ :type _headers: dict, optional
640
+ :param _host_index: set to override the host_index for a single
641
+ request; this effectively ignores the host_index
642
+ in the spec for a single request.
643
+ :type _host_index: int, optional
644
+ :return: Returns the result object.
645
+ """ # noqa: E501
646
+
647
+ _param = self._delete_website_serialize(
648
+ website_id=website_id,
649
+ _request_auth=_request_auth,
650
+ _content_type=_content_type,
651
+ _headers=_headers,
652
+ _host_index=_host_index
653
+ )
654
+
655
+ _response_types_map: Dict[str, Optional[str]] = {
656
+ '204': None,
657
+ '401': None,
658
+ '403': None,
659
+ '500': None,
660
+ }
661
+ response_data = self.api_client.call_api(
662
+ *_param,
663
+ _request_timeout=_request_timeout
664
+ )
665
+ response_data.read()
666
+ return self.api_client.response_deserialize(
667
+ response_data=response_data,
668
+ response_types_map=_response_types_map,
669
+ ).data
670
+
671
+
672
+ @validate_call
673
+ def delete_website_with_http_info(
674
+ self,
675
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
676
+ _request_timeout: Union[
677
+ None,
678
+ Annotated[StrictFloat, Field(gt=0)],
679
+ Tuple[
680
+ Annotated[StrictFloat, Field(gt=0)],
681
+ Annotated[StrictFloat, Field(gt=0)]
682
+ ]
683
+ ] = None,
684
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
685
+ _content_type: Optional[StrictStr] = None,
686
+ _headers: Optional[Dict[StrictStr, Any]] = None,
687
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
688
+ ) -> ApiResponse[None]:
689
+ """Remove website
690
+
691
+ API request to delete website.
692
+
693
+ :param website_id: websiteId (required)
694
+ :type website_id: str
695
+ :param _request_timeout: timeout setting for this request. If one
696
+ number provided, it will be total request
697
+ timeout. It can also be a pair (tuple) of
698
+ (connection, read) timeouts.
699
+ :type _request_timeout: int, tuple(int, int), optional
700
+ :param _request_auth: set to override the auth_settings for an a single
701
+ request; this effectively ignores the
702
+ authentication in the spec for a single request.
703
+ :type _request_auth: dict, optional
704
+ :param _content_type: force content-type for the request.
705
+ :type _content_type: str, Optional
706
+ :param _headers: set to override the headers for a single
707
+ request; this effectively ignores the headers
708
+ in the spec for a single request.
709
+ :type _headers: dict, optional
710
+ :param _host_index: set to override the host_index for a single
711
+ request; this effectively ignores the host_index
712
+ in the spec for a single request.
713
+ :type _host_index: int, optional
714
+ :return: Returns the result object.
715
+ """ # noqa: E501
716
+
717
+ _param = self._delete_website_serialize(
718
+ website_id=website_id,
719
+ _request_auth=_request_auth,
720
+ _content_type=_content_type,
721
+ _headers=_headers,
722
+ _host_index=_host_index
723
+ )
724
+
725
+ _response_types_map: Dict[str, Optional[str]] = {
726
+ '204': None,
727
+ '401': None,
728
+ '403': None,
729
+ '500': None,
730
+ }
731
+ response_data = self.api_client.call_api(
732
+ *_param,
733
+ _request_timeout=_request_timeout
734
+ )
735
+ response_data.read()
736
+ return self.api_client.response_deserialize(
737
+ response_data=response_data,
738
+ response_types_map=_response_types_map,
739
+ )
740
+
741
+
742
+ @validate_call
743
+ def delete_website_without_preload_content(
744
+ self,
745
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
746
+ _request_timeout: Union[
747
+ None,
748
+ Annotated[StrictFloat, Field(gt=0)],
749
+ Tuple[
750
+ Annotated[StrictFloat, Field(gt=0)],
751
+ Annotated[StrictFloat, Field(gt=0)]
752
+ ]
753
+ ] = None,
754
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
755
+ _content_type: Optional[StrictStr] = None,
756
+ _headers: Optional[Dict[StrictStr, Any]] = None,
757
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
758
+ ) -> RESTResponseType:
759
+ """Remove website
760
+
761
+ API request to delete website.
762
+
763
+ :param website_id: websiteId (required)
764
+ :type website_id: str
765
+ :param _request_timeout: timeout setting for this request. If one
766
+ number provided, it will be total request
767
+ timeout. It can also be a pair (tuple) of
768
+ (connection, read) timeouts.
769
+ :type _request_timeout: int, tuple(int, int), optional
770
+ :param _request_auth: set to override the auth_settings for an a single
771
+ request; this effectively ignores the
772
+ authentication in the spec for a single request.
773
+ :type _request_auth: dict, optional
774
+ :param _content_type: force content-type for the request.
775
+ :type _content_type: str, Optional
776
+ :param _headers: set to override the headers for a single
777
+ request; this effectively ignores the headers
778
+ in the spec for a single request.
779
+ :type _headers: dict, optional
780
+ :param _host_index: set to override the host_index for a single
781
+ request; this effectively ignores the host_index
782
+ in the spec for a single request.
783
+ :type _host_index: int, optional
784
+ :return: Returns the result object.
785
+ """ # noqa: E501
786
+
787
+ _param = self._delete_website_serialize(
788
+ website_id=website_id,
789
+ _request_auth=_request_auth,
790
+ _content_type=_content_type,
791
+ _headers=_headers,
792
+ _host_index=_host_index
793
+ )
794
+
795
+ _response_types_map: Dict[str, Optional[str]] = {
796
+ '204': None,
797
+ '401': None,
798
+ '403': None,
799
+ '500': None,
800
+ }
801
+ response_data = self.api_client.call_api(
802
+ *_param,
803
+ _request_timeout=_request_timeout
804
+ )
805
+ return response_data.response
806
+
807
+
808
+ def _delete_website_serialize(
809
+ self,
810
+ website_id,
811
+ _request_auth,
812
+ _content_type,
813
+ _headers,
814
+ _host_index,
815
+ ) -> RequestSerialized:
816
+
817
+ _host = None
818
+
819
+ _collection_formats: Dict[str, str] = {
820
+ }
821
+
822
+ _path_params: Dict[str, str] = {}
823
+ _query_params: List[Tuple[str, str]] = []
824
+ _header_params: Dict[str, Optional[str]] = _headers or {}
825
+ _form_params: List[Tuple[str, str]] = []
826
+ _files: Dict[
827
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
828
+ ] = {}
829
+ _body_params: Optional[bytes] = None
830
+
831
+ # process the path parameters
832
+ if website_id is not None:
833
+ _path_params['websiteId'] = website_id
834
+ # process the query parameters
835
+ # process the header parameters
836
+ # process the form parameters
837
+ # process the body parameter
838
+
839
+
840
+
841
+
842
+ # authentication setting
843
+ _auth_settings: List[str] = [
844
+ 'ApiKeyAuth'
845
+ ]
846
+
847
+ return self.api_client.param_serialize(
848
+ method='DELETE',
849
+ resource_path='/api/website-monitoring/config/{websiteId}',
850
+ path_params=_path_params,
851
+ query_params=_query_params,
852
+ header_params=_header_params,
853
+ body=_body_params,
854
+ post_params=_form_params,
855
+ files=_files,
856
+ auth_settings=_auth_settings,
857
+ collection_formats=_collection_formats,
858
+ _host=_host,
859
+ _request_auth=_request_auth
860
+ )
861
+
862
+
863
+
864
+
865
+ @validate_call
866
+ def get_website(
867
+ self,
868
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
869
+ _request_timeout: Union[
870
+ None,
871
+ Annotated[StrictFloat, Field(gt=0)],
872
+ Tuple[
873
+ Annotated[StrictFloat, Field(gt=0)],
874
+ Annotated[StrictFloat, Field(gt=0)]
875
+ ]
876
+ ] = None,
877
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
878
+ _content_type: Optional[StrictStr] = None,
879
+ _headers: Optional[Dict[StrictStr, Any]] = None,
880
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
881
+ ) -> Website:
882
+ """Get configured website
883
+
884
+ API request to get configured website details for specified websiteId
885
+
886
+ :param website_id: websiteId (required)
887
+ :type website_id: str
888
+ :param _request_timeout: timeout setting for this request. If one
889
+ number provided, it will be total request
890
+ timeout. It can also be a pair (tuple) of
891
+ (connection, read) timeouts.
892
+ :type _request_timeout: int, tuple(int, int), optional
893
+ :param _request_auth: set to override the auth_settings for an a single
894
+ request; this effectively ignores the
895
+ authentication in the spec for a single request.
896
+ :type _request_auth: dict, optional
897
+ :param _content_type: force content-type for the request.
898
+ :type _content_type: str, Optional
899
+ :param _headers: set to override the headers for a single
900
+ request; this effectively ignores the headers
901
+ in the spec for a single request.
902
+ :type _headers: dict, optional
903
+ :param _host_index: set to override the host_index for a single
904
+ request; this effectively ignores the host_index
905
+ in the spec for a single request.
906
+ :type _host_index: int, optional
907
+ :return: Returns the result object.
908
+ """ # noqa: E501
909
+
910
+ _param = self._get_website_serialize(
911
+ website_id=website_id,
912
+ _request_auth=_request_auth,
913
+ _content_type=_content_type,
914
+ _headers=_headers,
915
+ _host_index=_host_index
916
+ )
917
+
918
+ _response_types_map: Dict[str, Optional[str]] = {
919
+ '200': "Website",
920
+ '401': None,
921
+ '500': None,
922
+ }
923
+ response_data = self.api_client.call_api(
924
+ *_param,
925
+ _request_timeout=_request_timeout
926
+ )
927
+ response_data.read()
928
+ return self.api_client.response_deserialize(
929
+ response_data=response_data,
930
+ response_types_map=_response_types_map,
931
+ ).data
932
+
933
+
934
+ @validate_call
935
+ def get_website_with_http_info(
936
+ self,
937
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
938
+ _request_timeout: Union[
939
+ None,
940
+ Annotated[StrictFloat, Field(gt=0)],
941
+ Tuple[
942
+ Annotated[StrictFloat, Field(gt=0)],
943
+ Annotated[StrictFloat, Field(gt=0)]
944
+ ]
945
+ ] = None,
946
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
947
+ _content_type: Optional[StrictStr] = None,
948
+ _headers: Optional[Dict[StrictStr, Any]] = None,
949
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
950
+ ) -> ApiResponse[Website]:
951
+ """Get configured website
952
+
953
+ API request to get configured website details for specified websiteId
954
+
955
+ :param website_id: websiteId (required)
956
+ :type website_id: str
957
+ :param _request_timeout: timeout setting for this request. If one
958
+ number provided, it will be total request
959
+ timeout. It can also be a pair (tuple) of
960
+ (connection, read) timeouts.
961
+ :type _request_timeout: int, tuple(int, int), optional
962
+ :param _request_auth: set to override the auth_settings for an a single
963
+ request; this effectively ignores the
964
+ authentication in the spec for a single request.
965
+ :type _request_auth: dict, optional
966
+ :param _content_type: force content-type for the request.
967
+ :type _content_type: str, Optional
968
+ :param _headers: set to override the headers for a single
969
+ request; this effectively ignores the headers
970
+ in the spec for a single request.
971
+ :type _headers: dict, optional
972
+ :param _host_index: set to override the host_index for a single
973
+ request; this effectively ignores the host_index
974
+ in the spec for a single request.
975
+ :type _host_index: int, optional
976
+ :return: Returns the result object.
977
+ """ # noqa: E501
978
+
979
+ _param = self._get_website_serialize(
980
+ website_id=website_id,
981
+ _request_auth=_request_auth,
982
+ _content_type=_content_type,
983
+ _headers=_headers,
984
+ _host_index=_host_index
985
+ )
986
+
987
+ _response_types_map: Dict[str, Optional[str]] = {
988
+ '200': "Website",
989
+ '401': None,
990
+ '500': None,
991
+ }
992
+ response_data = self.api_client.call_api(
993
+ *_param,
994
+ _request_timeout=_request_timeout
995
+ )
996
+ response_data.read()
997
+ return self.api_client.response_deserialize(
998
+ response_data=response_data,
999
+ response_types_map=_response_types_map,
1000
+ )
1001
+
1002
+
1003
+ @validate_call
1004
+ def get_website_without_preload_content(
1005
+ self,
1006
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1007
+ _request_timeout: Union[
1008
+ None,
1009
+ Annotated[StrictFloat, Field(gt=0)],
1010
+ Tuple[
1011
+ Annotated[StrictFloat, Field(gt=0)],
1012
+ Annotated[StrictFloat, Field(gt=0)]
1013
+ ]
1014
+ ] = None,
1015
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1016
+ _content_type: Optional[StrictStr] = None,
1017
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1018
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1019
+ ) -> RESTResponseType:
1020
+ """Get configured website
1021
+
1022
+ API request to get configured website details for specified websiteId
1023
+
1024
+ :param website_id: websiteId (required)
1025
+ :type website_id: str
1026
+ :param _request_timeout: timeout setting for this request. If one
1027
+ number provided, it will be total request
1028
+ timeout. It can also be a pair (tuple) of
1029
+ (connection, read) timeouts.
1030
+ :type _request_timeout: int, tuple(int, int), optional
1031
+ :param _request_auth: set to override the auth_settings for an a single
1032
+ request; this effectively ignores the
1033
+ authentication in the spec for a single request.
1034
+ :type _request_auth: dict, optional
1035
+ :param _content_type: force content-type for the request.
1036
+ :type _content_type: str, Optional
1037
+ :param _headers: set to override the headers for a single
1038
+ request; this effectively ignores the headers
1039
+ in the spec for a single request.
1040
+ :type _headers: dict, optional
1041
+ :param _host_index: set to override the host_index for a single
1042
+ request; this effectively ignores the host_index
1043
+ in the spec for a single request.
1044
+ :type _host_index: int, optional
1045
+ :return: Returns the result object.
1046
+ """ # noqa: E501
1047
+
1048
+ _param = self._get_website_serialize(
1049
+ website_id=website_id,
1050
+ _request_auth=_request_auth,
1051
+ _content_type=_content_type,
1052
+ _headers=_headers,
1053
+ _host_index=_host_index
1054
+ )
1055
+
1056
+ _response_types_map: Dict[str, Optional[str]] = {
1057
+ '200': "Website",
1058
+ '401': None,
1059
+ '500': None,
1060
+ }
1061
+ response_data = self.api_client.call_api(
1062
+ *_param,
1063
+ _request_timeout=_request_timeout
1064
+ )
1065
+ return response_data.response
1066
+
1067
+
1068
+ def _get_website_serialize(
1069
+ self,
1070
+ website_id,
1071
+ _request_auth,
1072
+ _content_type,
1073
+ _headers,
1074
+ _host_index,
1075
+ ) -> RequestSerialized:
1076
+
1077
+ _host = None
1078
+
1079
+ _collection_formats: Dict[str, str] = {
1080
+ }
1081
+
1082
+ _path_params: Dict[str, str] = {}
1083
+ _query_params: List[Tuple[str, str]] = []
1084
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1085
+ _form_params: List[Tuple[str, str]] = []
1086
+ _files: Dict[
1087
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1088
+ ] = {}
1089
+ _body_params: Optional[bytes] = None
1090
+
1091
+ # process the path parameters
1092
+ if website_id is not None:
1093
+ _path_params['websiteId'] = website_id
1094
+ # process the query parameters
1095
+ # process the header parameters
1096
+ # process the form parameters
1097
+ # process the body parameter
1098
+
1099
+
1100
+ # set the HTTP header `Accept`
1101
+ if 'Accept' not in _header_params:
1102
+ _header_params['Accept'] = self.api_client.select_header_accept(
1103
+ [
1104
+ 'application/json'
1105
+ ]
1106
+ )
1107
+
1108
+
1109
+ # authentication setting
1110
+ _auth_settings: List[str] = [
1111
+ 'ApiKeyAuth'
1112
+ ]
1113
+
1114
+ return self.api_client.param_serialize(
1115
+ method='GET',
1116
+ resource_path='/api/website-monitoring/config/{websiteId}',
1117
+ path_params=_path_params,
1118
+ query_params=_query_params,
1119
+ header_params=_header_params,
1120
+ body=_body_params,
1121
+ post_params=_form_params,
1122
+ files=_files,
1123
+ auth_settings=_auth_settings,
1124
+ collection_formats=_collection_formats,
1125
+ _host=_host,
1126
+ _request_auth=_request_auth
1127
+ )
1128
+
1129
+
1130
+
1131
+
1132
+ @validate_call
1133
+ def get_website_geo_location_configuration(
1134
+ self,
1135
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1136
+ _request_timeout: Union[
1137
+ None,
1138
+ Annotated[StrictFloat, Field(gt=0)],
1139
+ Tuple[
1140
+ Annotated[StrictFloat, Field(gt=0)],
1141
+ Annotated[StrictFloat, Field(gt=0)]
1142
+ ]
1143
+ ] = None,
1144
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1145
+ _content_type: Optional[StrictStr] = None,
1146
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1147
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1148
+ ) -> GeoLocationConfiguration:
1149
+ """Get geo location configuration for website
1150
+
1151
+ API request to get geo-location configuration of a website specified by its websiteId
1152
+
1153
+ :param website_id: websiteId (required)
1154
+ :type website_id: str
1155
+ :param _request_timeout: timeout setting for this request. If one
1156
+ number provided, it will be total request
1157
+ timeout. It can also be a pair (tuple) of
1158
+ (connection, read) timeouts.
1159
+ :type _request_timeout: int, tuple(int, int), optional
1160
+ :param _request_auth: set to override the auth_settings for an a single
1161
+ request; this effectively ignores the
1162
+ authentication in the spec for a single request.
1163
+ :type _request_auth: dict, optional
1164
+ :param _content_type: force content-type for the request.
1165
+ :type _content_type: str, Optional
1166
+ :param _headers: set to override the headers for a single
1167
+ request; this effectively ignores the headers
1168
+ in the spec for a single request.
1169
+ :type _headers: dict, optional
1170
+ :param _host_index: set to override the host_index for a single
1171
+ request; this effectively ignores the host_index
1172
+ in the spec for a single request.
1173
+ :type _host_index: int, optional
1174
+ :return: Returns the result object.
1175
+ """ # noqa: E501
1176
+
1177
+ _param = self._get_website_geo_location_configuration_serialize(
1178
+ website_id=website_id,
1179
+ _request_auth=_request_auth,
1180
+ _content_type=_content_type,
1181
+ _headers=_headers,
1182
+ _host_index=_host_index
1183
+ )
1184
+
1185
+ _response_types_map: Dict[str, Optional[str]] = {
1186
+ '200': "GeoLocationConfiguration",
1187
+ '401': None,
1188
+ '403': None,
1189
+ '404': None,
1190
+ '500': None,
1191
+ }
1192
+ response_data = self.api_client.call_api(
1193
+ *_param,
1194
+ _request_timeout=_request_timeout
1195
+ )
1196
+ response_data.read()
1197
+ return self.api_client.response_deserialize(
1198
+ response_data=response_data,
1199
+ response_types_map=_response_types_map,
1200
+ ).data
1201
+
1202
+
1203
+ @validate_call
1204
+ def get_website_geo_location_configuration_with_http_info(
1205
+ self,
1206
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1207
+ _request_timeout: Union[
1208
+ None,
1209
+ Annotated[StrictFloat, Field(gt=0)],
1210
+ Tuple[
1211
+ Annotated[StrictFloat, Field(gt=0)],
1212
+ Annotated[StrictFloat, Field(gt=0)]
1213
+ ]
1214
+ ] = None,
1215
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1216
+ _content_type: Optional[StrictStr] = None,
1217
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1218
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1219
+ ) -> ApiResponse[GeoLocationConfiguration]:
1220
+ """Get geo location configuration for website
1221
+
1222
+ API request to get geo-location configuration of a website specified by its websiteId
1223
+
1224
+ :param website_id: websiteId (required)
1225
+ :type website_id: str
1226
+ :param _request_timeout: timeout setting for this request. If one
1227
+ number provided, it will be total request
1228
+ timeout. It can also be a pair (tuple) of
1229
+ (connection, read) timeouts.
1230
+ :type _request_timeout: int, tuple(int, int), optional
1231
+ :param _request_auth: set to override the auth_settings for an a single
1232
+ request; this effectively ignores the
1233
+ authentication in the spec for a single request.
1234
+ :type _request_auth: dict, optional
1235
+ :param _content_type: force content-type for the request.
1236
+ :type _content_type: str, Optional
1237
+ :param _headers: set to override the headers for a single
1238
+ request; this effectively ignores the headers
1239
+ in the spec for a single request.
1240
+ :type _headers: dict, optional
1241
+ :param _host_index: set to override the host_index for a single
1242
+ request; this effectively ignores the host_index
1243
+ in the spec for a single request.
1244
+ :type _host_index: int, optional
1245
+ :return: Returns the result object.
1246
+ """ # noqa: E501
1247
+
1248
+ _param = self._get_website_geo_location_configuration_serialize(
1249
+ website_id=website_id,
1250
+ _request_auth=_request_auth,
1251
+ _content_type=_content_type,
1252
+ _headers=_headers,
1253
+ _host_index=_host_index
1254
+ )
1255
+
1256
+ _response_types_map: Dict[str, Optional[str]] = {
1257
+ '200': "GeoLocationConfiguration",
1258
+ '401': None,
1259
+ '403': None,
1260
+ '404': None,
1261
+ '500': None,
1262
+ }
1263
+ response_data = self.api_client.call_api(
1264
+ *_param,
1265
+ _request_timeout=_request_timeout
1266
+ )
1267
+ response_data.read()
1268
+ return self.api_client.response_deserialize(
1269
+ response_data=response_data,
1270
+ response_types_map=_response_types_map,
1271
+ )
1272
+
1273
+
1274
+ @validate_call
1275
+ def get_website_geo_location_configuration_without_preload_content(
1276
+ self,
1277
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1278
+ _request_timeout: Union[
1279
+ None,
1280
+ Annotated[StrictFloat, Field(gt=0)],
1281
+ Tuple[
1282
+ Annotated[StrictFloat, Field(gt=0)],
1283
+ Annotated[StrictFloat, Field(gt=0)]
1284
+ ]
1285
+ ] = None,
1286
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1287
+ _content_type: Optional[StrictStr] = None,
1288
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1289
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1290
+ ) -> RESTResponseType:
1291
+ """Get geo location configuration for website
1292
+
1293
+ API request to get geo-location configuration of a website specified by its websiteId
1294
+
1295
+ :param website_id: websiteId (required)
1296
+ :type website_id: str
1297
+ :param _request_timeout: timeout setting for this request. If one
1298
+ number provided, it will be total request
1299
+ timeout. It can also be a pair (tuple) of
1300
+ (connection, read) timeouts.
1301
+ :type _request_timeout: int, tuple(int, int), optional
1302
+ :param _request_auth: set to override the auth_settings for an a single
1303
+ request; this effectively ignores the
1304
+ authentication in the spec for a single request.
1305
+ :type _request_auth: dict, optional
1306
+ :param _content_type: force content-type for the request.
1307
+ :type _content_type: str, Optional
1308
+ :param _headers: set to override the headers for a single
1309
+ request; this effectively ignores the headers
1310
+ in the spec for a single request.
1311
+ :type _headers: dict, optional
1312
+ :param _host_index: set to override the host_index for a single
1313
+ request; this effectively ignores the host_index
1314
+ in the spec for a single request.
1315
+ :type _host_index: int, optional
1316
+ :return: Returns the result object.
1317
+ """ # noqa: E501
1318
+
1319
+ _param = self._get_website_geo_location_configuration_serialize(
1320
+ website_id=website_id,
1321
+ _request_auth=_request_auth,
1322
+ _content_type=_content_type,
1323
+ _headers=_headers,
1324
+ _host_index=_host_index
1325
+ )
1326
+
1327
+ _response_types_map: Dict[str, Optional[str]] = {
1328
+ '200': "GeoLocationConfiguration",
1329
+ '401': None,
1330
+ '403': None,
1331
+ '404': None,
1332
+ '500': None,
1333
+ }
1334
+ response_data = self.api_client.call_api(
1335
+ *_param,
1336
+ _request_timeout=_request_timeout
1337
+ )
1338
+ return response_data.response
1339
+
1340
+
1341
+ def _get_website_geo_location_configuration_serialize(
1342
+ self,
1343
+ website_id,
1344
+ _request_auth,
1345
+ _content_type,
1346
+ _headers,
1347
+ _host_index,
1348
+ ) -> RequestSerialized:
1349
+
1350
+ _host = None
1351
+
1352
+ _collection_formats: Dict[str, str] = {
1353
+ }
1354
+
1355
+ _path_params: Dict[str, str] = {}
1356
+ _query_params: List[Tuple[str, str]] = []
1357
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1358
+ _form_params: List[Tuple[str, str]] = []
1359
+ _files: Dict[
1360
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1361
+ ] = {}
1362
+ _body_params: Optional[bytes] = None
1363
+
1364
+ # process the path parameters
1365
+ if website_id is not None:
1366
+ _path_params['websiteId'] = website_id
1367
+ # process the query parameters
1368
+ # process the header parameters
1369
+ # process the form parameters
1370
+ # process the body parameter
1371
+
1372
+
1373
+ # set the HTTP header `Accept`
1374
+ if 'Accept' not in _header_params:
1375
+ _header_params['Accept'] = self.api_client.select_header_accept(
1376
+ [
1377
+ 'application/json'
1378
+ ]
1379
+ )
1380
+
1381
+
1382
+ # authentication setting
1383
+ _auth_settings: List[str] = [
1384
+ 'ApiKeyAuth'
1385
+ ]
1386
+
1387
+ return self.api_client.param_serialize(
1388
+ method='GET',
1389
+ resource_path='/api/website-monitoring/config/{websiteId}/geo-location',
1390
+ path_params=_path_params,
1391
+ query_params=_query_params,
1392
+ header_params=_header_params,
1393
+ body=_body_params,
1394
+ post_params=_form_params,
1395
+ files=_files,
1396
+ auth_settings=_auth_settings,
1397
+ collection_formats=_collection_formats,
1398
+ _host=_host,
1399
+ _request_auth=_request_auth
1400
+ )
1401
+
1402
+
1403
+
1404
+
1405
+ @validate_call
1406
+ def get_website_geo_mapping_rules(
1407
+ self,
1408
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
1409
+ _request_timeout: Union[
1410
+ None,
1411
+ Annotated[StrictFloat, Field(gt=0)],
1412
+ Tuple[
1413
+ Annotated[StrictFloat, Field(gt=0)],
1414
+ Annotated[StrictFloat, Field(gt=0)]
1415
+ ]
1416
+ ] = None,
1417
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1418
+ _content_type: Optional[StrictStr] = None,
1419
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1420
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1421
+ ) -> None:
1422
+ """Get custom geo mapping rules for website
1423
+
1424
+ API request to get custom geo mapping rules for website.
1425
+
1426
+ :param website_id: Website ID (required)
1427
+ :type website_id: str
1428
+ :param _request_timeout: timeout setting for this request. If one
1429
+ number provided, it will be total request
1430
+ timeout. It can also be a pair (tuple) of
1431
+ (connection, read) timeouts.
1432
+ :type _request_timeout: int, tuple(int, int), optional
1433
+ :param _request_auth: set to override the auth_settings for an a single
1434
+ request; this effectively ignores the
1435
+ authentication in the spec for a single request.
1436
+ :type _request_auth: dict, optional
1437
+ :param _content_type: force content-type for the request.
1438
+ :type _content_type: str, Optional
1439
+ :param _headers: set to override the headers for a single
1440
+ request; this effectively ignores the headers
1441
+ in the spec for a single request.
1442
+ :type _headers: dict, optional
1443
+ :param _host_index: set to override the host_index for a single
1444
+ request; this effectively ignores the host_index
1445
+ in the spec for a single request.
1446
+ :type _host_index: int, optional
1447
+ :return: Returns the result object.
1448
+ """ # noqa: E501
1449
+
1450
+ _param = self._get_website_geo_mapping_rules_serialize(
1451
+ website_id=website_id,
1452
+ _request_auth=_request_auth,
1453
+ _content_type=_content_type,
1454
+ _headers=_headers,
1455
+ _host_index=_host_index
1456
+ )
1457
+
1458
+ _response_types_map: Dict[str, Optional[str]] = {
1459
+ '200': None,
1460
+ '401': None,
1461
+ '403': None,
1462
+ '404': None,
1463
+ '500': None,
1464
+ }
1465
+ response_data = self.api_client.call_api(
1466
+ *_param,
1467
+ _request_timeout=_request_timeout
1468
+ )
1469
+ response_data.read()
1470
+ return self.api_client.response_deserialize(
1471
+ response_data=response_data,
1472
+ response_types_map=_response_types_map,
1473
+ ).data
1474
+
1475
+
1476
+ @validate_call
1477
+ def get_website_geo_mapping_rules_with_http_info(
1478
+ self,
1479
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
1480
+ _request_timeout: Union[
1481
+ None,
1482
+ Annotated[StrictFloat, Field(gt=0)],
1483
+ Tuple[
1484
+ Annotated[StrictFloat, Field(gt=0)],
1485
+ Annotated[StrictFloat, Field(gt=0)]
1486
+ ]
1487
+ ] = None,
1488
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1489
+ _content_type: Optional[StrictStr] = None,
1490
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1491
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1492
+ ) -> ApiResponse[None]:
1493
+ """Get custom geo mapping rules for website
1494
+
1495
+ API request to get custom geo mapping rules for website.
1496
+
1497
+ :param website_id: Website ID (required)
1498
+ :type website_id: str
1499
+ :param _request_timeout: timeout setting for this request. If one
1500
+ number provided, it will be total request
1501
+ timeout. It can also be a pair (tuple) of
1502
+ (connection, read) timeouts.
1503
+ :type _request_timeout: int, tuple(int, int), optional
1504
+ :param _request_auth: set to override the auth_settings for an a single
1505
+ request; this effectively ignores the
1506
+ authentication in the spec for a single request.
1507
+ :type _request_auth: dict, optional
1508
+ :param _content_type: force content-type for the request.
1509
+ :type _content_type: str, Optional
1510
+ :param _headers: set to override the headers for a single
1511
+ request; this effectively ignores the headers
1512
+ in the spec for a single request.
1513
+ :type _headers: dict, optional
1514
+ :param _host_index: set to override the host_index for a single
1515
+ request; this effectively ignores the host_index
1516
+ in the spec for a single request.
1517
+ :type _host_index: int, optional
1518
+ :return: Returns the result object.
1519
+ """ # noqa: E501
1520
+
1521
+ _param = self._get_website_geo_mapping_rules_serialize(
1522
+ website_id=website_id,
1523
+ _request_auth=_request_auth,
1524
+ _content_type=_content_type,
1525
+ _headers=_headers,
1526
+ _host_index=_host_index
1527
+ )
1528
+
1529
+ _response_types_map: Dict[str, Optional[str]] = {
1530
+ '200': None,
1531
+ '401': None,
1532
+ '403': None,
1533
+ '404': None,
1534
+ '500': None,
1535
+ }
1536
+ response_data = self.api_client.call_api(
1537
+ *_param,
1538
+ _request_timeout=_request_timeout
1539
+ )
1540
+ response_data.read()
1541
+ return self.api_client.response_deserialize(
1542
+ response_data=response_data,
1543
+ response_types_map=_response_types_map,
1544
+ )
1545
+
1546
+
1547
+ @validate_call
1548
+ def get_website_geo_mapping_rules_without_preload_content(
1549
+ self,
1550
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
1551
+ _request_timeout: Union[
1552
+ None,
1553
+ Annotated[StrictFloat, Field(gt=0)],
1554
+ Tuple[
1555
+ Annotated[StrictFloat, Field(gt=0)],
1556
+ Annotated[StrictFloat, Field(gt=0)]
1557
+ ]
1558
+ ] = None,
1559
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1560
+ _content_type: Optional[StrictStr] = None,
1561
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1562
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1563
+ ) -> RESTResponseType:
1564
+ """Get custom geo mapping rules for website
1565
+
1566
+ API request to get custom geo mapping rules for website.
1567
+
1568
+ :param website_id: Website ID (required)
1569
+ :type website_id: str
1570
+ :param _request_timeout: timeout setting for this request. If one
1571
+ number provided, it will be total request
1572
+ timeout. It can also be a pair (tuple) of
1573
+ (connection, read) timeouts.
1574
+ :type _request_timeout: int, tuple(int, int), optional
1575
+ :param _request_auth: set to override the auth_settings for an a single
1576
+ request; this effectively ignores the
1577
+ authentication in the spec for a single request.
1578
+ :type _request_auth: dict, optional
1579
+ :param _content_type: force content-type for the request.
1580
+ :type _content_type: str, Optional
1581
+ :param _headers: set to override the headers for a single
1582
+ request; this effectively ignores the headers
1583
+ in the spec for a single request.
1584
+ :type _headers: dict, optional
1585
+ :param _host_index: set to override the host_index for a single
1586
+ request; this effectively ignores the host_index
1587
+ in the spec for a single request.
1588
+ :type _host_index: int, optional
1589
+ :return: Returns the result object.
1590
+ """ # noqa: E501
1591
+
1592
+ _param = self._get_website_geo_mapping_rules_serialize(
1593
+ website_id=website_id,
1594
+ _request_auth=_request_auth,
1595
+ _content_type=_content_type,
1596
+ _headers=_headers,
1597
+ _host_index=_host_index
1598
+ )
1599
+
1600
+ _response_types_map: Dict[str, Optional[str]] = {
1601
+ '200': None,
1602
+ '401': None,
1603
+ '403': None,
1604
+ '404': None,
1605
+ '500': None,
1606
+ }
1607
+ response_data = self.api_client.call_api(
1608
+ *_param,
1609
+ _request_timeout=_request_timeout
1610
+ )
1611
+ return response_data.response
1612
+
1613
+
1614
+ def _get_website_geo_mapping_rules_serialize(
1615
+ self,
1616
+ website_id,
1617
+ _request_auth,
1618
+ _content_type,
1619
+ _headers,
1620
+ _host_index,
1621
+ ) -> RequestSerialized:
1622
+
1623
+ _host = None
1624
+
1625
+ _collection_formats: Dict[str, str] = {
1626
+ }
1627
+
1628
+ _path_params: Dict[str, str] = {}
1629
+ _query_params: List[Tuple[str, str]] = []
1630
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1631
+ _form_params: List[Tuple[str, str]] = []
1632
+ _files: Dict[
1633
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1634
+ ] = {}
1635
+ _body_params: Optional[bytes] = None
1636
+
1637
+ # process the path parameters
1638
+ if website_id is not None:
1639
+ _path_params['websiteId'] = website_id
1640
+ # process the query parameters
1641
+ # process the header parameters
1642
+ # process the form parameters
1643
+ # process the body parameter
1644
+
1645
+
1646
+ # set the HTTP header `Accept`
1647
+ if 'Accept' not in _header_params:
1648
+ _header_params['Accept'] = self.api_client.select_header_accept(
1649
+ [
1650
+ 'text/csv'
1651
+ ]
1652
+ )
1653
+
1654
+
1655
+ # authentication setting
1656
+ _auth_settings: List[str] = [
1657
+ 'ApiKeyAuth'
1658
+ ]
1659
+
1660
+ return self.api_client.param_serialize(
1661
+ method='GET',
1662
+ resource_path='/api/website-monitoring/config/{websiteId}/geo-mapping-rules',
1663
+ path_params=_path_params,
1664
+ query_params=_query_params,
1665
+ header_params=_header_params,
1666
+ body=_body_params,
1667
+ post_params=_form_params,
1668
+ files=_files,
1669
+ auth_settings=_auth_settings,
1670
+ collection_formats=_collection_formats,
1671
+ _host=_host,
1672
+ _request_auth=_request_auth
1673
+ )
1674
+
1675
+
1676
+
1677
+
1678
+ @validate_call
1679
+ def get_website_ip_masking_configuration(
1680
+ self,
1681
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1682
+ _request_timeout: Union[
1683
+ None,
1684
+ Annotated[StrictFloat, Field(gt=0)],
1685
+ Tuple[
1686
+ Annotated[StrictFloat, Field(gt=0)],
1687
+ Annotated[StrictFloat, Field(gt=0)]
1688
+ ]
1689
+ ] = None,
1690
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1691
+ _content_type: Optional[StrictStr] = None,
1692
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1693
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1694
+ ) -> IpMaskingConfiguration:
1695
+ """Get IP masking configuration for website
1696
+
1697
+ API request to get IP masking configuration of a website specified by its websiteId
1698
+
1699
+ :param website_id: websiteId (required)
1700
+ :type website_id: str
1701
+ :param _request_timeout: timeout setting for this request. If one
1702
+ number provided, it will be total request
1703
+ timeout. It can also be a pair (tuple) of
1704
+ (connection, read) timeouts.
1705
+ :type _request_timeout: int, tuple(int, int), optional
1706
+ :param _request_auth: set to override the auth_settings for an a single
1707
+ request; this effectively ignores the
1708
+ authentication in the spec for a single request.
1709
+ :type _request_auth: dict, optional
1710
+ :param _content_type: force content-type for the request.
1711
+ :type _content_type: str, Optional
1712
+ :param _headers: set to override the headers for a single
1713
+ request; this effectively ignores the headers
1714
+ in the spec for a single request.
1715
+ :type _headers: dict, optional
1716
+ :param _host_index: set to override the host_index for a single
1717
+ request; this effectively ignores the host_index
1718
+ in the spec for a single request.
1719
+ :type _host_index: int, optional
1720
+ :return: Returns the result object.
1721
+ """ # noqa: E501
1722
+
1723
+ _param = self._get_website_ip_masking_configuration_serialize(
1724
+ website_id=website_id,
1725
+ _request_auth=_request_auth,
1726
+ _content_type=_content_type,
1727
+ _headers=_headers,
1728
+ _host_index=_host_index
1729
+ )
1730
+
1731
+ _response_types_map: Dict[str, Optional[str]] = {
1732
+ '200': "IpMaskingConfiguration",
1733
+ '401': None,
1734
+ '403': None,
1735
+ '404': None,
1736
+ '500': None,
1737
+ }
1738
+ response_data = self.api_client.call_api(
1739
+ *_param,
1740
+ _request_timeout=_request_timeout
1741
+ )
1742
+ response_data.read()
1743
+ return self.api_client.response_deserialize(
1744
+ response_data=response_data,
1745
+ response_types_map=_response_types_map,
1746
+ ).data
1747
+
1748
+
1749
+ @validate_call
1750
+ def get_website_ip_masking_configuration_with_http_info(
1751
+ self,
1752
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1753
+ _request_timeout: Union[
1754
+ None,
1755
+ Annotated[StrictFloat, Field(gt=0)],
1756
+ Tuple[
1757
+ Annotated[StrictFloat, Field(gt=0)],
1758
+ Annotated[StrictFloat, Field(gt=0)]
1759
+ ]
1760
+ ] = None,
1761
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1762
+ _content_type: Optional[StrictStr] = None,
1763
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1764
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1765
+ ) -> ApiResponse[IpMaskingConfiguration]:
1766
+ """Get IP masking configuration for website
1767
+
1768
+ API request to get IP masking configuration of a website specified by its websiteId
1769
+
1770
+ :param website_id: websiteId (required)
1771
+ :type website_id: str
1772
+ :param _request_timeout: timeout setting for this request. If one
1773
+ number provided, it will be total request
1774
+ timeout. It can also be a pair (tuple) of
1775
+ (connection, read) timeouts.
1776
+ :type _request_timeout: int, tuple(int, int), optional
1777
+ :param _request_auth: set to override the auth_settings for an a single
1778
+ request; this effectively ignores the
1779
+ authentication in the spec for a single request.
1780
+ :type _request_auth: dict, optional
1781
+ :param _content_type: force content-type for the request.
1782
+ :type _content_type: str, Optional
1783
+ :param _headers: set to override the headers for a single
1784
+ request; this effectively ignores the headers
1785
+ in the spec for a single request.
1786
+ :type _headers: dict, optional
1787
+ :param _host_index: set to override the host_index for a single
1788
+ request; this effectively ignores the host_index
1789
+ in the spec for a single request.
1790
+ :type _host_index: int, optional
1791
+ :return: Returns the result object.
1792
+ """ # noqa: E501
1793
+
1794
+ _param = self._get_website_ip_masking_configuration_serialize(
1795
+ website_id=website_id,
1796
+ _request_auth=_request_auth,
1797
+ _content_type=_content_type,
1798
+ _headers=_headers,
1799
+ _host_index=_host_index
1800
+ )
1801
+
1802
+ _response_types_map: Dict[str, Optional[str]] = {
1803
+ '200': "IpMaskingConfiguration",
1804
+ '401': None,
1805
+ '403': None,
1806
+ '404': None,
1807
+ '500': None,
1808
+ }
1809
+ response_data = self.api_client.call_api(
1810
+ *_param,
1811
+ _request_timeout=_request_timeout
1812
+ )
1813
+ response_data.read()
1814
+ return self.api_client.response_deserialize(
1815
+ response_data=response_data,
1816
+ response_types_map=_response_types_map,
1817
+ )
1818
+
1819
+
1820
+ @validate_call
1821
+ def get_website_ip_masking_configuration_without_preload_content(
1822
+ self,
1823
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
1824
+ _request_timeout: Union[
1825
+ None,
1826
+ Annotated[StrictFloat, Field(gt=0)],
1827
+ Tuple[
1828
+ Annotated[StrictFloat, Field(gt=0)],
1829
+ Annotated[StrictFloat, Field(gt=0)]
1830
+ ]
1831
+ ] = None,
1832
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1833
+ _content_type: Optional[StrictStr] = None,
1834
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1835
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1836
+ ) -> RESTResponseType:
1837
+ """Get IP masking configuration for website
1838
+
1839
+ API request to get IP masking configuration of a website specified by its websiteId
1840
+
1841
+ :param website_id: websiteId (required)
1842
+ :type website_id: str
1843
+ :param _request_timeout: timeout setting for this request. If one
1844
+ number provided, it will be total request
1845
+ timeout. It can also be a pair (tuple) of
1846
+ (connection, read) timeouts.
1847
+ :type _request_timeout: int, tuple(int, int), optional
1848
+ :param _request_auth: set to override the auth_settings for an a single
1849
+ request; this effectively ignores the
1850
+ authentication in the spec for a single request.
1851
+ :type _request_auth: dict, optional
1852
+ :param _content_type: force content-type for the request.
1853
+ :type _content_type: str, Optional
1854
+ :param _headers: set to override the headers for a single
1855
+ request; this effectively ignores the headers
1856
+ in the spec for a single request.
1857
+ :type _headers: dict, optional
1858
+ :param _host_index: set to override the host_index for a single
1859
+ request; this effectively ignores the host_index
1860
+ in the spec for a single request.
1861
+ :type _host_index: int, optional
1862
+ :return: Returns the result object.
1863
+ """ # noqa: E501
1864
+
1865
+ _param = self._get_website_ip_masking_configuration_serialize(
1866
+ website_id=website_id,
1867
+ _request_auth=_request_auth,
1868
+ _content_type=_content_type,
1869
+ _headers=_headers,
1870
+ _host_index=_host_index
1871
+ )
1872
+
1873
+ _response_types_map: Dict[str, Optional[str]] = {
1874
+ '200': "IpMaskingConfiguration",
1875
+ '401': None,
1876
+ '403': None,
1877
+ '404': None,
1878
+ '500': None,
1879
+ }
1880
+ response_data = self.api_client.call_api(
1881
+ *_param,
1882
+ _request_timeout=_request_timeout
1883
+ )
1884
+ return response_data.response
1885
+
1886
+
1887
+ def _get_website_ip_masking_configuration_serialize(
1888
+ self,
1889
+ website_id,
1890
+ _request_auth,
1891
+ _content_type,
1892
+ _headers,
1893
+ _host_index,
1894
+ ) -> RequestSerialized:
1895
+
1896
+ _host = None
1897
+
1898
+ _collection_formats: Dict[str, str] = {
1899
+ }
1900
+
1901
+ _path_params: Dict[str, str] = {}
1902
+ _query_params: List[Tuple[str, str]] = []
1903
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1904
+ _form_params: List[Tuple[str, str]] = []
1905
+ _files: Dict[
1906
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1907
+ ] = {}
1908
+ _body_params: Optional[bytes] = None
1909
+
1910
+ # process the path parameters
1911
+ if website_id is not None:
1912
+ _path_params['websiteId'] = website_id
1913
+ # process the query parameters
1914
+ # process the header parameters
1915
+ # process the form parameters
1916
+ # process the body parameter
1917
+
1918
+
1919
+ # set the HTTP header `Accept`
1920
+ if 'Accept' not in _header_params:
1921
+ _header_params['Accept'] = self.api_client.select_header_accept(
1922
+ [
1923
+ 'application/json'
1924
+ ]
1925
+ )
1926
+
1927
+
1928
+ # authentication setting
1929
+ _auth_settings: List[str] = [
1930
+ 'ApiKeyAuth'
1931
+ ]
1932
+
1933
+ return self.api_client.param_serialize(
1934
+ method='GET',
1935
+ resource_path='/api/website-monitoring/config/{websiteId}/ip-masking',
1936
+ path_params=_path_params,
1937
+ query_params=_query_params,
1938
+ header_params=_header_params,
1939
+ body=_body_params,
1940
+ post_params=_form_params,
1941
+ files=_files,
1942
+ auth_settings=_auth_settings,
1943
+ collection_formats=_collection_formats,
1944
+ _host=_host,
1945
+ _request_auth=_request_auth
1946
+ )
1947
+
1948
+
1949
+
1950
+
1951
+ @validate_call
1952
+ def get_websites(
1953
+ self,
1954
+ _request_timeout: Union[
1955
+ None,
1956
+ Annotated[StrictFloat, Field(gt=0)],
1957
+ Tuple[
1958
+ Annotated[StrictFloat, Field(gt=0)],
1959
+ Annotated[StrictFloat, Field(gt=0)]
1960
+ ]
1961
+ ] = None,
1962
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1963
+ _content_type: Optional[StrictStr] = None,
1964
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1965
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1966
+ ) -> List[Website]:
1967
+ """Get configured websites
1968
+
1969
+ API request to get all configured websites details.
1970
+
1971
+ :param _request_timeout: timeout setting for this request. If one
1972
+ number provided, it will be total request
1973
+ timeout. It can also be a pair (tuple) of
1974
+ (connection, read) timeouts.
1975
+ :type _request_timeout: int, tuple(int, int), optional
1976
+ :param _request_auth: set to override the auth_settings for an a single
1977
+ request; this effectively ignores the
1978
+ authentication in the spec for a single request.
1979
+ :type _request_auth: dict, optional
1980
+ :param _content_type: force content-type for the request.
1981
+ :type _content_type: str, Optional
1982
+ :param _headers: set to override the headers for a single
1983
+ request; this effectively ignores the headers
1984
+ in the spec for a single request.
1985
+ :type _headers: dict, optional
1986
+ :param _host_index: set to override the host_index for a single
1987
+ request; this effectively ignores the host_index
1988
+ in the spec for a single request.
1989
+ :type _host_index: int, optional
1990
+ :return: Returns the result object.
1991
+ """ # noqa: E501
1992
+
1993
+ _param = self._get_websites_serialize(
1994
+ _request_auth=_request_auth,
1995
+ _content_type=_content_type,
1996
+ _headers=_headers,
1997
+ _host_index=_host_index
1998
+ )
1999
+
2000
+ _response_types_map: Dict[str, Optional[str]] = {
2001
+ '200': "List[Website]",
2002
+ '400': None,
2003
+ '401': None,
2004
+ '500': None,
2005
+ }
2006
+ response_data = self.api_client.call_api(
2007
+ *_param,
2008
+ _request_timeout=_request_timeout
2009
+ )
2010
+ response_data.read()
2011
+ return self.api_client.response_deserialize(
2012
+ response_data=response_data,
2013
+ response_types_map=_response_types_map,
2014
+ ).data
2015
+
2016
+
2017
+ @validate_call
2018
+ def get_websites_with_http_info(
2019
+ self,
2020
+ _request_timeout: Union[
2021
+ None,
2022
+ Annotated[StrictFloat, Field(gt=0)],
2023
+ Tuple[
2024
+ Annotated[StrictFloat, Field(gt=0)],
2025
+ Annotated[StrictFloat, Field(gt=0)]
2026
+ ]
2027
+ ] = None,
2028
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2029
+ _content_type: Optional[StrictStr] = None,
2030
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2031
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2032
+ ) -> ApiResponse[List[Website]]:
2033
+ """Get configured websites
2034
+
2035
+ API request to get all configured websites details.
2036
+
2037
+ :param _request_timeout: timeout setting for this request. If one
2038
+ number provided, it will be total request
2039
+ timeout. It can also be a pair (tuple) of
2040
+ (connection, read) timeouts.
2041
+ :type _request_timeout: int, tuple(int, int), optional
2042
+ :param _request_auth: set to override the auth_settings for an a single
2043
+ request; this effectively ignores the
2044
+ authentication in the spec for a single request.
2045
+ :type _request_auth: dict, optional
2046
+ :param _content_type: force content-type for the request.
2047
+ :type _content_type: str, Optional
2048
+ :param _headers: set to override the headers for a single
2049
+ request; this effectively ignores the headers
2050
+ in the spec for a single request.
2051
+ :type _headers: dict, optional
2052
+ :param _host_index: set to override the host_index for a single
2053
+ request; this effectively ignores the host_index
2054
+ in the spec for a single request.
2055
+ :type _host_index: int, optional
2056
+ :return: Returns the result object.
2057
+ """ # noqa: E501
2058
+
2059
+ _param = self._get_websites_serialize(
2060
+ _request_auth=_request_auth,
2061
+ _content_type=_content_type,
2062
+ _headers=_headers,
2063
+ _host_index=_host_index
2064
+ )
2065
+
2066
+ _response_types_map: Dict[str, Optional[str]] = {
2067
+ '200': "List[Website]",
2068
+ '400': None,
2069
+ '401': None,
2070
+ '500': None,
2071
+ }
2072
+ response_data = self.api_client.call_api(
2073
+ *_param,
2074
+ _request_timeout=_request_timeout
2075
+ )
2076
+ response_data.read()
2077
+ return self.api_client.response_deserialize(
2078
+ response_data=response_data,
2079
+ response_types_map=_response_types_map,
2080
+ )
2081
+
2082
+
2083
+ @validate_call
2084
+ def get_websites_without_preload_content(
2085
+ self,
2086
+ _request_timeout: Union[
2087
+ None,
2088
+ Annotated[StrictFloat, Field(gt=0)],
2089
+ Tuple[
2090
+ Annotated[StrictFloat, Field(gt=0)],
2091
+ Annotated[StrictFloat, Field(gt=0)]
2092
+ ]
2093
+ ] = None,
2094
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2095
+ _content_type: Optional[StrictStr] = None,
2096
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2097
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2098
+ ) -> RESTResponseType:
2099
+ """Get configured websites
2100
+
2101
+ API request to get all configured websites details.
2102
+
2103
+ :param _request_timeout: timeout setting for this request. If one
2104
+ number provided, it will be total request
2105
+ timeout. It can also be a pair (tuple) of
2106
+ (connection, read) timeouts.
2107
+ :type _request_timeout: int, tuple(int, int), optional
2108
+ :param _request_auth: set to override the auth_settings for an a single
2109
+ request; this effectively ignores the
2110
+ authentication in the spec for a single request.
2111
+ :type _request_auth: dict, optional
2112
+ :param _content_type: force content-type for the request.
2113
+ :type _content_type: str, Optional
2114
+ :param _headers: set to override the headers for a single
2115
+ request; this effectively ignores the headers
2116
+ in the spec for a single request.
2117
+ :type _headers: dict, optional
2118
+ :param _host_index: set to override the host_index for a single
2119
+ request; this effectively ignores the host_index
2120
+ in the spec for a single request.
2121
+ :type _host_index: int, optional
2122
+ :return: Returns the result object.
2123
+ """ # noqa: E501
2124
+
2125
+ _param = self._get_websites_serialize(
2126
+ _request_auth=_request_auth,
2127
+ _content_type=_content_type,
2128
+ _headers=_headers,
2129
+ _host_index=_host_index
2130
+ )
2131
+
2132
+ _response_types_map: Dict[str, Optional[str]] = {
2133
+ '200': "List[Website]",
2134
+ '400': None,
2135
+ '401': None,
2136
+ '500': None,
2137
+ }
2138
+ response_data = self.api_client.call_api(
2139
+ *_param,
2140
+ _request_timeout=_request_timeout
2141
+ )
2142
+ return response_data.response
2143
+
2144
+
2145
+ def _get_websites_serialize(
2146
+ self,
2147
+ _request_auth,
2148
+ _content_type,
2149
+ _headers,
2150
+ _host_index,
2151
+ ) -> RequestSerialized:
2152
+
2153
+ _host = None
2154
+
2155
+ _collection_formats: Dict[str, str] = {
2156
+ }
2157
+
2158
+ _path_params: Dict[str, str] = {}
2159
+ _query_params: List[Tuple[str, str]] = []
2160
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2161
+ _form_params: List[Tuple[str, str]] = []
2162
+ _files: Dict[
2163
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2164
+ ] = {}
2165
+ _body_params: Optional[bytes] = None
2166
+
2167
+ # process the path parameters
2168
+ # process the query parameters
2169
+ # process the header parameters
2170
+ # process the form parameters
2171
+ # process the body parameter
2172
+
2173
+
2174
+ # set the HTTP header `Accept`
2175
+ if 'Accept' not in _header_params:
2176
+ _header_params['Accept'] = self.api_client.select_header_accept(
2177
+ [
2178
+ 'application/json'
2179
+ ]
2180
+ )
2181
+
2182
+
2183
+ # authentication setting
2184
+ _auth_settings: List[str] = [
2185
+ 'ApiKeyAuth'
2186
+ ]
2187
+
2188
+ return self.api_client.param_serialize(
2189
+ method='GET',
2190
+ resource_path='/api/website-monitoring/config',
2191
+ path_params=_path_params,
2192
+ query_params=_query_params,
2193
+ header_params=_header_params,
2194
+ body=_body_params,
2195
+ post_params=_form_params,
2196
+ files=_files,
2197
+ auth_settings=_auth_settings,
2198
+ collection_formats=_collection_formats,
2199
+ _host=_host,
2200
+ _request_auth=_request_auth
2201
+ )
2202
+
2203
+
2204
+
2205
+
2206
+ @validate_call
2207
+ def rename_website(
2208
+ self,
2209
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
2210
+ name: Optional[StrictStr] = None,
2211
+ _request_timeout: Union[
2212
+ None,
2213
+ Annotated[StrictFloat, Field(gt=0)],
2214
+ Tuple[
2215
+ Annotated[StrictFloat, Field(gt=0)],
2216
+ Annotated[StrictFloat, Field(gt=0)]
2217
+ ]
2218
+ ] = None,
2219
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2220
+ _content_type: Optional[StrictStr] = None,
2221
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2222
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2223
+ ) -> Website:
2224
+ """Rename website
2225
+
2226
+ API request to rename website.
2227
+
2228
+ :param website_id: websiteId (required)
2229
+ :type website_id: str
2230
+ :param name:
2231
+ :type name: str
2232
+ :param _request_timeout: timeout setting for this request. If one
2233
+ number provided, it will be total request
2234
+ timeout. It can also be a pair (tuple) of
2235
+ (connection, read) timeouts.
2236
+ :type _request_timeout: int, tuple(int, int), optional
2237
+ :param _request_auth: set to override the auth_settings for an a single
2238
+ request; this effectively ignores the
2239
+ authentication in the spec for a single request.
2240
+ :type _request_auth: dict, optional
2241
+ :param _content_type: force content-type for the request.
2242
+ :type _content_type: str, Optional
2243
+ :param _headers: set to override the headers for a single
2244
+ request; this effectively ignores the headers
2245
+ in the spec for a single request.
2246
+ :type _headers: dict, optional
2247
+ :param _host_index: set to override the host_index for a single
2248
+ request; this effectively ignores the host_index
2249
+ in the spec for a single request.
2250
+ :type _host_index: int, optional
2251
+ :return: Returns the result object.
2252
+ """ # noqa: E501
2253
+
2254
+ _param = self._rename_website_serialize(
2255
+ website_id=website_id,
2256
+ name=name,
2257
+ _request_auth=_request_auth,
2258
+ _content_type=_content_type,
2259
+ _headers=_headers,
2260
+ _host_index=_host_index
2261
+ )
2262
+
2263
+ _response_types_map: Dict[str, Optional[str]] = {
2264
+ '200': "Website",
2265
+ '400': None,
2266
+ '401': None,
2267
+ '403': None,
2268
+ '500': None,
2269
+ }
2270
+ response_data = self.api_client.call_api(
2271
+ *_param,
2272
+ _request_timeout=_request_timeout
2273
+ )
2274
+ response_data.read()
2275
+ return self.api_client.response_deserialize(
2276
+ response_data=response_data,
2277
+ response_types_map=_response_types_map,
2278
+ ).data
2279
+
2280
+
2281
+ @validate_call
2282
+ def rename_website_with_http_info(
2283
+ self,
2284
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
2285
+ name: Optional[StrictStr] = None,
2286
+ _request_timeout: Union[
2287
+ None,
2288
+ Annotated[StrictFloat, Field(gt=0)],
2289
+ Tuple[
2290
+ Annotated[StrictFloat, Field(gt=0)],
2291
+ Annotated[StrictFloat, Field(gt=0)]
2292
+ ]
2293
+ ] = None,
2294
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2295
+ _content_type: Optional[StrictStr] = None,
2296
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2297
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2298
+ ) -> ApiResponse[Website]:
2299
+ """Rename website
2300
+
2301
+ API request to rename website.
2302
+
2303
+ :param website_id: websiteId (required)
2304
+ :type website_id: str
2305
+ :param name:
2306
+ :type name: str
2307
+ :param _request_timeout: timeout setting for this request. If one
2308
+ number provided, it will be total request
2309
+ timeout. It can also be a pair (tuple) of
2310
+ (connection, read) timeouts.
2311
+ :type _request_timeout: int, tuple(int, int), optional
2312
+ :param _request_auth: set to override the auth_settings for an a single
2313
+ request; this effectively ignores the
2314
+ authentication in the spec for a single request.
2315
+ :type _request_auth: dict, optional
2316
+ :param _content_type: force content-type for the request.
2317
+ :type _content_type: str, Optional
2318
+ :param _headers: set to override the headers for a single
2319
+ request; this effectively ignores the headers
2320
+ in the spec for a single request.
2321
+ :type _headers: dict, optional
2322
+ :param _host_index: set to override the host_index for a single
2323
+ request; this effectively ignores the host_index
2324
+ in the spec for a single request.
2325
+ :type _host_index: int, optional
2326
+ :return: Returns the result object.
2327
+ """ # noqa: E501
2328
+
2329
+ _param = self._rename_website_serialize(
2330
+ website_id=website_id,
2331
+ name=name,
2332
+ _request_auth=_request_auth,
2333
+ _content_type=_content_type,
2334
+ _headers=_headers,
2335
+ _host_index=_host_index
2336
+ )
2337
+
2338
+ _response_types_map: Dict[str, Optional[str]] = {
2339
+ '200': "Website",
2340
+ '400': None,
2341
+ '401': None,
2342
+ '403': None,
2343
+ '500': None,
2344
+ }
2345
+ response_data = self.api_client.call_api(
2346
+ *_param,
2347
+ _request_timeout=_request_timeout
2348
+ )
2349
+ response_data.read()
2350
+ return self.api_client.response_deserialize(
2351
+ response_data=response_data,
2352
+ response_types_map=_response_types_map,
2353
+ )
2354
+
2355
+
2356
+ @validate_call
2357
+ def rename_website_without_preload_content(
2358
+ self,
2359
+ website_id: Annotated[StrictStr, Field(description="websiteId")],
2360
+ name: Optional[StrictStr] = None,
2361
+ _request_timeout: Union[
2362
+ None,
2363
+ Annotated[StrictFloat, Field(gt=0)],
2364
+ Tuple[
2365
+ Annotated[StrictFloat, Field(gt=0)],
2366
+ Annotated[StrictFloat, Field(gt=0)]
2367
+ ]
2368
+ ] = None,
2369
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2370
+ _content_type: Optional[StrictStr] = None,
2371
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2372
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2373
+ ) -> RESTResponseType:
2374
+ """Rename website
2375
+
2376
+ API request to rename website.
2377
+
2378
+ :param website_id: websiteId (required)
2379
+ :type website_id: str
2380
+ :param name:
2381
+ :type name: str
2382
+ :param _request_timeout: timeout setting for this request. If one
2383
+ number provided, it will be total request
2384
+ timeout. It can also be a pair (tuple) of
2385
+ (connection, read) timeouts.
2386
+ :type _request_timeout: int, tuple(int, int), optional
2387
+ :param _request_auth: set to override the auth_settings for an a single
2388
+ request; this effectively ignores the
2389
+ authentication in the spec for a single request.
2390
+ :type _request_auth: dict, optional
2391
+ :param _content_type: force content-type for the request.
2392
+ :type _content_type: str, Optional
2393
+ :param _headers: set to override the headers for a single
2394
+ request; this effectively ignores the headers
2395
+ in the spec for a single request.
2396
+ :type _headers: dict, optional
2397
+ :param _host_index: set to override the host_index for a single
2398
+ request; this effectively ignores the host_index
2399
+ in the spec for a single request.
2400
+ :type _host_index: int, optional
2401
+ :return: Returns the result object.
2402
+ """ # noqa: E501
2403
+
2404
+ _param = self._rename_website_serialize(
2405
+ website_id=website_id,
2406
+ name=name,
2407
+ _request_auth=_request_auth,
2408
+ _content_type=_content_type,
2409
+ _headers=_headers,
2410
+ _host_index=_host_index
2411
+ )
2412
+
2413
+ _response_types_map: Dict[str, Optional[str]] = {
2414
+ '200': "Website",
2415
+ '400': None,
2416
+ '401': None,
2417
+ '403': None,
2418
+ '500': None,
2419
+ }
2420
+ response_data = self.api_client.call_api(
2421
+ *_param,
2422
+ _request_timeout=_request_timeout
2423
+ )
2424
+ return response_data.response
2425
+
2426
+
2427
+ def _rename_website_serialize(
2428
+ self,
2429
+ website_id,
2430
+ name,
2431
+ _request_auth,
2432
+ _content_type,
2433
+ _headers,
2434
+ _host_index,
2435
+ ) -> RequestSerialized:
2436
+
2437
+ _host = None
2438
+
2439
+ _collection_formats: Dict[str, str] = {
2440
+ }
2441
+
2442
+ _path_params: Dict[str, str] = {}
2443
+ _query_params: List[Tuple[str, str]] = []
2444
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2445
+ _form_params: List[Tuple[str, str]] = []
2446
+ _files: Dict[
2447
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2448
+ ] = {}
2449
+ _body_params: Optional[bytes] = None
2450
+
2451
+ # process the path parameters
2452
+ if website_id is not None:
2453
+ _path_params['websiteId'] = website_id
2454
+ # process the query parameters
2455
+ if name is not None:
2456
+
2457
+ _query_params.append(('name', name))
2458
+
2459
+ # process the header parameters
2460
+ # process the form parameters
2461
+ # process the body parameter
2462
+
2463
+
2464
+ # set the HTTP header `Accept`
2465
+ if 'Accept' not in _header_params:
2466
+ _header_params['Accept'] = self.api_client.select_header_accept(
2467
+ [
2468
+ 'application/json'
2469
+ ]
2470
+ )
2471
+
2472
+
2473
+ # authentication setting
2474
+ _auth_settings: List[str] = [
2475
+ 'ApiKeyAuth'
2476
+ ]
2477
+
2478
+ return self.api_client.param_serialize(
2479
+ method='PUT',
2480
+ resource_path='/api/website-monitoring/config/{websiteId}',
2481
+ path_params=_path_params,
2482
+ query_params=_query_params,
2483
+ header_params=_header_params,
2484
+ body=_body_params,
2485
+ post_params=_form_params,
2486
+ files=_files,
2487
+ auth_settings=_auth_settings,
2488
+ collection_formats=_collection_formats,
2489
+ _host=_host,
2490
+ _request_auth=_request_auth
2491
+ )
2492
+
2493
+
2494
+
2495
+
2496
+ @validate_call
2497
+ def set_website_geo_mapping_rules(
2498
+ self,
2499
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2500
+ body: Optional[StrictStr] = None,
2501
+ _request_timeout: Union[
2502
+ None,
2503
+ Annotated[StrictFloat, Field(gt=0)],
2504
+ Tuple[
2505
+ Annotated[StrictFloat, Field(gt=0)],
2506
+ Annotated[StrictFloat, Field(gt=0)]
2507
+ ]
2508
+ ] = None,
2509
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2510
+ _content_type: Optional[StrictStr] = None,
2511
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2512
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2513
+ ) -> None:
2514
+ """Set custom geo mapping rules for website
2515
+
2516
+ API request to set custom geo mapping rules for website.
2517
+
2518
+ :param website_id: Website ID (required)
2519
+ :type website_id: str
2520
+ :param body:
2521
+ :type body: str
2522
+ :param _request_timeout: timeout setting for this request. If one
2523
+ number provided, it will be total request
2524
+ timeout. It can also be a pair (tuple) of
2525
+ (connection, read) timeouts.
2526
+ :type _request_timeout: int, tuple(int, int), optional
2527
+ :param _request_auth: set to override the auth_settings for an a single
2528
+ request; this effectively ignores the
2529
+ authentication in the spec for a single request.
2530
+ :type _request_auth: dict, optional
2531
+ :param _content_type: force content-type for the request.
2532
+ :type _content_type: str, Optional
2533
+ :param _headers: set to override the headers for a single
2534
+ request; this effectively ignores the headers
2535
+ in the spec for a single request.
2536
+ :type _headers: dict, optional
2537
+ :param _host_index: set to override the host_index for a single
2538
+ request; this effectively ignores the host_index
2539
+ in the spec for a single request.
2540
+ :type _host_index: int, optional
2541
+ :return: Returns the result object.
2542
+ """ # noqa: E501
2543
+
2544
+ _param = self._set_website_geo_mapping_rules_serialize(
2545
+ website_id=website_id,
2546
+ body=body,
2547
+ _request_auth=_request_auth,
2548
+ _content_type=_content_type,
2549
+ _headers=_headers,
2550
+ _host_index=_host_index
2551
+ )
2552
+
2553
+ _response_types_map: Dict[str, Optional[str]] = {
2554
+ '200': None,
2555
+ '401': None,
2556
+ '403': None,
2557
+ '404': None,
2558
+ '415': None,
2559
+ '500': None,
2560
+ }
2561
+ response_data = self.api_client.call_api(
2562
+ *_param,
2563
+ _request_timeout=_request_timeout
2564
+ )
2565
+ response_data.read()
2566
+ return self.api_client.response_deserialize(
2567
+ response_data=response_data,
2568
+ response_types_map=_response_types_map,
2569
+ ).data
2570
+
2571
+
2572
+ @validate_call
2573
+ def set_website_geo_mapping_rules_with_http_info(
2574
+ self,
2575
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2576
+ body: Optional[StrictStr] = None,
2577
+ _request_timeout: Union[
2578
+ None,
2579
+ Annotated[StrictFloat, Field(gt=0)],
2580
+ Tuple[
2581
+ Annotated[StrictFloat, Field(gt=0)],
2582
+ Annotated[StrictFloat, Field(gt=0)]
2583
+ ]
2584
+ ] = None,
2585
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2586
+ _content_type: Optional[StrictStr] = None,
2587
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2588
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2589
+ ) -> ApiResponse[None]:
2590
+ """Set custom geo mapping rules for website
2591
+
2592
+ API request to set custom geo mapping rules for website.
2593
+
2594
+ :param website_id: Website ID (required)
2595
+ :type website_id: str
2596
+ :param body:
2597
+ :type body: str
2598
+ :param _request_timeout: timeout setting for this request. If one
2599
+ number provided, it will be total request
2600
+ timeout. It can also be a pair (tuple) of
2601
+ (connection, read) timeouts.
2602
+ :type _request_timeout: int, tuple(int, int), optional
2603
+ :param _request_auth: set to override the auth_settings for an a single
2604
+ request; this effectively ignores the
2605
+ authentication in the spec for a single request.
2606
+ :type _request_auth: dict, optional
2607
+ :param _content_type: force content-type for the request.
2608
+ :type _content_type: str, Optional
2609
+ :param _headers: set to override the headers for a single
2610
+ request; this effectively ignores the headers
2611
+ in the spec for a single request.
2612
+ :type _headers: dict, optional
2613
+ :param _host_index: set to override the host_index for a single
2614
+ request; this effectively ignores the host_index
2615
+ in the spec for a single request.
2616
+ :type _host_index: int, optional
2617
+ :return: Returns the result object.
2618
+ """ # noqa: E501
2619
+
2620
+ _param = self._set_website_geo_mapping_rules_serialize(
2621
+ website_id=website_id,
2622
+ body=body,
2623
+ _request_auth=_request_auth,
2624
+ _content_type=_content_type,
2625
+ _headers=_headers,
2626
+ _host_index=_host_index
2627
+ )
2628
+
2629
+ _response_types_map: Dict[str, Optional[str]] = {
2630
+ '200': None,
2631
+ '401': None,
2632
+ '403': None,
2633
+ '404': None,
2634
+ '415': None,
2635
+ '500': None,
2636
+ }
2637
+ response_data = self.api_client.call_api(
2638
+ *_param,
2639
+ _request_timeout=_request_timeout
2640
+ )
2641
+ response_data.read()
2642
+ return self.api_client.response_deserialize(
2643
+ response_data=response_data,
2644
+ response_types_map=_response_types_map,
2645
+ )
2646
+
2647
+
2648
+ @validate_call
2649
+ def set_website_geo_mapping_rules_without_preload_content(
2650
+ self,
2651
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2652
+ body: Optional[StrictStr] = None,
2653
+ _request_timeout: Union[
2654
+ None,
2655
+ Annotated[StrictFloat, Field(gt=0)],
2656
+ Tuple[
2657
+ Annotated[StrictFloat, Field(gt=0)],
2658
+ Annotated[StrictFloat, Field(gt=0)]
2659
+ ]
2660
+ ] = None,
2661
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2662
+ _content_type: Optional[StrictStr] = None,
2663
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2664
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2665
+ ) -> RESTResponseType:
2666
+ """Set custom geo mapping rules for website
2667
+
2668
+ API request to set custom geo mapping rules for website.
2669
+
2670
+ :param website_id: Website ID (required)
2671
+ :type website_id: str
2672
+ :param body:
2673
+ :type body: str
2674
+ :param _request_timeout: timeout setting for this request. If one
2675
+ number provided, it will be total request
2676
+ timeout. It can also be a pair (tuple) of
2677
+ (connection, read) timeouts.
2678
+ :type _request_timeout: int, tuple(int, int), optional
2679
+ :param _request_auth: set to override the auth_settings for an a single
2680
+ request; this effectively ignores the
2681
+ authentication in the spec for a single request.
2682
+ :type _request_auth: dict, optional
2683
+ :param _content_type: force content-type for the request.
2684
+ :type _content_type: str, Optional
2685
+ :param _headers: set to override the headers for a single
2686
+ request; this effectively ignores the headers
2687
+ in the spec for a single request.
2688
+ :type _headers: dict, optional
2689
+ :param _host_index: set to override the host_index for a single
2690
+ request; this effectively ignores the host_index
2691
+ in the spec for a single request.
2692
+ :type _host_index: int, optional
2693
+ :return: Returns the result object.
2694
+ """ # noqa: E501
2695
+
2696
+ _param = self._set_website_geo_mapping_rules_serialize(
2697
+ website_id=website_id,
2698
+ body=body,
2699
+ _request_auth=_request_auth,
2700
+ _content_type=_content_type,
2701
+ _headers=_headers,
2702
+ _host_index=_host_index
2703
+ )
2704
+
2705
+ _response_types_map: Dict[str, Optional[str]] = {
2706
+ '200': None,
2707
+ '401': None,
2708
+ '403': None,
2709
+ '404': None,
2710
+ '415': None,
2711
+ '500': None,
2712
+ }
2713
+ response_data = self.api_client.call_api(
2714
+ *_param,
2715
+ _request_timeout=_request_timeout
2716
+ )
2717
+ return response_data.response
2718
+
2719
+
2720
+ def _set_website_geo_mapping_rules_serialize(
2721
+ self,
2722
+ website_id,
2723
+ body,
2724
+ _request_auth,
2725
+ _content_type,
2726
+ _headers,
2727
+ _host_index,
2728
+ ) -> RequestSerialized:
2729
+
2730
+ _host = None
2731
+
2732
+ _collection_formats: Dict[str, str] = {
2733
+ }
2734
+
2735
+ _path_params: Dict[str, str] = {}
2736
+ _query_params: List[Tuple[str, str]] = []
2737
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2738
+ _form_params: List[Tuple[str, str]] = []
2739
+ _files: Dict[
2740
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2741
+ ] = {}
2742
+ _body_params: Optional[bytes] = None
2743
+
2744
+ # process the path parameters
2745
+ if website_id is not None:
2746
+ _path_params['websiteId'] = website_id
2747
+ # process the query parameters
2748
+ # process the header parameters
2749
+ # process the form parameters
2750
+ # process the body parameter
2751
+ if body is not None:
2752
+ _body_params = body
2753
+
2754
+
2755
+ # set the HTTP header `Accept`
2756
+ if 'Accept' not in _header_params:
2757
+ _header_params['Accept'] = self.api_client.select_header_accept(
2758
+ [
2759
+ 'text/csv'
2760
+ ]
2761
+ )
2762
+
2763
+ # set the HTTP header `Content-Type`
2764
+ if _content_type:
2765
+ _header_params['Content-Type'] = _content_type
2766
+ else:
2767
+ _default_content_type = (
2768
+ self.api_client.select_header_content_type(
2769
+ [
2770
+ 'text/csv'
2771
+ ]
2772
+ )
2773
+ )
2774
+ if _default_content_type is not None:
2775
+ _header_params['Content-Type'] = _default_content_type
2776
+
2777
+ # authentication setting
2778
+ _auth_settings: List[str] = [
2779
+ 'ApiKeyAuth'
2780
+ ]
2781
+
2782
+ return self.api_client.param_serialize(
2783
+ method='PUT',
2784
+ resource_path='/api/website-monitoring/config/{websiteId}/geo-mapping-rules',
2785
+ path_params=_path_params,
2786
+ query_params=_query_params,
2787
+ header_params=_header_params,
2788
+ body=_body_params,
2789
+ post_params=_form_params,
2790
+ files=_files,
2791
+ auth_settings=_auth_settings,
2792
+ collection_formats=_collection_formats,
2793
+ _host=_host,
2794
+ _request_auth=_request_auth
2795
+ )
2796
+
2797
+
2798
+
2799
+
2800
+ @validate_call
2801
+ def update_website_geo_location_configuration(
2802
+ self,
2803
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2804
+ geo_location_configuration: Optional[GeoLocationConfiguration] = None,
2805
+ _request_timeout: Union[
2806
+ None,
2807
+ Annotated[StrictFloat, Field(gt=0)],
2808
+ Tuple[
2809
+ Annotated[StrictFloat, Field(gt=0)],
2810
+ Annotated[StrictFloat, Field(gt=0)]
2811
+ ]
2812
+ ] = None,
2813
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2814
+ _content_type: Optional[StrictStr] = None,
2815
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2816
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2817
+ ) -> GeoLocationConfiguration:
2818
+ """Update geo location configuration for website
2819
+
2820
+ API request to update geo location configuration for website.
2821
+
2822
+ :param website_id: Website ID (required)
2823
+ :type website_id: str
2824
+ :param geo_location_configuration:
2825
+ :type geo_location_configuration: GeoLocationConfiguration
2826
+ :param _request_timeout: timeout setting for this request. If one
2827
+ number provided, it will be total request
2828
+ timeout. It can also be a pair (tuple) of
2829
+ (connection, read) timeouts.
2830
+ :type _request_timeout: int, tuple(int, int), optional
2831
+ :param _request_auth: set to override the auth_settings for an a single
2832
+ request; this effectively ignores the
2833
+ authentication in the spec for a single request.
2834
+ :type _request_auth: dict, optional
2835
+ :param _content_type: force content-type for the request.
2836
+ :type _content_type: str, Optional
2837
+ :param _headers: set to override the headers for a single
2838
+ request; this effectively ignores the headers
2839
+ in the spec for a single request.
2840
+ :type _headers: dict, optional
2841
+ :param _host_index: set to override the host_index for a single
2842
+ request; this effectively ignores the host_index
2843
+ in the spec for a single request.
2844
+ :type _host_index: int, optional
2845
+ :return: Returns the result object.
2846
+ """ # noqa: E501
2847
+
2848
+ _param = self._update_website_geo_location_configuration_serialize(
2849
+ website_id=website_id,
2850
+ geo_location_configuration=geo_location_configuration,
2851
+ _request_auth=_request_auth,
2852
+ _content_type=_content_type,
2853
+ _headers=_headers,
2854
+ _host_index=_host_index
2855
+ )
2856
+
2857
+ _response_types_map: Dict[str, Optional[str]] = {
2858
+ '200': "GeoLocationConfiguration",
2859
+ '401': None,
2860
+ '403': None,
2861
+ '404': None,
2862
+ '500': None,
2863
+ }
2864
+ response_data = self.api_client.call_api(
2865
+ *_param,
2866
+ _request_timeout=_request_timeout
2867
+ )
2868
+ response_data.read()
2869
+ return self.api_client.response_deserialize(
2870
+ response_data=response_data,
2871
+ response_types_map=_response_types_map,
2872
+ ).data
2873
+
2874
+
2875
+ @validate_call
2876
+ def update_website_geo_location_configuration_with_http_info(
2877
+ self,
2878
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2879
+ geo_location_configuration: Optional[GeoLocationConfiguration] = None,
2880
+ _request_timeout: Union[
2881
+ None,
2882
+ Annotated[StrictFloat, Field(gt=0)],
2883
+ Tuple[
2884
+ Annotated[StrictFloat, Field(gt=0)],
2885
+ Annotated[StrictFloat, Field(gt=0)]
2886
+ ]
2887
+ ] = None,
2888
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2889
+ _content_type: Optional[StrictStr] = None,
2890
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2891
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2892
+ ) -> ApiResponse[GeoLocationConfiguration]:
2893
+ """Update geo location configuration for website
2894
+
2895
+ API request to update geo location configuration for website.
2896
+
2897
+ :param website_id: Website ID (required)
2898
+ :type website_id: str
2899
+ :param geo_location_configuration:
2900
+ :type geo_location_configuration: GeoLocationConfiguration
2901
+ :param _request_timeout: timeout setting for this request. If one
2902
+ number provided, it will be total request
2903
+ timeout. It can also be a pair (tuple) of
2904
+ (connection, read) timeouts.
2905
+ :type _request_timeout: int, tuple(int, int), optional
2906
+ :param _request_auth: set to override the auth_settings for an a single
2907
+ request; this effectively ignores the
2908
+ authentication in the spec for a single request.
2909
+ :type _request_auth: dict, optional
2910
+ :param _content_type: force content-type for the request.
2911
+ :type _content_type: str, Optional
2912
+ :param _headers: set to override the headers for a single
2913
+ request; this effectively ignores the headers
2914
+ in the spec for a single request.
2915
+ :type _headers: dict, optional
2916
+ :param _host_index: set to override the host_index for a single
2917
+ request; this effectively ignores the host_index
2918
+ in the spec for a single request.
2919
+ :type _host_index: int, optional
2920
+ :return: Returns the result object.
2921
+ """ # noqa: E501
2922
+
2923
+ _param = self._update_website_geo_location_configuration_serialize(
2924
+ website_id=website_id,
2925
+ geo_location_configuration=geo_location_configuration,
2926
+ _request_auth=_request_auth,
2927
+ _content_type=_content_type,
2928
+ _headers=_headers,
2929
+ _host_index=_host_index
2930
+ )
2931
+
2932
+ _response_types_map: Dict[str, Optional[str]] = {
2933
+ '200': "GeoLocationConfiguration",
2934
+ '401': None,
2935
+ '403': None,
2936
+ '404': None,
2937
+ '500': None,
2938
+ }
2939
+ response_data = self.api_client.call_api(
2940
+ *_param,
2941
+ _request_timeout=_request_timeout
2942
+ )
2943
+ response_data.read()
2944
+ return self.api_client.response_deserialize(
2945
+ response_data=response_data,
2946
+ response_types_map=_response_types_map,
2947
+ )
2948
+
2949
+
2950
+ @validate_call
2951
+ def update_website_geo_location_configuration_without_preload_content(
2952
+ self,
2953
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
2954
+ geo_location_configuration: Optional[GeoLocationConfiguration] = None,
2955
+ _request_timeout: Union[
2956
+ None,
2957
+ Annotated[StrictFloat, Field(gt=0)],
2958
+ Tuple[
2959
+ Annotated[StrictFloat, Field(gt=0)],
2960
+ Annotated[StrictFloat, Field(gt=0)]
2961
+ ]
2962
+ ] = None,
2963
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2964
+ _content_type: Optional[StrictStr] = None,
2965
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2966
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2967
+ ) -> RESTResponseType:
2968
+ """Update geo location configuration for website
2969
+
2970
+ API request to update geo location configuration for website.
2971
+
2972
+ :param website_id: Website ID (required)
2973
+ :type website_id: str
2974
+ :param geo_location_configuration:
2975
+ :type geo_location_configuration: GeoLocationConfiguration
2976
+ :param _request_timeout: timeout setting for this request. If one
2977
+ number provided, it will be total request
2978
+ timeout. It can also be a pair (tuple) of
2979
+ (connection, read) timeouts.
2980
+ :type _request_timeout: int, tuple(int, int), optional
2981
+ :param _request_auth: set to override the auth_settings for an a single
2982
+ request; this effectively ignores the
2983
+ authentication in the spec for a single request.
2984
+ :type _request_auth: dict, optional
2985
+ :param _content_type: force content-type for the request.
2986
+ :type _content_type: str, Optional
2987
+ :param _headers: set to override the headers for a single
2988
+ request; this effectively ignores the headers
2989
+ in the spec for a single request.
2990
+ :type _headers: dict, optional
2991
+ :param _host_index: set to override the host_index for a single
2992
+ request; this effectively ignores the host_index
2993
+ in the spec for a single request.
2994
+ :type _host_index: int, optional
2995
+ :return: Returns the result object.
2996
+ """ # noqa: E501
2997
+
2998
+ _param = self._update_website_geo_location_configuration_serialize(
2999
+ website_id=website_id,
3000
+ geo_location_configuration=geo_location_configuration,
3001
+ _request_auth=_request_auth,
3002
+ _content_type=_content_type,
3003
+ _headers=_headers,
3004
+ _host_index=_host_index
3005
+ )
3006
+
3007
+ _response_types_map: Dict[str, Optional[str]] = {
3008
+ '200': "GeoLocationConfiguration",
3009
+ '401': None,
3010
+ '403': None,
3011
+ '404': None,
3012
+ '500': None,
3013
+ }
3014
+ response_data = self.api_client.call_api(
3015
+ *_param,
3016
+ _request_timeout=_request_timeout
3017
+ )
3018
+ return response_data.response
3019
+
3020
+
3021
+ def _update_website_geo_location_configuration_serialize(
3022
+ self,
3023
+ website_id,
3024
+ geo_location_configuration,
3025
+ _request_auth,
3026
+ _content_type,
3027
+ _headers,
3028
+ _host_index,
3029
+ ) -> RequestSerialized:
3030
+
3031
+ _host = None
3032
+
3033
+ _collection_formats: Dict[str, str] = {
3034
+ }
3035
+
3036
+ _path_params: Dict[str, str] = {}
3037
+ _query_params: List[Tuple[str, str]] = []
3038
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3039
+ _form_params: List[Tuple[str, str]] = []
3040
+ _files: Dict[
3041
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3042
+ ] = {}
3043
+ _body_params: Optional[bytes] = None
3044
+
3045
+ # process the path parameters
3046
+ if website_id is not None:
3047
+ _path_params['websiteId'] = website_id
3048
+ # process the query parameters
3049
+ # process the header parameters
3050
+ # process the form parameters
3051
+ # process the body parameter
3052
+ if geo_location_configuration is not None:
3053
+ _body_params = geo_location_configuration
3054
+
3055
+
3056
+ # set the HTTP header `Accept`
3057
+ if 'Accept' not in _header_params:
3058
+ _header_params['Accept'] = self.api_client.select_header_accept(
3059
+ [
3060
+ 'application/json'
3061
+ ]
3062
+ )
3063
+
3064
+ # set the HTTP header `Content-Type`
3065
+ if _content_type:
3066
+ _header_params['Content-Type'] = _content_type
3067
+ else:
3068
+ _default_content_type = (
3069
+ self.api_client.select_header_content_type(
3070
+ [
3071
+ 'application/json'
3072
+ ]
3073
+ )
3074
+ )
3075
+ if _default_content_type is not None:
3076
+ _header_params['Content-Type'] = _default_content_type
3077
+
3078
+ # authentication setting
3079
+ _auth_settings: List[str] = [
3080
+ 'ApiKeyAuth'
3081
+ ]
3082
+
3083
+ return self.api_client.param_serialize(
3084
+ method='PUT',
3085
+ resource_path='/api/website-monitoring/config/{websiteId}/geo-location',
3086
+ path_params=_path_params,
3087
+ query_params=_query_params,
3088
+ header_params=_header_params,
3089
+ body=_body_params,
3090
+ post_params=_form_params,
3091
+ files=_files,
3092
+ auth_settings=_auth_settings,
3093
+ collection_formats=_collection_formats,
3094
+ _host=_host,
3095
+ _request_auth=_request_auth
3096
+ )
3097
+
3098
+
3099
+
3100
+
3101
+ @validate_call
3102
+ def update_website_ip_masking_configuration(
3103
+ self,
3104
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3105
+ ip_masking_configuration: Optional[IpMaskingConfiguration] = None,
3106
+ _request_timeout: Union[
3107
+ None,
3108
+ Annotated[StrictFloat, Field(gt=0)],
3109
+ Tuple[
3110
+ Annotated[StrictFloat, Field(gt=0)],
3111
+ Annotated[StrictFloat, Field(gt=0)]
3112
+ ]
3113
+ ] = None,
3114
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3115
+ _content_type: Optional[StrictStr] = None,
3116
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3117
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3118
+ ) -> IpMaskingConfiguration:
3119
+ """Update IP masking configuration for website
3120
+
3121
+ API request to update IP masking configuration for website.
3122
+
3123
+ :param website_id: Website ID (required)
3124
+ :type website_id: str
3125
+ :param ip_masking_configuration:
3126
+ :type ip_masking_configuration: IpMaskingConfiguration
3127
+ :param _request_timeout: timeout setting for this request. If one
3128
+ number provided, it will be total request
3129
+ timeout. It can also be a pair (tuple) of
3130
+ (connection, read) timeouts.
3131
+ :type _request_timeout: int, tuple(int, int), optional
3132
+ :param _request_auth: set to override the auth_settings for an a single
3133
+ request; this effectively ignores the
3134
+ authentication in the spec for a single request.
3135
+ :type _request_auth: dict, optional
3136
+ :param _content_type: force content-type for the request.
3137
+ :type _content_type: str, Optional
3138
+ :param _headers: set to override the headers for a single
3139
+ request; this effectively ignores the headers
3140
+ in the spec for a single request.
3141
+ :type _headers: dict, optional
3142
+ :param _host_index: set to override the host_index for a single
3143
+ request; this effectively ignores the host_index
3144
+ in the spec for a single request.
3145
+ :type _host_index: int, optional
3146
+ :return: Returns the result object.
3147
+ """ # noqa: E501
3148
+
3149
+ _param = self._update_website_ip_masking_configuration_serialize(
3150
+ website_id=website_id,
3151
+ ip_masking_configuration=ip_masking_configuration,
3152
+ _request_auth=_request_auth,
3153
+ _content_type=_content_type,
3154
+ _headers=_headers,
3155
+ _host_index=_host_index
3156
+ )
3157
+
3158
+ _response_types_map: Dict[str, Optional[str]] = {
3159
+ '200': "IpMaskingConfiguration",
3160
+ '401': None,
3161
+ '403': None,
3162
+ '404': None,
3163
+ '500': None,
3164
+ }
3165
+ response_data = self.api_client.call_api(
3166
+ *_param,
3167
+ _request_timeout=_request_timeout
3168
+ )
3169
+ response_data.read()
3170
+ return self.api_client.response_deserialize(
3171
+ response_data=response_data,
3172
+ response_types_map=_response_types_map,
3173
+ ).data
3174
+
3175
+
3176
+ @validate_call
3177
+ def update_website_ip_masking_configuration_with_http_info(
3178
+ self,
3179
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3180
+ ip_masking_configuration: Optional[IpMaskingConfiguration] = None,
3181
+ _request_timeout: Union[
3182
+ None,
3183
+ Annotated[StrictFloat, Field(gt=0)],
3184
+ Tuple[
3185
+ Annotated[StrictFloat, Field(gt=0)],
3186
+ Annotated[StrictFloat, Field(gt=0)]
3187
+ ]
3188
+ ] = None,
3189
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3190
+ _content_type: Optional[StrictStr] = None,
3191
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3192
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3193
+ ) -> ApiResponse[IpMaskingConfiguration]:
3194
+ """Update IP masking configuration for website
3195
+
3196
+ API request to update IP masking configuration for website.
3197
+
3198
+ :param website_id: Website ID (required)
3199
+ :type website_id: str
3200
+ :param ip_masking_configuration:
3201
+ :type ip_masking_configuration: IpMaskingConfiguration
3202
+ :param _request_timeout: timeout setting for this request. If one
3203
+ number provided, it will be total request
3204
+ timeout. It can also be a pair (tuple) of
3205
+ (connection, read) timeouts.
3206
+ :type _request_timeout: int, tuple(int, int), optional
3207
+ :param _request_auth: set to override the auth_settings for an a single
3208
+ request; this effectively ignores the
3209
+ authentication in the spec for a single request.
3210
+ :type _request_auth: dict, optional
3211
+ :param _content_type: force content-type for the request.
3212
+ :type _content_type: str, Optional
3213
+ :param _headers: set to override the headers for a single
3214
+ request; this effectively ignores the headers
3215
+ in the spec for a single request.
3216
+ :type _headers: dict, optional
3217
+ :param _host_index: set to override the host_index for a single
3218
+ request; this effectively ignores the host_index
3219
+ in the spec for a single request.
3220
+ :type _host_index: int, optional
3221
+ :return: Returns the result object.
3222
+ """ # noqa: E501
3223
+
3224
+ _param = self._update_website_ip_masking_configuration_serialize(
3225
+ website_id=website_id,
3226
+ ip_masking_configuration=ip_masking_configuration,
3227
+ _request_auth=_request_auth,
3228
+ _content_type=_content_type,
3229
+ _headers=_headers,
3230
+ _host_index=_host_index
3231
+ )
3232
+
3233
+ _response_types_map: Dict[str, Optional[str]] = {
3234
+ '200': "IpMaskingConfiguration",
3235
+ '401': None,
3236
+ '403': None,
3237
+ '404': None,
3238
+ '500': None,
3239
+ }
3240
+ response_data = self.api_client.call_api(
3241
+ *_param,
3242
+ _request_timeout=_request_timeout
3243
+ )
3244
+ response_data.read()
3245
+ return self.api_client.response_deserialize(
3246
+ response_data=response_data,
3247
+ response_types_map=_response_types_map,
3248
+ )
3249
+
3250
+
3251
+ @validate_call
3252
+ def update_website_ip_masking_configuration_without_preload_content(
3253
+ self,
3254
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3255
+ ip_masking_configuration: Optional[IpMaskingConfiguration] = None,
3256
+ _request_timeout: Union[
3257
+ None,
3258
+ Annotated[StrictFloat, Field(gt=0)],
3259
+ Tuple[
3260
+ Annotated[StrictFloat, Field(gt=0)],
3261
+ Annotated[StrictFloat, Field(gt=0)]
3262
+ ]
3263
+ ] = None,
3264
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3265
+ _content_type: Optional[StrictStr] = None,
3266
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3267
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3268
+ ) -> RESTResponseType:
3269
+ """Update IP masking configuration for website
3270
+
3271
+ API request to update IP masking configuration for website.
3272
+
3273
+ :param website_id: Website ID (required)
3274
+ :type website_id: str
3275
+ :param ip_masking_configuration:
3276
+ :type ip_masking_configuration: IpMaskingConfiguration
3277
+ :param _request_timeout: timeout setting for this request. If one
3278
+ number provided, it will be total request
3279
+ timeout. It can also be a pair (tuple) of
3280
+ (connection, read) timeouts.
3281
+ :type _request_timeout: int, tuple(int, int), optional
3282
+ :param _request_auth: set to override the auth_settings for an a single
3283
+ request; this effectively ignores the
3284
+ authentication in the spec for a single request.
3285
+ :type _request_auth: dict, optional
3286
+ :param _content_type: force content-type for the request.
3287
+ :type _content_type: str, Optional
3288
+ :param _headers: set to override the headers for a single
3289
+ request; this effectively ignores the headers
3290
+ in the spec for a single request.
3291
+ :type _headers: dict, optional
3292
+ :param _host_index: set to override the host_index for a single
3293
+ request; this effectively ignores the host_index
3294
+ in the spec for a single request.
3295
+ :type _host_index: int, optional
3296
+ :return: Returns the result object.
3297
+ """ # noqa: E501
3298
+
3299
+ _param = self._update_website_ip_masking_configuration_serialize(
3300
+ website_id=website_id,
3301
+ ip_masking_configuration=ip_masking_configuration,
3302
+ _request_auth=_request_auth,
3303
+ _content_type=_content_type,
3304
+ _headers=_headers,
3305
+ _host_index=_host_index
3306
+ )
3307
+
3308
+ _response_types_map: Dict[str, Optional[str]] = {
3309
+ '200': "IpMaskingConfiguration",
3310
+ '401': None,
3311
+ '403': None,
3312
+ '404': None,
3313
+ '500': None,
3314
+ }
3315
+ response_data = self.api_client.call_api(
3316
+ *_param,
3317
+ _request_timeout=_request_timeout
3318
+ )
3319
+ return response_data.response
3320
+
3321
+
3322
+ def _update_website_ip_masking_configuration_serialize(
3323
+ self,
3324
+ website_id,
3325
+ ip_masking_configuration,
3326
+ _request_auth,
3327
+ _content_type,
3328
+ _headers,
3329
+ _host_index,
3330
+ ) -> RequestSerialized:
3331
+
3332
+ _host = None
3333
+
3334
+ _collection_formats: Dict[str, str] = {
3335
+ }
3336
+
3337
+ _path_params: Dict[str, str] = {}
3338
+ _query_params: List[Tuple[str, str]] = []
3339
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3340
+ _form_params: List[Tuple[str, str]] = []
3341
+ _files: Dict[
3342
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3343
+ ] = {}
3344
+ _body_params: Optional[bytes] = None
3345
+
3346
+ # process the path parameters
3347
+ if website_id is not None:
3348
+ _path_params['websiteId'] = website_id
3349
+ # process the query parameters
3350
+ # process the header parameters
3351
+ # process the form parameters
3352
+ # process the body parameter
3353
+ if ip_masking_configuration is not None:
3354
+ _body_params = ip_masking_configuration
3355
+
3356
+
3357
+ # set the HTTP header `Accept`
3358
+ if 'Accept' not in _header_params:
3359
+ _header_params['Accept'] = self.api_client.select_header_accept(
3360
+ [
3361
+ 'application/json'
3362
+ ]
3363
+ )
3364
+
3365
+ # set the HTTP header `Content-Type`
3366
+ if _content_type:
3367
+ _header_params['Content-Type'] = _content_type
3368
+ else:
3369
+ _default_content_type = (
3370
+ self.api_client.select_header_content_type(
3371
+ [
3372
+ 'application/json'
3373
+ ]
3374
+ )
3375
+ )
3376
+ if _default_content_type is not None:
3377
+ _header_params['Content-Type'] = _default_content_type
3378
+
3379
+ # authentication setting
3380
+ _auth_settings: List[str] = [
3381
+ 'ApiKeyAuth'
3382
+ ]
3383
+
3384
+ return self.api_client.param_serialize(
3385
+ method='PUT',
3386
+ resource_path='/api/website-monitoring/config/{websiteId}/ip-masking',
3387
+ path_params=_path_params,
3388
+ query_params=_query_params,
3389
+ header_params=_header_params,
3390
+ body=_body_params,
3391
+ post_params=_form_params,
3392
+ files=_files,
3393
+ auth_settings=_auth_settings,
3394
+ collection_formats=_collection_formats,
3395
+ _host=_host,
3396
+ _request_auth=_request_auth
3397
+ )
3398
+
3399
+
3400
+
3401
+
3402
+ @validate_call
3403
+ def upload_source_map_file(
3404
+ self,
3405
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3406
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
3407
+ file_format: Optional[StrictStr] = None,
3408
+ source_map: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
3409
+ url: Optional[StrictStr] = None,
3410
+ _request_timeout: Union[
3411
+ None,
3412
+ Annotated[StrictFloat, Field(gt=0)],
3413
+ Tuple[
3414
+ Annotated[StrictFloat, Field(gt=0)],
3415
+ Annotated[StrictFloat, Field(gt=0)]
3416
+ ]
3417
+ ] = None,
3418
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3419
+ _content_type: Optional[StrictStr] = None,
3420
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3421
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3422
+ ) -> SourceMapUploadConfig:
3423
+ """Upload source map file for website
3424
+
3425
+ API request to upload source map file for a website.
3426
+
3427
+ :param website_id: Website ID (required)
3428
+ :type website_id: str
3429
+ :param source_map_config_id: Source Map Config ID (required)
3430
+ :type source_map_config_id: str
3431
+ :param file_format:
3432
+ :type file_format: str
3433
+ :param source_map:
3434
+ :type source_map: bytearray
3435
+ :param url:
3436
+ :type url: str
3437
+ :param _request_timeout: timeout setting for this request. If one
3438
+ number provided, it will be total request
3439
+ timeout. It can also be a pair (tuple) of
3440
+ (connection, read) timeouts.
3441
+ :type _request_timeout: int, tuple(int, int), optional
3442
+ :param _request_auth: set to override the auth_settings for an a single
3443
+ request; this effectively ignores the
3444
+ authentication in the spec for a single request.
3445
+ :type _request_auth: dict, optional
3446
+ :param _content_type: force content-type for the request.
3447
+ :type _content_type: str, Optional
3448
+ :param _headers: set to override the headers for a single
3449
+ request; this effectively ignores the headers
3450
+ in the spec for a single request.
3451
+ :type _headers: dict, optional
3452
+ :param _host_index: set to override the host_index for a single
3453
+ request; this effectively ignores the host_index
3454
+ in the spec for a single request.
3455
+ :type _host_index: int, optional
3456
+ :return: Returns the result object.
3457
+ """ # noqa: E501
3458
+
3459
+ _param = self._upload_source_map_file_serialize(
3460
+ website_id=website_id,
3461
+ source_map_config_id=source_map_config_id,
3462
+ file_format=file_format,
3463
+ source_map=source_map,
3464
+ url=url,
3465
+ _request_auth=_request_auth,
3466
+ _content_type=_content_type,
3467
+ _headers=_headers,
3468
+ _host_index=_host_index
3469
+ )
3470
+
3471
+ _response_types_map: Dict[str, Optional[str]] = {
3472
+ '200': "SourceMapUploadConfig",
3473
+ '401': None,
3474
+ '403': None,
3475
+ '404': None,
3476
+ '500': None,
3477
+ }
3478
+ response_data = self.api_client.call_api(
3479
+ *_param,
3480
+ _request_timeout=_request_timeout
3481
+ )
3482
+ response_data.read()
3483
+ return self.api_client.response_deserialize(
3484
+ response_data=response_data,
3485
+ response_types_map=_response_types_map,
3486
+ ).data
3487
+
3488
+
3489
+ @validate_call
3490
+ def upload_source_map_file_with_http_info(
3491
+ self,
3492
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3493
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
3494
+ file_format: Optional[StrictStr] = None,
3495
+ source_map: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
3496
+ url: Optional[StrictStr] = None,
3497
+ _request_timeout: Union[
3498
+ None,
3499
+ Annotated[StrictFloat, Field(gt=0)],
3500
+ Tuple[
3501
+ Annotated[StrictFloat, Field(gt=0)],
3502
+ Annotated[StrictFloat, Field(gt=0)]
3503
+ ]
3504
+ ] = None,
3505
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3506
+ _content_type: Optional[StrictStr] = None,
3507
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3508
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3509
+ ) -> ApiResponse[SourceMapUploadConfig]:
3510
+ """Upload source map file for website
3511
+
3512
+ API request to upload source map file for a website.
3513
+
3514
+ :param website_id: Website ID (required)
3515
+ :type website_id: str
3516
+ :param source_map_config_id: Source Map Config ID (required)
3517
+ :type source_map_config_id: str
3518
+ :param file_format:
3519
+ :type file_format: str
3520
+ :param source_map:
3521
+ :type source_map: bytearray
3522
+ :param url:
3523
+ :type url: str
3524
+ :param _request_timeout: timeout setting for this request. If one
3525
+ number provided, it will be total request
3526
+ timeout. It can also be a pair (tuple) of
3527
+ (connection, read) timeouts.
3528
+ :type _request_timeout: int, tuple(int, int), optional
3529
+ :param _request_auth: set to override the auth_settings for an a single
3530
+ request; this effectively ignores the
3531
+ authentication in the spec for a single request.
3532
+ :type _request_auth: dict, optional
3533
+ :param _content_type: force content-type for the request.
3534
+ :type _content_type: str, Optional
3535
+ :param _headers: set to override the headers for a single
3536
+ request; this effectively ignores the headers
3537
+ in the spec for a single request.
3538
+ :type _headers: dict, optional
3539
+ :param _host_index: set to override the host_index for a single
3540
+ request; this effectively ignores the host_index
3541
+ in the spec for a single request.
3542
+ :type _host_index: int, optional
3543
+ :return: Returns the result object.
3544
+ """ # noqa: E501
3545
+
3546
+ _param = self._upload_source_map_file_serialize(
3547
+ website_id=website_id,
3548
+ source_map_config_id=source_map_config_id,
3549
+ file_format=file_format,
3550
+ source_map=source_map,
3551
+ url=url,
3552
+ _request_auth=_request_auth,
3553
+ _content_type=_content_type,
3554
+ _headers=_headers,
3555
+ _host_index=_host_index
3556
+ )
3557
+
3558
+ _response_types_map: Dict[str, Optional[str]] = {
3559
+ '200': "SourceMapUploadConfig",
3560
+ '401': None,
3561
+ '403': None,
3562
+ '404': None,
3563
+ '500': None,
3564
+ }
3565
+ response_data = self.api_client.call_api(
3566
+ *_param,
3567
+ _request_timeout=_request_timeout
3568
+ )
3569
+ response_data.read()
3570
+ return self.api_client.response_deserialize(
3571
+ response_data=response_data,
3572
+ response_types_map=_response_types_map,
3573
+ )
3574
+
3575
+
3576
+ @validate_call
3577
+ def upload_source_map_file_without_preload_content(
3578
+ self,
3579
+ website_id: Annotated[StrictStr, Field(description="Website ID")],
3580
+ source_map_config_id: Annotated[StrictStr, Field(description="Source Map Config ID")],
3581
+ file_format: Optional[StrictStr] = None,
3582
+ source_map: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
3583
+ url: Optional[StrictStr] = None,
3584
+ _request_timeout: Union[
3585
+ None,
3586
+ Annotated[StrictFloat, Field(gt=0)],
3587
+ Tuple[
3588
+ Annotated[StrictFloat, Field(gt=0)],
3589
+ Annotated[StrictFloat, Field(gt=0)]
3590
+ ]
3591
+ ] = None,
3592
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3593
+ _content_type: Optional[StrictStr] = None,
3594
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3595
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3596
+ ) -> RESTResponseType:
3597
+ """Upload source map file for website
3598
+
3599
+ API request to upload source map file for a website.
3600
+
3601
+ :param website_id: Website ID (required)
3602
+ :type website_id: str
3603
+ :param source_map_config_id: Source Map Config ID (required)
3604
+ :type source_map_config_id: str
3605
+ :param file_format:
3606
+ :type file_format: str
3607
+ :param source_map:
3608
+ :type source_map: bytearray
3609
+ :param url:
3610
+ :type url: str
3611
+ :param _request_timeout: timeout setting for this request. If one
3612
+ number provided, it will be total request
3613
+ timeout. It can also be a pair (tuple) of
3614
+ (connection, read) timeouts.
3615
+ :type _request_timeout: int, tuple(int, int), optional
3616
+ :param _request_auth: set to override the auth_settings for an a single
3617
+ request; this effectively ignores the
3618
+ authentication in the spec for a single request.
3619
+ :type _request_auth: dict, optional
3620
+ :param _content_type: force content-type for the request.
3621
+ :type _content_type: str, Optional
3622
+ :param _headers: set to override the headers for a single
3623
+ request; this effectively ignores the headers
3624
+ in the spec for a single request.
3625
+ :type _headers: dict, optional
3626
+ :param _host_index: set to override the host_index for a single
3627
+ request; this effectively ignores the host_index
3628
+ in the spec for a single request.
3629
+ :type _host_index: int, optional
3630
+ :return: Returns the result object.
3631
+ """ # noqa: E501
3632
+
3633
+ _param = self._upload_source_map_file_serialize(
3634
+ website_id=website_id,
3635
+ source_map_config_id=source_map_config_id,
3636
+ file_format=file_format,
3637
+ source_map=source_map,
3638
+ url=url,
3639
+ _request_auth=_request_auth,
3640
+ _content_type=_content_type,
3641
+ _headers=_headers,
3642
+ _host_index=_host_index
3643
+ )
3644
+
3645
+ _response_types_map: Dict[str, Optional[str]] = {
3646
+ '200': "SourceMapUploadConfig",
3647
+ '401': None,
3648
+ '403': None,
3649
+ '404': None,
3650
+ '500': None,
3651
+ }
3652
+ response_data = self.api_client.call_api(
3653
+ *_param,
3654
+ _request_timeout=_request_timeout
3655
+ )
3656
+ return response_data.response
3657
+
3658
+
3659
+ def _upload_source_map_file_serialize(
3660
+ self,
3661
+ website_id,
3662
+ source_map_config_id,
3663
+ file_format,
3664
+ source_map,
3665
+ url,
3666
+ _request_auth,
3667
+ _content_type,
3668
+ _headers,
3669
+ _host_index,
3670
+ ) -> RequestSerialized:
3671
+
3672
+ _host = None
3673
+
3674
+ _collection_formats: Dict[str, str] = {
3675
+ }
3676
+
3677
+ _path_params: Dict[str, str] = {}
3678
+ _query_params: List[Tuple[str, str]] = []
3679
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3680
+ _form_params: List[Tuple[str, str]] = []
3681
+ _files: Dict[
3682
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3683
+ ] = {}
3684
+ _body_params: Optional[bytes] = None
3685
+
3686
+ # process the path parameters
3687
+ if website_id is not None:
3688
+ _path_params['websiteId'] = website_id
3689
+ if source_map_config_id is not None:
3690
+ _path_params['sourceMapConfigId'] = source_map_config_id
3691
+ # process the query parameters
3692
+ # process the header parameters
3693
+ # process the form parameters
3694
+ if file_format is not None:
3695
+ _form_params.append(('fileFormat', file_format))
3696
+ if source_map is not None:
3697
+ _files['sourceMap'] = source_map
3698
+ if url is not None:
3699
+ _form_params.append(('url', url))
3700
+ # process the body parameter
3701
+
3702
+
3703
+ # set the HTTP header `Accept`
3704
+ if 'Accept' not in _header_params:
3705
+ _header_params['Accept'] = self.api_client.select_header_accept(
3706
+ [
3707
+ 'application/json'
3708
+ ]
3709
+ )
3710
+
3711
+ # set the HTTP header `Content-Type`
3712
+ if _content_type:
3713
+ _header_params['Content-Type'] = _content_type
3714
+ else:
3715
+ _default_content_type = (
3716
+ self.api_client.select_header_content_type(
3717
+ [
3718
+ 'multipart/form-data'
3719
+ ]
3720
+ )
3721
+ )
3722
+ if _default_content_type is not None:
3723
+ _header_params['Content-Type'] = _default_content_type
3724
+
3725
+ # authentication setting
3726
+ _auth_settings: List[str] = [
3727
+ 'ApiKeyAuth'
3728
+ ]
3729
+
3730
+ return self.api_client.param_serialize(
3731
+ method='PUT',
3732
+ resource_path='/api/website-monitoring/config/{websiteId}/sourcemap-upload/{sourceMapConfigId}/form',
3733
+ path_params=_path_params,
3734
+ query_params=_query_params,
3735
+ header_params=_header_params,
3736
+ body=_body_params,
3737
+ post_params=_form_params,
3738
+ files=_files,
3739
+ auth_settings=_auth_settings,
3740
+ collection_formats=_collection_formats,
3741
+ _host=_host,
3742
+ _request_auth=_request_auth
3743
+ )
3744
+
3745
+