composio 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (270) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +11 -0
  3. data/Gemfile.lock +93 -0
  4. data/README.md +1779 -0
  5. data/Rakefile +10 -0
  6. data/composio.gemspec +39 -0
  7. data/header.png +0 -0
  8. data/lib/composio/api/actions_api.rb +1062 -0
  9. data/lib/composio/api/api_keys_api.rb +268 -0
  10. data/lib/composio/api/apps_api.rb +266 -0
  11. data/lib/composio/api/auth_api.rb +370 -0
  12. data/lib/composio/api/cli_api.rb +266 -0
  13. data/lib/composio/api/connections_api.rb +591 -0
  14. data/lib/composio/api/integrations_api.rb +578 -0
  15. data/lib/composio/api/logs_api.rb +166 -0
  16. data/lib/composio/api/metadata_api.rb +180 -0
  17. data/lib/composio/api/team_api.rb +188 -0
  18. data/lib/composio/api/triggers_api.rb +1222 -0
  19. data/lib/composio/api_client.rb +436 -0
  20. data/lib/composio/api_client_custom.rb +14 -0
  21. data/lib/composio/api_error.rb +53 -0
  22. data/lib/composio/configuration.rb +330 -0
  23. data/lib/composio/models/action_details.rb +357 -0
  24. data/lib/composio/models/action_details_minimal.rb +329 -0
  25. data/lib/composio/models/action_execution_req_dto.rb +260 -0
  26. data/lib/composio/models/action_execution_res_dto.rb +238 -0
  27. data/lib/composio/models/action_log_data.rb +345 -0
  28. data/lib/composio/models/action_metadata.rb +402 -0
  29. data/lib/composio/models/action_metadata_type.rb +101 -0
  30. data/lib/composio/models/actions_controller_v1.rb +222 -0
  31. data/lib/composio/models/actions_list_response_dto.rb +250 -0
  32. data/lib/composio/models/actions_minimal_list_response_dto.rb +250 -0
  33. data/lib/composio/models/actions_query_dto.rb +300 -0
  34. data/lib/composio/models/active_trigger_instance.rb +311 -0
  35. data/lib/composio/models/active_triggers_res_dto.rb +238 -0
  36. data/lib/composio/models/add_repo_url_req_dto.rb +221 -0
  37. data/lib/composio/models/add_repo_url_res_dto.rb +221 -0
  38. data/lib/composio/models/add_tools_req_dto.rb +251 -0
  39. data/lib/composio/models/add_tools_request_dto.rb +251 -0
  40. data/lib/composio/models/api_key_res_dto.rb +323 -0
  41. data/lib/composio/models/app_info_response_dto.rb +323 -0
  42. data/lib/composio/models/app_list_res_dto.rb +238 -0
  43. data/lib/composio/models/app_query_dto.rb +216 -0
  44. data/lib/composio/models/auth_config_dto.rb +229 -0
  45. data/lib/composio/models/cli_query_dto.rb +231 -0
  46. data/lib/composio/models/connected_account_response_dto.rb +331 -0
  47. data/lib/composio/models/connection_params.rb +395 -0
  48. data/lib/composio/models/connection_params_for_account.rb +323 -0
  49. data/lib/composio/models/connection_params_headers.rb +224 -0
  50. data/lib/composio/models/connection_with_app_data.rb +358 -0
  51. data/lib/composio/models/connection_with_app_data_created_at.rb +101 -0
  52. data/lib/composio/models/connector_list_item_dto.rb +376 -0
  53. data/lib/composio/models/connector_list_item_dto_created_at.rb +102 -0
  54. data/lib/composio/models/connector_list_item_dto_updated_at.rb +102 -0
  55. data/lib/composio/models/create_connector_payload_dto.rb +274 -0
  56. data/lib/composio/models/create_connector_payload_dto_use_composio_auth.rb +226 -0
  57. data/lib/composio/models/delete_api_key_req_dto.rb +221 -0
  58. data/lib/composio/models/delete_api_key_response_dto.rb +221 -0
  59. data/lib/composio/models/delete_row_apidto.rb +236 -0
  60. data/lib/composio/models/delete_tools_req_dto.rb +221 -0
  61. data/lib/composio/models/delete_tools_res_dto.rb +221 -0
  62. data/lib/composio/models/direct_execute_req_dto.rb +262 -0
  63. data/lib/composio/models/enable_trigger_body_dto.rb +221 -0
  64. data/lib/composio/models/enable_trigger_params_dto.rb +236 -0
  65. data/lib/composio/models/execute_action_res_dto.rb +236 -0
  66. data/lib/composio/models/generate_api_key_req_dto.rb +221 -0
  67. data/lib/composio/models/generate_cli_session_req_dto.rb +221 -0
  68. data/lib/composio/models/generate_cli_session_res_dto.rb +221 -0
  69. data/lib/composio/models/get_active_triggers_query_dto.rb +276 -0
  70. data/lib/composio/models/get_cli_session_res_dto.rb +236 -0
  71. data/lib/composio/models/get_connections_query_dto.rb +287 -0
  72. data/lib/composio/models/get_connections_response_dto.rb +250 -0
  73. data/lib/composio/models/get_connections_result.rb +236 -0
  74. data/lib/composio/models/get_connector_info_res_dto.rb +417 -0
  75. data/lib/composio/models/get_connector_list_res_dto.rb +253 -0
  76. data/lib/composio/models/get_logs_dto.rb +288 -0
  77. data/lib/composio/models/get_logs_query_dto.rb +246 -0
  78. data/lib/composio/models/get_trigger_params_dto.rb +221 -0
  79. data/lib/composio/models/get_trigger_response_dto.rb +230 -0
  80. data/lib/composio/models/handle_trigger_body_dto.rb +221 -0
  81. data/lib/composio/models/handle_trigger_params_dto.rb +236 -0
  82. data/lib/composio/models/identify_client_req_dto.rb +231 -0
  83. data/lib/composio/models/identify_client_res_dto.rb +251 -0
  84. data/lib/composio/models/initiate_connection_payload_dto.rb +281 -0
  85. data/lib/composio/models/initiate_connection_response.rb +272 -0
  86. data/lib/composio/models/invite_member_req_dto.rb +251 -0
  87. data/lib/composio/models/job_status.rb +37 -0
  88. data/lib/composio/models/list_triggers_query_dto.rb +246 -0
  89. data/lib/composio/models/logout_res_dto.rb +221 -0
  90. data/lib/composio/models/logs_res_dto.rb +233 -0
  91. data/lib/composio/models/magic_link_req_dto.rb +236 -0
  92. data/lib/composio/models/magic_link_res_dto.rb +220 -0
  93. data/lib/composio/models/member_res_dto.rb +305 -0
  94. data/lib/composio/models/meta.rb +220 -0
  95. data/lib/composio/models/meta_app.rb +220 -0
  96. data/lib/composio/models/metadata_query_dto.rb +221 -0
  97. data/lib/composio/models/metadata_req_dto.rb +232 -0
  98. data/lib/composio/models/o_auth2_callback_query_dto.rb +220 -0
  99. data/lib/composio/models/open_api_spec_list_res_dto.rb +436 -0
  100. data/lib/composio/models/page_info.rb +338 -0
  101. data/lib/composio/models/page_info_dto.rb +248 -0
  102. data/lib/composio/models/patch_connector_req_dto.rb +226 -0
  103. data/lib/composio/models/patch_connector_res_dto.rb +221 -0
  104. data/lib/composio/models/proxy_execution_req_dto.rb +234 -0
  105. data/lib/composio/models/redirect_uri_dto.rb +215 -0
  106. data/lib/composio/models/set_callback_url_body_dto.rb +221 -0
  107. data/lib/composio/models/single_app_info_res_dto.rb +394 -0
  108. data/lib/composio/models/single_trigger_res_dto.rb +336 -0
  109. data/lib/composio/models/status.rb +37 -0
  110. data/lib/composio/models/switch_trigger_status_body_dto.rb +221 -0
  111. data/lib/composio/models/switch_trigger_status_params_dto.rb +221 -0
  112. data/lib/composio/models/time.rb +41 -0
  113. data/lib/composio/models/toggle_connected_account_response_dto.rb +220 -0
  114. data/lib/composio/models/toggle_trigger_state_response_dto.rb +220 -0
  115. data/lib/composio/models/tools_execute_req_dto.rb +275 -0
  116. data/lib/composio/models/track_client_req_dto.rb +240 -0
  117. data/lib/composio/models/track_client_res_dto.rb +221 -0
  118. data/lib/composio/models/trigger_config.rb +237 -0
  119. data/lib/composio/models/trigger_instance_params_dto.rb +221 -0
  120. data/lib/composio/models/trigger_log_data.rb +345 -0
  121. data/lib/composio/models/trigger_log_item_dto.rb +336 -0
  122. data/lib/composio/models/trigger_logs_res_dto.rb +236 -0
  123. data/lib/composio/models/trigger_metadata.rb +402 -0
  124. data/lib/composio/models/trigger_metadata_dto.rb +347 -0
  125. data/lib/composio/models/trigger_metadata_type.rb +101 -0
  126. data/lib/composio/models/trigger_res_dto.rb +361 -0
  127. data/lib/composio/models/trigger_response_dto.rb +241 -0
  128. data/lib/composio/models/trigger_toggle_info_response_dto.rb +221 -0
  129. data/lib/composio/models/triggers_enabled_toggle_req_dto.rb +221 -0
  130. data/lib/composio/models/triggers_enabled_toggle_res_dto.rb +221 -0
  131. data/lib/composio/models/type.rb +37 -0
  132. data/lib/composio/models/user_git_user_info.rb +230 -0
  133. data/lib/composio/models/verify_cli_code_res_dto.rb +251 -0
  134. data/lib/composio/models/verify_magic_link_data_dto.rb +263 -0
  135. data/lib/composio/models/verify_magic_link_req_dto.rb +221 -0
  136. data/lib/composio/models/verify_magic_link_res_dto.rb +230 -0
  137. data/lib/composio/models/webhook_url_response_dto.rb +231 -0
  138. data/lib/composio/version.rb +11 -0
  139. data/lib/composio.rb +214 -0
  140. data/spec/api/actions_api_spec.rb +164 -0
  141. data/spec/api/api_keys_api_spec.rb +61 -0
  142. data/spec/api/apps_api_spec.rb +63 -0
  143. data/spec/api/auth_api_spec.rb +73 -0
  144. data/spec/api/cli_api_spec.rb +63 -0
  145. data/spec/api/connections_api_spec.rb +103 -0
  146. data/spec/api/integrations_api_spec.rb +96 -0
  147. data/spec/api/logs_api_spec.rb +48 -0
  148. data/spec/api/metadata_api_spec.rb +50 -0
  149. data/spec/api/team_api_spec.rb +50 -0
  150. data/spec/api/triggers_api_spec.rb +188 -0
  151. data/spec/api_client_spec.rb +191 -0
  152. data/spec/configuration_spec.rb +38 -0
  153. data/spec/models/action_details_minimal_spec.rb +76 -0
  154. data/spec/models/action_details_spec.rb +88 -0
  155. data/spec/models/action_execution_req_dto_spec.rb +58 -0
  156. data/spec/models/action_execution_res_dto_spec.rb +40 -0
  157. data/spec/models/action_log_data_spec.rb +70 -0
  158. data/spec/models/action_metadata_spec.rb +88 -0
  159. data/spec/models/action_metadata_type_spec.rb +25 -0
  160. data/spec/models/actions_controller_v1_spec.rb +28 -0
  161. data/spec/models/actions_list_response_dto_spec.rb +40 -0
  162. data/spec/models/actions_minimal_list_response_dto_spec.rb +40 -0
  163. data/spec/models/actions_query_dto_spec.rb +82 -0
  164. data/spec/models/active_trigger_instance_spec.rb +70 -0
  165. data/spec/models/active_triggers_res_dto_spec.rb +34 -0
  166. data/spec/models/add_repo_url_req_dto_spec.rb +28 -0
  167. data/spec/models/add_repo_url_res_dto_spec.rb +28 -0
  168. data/spec/models/add_tools_req_dto_spec.rb +40 -0
  169. data/spec/models/add_tools_request_dto_spec.rb +40 -0
  170. data/spec/models/api_key_res_dto_spec.rb +52 -0
  171. data/spec/models/app_info_response_dto_spec.rb +70 -0
  172. data/spec/models/app_list_res_dto_spec.rb +34 -0
  173. data/spec/models/app_query_dto_spec.rb +28 -0
  174. data/spec/models/auth_config_dto_spec.rb +34 -0
  175. data/spec/models/cli_query_dto_spec.rb +34 -0
  176. data/spec/models/connected_account_response_dto_spec.rb +82 -0
  177. data/spec/models/connection_params_for_account_spec.rb +100 -0
  178. data/spec/models/connection_params_headers_spec.rb +34 -0
  179. data/spec/models/connection_params_spec.rb +118 -0
  180. data/spec/models/connection_with_app_data_created_at_spec.rb +25 -0
  181. data/spec/models/connection_with_app_data_spec.rb +100 -0
  182. data/spec/models/connector_list_item_dto_created_at_spec.rb +25 -0
  183. data/spec/models/connector_list_item_dto_spec.rb +94 -0
  184. data/spec/models/connector_list_item_dto_updated_at_spec.rb +25 -0
  185. data/spec/models/create_connector_payload_dto_spec.rb +58 -0
  186. data/spec/models/create_connector_payload_dto_use_composio_auth_spec.rb +22 -0
  187. data/spec/models/delete_api_key_req_dto_spec.rb +28 -0
  188. data/spec/models/delete_api_key_response_dto_spec.rb +28 -0
  189. data/spec/models/delete_row_apidto_spec.rb +34 -0
  190. data/spec/models/delete_tools_req_dto_spec.rb +28 -0
  191. data/spec/models/delete_tools_res_dto_spec.rb +28 -0
  192. data/spec/models/direct_execute_req_dto_spec.rb +46 -0
  193. data/spec/models/enable_trigger_body_dto_spec.rb +28 -0
  194. data/spec/models/enable_trigger_params_dto_spec.rb +34 -0
  195. data/spec/models/execute_action_res_dto_spec.rb +34 -0
  196. data/spec/models/generate_api_key_req_dto_spec.rb +28 -0
  197. data/spec/models/generate_cli_session_req_dto_spec.rb +28 -0
  198. data/spec/models/generate_cli_session_res_dto_spec.rb +28 -0
  199. data/spec/models/get_active_triggers_query_dto_spec.rb +64 -0
  200. data/spec/models/get_cli_session_res_dto_spec.rb +34 -0
  201. data/spec/models/get_connections_query_dto_spec.rb +76 -0
  202. data/spec/models/get_connections_response_dto_spec.rb +40 -0
  203. data/spec/models/get_connections_result_spec.rb +34 -0
  204. data/spec/models/get_connector_info_res_dto_spec.rb +106 -0
  205. data/spec/models/get_connector_list_res_dto_spec.rb +40 -0
  206. data/spec/models/get_logs_dto_spec.rb +70 -0
  207. data/spec/models/get_logs_query_dto_spec.rb +46 -0
  208. data/spec/models/get_trigger_params_dto_spec.rb +28 -0
  209. data/spec/models/get_trigger_response_dto_spec.rb +34 -0
  210. data/spec/models/handle_trigger_body_dto_spec.rb +28 -0
  211. data/spec/models/handle_trigger_params_dto_spec.rb +34 -0
  212. data/spec/models/identify_client_req_dto_spec.rb +34 -0
  213. data/spec/models/identify_client_res_dto_spec.rb +40 -0
  214. data/spec/models/initiate_connection_payload_dto_spec.rb +46 -0
  215. data/spec/models/initiate_connection_response_spec.rb +34 -0
  216. data/spec/models/invite_member_req_dto_spec.rb +40 -0
  217. data/spec/models/job_status_spec.rb +22 -0
  218. data/spec/models/list_triggers_query_dto_spec.rb +46 -0
  219. data/spec/models/logout_res_dto_spec.rb +28 -0
  220. data/spec/models/logs_res_dto_spec.rb +34 -0
  221. data/spec/models/magic_link_req_dto_spec.rb +34 -0
  222. data/spec/models/magic_link_res_dto_spec.rb +28 -0
  223. data/spec/models/member_res_dto_spec.rb +52 -0
  224. data/spec/models/meta_app_spec.rb +28 -0
  225. data/spec/models/meta_spec.rb +28 -0
  226. data/spec/models/metadata_query_dto_spec.rb +28 -0
  227. data/spec/models/metadata_req_dto_spec.rb +34 -0
  228. data/spec/models/o_auth2_callback_query_dto_spec.rb +28 -0
  229. data/spec/models/open_api_spec_list_res_dto_spec.rb +94 -0
  230. data/spec/models/page_info_dto_spec.rb +40 -0
  231. data/spec/models/page_info_spec.rb +46 -0
  232. data/spec/models/patch_connector_req_dto_spec.rb +34 -0
  233. data/spec/models/patch_connector_res_dto_spec.rb +28 -0
  234. data/spec/models/proxy_execution_req_dto_spec.rb +34 -0
  235. data/spec/models/redirect_uri_dto_spec.rb +28 -0
  236. data/spec/models/set_callback_url_body_dto_spec.rb +28 -0
  237. data/spec/models/single_app_info_res_dto_spec.rb +118 -0
  238. data/spec/models/single_trigger_res_dto_spec.rb +76 -0
  239. data/spec/models/status_spec.rb +22 -0
  240. data/spec/models/switch_trigger_status_body_dto_spec.rb +28 -0
  241. data/spec/models/switch_trigger_status_params_dto_spec.rb +28 -0
  242. data/spec/models/time_spec.rb +22 -0
  243. data/spec/models/toggle_connected_account_response_dto_spec.rb +28 -0
  244. data/spec/models/toggle_trigger_state_response_dto_spec.rb +28 -0
  245. data/spec/models/tools_execute_req_dto_spec.rb +58 -0
  246. data/spec/models/track_client_req_dto_spec.rb +40 -0
  247. data/spec/models/track_client_res_dto_spec.rb +28 -0
  248. data/spec/models/trigger_config_spec.rb +34 -0
  249. data/spec/models/trigger_instance_params_dto_spec.rb +28 -0
  250. data/spec/models/trigger_log_data_spec.rb +70 -0
  251. data/spec/models/trigger_log_item_dto_spec.rb +82 -0
  252. data/spec/models/trigger_logs_res_dto_spec.rb +34 -0
  253. data/spec/models/trigger_metadata_dto_spec.rb +82 -0
  254. data/spec/models/trigger_metadata_spec.rb +94 -0
  255. data/spec/models/trigger_metadata_type_spec.rb +25 -0
  256. data/spec/models/trigger_res_dto_spec.rb +100 -0
  257. data/spec/models/trigger_response_dto_spec.rb +40 -0
  258. data/spec/models/trigger_toggle_info_response_dto_spec.rb +28 -0
  259. data/spec/models/triggers_enabled_toggle_req_dto_spec.rb +28 -0
  260. data/spec/models/triggers_enabled_toggle_res_dto_spec.rb +28 -0
  261. data/spec/models/type_spec.rb +22 -0
  262. data/spec/models/user_git_user_info_spec.rb +34 -0
  263. data/spec/models/verify_cli_code_res_dto_spec.rb +40 -0
  264. data/spec/models/verify_magic_link_data_dto_spec.rb +46 -0
  265. data/spec/models/verify_magic_link_req_dto_spec.rb +28 -0
  266. data/spec/models/verify_magic_link_res_dto_spec.rb +34 -0
  267. data/spec/models/webhook_url_response_dto_spec.rb +34 -0
  268. data/spec/simple_test_spec.rb +52 -0
  269. data/spec/spec_helper.rb +107 -0
  270. metadata +504 -0
