oci 2.134.0__py3-none-any.whl → 2.135.1__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 (703) hide show
  1. oci/__init__.py +2 -2
  2. oci/access_governance_cp/access_governance_cp_client.py +8 -8
  3. oci/adm/application_dependency_management_client.py +36 -36
  4. oci/ai_anomaly_detection/anomaly_detection_client.py +36 -36
  5. oci/ai_document/ai_service_document_client.py +26 -26
  6. oci/ai_language/ai_service_language_client.py +44 -44
  7. oci/ai_speech/ai_service_speech_client.py +19 -19
  8. oci/ai_vision/ai_service_vision_client.py +25 -25
  9. oci/analytics/analytics_client.py +24 -24
  10. oci/analytics/models/analytics_instance.py +55 -0
  11. oci/analytics/models/create_analytics_instance_details.py +55 -0
  12. oci/analytics/models/update_analytics_instance_details.py +57 -2
  13. oci/announcements_service/announcement_client.py +5 -5
  14. oci/announcements_service/announcement_subscription_client.py +9 -9
  15. oci/announcements_service/announcements_preferences_client.py +4 -4
  16. oci/announcements_service/models/base_announcement.py +25 -25
  17. oci/announcements_service/models/base_create_announcements_preferences_details.py +5 -5
  18. oci/announcements_service/models/base_service.py +15 -15
  19. oci/announcements_service/service_client.py +1 -1
  20. oci/apigateway/api_gateway_client.py +21 -21
  21. oci/apigateway/deployment_client.py +6 -6
  22. oci/apigateway/gateway_client.py +6 -6
  23. oci/apigateway/models/body_validation_request_policy.py +5 -5
  24. oci/apigateway/models/header_validation_request_policy.py +5 -5
  25. oci/apigateway/models/validation_request_policy.py +5 -5
  26. oci/apigateway/subscribers_client.py +6 -6
  27. oci/apigateway/usage_plans_client.py +6 -6
  28. oci/apigateway/work_requests_client.py +5 -5
  29. oci/apm_config/config_client.py +9 -9
  30. oci/apm_control_plane/apm_domain_client.py +14 -14
  31. oci/apm_control_plane/models/base_domain_details.py +5 -5
  32. oci/apm_control_plane/models/base_key_details.py +5 -5
  33. oci/apm_synthetics/apm_synthetic_client.py +28 -28
  34. oci/apm_traces/attributes_client.py +8 -8
  35. oci/apm_traces/query_client.py +2 -2
  36. oci/apm_traces/trace_client.py +4 -4
  37. oci/appmgmt_control/appmgmt_control_client.py +8 -8
  38. oci/artifacts/artifacts_client.py +32 -32
  39. oci/audit/audit_client.py +3 -3
  40. oci/autoscaling/auto_scaling_client.py +11 -11
  41. oci/bastion/bastion_client.py +15 -15
  42. oci/bds/bds_client.py +72 -72
  43. oci/blockchain/blockchain_platform_client.py +27 -27
  44. oci/blockchain/models/availability_domain.py +5 -5
  45. oci/blockchain/models/peer_role.py +5 -5
  46. oci/budget/budget_client.py +10 -10
  47. oci/capacity_management/capacity_management_client.py +32 -32
  48. oci/certificates/certificates_client.py +5 -5
  49. oci/certificates_management/certificates_management_client.py +32 -32
  50. oci/cims/incident_client.py +8 -8
  51. oci/cims/user_client.py +1 -1
  52. oci/cloud_bridge/common_client.py +5 -5
  53. oci/cloud_bridge/discovery_client.py +14 -14
  54. oci/cloud_bridge/inventory_client.py +16 -16
  55. oci/cloud_bridge/ocb_agent_svc_client.py +23 -23
  56. oci/cloud_guard/cloud_guard_client.py +155 -155
  57. oci/cloud_migrations/migration_client.py +43 -43
  58. oci/cluster_placement_groups/cluster_placement_groups_cp_client.py +13 -13
  59. oci/compute_cloud_at_customer/compute_cloud_at_customer_client.py +12 -12
  60. oci/compute_instance_agent/compute_instance_agent_client.py +6 -6
  61. oci/compute_instance_agent/plugin_client.py +2 -2
  62. oci/compute_instance_agent/pluginconfig_client.py +1 -1
  63. oci/container_engine/container_engine_client.py +44 -44
  64. oci/container_instances/container_instance_client.py +18 -18
  65. oci/core/blockstorage_client.py +60 -60
  66. oci/core/compute_client.py +108 -102
  67. oci/core/compute_management_client.py +32 -32
  68. oci/core/models/add_network_security_group_security_rules_details.py +6 -2
  69. oci/core/models/compute_bare_metal_host.py +10 -10
  70. oci/core/models/compute_hpc_island.py +5 -5
  71. oci/core/models/compute_network_block.py +5 -5
  72. oci/core/models/create_service_gateway_details.py +2 -2
  73. oci/core/models/create_vcn_details.py +35 -0
  74. oci/core/models/create_vnic_details.py +35 -0
  75. oci/core/models/instance.py +82 -0
  76. oci/core/models/instance_configuration_create_vnic_details.py +35 -0
  77. oci/core/models/instance_configuration_launch_instance_details.py +35 -0
  78. oci/core/models/launch_instance_details.py +35 -0
  79. oci/core/models/service_gateway.py +4 -4
  80. oci/core/models/topology.py +5 -5
  81. oci/core/models/update_instance_details.py +35 -0
  82. oci/core/models/update_vcn_details.py +37 -2
  83. oci/core/models/update_vnic_details.py +35 -0
  84. oci/core/models/vcn.py +35 -0
  85. oci/core/models/vnic.py +35 -0
  86. oci/core/virtual_network_client.py +256 -253
  87. oci/dashboard_service/dashboard_client.py +6 -6
  88. oci/dashboard_service/dashboard_group_client.py +6 -6
  89. oci/data_catalog/data_catalog_client.py +149 -149
  90. oci/data_catalog/models/base_tag.py +5 -5
  91. oci/data_catalog/models/base_tag_summary.py +5 -5
  92. oci/data_catalog/models/object_lineage.py +5 -5
  93. oci/data_flow/data_flow_client.py +42 -42
  94. oci/data_integration/data_integration_client.py +163 -163
  95. oci/data_integration/models/abstract_call_attribute.py +5 -5
  96. oci/data_integration/models/abstract_data_operation_config.py +5 -5
  97. oci/data_integration/models/cancel_rest_call_config.py +5 -5
  98. oci/data_integration/models/composite_type.py +2 -1
  99. oci/data_integration/models/conditional_composite_field_map.py +2 -1
  100. oci/data_integration/models/connection_details.py +5 -5
  101. oci/data_integration/models/connection_from_adwc_details.py +2 -1
  102. oci/data_integration/models/connection_from_atp_details.py +2 -1
  103. oci/data_integration/models/connection_from_hdfs_details.py +2 -1
  104. oci/data_integration/models/connection_from_jdbc_details.py +2 -1
  105. oci/data_integration/models/connection_from_lake_details.py +2 -1
  106. oci/data_integration/models/connection_from_my_sql_details.py +2 -1
  107. oci/data_integration/models/connection_from_my_sql_heat_wave_details.py +2 -1
  108. oci/data_integration/models/connection_from_o_auth2_details.py +7 -6
  109. oci/data_integration/models/connection_from_object_storage_details.py +2 -1
  110. oci/data_integration/models/connection_from_oracle_ebs_details.py +2 -1
  111. oci/data_integration/models/connection_from_oracle_people_soft_details.py +2 -1
  112. oci/data_integration/models/connection_from_oracle_siebel_details.py +2 -1
  113. oci/data_integration/models/connection_summary_from_adwc.py +2 -1
  114. oci/data_integration/models/connection_summary_from_atp.py +2 -1
  115. oci/data_integration/models/connection_summary_from_hdfs.py +2 -1
  116. oci/data_integration/models/connection_summary_from_jdbc.py +2 -1
  117. oci/data_integration/models/connection_summary_from_lake.py +2 -1
  118. oci/data_integration/models/connection_summary_from_my_sql.py +2 -1
  119. oci/data_integration/models/connection_summary_from_my_sql_heat_wave.py +2 -1
  120. oci/data_integration/models/connection_summary_from_oracle_ebs.py +2 -1
  121. oci/data_integration/models/connection_summary_from_oracle_people_soft.py +2 -1
  122. oci/data_integration/models/connection_summary_from_oracle_siebel.py +2 -1
  123. oci/data_integration/models/connector_attribute.py +5 -5
  124. oci/data_integration/models/derived_type.py +2 -1
  125. oci/data_integration/models/dynamic_proxy_field.py +2 -1
  126. oci/data_integration/models/flow_port_link.py +5 -5
  127. oci/data_integration/models/key.py +5 -5
  128. oci/data_integration/models/materialized_composite_type.py +2 -1
  129. oci/data_integration/models/materialized_dynamic_field.py +2 -1
  130. oci/data_integration/models/output_link.py +2 -1
  131. oci/data_integration/models/poll_rest_call_config.py +5 -5
  132. oci/data_integration/models/rest_call_config.py +5 -5
  133. oci/data_integration/models/shape_field.py +2 -1
  134. oci/data_integration/models/task_run_lineage_details.py +5 -5
  135. oci/data_integration/models/typed_expression.py +2 -1
  136. oci/data_labeling_service/data_labeling_management_client.py +17 -17
  137. oci/data_labeling_service_dataplane/data_labeling_client.py +15 -15
  138. oci/data_safe/data_safe_client.py +781 -287
  139. oci/data_safe/data_safe_client_composite_operations.py +164 -0
  140. oci/data_safe/models/__init__.py +12 -0
  141. oci/data_safe/models/bulk_create_sql_firewall_allowed_sqls_details.py +142 -0
  142. oci/data_safe/models/bulk_delete_sql_firewall_allowed_sqls_details.py +99 -0
  143. oci/data_safe/models/generate_report_details.py +7 -3
  144. oci/data_safe/models/list_selection_mode.py +84 -0
  145. oci/data_safe/models/patch_sql_firewall_allowed_sql_details.py +103 -0
  146. oci/data_safe/models/report.py +7 -3
  147. oci/data_safe/models/report_definition.py +7 -3
  148. oci/data_safe/models/report_summary.py +7 -3
  149. oci/data_safe/models/schedule_report_details.py +7 -3
  150. oci/data_safe/models/scim_query_selection_mode.py +98 -0
  151. oci/data_safe/models/selection_details.py +113 -0
  152. oci/data_safe/models/sql_firewall_allowed_sql.py +10 -10
  153. oci/data_safe/models/work_request.py +15 -3
  154. oci/data_safe/models/work_request_summary.py +15 -3
  155. oci/data_science/data_science_client.py +91 -91
  156. oci/data_science/models/custom_expression_query_scaling_configuration.py +2 -1
  157. oci/data_science/models/scaling_configuration.py +5 -5
  158. oci/database/database_client.py +652 -394
  159. oci/database/database_client_composite_operations.py +176 -0
  160. oci/database/models/__init__.py +6 -0
  161. oci/database/models/autonomous_database.py +70 -0
  162. oci/database/models/autonomous_database_summary.py +70 -0
  163. oci/database/models/cloud_autonomous_vm_cluster.py +39 -0
  164. oci/database/models/cloud_autonomous_vm_cluster_summary.py +39 -0
  165. oci/database/models/cloud_vm_cluster.py +39 -0
  166. oci/database/models/cloud_vm_cluster_summary.py +39 -0
  167. oci/database/models/create_autonomous_database_base.py +50 -3
  168. oci/database/models/create_autonomous_database_clone_details.py +8 -1
  169. oci/database/models/create_autonomous_database_details.py +8 -1
  170. oci/database/models/create_autonomous_database_from_backup_details.py +8 -1
  171. oci/database/models/create_autonomous_database_from_backup_timestamp_details.py +8 -1
  172. oci/database/models/create_cloud_autonomous_vm_cluster_details.py +41 -2
  173. oci/database/models/create_cloud_vm_cluster_details.py +39 -0
  174. oci/database/models/create_cross_region_autonomous_database_data_guard_details.py +8 -1
  175. oci/database/models/create_cross_region_disaster_recovery_details.py +8 -1
  176. oci/database/models/create_cross_tenancy_disaster_recovery_details.py +8 -1
  177. oci/database/models/create_data_guard_association_with_new_db_system_details.py +39 -0
  178. oci/database/models/create_exadb_vm_cluster_details.py +39 -0
  179. oci/database/models/create_refreshable_autonomous_database_clone_details.py +8 -1
  180. oci/database/models/db_system.py +39 -0
  181. oci/database/models/db_system_summary.py +39 -0
  182. oci/database/models/exadb_vm_cluster.py +39 -0
  183. oci/database/models/exadb_vm_cluster_summary.py +39 -0
  184. oci/database/models/external_database_base.py +15 -15
  185. oci/database/models/infrastructure_target_version_summary.py +5 -5
  186. oci/database/models/launch_db_system_base.py +39 -0
  187. oci/database/models/launch_db_system_details.py +7 -0
  188. oci/database/models/launch_db_system_from_backup_details.py +7 -0
  189. oci/database/models/launch_db_system_from_database_details.py +7 -0
  190. oci/database/models/launch_db_system_from_db_system_details.py +7 -0
  191. oci/database/models/oci_provider_set_key_version_details.py +82 -0
  192. oci/database/models/pluggable_database.py +62 -0
  193. oci/database/models/pluggable_database_summary.py +62 -0
  194. oci/database/models/set_key_version_details.py +101 -0
  195. oci/database/models/undelete_autonomous_database_details.py +447 -0
  196. oci/database/models/update_autonomous_database_details.py +39 -0
  197. oci/database/models/update_cloud_autonomous_vm_cluster_details.py +41 -2
  198. oci/database/models/update_cloud_vm_cluster_details.py +39 -0
  199. oci/database/models/update_db_system_details.py +39 -0
  200. oci/database/models/update_exadb_vm_cluster_details.py +39 -0
  201. oci/database_management/db_management_client.py +211 -211
  202. oci/database_management/diagnosability_client.py +4 -4
  203. oci/database_management/managed_my_sql_databases_client.py +7 -7
  204. oci/database_management/models/awr_query_result.py +5 -5
  205. oci/database_management/models/dbm_resource.py +10 -10
  206. oci/database_management/models/discovered_external_asm_instance.py +4 -2
  207. oci/database_management/models/discovered_external_pluggable_database.py +4 -2
  208. oci/database_management/models/entity_discovered.py +10 -10
  209. oci/database_management/models/external_exadata_infrastructure_discovery_summary.py +9 -7
  210. oci/database_management/models/external_exadata_storage_grid_summary.py +4 -2
  211. oci/database_management/models/external_serviced_database.py +10 -10
  212. oci/database_management/models/external_storage_grid_discovery_summary.py +4 -2
  213. oci/database_management/models/external_storage_server_discovery_summary.py +4 -2
  214. oci/database_management/perfhub_client.py +1 -1
  215. oci/database_management/sql_tuning_client.py +17 -17
  216. oci/database_migration/database_migration_client.py +42 -42
  217. oci/database_migration/models/migration_parameter_base.py +5 -5
  218. oci/database_tools/database_tools_client.py +23 -23
  219. oci/delegate_access_control/delegate_access_control_client.py +26 -26
  220. oci/delegate_access_control/work_request_client.py +4 -4
  221. oci/demand_signal/occ_demand_signal_client.py +7 -7
  222. oci/desktops/desktop_service_client.py +21 -21
  223. oci/devops/devops_client.py +141 -141
  224. oci/devops/models/build_run_snapshot.py +5 -5
  225. oci/disaster_recovery/disaster_recovery_client.py +29 -29
  226. oci/dns/dns_client.py +52 -52
  227. oci/dts/appliance_export_job_client.py +6 -6
  228. oci/dts/shipping_vendors_client.py +1 -1
  229. oci/dts/transfer_appliance_client.py +8 -8
  230. oci/dts/transfer_appliance_entitlement_client.py +3 -3
  231. oci/dts/transfer_device_client.py +5 -5
  232. oci/dts/transfer_job_client.py +6 -6
  233. oci/dts/transfer_package_client.py +7 -7
  234. oci/em_warehouse/em_data_lake_client.py +13 -13
  235. oci/em_warehouse/em_warehouse_client.py +13 -13
  236. oci/email/email_client.py +31 -31
  237. oci/email_data_plane/email_dp_client.py +1 -1
  238. oci/events/events_client.py +6 -6
  239. oci/file_storage/file_storage_client.py +54 -54
  240. oci/fleet_apps_management/fleet_apps_management_admin_client.py +8 -8
  241. oci/fleet_apps_management/fleet_apps_management_client.py +35 -35
  242. oci/fleet_apps_management/fleet_apps_management_maintenance_window_client.py +5 -5
  243. oci/fleet_apps_management/fleet_apps_management_operations_client.py +13 -13
  244. oci/fleet_apps_management/fleet_apps_management_runbooks_client.py +4 -4
  245. oci/fleet_apps_management/models/fleet_target.py +10 -10
  246. oci/fleet_software_update/fleet_software_update_client.py +46 -46
  247. oci/functions/functions_invoke_client.py +1 -1
  248. oci/functions/functions_management_client.py +16 -16
  249. oci/fusion_apps/data_masking_activity_client.py +3 -3
  250. oci/fusion_apps/fusion_applications_client.py +41 -41
  251. oci/fusion_apps/fusion_environment_client.py +15 -15
  252. oci/fusion_apps/fusion_environment_family_client.py +8 -8
  253. oci/fusion_apps/models/allow_rule.py +1 -1
  254. oci/fusion_apps/models/create_refresh_activity_details.py +31 -0
  255. oci/fusion_apps/models/maintenance_policy.py +10 -10
  256. oci/fusion_apps/models/refresh_activity.py +31 -0
  257. oci/fusion_apps/models/refresh_activity_summary.py +31 -0
  258. oci/fusion_apps/refresh_activity_client.py +4 -4
  259. oci/fusion_apps/scheduled_activity_client.py +2 -2
  260. oci/fusion_apps/service_attachment_client.py +2 -2
  261. oci/generative_ai/generative_ai_client.py +22 -22
  262. oci/generative_ai_agent/__init__.py +14 -0
  263. oci/generative_ai_agent/generative_ai_agent_client.py +4245 -0
  264. oci/generative_ai_agent/generative_ai_agent_client_composite_operations.py +774 -0
  265. oci/generative_ai_agent/models/__init__.py +118 -0
  266. oci/generative_ai_agent/models/agent.py +536 -0
  267. oci/generative_ai_agent/models/agent_collection.py +74 -0
  268. oci/generative_ai_agent/models/agent_endpoint.py +648 -0
  269. oci/generative_ai_agent/models/agent_endpoint_collection.py +74 -0
  270. oci/generative_ai_agent/models/agent_endpoint_summary.py +612 -0
  271. oci/generative_ai_agent/models/agent_summary.py +500 -0
  272. oci/generative_ai_agent/models/basic_auth_secret.py +88 -0
  273. oci/generative_ai_agent/models/change_agent_compartment_details.py +78 -0
  274. oci/generative_ai_agent/models/change_agent_endpoint_compartment_details.py +78 -0
  275. oci/generative_ai_agent/models/change_knowledge_base_compartment_details.py +78 -0
  276. oci/generative_ai_agent/models/content_moderation_config.py +103 -0
  277. oci/generative_ai_agent/models/create_agent_details.py +288 -0
  278. oci/generative_ai_agent/models/create_agent_endpoint_details.py +400 -0
  279. oci/generative_ai_agent/models/create_data_ingestion_job_details.py +257 -0
  280. oci/generative_ai_agent/models/create_data_source_details.py +284 -0
  281. oci/generative_ai_agent/models/create_knowledge_base_details.py +249 -0
  282. oci/generative_ai_agent/models/data_ingestion_job.py +536 -0
  283. oci/generative_ai_agent/models/data_ingestion_job_collection.py +74 -0
  284. oci/generative_ai_agent/models/data_ingestion_job_statistics.py +136 -0
  285. oci/generative_ai_agent/models/data_ingestion_job_summary.py +469 -0
  286. oci/generative_ai_agent/models/data_source.py +536 -0
  287. oci/generative_ai_agent/models/data_source_collection.py +74 -0
  288. oci/generative_ai_agent/models/data_source_config.py +107 -0
  289. oci/generative_ai_agent/models/data_source_summary.py +469 -0
  290. oci/generative_ai_agent/models/database_connection.py +107 -0
  291. oci/generative_ai_agent/models/database_function.py +74 -0
  292. oci/generative_ai_agent/models/database_tool_connection.py +88 -0
  293. oci/generative_ai_agent/models/default_index_config.py +84 -0
  294. oci/generative_ai_agent/models/idcs_secret.py +181 -0
  295. oci/generative_ai_agent/models/index.py +101 -0
  296. oci/generative_ai_agent/models/index_config.py +127 -0
  297. oci/generative_ai_agent/models/index_schema.py +167 -0
  298. oci/generative_ai_agent/models/knowledge_base.py +501 -0
  299. oci/generative_ai_agent/models/knowledge_base_collection.py +74 -0
  300. oci/generative_ai_agent/models/knowledge_base_summary.py +434 -0
  301. oci/generative_ai_agent/models/object_storage_prefix.py +136 -0
  302. oci/generative_ai_agent/models/oci_database_config.py +111 -0
  303. oci/generative_ai_agent/models/oci_object_storage_data_source_config.py +84 -0
  304. oci/generative_ai_agent/models/oci_open_search_index_config.py +146 -0
  305. oci/generative_ai_agent/models/secret_detail.py +117 -0
  306. oci/generative_ai_agent/models/session_config.py +74 -0
  307. oci/generative_ai_agent/models/update_agent_details.py +253 -0
  308. oci/generative_ai_agent/models/update_agent_endpoint_details.py +303 -0
  309. oci/generative_ai_agent/models/update_data_source_details.py +214 -0
  310. oci/generative_ai_agent/models/update_knowledge_base_details.py +214 -0
  311. oci/generative_ai_agent/models/work_request.py +505 -0
  312. oci/generative_ai_agent/models/work_request_error.py +148 -0
  313. oci/generative_ai_agent/models/work_request_error_collection.py +74 -0
  314. oci/generative_ai_agent/models/work_request_log_entry.py +111 -0
  315. oci/generative_ai_agent/models/work_request_log_entry_collection.py +74 -0
  316. oci/generative_ai_agent/models/work_request_resource.py +240 -0
  317. oci/generative_ai_agent/models/work_request_summary.py +503 -0
  318. oci/generative_ai_agent/models/work_request_summary_collection.py +74 -0
  319. oci/generative_ai_agent_runtime/__init__.py +14 -0
  320. oci/generative_ai_agent_runtime/generative_ai_agent_runtime_client.py +689 -0
  321. oci/generative_ai_agent_runtime/generative_ai_agent_runtime_client_composite_operations.py +26 -0
  322. oci/generative_ai_agent_runtime/models/__init__.py +44 -0
  323. oci/generative_ai_agent_runtime/models/chat_details.py +134 -0
  324. oci/generative_ai_agent_runtime/models/chat_result.py +99 -0
  325. oci/generative_ai_agent_runtime/models/citation.py +99 -0
  326. oci/generative_ai_agent_runtime/models/create_session_details.py +103 -0
  327. oci/generative_ai_agent_runtime/models/error_trace.py +89 -0
  328. oci/generative_ai_agent_runtime/models/generation_trace.py +89 -0
  329. oci/generative_ai_agent_runtime/models/message.py +146 -0
  330. oci/generative_ai_agent_runtime/models/message_content.py +103 -0
  331. oci/generative_ai_agent_runtime/models/oci_database_source_location.py +148 -0
  332. oci/generative_ai_agent_runtime/models/oci_object_storage_source_location.py +82 -0
  333. oci/generative_ai_agent_runtime/models/oci_open_search_source_location.py +144 -0
  334. oci/generative_ai_agent_runtime/models/retrieval_trace.py +120 -0
  335. oci/generative_ai_agent_runtime/models/session.py +227 -0
  336. oci/generative_ai_agent_runtime/models/source_location.py +117 -0
  337. oci/generative_ai_agent_runtime/models/trace.py +148 -0
  338. oci/generative_ai_agent_runtime/models/update_session_details.py +103 -0
  339. oci/generative_ai_inference/generative_ai_inference_client.py +4 -4
  340. oci/generic_artifacts_content/generic_artifacts_content_client.py +3 -3
  341. oci/globally_distributed_database/sharded_database_service_client.py +30 -30
  342. oci/golden_gate/golden_gate_client.py +68 -68
  343. oci/governance_rules_control_plane/governance_rule_client.py +15 -15
  344. oci/governance_rules_control_plane/work_request_client.py +5 -5
  345. oci/healthchecks/health_checks_client.py +17 -17
  346. oci/identity/identity_client.py +145 -145
  347. oci/identity_data_plane/dataplane_client.py +2 -2
  348. oci/identity_domains/identity_domains_client.py +307 -307
  349. oci/integration/integration_instance_client.py +374 -18
  350. oci/integration/integration_instance_client_composite_operations.py +120 -0
  351. oci/integration/models/__init__.py +6 -0
  352. oci/integration/models/add_oracle_managed_custom_endpoint_details.py +146 -0
  353. oci/integration/models/create_integration_instance_details.py +31 -0
  354. oci/integration/models/cross_region_integration_instance_details.py +185 -0
  355. oci/integration/models/custom_endpoint_details.py +121 -0
  356. oci/integration/models/disaster_recovery_details.py +150 -0
  357. oci/integration/models/integration_instance.py +123 -7
  358. oci/integration/models/integration_instance_summary.py +96 -7
  359. oci/integration/models/work_request.py +15 -3
  360. oci/integration/models/work_request_summary.py +15 -3
  361. oci/jms/java_management_service_client.py +75 -75
  362. oci/jms_java_downloads/java_download_client.py +25 -25
  363. oci/key_management/ekm_client.py +5 -5
  364. oci/key_management/kms_crypto_client.py +6 -6
  365. oci/key_management/kms_hsm_cluster_client.py +12 -12
  366. oci/key_management/kms_management_client.py +21 -21
  367. oci/key_management/kms_vault_client.py +14 -14
  368. oci/license_manager/license_manager_client.py +18 -18
  369. oci/limits/limits_client.py +4 -4
  370. oci/limits/quotas_client.py +7 -7
  371. oci/load_balancer/load_balancer_client.py +61 -61
  372. oci/load_balancer/models/create_load_balancer_details.py +35 -0
  373. oci/load_balancer/models/load_balancer.py +35 -0
  374. oci/load_balancer/models/update_load_balancer_details.py +37 -2
  375. oci/lockbox/lockbox_client.py +24 -24
  376. oci/log_analytics/log_analytics_client.py +193 -193
  377. oci/log_analytics/models/chart_data_column.py +6 -3
  378. oci/log_analytics/models/function_field.py +4 -2
  379. oci/log_analytics/models/time_cluster_data_column.py +6 -3
  380. oci/log_analytics/models/time_stats_data_column.py +6 -3
  381. oci/logging/logging_management_client.py +30 -30
  382. oci/logging/models/unified_agent_monitoring_filter.py +5 -5
  383. oci/logging/models/unified_agent_tail_log_source.py +2 -1
  384. oci/logging/models/unified_agent_url_filter.py +2 -1
  385. oci/loggingingestion/logging_client.py +1 -1
  386. oci/loggingsearch/log_search_client.py +1 -1
  387. oci/management_agent/management_agent_client.py +28 -28
  388. oci/management_dashboard/dashx_apis_client.py +14 -14
  389. oci/marketplace/account_client.py +2 -2
  390. oci/marketplace/marketplace_client.py +30 -30
  391. oci/marketplace_private_offer/attachment_client.py +5 -5
  392. oci/marketplace_private_offer/offer_client.py +6 -6
  393. oci/marketplace_publisher/attachment_client.py +5 -5
  394. oci/marketplace_publisher/marketplace_publisher_client.py +71 -71
  395. oci/marketplace_publisher/offer_client.py +6 -6
  396. oci/media_services/media_services_client.py +60 -60
  397. oci/media_services/media_stream_client.py +2 -2
  398. oci/monitoring/models/__init__.py +6 -0
  399. oci/monitoring/models/alarm_status_summary.py +2 -0
  400. oci/monitoring/models/alarm_suppression.py +94 -2
  401. oci/monitoring/models/alarm_suppression_alarm_target.py +1 -1
  402. oci/monitoring/models/alarm_suppression_collection.py +3 -3
  403. oci/monitoring/models/alarm_suppression_compartment_target.py +127 -0
  404. oci/monitoring/models/alarm_suppression_history_item.py +43 -2
  405. oci/monitoring/models/alarm_suppression_summary.py +78 -2
  406. oci/monitoring/models/alarm_suppression_target.py +11 -3
  407. oci/monitoring/models/create_alarm_suppression_details.py +86 -6
  408. oci/monitoring/models/recurrence.py +127 -0
  409. oci/monitoring/models/suppression.py +1 -0
  410. oci/monitoring/models/suppression_condition.py +101 -0
  411. oci/monitoring/monitoring_client.py +115 -33
  412. oci/mysql/channels_client.py +7 -7
  413. oci/mysql/db_backups_client.py +7 -7
  414. oci/mysql/db_system_client.py +17 -17
  415. oci/mysql/mysqlaas_client.py +7 -7
  416. oci/mysql/replicas_client.py +5 -5
  417. oci/mysql/work_requests_client.py +4 -4
  418. oci/network_firewall/network_firewall_client.py +86 -86
  419. oci/network_load_balancer/models/create_network_load_balancer_details.py +43 -2
  420. oci/network_load_balancer/models/network_load_balancer.py +41 -0
  421. oci/network_load_balancer/models/network_load_balancer_summary.py +41 -0
  422. oci/network_load_balancer/models/update_network_load_balancer_details.py +43 -2
  423. oci/network_load_balancer/network_load_balancer_client.py +34 -34
  424. oci/nosql/nosql_client.py +24 -24
  425. oci/object_storage/object_storage_client.py +55 -55
  426. oci/oce/oce_instance_client.py +10 -10
  427. oci/oci_control_center/occ_metrics_client.py +3 -3
  428. oci/ocvp/cluster_client.py +5 -5
  429. oci/ocvp/esxi_host_client.py +8 -8
  430. oci/ocvp/sddc_client.py +14 -14
  431. oci/ocvp/work_request_client.py +4 -4
  432. oci/oda/management_client.py +59 -59
  433. oci/oda/models/bot.py +15 -15
  434. oci/oda/models/parameter.py +10 -10
  435. oci/oda/oda_client.py +17 -17
  436. oci/oda/odapackage_client.py +7 -7
  437. oci/onesubscription/billing_schedule_client.py +1 -1
  438. oci/onesubscription/commitment_client.py +2 -2
  439. oci/onesubscription/computed_usage_client.py +3 -3
  440. oci/onesubscription/invoice_summary_client.py +2 -2
  441. oci/onesubscription/organization_subscription_client.py +1 -1
  442. oci/onesubscription/ratecard_client.py +1 -1
  443. oci/onesubscription/subscribed_service_client.py +2 -2
  444. oci/onesubscription/subscription_client.py +1 -1
  445. oci/ons/notification_control_plane_client.py +6 -6
  446. oci/ons/notification_data_plane_client.py +10 -10
  447. oci/opa/opa_instance_client.py +13 -13
  448. oci/opensearch/opensearch_cluster_backup_client.py +4 -4
  449. oci/opensearch/opensearch_cluster_client.py +14 -14
  450. oci/operator_access_control/access_requests_client.py +10 -10
  451. oci/operator_access_control/operator_actions_client.py +2 -2
  452. oci/operator_access_control/operator_control_assignment_client.py +8 -8
  453. oci/operator_access_control/operator_control_client.py +6 -6
  454. oci/opsi/models/__init__.py +50 -0
  455. oci/opsi/models/add_em_managed_external_exadata_insight_members_details.py +1 -1
  456. oci/opsi/models/add_exadata_insight_members_details.py +11 -3
  457. oci/opsi/models/add_macs_managed_cloud_exadata_insight_members_details.py +78 -0
  458. oci/opsi/models/add_pe_comanaged_exadata_insight_members_details.py +1 -1
  459. oci/opsi/models/autonomous_database_configuration_summary.py +1 -1
  460. oci/opsi/models/autonomous_database_insight.py +1 -1
  461. oci/opsi/models/autonomous_database_insight_summary.py +1 -1
  462. oci/opsi/models/awr_query_result.py +5 -5
  463. oci/opsi/models/change_macs_managed_cloud_database_insight_connection_details.py +130 -0
  464. oci/opsi/models/create_database_insight_details.py +11 -3
  465. oci/opsi/models/create_em_managed_external_database_insight_details.py +1 -1
  466. oci/opsi/models/create_em_managed_external_exadata_insight_details.py +1 -1
  467. oci/opsi/models/create_em_managed_external_host_insight_details.py +1 -1
  468. oci/opsi/models/create_exadata_insight_details.py +11 -3
  469. oci/opsi/models/create_host_insight_details.py +7 -3
  470. oci/opsi/models/create_macs_managed_cloud_database_insight_details.py +315 -0
  471. oci/opsi/models/create_macs_managed_cloud_exadata_cluster_details.py +171 -0
  472. oci/opsi/models/create_macs_managed_cloud_exadata_insight_details.py +134 -0
  473. oci/opsi/models/create_macs_managed_cloud_exadata_vmcluster_details.py +96 -0
  474. oci/opsi/models/create_macs_managed_cloud_host_insight_details.py +1 -1
  475. oci/opsi/models/create_macs_managed_external_host_insight_details.py +1 -1
  476. oci/opsi/models/create_mds_my_sql_database_insight_details.py +1 -1
  477. oci/opsi/models/create_pe_comanaged_database_insight_details.py +1 -1
  478. oci/opsi/models/create_pe_comanaged_exadata_insight_details.py +1 -1
  479. oci/opsi/models/database_configuration_metric_group.py +35 -3
  480. oci/opsi/models/database_configuration_summary.py +11 -3
  481. oci/opsi/models/database_insight.py +11 -3
  482. oci/opsi/models/database_insight_summary.py +11 -3
  483. oci/opsi/models/db_connection_status.py +58 -0
  484. oci/opsi/models/db_external_instance.py +1 -1
  485. oci/opsi/models/db_external_properties.py +1 -1
  486. oci/opsi/models/db_parameters.py +1 -1
  487. oci/opsi/models/dbos_config_instance.py +1 -1
  488. oci/opsi/models/em_managed_external_database_configuration_summary.py +127 -3
  489. oci/opsi/models/em_managed_external_database_insight.py +1 -1
  490. oci/opsi/models/em_managed_external_database_insight_summary.py +1 -1
  491. oci/opsi/models/em_managed_external_exadata_insight.py +2 -2
  492. oci/opsi/models/em_managed_external_exadata_insight_summary.py +2 -2
  493. oci/opsi/models/em_managed_external_host_configuration_summary.py +127 -3
  494. oci/opsi/models/em_managed_external_host_insight.py +1 -1
  495. oci/opsi/models/em_managed_external_host_insight_summary.py +1 -1
  496. oci/opsi/models/enable_database_insight_details.py +11 -3
  497. oci/opsi/models/enable_em_managed_external_database_insight_details.py +1 -1
  498. oci/opsi/models/enable_em_managed_external_exadata_insight_details.py +1 -1
  499. oci/opsi/models/enable_em_managed_external_host_insight_details.py +1 -1
  500. oci/opsi/models/enable_exadata_insight_details.py +11 -3
  501. oci/opsi/models/enable_host_insight_details.py +7 -3
  502. oci/opsi/models/enable_macs_managed_cloud_database_insight_details.py +274 -0
  503. oci/opsi/models/enable_macs_managed_cloud_exadata_insight_details.py +51 -0
  504. oci/opsi/models/enable_macs_managed_cloud_host_insight_details.py +1 -1
  505. oci/opsi/models/enable_macs_managed_external_host_insight_details.py +1 -1
  506. oci/opsi/models/enable_mds_my_sql_database_insight_details.py +1 -1
  507. oci/opsi/models/enable_pe_comanaged_database_insight_details.py +1 -1
  508. oci/opsi/models/enable_pe_comanaged_exadata_insight_details.py +1 -1
  509. oci/opsi/models/exadata_asm_entity.py +151 -0
  510. oci/opsi/models/exadata_cell_config.py +213 -0
  511. oci/opsi/models/exadata_configuration_summary.py +30 -6
  512. oci/opsi/models/exadata_database_machine_configuration_summary.py +128 -4
  513. oci/opsi/models/exadata_exacc_configuration_summary.py +186 -0
  514. oci/opsi/models/exadata_exacs_configuration_summary.py +2 -2
  515. oci/opsi/models/exadata_insight.py +30 -6
  516. oci/opsi/models/exadata_insight_summary.py +30 -6
  517. oci/opsi/models/exadata_member_collection.py +19 -3
  518. oci/opsi/models/host_allocation.py +120 -0
  519. oci/opsi/models/host_configuration_summary.py +11 -3
  520. oci/opsi/models/host_containers.py +2 -2
  521. oci/opsi/models/host_insight.py +11 -3
  522. oci/opsi/models/host_insight_summary.py +11 -3
  523. oci/opsi/models/macs_managed_cloud_database_configuration_summary.py +253 -0
  524. oci/opsi/models/macs_managed_cloud_database_host_insight.py +394 -0
  525. oci/opsi/models/macs_managed_cloud_database_host_insight_summary.py +339 -0
  526. oci/opsi/models/macs_managed_cloud_database_insight.py +469 -0
  527. oci/opsi/models/macs_managed_cloud_database_insight_summary.py +315 -0
  528. oci/opsi/models/macs_managed_cloud_db_host_configuration_summary.py +282 -0
  529. oci/opsi/models/macs_managed_cloud_exadata_insight.py +278 -0
  530. oci/opsi/models/macs_managed_cloud_exadata_insight_summary.py +271 -0
  531. oci/opsi/models/macs_managed_cloud_host_configuration_summary.py +1 -1
  532. oci/opsi/models/macs_managed_cloud_host_insight.py +1 -1
  533. oci/opsi/models/macs_managed_cloud_host_insight_summary.py +1 -1
  534. oci/opsi/models/macs_managed_external_database_configuration_summary.py +1 -1
  535. oci/opsi/models/macs_managed_external_database_insight.py +1 -1
  536. oci/opsi/models/macs_managed_external_database_insight_summary.py +1 -1
  537. oci/opsi/models/macs_managed_external_host_configuration_summary.py +1 -1
  538. oci/opsi/models/macs_managed_external_host_insight.py +1 -1
  539. oci/opsi/models/macs_managed_external_host_insight_summary.py +1 -1
  540. oci/opsi/models/mds_my_sql_database_insight.py +1 -1
  541. oci/opsi/models/mds_my_sql_database_insight_summary.py +1 -1
  542. oci/opsi/models/mds_mysql_database_configuration_summary.py +1 -1
  543. oci/opsi/models/pe_comanaged_database_insight.py +1 -1
  544. oci/opsi/models/pe_comanaged_database_insight_summary.py +1 -1
  545. oci/opsi/models/pe_comanaged_exadata_insight.py +9 -5
  546. oci/opsi/models/pe_comanaged_exadata_insight_summary.py +9 -5
  547. oci/opsi/models/pe_comanaged_host_configuration_summary.py +1 -1
  548. oci/opsi/models/pe_comanaged_host_insight.py +1 -1
  549. oci/opsi/models/pe_comanaged_host_insight_summary.py +1 -1
  550. oci/opsi/models/pe_comanaged_managed_external_database_configuration_summary.py +1 -1
  551. oci/opsi/models/test_macs_managed_cloud_database_insight_connection_details.py +130 -0
  552. oci/opsi/models/update_autonomous_database_insight_details.py +1 -1
  553. oci/opsi/models/update_database_insight_details.py +11 -3
  554. oci/opsi/models/update_em_managed_external_database_insight_details.py +1 -1
  555. oci/opsi/models/update_em_managed_external_exadata_insight_details.py +1 -1
  556. oci/opsi/models/update_em_managed_external_host_insight_details.py +1 -1
  557. oci/opsi/models/update_exadata_insight_details.py +11 -3
  558. oci/opsi/models/update_host_insight_details.py +11 -3
  559. oci/opsi/models/update_macs_managed_cloud_database_host_insight_details.py +65 -0
  560. oci/opsi/models/update_macs_managed_cloud_database_insight_details.py +65 -0
  561. oci/opsi/models/update_macs_managed_cloud_exadata_insight_details.py +65 -0
  562. oci/opsi/models/update_macs_managed_cloud_host_insight_details.py +1 -1
  563. oci/opsi/models/update_macs_managed_external_database_insight_details.py +1 -1
  564. oci/opsi/models/update_macs_managed_external_host_insight_details.py +1 -1
  565. oci/opsi/models/update_mds_my_sql_database_insight.py +1 -1
  566. oci/opsi/models/update_pe_comanaged_database_insight_details.py +1 -1
  567. oci/opsi/models/update_pe_comanaged_exadata_insight_details.py +1 -1
  568. oci/opsi/models/update_pe_comanaged_host_insight_details.py +1 -1
  569. oci/opsi/models/work_request.py +11 -3
  570. oci/opsi/operations_insights_client.py +482 -214
  571. oci/opsi/operations_insights_client_composite_operations.py +81 -0
  572. oci/optimizer/optimizer_client.py +26 -26
  573. oci/os_management/event_client.py +8 -8
  574. oci/os_management/os_management_client.py +69 -69
  575. oci/os_management_hub/event_client.py +8 -8
  576. oci/os_management_hub/lifecycle_environment_client.py +12 -12
  577. oci/os_management_hub/managed_instance_client.py +31 -31
  578. oci/os_management_hub/managed_instance_group_client.py +25 -25
  579. oci/os_management_hub/management_station_client.py +10 -10
  580. oci/os_management_hub/models/event_content.py +5 -5
  581. oci/os_management_hub/models/exploit_attempt_event_content.py +2 -1
  582. oci/os_management_hub/models/package_summary.py +10 -10
  583. oci/os_management_hub/onboarding_client.py +6 -6
  584. oci/os_management_hub/reporting_managed_instance_client.py +3 -3
  585. oci/os_management_hub/scheduled_job_client.py +7 -7
  586. oci/os_management_hub/software_source_client.py +27 -27
  587. oci/os_management_hub/work_request_client.py +4 -4
  588. oci/osp_gateway/address_rule_service_client.py +1 -1
  589. oci/osp_gateway/address_service_client.py +2 -2
  590. oci/osp_gateway/invoice_service_client.py +5 -5
  591. oci/osp_gateway/subscription_service_client.py +5 -5
  592. oci/osub_billing_schedule/billing_schedule_client.py +1 -1
  593. oci/osub_organization_subscription/organization_subscription_client.py +1 -1
  594. oci/osub_subscription/commitment_client.py +2 -2
  595. oci/osub_subscription/ratecard_client.py +1 -1
  596. oci/osub_subscription/subscription_client.py +1 -1
  597. oci/osub_usage/computed_usage_client.py +3 -3
  598. oci/psql/postgresql_client.py +33 -33
  599. oci/queue/queue_admin_client.py +11 -11
  600. oci/queue/queue_client.py +8 -8
  601. oci/recovery/database_recovery_client.py +26 -26
  602. oci/redis/redis_cluster_client.py +12 -12
  603. oci/regions_definitions.py +8 -0
  604. oci/resource_manager/resource_manager_client.py +52 -52
  605. oci/resource_scheduler/schedule_client.py +13 -13
  606. oci/resource_search/resource_search_client.py +3 -3
  607. oci/rover/rover_bundle_client.py +8 -8
  608. oci/rover/rover_cluster_client.py +8 -8
  609. oci/rover/rover_entitlement_client.py +6 -6
  610. oci/rover/rover_node_client.py +15 -15
  611. oci/rover/shape_client.py +1 -1
  612. oci/rover/work_requests_client.py +5 -5
  613. oci/sch/connector_plugins_client.py +2 -2
  614. oci/sch/service_connector_client.py +12 -12
  615. oci/secrets/secrets_client.py +3 -3
  616. oci/security_attribute/__init__.py +14 -0
  617. oci/security_attribute/models/__init__.py +54 -0
  618. oci/security_attribute/models/base_security_attribute_validator.py +122 -0
  619. oci/security_attribute/models/bulk_delete_security_attributes_details.py +72 -0
  620. oci/security_attribute/models/bulk_edit_resource.py +134 -0
  621. oci/security_attribute/models/bulk_edit_security_attribute_details.py +134 -0
  622. oci/security_attribute/models/bulk_edit_security_attribute_operation_details.py +147 -0
  623. oci/security_attribute/models/change_security_attribute_namespace_compartment_details.py +72 -0
  624. oci/security_attribute/models/create_security_attribute_details.py +132 -0
  625. oci/security_attribute/models/create_security_attribute_namespace_details.py +216 -0
  626. oci/security_attribute/models/default_security_attribute_validator.py +53 -0
  627. oci/security_attribute/models/enum_security_attribute_validator.py +85 -0
  628. oci/security_attribute/models/security_attribute.py +421 -0
  629. oci/security_attribute/models/security_attribute_namespace.py +446 -0
  630. oci/security_attribute/models/security_attribute_namespace_summary.py +410 -0
  631. oci/security_attribute/models/security_attribute_summary.py +361 -0
  632. oci/security_attribute/models/security_attribute_work_request.py +387 -0
  633. oci/security_attribute/models/security_attribute_work_request_error_summary.py +136 -0
  634. oci/security_attribute/models/security_attribute_work_request_log_summary.py +105 -0
  635. oci/security_attribute/models/security_attribute_work_request_summary.py +386 -0
  636. oci/security_attribute/models/update_security_attribute_details.py +136 -0
  637. oci/security_attribute/models/update_security_attribute_namespace_details.py +191 -0
  638. oci/security_attribute/models/work_request_resource.py +197 -0
  639. oci/security_attribute/security_attribute_client.py +2321 -0
  640. oci/security_attribute/security_attribute_client_composite_operations.py +265 -0
  641. oci/service_catalog/service_catalog_client.py +26 -26
  642. oci/service_manager_proxy/service_manager_proxy_client.py +2 -2
  643. oci/service_mesh/models/traffic_rule_target.py +5 -5
  644. oci/service_mesh/service_mesh_client.py +48 -48
  645. oci/stack_monitoring/stack_monitoring_client.py +64 -64
  646. oci/streaming/stream_admin_client.py +18 -18
  647. oci/streaming/stream_client.py +8 -8
  648. oci/tenant_manager_control_plane/domain_client.py +5 -5
  649. oci/tenant_manager_control_plane/domain_governance_client.py +5 -5
  650. oci/tenant_manager_control_plane/governance_client.py +2 -2
  651. oci/tenant_manager_control_plane/link_client.py +3 -3
  652. oci/tenant_manager_control_plane/orders_client.py +2 -2
  653. oci/tenant_manager_control_plane/organization_client.py +10 -10
  654. oci/tenant_manager_control_plane/recipient_invitation_client.py +5 -5
  655. oci/tenant_manager_control_plane/sender_invitation_client.py +5 -5
  656. oci/tenant_manager_control_plane/subscription_client.py +11 -11
  657. oci/tenant_manager_control_plane/work_request_client.py +4 -4
  658. oci/threat_intelligence/threatintel_client.py +5 -5
  659. oci/usage/resources_client.py +2 -2
  660. oci/usage/rewards_client.py +6 -6
  661. oci/usage/usagelimits_client.py +1 -1
  662. oci/usage_api/usageapi_client.py +33 -33
  663. oci/vault/vaults_client.py +13 -13
  664. oci/vbs_inst/vbs_instance_client.py +10 -10
  665. oci/version.py +1 -1
  666. oci/visual_builder/vb_instance_client.py +13 -13
  667. oci/vn_monitoring/models/topology.py +5 -5
  668. oci/vn_monitoring/vn_monitoring_client.py +12 -12
  669. oci/vulnerability_scanning/vulnerability_scanning_client.py +58 -58
  670. oci/waa/waa_client.py +13 -13
  671. oci/waa/work_request_client.py +4 -4
  672. oci/waas/redirect_client.py +6 -6
  673. oci/waas/waas_client.py +66 -66
  674. oci/waf/models/protection_rule.py +4 -2
  675. oci/waf/models/request_rate_limiting_rule.py +4 -2
  676. oci/waf/models/web_app_firewall_policy_rule.py +10 -10
  677. oci/waf/waf_client.py +24 -24
  678. oci/work_requests/work_request_client.py +4 -4
  679. oci/zpr/__init__.py +14 -0
  680. oci/zpr/models/__init__.py +42 -0
  681. oci/zpr/models/configuration.py +449 -0
  682. oci/zpr/models/create_configuration_details.py +189 -0
  683. oci/zpr/models/create_zpr_policy_details.py +251 -0
  684. oci/zpr/models/update_zpr_policy_details.py +185 -0
  685. oci/zpr/models/work_request.py +459 -0
  686. oci/zpr/models/work_request_error.py +146 -0
  687. oci/zpr/models/work_request_error_collection.py +72 -0
  688. oci/zpr/models/work_request_log_entry.py +109 -0
  689. oci/zpr/models/work_request_log_entry_collection.py +72 -0
  690. oci/zpr/models/work_request_resource.py +238 -0
  691. oci/zpr/models/work_request_summary.py +457 -0
  692. oci/zpr/models/work_request_summary_collection.py +72 -0
  693. oci/zpr/models/zpr_policy.py +505 -0
  694. oci/zpr/models/zpr_policy_collection.py +72 -0
  695. oci/zpr/models/zpr_policy_summary.py +463 -0
  696. oci/zpr/zpr_client.py +2124 -0
  697. oci/zpr/zpr_client_composite_operations.py +197 -0
  698. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/METADATA +1 -1
  699. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/RECORD +703 -542
  700. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/LICENSE.txt +0 -0
  701. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/THIRD_PARTY_LICENSES.txt +0 -0
  702. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/WHEEL +0 -0
  703. {oci-2.134.0.dist-info → oci-2.135.1.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,4245 @@
1
+ # coding: utf-8
2
+ # Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved.
3
+ # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
4
+
5
+ # NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20240531
6
+
7
+ from __future__ import absolute_import
8
+
9
+ from oci._vendor import requests # noqa: F401
10
+ from oci._vendor import six
11
+
12
+ from oci import retry, circuit_breaker # noqa: F401
13
+ from oci.base_client import BaseClient
14
+ from oci.config import get_config_value_or_default, validate_config
15
+ from oci.signer import Signer
16
+ from oci.util import Sentinel, get_signer_from_authentication_type, AUTHENTICATION_TYPE_FIELD_NAME
17
+ from oci.exceptions import InvalidAlloyConfig
18
+ from oci.alloy import OCI_SDK_ENABLED_SERVICES_SET
19
+ from .models import generative_ai_agent_type_mapping
20
+ missing = Sentinel("Missing")
21
+
22
+
23
+ class GenerativeAiAgentClient(object):
24
+ """
25
+ **Generative AI Agents API**
26
+
27
+
28
+ OCI Generative AI Agents is a fully managed service that combines the power of large language models (LLMs) with an intelligent retrieval system to create contextually relevant answers by searching your knowledge base, making your AI applications smart and efficient.
29
+
30
+ OCI Generative AI Agents supports several ways to onboard your data and then allows you and your customers to interact with your data using a chat interface or API.
31
+
32
+ Use the Generative AI Agents API to create and manage agents, knowledge bases, data sources, endpoints, data ingestion jobs, and work requests.
33
+
34
+ For creating and managing client chat sessions see the [Generative AI Agents Client API](#/EN/generative-ai-agents-client/latest/).
35
+
36
+ To learn more about the service, see the [Generative AI Agents documentation](/iaas/Content/generative-ai-agents/home.htm).
37
+ """
38
+
39
+ def __init__(self, config, **kwargs):
40
+ """
41
+ Creates a new service client
42
+
43
+ :param dict config:
44
+ Configuration keys and values as per `SDK and Tool Configuration <https://docs.cloud.oracle.com/Content/API/Concepts/sdkconfig.htm>`__.
45
+ The :py:meth:`~oci.config.from_file` method can be used to load configuration from a file. Alternatively, a ``dict`` can be passed. You can validate_config
46
+ the dict using :py:meth:`~oci.config.validate_config`
47
+
48
+ :param str service_endpoint: (optional)
49
+ The endpoint of the service to call using this client. For example ``https://iaas.us-ashburn-1.oraclecloud.com``. If this keyword argument is
50
+ not provided then it will be derived using the region in the config parameter. You should only provide this keyword argument if you have an explicit
51
+ need to specify a service endpoint.
52
+
53
+ :param timeout: (optional)
54
+ The connection and read timeouts for the client. The default values are connection timeout 10 seconds and read timeout 60 seconds. This keyword argument can be provided
55
+ as a single float, in which case the value provided is used for both the read and connection timeouts, or as a tuple of two floats. If
56
+ a tuple is provided then the first value is used as the connection timeout and the second value as the read timeout.
57
+ :type timeout: float or tuple(float, float)
58
+
59
+ :param signer: (optional)
60
+ The signer to use when signing requests made by the service client. The default is to use a :py:class:`~oci.signer.Signer` based on the values
61
+ provided in the config parameter.
62
+
63
+ One use case for this parameter is for `Instance Principals authentication <https://docs.cloud.oracle.com/Content/Identity/Tasks/callingservicesfrominstances.htm>`__
64
+ by passing an instance of :py:class:`~oci.auth.signers.InstancePrincipalsSecurityTokenSigner` as the value for this keyword argument
65
+ :type signer: :py:class:`~oci.signer.AbstractBaseSigner`
66
+
67
+ :param obj retry_strategy: (optional)
68
+ A retry strategy to apply to all calls made by this service client (i.e. at the client level). There is no retry strategy applied by default.
69
+ Retry strategies can also be applied at the operation level by passing a ``retry_strategy`` keyword argument as part of calling the operation.
70
+ Any value provided at the operation level will override whatever is specified at the client level.
71
+
72
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. A convenience :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY`
73
+ is also available. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
74
+
75
+ :param obj circuit_breaker_strategy: (optional)
76
+ A circuit breaker strategy to apply to all calls made by this service client (i.e. at the client level).
77
+ This client uses :py:data:`~oci.circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY` as default if no circuit breaker strategy is provided.
78
+ The specifics of circuit breaker strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/circuit_breakers.html>`__.
79
+
80
+ :param function circuit_breaker_callback: (optional)
81
+ Callback function to receive any exceptions triggerred by the circuit breaker.
82
+
83
+ :param bool client_level_realm_specific_endpoint_template_enabled: (optional)
84
+ A boolean flag to indicate whether or not this client should be created with realm specific endpoint template enabled or disable. By default, this will be set as None.
85
+
86
+ :param allow_control_chars: (optional)
87
+ allow_control_chars is a boolean to indicate whether or not this client should allow control characters in the response object. By default, the client will not
88
+ allow control characters to be in the response object.
89
+ """
90
+ if not OCI_SDK_ENABLED_SERVICES_SET.is_service_enabled("generative_ai_agent"):
91
+ raise InvalidAlloyConfig("The Alloy configuration has disabled this service, this behavior is controlled by OCI_SDK_ENABLED_SERVICES_SET variable. Please check if your local alloy-config file configured the service you're targeting or contact the cloud provider on the availability of this service")
92
+
93
+ validate_config(config, signer=kwargs.get('signer'))
94
+ if 'signer' in kwargs:
95
+ signer = kwargs['signer']
96
+
97
+ elif AUTHENTICATION_TYPE_FIELD_NAME in config:
98
+ signer = get_signer_from_authentication_type(config)
99
+
100
+ else:
101
+ signer = Signer(
102
+ tenancy=config["tenancy"],
103
+ user=config["user"],
104
+ fingerprint=config["fingerprint"],
105
+ private_key_file_location=config.get("key_file"),
106
+ pass_phrase=get_config_value_or_default(config, "pass_phrase"),
107
+ private_key_content=config.get("key_content")
108
+ )
109
+
110
+ base_client_init_kwargs = {
111
+ 'regional_client': True,
112
+ 'service_endpoint': kwargs.get('service_endpoint'),
113
+ 'base_path': '/20240531',
114
+ 'service_endpoint_template': 'https://agent.generativeai.{region}.oci.{secondLevelDomain}',
115
+ 'service_endpoint_template_per_realm': { }, # noqa: E201 E202
116
+ 'skip_deserialization': kwargs.get('skip_deserialization', False),
117
+ 'circuit_breaker_strategy': kwargs.get('circuit_breaker_strategy', circuit_breaker.GLOBAL_CIRCUIT_BREAKER_STRATEGY),
118
+ 'client_level_realm_specific_endpoint_template_enabled': kwargs.get('client_level_realm_specific_endpoint_template_enabled')
119
+ }
120
+ if 'timeout' in kwargs:
121
+ base_client_init_kwargs['timeout'] = kwargs.get('timeout')
122
+ if base_client_init_kwargs.get('circuit_breaker_strategy') is None:
123
+ base_client_init_kwargs['circuit_breaker_strategy'] = circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY
124
+ if 'allow_control_chars' in kwargs:
125
+ base_client_init_kwargs['allow_control_chars'] = kwargs.get('allow_control_chars')
126
+ self.base_client = BaseClient("generative_ai_agent", config, signer, generative_ai_agent_type_mapping, **base_client_init_kwargs)
127
+ self.retry_strategy = kwargs.get('retry_strategy')
128
+ self.circuit_breaker_callback = kwargs.get('circuit_breaker_callback')
129
+
130
+ def cancel_work_request(self, work_request_id, **kwargs):
131
+ """
132
+ **CancelWorkRequest**
133
+
134
+ Cancels a work request.
135
+
136
+
137
+ :param str work_request_id: (required)
138
+ The `OCID`__ of the asynchronous work request.
139
+
140
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
141
+
142
+ :param str if_match: (optional)
143
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
144
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
145
+ that resource. The resource will be updated or deleted only if the etag you provide
146
+ matches the resource's current etag value.
147
+
148
+ :param str opc_request_id: (optional)
149
+ Unique Oracle-assigned identifier for the request. If you need to contact
150
+ Oracle about a particular request, please provide the request ID.
151
+ The only valid characters for request IDs are letters, numbers,
152
+ underscore, and dash.
153
+
154
+ :param obj retry_strategy: (optional)
155
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
156
+
157
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
158
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
159
+
160
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
161
+
162
+ :param bool allow_control_chars: (optional)
163
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
164
+ By default, the response will not allow control characters in strings
165
+
166
+ :return: A :class:`~oci.response.Response` object with data of type None
167
+ :rtype: :class:`~oci.response.Response`
168
+
169
+ :example:
170
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/cancel_work_request.py.html>`__ to see an example of how to use cancel_work_request API.
171
+ """
172
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
173
+ required_arguments = ['workRequestId']
174
+ resource_path = "/workRequests/{workRequestId}"
175
+ method = "DELETE"
176
+ operation_name = "cancel_work_request"
177
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/WorkRequest/CancelWorkRequest"
178
+
179
+ # Don't accept unknown kwargs
180
+ expected_kwargs = [
181
+ "allow_control_chars",
182
+ "retry_strategy",
183
+ "if_match",
184
+ "opc_request_id"
185
+ ]
186
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
187
+ if extra_kwargs:
188
+ raise ValueError(
189
+ f"cancel_work_request got unknown kwargs: {extra_kwargs!r}")
190
+
191
+ path_params = {
192
+ "workRequestId": work_request_id
193
+ }
194
+
195
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
196
+
197
+ for (k, v) in six.iteritems(path_params):
198
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
199
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
200
+
201
+ header_params = {
202
+ "accept": "application/json",
203
+ "content-type": "application/json",
204
+ "if-match": kwargs.get("if_match", missing),
205
+ "opc-request-id": kwargs.get("opc_request_id", missing)
206
+ }
207
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
208
+
209
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
210
+ operation_retry_strategy=kwargs.get('retry_strategy'),
211
+ client_retry_strategy=self.retry_strategy
212
+ )
213
+ if retry_strategy is None:
214
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
215
+
216
+ if retry_strategy:
217
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
218
+ self.base_client.add_opc_client_retries_header(header_params)
219
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
220
+ return retry_strategy.make_retrying_call(
221
+ self.base_client.call_api,
222
+ resource_path=resource_path,
223
+ method=method,
224
+ path_params=path_params,
225
+ header_params=header_params,
226
+ allow_control_chars=kwargs.get('allow_control_chars'),
227
+ operation_name=operation_name,
228
+ api_reference_link=api_reference_link,
229
+ required_arguments=required_arguments)
230
+ else:
231
+ return self.base_client.call_api(
232
+ resource_path=resource_path,
233
+ method=method,
234
+ path_params=path_params,
235
+ header_params=header_params,
236
+ allow_control_chars=kwargs.get('allow_control_chars'),
237
+ operation_name=operation_name,
238
+ api_reference_link=api_reference_link,
239
+ required_arguments=required_arguments)
240
+
241
+ def change_agent_compartment(self, agent_id, change_agent_compartment_details, **kwargs):
242
+ """
243
+ **ChangeAgentCompartment**
244
+
245
+ Moves an agent into a different compartment within the same tenancy. For information about moving resources between
246
+ compartments, see `Moving Resources to a Different Compartment`__.
247
+
248
+ __ https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes
249
+
250
+
251
+ :param str agent_id: (required)
252
+ The `OCID`__ of the agent.
253
+
254
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
255
+
256
+ :param oci.generative_ai_agent.models.ChangeAgentCompartmentDetails change_agent_compartment_details: (required)
257
+ The information to be updated.
258
+
259
+ :param str if_match: (optional)
260
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
261
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
262
+ that resource. The resource will be updated or deleted only if the etag you provide
263
+ matches the resource's current etag value.
264
+
265
+ :param str opc_request_id: (optional)
266
+ Unique Oracle-assigned identifier for the request. If you need to contact
267
+ Oracle about a particular request, please provide the request ID.
268
+ The only valid characters for request IDs are letters, numbers,
269
+ underscore, and dash.
270
+
271
+ :param str opc_retry_token: (optional)
272
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
273
+ server error without risk of running that same action again. Retry tokens expire after 24
274
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
275
+ has been deleted and removed from the system, then a retry of the original creation request
276
+ might be rejected.
277
+
278
+ :param obj retry_strategy: (optional)
279
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
280
+
281
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
282
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
283
+
284
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
285
+
286
+ :param bool allow_control_chars: (optional)
287
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
288
+ By default, the response will not allow control characters in strings
289
+
290
+ :return: A :class:`~oci.response.Response` object with data of type None
291
+ :rtype: :class:`~oci.response.Response`
292
+
293
+ :example:
294
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/change_agent_compartment.py.html>`__ to see an example of how to use change_agent_compartment API.
295
+ """
296
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
297
+ required_arguments = ['agentId']
298
+ resource_path = "/agents/{agentId}/actions/changeCompartment"
299
+ method = "POST"
300
+ operation_name = "change_agent_compartment"
301
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/ChangeAgentCompartment"
302
+
303
+ # Don't accept unknown kwargs
304
+ expected_kwargs = [
305
+ "allow_control_chars",
306
+ "retry_strategy",
307
+ "if_match",
308
+ "opc_request_id",
309
+ "opc_retry_token"
310
+ ]
311
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
312
+ if extra_kwargs:
313
+ raise ValueError(
314
+ f"change_agent_compartment got unknown kwargs: {extra_kwargs!r}")
315
+
316
+ path_params = {
317
+ "agentId": agent_id
318
+ }
319
+
320
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
321
+
322
+ for (k, v) in six.iteritems(path_params):
323
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
324
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
325
+
326
+ header_params = {
327
+ "accept": "application/json",
328
+ "content-type": "application/json",
329
+ "if-match": kwargs.get("if_match", missing),
330
+ "opc-request-id": kwargs.get("opc_request_id", missing),
331
+ "opc-retry-token": kwargs.get("opc_retry_token", missing)
332
+ }
333
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
334
+
335
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
336
+ operation_retry_strategy=kwargs.get('retry_strategy'),
337
+ client_retry_strategy=self.retry_strategy
338
+ )
339
+ if retry_strategy is None:
340
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
341
+
342
+ if retry_strategy:
343
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
344
+ self.base_client.add_opc_retry_token_if_needed(header_params)
345
+ self.base_client.add_opc_client_retries_header(header_params)
346
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
347
+ return retry_strategy.make_retrying_call(
348
+ self.base_client.call_api,
349
+ resource_path=resource_path,
350
+ method=method,
351
+ path_params=path_params,
352
+ header_params=header_params,
353
+ body=change_agent_compartment_details,
354
+ allow_control_chars=kwargs.get('allow_control_chars'),
355
+ operation_name=operation_name,
356
+ api_reference_link=api_reference_link,
357
+ required_arguments=required_arguments)
358
+ else:
359
+ return self.base_client.call_api(
360
+ resource_path=resource_path,
361
+ method=method,
362
+ path_params=path_params,
363
+ header_params=header_params,
364
+ body=change_agent_compartment_details,
365
+ allow_control_chars=kwargs.get('allow_control_chars'),
366
+ operation_name=operation_name,
367
+ api_reference_link=api_reference_link,
368
+ required_arguments=required_arguments)
369
+
370
+ def change_agent_endpoint_compartment(self, agent_endpoint_id, change_agent_endpoint_compartment_details, **kwargs):
371
+ """
372
+ **ChangeAgentEndpointCompartment**
373
+
374
+ Moves an endpoint into a different compartment within the same tenancy. For information about moving resources between
375
+ compartments, see `Moving Resources to a Different Compartment`__.
376
+
377
+ __ https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes
378
+
379
+
380
+ :param str agent_endpoint_id: (required)
381
+ The `OCID`__ of the endpoint.
382
+
383
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
384
+
385
+ :param oci.generative_ai_agent.models.ChangeAgentEndpointCompartmentDetails change_agent_endpoint_compartment_details: (required)
386
+ The information to be updated.
387
+
388
+ :param str if_match: (optional)
389
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
390
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
391
+ that resource. The resource will be updated or deleted only if the etag you provide
392
+ matches the resource's current etag value.
393
+
394
+ :param str opc_request_id: (optional)
395
+ Unique Oracle-assigned identifier for the request. If you need to contact
396
+ Oracle about a particular request, please provide the request ID.
397
+ The only valid characters for request IDs are letters, numbers,
398
+ underscore, and dash.
399
+
400
+ :param str opc_retry_token: (optional)
401
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
402
+ server error without risk of running that same action again. Retry tokens expire after 24
403
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
404
+ has been deleted and removed from the system, then a retry of the original creation request
405
+ might be rejected.
406
+
407
+ :param obj retry_strategy: (optional)
408
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
409
+
410
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
411
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
412
+
413
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
414
+
415
+ :param bool allow_control_chars: (optional)
416
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
417
+ By default, the response will not allow control characters in strings
418
+
419
+ :return: A :class:`~oci.response.Response` object with data of type None
420
+ :rtype: :class:`~oci.response.Response`
421
+
422
+ :example:
423
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/change_agent_endpoint_compartment.py.html>`__ to see an example of how to use change_agent_endpoint_compartment API.
424
+ """
425
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
426
+ required_arguments = ['agentEndpointId']
427
+ resource_path = "/agentEndpoints/{agentEndpointId}/actions/changeCompartment"
428
+ method = "POST"
429
+ operation_name = "change_agent_endpoint_compartment"
430
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/ChangeAgentEndpointCompartment"
431
+
432
+ # Don't accept unknown kwargs
433
+ expected_kwargs = [
434
+ "allow_control_chars",
435
+ "retry_strategy",
436
+ "if_match",
437
+ "opc_request_id",
438
+ "opc_retry_token"
439
+ ]
440
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
441
+ if extra_kwargs:
442
+ raise ValueError(
443
+ f"change_agent_endpoint_compartment got unknown kwargs: {extra_kwargs!r}")
444
+
445
+ path_params = {
446
+ "agentEndpointId": agent_endpoint_id
447
+ }
448
+
449
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
450
+
451
+ for (k, v) in six.iteritems(path_params):
452
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
453
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
454
+
455
+ header_params = {
456
+ "accept": "application/json",
457
+ "content-type": "application/json",
458
+ "if-match": kwargs.get("if_match", missing),
459
+ "opc-request-id": kwargs.get("opc_request_id", missing),
460
+ "opc-retry-token": kwargs.get("opc_retry_token", missing)
461
+ }
462
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
463
+
464
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
465
+ operation_retry_strategy=kwargs.get('retry_strategy'),
466
+ client_retry_strategy=self.retry_strategy
467
+ )
468
+ if retry_strategy is None:
469
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
470
+
471
+ if retry_strategy:
472
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
473
+ self.base_client.add_opc_retry_token_if_needed(header_params)
474
+ self.base_client.add_opc_client_retries_header(header_params)
475
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
476
+ return retry_strategy.make_retrying_call(
477
+ self.base_client.call_api,
478
+ resource_path=resource_path,
479
+ method=method,
480
+ path_params=path_params,
481
+ header_params=header_params,
482
+ body=change_agent_endpoint_compartment_details,
483
+ allow_control_chars=kwargs.get('allow_control_chars'),
484
+ operation_name=operation_name,
485
+ api_reference_link=api_reference_link,
486
+ required_arguments=required_arguments)
487
+ else:
488
+ return self.base_client.call_api(
489
+ resource_path=resource_path,
490
+ method=method,
491
+ path_params=path_params,
492
+ header_params=header_params,
493
+ body=change_agent_endpoint_compartment_details,
494
+ allow_control_chars=kwargs.get('allow_control_chars'),
495
+ operation_name=operation_name,
496
+ api_reference_link=api_reference_link,
497
+ required_arguments=required_arguments)
498
+
499
+ def change_knowledge_base_compartment(self, knowledge_base_id, change_knowledge_base_compartment_details, **kwargs):
500
+ """
501
+ **ChangeKnowledgeBaseCompartment**
502
+
503
+ Moves a knowledge base into a different compartment within the same tenancy. For information about moving resources between
504
+ compartments, see `Moving Resources to a Different Compartment`__.
505
+
506
+ __ https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes
507
+
508
+
509
+ :param str knowledge_base_id: (required)
510
+ The `OCID`__ of the knowledge base.
511
+
512
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
513
+
514
+ :param oci.generative_ai_agent.models.ChangeKnowledgeBaseCompartmentDetails change_knowledge_base_compartment_details: (required)
515
+ The information to be updated.
516
+
517
+ :param str if_match: (optional)
518
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
519
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
520
+ that resource. The resource will be updated or deleted only if the etag you provide
521
+ matches the resource's current etag value.
522
+
523
+ :param str opc_request_id: (optional)
524
+ Unique Oracle-assigned identifier for the request. If you need to contact
525
+ Oracle about a particular request, please provide the request ID.
526
+ The only valid characters for request IDs are letters, numbers,
527
+ underscore, and dash.
528
+
529
+ :param str opc_retry_token: (optional)
530
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
531
+ server error without risk of running that same action again. Retry tokens expire after 24
532
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
533
+ has been deleted and removed from the system, then a retry of the original creation request
534
+ might be rejected.
535
+
536
+ :param obj retry_strategy: (optional)
537
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
538
+
539
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
540
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
541
+
542
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
543
+
544
+ :param bool allow_control_chars: (optional)
545
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
546
+ By default, the response will not allow control characters in strings
547
+
548
+ :return: A :class:`~oci.response.Response` object with data of type None
549
+ :rtype: :class:`~oci.response.Response`
550
+
551
+ :example:
552
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/change_knowledge_base_compartment.py.html>`__ to see an example of how to use change_knowledge_base_compartment API.
553
+ """
554
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
555
+ required_arguments = ['knowledgeBaseId']
556
+ resource_path = "/knowledgeBases/{knowledgeBaseId}/actions/changeCompartment"
557
+ method = "POST"
558
+ operation_name = "change_knowledge_base_compartment"
559
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/ChangeKnowledgeBaseCompartment"
560
+
561
+ # Don't accept unknown kwargs
562
+ expected_kwargs = [
563
+ "allow_control_chars",
564
+ "retry_strategy",
565
+ "if_match",
566
+ "opc_request_id",
567
+ "opc_retry_token"
568
+ ]
569
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
570
+ if extra_kwargs:
571
+ raise ValueError(
572
+ f"change_knowledge_base_compartment got unknown kwargs: {extra_kwargs!r}")
573
+
574
+ path_params = {
575
+ "knowledgeBaseId": knowledge_base_id
576
+ }
577
+
578
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
579
+
580
+ for (k, v) in six.iteritems(path_params):
581
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
582
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
583
+
584
+ header_params = {
585
+ "accept": "application/json",
586
+ "content-type": "application/json",
587
+ "if-match": kwargs.get("if_match", missing),
588
+ "opc-request-id": kwargs.get("opc_request_id", missing),
589
+ "opc-retry-token": kwargs.get("opc_retry_token", missing)
590
+ }
591
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
592
+
593
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
594
+ operation_retry_strategy=kwargs.get('retry_strategy'),
595
+ client_retry_strategy=self.retry_strategy
596
+ )
597
+ if retry_strategy is None:
598
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
599
+
600
+ if retry_strategy:
601
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
602
+ self.base_client.add_opc_retry_token_if_needed(header_params)
603
+ self.base_client.add_opc_client_retries_header(header_params)
604
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
605
+ return retry_strategy.make_retrying_call(
606
+ self.base_client.call_api,
607
+ resource_path=resource_path,
608
+ method=method,
609
+ path_params=path_params,
610
+ header_params=header_params,
611
+ body=change_knowledge_base_compartment_details,
612
+ allow_control_chars=kwargs.get('allow_control_chars'),
613
+ operation_name=operation_name,
614
+ api_reference_link=api_reference_link,
615
+ required_arguments=required_arguments)
616
+ else:
617
+ return self.base_client.call_api(
618
+ resource_path=resource_path,
619
+ method=method,
620
+ path_params=path_params,
621
+ header_params=header_params,
622
+ body=change_knowledge_base_compartment_details,
623
+ allow_control_chars=kwargs.get('allow_control_chars'),
624
+ operation_name=operation_name,
625
+ api_reference_link=api_reference_link,
626
+ required_arguments=required_arguments)
627
+
628
+ def create_agent(self, create_agent_details, **kwargs):
629
+ """
630
+ **CreateAgent**
631
+
632
+ Creates an agent.
633
+
634
+
635
+ :param oci.generative_ai_agent.models.CreateAgentDetails create_agent_details: (required)
636
+ Details for the new agent.
637
+
638
+ :param str opc_retry_token: (optional)
639
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
640
+ server error without risk of running that same action again. Retry tokens expire after 24
641
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
642
+ has been deleted and removed from the system, then a retry of the original creation request
643
+ might be rejected.
644
+
645
+ :param str opc_request_id: (optional)
646
+ Unique Oracle-assigned identifier for the request. If you need to contact
647
+ Oracle about a particular request, please provide the request ID.
648
+ The only valid characters for request IDs are letters, numbers,
649
+ underscore, and dash.
650
+
651
+ :param obj retry_strategy: (optional)
652
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
653
+
654
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
655
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
656
+
657
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
658
+
659
+ :param bool allow_control_chars: (optional)
660
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
661
+ By default, the response will not allow control characters in strings
662
+
663
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.Agent`
664
+ :rtype: :class:`~oci.response.Response`
665
+
666
+ :example:
667
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/create_agent.py.html>`__ to see an example of how to use create_agent API.
668
+ """
669
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
670
+ required_arguments = []
671
+ resource_path = "/agents"
672
+ method = "POST"
673
+ operation_name = "create_agent"
674
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/CreateAgent"
675
+
676
+ # Don't accept unknown kwargs
677
+ expected_kwargs = [
678
+ "allow_control_chars",
679
+ "retry_strategy",
680
+ "opc_retry_token",
681
+ "opc_request_id"
682
+ ]
683
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
684
+ if extra_kwargs:
685
+ raise ValueError(
686
+ f"create_agent got unknown kwargs: {extra_kwargs!r}")
687
+
688
+ header_params = {
689
+ "accept": "application/json",
690
+ "content-type": "application/json",
691
+ "opc-retry-token": kwargs.get("opc_retry_token", missing),
692
+ "opc-request-id": kwargs.get("opc_request_id", missing)
693
+ }
694
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
695
+
696
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
697
+ operation_retry_strategy=kwargs.get('retry_strategy'),
698
+ client_retry_strategy=self.retry_strategy
699
+ )
700
+ if retry_strategy is None:
701
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
702
+
703
+ if retry_strategy:
704
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
705
+ self.base_client.add_opc_retry_token_if_needed(header_params)
706
+ self.base_client.add_opc_client_retries_header(header_params)
707
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
708
+ return retry_strategy.make_retrying_call(
709
+ self.base_client.call_api,
710
+ resource_path=resource_path,
711
+ method=method,
712
+ header_params=header_params,
713
+ body=create_agent_details,
714
+ response_type="Agent",
715
+ allow_control_chars=kwargs.get('allow_control_chars'),
716
+ operation_name=operation_name,
717
+ api_reference_link=api_reference_link,
718
+ required_arguments=required_arguments)
719
+ else:
720
+ return self.base_client.call_api(
721
+ resource_path=resource_path,
722
+ method=method,
723
+ header_params=header_params,
724
+ body=create_agent_details,
725
+ response_type="Agent",
726
+ allow_control_chars=kwargs.get('allow_control_chars'),
727
+ operation_name=operation_name,
728
+ api_reference_link=api_reference_link,
729
+ required_arguments=required_arguments)
730
+
731
+ def create_agent_endpoint(self, create_agent_endpoint_details, **kwargs):
732
+ """
733
+ **CreateAgentEndpoint**
734
+
735
+ Creates an endpoint.
736
+
737
+
738
+ :param oci.generative_ai_agent.models.CreateAgentEndpointDetails create_agent_endpoint_details: (required)
739
+ Details for the new endpoint.
740
+
741
+ :param str opc_retry_token: (optional)
742
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
743
+ server error without risk of running that same action again. Retry tokens expire after 24
744
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
745
+ has been deleted and removed from the system, then a retry of the original creation request
746
+ might be rejected.
747
+
748
+ :param str opc_request_id: (optional)
749
+ Unique Oracle-assigned identifier for the request. If you need to contact
750
+ Oracle about a particular request, please provide the request ID.
751
+ The only valid characters for request IDs are letters, numbers,
752
+ underscore, and dash.
753
+
754
+ :param obj retry_strategy: (optional)
755
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
756
+
757
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
758
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
759
+
760
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
761
+
762
+ :param bool allow_control_chars: (optional)
763
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
764
+ By default, the response will not allow control characters in strings
765
+
766
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.AgentEndpoint`
767
+ :rtype: :class:`~oci.response.Response`
768
+
769
+ :example:
770
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/create_agent_endpoint.py.html>`__ to see an example of how to use create_agent_endpoint API.
771
+ """
772
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
773
+ required_arguments = []
774
+ resource_path = "/agentEndpoints"
775
+ method = "POST"
776
+ operation_name = "create_agent_endpoint"
777
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/CreateAgentEndpoint"
778
+
779
+ # Don't accept unknown kwargs
780
+ expected_kwargs = [
781
+ "allow_control_chars",
782
+ "retry_strategy",
783
+ "opc_retry_token",
784
+ "opc_request_id"
785
+ ]
786
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
787
+ if extra_kwargs:
788
+ raise ValueError(
789
+ f"create_agent_endpoint got unknown kwargs: {extra_kwargs!r}")
790
+
791
+ header_params = {
792
+ "accept": "application/json",
793
+ "content-type": "application/json",
794
+ "opc-retry-token": kwargs.get("opc_retry_token", missing),
795
+ "opc-request-id": kwargs.get("opc_request_id", missing)
796
+ }
797
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
798
+
799
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
800
+ operation_retry_strategy=kwargs.get('retry_strategy'),
801
+ client_retry_strategy=self.retry_strategy
802
+ )
803
+ if retry_strategy is None:
804
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
805
+
806
+ if retry_strategy:
807
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
808
+ self.base_client.add_opc_retry_token_if_needed(header_params)
809
+ self.base_client.add_opc_client_retries_header(header_params)
810
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
811
+ return retry_strategy.make_retrying_call(
812
+ self.base_client.call_api,
813
+ resource_path=resource_path,
814
+ method=method,
815
+ header_params=header_params,
816
+ body=create_agent_endpoint_details,
817
+ response_type="AgentEndpoint",
818
+ allow_control_chars=kwargs.get('allow_control_chars'),
819
+ operation_name=operation_name,
820
+ api_reference_link=api_reference_link,
821
+ required_arguments=required_arguments)
822
+ else:
823
+ return self.base_client.call_api(
824
+ resource_path=resource_path,
825
+ method=method,
826
+ header_params=header_params,
827
+ body=create_agent_endpoint_details,
828
+ response_type="AgentEndpoint",
829
+ allow_control_chars=kwargs.get('allow_control_chars'),
830
+ operation_name=operation_name,
831
+ api_reference_link=api_reference_link,
832
+ required_arguments=required_arguments)
833
+
834
+ def create_data_ingestion_job(self, create_data_ingestion_job_details, **kwargs):
835
+ """
836
+ **CreateDataIngestionJob**
837
+
838
+ Creates a data ingestion job.
839
+
840
+
841
+ :param oci.generative_ai_agent.models.CreateDataIngestionJobDetails create_data_ingestion_job_details: (required)
842
+ Details for the new data ingestion job.
843
+
844
+ :param str opc_retry_token: (optional)
845
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
846
+ server error without risk of running that same action again. Retry tokens expire after 24
847
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
848
+ has been deleted and removed from the system, then a retry of the original creation request
849
+ might be rejected.
850
+
851
+ :param str opc_request_id: (optional)
852
+ Unique Oracle-assigned identifier for the request. If you need to contact
853
+ Oracle about a particular request, please provide the request ID.
854
+ The only valid characters for request IDs are letters, numbers,
855
+ underscore, and dash.
856
+
857
+ :param obj retry_strategy: (optional)
858
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
859
+
860
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
861
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
862
+
863
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
864
+
865
+ :param bool allow_control_chars: (optional)
866
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
867
+ By default, the response will not allow control characters in strings
868
+
869
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataIngestionJob`
870
+ :rtype: :class:`~oci.response.Response`
871
+
872
+ :example:
873
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/create_data_ingestion_job.py.html>`__ to see an example of how to use create_data_ingestion_job API.
874
+ """
875
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
876
+ required_arguments = []
877
+ resource_path = "/dataIngestionJobs"
878
+ method = "POST"
879
+ operation_name = "create_data_ingestion_job"
880
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataIngestionJob/CreateDataIngestionJob"
881
+
882
+ # Don't accept unknown kwargs
883
+ expected_kwargs = [
884
+ "allow_control_chars",
885
+ "retry_strategy",
886
+ "opc_retry_token",
887
+ "opc_request_id"
888
+ ]
889
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
890
+ if extra_kwargs:
891
+ raise ValueError(
892
+ f"create_data_ingestion_job got unknown kwargs: {extra_kwargs!r}")
893
+
894
+ header_params = {
895
+ "accept": "application/json",
896
+ "content-type": "application/json",
897
+ "opc-retry-token": kwargs.get("opc_retry_token", missing),
898
+ "opc-request-id": kwargs.get("opc_request_id", missing)
899
+ }
900
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
901
+
902
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
903
+ operation_retry_strategy=kwargs.get('retry_strategy'),
904
+ client_retry_strategy=self.retry_strategy
905
+ )
906
+ if retry_strategy is None:
907
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
908
+
909
+ if retry_strategy:
910
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
911
+ self.base_client.add_opc_retry_token_if_needed(header_params)
912
+ self.base_client.add_opc_client_retries_header(header_params)
913
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
914
+ return retry_strategy.make_retrying_call(
915
+ self.base_client.call_api,
916
+ resource_path=resource_path,
917
+ method=method,
918
+ header_params=header_params,
919
+ body=create_data_ingestion_job_details,
920
+ response_type="DataIngestionJob",
921
+ allow_control_chars=kwargs.get('allow_control_chars'),
922
+ operation_name=operation_name,
923
+ api_reference_link=api_reference_link,
924
+ required_arguments=required_arguments)
925
+ else:
926
+ return self.base_client.call_api(
927
+ resource_path=resource_path,
928
+ method=method,
929
+ header_params=header_params,
930
+ body=create_data_ingestion_job_details,
931
+ response_type="DataIngestionJob",
932
+ allow_control_chars=kwargs.get('allow_control_chars'),
933
+ operation_name=operation_name,
934
+ api_reference_link=api_reference_link,
935
+ required_arguments=required_arguments)
936
+
937
+ def create_data_source(self, create_data_source_details, **kwargs):
938
+ """
939
+ **CreateDataSource**
940
+
941
+ Creates a data source.
942
+
943
+
944
+ :param oci.generative_ai_agent.models.CreateDataSourceDetails create_data_source_details: (required)
945
+ Details for the new data source.
946
+
947
+ :param str opc_retry_token: (optional)
948
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
949
+ server error without risk of running that same action again. Retry tokens expire after 24
950
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
951
+ has been deleted and removed from the system, then a retry of the original creation request
952
+ might be rejected.
953
+
954
+ :param str opc_request_id: (optional)
955
+ Unique Oracle-assigned identifier for the request. If you need to contact
956
+ Oracle about a particular request, please provide the request ID.
957
+ The only valid characters for request IDs are letters, numbers,
958
+ underscore, and dash.
959
+
960
+ :param obj retry_strategy: (optional)
961
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
962
+
963
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
964
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
965
+
966
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
967
+
968
+ :param bool allow_control_chars: (optional)
969
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
970
+ By default, the response will not allow control characters in strings
971
+
972
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataSource`
973
+ :rtype: :class:`~oci.response.Response`
974
+
975
+ :example:
976
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/create_data_source.py.html>`__ to see an example of how to use create_data_source API.
977
+ """
978
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
979
+ required_arguments = []
980
+ resource_path = "/dataSources"
981
+ method = "POST"
982
+ operation_name = "create_data_source"
983
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataSource/CreateDataSource"
984
+
985
+ # Don't accept unknown kwargs
986
+ expected_kwargs = [
987
+ "allow_control_chars",
988
+ "retry_strategy",
989
+ "opc_retry_token",
990
+ "opc_request_id"
991
+ ]
992
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
993
+ if extra_kwargs:
994
+ raise ValueError(
995
+ f"create_data_source got unknown kwargs: {extra_kwargs!r}")
996
+
997
+ header_params = {
998
+ "accept": "application/json",
999
+ "content-type": "application/json",
1000
+ "opc-retry-token": kwargs.get("opc_retry_token", missing),
1001
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1002
+ }
1003
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1004
+
1005
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1006
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1007
+ client_retry_strategy=self.retry_strategy
1008
+ )
1009
+ if retry_strategy is None:
1010
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1011
+
1012
+ if retry_strategy:
1013
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1014
+ self.base_client.add_opc_retry_token_if_needed(header_params)
1015
+ self.base_client.add_opc_client_retries_header(header_params)
1016
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1017
+ return retry_strategy.make_retrying_call(
1018
+ self.base_client.call_api,
1019
+ resource_path=resource_path,
1020
+ method=method,
1021
+ header_params=header_params,
1022
+ body=create_data_source_details,
1023
+ response_type="DataSource",
1024
+ allow_control_chars=kwargs.get('allow_control_chars'),
1025
+ operation_name=operation_name,
1026
+ api_reference_link=api_reference_link,
1027
+ required_arguments=required_arguments)
1028
+ else:
1029
+ return self.base_client.call_api(
1030
+ resource_path=resource_path,
1031
+ method=method,
1032
+ header_params=header_params,
1033
+ body=create_data_source_details,
1034
+ response_type="DataSource",
1035
+ allow_control_chars=kwargs.get('allow_control_chars'),
1036
+ operation_name=operation_name,
1037
+ api_reference_link=api_reference_link,
1038
+ required_arguments=required_arguments)
1039
+
1040
+ def create_knowledge_base(self, create_knowledge_base_details, **kwargs):
1041
+ """
1042
+ **CreateKnowledgeBase**
1043
+
1044
+ Creates a knowledge base.
1045
+
1046
+
1047
+ :param oci.generative_ai_agent.models.CreateKnowledgeBaseDetails create_knowledge_base_details: (required)
1048
+ Details for the new knowledge base.
1049
+
1050
+ :param str opc_retry_token: (optional)
1051
+ A token that uniquely identifies a request so it can be retried in case of a timeout or
1052
+ server error without risk of running that same action again. Retry tokens expire after 24
1053
+ hours, but can be invalidated before then due to conflicting operations. For example, if a resource
1054
+ has been deleted and removed from the system, then a retry of the original creation request
1055
+ might be rejected.
1056
+
1057
+ :param str opc_request_id: (optional)
1058
+ Unique Oracle-assigned identifier for the request. If you need to contact
1059
+ Oracle about a particular request, please provide the request ID.
1060
+ The only valid characters for request IDs are letters, numbers,
1061
+ underscore, and dash.
1062
+
1063
+ :param obj retry_strategy: (optional)
1064
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1065
+
1066
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1067
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1068
+
1069
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1070
+
1071
+ :param bool allow_control_chars: (optional)
1072
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1073
+ By default, the response will not allow control characters in strings
1074
+
1075
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.KnowledgeBase`
1076
+ :rtype: :class:`~oci.response.Response`
1077
+
1078
+ :example:
1079
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/create_knowledge_base.py.html>`__ to see an example of how to use create_knowledge_base API.
1080
+ """
1081
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1082
+ required_arguments = []
1083
+ resource_path = "/knowledgeBases"
1084
+ method = "POST"
1085
+ operation_name = "create_knowledge_base"
1086
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/CreateKnowledgeBase"
1087
+
1088
+ # Don't accept unknown kwargs
1089
+ expected_kwargs = [
1090
+ "allow_control_chars",
1091
+ "retry_strategy",
1092
+ "opc_retry_token",
1093
+ "opc_request_id"
1094
+ ]
1095
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1096
+ if extra_kwargs:
1097
+ raise ValueError(
1098
+ f"create_knowledge_base got unknown kwargs: {extra_kwargs!r}")
1099
+
1100
+ header_params = {
1101
+ "accept": "application/json",
1102
+ "content-type": "application/json",
1103
+ "opc-retry-token": kwargs.get("opc_retry_token", missing),
1104
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1105
+ }
1106
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1107
+
1108
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1109
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1110
+ client_retry_strategy=self.retry_strategy
1111
+ )
1112
+ if retry_strategy is None:
1113
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1114
+
1115
+ if retry_strategy:
1116
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1117
+ self.base_client.add_opc_retry_token_if_needed(header_params)
1118
+ self.base_client.add_opc_client_retries_header(header_params)
1119
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1120
+ return retry_strategy.make_retrying_call(
1121
+ self.base_client.call_api,
1122
+ resource_path=resource_path,
1123
+ method=method,
1124
+ header_params=header_params,
1125
+ body=create_knowledge_base_details,
1126
+ response_type="KnowledgeBase",
1127
+ allow_control_chars=kwargs.get('allow_control_chars'),
1128
+ operation_name=operation_name,
1129
+ api_reference_link=api_reference_link,
1130
+ required_arguments=required_arguments)
1131
+ else:
1132
+ return self.base_client.call_api(
1133
+ resource_path=resource_path,
1134
+ method=method,
1135
+ header_params=header_params,
1136
+ body=create_knowledge_base_details,
1137
+ response_type="KnowledgeBase",
1138
+ allow_control_chars=kwargs.get('allow_control_chars'),
1139
+ operation_name=operation_name,
1140
+ api_reference_link=api_reference_link,
1141
+ required_arguments=required_arguments)
1142
+
1143
+ def delete_agent(self, agent_id, **kwargs):
1144
+ """
1145
+ **DeleteAgent**
1146
+
1147
+ Deletes an agent.
1148
+
1149
+
1150
+ :param str agent_id: (required)
1151
+ The `OCID`__ of the agent.
1152
+
1153
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1154
+
1155
+ :param str if_match: (optional)
1156
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
1157
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
1158
+ that resource. The resource will be updated or deleted only if the etag you provide
1159
+ matches the resource's current etag value.
1160
+
1161
+ :param str opc_request_id: (optional)
1162
+ Unique Oracle-assigned identifier for the request. If you need to contact
1163
+ Oracle about a particular request, please provide the request ID.
1164
+ The only valid characters for request IDs are letters, numbers,
1165
+ underscore, and dash.
1166
+
1167
+ :param obj retry_strategy: (optional)
1168
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1169
+
1170
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1171
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1172
+
1173
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1174
+
1175
+ :param bool allow_control_chars: (optional)
1176
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1177
+ By default, the response will not allow control characters in strings
1178
+
1179
+ :return: A :class:`~oci.response.Response` object with data of type None
1180
+ :rtype: :class:`~oci.response.Response`
1181
+
1182
+ :example:
1183
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/delete_agent.py.html>`__ to see an example of how to use delete_agent API.
1184
+ """
1185
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1186
+ required_arguments = ['agentId']
1187
+ resource_path = "/agents/{agentId}"
1188
+ method = "DELETE"
1189
+ operation_name = "delete_agent"
1190
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/DeleteAgent"
1191
+
1192
+ # Don't accept unknown kwargs
1193
+ expected_kwargs = [
1194
+ "allow_control_chars",
1195
+ "retry_strategy",
1196
+ "if_match",
1197
+ "opc_request_id"
1198
+ ]
1199
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1200
+ if extra_kwargs:
1201
+ raise ValueError(
1202
+ f"delete_agent got unknown kwargs: {extra_kwargs!r}")
1203
+
1204
+ path_params = {
1205
+ "agentId": agent_id
1206
+ }
1207
+
1208
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1209
+
1210
+ for (k, v) in six.iteritems(path_params):
1211
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1212
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1213
+
1214
+ header_params = {
1215
+ "accept": "application/json",
1216
+ "content-type": "application/json",
1217
+ "if-match": kwargs.get("if_match", missing),
1218
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1219
+ }
1220
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1221
+
1222
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1223
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1224
+ client_retry_strategy=self.retry_strategy
1225
+ )
1226
+ if retry_strategy is None:
1227
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1228
+
1229
+ if retry_strategy:
1230
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1231
+ self.base_client.add_opc_client_retries_header(header_params)
1232
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1233
+ return retry_strategy.make_retrying_call(
1234
+ self.base_client.call_api,
1235
+ resource_path=resource_path,
1236
+ method=method,
1237
+ path_params=path_params,
1238
+ header_params=header_params,
1239
+ allow_control_chars=kwargs.get('allow_control_chars'),
1240
+ operation_name=operation_name,
1241
+ api_reference_link=api_reference_link,
1242
+ required_arguments=required_arguments)
1243
+ else:
1244
+ return self.base_client.call_api(
1245
+ resource_path=resource_path,
1246
+ method=method,
1247
+ path_params=path_params,
1248
+ header_params=header_params,
1249
+ allow_control_chars=kwargs.get('allow_control_chars'),
1250
+ operation_name=operation_name,
1251
+ api_reference_link=api_reference_link,
1252
+ required_arguments=required_arguments)
1253
+
1254
+ def delete_agent_endpoint(self, agent_endpoint_id, **kwargs):
1255
+ """
1256
+ **DeleteAgentEndpoint**
1257
+
1258
+ Deletes an endpoint.
1259
+
1260
+
1261
+ :param str agent_endpoint_id: (required)
1262
+ The `OCID`__ of the endpoint.
1263
+
1264
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1265
+
1266
+ :param str if_match: (optional)
1267
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
1268
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
1269
+ that resource. The resource will be updated or deleted only if the etag you provide
1270
+ matches the resource's current etag value.
1271
+
1272
+ :param str opc_request_id: (optional)
1273
+ Unique Oracle-assigned identifier for the request. If you need to contact
1274
+ Oracle about a particular request, please provide the request ID.
1275
+ The only valid characters for request IDs are letters, numbers,
1276
+ underscore, and dash.
1277
+
1278
+ :param obj retry_strategy: (optional)
1279
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1280
+
1281
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1282
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1283
+
1284
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1285
+
1286
+ :param bool allow_control_chars: (optional)
1287
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1288
+ By default, the response will not allow control characters in strings
1289
+
1290
+ :return: A :class:`~oci.response.Response` object with data of type None
1291
+ :rtype: :class:`~oci.response.Response`
1292
+
1293
+ :example:
1294
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/delete_agent_endpoint.py.html>`__ to see an example of how to use delete_agent_endpoint API.
1295
+ """
1296
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1297
+ required_arguments = ['agentEndpointId']
1298
+ resource_path = "/agentEndpoints/{agentEndpointId}"
1299
+ method = "DELETE"
1300
+ operation_name = "delete_agent_endpoint"
1301
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/DeleteAgentEndpoint"
1302
+
1303
+ # Don't accept unknown kwargs
1304
+ expected_kwargs = [
1305
+ "allow_control_chars",
1306
+ "retry_strategy",
1307
+ "if_match",
1308
+ "opc_request_id"
1309
+ ]
1310
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1311
+ if extra_kwargs:
1312
+ raise ValueError(
1313
+ f"delete_agent_endpoint got unknown kwargs: {extra_kwargs!r}")
1314
+
1315
+ path_params = {
1316
+ "agentEndpointId": agent_endpoint_id
1317
+ }
1318
+
1319
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1320
+
1321
+ for (k, v) in six.iteritems(path_params):
1322
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1323
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1324
+
1325
+ header_params = {
1326
+ "accept": "application/json",
1327
+ "content-type": "application/json",
1328
+ "if-match": kwargs.get("if_match", missing),
1329
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1330
+ }
1331
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1332
+
1333
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1334
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1335
+ client_retry_strategy=self.retry_strategy
1336
+ )
1337
+ if retry_strategy is None:
1338
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1339
+
1340
+ if retry_strategy:
1341
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1342
+ self.base_client.add_opc_client_retries_header(header_params)
1343
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1344
+ return retry_strategy.make_retrying_call(
1345
+ self.base_client.call_api,
1346
+ resource_path=resource_path,
1347
+ method=method,
1348
+ path_params=path_params,
1349
+ header_params=header_params,
1350
+ allow_control_chars=kwargs.get('allow_control_chars'),
1351
+ operation_name=operation_name,
1352
+ api_reference_link=api_reference_link,
1353
+ required_arguments=required_arguments)
1354
+ else:
1355
+ return self.base_client.call_api(
1356
+ resource_path=resource_path,
1357
+ method=method,
1358
+ path_params=path_params,
1359
+ header_params=header_params,
1360
+ allow_control_chars=kwargs.get('allow_control_chars'),
1361
+ operation_name=operation_name,
1362
+ api_reference_link=api_reference_link,
1363
+ required_arguments=required_arguments)
1364
+
1365
+ def delete_data_ingestion_job(self, data_ingestion_job_id, **kwargs):
1366
+ """
1367
+ **DeleteDataIngestionJob**
1368
+
1369
+ Deletes a data ingestion job.
1370
+
1371
+
1372
+ :param str data_ingestion_job_id: (required)
1373
+ The `OCID`__ of the data ingestion job.
1374
+
1375
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1376
+
1377
+ :param str if_match: (optional)
1378
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
1379
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
1380
+ that resource. The resource will be updated or deleted only if the etag you provide
1381
+ matches the resource's current etag value.
1382
+
1383
+ :param str opc_request_id: (optional)
1384
+ Unique Oracle-assigned identifier for the request. If you need to contact
1385
+ Oracle about a particular request, please provide the request ID.
1386
+ The only valid characters for request IDs are letters, numbers,
1387
+ underscore, and dash.
1388
+
1389
+ :param obj retry_strategy: (optional)
1390
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1391
+
1392
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1393
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1394
+
1395
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1396
+
1397
+ :param bool allow_control_chars: (optional)
1398
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1399
+ By default, the response will not allow control characters in strings
1400
+
1401
+ :return: A :class:`~oci.response.Response` object with data of type None
1402
+ :rtype: :class:`~oci.response.Response`
1403
+
1404
+ :example:
1405
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/delete_data_ingestion_job.py.html>`__ to see an example of how to use delete_data_ingestion_job API.
1406
+ """
1407
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1408
+ required_arguments = ['dataIngestionJobId']
1409
+ resource_path = "/dataIngestionJobs/{dataIngestionJobId}"
1410
+ method = "DELETE"
1411
+ operation_name = "delete_data_ingestion_job"
1412
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataIngestionJob/DeleteDataIngestionJob"
1413
+
1414
+ # Don't accept unknown kwargs
1415
+ expected_kwargs = [
1416
+ "allow_control_chars",
1417
+ "retry_strategy",
1418
+ "if_match",
1419
+ "opc_request_id"
1420
+ ]
1421
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1422
+ if extra_kwargs:
1423
+ raise ValueError(
1424
+ f"delete_data_ingestion_job got unknown kwargs: {extra_kwargs!r}")
1425
+
1426
+ path_params = {
1427
+ "dataIngestionJobId": data_ingestion_job_id
1428
+ }
1429
+
1430
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1431
+
1432
+ for (k, v) in six.iteritems(path_params):
1433
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1434
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1435
+
1436
+ header_params = {
1437
+ "accept": "application/json",
1438
+ "content-type": "application/json",
1439
+ "if-match": kwargs.get("if_match", missing),
1440
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1441
+ }
1442
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1443
+
1444
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1445
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1446
+ client_retry_strategy=self.retry_strategy
1447
+ )
1448
+ if retry_strategy is None:
1449
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1450
+
1451
+ if retry_strategy:
1452
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1453
+ self.base_client.add_opc_client_retries_header(header_params)
1454
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1455
+ return retry_strategy.make_retrying_call(
1456
+ self.base_client.call_api,
1457
+ resource_path=resource_path,
1458
+ method=method,
1459
+ path_params=path_params,
1460
+ header_params=header_params,
1461
+ allow_control_chars=kwargs.get('allow_control_chars'),
1462
+ operation_name=operation_name,
1463
+ api_reference_link=api_reference_link,
1464
+ required_arguments=required_arguments)
1465
+ else:
1466
+ return self.base_client.call_api(
1467
+ resource_path=resource_path,
1468
+ method=method,
1469
+ path_params=path_params,
1470
+ header_params=header_params,
1471
+ allow_control_chars=kwargs.get('allow_control_chars'),
1472
+ operation_name=operation_name,
1473
+ api_reference_link=api_reference_link,
1474
+ required_arguments=required_arguments)
1475
+
1476
+ def delete_data_source(self, data_source_id, **kwargs):
1477
+ """
1478
+ **DeleteDataSource**
1479
+
1480
+ Deletes a data source.
1481
+
1482
+
1483
+ :param str data_source_id: (required)
1484
+ The `OCID`__ of the data source.
1485
+
1486
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1487
+
1488
+ :param str if_match: (optional)
1489
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
1490
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
1491
+ that resource. The resource will be updated or deleted only if the etag you provide
1492
+ matches the resource's current etag value.
1493
+
1494
+ :param str opc_request_id: (optional)
1495
+ Unique Oracle-assigned identifier for the request. If you need to contact
1496
+ Oracle about a particular request, please provide the request ID.
1497
+ The only valid characters for request IDs are letters, numbers,
1498
+ underscore, and dash.
1499
+
1500
+ :param obj retry_strategy: (optional)
1501
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1502
+
1503
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1504
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1505
+
1506
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1507
+
1508
+ :param bool allow_control_chars: (optional)
1509
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1510
+ By default, the response will not allow control characters in strings
1511
+
1512
+ :return: A :class:`~oci.response.Response` object with data of type None
1513
+ :rtype: :class:`~oci.response.Response`
1514
+
1515
+ :example:
1516
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/delete_data_source.py.html>`__ to see an example of how to use delete_data_source API.
1517
+ """
1518
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1519
+ required_arguments = ['dataSourceId']
1520
+ resource_path = "/dataSources/{dataSourceId}"
1521
+ method = "DELETE"
1522
+ operation_name = "delete_data_source"
1523
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataSource/DeleteDataSource"
1524
+
1525
+ # Don't accept unknown kwargs
1526
+ expected_kwargs = [
1527
+ "allow_control_chars",
1528
+ "retry_strategy",
1529
+ "if_match",
1530
+ "opc_request_id"
1531
+ ]
1532
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1533
+ if extra_kwargs:
1534
+ raise ValueError(
1535
+ f"delete_data_source got unknown kwargs: {extra_kwargs!r}")
1536
+
1537
+ path_params = {
1538
+ "dataSourceId": data_source_id
1539
+ }
1540
+
1541
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1542
+
1543
+ for (k, v) in six.iteritems(path_params):
1544
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1545
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1546
+
1547
+ header_params = {
1548
+ "accept": "application/json",
1549
+ "content-type": "application/json",
1550
+ "if-match": kwargs.get("if_match", missing),
1551
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1552
+ }
1553
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1554
+
1555
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1556
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1557
+ client_retry_strategy=self.retry_strategy
1558
+ )
1559
+ if retry_strategy is None:
1560
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1561
+
1562
+ if retry_strategy:
1563
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1564
+ self.base_client.add_opc_client_retries_header(header_params)
1565
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1566
+ return retry_strategy.make_retrying_call(
1567
+ self.base_client.call_api,
1568
+ resource_path=resource_path,
1569
+ method=method,
1570
+ path_params=path_params,
1571
+ header_params=header_params,
1572
+ allow_control_chars=kwargs.get('allow_control_chars'),
1573
+ operation_name=operation_name,
1574
+ api_reference_link=api_reference_link,
1575
+ required_arguments=required_arguments)
1576
+ else:
1577
+ return self.base_client.call_api(
1578
+ resource_path=resource_path,
1579
+ method=method,
1580
+ path_params=path_params,
1581
+ header_params=header_params,
1582
+ allow_control_chars=kwargs.get('allow_control_chars'),
1583
+ operation_name=operation_name,
1584
+ api_reference_link=api_reference_link,
1585
+ required_arguments=required_arguments)
1586
+
1587
+ def delete_knowledge_base(self, knowledge_base_id, **kwargs):
1588
+ """
1589
+ **DeleteKnowledgeBase**
1590
+
1591
+ Deletes a knowledge base.
1592
+
1593
+
1594
+ :param str knowledge_base_id: (required)
1595
+ The `OCID`__ of the knowledge base.
1596
+
1597
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1598
+
1599
+ :param str if_match: (optional)
1600
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
1601
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
1602
+ that resource. The resource will be updated or deleted only if the etag you provide
1603
+ matches the resource's current etag value.
1604
+
1605
+ :param str opc_request_id: (optional)
1606
+ Unique Oracle-assigned identifier for the request. If you need to contact
1607
+ Oracle about a particular request, please provide the request ID.
1608
+ The only valid characters for request IDs are letters, numbers,
1609
+ underscore, and dash.
1610
+
1611
+ :param obj retry_strategy: (optional)
1612
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1613
+
1614
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1615
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1616
+
1617
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1618
+
1619
+ :param bool allow_control_chars: (optional)
1620
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1621
+ By default, the response will not allow control characters in strings
1622
+
1623
+ :return: A :class:`~oci.response.Response` object with data of type None
1624
+ :rtype: :class:`~oci.response.Response`
1625
+
1626
+ :example:
1627
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/delete_knowledge_base.py.html>`__ to see an example of how to use delete_knowledge_base API.
1628
+ """
1629
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1630
+ required_arguments = ['knowledgeBaseId']
1631
+ resource_path = "/knowledgeBases/{knowledgeBaseId}"
1632
+ method = "DELETE"
1633
+ operation_name = "delete_knowledge_base"
1634
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/DeleteKnowledgeBase"
1635
+
1636
+ # Don't accept unknown kwargs
1637
+ expected_kwargs = [
1638
+ "allow_control_chars",
1639
+ "retry_strategy",
1640
+ "if_match",
1641
+ "opc_request_id"
1642
+ ]
1643
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1644
+ if extra_kwargs:
1645
+ raise ValueError(
1646
+ f"delete_knowledge_base got unknown kwargs: {extra_kwargs!r}")
1647
+
1648
+ path_params = {
1649
+ "knowledgeBaseId": knowledge_base_id
1650
+ }
1651
+
1652
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1653
+
1654
+ for (k, v) in six.iteritems(path_params):
1655
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1656
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1657
+
1658
+ header_params = {
1659
+ "accept": "application/json",
1660
+ "content-type": "application/json",
1661
+ "if-match": kwargs.get("if_match", missing),
1662
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1663
+ }
1664
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1665
+
1666
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1667
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1668
+ client_retry_strategy=self.retry_strategy
1669
+ )
1670
+ if retry_strategy is None:
1671
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1672
+
1673
+ if retry_strategy:
1674
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1675
+ self.base_client.add_opc_client_retries_header(header_params)
1676
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1677
+ return retry_strategy.make_retrying_call(
1678
+ self.base_client.call_api,
1679
+ resource_path=resource_path,
1680
+ method=method,
1681
+ path_params=path_params,
1682
+ header_params=header_params,
1683
+ allow_control_chars=kwargs.get('allow_control_chars'),
1684
+ operation_name=operation_name,
1685
+ api_reference_link=api_reference_link,
1686
+ required_arguments=required_arguments)
1687
+ else:
1688
+ return self.base_client.call_api(
1689
+ resource_path=resource_path,
1690
+ method=method,
1691
+ path_params=path_params,
1692
+ header_params=header_params,
1693
+ allow_control_chars=kwargs.get('allow_control_chars'),
1694
+ operation_name=operation_name,
1695
+ api_reference_link=api_reference_link,
1696
+ required_arguments=required_arguments)
1697
+
1698
+ def get_agent(self, agent_id, **kwargs):
1699
+ """
1700
+ **GetAgent**
1701
+
1702
+ Gets information about an agent.
1703
+
1704
+
1705
+ :param str agent_id: (required)
1706
+ The `OCID`__ of the agent.
1707
+
1708
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1709
+
1710
+ :param str opc_request_id: (optional)
1711
+ Unique Oracle-assigned identifier for the request. If you need to contact
1712
+ Oracle about a particular request, please provide the request ID.
1713
+ The only valid characters for request IDs are letters, numbers,
1714
+ underscore, and dash.
1715
+
1716
+ :param obj retry_strategy: (optional)
1717
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1718
+
1719
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1720
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1721
+
1722
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1723
+
1724
+ :param bool allow_control_chars: (optional)
1725
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1726
+ By default, the response will not allow control characters in strings
1727
+
1728
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.Agent`
1729
+ :rtype: :class:`~oci.response.Response`
1730
+
1731
+ :example:
1732
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_agent.py.html>`__ to see an example of how to use get_agent API.
1733
+ """
1734
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1735
+ required_arguments = ['agentId']
1736
+ resource_path = "/agents/{agentId}"
1737
+ method = "GET"
1738
+ operation_name = "get_agent"
1739
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/GetAgent"
1740
+
1741
+ # Don't accept unknown kwargs
1742
+ expected_kwargs = [
1743
+ "allow_control_chars",
1744
+ "retry_strategy",
1745
+ "opc_request_id"
1746
+ ]
1747
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1748
+ if extra_kwargs:
1749
+ raise ValueError(
1750
+ f"get_agent got unknown kwargs: {extra_kwargs!r}")
1751
+
1752
+ path_params = {
1753
+ "agentId": agent_id
1754
+ }
1755
+
1756
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1757
+
1758
+ for (k, v) in six.iteritems(path_params):
1759
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1760
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1761
+
1762
+ header_params = {
1763
+ "accept": "application/json",
1764
+ "content-type": "application/json",
1765
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1766
+ }
1767
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1768
+
1769
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1770
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1771
+ client_retry_strategy=self.retry_strategy
1772
+ )
1773
+ if retry_strategy is None:
1774
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1775
+
1776
+ if retry_strategy:
1777
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1778
+ self.base_client.add_opc_client_retries_header(header_params)
1779
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1780
+ return retry_strategy.make_retrying_call(
1781
+ self.base_client.call_api,
1782
+ resource_path=resource_path,
1783
+ method=method,
1784
+ path_params=path_params,
1785
+ header_params=header_params,
1786
+ response_type="Agent",
1787
+ allow_control_chars=kwargs.get('allow_control_chars'),
1788
+ operation_name=operation_name,
1789
+ api_reference_link=api_reference_link,
1790
+ required_arguments=required_arguments)
1791
+ else:
1792
+ return self.base_client.call_api(
1793
+ resource_path=resource_path,
1794
+ method=method,
1795
+ path_params=path_params,
1796
+ header_params=header_params,
1797
+ response_type="Agent",
1798
+ allow_control_chars=kwargs.get('allow_control_chars'),
1799
+ operation_name=operation_name,
1800
+ api_reference_link=api_reference_link,
1801
+ required_arguments=required_arguments)
1802
+
1803
+ def get_agent_endpoint(self, agent_endpoint_id, **kwargs):
1804
+ """
1805
+ **GetAgentEndpoint**
1806
+
1807
+ Gets information about an endpoint.
1808
+
1809
+
1810
+ :param str agent_endpoint_id: (required)
1811
+ The `OCID`__ of the endpoint.
1812
+
1813
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1814
+
1815
+ :param str opc_request_id: (optional)
1816
+ Unique Oracle-assigned identifier for the request. If you need to contact
1817
+ Oracle about a particular request, please provide the request ID.
1818
+ The only valid characters for request IDs are letters, numbers,
1819
+ underscore, and dash.
1820
+
1821
+ :param obj retry_strategy: (optional)
1822
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1823
+
1824
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1825
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1826
+
1827
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1828
+
1829
+ :param bool allow_control_chars: (optional)
1830
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1831
+ By default, the response will not allow control characters in strings
1832
+
1833
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.AgentEndpoint`
1834
+ :rtype: :class:`~oci.response.Response`
1835
+
1836
+ :example:
1837
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_agent_endpoint.py.html>`__ to see an example of how to use get_agent_endpoint API.
1838
+ """
1839
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1840
+ required_arguments = ['agentEndpointId']
1841
+ resource_path = "/agentEndpoints/{agentEndpointId}"
1842
+ method = "GET"
1843
+ operation_name = "get_agent_endpoint"
1844
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/GetAgentEndpoint"
1845
+
1846
+ # Don't accept unknown kwargs
1847
+ expected_kwargs = [
1848
+ "allow_control_chars",
1849
+ "retry_strategy",
1850
+ "opc_request_id"
1851
+ ]
1852
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1853
+ if extra_kwargs:
1854
+ raise ValueError(
1855
+ f"get_agent_endpoint got unknown kwargs: {extra_kwargs!r}")
1856
+
1857
+ path_params = {
1858
+ "agentEndpointId": agent_endpoint_id
1859
+ }
1860
+
1861
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1862
+
1863
+ for (k, v) in six.iteritems(path_params):
1864
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1865
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1866
+
1867
+ header_params = {
1868
+ "accept": "application/json",
1869
+ "content-type": "application/json",
1870
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1871
+ }
1872
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1873
+
1874
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1875
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1876
+ client_retry_strategy=self.retry_strategy
1877
+ )
1878
+ if retry_strategy is None:
1879
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1880
+
1881
+ if retry_strategy:
1882
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1883
+ self.base_client.add_opc_client_retries_header(header_params)
1884
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1885
+ return retry_strategy.make_retrying_call(
1886
+ self.base_client.call_api,
1887
+ resource_path=resource_path,
1888
+ method=method,
1889
+ path_params=path_params,
1890
+ header_params=header_params,
1891
+ response_type="AgentEndpoint",
1892
+ allow_control_chars=kwargs.get('allow_control_chars'),
1893
+ operation_name=operation_name,
1894
+ api_reference_link=api_reference_link,
1895
+ required_arguments=required_arguments)
1896
+ else:
1897
+ return self.base_client.call_api(
1898
+ resource_path=resource_path,
1899
+ method=method,
1900
+ path_params=path_params,
1901
+ header_params=header_params,
1902
+ response_type="AgentEndpoint",
1903
+ allow_control_chars=kwargs.get('allow_control_chars'),
1904
+ operation_name=operation_name,
1905
+ api_reference_link=api_reference_link,
1906
+ required_arguments=required_arguments)
1907
+
1908
+ def get_data_ingestion_job(self, data_ingestion_job_id, **kwargs):
1909
+ """
1910
+ **GetDataIngestionJob**
1911
+
1912
+ Gets information about a data ingestion job.
1913
+
1914
+
1915
+ :param str data_ingestion_job_id: (required)
1916
+ The `OCID`__ of the data ingestion job.
1917
+
1918
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
1919
+
1920
+ :param str opc_request_id: (optional)
1921
+ Unique Oracle-assigned identifier for the request. If you need to contact
1922
+ Oracle about a particular request, please provide the request ID.
1923
+ The only valid characters for request IDs are letters, numbers,
1924
+ underscore, and dash.
1925
+
1926
+ :param obj retry_strategy: (optional)
1927
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
1928
+
1929
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
1930
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
1931
+
1932
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
1933
+
1934
+ :param bool allow_control_chars: (optional)
1935
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
1936
+ By default, the response will not allow control characters in strings
1937
+
1938
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataIngestionJob`
1939
+ :rtype: :class:`~oci.response.Response`
1940
+
1941
+ :example:
1942
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_data_ingestion_job.py.html>`__ to see an example of how to use get_data_ingestion_job API.
1943
+ """
1944
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
1945
+ required_arguments = ['dataIngestionJobId']
1946
+ resource_path = "/dataIngestionJobs/{dataIngestionJobId}"
1947
+ method = "GET"
1948
+ operation_name = "get_data_ingestion_job"
1949
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataIngestionJob/GetDataIngestionJob"
1950
+
1951
+ # Don't accept unknown kwargs
1952
+ expected_kwargs = [
1953
+ "allow_control_chars",
1954
+ "retry_strategy",
1955
+ "opc_request_id"
1956
+ ]
1957
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
1958
+ if extra_kwargs:
1959
+ raise ValueError(
1960
+ f"get_data_ingestion_job got unknown kwargs: {extra_kwargs!r}")
1961
+
1962
+ path_params = {
1963
+ "dataIngestionJobId": data_ingestion_job_id
1964
+ }
1965
+
1966
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1967
+
1968
+ for (k, v) in six.iteritems(path_params):
1969
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
1970
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
1971
+
1972
+ header_params = {
1973
+ "accept": "application/json",
1974
+ "content-type": "application/json",
1975
+ "opc-request-id": kwargs.get("opc_request_id", missing)
1976
+ }
1977
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
1978
+
1979
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
1980
+ operation_retry_strategy=kwargs.get('retry_strategy'),
1981
+ client_retry_strategy=self.retry_strategy
1982
+ )
1983
+ if retry_strategy is None:
1984
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
1985
+
1986
+ if retry_strategy:
1987
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
1988
+ self.base_client.add_opc_client_retries_header(header_params)
1989
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
1990
+ return retry_strategy.make_retrying_call(
1991
+ self.base_client.call_api,
1992
+ resource_path=resource_path,
1993
+ method=method,
1994
+ path_params=path_params,
1995
+ header_params=header_params,
1996
+ response_type="DataIngestionJob",
1997
+ allow_control_chars=kwargs.get('allow_control_chars'),
1998
+ operation_name=operation_name,
1999
+ api_reference_link=api_reference_link,
2000
+ required_arguments=required_arguments)
2001
+ else:
2002
+ return self.base_client.call_api(
2003
+ resource_path=resource_path,
2004
+ method=method,
2005
+ path_params=path_params,
2006
+ header_params=header_params,
2007
+ response_type="DataIngestionJob",
2008
+ allow_control_chars=kwargs.get('allow_control_chars'),
2009
+ operation_name=operation_name,
2010
+ api_reference_link=api_reference_link,
2011
+ required_arguments=required_arguments)
2012
+
2013
+ def get_data_ingestion_job_log_content(self, data_ingestion_job_id, **kwargs):
2014
+ """
2015
+ **GetDataIngestionJobLogContent**
2016
+
2017
+ Returns the raw log file for the specified data ingestion job in text format.
2018
+
2019
+
2020
+ :param str data_ingestion_job_id: (required)
2021
+ The `OCID`__ of the data ingestion job.
2022
+
2023
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2024
+
2025
+ :param str opc_request_id: (optional)
2026
+ Unique Oracle-assigned identifier for the request. If you need to contact
2027
+ Oracle about a particular request, please provide the request ID.
2028
+ The only valid characters for request IDs are letters, numbers,
2029
+ underscore, and dash.
2030
+
2031
+ :param obj retry_strategy: (optional)
2032
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2033
+
2034
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2035
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2036
+
2037
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2038
+
2039
+ :param bool allow_control_chars: (optional)
2040
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2041
+ By default, the response will not allow control characters in strings
2042
+
2043
+ :return: A :class:`~oci.response.Response` object with data of type stream
2044
+ :rtype: :class:`~oci.response.Response`
2045
+
2046
+ :example:
2047
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_data_ingestion_job_log_content.py.html>`__ to see an example of how to use get_data_ingestion_job_log_content API.
2048
+ """
2049
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2050
+ required_arguments = ['dataIngestionJobId']
2051
+ resource_path = "/dataIngestionJobs/{dataIngestionJobId}/logs/content"
2052
+ method = "GET"
2053
+ operation_name = "get_data_ingestion_job_log_content"
2054
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataIngestionJob/GetDataIngestionJobLogContent"
2055
+
2056
+ # Don't accept unknown kwargs
2057
+ expected_kwargs = [
2058
+ "allow_control_chars",
2059
+ "retry_strategy",
2060
+ "opc_request_id"
2061
+ ]
2062
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2063
+ if extra_kwargs:
2064
+ raise ValueError(
2065
+ f"get_data_ingestion_job_log_content got unknown kwargs: {extra_kwargs!r}")
2066
+
2067
+ path_params = {
2068
+ "dataIngestionJobId": data_ingestion_job_id
2069
+ }
2070
+
2071
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
2072
+
2073
+ for (k, v) in six.iteritems(path_params):
2074
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
2075
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
2076
+
2077
+ header_params = {
2078
+ "accept": "text/plain; charset=utf-8",
2079
+ "content-type": "application/json",
2080
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2081
+ }
2082
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2083
+
2084
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2085
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2086
+ client_retry_strategy=self.retry_strategy
2087
+ )
2088
+ if retry_strategy is None:
2089
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2090
+
2091
+ if retry_strategy:
2092
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2093
+ self.base_client.add_opc_client_retries_header(header_params)
2094
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2095
+ return retry_strategy.make_retrying_call(
2096
+ self.base_client.call_api,
2097
+ resource_path=resource_path,
2098
+ method=method,
2099
+ path_params=path_params,
2100
+ header_params=header_params,
2101
+ response_type="stream",
2102
+ allow_control_chars=kwargs.get('allow_control_chars'),
2103
+ operation_name=operation_name,
2104
+ api_reference_link=api_reference_link,
2105
+ required_arguments=required_arguments)
2106
+ else:
2107
+ return self.base_client.call_api(
2108
+ resource_path=resource_path,
2109
+ method=method,
2110
+ path_params=path_params,
2111
+ header_params=header_params,
2112
+ response_type="stream",
2113
+ allow_control_chars=kwargs.get('allow_control_chars'),
2114
+ operation_name=operation_name,
2115
+ api_reference_link=api_reference_link,
2116
+ required_arguments=required_arguments)
2117
+
2118
+ def get_data_source(self, data_source_id, **kwargs):
2119
+ """
2120
+ **GetDataSource**
2121
+
2122
+ Gets information about a data source.
2123
+
2124
+
2125
+ :param str data_source_id: (required)
2126
+ The `OCID`__ of the data source.
2127
+
2128
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2129
+
2130
+ :param str opc_request_id: (optional)
2131
+ Unique Oracle-assigned identifier for the request. If you need to contact
2132
+ Oracle about a particular request, please provide the request ID.
2133
+ The only valid characters for request IDs are letters, numbers,
2134
+ underscore, and dash.
2135
+
2136
+ :param obj retry_strategy: (optional)
2137
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2138
+
2139
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2140
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2141
+
2142
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2143
+
2144
+ :param bool allow_control_chars: (optional)
2145
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2146
+ By default, the response will not allow control characters in strings
2147
+
2148
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataSource`
2149
+ :rtype: :class:`~oci.response.Response`
2150
+
2151
+ :example:
2152
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_data_source.py.html>`__ to see an example of how to use get_data_source API.
2153
+ """
2154
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2155
+ required_arguments = ['dataSourceId']
2156
+ resource_path = "/dataSources/{dataSourceId}"
2157
+ method = "GET"
2158
+ operation_name = "get_data_source"
2159
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataSource/GetDataSource"
2160
+
2161
+ # Don't accept unknown kwargs
2162
+ expected_kwargs = [
2163
+ "allow_control_chars",
2164
+ "retry_strategy",
2165
+ "opc_request_id"
2166
+ ]
2167
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2168
+ if extra_kwargs:
2169
+ raise ValueError(
2170
+ f"get_data_source got unknown kwargs: {extra_kwargs!r}")
2171
+
2172
+ path_params = {
2173
+ "dataSourceId": data_source_id
2174
+ }
2175
+
2176
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
2177
+
2178
+ for (k, v) in six.iteritems(path_params):
2179
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
2180
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
2181
+
2182
+ header_params = {
2183
+ "accept": "application/json",
2184
+ "content-type": "application/json",
2185
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2186
+ }
2187
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2188
+
2189
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2190
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2191
+ client_retry_strategy=self.retry_strategy
2192
+ )
2193
+ if retry_strategy is None:
2194
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2195
+
2196
+ if retry_strategy:
2197
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2198
+ self.base_client.add_opc_client_retries_header(header_params)
2199
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2200
+ return retry_strategy.make_retrying_call(
2201
+ self.base_client.call_api,
2202
+ resource_path=resource_path,
2203
+ method=method,
2204
+ path_params=path_params,
2205
+ header_params=header_params,
2206
+ response_type="DataSource",
2207
+ allow_control_chars=kwargs.get('allow_control_chars'),
2208
+ operation_name=operation_name,
2209
+ api_reference_link=api_reference_link,
2210
+ required_arguments=required_arguments)
2211
+ else:
2212
+ return self.base_client.call_api(
2213
+ resource_path=resource_path,
2214
+ method=method,
2215
+ path_params=path_params,
2216
+ header_params=header_params,
2217
+ response_type="DataSource",
2218
+ allow_control_chars=kwargs.get('allow_control_chars'),
2219
+ operation_name=operation_name,
2220
+ api_reference_link=api_reference_link,
2221
+ required_arguments=required_arguments)
2222
+
2223
+ def get_knowledge_base(self, knowledge_base_id, **kwargs):
2224
+ """
2225
+ **GetKnowledgeBase**
2226
+
2227
+ Gets information about a knowledge base.
2228
+
2229
+
2230
+ :param str knowledge_base_id: (required)
2231
+ The `OCID`__ of the knowledge base.
2232
+
2233
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2234
+
2235
+ :param str opc_request_id: (optional)
2236
+ Unique Oracle-assigned identifier for the request. If you need to contact
2237
+ Oracle about a particular request, please provide the request ID.
2238
+ The only valid characters for request IDs are letters, numbers,
2239
+ underscore, and dash.
2240
+
2241
+ :param obj retry_strategy: (optional)
2242
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2243
+
2244
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2245
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2246
+
2247
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2248
+
2249
+ :param bool allow_control_chars: (optional)
2250
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2251
+ By default, the response will not allow control characters in strings
2252
+
2253
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.KnowledgeBase`
2254
+ :rtype: :class:`~oci.response.Response`
2255
+
2256
+ :example:
2257
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_knowledge_base.py.html>`__ to see an example of how to use get_knowledge_base API.
2258
+ """
2259
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2260
+ required_arguments = ['knowledgeBaseId']
2261
+ resource_path = "/knowledgeBases/{knowledgeBaseId}"
2262
+ method = "GET"
2263
+ operation_name = "get_knowledge_base"
2264
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/GetKnowledgeBase"
2265
+
2266
+ # Don't accept unknown kwargs
2267
+ expected_kwargs = [
2268
+ "allow_control_chars",
2269
+ "retry_strategy",
2270
+ "opc_request_id"
2271
+ ]
2272
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2273
+ if extra_kwargs:
2274
+ raise ValueError(
2275
+ f"get_knowledge_base got unknown kwargs: {extra_kwargs!r}")
2276
+
2277
+ path_params = {
2278
+ "knowledgeBaseId": knowledge_base_id
2279
+ }
2280
+
2281
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
2282
+
2283
+ for (k, v) in six.iteritems(path_params):
2284
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
2285
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
2286
+
2287
+ header_params = {
2288
+ "accept": "application/json",
2289
+ "content-type": "application/json",
2290
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2291
+ }
2292
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2293
+
2294
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2295
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2296
+ client_retry_strategy=self.retry_strategy
2297
+ )
2298
+ if retry_strategy is None:
2299
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2300
+
2301
+ if retry_strategy:
2302
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2303
+ self.base_client.add_opc_client_retries_header(header_params)
2304
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2305
+ return retry_strategy.make_retrying_call(
2306
+ self.base_client.call_api,
2307
+ resource_path=resource_path,
2308
+ method=method,
2309
+ path_params=path_params,
2310
+ header_params=header_params,
2311
+ response_type="KnowledgeBase",
2312
+ allow_control_chars=kwargs.get('allow_control_chars'),
2313
+ operation_name=operation_name,
2314
+ api_reference_link=api_reference_link,
2315
+ required_arguments=required_arguments)
2316
+ else:
2317
+ return self.base_client.call_api(
2318
+ resource_path=resource_path,
2319
+ method=method,
2320
+ path_params=path_params,
2321
+ header_params=header_params,
2322
+ response_type="KnowledgeBase",
2323
+ allow_control_chars=kwargs.get('allow_control_chars'),
2324
+ operation_name=operation_name,
2325
+ api_reference_link=api_reference_link,
2326
+ required_arguments=required_arguments)
2327
+
2328
+ def get_work_request(self, work_request_id, **kwargs):
2329
+ """
2330
+ **GetWorkRequest**
2331
+
2332
+ Gets the details of a work request.
2333
+
2334
+
2335
+ :param str work_request_id: (required)
2336
+ The `OCID`__ of the asynchronous work request.
2337
+
2338
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2339
+
2340
+ :param str opc_request_id: (optional)
2341
+ Unique Oracle-assigned identifier for the request. If you need to contact
2342
+ Oracle about a particular request, please provide the request ID.
2343
+ The only valid characters for request IDs are letters, numbers,
2344
+ underscore, and dash.
2345
+
2346
+ :param obj retry_strategy: (optional)
2347
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2348
+
2349
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2350
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2351
+
2352
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2353
+
2354
+ :param bool allow_control_chars: (optional)
2355
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2356
+ By default, the response will not allow control characters in strings
2357
+
2358
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.WorkRequest`
2359
+ :rtype: :class:`~oci.response.Response`
2360
+
2361
+ :example:
2362
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/get_work_request.py.html>`__ to see an example of how to use get_work_request API.
2363
+ """
2364
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2365
+ required_arguments = ['workRequestId']
2366
+ resource_path = "/workRequests/{workRequestId}"
2367
+ method = "GET"
2368
+ operation_name = "get_work_request"
2369
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/WorkRequest/GetWorkRequest"
2370
+
2371
+ # Don't accept unknown kwargs
2372
+ expected_kwargs = [
2373
+ "allow_control_chars",
2374
+ "retry_strategy",
2375
+ "opc_request_id"
2376
+ ]
2377
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2378
+ if extra_kwargs:
2379
+ raise ValueError(
2380
+ f"get_work_request got unknown kwargs: {extra_kwargs!r}")
2381
+
2382
+ path_params = {
2383
+ "workRequestId": work_request_id
2384
+ }
2385
+
2386
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
2387
+
2388
+ for (k, v) in six.iteritems(path_params):
2389
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
2390
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
2391
+
2392
+ header_params = {
2393
+ "accept": "application/json",
2394
+ "content-type": "application/json",
2395
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2396
+ }
2397
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2398
+
2399
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2400
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2401
+ client_retry_strategy=self.retry_strategy
2402
+ )
2403
+ if retry_strategy is None:
2404
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2405
+
2406
+ if retry_strategy:
2407
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2408
+ self.base_client.add_opc_client_retries_header(header_params)
2409
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2410
+ return retry_strategy.make_retrying_call(
2411
+ self.base_client.call_api,
2412
+ resource_path=resource_path,
2413
+ method=method,
2414
+ path_params=path_params,
2415
+ header_params=header_params,
2416
+ response_type="WorkRequest",
2417
+ allow_control_chars=kwargs.get('allow_control_chars'),
2418
+ operation_name=operation_name,
2419
+ api_reference_link=api_reference_link,
2420
+ required_arguments=required_arguments)
2421
+ else:
2422
+ return self.base_client.call_api(
2423
+ resource_path=resource_path,
2424
+ method=method,
2425
+ path_params=path_params,
2426
+ header_params=header_params,
2427
+ response_type="WorkRequest",
2428
+ allow_control_chars=kwargs.get('allow_control_chars'),
2429
+ operation_name=operation_name,
2430
+ api_reference_link=api_reference_link,
2431
+ required_arguments=required_arguments)
2432
+
2433
+ def list_agent_endpoints(self, **kwargs):
2434
+ """
2435
+ **ListAgentEndpoints**
2436
+
2437
+ Gets a list of endpoints.
2438
+
2439
+
2440
+ :param str compartment_id: (optional)
2441
+ The `OCID`__ of the compartment in which to list resources.
2442
+
2443
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2444
+
2445
+ :param str agent_id: (optional)
2446
+ The `OCID`__ of the agent.
2447
+
2448
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2449
+
2450
+ :param str lifecycle_state: (optional)
2451
+ A filter to return only resources that match the given lifecycle state. The
2452
+ state value is case-insensitive.
2453
+
2454
+ Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"
2455
+
2456
+ :param str display_name: (optional)
2457
+ A filter to return only resources that match the given display name exactly.
2458
+
2459
+ :param int limit: (optional)
2460
+ For list pagination. The maximum number of results per page, or items to return in a
2461
+ paginated \"List\" call. For important details about how pagination works, see
2462
+ `List Pagination`__.
2463
+
2464
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2465
+
2466
+ :param str page: (optional)
2467
+ For list pagination. The value of the opc-next-page response header from the previous
2468
+ \"List\" call. For important details about how pagination works, see
2469
+ `List Pagination`__.
2470
+
2471
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2472
+
2473
+ :param str sort_order: (optional)
2474
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
2475
+
2476
+ Allowed values are: "ASC", "DESC"
2477
+
2478
+ :param str sort_by: (optional)
2479
+ The field to sort by. You can provide only one sort order. Default order for `timeCreated`
2480
+ is descending. Default order for `displayName` is ascending.
2481
+
2482
+ Allowed values are: "timeCreated", "displayName"
2483
+
2484
+ :param str opc_request_id: (optional)
2485
+ Unique Oracle-assigned identifier for the request. If you need to contact
2486
+ Oracle about a particular request, please provide the request ID.
2487
+ The only valid characters for request IDs are letters, numbers,
2488
+ underscore, and dash.
2489
+
2490
+ :param obj retry_strategy: (optional)
2491
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2492
+
2493
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2494
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2495
+
2496
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2497
+
2498
+ :param bool allow_control_chars: (optional)
2499
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2500
+ By default, the response will not allow control characters in strings
2501
+
2502
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.AgentEndpointCollection`
2503
+ :rtype: :class:`~oci.response.Response`
2504
+
2505
+ :example:
2506
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_agent_endpoints.py.html>`__ to see an example of how to use list_agent_endpoints API.
2507
+ """
2508
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2509
+ required_arguments = []
2510
+ resource_path = "/agentEndpoints"
2511
+ method = "GET"
2512
+ operation_name = "list_agent_endpoints"
2513
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/ListAgentEndpoints"
2514
+
2515
+ # Don't accept unknown kwargs
2516
+ expected_kwargs = [
2517
+ "allow_control_chars",
2518
+ "retry_strategy",
2519
+ "compartment_id",
2520
+ "agent_id",
2521
+ "lifecycle_state",
2522
+ "display_name",
2523
+ "limit",
2524
+ "page",
2525
+ "sort_order",
2526
+ "sort_by",
2527
+ "opc_request_id"
2528
+ ]
2529
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2530
+ if extra_kwargs:
2531
+ raise ValueError(
2532
+ f"list_agent_endpoints got unknown kwargs: {extra_kwargs!r}")
2533
+
2534
+ if 'lifecycle_state' in kwargs:
2535
+ lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"]
2536
+ if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
2537
+ raise ValueError(
2538
+ f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
2539
+ )
2540
+
2541
+ if 'sort_order' in kwargs:
2542
+ sort_order_allowed_values = ["ASC", "DESC"]
2543
+ if kwargs['sort_order'] not in sort_order_allowed_values:
2544
+ raise ValueError(
2545
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
2546
+ )
2547
+
2548
+ if 'sort_by' in kwargs:
2549
+ sort_by_allowed_values = ["timeCreated", "displayName"]
2550
+ if kwargs['sort_by'] not in sort_by_allowed_values:
2551
+ raise ValueError(
2552
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
2553
+ )
2554
+
2555
+ query_params = {
2556
+ "compartmentId": kwargs.get("compartment_id", missing),
2557
+ "agentId": kwargs.get("agent_id", missing),
2558
+ "lifecycleState": kwargs.get("lifecycle_state", missing),
2559
+ "displayName": kwargs.get("display_name", missing),
2560
+ "limit": kwargs.get("limit", missing),
2561
+ "page": kwargs.get("page", missing),
2562
+ "sortOrder": kwargs.get("sort_order", missing),
2563
+ "sortBy": kwargs.get("sort_by", missing)
2564
+ }
2565
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
2566
+
2567
+ header_params = {
2568
+ "accept": "application/json",
2569
+ "content-type": "application/json",
2570
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2571
+ }
2572
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2573
+
2574
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2575
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2576
+ client_retry_strategy=self.retry_strategy
2577
+ )
2578
+ if retry_strategy is None:
2579
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2580
+
2581
+ if retry_strategy:
2582
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2583
+ self.base_client.add_opc_client_retries_header(header_params)
2584
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2585
+ return retry_strategy.make_retrying_call(
2586
+ self.base_client.call_api,
2587
+ resource_path=resource_path,
2588
+ method=method,
2589
+ query_params=query_params,
2590
+ header_params=header_params,
2591
+ response_type="AgentEndpointCollection",
2592
+ allow_control_chars=kwargs.get('allow_control_chars'),
2593
+ operation_name=operation_name,
2594
+ api_reference_link=api_reference_link,
2595
+ required_arguments=required_arguments)
2596
+ else:
2597
+ return self.base_client.call_api(
2598
+ resource_path=resource_path,
2599
+ method=method,
2600
+ query_params=query_params,
2601
+ header_params=header_params,
2602
+ response_type="AgentEndpointCollection",
2603
+ allow_control_chars=kwargs.get('allow_control_chars'),
2604
+ operation_name=operation_name,
2605
+ api_reference_link=api_reference_link,
2606
+ required_arguments=required_arguments)
2607
+
2608
+ def list_agents(self, **kwargs):
2609
+ """
2610
+ **ListAgents**
2611
+
2612
+ Gets a list of agents.
2613
+
2614
+
2615
+ :param str compartment_id: (optional)
2616
+ The `OCID`__ of the compartment in which to list resources.
2617
+
2618
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2619
+
2620
+ :param str lifecycle_state: (optional)
2621
+ A filter to return only resources that match the given lifecycle state. The
2622
+ state value is case-insensitive.
2623
+
2624
+ Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"
2625
+
2626
+ :param str display_name: (optional)
2627
+ A filter to return only resources that match the given display name exactly.
2628
+
2629
+ :param int limit: (optional)
2630
+ For list pagination. The maximum number of results per page, or items to return in a
2631
+ paginated \"List\" call. For important details about how pagination works, see
2632
+ `List Pagination`__.
2633
+
2634
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2635
+
2636
+ :param str page: (optional)
2637
+ For list pagination. The value of the opc-next-page response header from the previous
2638
+ \"List\" call. For important details about how pagination works, see
2639
+ `List Pagination`__.
2640
+
2641
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2642
+
2643
+ :param str sort_order: (optional)
2644
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
2645
+
2646
+ Allowed values are: "ASC", "DESC"
2647
+
2648
+ :param str sort_by: (optional)
2649
+ The field to sort by. You can provide only one sort order. Default order for `timeCreated`
2650
+ is descending. Default order for `displayName` is ascending.
2651
+
2652
+ Allowed values are: "timeCreated", "displayName"
2653
+
2654
+ :param str opc_request_id: (optional)
2655
+ Unique Oracle-assigned identifier for the request. If you need to contact
2656
+ Oracle about a particular request, please provide the request ID.
2657
+ The only valid characters for request IDs are letters, numbers,
2658
+ underscore, and dash.
2659
+
2660
+ :param obj retry_strategy: (optional)
2661
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2662
+
2663
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2664
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2665
+
2666
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2667
+
2668
+ :param bool allow_control_chars: (optional)
2669
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2670
+ By default, the response will not allow control characters in strings
2671
+
2672
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.AgentCollection`
2673
+ :rtype: :class:`~oci.response.Response`
2674
+
2675
+ :example:
2676
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_agents.py.html>`__ to see an example of how to use list_agents API.
2677
+ """
2678
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2679
+ required_arguments = []
2680
+ resource_path = "/agents"
2681
+ method = "GET"
2682
+ operation_name = "list_agents"
2683
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/ListAgents"
2684
+
2685
+ # Don't accept unknown kwargs
2686
+ expected_kwargs = [
2687
+ "allow_control_chars",
2688
+ "retry_strategy",
2689
+ "compartment_id",
2690
+ "lifecycle_state",
2691
+ "display_name",
2692
+ "limit",
2693
+ "page",
2694
+ "sort_order",
2695
+ "sort_by",
2696
+ "opc_request_id"
2697
+ ]
2698
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2699
+ if extra_kwargs:
2700
+ raise ValueError(
2701
+ f"list_agents got unknown kwargs: {extra_kwargs!r}")
2702
+
2703
+ if 'lifecycle_state' in kwargs:
2704
+ lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"]
2705
+ if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
2706
+ raise ValueError(
2707
+ f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
2708
+ )
2709
+
2710
+ if 'sort_order' in kwargs:
2711
+ sort_order_allowed_values = ["ASC", "DESC"]
2712
+ if kwargs['sort_order'] not in sort_order_allowed_values:
2713
+ raise ValueError(
2714
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
2715
+ )
2716
+
2717
+ if 'sort_by' in kwargs:
2718
+ sort_by_allowed_values = ["timeCreated", "displayName"]
2719
+ if kwargs['sort_by'] not in sort_by_allowed_values:
2720
+ raise ValueError(
2721
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
2722
+ )
2723
+
2724
+ query_params = {
2725
+ "compartmentId": kwargs.get("compartment_id", missing),
2726
+ "lifecycleState": kwargs.get("lifecycle_state", missing),
2727
+ "displayName": kwargs.get("display_name", missing),
2728
+ "limit": kwargs.get("limit", missing),
2729
+ "page": kwargs.get("page", missing),
2730
+ "sortOrder": kwargs.get("sort_order", missing),
2731
+ "sortBy": kwargs.get("sort_by", missing)
2732
+ }
2733
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
2734
+
2735
+ header_params = {
2736
+ "accept": "application/json",
2737
+ "content-type": "application/json",
2738
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2739
+ }
2740
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2741
+
2742
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2743
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2744
+ client_retry_strategy=self.retry_strategy
2745
+ )
2746
+ if retry_strategy is None:
2747
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2748
+
2749
+ if retry_strategy:
2750
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2751
+ self.base_client.add_opc_client_retries_header(header_params)
2752
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2753
+ return retry_strategy.make_retrying_call(
2754
+ self.base_client.call_api,
2755
+ resource_path=resource_path,
2756
+ method=method,
2757
+ query_params=query_params,
2758
+ header_params=header_params,
2759
+ response_type="AgentCollection",
2760
+ allow_control_chars=kwargs.get('allow_control_chars'),
2761
+ operation_name=operation_name,
2762
+ api_reference_link=api_reference_link,
2763
+ required_arguments=required_arguments)
2764
+ else:
2765
+ return self.base_client.call_api(
2766
+ resource_path=resource_path,
2767
+ method=method,
2768
+ query_params=query_params,
2769
+ header_params=header_params,
2770
+ response_type="AgentCollection",
2771
+ allow_control_chars=kwargs.get('allow_control_chars'),
2772
+ operation_name=operation_name,
2773
+ api_reference_link=api_reference_link,
2774
+ required_arguments=required_arguments)
2775
+
2776
+ def list_data_ingestion_jobs(self, **kwargs):
2777
+ """
2778
+ **ListDataIngestionJobs**
2779
+
2780
+ Gets a list of data ingestion jobs.
2781
+
2782
+
2783
+ :param str compartment_id: (optional)
2784
+ The `OCID`__ of the compartment in which to list resources.
2785
+
2786
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2787
+
2788
+ :param str data_source_id: (optional)
2789
+ The `OCID`__ of the data source.
2790
+
2791
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2792
+
2793
+ :param str lifecycle_state: (optional)
2794
+ A filter to return only resources that match the given lifecycle state. The
2795
+ state value is case-insensitive.
2796
+
2797
+ Allowed values are: "ACCEPTED", "IN_PROGRESS", "WAITING", "FAILED", "SUCCEEDED", "DELETING", "DELETED"
2798
+
2799
+ :param str display_name: (optional)
2800
+ A filter to return only resources that match the given display name exactly.
2801
+
2802
+ :param int limit: (optional)
2803
+ For list pagination. The maximum number of results per page, or items to return in a
2804
+ paginated \"List\" call. For important details about how pagination works, see
2805
+ `List Pagination`__.
2806
+
2807
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2808
+
2809
+ :param str page: (optional)
2810
+ For list pagination. The value of the opc-next-page response header from the previous
2811
+ \"List\" call. For important details about how pagination works, see
2812
+ `List Pagination`__.
2813
+
2814
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2815
+
2816
+ :param str sort_order: (optional)
2817
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
2818
+
2819
+ Allowed values are: "ASC", "DESC"
2820
+
2821
+ :param str sort_by: (optional)
2822
+ The field to sort by. You can provide only one sort order. Default order for `timeCreated`
2823
+ is descending. Default order for `displayName` is ascending.
2824
+
2825
+ Allowed values are: "timeCreated", "displayName"
2826
+
2827
+ :param str opc_request_id: (optional)
2828
+ Unique Oracle-assigned identifier for the request. If you need to contact
2829
+ Oracle about a particular request, please provide the request ID.
2830
+ The only valid characters for request IDs are letters, numbers,
2831
+ underscore, and dash.
2832
+
2833
+ :param obj retry_strategy: (optional)
2834
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
2835
+
2836
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
2837
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
2838
+
2839
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
2840
+
2841
+ :param bool allow_control_chars: (optional)
2842
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
2843
+ By default, the response will not allow control characters in strings
2844
+
2845
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataIngestionJobCollection`
2846
+ :rtype: :class:`~oci.response.Response`
2847
+
2848
+ :example:
2849
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_data_ingestion_jobs.py.html>`__ to see an example of how to use list_data_ingestion_jobs API.
2850
+ """
2851
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
2852
+ required_arguments = []
2853
+ resource_path = "/dataIngestionJobs"
2854
+ method = "GET"
2855
+ operation_name = "list_data_ingestion_jobs"
2856
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataIngestionJob/ListDataIngestionJobs"
2857
+
2858
+ # Don't accept unknown kwargs
2859
+ expected_kwargs = [
2860
+ "allow_control_chars",
2861
+ "retry_strategy",
2862
+ "compartment_id",
2863
+ "data_source_id",
2864
+ "lifecycle_state",
2865
+ "display_name",
2866
+ "limit",
2867
+ "page",
2868
+ "sort_order",
2869
+ "sort_by",
2870
+ "opc_request_id"
2871
+ ]
2872
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
2873
+ if extra_kwargs:
2874
+ raise ValueError(
2875
+ f"list_data_ingestion_jobs got unknown kwargs: {extra_kwargs!r}")
2876
+
2877
+ if 'lifecycle_state' in kwargs:
2878
+ lifecycle_state_allowed_values = ["ACCEPTED", "IN_PROGRESS", "WAITING", "FAILED", "SUCCEEDED", "DELETING", "DELETED"]
2879
+ if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
2880
+ raise ValueError(
2881
+ f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
2882
+ )
2883
+
2884
+ if 'sort_order' in kwargs:
2885
+ sort_order_allowed_values = ["ASC", "DESC"]
2886
+ if kwargs['sort_order'] not in sort_order_allowed_values:
2887
+ raise ValueError(
2888
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
2889
+ )
2890
+
2891
+ if 'sort_by' in kwargs:
2892
+ sort_by_allowed_values = ["timeCreated", "displayName"]
2893
+ if kwargs['sort_by'] not in sort_by_allowed_values:
2894
+ raise ValueError(
2895
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
2896
+ )
2897
+
2898
+ query_params = {
2899
+ "compartmentId": kwargs.get("compartment_id", missing),
2900
+ "dataSourceId": kwargs.get("data_source_id", missing),
2901
+ "lifecycleState": kwargs.get("lifecycle_state", missing),
2902
+ "displayName": kwargs.get("display_name", missing),
2903
+ "limit": kwargs.get("limit", missing),
2904
+ "page": kwargs.get("page", missing),
2905
+ "sortOrder": kwargs.get("sort_order", missing),
2906
+ "sortBy": kwargs.get("sort_by", missing)
2907
+ }
2908
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
2909
+
2910
+ header_params = {
2911
+ "accept": "application/json",
2912
+ "content-type": "application/json",
2913
+ "opc-request-id": kwargs.get("opc_request_id", missing)
2914
+ }
2915
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
2916
+
2917
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
2918
+ operation_retry_strategy=kwargs.get('retry_strategy'),
2919
+ client_retry_strategy=self.retry_strategy
2920
+ )
2921
+ if retry_strategy is None:
2922
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
2923
+
2924
+ if retry_strategy:
2925
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
2926
+ self.base_client.add_opc_client_retries_header(header_params)
2927
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
2928
+ return retry_strategy.make_retrying_call(
2929
+ self.base_client.call_api,
2930
+ resource_path=resource_path,
2931
+ method=method,
2932
+ query_params=query_params,
2933
+ header_params=header_params,
2934
+ response_type="DataIngestionJobCollection",
2935
+ allow_control_chars=kwargs.get('allow_control_chars'),
2936
+ operation_name=operation_name,
2937
+ api_reference_link=api_reference_link,
2938
+ required_arguments=required_arguments)
2939
+ else:
2940
+ return self.base_client.call_api(
2941
+ resource_path=resource_path,
2942
+ method=method,
2943
+ query_params=query_params,
2944
+ header_params=header_params,
2945
+ response_type="DataIngestionJobCollection",
2946
+ allow_control_chars=kwargs.get('allow_control_chars'),
2947
+ operation_name=operation_name,
2948
+ api_reference_link=api_reference_link,
2949
+ required_arguments=required_arguments)
2950
+
2951
+ def list_data_sources(self, **kwargs):
2952
+ """
2953
+ **ListDataSources**
2954
+
2955
+ Gets a list of data sources.
2956
+
2957
+
2958
+ :param str compartment_id: (optional)
2959
+ The `OCID`__ of the compartment in which to list resources.
2960
+
2961
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2962
+
2963
+ :param str knowledge_base_id: (optional)
2964
+ The `OCID`__ of the knowledge base.
2965
+
2966
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
2967
+
2968
+ :param str lifecycle_state: (optional)
2969
+ A filter to return only resources that match the given lifecycle state. The
2970
+ state value is case-insensitive.
2971
+
2972
+ Allowed values are: "CREATING", "ACTIVE", "INACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED"
2973
+
2974
+ :param str display_name: (optional)
2975
+ A filter to return only resources that match the given display name exactly.
2976
+
2977
+ :param int limit: (optional)
2978
+ For list pagination. The maximum number of results per page, or items to return in a
2979
+ paginated \"List\" call. For important details about how pagination works, see
2980
+ `List Pagination`__.
2981
+
2982
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2983
+
2984
+ :param str page: (optional)
2985
+ For list pagination. The value of the opc-next-page response header from the previous
2986
+ \"List\" call. For important details about how pagination works, see
2987
+ `List Pagination`__.
2988
+
2989
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
2990
+
2991
+ :param str sort_order: (optional)
2992
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
2993
+
2994
+ Allowed values are: "ASC", "DESC"
2995
+
2996
+ :param str sort_by: (optional)
2997
+ The field to sort by. You can provide only one sort order. Default order for `timeCreated`
2998
+ is descending. Default order for `displayName` is ascending.
2999
+
3000
+ Allowed values are: "timeCreated", "displayName"
3001
+
3002
+ :param str opc_request_id: (optional)
3003
+ Unique Oracle-assigned identifier for the request. If you need to contact
3004
+ Oracle about a particular request, please provide the request ID.
3005
+ The only valid characters for request IDs are letters, numbers,
3006
+ underscore, and dash.
3007
+
3008
+ :param obj retry_strategy: (optional)
3009
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3010
+
3011
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3012
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3013
+
3014
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3015
+
3016
+ :param bool allow_control_chars: (optional)
3017
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3018
+ By default, the response will not allow control characters in strings
3019
+
3020
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.DataSourceCollection`
3021
+ :rtype: :class:`~oci.response.Response`
3022
+
3023
+ :example:
3024
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_data_sources.py.html>`__ to see an example of how to use list_data_sources API.
3025
+ """
3026
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3027
+ required_arguments = []
3028
+ resource_path = "/dataSources"
3029
+ method = "GET"
3030
+ operation_name = "list_data_sources"
3031
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataSource/ListDataSources"
3032
+
3033
+ # Don't accept unknown kwargs
3034
+ expected_kwargs = [
3035
+ "allow_control_chars",
3036
+ "retry_strategy",
3037
+ "compartment_id",
3038
+ "knowledge_base_id",
3039
+ "lifecycle_state",
3040
+ "display_name",
3041
+ "limit",
3042
+ "page",
3043
+ "sort_order",
3044
+ "sort_by",
3045
+ "opc_request_id"
3046
+ ]
3047
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3048
+ if extra_kwargs:
3049
+ raise ValueError(
3050
+ f"list_data_sources got unknown kwargs: {extra_kwargs!r}")
3051
+
3052
+ if 'lifecycle_state' in kwargs:
3053
+ lifecycle_state_allowed_values = ["CREATING", "ACTIVE", "INACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED"]
3054
+ if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
3055
+ raise ValueError(
3056
+ f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
3057
+ )
3058
+
3059
+ if 'sort_order' in kwargs:
3060
+ sort_order_allowed_values = ["ASC", "DESC"]
3061
+ if kwargs['sort_order'] not in sort_order_allowed_values:
3062
+ raise ValueError(
3063
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
3064
+ )
3065
+
3066
+ if 'sort_by' in kwargs:
3067
+ sort_by_allowed_values = ["timeCreated", "displayName"]
3068
+ if kwargs['sort_by'] not in sort_by_allowed_values:
3069
+ raise ValueError(
3070
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
3071
+ )
3072
+
3073
+ query_params = {
3074
+ "compartmentId": kwargs.get("compartment_id", missing),
3075
+ "knowledgeBaseId": kwargs.get("knowledge_base_id", missing),
3076
+ "lifecycleState": kwargs.get("lifecycle_state", missing),
3077
+ "displayName": kwargs.get("display_name", missing),
3078
+ "limit": kwargs.get("limit", missing),
3079
+ "page": kwargs.get("page", missing),
3080
+ "sortOrder": kwargs.get("sort_order", missing),
3081
+ "sortBy": kwargs.get("sort_by", missing)
3082
+ }
3083
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
3084
+
3085
+ header_params = {
3086
+ "accept": "application/json",
3087
+ "content-type": "application/json",
3088
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3089
+ }
3090
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3091
+
3092
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3093
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3094
+ client_retry_strategy=self.retry_strategy
3095
+ )
3096
+ if retry_strategy is None:
3097
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3098
+
3099
+ if retry_strategy:
3100
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3101
+ self.base_client.add_opc_client_retries_header(header_params)
3102
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3103
+ return retry_strategy.make_retrying_call(
3104
+ self.base_client.call_api,
3105
+ resource_path=resource_path,
3106
+ method=method,
3107
+ query_params=query_params,
3108
+ header_params=header_params,
3109
+ response_type="DataSourceCollection",
3110
+ allow_control_chars=kwargs.get('allow_control_chars'),
3111
+ operation_name=operation_name,
3112
+ api_reference_link=api_reference_link,
3113
+ required_arguments=required_arguments)
3114
+ else:
3115
+ return self.base_client.call_api(
3116
+ resource_path=resource_path,
3117
+ method=method,
3118
+ query_params=query_params,
3119
+ header_params=header_params,
3120
+ response_type="DataSourceCollection",
3121
+ allow_control_chars=kwargs.get('allow_control_chars'),
3122
+ operation_name=operation_name,
3123
+ api_reference_link=api_reference_link,
3124
+ required_arguments=required_arguments)
3125
+
3126
+ def list_knowledge_bases(self, **kwargs):
3127
+ """
3128
+ **ListKnowledgeBases**
3129
+
3130
+ Gets a list of knowledge bases.
3131
+
3132
+
3133
+ :param str compartment_id: (optional)
3134
+ The `OCID`__ of the compartment in which to list resources.
3135
+
3136
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3137
+
3138
+ :param str lifecycle_state: (optional)
3139
+ A filter to return only resources that match the given lifecycle state. The
3140
+ state value is case-insensitive.
3141
+
3142
+ Allowed values are: "CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"
3143
+
3144
+ :param str display_name: (optional)
3145
+ A filter to return only resources that match the given display name exactly.
3146
+
3147
+ :param int limit: (optional)
3148
+ For list pagination. The maximum number of results per page, or items to return in a
3149
+ paginated \"List\" call. For important details about how pagination works, see
3150
+ `List Pagination`__.
3151
+
3152
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3153
+
3154
+ :param str page: (optional)
3155
+ For list pagination. The value of the opc-next-page response header from the previous
3156
+ \"List\" call. For important details about how pagination works, see
3157
+ `List Pagination`__.
3158
+
3159
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3160
+
3161
+ :param str sort_order: (optional)
3162
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
3163
+
3164
+ Allowed values are: "ASC", "DESC"
3165
+
3166
+ :param str sort_by: (optional)
3167
+ The field to sort by. You can provide only one sort order. Default order for `timeCreated`
3168
+ is descending. Default order for `displayName` is ascending.
3169
+
3170
+ Allowed values are: "timeCreated", "displayName"
3171
+
3172
+ :param str opc_request_id: (optional)
3173
+ Unique Oracle-assigned identifier for the request. If you need to contact
3174
+ Oracle about a particular request, please provide the request ID.
3175
+ The only valid characters for request IDs are letters, numbers,
3176
+ underscore, and dash.
3177
+
3178
+ :param obj retry_strategy: (optional)
3179
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3180
+
3181
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3182
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3183
+
3184
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3185
+
3186
+ :param bool allow_control_chars: (optional)
3187
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3188
+ By default, the response will not allow control characters in strings
3189
+
3190
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.KnowledgeBaseCollection`
3191
+ :rtype: :class:`~oci.response.Response`
3192
+
3193
+ :example:
3194
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_knowledge_bases.py.html>`__ to see an example of how to use list_knowledge_bases API.
3195
+ """
3196
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3197
+ required_arguments = []
3198
+ resource_path = "/knowledgeBases"
3199
+ method = "GET"
3200
+ operation_name = "list_knowledge_bases"
3201
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/ListKnowledgeBases"
3202
+
3203
+ # Don't accept unknown kwargs
3204
+ expected_kwargs = [
3205
+ "allow_control_chars",
3206
+ "retry_strategy",
3207
+ "compartment_id",
3208
+ "lifecycle_state",
3209
+ "display_name",
3210
+ "limit",
3211
+ "page",
3212
+ "sort_order",
3213
+ "sort_by",
3214
+ "opc_request_id"
3215
+ ]
3216
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3217
+ if extra_kwargs:
3218
+ raise ValueError(
3219
+ f"list_knowledge_bases got unknown kwargs: {extra_kwargs!r}")
3220
+
3221
+ if 'lifecycle_state' in kwargs:
3222
+ lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"]
3223
+ if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
3224
+ raise ValueError(
3225
+ f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
3226
+ )
3227
+
3228
+ if 'sort_order' in kwargs:
3229
+ sort_order_allowed_values = ["ASC", "DESC"]
3230
+ if kwargs['sort_order'] not in sort_order_allowed_values:
3231
+ raise ValueError(
3232
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
3233
+ )
3234
+
3235
+ if 'sort_by' in kwargs:
3236
+ sort_by_allowed_values = ["timeCreated", "displayName"]
3237
+ if kwargs['sort_by'] not in sort_by_allowed_values:
3238
+ raise ValueError(
3239
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
3240
+ )
3241
+
3242
+ query_params = {
3243
+ "compartmentId": kwargs.get("compartment_id", missing),
3244
+ "lifecycleState": kwargs.get("lifecycle_state", missing),
3245
+ "displayName": kwargs.get("display_name", missing),
3246
+ "limit": kwargs.get("limit", missing),
3247
+ "page": kwargs.get("page", missing),
3248
+ "sortOrder": kwargs.get("sort_order", missing),
3249
+ "sortBy": kwargs.get("sort_by", missing)
3250
+ }
3251
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
3252
+
3253
+ header_params = {
3254
+ "accept": "application/json",
3255
+ "content-type": "application/json",
3256
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3257
+ }
3258
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3259
+
3260
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3261
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3262
+ client_retry_strategy=self.retry_strategy
3263
+ )
3264
+ if retry_strategy is None:
3265
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3266
+
3267
+ if retry_strategy:
3268
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3269
+ self.base_client.add_opc_client_retries_header(header_params)
3270
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3271
+ return retry_strategy.make_retrying_call(
3272
+ self.base_client.call_api,
3273
+ resource_path=resource_path,
3274
+ method=method,
3275
+ query_params=query_params,
3276
+ header_params=header_params,
3277
+ response_type="KnowledgeBaseCollection",
3278
+ allow_control_chars=kwargs.get('allow_control_chars'),
3279
+ operation_name=operation_name,
3280
+ api_reference_link=api_reference_link,
3281
+ required_arguments=required_arguments)
3282
+ else:
3283
+ return self.base_client.call_api(
3284
+ resource_path=resource_path,
3285
+ method=method,
3286
+ query_params=query_params,
3287
+ header_params=header_params,
3288
+ response_type="KnowledgeBaseCollection",
3289
+ allow_control_chars=kwargs.get('allow_control_chars'),
3290
+ operation_name=operation_name,
3291
+ api_reference_link=api_reference_link,
3292
+ required_arguments=required_arguments)
3293
+
3294
+ def list_work_request_errors(self, work_request_id, **kwargs):
3295
+ """
3296
+ **ListWorkRequestErrors**
3297
+
3298
+ Lists the errors for a work request.
3299
+
3300
+
3301
+ :param str work_request_id: (required)
3302
+ The `OCID`__ of the asynchronous work request.
3303
+
3304
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3305
+
3306
+ :param str opc_request_id: (optional)
3307
+ Unique Oracle-assigned identifier for the request. If you need to contact
3308
+ Oracle about a particular request, please provide the request ID.
3309
+ The only valid characters for request IDs are letters, numbers,
3310
+ underscore, and dash.
3311
+
3312
+ :param str page: (optional)
3313
+ For list pagination. The value of the opc-next-page response header from the previous
3314
+ \"List\" call. For important details about how pagination works, see
3315
+ `List Pagination`__.
3316
+
3317
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3318
+
3319
+ :param int limit: (optional)
3320
+ For list pagination. The maximum number of results per page, or items to return in a
3321
+ paginated \"List\" call. For important details about how pagination works, see
3322
+ `List Pagination`__.
3323
+
3324
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3325
+
3326
+ :param str sort_by: (optional)
3327
+ The field to sort by. Only one sort order may be provided. Default order for `timestamp` is descending.
3328
+
3329
+ Allowed values are: "timestamp"
3330
+
3331
+ :param str sort_order: (optional)
3332
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
3333
+
3334
+ Allowed values are: "ASC", "DESC"
3335
+
3336
+ :param obj retry_strategy: (optional)
3337
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3338
+
3339
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3340
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3341
+
3342
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3343
+
3344
+ :param bool allow_control_chars: (optional)
3345
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3346
+ By default, the response will not allow control characters in strings
3347
+
3348
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.WorkRequestErrorCollection`
3349
+ :rtype: :class:`~oci.response.Response`
3350
+
3351
+ :example:
3352
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_work_request_errors.py.html>`__ to see an example of how to use list_work_request_errors API.
3353
+ """
3354
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3355
+ required_arguments = ['workRequestId']
3356
+ resource_path = "/workRequests/{workRequestId}/errors"
3357
+ method = "GET"
3358
+ operation_name = "list_work_request_errors"
3359
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/WorkRequestError/ListWorkRequestErrors"
3360
+
3361
+ # Don't accept unknown kwargs
3362
+ expected_kwargs = [
3363
+ "allow_control_chars",
3364
+ "retry_strategy",
3365
+ "opc_request_id",
3366
+ "page",
3367
+ "limit",
3368
+ "sort_by",
3369
+ "sort_order"
3370
+ ]
3371
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3372
+ if extra_kwargs:
3373
+ raise ValueError(
3374
+ f"list_work_request_errors got unknown kwargs: {extra_kwargs!r}")
3375
+
3376
+ path_params = {
3377
+ "workRequestId": work_request_id
3378
+ }
3379
+
3380
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
3381
+
3382
+ for (k, v) in six.iteritems(path_params):
3383
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
3384
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
3385
+
3386
+ if 'sort_by' in kwargs:
3387
+ sort_by_allowed_values = ["timestamp"]
3388
+ if kwargs['sort_by'] not in sort_by_allowed_values:
3389
+ raise ValueError(
3390
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
3391
+ )
3392
+
3393
+ if 'sort_order' in kwargs:
3394
+ sort_order_allowed_values = ["ASC", "DESC"]
3395
+ if kwargs['sort_order'] not in sort_order_allowed_values:
3396
+ raise ValueError(
3397
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
3398
+ )
3399
+
3400
+ query_params = {
3401
+ "page": kwargs.get("page", missing),
3402
+ "limit": kwargs.get("limit", missing),
3403
+ "sortBy": kwargs.get("sort_by", missing),
3404
+ "sortOrder": kwargs.get("sort_order", missing)
3405
+ }
3406
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
3407
+
3408
+ header_params = {
3409
+ "accept": "application/json",
3410
+ "content-type": "application/json",
3411
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3412
+ }
3413
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3414
+
3415
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3416
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3417
+ client_retry_strategy=self.retry_strategy
3418
+ )
3419
+ if retry_strategy is None:
3420
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3421
+
3422
+ if retry_strategy:
3423
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3424
+ self.base_client.add_opc_client_retries_header(header_params)
3425
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3426
+ return retry_strategy.make_retrying_call(
3427
+ self.base_client.call_api,
3428
+ resource_path=resource_path,
3429
+ method=method,
3430
+ path_params=path_params,
3431
+ query_params=query_params,
3432
+ header_params=header_params,
3433
+ response_type="WorkRequestErrorCollection",
3434
+ allow_control_chars=kwargs.get('allow_control_chars'),
3435
+ operation_name=operation_name,
3436
+ api_reference_link=api_reference_link,
3437
+ required_arguments=required_arguments)
3438
+ else:
3439
+ return self.base_client.call_api(
3440
+ resource_path=resource_path,
3441
+ method=method,
3442
+ path_params=path_params,
3443
+ query_params=query_params,
3444
+ header_params=header_params,
3445
+ response_type="WorkRequestErrorCollection",
3446
+ allow_control_chars=kwargs.get('allow_control_chars'),
3447
+ operation_name=operation_name,
3448
+ api_reference_link=api_reference_link,
3449
+ required_arguments=required_arguments)
3450
+
3451
+ def list_work_request_logs(self, work_request_id, **kwargs):
3452
+ """
3453
+ **ListWorkRequestLogs**
3454
+
3455
+ Lists the logs for a work request.
3456
+
3457
+
3458
+ :param str work_request_id: (required)
3459
+ The `OCID`__ of the asynchronous work request.
3460
+
3461
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3462
+
3463
+ :param str opc_request_id: (optional)
3464
+ Unique Oracle-assigned identifier for the request. If you need to contact
3465
+ Oracle about a particular request, please provide the request ID.
3466
+ The only valid characters for request IDs are letters, numbers,
3467
+ underscore, and dash.
3468
+
3469
+ :param str page: (optional)
3470
+ For list pagination. The value of the opc-next-page response header from the previous
3471
+ \"List\" call. For important details about how pagination works, see
3472
+ `List Pagination`__.
3473
+
3474
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3475
+
3476
+ :param int limit: (optional)
3477
+ For list pagination. The maximum number of results per page, or items to return in a
3478
+ paginated \"List\" call. For important details about how pagination works, see
3479
+ `List Pagination`__.
3480
+
3481
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3482
+
3483
+ :param str sort_by: (optional)
3484
+ The field to sort by. Only one sort order may be provided. Default order for `timestamp` is descending.
3485
+
3486
+ Allowed values are: "timestamp"
3487
+
3488
+ :param str sort_order: (optional)
3489
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
3490
+
3491
+ Allowed values are: "ASC", "DESC"
3492
+
3493
+ :param obj retry_strategy: (optional)
3494
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3495
+
3496
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3497
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3498
+
3499
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3500
+
3501
+ :param bool allow_control_chars: (optional)
3502
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3503
+ By default, the response will not allow control characters in strings
3504
+
3505
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.WorkRequestLogEntryCollection`
3506
+ :rtype: :class:`~oci.response.Response`
3507
+
3508
+ :example:
3509
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_work_request_logs.py.html>`__ to see an example of how to use list_work_request_logs API.
3510
+ """
3511
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3512
+ required_arguments = ['workRequestId']
3513
+ resource_path = "/workRequests/{workRequestId}/logs"
3514
+ method = "GET"
3515
+ operation_name = "list_work_request_logs"
3516
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/WorkRequestLogEntry/ListWorkRequestLogs"
3517
+
3518
+ # Don't accept unknown kwargs
3519
+ expected_kwargs = [
3520
+ "allow_control_chars",
3521
+ "retry_strategy",
3522
+ "opc_request_id",
3523
+ "page",
3524
+ "limit",
3525
+ "sort_by",
3526
+ "sort_order"
3527
+ ]
3528
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3529
+ if extra_kwargs:
3530
+ raise ValueError(
3531
+ f"list_work_request_logs got unknown kwargs: {extra_kwargs!r}")
3532
+
3533
+ path_params = {
3534
+ "workRequestId": work_request_id
3535
+ }
3536
+
3537
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
3538
+
3539
+ for (k, v) in six.iteritems(path_params):
3540
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
3541
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
3542
+
3543
+ if 'sort_by' in kwargs:
3544
+ sort_by_allowed_values = ["timestamp"]
3545
+ if kwargs['sort_by'] not in sort_by_allowed_values:
3546
+ raise ValueError(
3547
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
3548
+ )
3549
+
3550
+ if 'sort_order' in kwargs:
3551
+ sort_order_allowed_values = ["ASC", "DESC"]
3552
+ if kwargs['sort_order'] not in sort_order_allowed_values:
3553
+ raise ValueError(
3554
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
3555
+ )
3556
+
3557
+ query_params = {
3558
+ "page": kwargs.get("page", missing),
3559
+ "limit": kwargs.get("limit", missing),
3560
+ "sortBy": kwargs.get("sort_by", missing),
3561
+ "sortOrder": kwargs.get("sort_order", missing)
3562
+ }
3563
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
3564
+
3565
+ header_params = {
3566
+ "accept": "application/json",
3567
+ "content-type": "application/json",
3568
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3569
+ }
3570
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3571
+
3572
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3573
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3574
+ client_retry_strategy=self.retry_strategy
3575
+ )
3576
+ if retry_strategy is None:
3577
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3578
+
3579
+ if retry_strategy:
3580
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3581
+ self.base_client.add_opc_client_retries_header(header_params)
3582
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3583
+ return retry_strategy.make_retrying_call(
3584
+ self.base_client.call_api,
3585
+ resource_path=resource_path,
3586
+ method=method,
3587
+ path_params=path_params,
3588
+ query_params=query_params,
3589
+ header_params=header_params,
3590
+ response_type="WorkRequestLogEntryCollection",
3591
+ allow_control_chars=kwargs.get('allow_control_chars'),
3592
+ operation_name=operation_name,
3593
+ api_reference_link=api_reference_link,
3594
+ required_arguments=required_arguments)
3595
+ else:
3596
+ return self.base_client.call_api(
3597
+ resource_path=resource_path,
3598
+ method=method,
3599
+ path_params=path_params,
3600
+ query_params=query_params,
3601
+ header_params=header_params,
3602
+ response_type="WorkRequestLogEntryCollection",
3603
+ allow_control_chars=kwargs.get('allow_control_chars'),
3604
+ operation_name=operation_name,
3605
+ api_reference_link=api_reference_link,
3606
+ required_arguments=required_arguments)
3607
+
3608
+ def list_work_requests(self, **kwargs):
3609
+ """
3610
+ **ListWorkRequests**
3611
+
3612
+ Lists the work requests in a compartment.
3613
+
3614
+
3615
+ :param str compartment_id: (optional)
3616
+ The `OCID`__ of the compartment in which to list resources.
3617
+
3618
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3619
+
3620
+ :param str work_request_id: (optional)
3621
+ The `OCID`__ of the asynchronous work request.
3622
+
3623
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3624
+
3625
+ :param str status: (optional)
3626
+ A filter to return only the resources that match the given lifecycle state.
3627
+
3628
+ Allowed values are: "ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"
3629
+
3630
+ :param str resource_id: (optional)
3631
+ The `OCID`__ of the resource affected by the work request.
3632
+
3633
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3634
+
3635
+ :param str opc_request_id: (optional)
3636
+ Unique Oracle-assigned identifier for the request. If you need to contact
3637
+ Oracle about a particular request, please provide the request ID.
3638
+ The only valid characters for request IDs are letters, numbers,
3639
+ underscore, and dash.
3640
+
3641
+ :param str page: (optional)
3642
+ For list pagination. The value of the opc-next-page response header from the previous
3643
+ \"List\" call. For important details about how pagination works, see
3644
+ `List Pagination`__.
3645
+
3646
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3647
+
3648
+ :param int limit: (optional)
3649
+ For list pagination. The maximum number of results per page, or items to return in a
3650
+ paginated \"List\" call. For important details about how pagination works, see
3651
+ `List Pagination`__.
3652
+
3653
+ __ https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine
3654
+
3655
+ :param str sort_order: (optional)
3656
+ The sort order to use, either ascending (`ASC`) or descending (`DESC`).
3657
+
3658
+ Allowed values are: "ASC", "DESC"
3659
+
3660
+ :param str sort_by: (optional)
3661
+ The field to sort by. Only one sort order may be provided. Default order for `timeAccepted` is descending.
3662
+
3663
+ Allowed values are: "timeAccepted"
3664
+
3665
+ :param obj retry_strategy: (optional)
3666
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3667
+
3668
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3669
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3670
+
3671
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3672
+
3673
+ :param bool allow_control_chars: (optional)
3674
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3675
+ By default, the response will not allow control characters in strings
3676
+
3677
+ :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.generative_ai_agent.models.WorkRequestSummaryCollection`
3678
+ :rtype: :class:`~oci.response.Response`
3679
+
3680
+ :example:
3681
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/list_work_requests.py.html>`__ to see an example of how to use list_work_requests API.
3682
+ """
3683
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3684
+ required_arguments = []
3685
+ resource_path = "/workRequests"
3686
+ method = "GET"
3687
+ operation_name = "list_work_requests"
3688
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/WorkRequest/ListWorkRequests"
3689
+
3690
+ # Don't accept unknown kwargs
3691
+ expected_kwargs = [
3692
+ "allow_control_chars",
3693
+ "retry_strategy",
3694
+ "compartment_id",
3695
+ "work_request_id",
3696
+ "status",
3697
+ "resource_id",
3698
+ "opc_request_id",
3699
+ "page",
3700
+ "limit",
3701
+ "sort_order",
3702
+ "sort_by"
3703
+ ]
3704
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3705
+ if extra_kwargs:
3706
+ raise ValueError(
3707
+ f"list_work_requests got unknown kwargs: {extra_kwargs!r}")
3708
+
3709
+ if 'status' in kwargs:
3710
+ status_allowed_values = ["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]
3711
+ if kwargs['status'] not in status_allowed_values:
3712
+ raise ValueError(
3713
+ f"Invalid value for `status`, must be one of { status_allowed_values }"
3714
+ )
3715
+
3716
+ if 'sort_order' in kwargs:
3717
+ sort_order_allowed_values = ["ASC", "DESC"]
3718
+ if kwargs['sort_order'] not in sort_order_allowed_values:
3719
+ raise ValueError(
3720
+ f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
3721
+ )
3722
+
3723
+ if 'sort_by' in kwargs:
3724
+ sort_by_allowed_values = ["timeAccepted"]
3725
+ if kwargs['sort_by'] not in sort_by_allowed_values:
3726
+ raise ValueError(
3727
+ f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
3728
+ )
3729
+
3730
+ query_params = {
3731
+ "compartmentId": kwargs.get("compartment_id", missing),
3732
+ "workRequestId": kwargs.get("work_request_id", missing),
3733
+ "status": kwargs.get("status", missing),
3734
+ "resourceId": kwargs.get("resource_id", missing),
3735
+ "page": kwargs.get("page", missing),
3736
+ "limit": kwargs.get("limit", missing),
3737
+ "sortOrder": kwargs.get("sort_order", missing),
3738
+ "sortBy": kwargs.get("sort_by", missing)
3739
+ }
3740
+ query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
3741
+
3742
+ header_params = {
3743
+ "accept": "application/json",
3744
+ "content-type": "application/json",
3745
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3746
+ }
3747
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3748
+
3749
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3750
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3751
+ client_retry_strategy=self.retry_strategy
3752
+ )
3753
+ if retry_strategy is None:
3754
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3755
+
3756
+ if retry_strategy:
3757
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3758
+ self.base_client.add_opc_client_retries_header(header_params)
3759
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3760
+ return retry_strategy.make_retrying_call(
3761
+ self.base_client.call_api,
3762
+ resource_path=resource_path,
3763
+ method=method,
3764
+ query_params=query_params,
3765
+ header_params=header_params,
3766
+ response_type="WorkRequestSummaryCollection",
3767
+ allow_control_chars=kwargs.get('allow_control_chars'),
3768
+ operation_name=operation_name,
3769
+ api_reference_link=api_reference_link,
3770
+ required_arguments=required_arguments)
3771
+ else:
3772
+ return self.base_client.call_api(
3773
+ resource_path=resource_path,
3774
+ method=method,
3775
+ query_params=query_params,
3776
+ header_params=header_params,
3777
+ response_type="WorkRequestSummaryCollection",
3778
+ allow_control_chars=kwargs.get('allow_control_chars'),
3779
+ operation_name=operation_name,
3780
+ api_reference_link=api_reference_link,
3781
+ required_arguments=required_arguments)
3782
+
3783
+ def update_agent(self, agent_id, update_agent_details, **kwargs):
3784
+ """
3785
+ **UpdateAgent**
3786
+
3787
+ Updates an agent.
3788
+
3789
+
3790
+ :param str agent_id: (required)
3791
+ The `OCID`__ of the agent.
3792
+
3793
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3794
+
3795
+ :param oci.generative_ai_agent.models.UpdateAgentDetails update_agent_details: (required)
3796
+ The information to be updated.
3797
+
3798
+ :param str if_match: (optional)
3799
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
3800
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
3801
+ that resource. The resource will be updated or deleted only if the etag you provide
3802
+ matches the resource's current etag value.
3803
+
3804
+ :param str opc_request_id: (optional)
3805
+ Unique Oracle-assigned identifier for the request. If you need to contact
3806
+ Oracle about a particular request, please provide the request ID.
3807
+ The only valid characters for request IDs are letters, numbers,
3808
+ underscore, and dash.
3809
+
3810
+ :param obj retry_strategy: (optional)
3811
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3812
+
3813
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3814
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3815
+
3816
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3817
+
3818
+ :param bool allow_control_chars: (optional)
3819
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3820
+ By default, the response will not allow control characters in strings
3821
+
3822
+ :return: A :class:`~oci.response.Response` object with data of type None
3823
+ :rtype: :class:`~oci.response.Response`
3824
+
3825
+ :example:
3826
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/update_agent.py.html>`__ to see an example of how to use update_agent API.
3827
+ """
3828
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3829
+ required_arguments = ['agentId']
3830
+ resource_path = "/agents/{agentId}"
3831
+ method = "PUT"
3832
+ operation_name = "update_agent"
3833
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/Agent/UpdateAgent"
3834
+
3835
+ # Don't accept unknown kwargs
3836
+ expected_kwargs = [
3837
+ "allow_control_chars",
3838
+ "retry_strategy",
3839
+ "if_match",
3840
+ "opc_request_id"
3841
+ ]
3842
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3843
+ if extra_kwargs:
3844
+ raise ValueError(
3845
+ f"update_agent got unknown kwargs: {extra_kwargs!r}")
3846
+
3847
+ path_params = {
3848
+ "agentId": agent_id
3849
+ }
3850
+
3851
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
3852
+
3853
+ for (k, v) in six.iteritems(path_params):
3854
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
3855
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
3856
+
3857
+ header_params = {
3858
+ "accept": "application/json",
3859
+ "content-type": "application/json",
3860
+ "if-match": kwargs.get("if_match", missing),
3861
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3862
+ }
3863
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3864
+
3865
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3866
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3867
+ client_retry_strategy=self.retry_strategy
3868
+ )
3869
+ if retry_strategy is None:
3870
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3871
+
3872
+ if retry_strategy:
3873
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3874
+ self.base_client.add_opc_client_retries_header(header_params)
3875
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3876
+ return retry_strategy.make_retrying_call(
3877
+ self.base_client.call_api,
3878
+ resource_path=resource_path,
3879
+ method=method,
3880
+ path_params=path_params,
3881
+ header_params=header_params,
3882
+ body=update_agent_details,
3883
+ allow_control_chars=kwargs.get('allow_control_chars'),
3884
+ operation_name=operation_name,
3885
+ api_reference_link=api_reference_link,
3886
+ required_arguments=required_arguments)
3887
+ else:
3888
+ return self.base_client.call_api(
3889
+ resource_path=resource_path,
3890
+ method=method,
3891
+ path_params=path_params,
3892
+ header_params=header_params,
3893
+ body=update_agent_details,
3894
+ allow_control_chars=kwargs.get('allow_control_chars'),
3895
+ operation_name=operation_name,
3896
+ api_reference_link=api_reference_link,
3897
+ required_arguments=required_arguments)
3898
+
3899
+ def update_agent_endpoint(self, agent_endpoint_id, update_agent_endpoint_details, **kwargs):
3900
+ """
3901
+ **UpdateAgentEndpoint**
3902
+
3903
+ Updates an endpoint.
3904
+
3905
+
3906
+ :param str agent_endpoint_id: (required)
3907
+ The `OCID`__ of the endpoint.
3908
+
3909
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
3910
+
3911
+ :param oci.generative_ai_agent.models.UpdateAgentEndpointDetails update_agent_endpoint_details: (required)
3912
+ The information to be updated.
3913
+
3914
+ :param str if_match: (optional)
3915
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
3916
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
3917
+ that resource. The resource will be updated or deleted only if the etag you provide
3918
+ matches the resource's current etag value.
3919
+
3920
+ :param str opc_request_id: (optional)
3921
+ Unique Oracle-assigned identifier for the request. If you need to contact
3922
+ Oracle about a particular request, please provide the request ID.
3923
+ The only valid characters for request IDs are letters, numbers,
3924
+ underscore, and dash.
3925
+
3926
+ :param obj retry_strategy: (optional)
3927
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
3928
+
3929
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
3930
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
3931
+
3932
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
3933
+
3934
+ :param bool allow_control_chars: (optional)
3935
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
3936
+ By default, the response will not allow control characters in strings
3937
+
3938
+ :return: A :class:`~oci.response.Response` object with data of type None
3939
+ :rtype: :class:`~oci.response.Response`
3940
+
3941
+ :example:
3942
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/update_agent_endpoint.py.html>`__ to see an example of how to use update_agent_endpoint API.
3943
+ """
3944
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
3945
+ required_arguments = ['agentEndpointId']
3946
+ resource_path = "/agentEndpoints/{agentEndpointId}"
3947
+ method = "PUT"
3948
+ operation_name = "update_agent_endpoint"
3949
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/AgentEndpoint/UpdateAgentEndpoint"
3950
+
3951
+ # Don't accept unknown kwargs
3952
+ expected_kwargs = [
3953
+ "allow_control_chars",
3954
+ "retry_strategy",
3955
+ "if_match",
3956
+ "opc_request_id"
3957
+ ]
3958
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
3959
+ if extra_kwargs:
3960
+ raise ValueError(
3961
+ f"update_agent_endpoint got unknown kwargs: {extra_kwargs!r}")
3962
+
3963
+ path_params = {
3964
+ "agentEndpointId": agent_endpoint_id
3965
+ }
3966
+
3967
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
3968
+
3969
+ for (k, v) in six.iteritems(path_params):
3970
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
3971
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
3972
+
3973
+ header_params = {
3974
+ "accept": "application/json",
3975
+ "content-type": "application/json",
3976
+ "if-match": kwargs.get("if_match", missing),
3977
+ "opc-request-id": kwargs.get("opc_request_id", missing)
3978
+ }
3979
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
3980
+
3981
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
3982
+ operation_retry_strategy=kwargs.get('retry_strategy'),
3983
+ client_retry_strategy=self.retry_strategy
3984
+ )
3985
+ if retry_strategy is None:
3986
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
3987
+
3988
+ if retry_strategy:
3989
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
3990
+ self.base_client.add_opc_client_retries_header(header_params)
3991
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
3992
+ return retry_strategy.make_retrying_call(
3993
+ self.base_client.call_api,
3994
+ resource_path=resource_path,
3995
+ method=method,
3996
+ path_params=path_params,
3997
+ header_params=header_params,
3998
+ body=update_agent_endpoint_details,
3999
+ allow_control_chars=kwargs.get('allow_control_chars'),
4000
+ operation_name=operation_name,
4001
+ api_reference_link=api_reference_link,
4002
+ required_arguments=required_arguments)
4003
+ else:
4004
+ return self.base_client.call_api(
4005
+ resource_path=resource_path,
4006
+ method=method,
4007
+ path_params=path_params,
4008
+ header_params=header_params,
4009
+ body=update_agent_endpoint_details,
4010
+ allow_control_chars=kwargs.get('allow_control_chars'),
4011
+ operation_name=operation_name,
4012
+ api_reference_link=api_reference_link,
4013
+ required_arguments=required_arguments)
4014
+
4015
+ def update_data_source(self, data_source_id, update_data_source_details, **kwargs):
4016
+ """
4017
+ **UpdateDataSource**
4018
+
4019
+ Updates a data source.
4020
+
4021
+
4022
+ :param str data_source_id: (required)
4023
+ The `OCID`__ of the data source.
4024
+
4025
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
4026
+
4027
+ :param oci.generative_ai_agent.models.UpdateDataSourceDetails update_data_source_details: (required)
4028
+ The data source information to be updated.
4029
+
4030
+ :param str if_match: (optional)
4031
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
4032
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
4033
+ that resource. The resource will be updated or deleted only if the etag you provide
4034
+ matches the resource's current etag value.
4035
+
4036
+ :param str opc_request_id: (optional)
4037
+ Unique Oracle-assigned identifier for the request. If you need to contact
4038
+ Oracle about a particular request, please provide the request ID.
4039
+ The only valid characters for request IDs are letters, numbers,
4040
+ underscore, and dash.
4041
+
4042
+ :param obj retry_strategy: (optional)
4043
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
4044
+
4045
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
4046
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
4047
+
4048
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
4049
+
4050
+ :param bool allow_control_chars: (optional)
4051
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
4052
+ By default, the response will not allow control characters in strings
4053
+
4054
+ :return: A :class:`~oci.response.Response` object with data of type None
4055
+ :rtype: :class:`~oci.response.Response`
4056
+
4057
+ :example:
4058
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/update_data_source.py.html>`__ to see an example of how to use update_data_source API.
4059
+ """
4060
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
4061
+ required_arguments = ['dataSourceId']
4062
+ resource_path = "/dataSources/{dataSourceId}"
4063
+ method = "PUT"
4064
+ operation_name = "update_data_source"
4065
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/DataSource/UpdateDataSource"
4066
+
4067
+ # Don't accept unknown kwargs
4068
+ expected_kwargs = [
4069
+ "allow_control_chars",
4070
+ "retry_strategy",
4071
+ "if_match",
4072
+ "opc_request_id"
4073
+ ]
4074
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
4075
+ if extra_kwargs:
4076
+ raise ValueError(
4077
+ f"update_data_source got unknown kwargs: {extra_kwargs!r}")
4078
+
4079
+ path_params = {
4080
+ "dataSourceId": data_source_id
4081
+ }
4082
+
4083
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
4084
+
4085
+ for (k, v) in six.iteritems(path_params):
4086
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
4087
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
4088
+
4089
+ header_params = {
4090
+ "accept": "application/json",
4091
+ "content-type": "application/json",
4092
+ "if-match": kwargs.get("if_match", missing),
4093
+ "opc-request-id": kwargs.get("opc_request_id", missing)
4094
+ }
4095
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
4096
+
4097
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
4098
+ operation_retry_strategy=kwargs.get('retry_strategy'),
4099
+ client_retry_strategy=self.retry_strategy
4100
+ )
4101
+ if retry_strategy is None:
4102
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
4103
+
4104
+ if retry_strategy:
4105
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
4106
+ self.base_client.add_opc_client_retries_header(header_params)
4107
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
4108
+ return retry_strategy.make_retrying_call(
4109
+ self.base_client.call_api,
4110
+ resource_path=resource_path,
4111
+ method=method,
4112
+ path_params=path_params,
4113
+ header_params=header_params,
4114
+ body=update_data_source_details,
4115
+ allow_control_chars=kwargs.get('allow_control_chars'),
4116
+ operation_name=operation_name,
4117
+ api_reference_link=api_reference_link,
4118
+ required_arguments=required_arguments)
4119
+ else:
4120
+ return self.base_client.call_api(
4121
+ resource_path=resource_path,
4122
+ method=method,
4123
+ path_params=path_params,
4124
+ header_params=header_params,
4125
+ body=update_data_source_details,
4126
+ allow_control_chars=kwargs.get('allow_control_chars'),
4127
+ operation_name=operation_name,
4128
+ api_reference_link=api_reference_link,
4129
+ required_arguments=required_arguments)
4130
+
4131
+ def update_knowledge_base(self, knowledge_base_id, update_knowledge_base_details, **kwargs):
4132
+ """
4133
+ **UpdateKnowledgeBase**
4134
+
4135
+ Updates a knowledge base.
4136
+
4137
+
4138
+ :param str knowledge_base_id: (required)
4139
+ The `OCID`__ of the knowledge base.
4140
+
4141
+ __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
4142
+
4143
+ :param oci.generative_ai_agent.models.UpdateKnowledgeBaseDetails update_knowledge_base_details: (required)
4144
+ The information to be updated.
4145
+
4146
+ :param str if_match: (optional)
4147
+ For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
4148
+ `if-match` parameter to the value of the etag from a previous GET or POST response for
4149
+ that resource. The resource will be updated or deleted only if the etag you provide
4150
+ matches the resource's current etag value.
4151
+
4152
+ :param str opc_request_id: (optional)
4153
+ Unique Oracle-assigned identifier for the request. If you need to contact
4154
+ Oracle about a particular request, please provide the request ID.
4155
+ The only valid characters for request IDs are letters, numbers,
4156
+ underscore, and dash.
4157
+
4158
+ :param obj retry_strategy: (optional)
4159
+ A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
4160
+
4161
+ This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
4162
+ The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
4163
+
4164
+ To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
4165
+
4166
+ :param bool allow_control_chars: (optional)
4167
+ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
4168
+ By default, the response will not allow control characters in strings
4169
+
4170
+ :return: A :class:`~oci.response.Response` object with data of type None
4171
+ :rtype: :class:`~oci.response.Response`
4172
+
4173
+ :example:
4174
+ Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.1/generativeaiagent/update_knowledge_base.py.html>`__ to see an example of how to use update_knowledge_base API.
4175
+ """
4176
+ # Required path and query arguments. These are in camelCase to replace values in service endpoints.
4177
+ required_arguments = ['knowledgeBaseId']
4178
+ resource_path = "/knowledgeBases/{knowledgeBaseId}"
4179
+ method = "PUT"
4180
+ operation_name = "update_knowledge_base"
4181
+ api_reference_link = "https://docs.oracle.com/iaas/api/#/en/generative-ai-agents/20240531/KnowledgeBase/UpdateKnowledgeBase"
4182
+
4183
+ # Don't accept unknown kwargs
4184
+ expected_kwargs = [
4185
+ "allow_control_chars",
4186
+ "retry_strategy",
4187
+ "if_match",
4188
+ "opc_request_id"
4189
+ ]
4190
+ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
4191
+ if extra_kwargs:
4192
+ raise ValueError(
4193
+ f"update_knowledge_base got unknown kwargs: {extra_kwargs!r}")
4194
+
4195
+ path_params = {
4196
+ "knowledgeBaseId": knowledge_base_id
4197
+ }
4198
+
4199
+ path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
4200
+
4201
+ for (k, v) in six.iteritems(path_params):
4202
+ if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
4203
+ raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
4204
+
4205
+ header_params = {
4206
+ "accept": "application/json",
4207
+ "content-type": "application/json",
4208
+ "if-match": kwargs.get("if_match", missing),
4209
+ "opc-request-id": kwargs.get("opc_request_id", missing)
4210
+ }
4211
+ header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
4212
+
4213
+ retry_strategy = self.base_client.get_preferred_retry_strategy(
4214
+ operation_retry_strategy=kwargs.get('retry_strategy'),
4215
+ client_retry_strategy=self.retry_strategy
4216
+ )
4217
+ if retry_strategy is None:
4218
+ retry_strategy = retry.DEFAULT_RETRY_STRATEGY
4219
+
4220
+ if retry_strategy:
4221
+ if not isinstance(retry_strategy, retry.NoneRetryStrategy):
4222
+ self.base_client.add_opc_client_retries_header(header_params)
4223
+ retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
4224
+ return retry_strategy.make_retrying_call(
4225
+ self.base_client.call_api,
4226
+ resource_path=resource_path,
4227
+ method=method,
4228
+ path_params=path_params,
4229
+ header_params=header_params,
4230
+ body=update_knowledge_base_details,
4231
+ allow_control_chars=kwargs.get('allow_control_chars'),
4232
+ operation_name=operation_name,
4233
+ api_reference_link=api_reference_link,
4234
+ required_arguments=required_arguments)
4235
+ else:
4236
+ return self.base_client.call_api(
4237
+ resource_path=resource_path,
4238
+ method=method,
4239
+ path_params=path_params,
4240
+ header_params=header_params,
4241
+ body=update_knowledge_base_details,
4242
+ allow_control_chars=kwargs.get('allow_control_chars'),
4243
+ operation_name=operation_name,
4244
+ api_reference_link=api_reference_link,
4245
+ required_arguments=required_arguments)