@@ -0,0 +1,1062 @@
1
+ =begin
2
+ #Composio OpenAPI
3
+
4
+ #Composio SDK: Equip your agent with high-quality tools and build your real-world usecase
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ =end
8
+
9
+ require 'cgi'
10
+
11
+ module Composio
12
+ class ActionsApi
13
+ attr_accessor :api_client
14
+
15
+ def initialize(api_client = ApiClient.default)
16
+ @api_client = api_client
17
+ end
18
+
19
+ # Execute action
20
+ #
21
+ # @param action_id [String]
22
+ # @param connected_account_id [String]
23
+ # @param app_name [String]
24
+ # @param entity_id [String]
25
+ # @param endpoint [String]
26
+ # @param input [Object]
27
+ # @param text [String]
28
+ # @param body [ActionExecutionReqDTO]
29
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
30
+ def execute(action_id:, connected_account_id: SENTINEL, app_name: SENTINEL, entity_id: SENTINEL, endpoint: SENTINEL, input: SENTINEL, text: SENTINEL, extra: {})
31
+ _body = {}
32
+ _body[:connectedAccountId] = connected_account_id if connected_account_id != SENTINEL
33
+ _body[:appName] = app_name if app_name != SENTINEL
34
+ _body[:entityId] = entity_id if entity_id != SENTINEL
35
+ _body[:endpoint] = endpoint if endpoint != SENTINEL
36
+ _body[:input] = input if input != SENTINEL
37
+ _body[:text] = text if text != SENTINEL
38
+ extra[:action_execution_req_dto] = _body if !_body.empty?
39
+ api_response = execute_with_http_info_impl(action_id, extra)
40
+ api_response.data
41
+ end
42
+
43
+ # Execute action
44
+ #
45
+ # @param action_id [String]
46
+ # @param connected_account_id [String]
47
+ # @param app_name [String]
48
+ # @param entity_id [String]
49
+ # @param endpoint [String]
50
+ # @param input [Object]
51
+ # @param text [String]
52
+ # @param body [ActionExecutionReqDTO]
53
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
54
+ def execute_with_http_info(action_id:, connected_account_id: SENTINEL, app_name: SENTINEL, entity_id: SENTINEL, endpoint: SENTINEL, input: SENTINEL, text: SENTINEL, extra: {})
55
+ _body = {}
56
+ _body[:connectedAccountId] = connected_account_id if connected_account_id != SENTINEL
57
+ _body[:appName] = app_name if app_name != SENTINEL
58
+ _body[:entityId] = entity_id if entity_id != SENTINEL
59
+ _body[:endpoint] = endpoint if endpoint != SENTINEL
60
+ _body[:input] = input if input != SENTINEL
61
+ _body[:text] = text if text != SENTINEL
62
+ extra[:action_execution_req_dto] = _body if !_body.empty?
63
+ execute_with_http_info_impl(action_id, extra)
64
+ end
65
+
66
+ # Execute action
67
+ # @param action_id [String]
68
+ # @param [Hash] opts the optional parameters
69
+ # @option opts [ActionExecutionReqDTO] :action_execution_req_dto ActionExecutionReqDTO
70
+ # @return [ActionExecutionResDto]
71
+ private def execute_impl(action_id, opts = {})
72
+ data, _status_code, _headers = execute_with_http_info(action_id, opts)
73
+ data
74
+ end
75
+
76
+ # Execute action
77
+ # @param action_id [String]
78
+ # @param [Hash] opts the optional parameters
79
+ # @option opts [ActionExecutionReqDTO] :action_execution_req_dto ActionExecutionReqDTO
80
+ # @return [APIResponse] data is ActionExecutionResDto, status code, headers and response
81
+ private def execute_with_http_info_impl(action_id, opts = {})
82
+ if @api_client.config.debugging
83
+ @api_client.config.logger.debug 'Calling API: ActionsApi.execute ...'
84
+ end
85
+ # verify the required parameter 'action_id' is set
86
+ if @api_client.config.client_side_validation && action_id.nil?
87
+ fail ArgumentError, "Missing the required parameter 'action_id' when calling ActionsApi.execute"
88
+ end
89
+ pattern = Regexp.new(/[^\/#\?]+?/)
90
+ if @api_client.config.client_side_validation && action_id !~ pattern
91
+ fail ArgumentError, "invalid value for 'action_id' when calling ActionsApi.execute, must conform to the pattern #{pattern}."
92
+ end
93
+
94
+ # resource path
95
+ local_var_path = '/api/v1/actions/{actionId}/execute'.sub('{' + 'actionId' + '}', CGI.escape(action_id.to_s))
96
+
97
+ # query parameters
98
+ query_params = opts[:query_params] || {}
99
+
100
+ # header parameters
101
+ header_params = opts[:header_params] || {}
102
+ # HTTP header 'Accept' (if needed)
103
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
104
+ # HTTP header 'Content-Type'
105
+ content_type = @api_client.select_header_content_type(['application/json'])
106
+ if !content_type.nil?
107
+ header_params['Content-Type'] = content_type
108
+ end
109
+
110
+ # form parameters
111
+ form_params = opts[:form_params] || {}
112
+
113
+ # http body (model)
114
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'action_execution_req_dto'])
115
+
116
+ # return_type
117
+ return_type = opts[:debug_return_type] || 'ActionExecutionResDto'
118
+
119
+ # auth_names
120
+ auth_names = opts[:debug_auth_names] || ['api_key']
121
+
122
+ new_options = opts.merge(
123
+ :operation => :"ActionsApi.execute",
124
+ :header_params => header_params,
125
+ :query_params => query_params,
126
+ :form_params => form_params,
127
+ :body => post_body,
128
+ :auth_names => auth_names,
129
+ :return_type => return_type
130
+ )
131
+
132
+ data, status_code, headers, response = @api_client.call_api(:POST, local_var_path, new_options)
133
+ if @api_client.config.debugging
134
+ @api_client.config.logger.debug "API called: ActionsApi#execute\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
135
+ end
136
+ APIResponse::new(data, status_code, headers, response)
137
+ end
138
+
139
+
140
+ # Execute action
141
+ #
142
+ # Execute an action. Support both connected account and no auth auth.
143
+ #
144
+ # @param action_id [String]
145
+ # @param connected_account_id [String]
146
+ # @param app_name [String]
147
+ # @param entity_id [String]
148
+ # @param endpoint [String]
149
+ # @param input [Object]
150
+ # @param text [String]
151
+ # @param body [ActionExecutionReqDTO]
152
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
153
+ def execute_0(action_id:, connected_account_id: SENTINEL, app_name: SENTINEL, entity_id: SENTINEL, endpoint: SENTINEL, input: SENTINEL, text: SENTINEL, extra: {})
154
+ _body = {}
155
+ _body[:connectedAccountId] = connected_account_id if connected_account_id != SENTINEL
156
+ _body[:appName] = app_name if app_name != SENTINEL
157
+ _body[:entityId] = entity_id if entity_id != SENTINEL
158
+ _body[:endpoint] = endpoint if endpoint != SENTINEL
159
+ _body[:input] = input if input != SENTINEL
160
+ _body[:text] = text if text != SENTINEL
161
+ extra[:action_execution_req_dto] = _body if !_body.empty?
162
+ api_response = execute_0_with_http_info_impl(action_id, extra)
163
+ api_response.data
164
+ end
165
+
166
+ # Execute action
167
+ #
168
+ # Execute an action. Support both connected account and no auth auth.
169
+ #
170
+ # @param action_id [String]
171
+ # @param connected_account_id [String]
172
+ # @param app_name [String]
173
+ # @param entity_id [String]
174
+ # @param endpoint [String]
175
+ # @param input [Object]
176
+ # @param text [String]
177
+ # @param body [ActionExecutionReqDTO]
178
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
179
+ def execute_0_with_http_info(action_id:, connected_account_id: SENTINEL, app_name: SENTINEL, entity_id: SENTINEL, endpoint: SENTINEL, input: SENTINEL, text: SENTINEL, extra: {})
180
+ _body = {}
181
+ _body[:connectedAccountId] = connected_account_id if connected_account_id != SENTINEL
182
+ _body[:appName] = app_name if app_name != SENTINEL
183
+ _body[:entityId] = entity_id if entity_id != SENTINEL
184
+ _body[:endpoint] = endpoint if endpoint != SENTINEL
185
+ _body[:input] = input if input != SENTINEL
186
+ _body[:text] = text if text != SENTINEL
187
+ extra[:action_execution_req_dto] = _body if !_body.empty?
188
+ execute_0_with_http_info_impl(action_id, extra)
189
+ end
190
+
191
+ # Execute action
192
+ # Execute an action. Support both connected account and no auth auth.
193
+ # @param action_id [String]
194
+ # @param [Hash] opts the optional parameters
195
+ # @option opts [ActionExecutionReqDTO] :action_execution_req_dto ActionExecutionReqDTO
196
+ # @return [ActionExecutionResDto]
197
+ private def execute_0_impl(action_id, opts = {})
198
+ data, _status_code, _headers = execute_0_with_http_info(action_id, opts)
199
+ data
200
+ end
201
+
202
+ # Execute action
203
+ # Execute an action. Support both connected account and no auth auth.
204
+ # @param action_id [String]
205
+ # @param [Hash] opts the optional parameters
206
+ # @option opts [ActionExecutionReqDTO] :action_execution_req_dto ActionExecutionReqDTO
207
+ # @return [APIResponse] data is ActionExecutionResDto, status code, headers and response
208
+ private def execute_0_with_http_info_impl(action_id, opts = {})
209
+ if @api_client.config.debugging
210
+ @api_client.config.logger.debug 'Calling API: ActionsApi.execute_0 ...'
211
+ end
212
+ # verify the required parameter 'action_id' is set
213
+ if @api_client.config.client_side_validation && action_id.nil?
214
+ fail ArgumentError, "Missing the required parameter 'action_id' when calling ActionsApi.execute_0"
215
+ end
216
+ pattern = Regexp.new(/[^\/#\?]+?/)
217
+ if @api_client.config.client_side_validation && action_id !~ pattern
218
+ fail ArgumentError, "invalid value for 'action_id' when calling ActionsApi.execute_0, must conform to the pattern #{pattern}."
219
+ end
220
+
221
+ # resource path
222
+ local_var_path = '/api/v2/actions/{actionId}/execute'.sub('{' + 'actionId' + '}', CGI.escape(action_id.to_s))
223
+
224
+ # query parameters
225
+ query_params = opts[:query_params] || {}
226
+
227
+ # header parameters
228
+ header_params = opts[:header_params] || {}
229
+ # HTTP header 'Accept' (if needed)
230
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
231
+ # HTTP header 'Content-Type'
232
+ content_type = @api_client.select_header_content_type(['application/json'])
233
+ if !content_type.nil?
234
+ header_params['Content-Type'] = content_type
235
+ end
236
+
237
+ # form parameters
238
+ form_params = opts[:form_params] || {}
239
+
240
+ # http body (model)
241
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'action_execution_req_dto'])
242
+
243
+ # return_type
244
+ return_type = opts[:debug_return_type] || 'ActionExecutionResDto'
245
+
246
+ # auth_names
247
+ auth_names = opts[:debug_auth_names] || ['api_key']
248
+
249
+ new_options = opts.merge(
250
+ :operation => :"ActionsApi.execute_0",
251
+ :header_params => header_params,
252
+ :query_params => query_params,
253
+ :form_params => form_params,
254
+ :body => post_body,
255
+ :auth_names => auth_names,
256
+ :return_type => return_type
257
+ )
258
+
259
+ data, status_code, headers, response = @api_client.call_api(:POST, local_var_path, new_options)
260
+ if @api_client.config.debugging
261
+ @api_client.config.logger.debug "API called: ActionsApi#execute_0\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
262
+ end
263
+ APIResponse::new(data, status_code, headers, response)
264
+ end
265
+
266
+
267
+ # Execute action proxy
268
+ #
269
+ # Execute an action with direct auth.
270
+ #
271
+ # @param endpoint [String]
272
+ # @param connected_account_id [String]
273
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
274
+ def execute_action_proxy(endpoint:, connected_account_id:, extra: {})
275
+ api_response = execute_action_proxy_with_http_info_impl(endpoint, connected_account_id, extra)
276
+ api_response.data
277
+ end
278
+
279
+ # Execute action proxy
280
+ #
281
+ # Execute an action with direct auth.
282
+ #
283
+ # @param endpoint [String]
284
+ # @param connected_account_id [String]
285
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
286
+ def execute_action_proxy_with_http_info(endpoint:, connected_account_id:, extra: {})
287
+ execute_action_proxy_with_http_info_impl(endpoint, connected_account_id, extra)
288
+ end
289
+
290
+ # Execute action proxy
291
+ # Execute an action with direct auth.
292
+ # @param endpoint [String]
293
+ # @param connected_account_id [String]
294
+ # @param [Hash] opts the optional parameters
295
+ # @return [ActionExecutionResDto]
296
+ private def execute_action_proxy_impl(endpoint, connected_account_id, opts = {})
297
+ data, _status_code, _headers = execute_action_proxy_with_http_info(endpoint, connected_account_id, opts)
298
+ data
299
+ end
300
+
301
+ # Execute action proxy
302
+ # Execute an action with direct auth.
303
+ # @param endpoint [String]
304
+ # @param connected_account_id [String]
305
+ # @param [Hash] opts the optional parameters
306
+ # @return [APIResponse] data is ActionExecutionResDto, status code, headers and response
307
+ private def execute_action_proxy_with_http_info_impl(endpoint, connected_account_id, opts = {})
308
+ if @api_client.config.debugging
309
+ @api_client.config.logger.debug 'Calling API: ActionsApi.execute_action_proxy ...'
310
+ end
311
+ # verify the required parameter 'endpoint' is set
312
+ if @api_client.config.client_side_validation && endpoint.nil?
313
+ fail ArgumentError, "Missing the required parameter 'endpoint' when calling ActionsApi.execute_action_proxy"
314
+ end
315
+ # verify the required parameter 'connected_account_id' is set
316
+ if @api_client.config.client_side_validation && connected_account_id.nil?
317
+ fail ArgumentError, "Missing the required parameter 'connected_account_id' when calling ActionsApi.execute_action_proxy"
318
+ end
319
+ # resource path
320
+ local_var_path = '/api/v2/actions/proxy'
321
+
322
+ # query parameters
323
+ query_params = opts[:query_params] || {}
324
+ query_params[:'endpoint'] = endpoint
325
+ query_params[:'connectedAccountId'] = connected_account_id
326
+
327
+ # header parameters
328
+ header_params = opts[:header_params] || {}
329
+ # HTTP header 'Accept' (if needed)
330
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
331
+
332
+ # form parameters
333
+ form_params = opts[:form_params] || {}
334
+
335
+ # http body (model)
336
+ post_body = opts[:debug_body]
337
+
338
+ # return_type
339
+ return_type = opts[:debug_return_type] || 'ActionExecutionResDto'
340
+
341
+ # auth_names
342
+ auth_names = opts[:debug_auth_names] || ['api_key']
343
+
344
+ new_options = opts.merge(
345
+ :operation => :"ActionsApi.execute_action_proxy",
346
+ :header_params => header_params,
347
+ :query_params => query_params,
348
+ :form_params => form_params,
349
+ :body => post_body,
350
+ :auth_names => auth_names,
351
+ :return_type => return_type
352
+ )
353
+
354
+ data, status_code, headers, response = @api_client.call_api(:POST, local_var_path, new_options)
355
+ if @api_client.config.debugging
356
+ @api_client.config.logger.debug "API called: ActionsApi#execute_action_proxy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
357
+ end
358
+ APIResponse::new(data, status_code, headers, response)
359
+ end
360
+
361
+
362
+ # Execute action proxy
363
+ #
364
+ # @param endpoint [String]
365
+ # @param connected_account_id [String]
366
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
367
+ def execute_proxy(endpoint:, connected_account_id:, extra: {})
368
+ api_response = execute_proxy_with_http_info_impl(endpoint, connected_account_id, extra)
369
+ api_response.data
370
+ end
371
+
372
+ # Execute action proxy
373
+ #
374
+ # @param endpoint [String]
375
+ # @param connected_account_id [String]
376
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
377
+ def execute_proxy_with_http_info(endpoint:, connected_account_id:, extra: {})
378
+ execute_proxy_with_http_info_impl(endpoint, connected_account_id, extra)
379
+ end
380
+
381
+ # Execute action proxy
382
+ # @param endpoint [String]
383
+ # @param connected_account_id [String]
384
+ # @param [Hash] opts the optional parameters
385
+ # @return [ExecuteActionResDTO]
386
+ private def execute_proxy_impl(endpoint, connected_account_id, opts = {})
387
+ data, _status_code, _headers = execute_proxy_with_http_info(endpoint, connected_account_id, opts)
388
+ data
389
+ end
390
+
391
+ # Execute action proxy
392
+ # @param endpoint [String]
393
+ # @param connected_account_id [String]
394
+ # @param [Hash] opts the optional parameters
395
+ # @return [APIResponse] data is ExecuteActionResDTO, status code, headers and response
396
+ private def execute_proxy_with_http_info_impl(endpoint, connected_account_id, opts = {})
397
+ if @api_client.config.debugging
398
+ @api_client.config.logger.debug 'Calling API: ActionsApi.execute_proxy ...'
399
+ end
400
+ # verify the required parameter 'endpoint' is set
401
+ if @api_client.config.client_side_validation && endpoint.nil?
402
+ fail ArgumentError, "Missing the required parameter 'endpoint' when calling ActionsApi.execute_proxy"
403
+ end
404
+ # verify the required parameter 'connected_account_id' is set
405
+ if @api_client.config.client_side_validation && connected_account_id.nil?
406
+ fail ArgumentError, "Missing the required parameter 'connected_account_id' when calling ActionsApi.execute_proxy"
407
+ end
408
+ # resource path
409
+ local_var_path = '/api/v1/actions/proxy'
410
+
411
+ # query parameters
412
+ query_params = opts[:query_params] || {}
413
+ query_params[:'endpoint'] = endpoint
414
+ query_params[:'connectedAccountId'] = connected_account_id
415
+
416
+ # header parameters
417
+ header_params = opts[:header_params] || {}
418
+ # HTTP header 'Accept' (if needed)
419
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
420
+
421
+ # form parameters
422
+ form_params = opts[:form_params] || {}
423
+
424
+ # http body (model)
425
+ post_body = opts[:debug_body]
426
+
427
+ # return_type
428
+ return_type = opts[:debug_return_type] || 'ExecuteActionResDTO'
429
+
430
+ # auth_names
431
+ auth_names = opts[:debug_auth_names] || ['api_key']
432
+
433
+ new_options = opts.merge(
434
+ :operation => :"ActionsApi.execute_proxy",
435
+ :header_params => header_params,
436
+ :query_params => query_params,
437
+ :form_params => form_params,
438
+ :body => post_body,
439
+ :auth_names => auth_names,
440
+ :return_type => return_type
441
+ )
442
+
443
+ data, status_code, headers, response = @api_client.call_api(:POST, local_var_path, new_options)
444
+ if @api_client.config.debugging
445
+ @api_client.config.logger.debug "API called: ActionsApi#execute_proxy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
446
+ end
447
+ APIResponse::new(data, status_code, headers, response)
448
+ end
449
+
450
+
451
+ # Get action
452
+ #
453
+ # @param action_id [String]
454
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
455
+ def get(action_id:, extra: {})
456
+ api_response = get_with_http_info_impl(action_id, extra)
457
+ api_response.data
458
+ end
459
+
460
+ # Get action
461
+ #
462
+ # @param action_id [String]
463
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
464
+ def get_with_http_info(action_id:, extra: {})
465
+ get_with_http_info_impl(action_id, extra)
466
+ end
467
+
468
+ # Get action
469
+ # @param action_id [String]
470
+ # @param [Hash] opts the optional parameters
471
+ # @return [ActionDetails]
472
+ private def get_impl(action_id, opts = {})
473
+ data, _status_code, _headers = get_with_http_info(action_id, opts)
474
+ data
475
+ end
476
+
477
+ # Get action
478
+ # @param action_id [String]
479
+ # @param [Hash] opts the optional parameters
480
+ # @return [APIResponse] data is ActionDetails, status code, headers and response
481
+ private def get_with_http_info_impl(action_id, opts = {})
482
+ if @api_client.config.debugging
483
+ @api_client.config.logger.debug 'Calling API: ActionsApi.get ...'
484
+ end
485
+ # verify the required parameter 'action_id' is set
486
+ if @api_client.config.client_side_validation && action_id.nil?
487
+ fail ArgumentError, "Missing the required parameter 'action_id' when calling ActionsApi.get"
488
+ end
489
+ pattern = Regexp.new(/[^\/#\?]+?/)
490
+ if @api_client.config.client_side_validation && action_id !~ pattern
491
+ fail ArgumentError, "invalid value for 'action_id' when calling ActionsApi.get, must conform to the pattern #{pattern}."
492
+ end
493
+
494
+ # resource path
495
+ local_var_path = '/api/v1/actions/{actionId}'.sub('{' + 'actionId' + '}', CGI.escape(action_id.to_s))
496
+
497
+ # query parameters
498
+ query_params = opts[:query_params] || {}
499
+
500
+ # header parameters
501
+ header_params = opts[:header_params] || {}
502
+ # HTTP header 'Accept' (if needed)
503
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
504
+
505
+ # form parameters
506
+ form_params = opts[:form_params] || {}
507
+
508
+ # http body (model)
509
+ post_body = opts[:debug_body]
510
+
511
+ # return_type
512
+ return_type = opts[:debug_return_type] || 'ActionDetails'
513
+
514
+ # auth_names
515
+ auth_names = opts[:debug_auth_names] || ['api_key']
516
+
517
+ new_options = opts.merge(
518
+ :operation => :"ActionsApi.get",
519
+ :header_params => header_params,
520
+ :query_params => query_params,
521
+ :form_params => form_params,
522
+ :body => post_body,
523
+ :auth_names => auth_names,
524
+ :return_type => return_type
525
+ )
526
+
527
+ data, status_code, headers, response = @api_client.call_api(:GET, local_var_path, new_options)
528
+ if @api_client.config.debugging
529
+ @api_client.config.logger.debug "API called: ActionsApi#get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
530
+ end
531
+ APIResponse::new(data, status_code, headers, response)
532
+ end
533
+
534
+
535
+ # Get action
536
+ #
537
+ # Get action details
538
+ #
539
+ # @param action_id [String]
540
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
541
+ def get_action_by_id(action_id:, extra: {})
542
+ api_response = get_action_by_id_with_http_info_impl(action_id, extra)
543
+ api_response.data
544
+ end
545
+
546
+ # Get action
547
+ #
548
+ # Get action details
549
+ #
550
+ # @param action_id [String]
551
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
552
+ def get_action_by_id_with_http_info(action_id:, extra: {})
553
+ get_action_by_id_with_http_info_impl(action_id, extra)
554
+ end
555
+
556
+ # Get action
557
+ # Get action details
558
+ # @param action_id [String]
559
+ # @param [Hash] opts the optional parameters
560
+ # @return [ActionDetails]
561
+ private def get_action_by_id_impl(action_id, opts = {})
562
+ data, _status_code, _headers = get_action_by_id_with_http_info(action_id, opts)
563
+ data
564
+ end
565
+
566
+ # Get action
567
+ # Get action details
568
+ # @param action_id [String]
569
+ # @param [Hash] opts the optional parameters
570
+ # @return [APIResponse] data is ActionDetails, status code, headers and response
571
+ private def get_action_by_id_with_http_info_impl(action_id, opts = {})
572
+ if @api_client.config.debugging
573
+ @api_client.config.logger.debug 'Calling API: ActionsApi.get_action_by_id ...'
574
+ end
575
+ # verify the required parameter 'action_id' is set
576
+ if @api_client.config.client_side_validation && action_id.nil?
577
+ fail ArgumentError, "Missing the required parameter 'action_id' when calling ActionsApi.get_action_by_id"
578
+ end
579
+ pattern = Regexp.new(/[^\/#\?]+?/)
580
+ if @api_client.config.client_side_validation && action_id !~ pattern
581
+ fail ArgumentError, "invalid value for 'action_id' when calling ActionsApi.get_action_by_id, must conform to the pattern #{pattern}."
582
+ end
583
+
584
+ # resource path
585
+ local_var_path = '/api/v2/actions/{actionId}'.sub('{' + 'actionId' + '}', CGI.escape(action_id.to_s))
586
+
587
+ # query parameters
588
+ query_params = opts[:query_params] || {}
589
+
590
+ # header parameters
591
+ header_params = opts[:header_params] || {}
592
+ # HTTP header 'Accept' (if needed)
593
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
594
+
595
+ # form parameters
596
+ form_params = opts[:form_params] || {}
597
+
598
+ # http body (model)
599
+ post_body = opts[:debug_body]
600
+
601
+ # return_type
602
+ return_type = opts[:debug_return_type] || 'ActionDetails'
603
+
604
+ # auth_names
605
+ auth_names = opts[:debug_auth_names] || ['api_key']
606
+
607
+ new_options = opts.merge(
608
+ :operation => :"ActionsApi.get_action_by_id",
609
+ :header_params => header_params,
610
+ :query_params => query_params,
611
+ :form_params => form_params,
612
+ :body => post_body,
613
+ :auth_names => auth_names,
614
+ :return_type => return_type
615
+ )
616
+
617
+ data, status_code, headers, response = @api_client.call_api(:GET, local_var_path, new_options)
618
+ if @api_client.config.debugging
619
+ @api_client.config.logger.debug "API called: ActionsApi#get_action_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
620
+ end
621
+ APIResponse::new(data, status_code, headers, response)
622
+ end
623
+
624
+
625
+ # List actions minimal
626
+ #
627
+ # Retrieve a list of all actions based on query parameters.
628
+ #
629
+ # @param app_names [String]
630
+ # @param use_case [String]
631
+ # @param show_enabled_only [Boolean]
632
+ # @param limit [Float]
633
+ # @param apps [String]
634
+ # @param actions [String]
635
+ # @param tags [String]
636
+ # @param usecase_limit [Float]
637
+ # @param filter_important_actions [Boolean]
638
+ # @param show_all [Boolean]
639
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
640
+ def get_all_actions_based_on_query(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
641
+ extra[:app_names] = app_names if app_names != SENTINEL
642
+ extra[:use_case] = use_case if use_case != SENTINEL
643
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
644
+ extra[:limit] = limit if limit != SENTINEL
645
+ extra[:apps] = apps if apps != SENTINEL
646
+ extra[:actions] = actions if actions != SENTINEL
647
+ extra[:tags] = tags if tags != SENTINEL
648
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
649
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
650
+ extra[:show_all] = show_all if show_all != SENTINEL
651
+ api_response = get_all_actions_based_on_query_with_http_info_impl(extra)
652
+ api_response.data
653
+ end
654
+
655
+ # List actions minimal
656
+ #
657
+ # Retrieve a list of all actions based on query parameters.
658
+ #
659
+ # @param app_names [String]
660
+ # @param use_case [String]
661
+ # @param show_enabled_only [Boolean]
662
+ # @param limit [Float]
663
+ # @param apps [String]
664
+ # @param actions [String]
665
+ # @param tags [String]
666
+ # @param usecase_limit [Float]
667
+ # @param filter_important_actions [Boolean]
668
+ # @param show_all [Boolean]
669
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
670
+ def get_all_actions_based_on_query_with_http_info(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
671
+ extra[:app_names] = app_names if app_names != SENTINEL
672
+ extra[:use_case] = use_case if use_case != SENTINEL
673
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
674
+ extra[:limit] = limit if limit != SENTINEL
675
+ extra[:apps] = apps if apps != SENTINEL
676
+ extra[:actions] = actions if actions != SENTINEL
677
+ extra[:tags] = tags if tags != SENTINEL
678
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
679
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
680
+ extra[:show_all] = show_all if show_all != SENTINEL
681
+ get_all_actions_based_on_query_with_http_info_impl(extra)
682
+ end
683
+
684
+ # List actions minimal
685
+ # Retrieve a list of all actions based on query parameters.
686
+ # @param [Hash] opts the optional parameters
687
+ # @option opts [String] :app_names
688
+ # @option opts [String] :use_case
689
+ # @option opts [Boolean] :show_enabled_only
690
+ # @option opts [Float] :limit
691
+ # @option opts [String] :apps
692
+ # @option opts [String] :actions
693
+ # @option opts [String] :tags
694
+ # @option opts [Float] :usecase_limit
695
+ # @option opts [Boolean] :filter_important_actions
696
+ # @option opts [Boolean] :show_all
697
+ # @return [ActionsListResponseDTO]
698
+ private def get_all_actions_based_on_query_impl(opts = {})
699
+ data, _status_code, _headers = get_all_actions_based_on_query_with_http_info(opts)
700
+ data
701
+ end
702
+
703
+ # List actions minimal
704
+ # Retrieve a list of all actions based on query parameters.
705
+ # @param [Hash] opts the optional parameters
706
+ # @option opts [String] :app_names
707
+ # @option opts [String] :use_case
708
+ # @option opts [Boolean] :show_enabled_only
709
+ # @option opts [Float] :limit
710
+ # @option opts [String] :apps
711
+ # @option opts [String] :actions
712
+ # @option opts [String] :tags
713
+ # @option opts [Float] :usecase_limit
714
+ # @option opts [Boolean] :filter_important_actions
715
+ # @option opts [Boolean] :show_all
716
+ # @return [APIResponse] data is ActionsListResponseDTO, status code, headers and response
717
+ private def get_all_actions_based_on_query_with_http_info_impl(opts = {})
718
+ if @api_client.config.debugging
719
+ @api_client.config.logger.debug 'Calling API: ActionsApi.get_all_actions_based_on_query ...'
720
+ end
721
+ # resource path
722
+ local_var_path = '/api/v2/actions/list/all'
723
+
724
+ # query parameters
725
+ query_params = opts[:query_params] || {}
726
+ query_params[:'appNames'] = opts[:'app_names'] if !opts[:'app_names'].nil?
727
+ query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
728
+ query_params[:'showEnabledOnly'] = opts[:'show_enabled_only'] if !opts[:'show_enabled_only'].nil?
729
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
730
+ query_params[:'apps'] = opts[:'apps'] if !opts[:'apps'].nil?
731
+ query_params[:'actions'] = opts[:'actions'] if !opts[:'actions'].nil?
732
+ query_params[:'tags'] = opts[:'tags'] if !opts[:'tags'].nil?
733
+ query_params[:'usecaseLimit'] = opts[:'usecase_limit'] if !opts[:'usecase_limit'].nil?
734
+ query_params[:'filterImportantActions'] = opts[:'filter_important_actions'] if !opts[:'filter_important_actions'].nil?
735
+ query_params[:'showAll'] = opts[:'show_all'] if !opts[:'show_all'].nil?
736
+
737
+ # header parameters
738
+ header_params = opts[:header_params] || {}
739
+ # HTTP header 'Accept' (if needed)
740
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
741
+
742
+ # form parameters
743
+ form_params = opts[:form_params] || {}
744
+
745
+ # http body (model)
746
+ post_body = opts[:debug_body]
747
+
748
+ # return_type
749
+ return_type = opts[:debug_return_type] || 'ActionsListResponseDTO'
750
+
751
+ # auth_names
752
+ auth_names = opts[:debug_auth_names] || ['api_key']
753
+
754
+ new_options = opts.merge(
755
+ :operation => :"ActionsApi.get_all_actions_based_on_query",
756
+ :header_params => header_params,
757
+ :query_params => query_params,
758
+ :form_params => form_params,
759
+ :body => post_body,
760
+ :auth_names => auth_names,
761
+ :return_type => return_type
762
+ )
763
+
764
+ data, status_code, headers, response = @api_client.call_api(:GET, local_var_path, new_options)
765
+ if @api_client.config.debugging
766
+ @api_client.config.logger.debug "API called: ActionsApi#get_all_actions_based_on_query\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
767
+ end
768
+ APIResponse::new(data, status_code, headers, response)
769
+ end
770
+
771
+
772
+ # List actions
773
+ #
774
+ # @param app_names [String]
775
+ # @param use_case [String]
776
+ # @param show_enabled_only [Boolean]
777
+ # @param limit [Float]
778
+ # @param apps [String]
779
+ # @param actions [String]
780
+ # @param tags [String]
781
+ # @param usecase_limit [Float]
782
+ # @param filter_important_actions [Boolean]
783
+ # @param show_all [Boolean]
784
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
785
+ def list(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
786
+ extra[:app_names] = app_names if app_names != SENTINEL
787
+ extra[:use_case] = use_case if use_case != SENTINEL
788
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
789
+ extra[:limit] = limit if limit != SENTINEL
790
+ extra[:apps] = apps if apps != SENTINEL
791
+ extra[:actions] = actions if actions != SENTINEL
792
+ extra[:tags] = tags if tags != SENTINEL
793
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
794
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
795
+ extra[:show_all] = show_all if show_all != SENTINEL
796
+ api_response = list_with_http_info_impl(extra)
797
+ api_response.data
798
+ end
799
+
800
+ # List actions
801
+ #
802
+ # @param app_names [String]
803
+ # @param use_case [String]
804
+ # @param show_enabled_only [Boolean]
805
+ # @param limit [Float]
806
+ # @param apps [String]
807
+ # @param actions [String]
808
+ # @param tags [String]
809
+ # @param usecase_limit [Float]
810
+ # @param filter_important_actions [Boolean]
811
+ # @param show_all [Boolean]
812
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
813
+ def list_with_http_info(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
814
+ extra[:app_names] = app_names if app_names != SENTINEL
815
+ extra[:use_case] = use_case if use_case != SENTINEL
816
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
817
+ extra[:limit] = limit if limit != SENTINEL
818
+ extra[:apps] = apps if apps != SENTINEL
819
+ extra[:actions] = actions if actions != SENTINEL
820
+ extra[:tags] = tags if tags != SENTINEL
821
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
822
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
823
+ extra[:show_all] = show_all if show_all != SENTINEL
824
+ list_with_http_info_impl(extra)
825
+ end
826
+
827
+ # List actions
828
+ # @param [Hash] opts the optional parameters
829
+ # @option opts [String] :app_names
830
+ # @option opts [String] :use_case
831
+ # @option opts [Boolean] :show_enabled_only
832
+ # @option opts [Float] :limit
833
+ # @option opts [String] :apps
834
+ # @option opts [String] :actions
835
+ # @option opts [String] :tags
836
+ # @option opts [Float] :usecase_limit
837
+ # @option opts [Boolean] :filter_important_actions
838
+ # @option opts [Boolean] :show_all
839
+ # @return [ActionsListResponseDTO]
840
+ private def list_impl(opts = {})
841
+ data, _status_code, _headers = list_with_http_info(opts)
842
+ data
843
+ end
844
+
845
+ # List actions
846
+ # @param [Hash] opts the optional parameters
847
+ # @option opts [String] :app_names
848
+ # @option opts [String] :use_case
849
+ # @option opts [Boolean] :show_enabled_only
850
+ # @option opts [Float] :limit
851
+ # @option opts [String] :apps
852
+ # @option opts [String] :actions
853
+ # @option opts [String] :tags
854
+ # @option opts [Float] :usecase_limit
855
+ # @option opts [Boolean] :filter_important_actions
856
+ # @option opts [Boolean] :show_all
857
+ # @return [APIResponse] data is ActionsListResponseDTO, status code, headers and response
858
+ private def list_with_http_info_impl(opts = {})
859
+ if @api_client.config.debugging
860
+ @api_client.config.logger.debug 'Calling API: ActionsApi.list ...'
861
+ end
862
+ # resource path
863
+ local_var_path = '/api/v1/actions'
864
+
865
+ # query parameters
866
+ query_params = opts[:query_params] || {}
867
+ query_params[:'appNames'] = opts[:'app_names'] if !opts[:'app_names'].nil?
868
+ query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
869
+ query_params[:'showEnabledOnly'] = opts[:'show_enabled_only'] if !opts[:'show_enabled_only'].nil?
870
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
871
+ query_params[:'apps'] = opts[:'apps'] if !opts[:'apps'].nil?
872
+ query_params[:'actions'] = opts[:'actions'] if !opts[:'actions'].nil?
873
+ query_params[:'tags'] = opts[:'tags'] if !opts[:'tags'].nil?
874
+ query_params[:'usecaseLimit'] = opts[:'usecase_limit'] if !opts[:'usecase_limit'].nil?
875
+ query_params[:'filterImportantActions'] = opts[:'filter_important_actions'] if !opts[:'filter_important_actions'].nil?
876
+ query_params[:'showAll'] = opts[:'show_all'] if !opts[:'show_all'].nil?
877
+
878
+ # header parameters
879
+ header_params = opts[:header_params] || {}
880
+ # HTTP header 'Accept' (if needed)
881
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
882
+
883
+ # form parameters
884
+ form_params = opts[:form_params] || {}
885
+
886
+ # http body (model)
887
+ post_body = opts[:debug_body]
888
+
889
+ # return_type
890
+ return_type = opts[:debug_return_type] || 'ActionsListResponseDTO'
891
+
892
+ # auth_names
893
+ auth_names = opts[:debug_auth_names] || ['api_key']
894
+
895
+ new_options = opts.merge(
896
+ :operation => :"ActionsApi.list",
897
+ :header_params => header_params,
898
+ :query_params => query_params,
899
+ :form_params => form_params,
900
+ :body => post_body,
901
+ :auth_names => auth_names,
902
+ :return_type => return_type
903
+ )
904
+
905
+ data, status_code, headers, response = @api_client.call_api(:GET, local_var_path, new_options)
906
+ if @api_client.config.debugging
907
+ @api_client.config.logger.debug "API called: ActionsApi#list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
908
+ end
909
+ APIResponse::new(data, status_code, headers, response)
910
+ end
911
+
912
+
913
+ # List actions
914
+ #
915
+ # Retrieve a list of all actions based on query parameters.
916
+ #
917
+ # @param app_names [String]
918
+ # @param use_case [String]
919
+ # @param show_enabled_only [Boolean]
920
+ # @param limit [Float]
921
+ # @param apps [String]
922
+ # @param actions [String]
923
+ # @param tags [String]
924
+ # @param usecase_limit [Float]
925
+ # @param filter_important_actions [Boolean]
926
+ # @param show_all [Boolean]
927
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
928
+ def list_0(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
929
+ extra[:app_names] = app_names if app_names != SENTINEL
930
+ extra[:use_case] = use_case if use_case != SENTINEL
931
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
932
+ extra[:limit] = limit if limit != SENTINEL
933
+ extra[:apps] = apps if apps != SENTINEL
934
+ extra[:actions] = actions if actions != SENTINEL
935
+ extra[:tags] = tags if tags != SENTINEL
936
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
937
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
938
+ extra[:show_all] = show_all if show_all != SENTINEL
939
+ api_response = list_0_with_http_info_impl(extra)
940
+ api_response.data
941
+ end
942
+
943
+ # List actions
944
+ #
945
+ # Retrieve a list of all actions based on query parameters.
946
+ #
947
+ # @param app_names [String]
948
+ # @param use_case [String]
949
+ # @param show_enabled_only [Boolean]
950
+ # @param limit [Float]
951
+ # @param apps [String]
952
+ # @param actions [String]
953
+ # @param tags [String]
954
+ # @param usecase_limit [Float]
955
+ # @param filter_important_actions [Boolean]
956
+ # @param show_all [Boolean]
957
+ # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
958
+ def list_0_with_http_info(app_names: SENTINEL, use_case: SENTINEL, show_enabled_only: SENTINEL, limit: SENTINEL, apps: SENTINEL, actions: SENTINEL, tags: SENTINEL, usecase_limit: SENTINEL, filter_important_actions: SENTINEL, show_all: SENTINEL, extra: {})
959
+ extra[:app_names] = app_names if app_names != SENTINEL
960
+ extra[:use_case] = use_case if use_case != SENTINEL
961
+ extra[:show_enabled_only] = show_enabled_only if show_enabled_only != SENTINEL
962
+ extra[:limit] = limit if limit != SENTINEL
963
+ extra[:apps] = apps if apps != SENTINEL
964
+ extra[:actions] = actions if actions != SENTINEL
965
+ extra[:tags] = tags if tags != SENTINEL
966
+ extra[:usecase_limit] = usecase_limit if usecase_limit != SENTINEL
967
+ extra[:filter_important_actions] = filter_important_actions if filter_important_actions != SENTINEL
968
+ extra[:show_all] = show_all if show_all != SENTINEL
969
+ list_0_with_http_info_impl(extra)
970
+ end
971
+
972
+ # List actions
973
+ # Retrieve a list of all actions based on query parameters.
974
+ # @param [Hash] opts the optional parameters
975
+ # @option opts [String] :app_names
976
+ # @option opts [String] :use_case
977
+ # @option opts [Boolean] :show_enabled_only
978
+ # @option opts [Float] :limit
979
+ # @option opts [String] :apps
980
+ # @option opts [String] :actions
981
+ # @option opts [String] :tags
982
+ # @option opts [Float] :usecase_limit
983
+ # @option opts [Boolean] :filter_important_actions
984
+ # @option opts [Boolean] :show_all
985
+ # @return [ActionsListResponseDTO]
986
+ private def list_0_impl(opts = {})
987
+ data, _status_code, _headers = list_0_with_http_info(opts)
988
+ data
989
+ end
990
+
991
+ # List actions
992
+ # Retrieve a list of all actions based on query parameters.
993
+ # @param [Hash] opts the optional parameters
994
+ # @option opts [String] :app_names
995
+ # @option opts [String] :use_case
996
+ # @option opts [Boolean] :show_enabled_only
997
+ # @option opts [Float] :limit
998
+ # @option opts [String] :apps
999
+ # @option opts [String] :actions
1000
+ # @option opts [String] :tags
1001
+ # @option opts [Float] :usecase_limit
1002
+ # @option opts [Boolean] :filter_important_actions
1003
+ # @option opts [Boolean] :show_all
1004
+ # @return [APIResponse] data is ActionsListResponseDTO, status code, headers and response
1005
+ private def list_0_with_http_info_impl(opts = {})
1006
+ if @api_client.config.debugging
1007
+ @api_client.config.logger.debug 'Calling API: ActionsApi.list_0 ...'
1008
+ end
1009
+ # resource path
1010
+ local_var_path = '/api/v2/actions'
1011
+
1012
+ # query parameters
1013
+ query_params = opts[:query_params] || {}
1014
+ query_params[:'appNames'] = opts[:'app_names'] if !opts[:'app_names'].nil?
1015
+ query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
1016
+ query_params[:'showEnabledOnly'] = opts[:'show_enabled_only'] if !opts[:'show_enabled_only'].nil?
1017
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
1018
+ query_params[:'apps'] = opts[:'apps'] if !opts[:'apps'].nil?
1019
+ query_params[:'actions'] = opts[:'actions'] if !opts[:'actions'].nil?
1020
+ query_params[:'tags'] = opts[:'tags'] if !opts[:'tags'].nil?
1021
+ query_params[:'usecaseLimit'] = opts[:'usecase_limit'] if !opts[:'usecase_limit'].nil?
1022
+ query_params[:'filterImportantActions'] = opts[:'filter_important_actions'] if !opts[:'filter_important_actions'].nil?
1023
+ query_params[:'showAll'] = opts[:'show_all'] if !opts[:'show_all'].nil?
1024
+
1025
+ # header parameters
1026
+ header_params = opts[:header_params] || {}
1027
+ # HTTP header 'Accept' (if needed)
1028
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1029
+
1030
+ # form parameters
1031
+ form_params = opts[:form_params] || {}
1032
+
1033
+ # http body (model)
1034
+ post_body = opts[:debug_body]
1035
+
1036
+ # return_type
1037
+ return_type = opts[:debug_return_type] || 'ActionsListResponseDTO'
1038
+
1039
+ # auth_names
1040
+ auth_names = opts[:debug_auth_names] || ['api_key']
1041
+
1042
+ new_options = opts.merge(
1043
+ :operation => :"ActionsApi.list_0",
1044
+ :header_params => header_params,
1045
+ :query_params => query_params,
1046
+ :form_params => form_params,
1047
+ :body => post_body,
1048
+ :auth_names => auth_names,
1049
+ :return_type => return_type
1050
+ )
1051
+
1052
+ data, status_code, headers, response = @api_client.call_api(:GET, local_var_path, new_options)
1053
+ if @api_client.config.debugging
1054
+ @api_client.config.logger.debug "API called: ActionsApi#list_0\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1055
+ end
1056
+ APIResponse::new(data, status_code, headers, response)
1057
+ end
1058
+ end
1059
+
1060
+ # top-level client access to avoid having the user to insantiate their own API instances
1061
+ Actions = ActionsApi::new
1062
+ end