hatchet-sdk 1.18.1__py3-none-any.whl → 1.19.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of hatchet-sdk might be problematic. Click here for more details.

Files changed (225) hide show
  1. {hatchet_sdk-1.18.1.dist-info → hatchet_sdk-1.19.0.dist-info}/METADATA +2 -3
  2. {hatchet_sdk-1.18.1.dist-info → hatchet_sdk-1.19.0.dist-info}/RECORD +4 -225
  3. hatchet_sdk/v0/__init__.py +0 -251
  4. hatchet_sdk/v0/client.py +0 -119
  5. hatchet_sdk/v0/clients/admin.py +0 -541
  6. hatchet_sdk/v0/clients/dispatcher/action_listener.py +0 -422
  7. hatchet_sdk/v0/clients/dispatcher/dispatcher.py +0 -204
  8. hatchet_sdk/v0/clients/event_ts.py +0 -28
  9. hatchet_sdk/v0/clients/events.py +0 -182
  10. hatchet_sdk/v0/clients/rest/__init__.py +0 -307
  11. hatchet_sdk/v0/clients/rest/api/__init__.py +0 -19
  12. hatchet_sdk/v0/clients/rest/api/api_token_api.py +0 -858
  13. hatchet_sdk/v0/clients/rest/api/default_api.py +0 -2259
  14. hatchet_sdk/v0/clients/rest/api/event_api.py +0 -2548
  15. hatchet_sdk/v0/clients/rest/api/github_api.py +0 -331
  16. hatchet_sdk/v0/clients/rest/api/healthcheck_api.py +0 -483
  17. hatchet_sdk/v0/clients/rest/api/log_api.py +0 -449
  18. hatchet_sdk/v0/clients/rest/api/metadata_api.py +0 -728
  19. hatchet_sdk/v0/clients/rest/api/rate_limits_api.py +0 -423
  20. hatchet_sdk/v0/clients/rest/api/slack_api.py +0 -577
  21. hatchet_sdk/v0/clients/rest/api/sns_api.py +0 -872
  22. hatchet_sdk/v0/clients/rest/api/step_run_api.py +0 -2202
  23. hatchet_sdk/v0/clients/rest/api/tenant_api.py +0 -4430
  24. hatchet_sdk/v0/clients/rest/api/user_api.py +0 -2888
  25. hatchet_sdk/v0/clients/rest/api/worker_api.py +0 -858
  26. hatchet_sdk/v0/clients/rest/api/workflow_api.py +0 -6312
  27. hatchet_sdk/v0/clients/rest/api/workflow_run_api.py +0 -1932
  28. hatchet_sdk/v0/clients/rest/api/workflow_runs_api.py +0 -610
  29. hatchet_sdk/v0/clients/rest/api_client.py +0 -759
  30. hatchet_sdk/v0/clients/rest/api_response.py +0 -22
  31. hatchet_sdk/v0/clients/rest/configuration.py +0 -611
  32. hatchet_sdk/v0/clients/rest/exceptions.py +0 -200
  33. hatchet_sdk/v0/clients/rest/models/__init__.py +0 -274
  34. hatchet_sdk/v0/clients/rest/models/accept_invite_request.py +0 -83
  35. hatchet_sdk/v0/clients/rest/models/api_error.py +0 -102
  36. hatchet_sdk/v0/clients/rest/models/api_errors.py +0 -100
  37. hatchet_sdk/v0/clients/rest/models/api_meta.py +0 -144
  38. hatchet_sdk/v0/clients/rest/models/api_meta_auth.py +0 -85
  39. hatchet_sdk/v0/clients/rest/models/api_meta_integration.py +0 -88
  40. hatchet_sdk/v0/clients/rest/models/api_meta_posthog.py +0 -90
  41. hatchet_sdk/v0/clients/rest/models/api_resource_meta.py +0 -98
  42. hatchet_sdk/v0/clients/rest/models/api_token.py +0 -105
  43. hatchet_sdk/v0/clients/rest/models/bulk_create_event_request.py +0 -100
  44. hatchet_sdk/v0/clients/rest/models/bulk_create_event_response.py +0 -110
  45. hatchet_sdk/v0/clients/rest/models/cancel_event_request.py +0 -85
  46. hatchet_sdk/v0/clients/rest/models/cancel_step_run_request.py +0 -83
  47. hatchet_sdk/v0/clients/rest/models/concurrency_limit_strategy.py +0 -39
  48. hatchet_sdk/v0/clients/rest/models/create_api_token_request.py +0 -92
  49. hatchet_sdk/v0/clients/rest/models/create_api_token_response.py +0 -83
  50. hatchet_sdk/v0/clients/rest/models/create_cron_workflow_trigger_request.py +0 -98
  51. hatchet_sdk/v0/clients/rest/models/create_event_request.py +0 -95
  52. hatchet_sdk/v0/clients/rest/models/create_pull_request_from_step_run.py +0 -83
  53. hatchet_sdk/v0/clients/rest/models/create_sns_integration_request.py +0 -85
  54. hatchet_sdk/v0/clients/rest/models/create_tenant_alert_email_group_request.py +0 -83
  55. hatchet_sdk/v0/clients/rest/models/create_tenant_invite_request.py +0 -86
  56. hatchet_sdk/v0/clients/rest/models/create_tenant_request.py +0 -84
  57. hatchet_sdk/v0/clients/rest/models/cron_workflows.py +0 -131
  58. hatchet_sdk/v0/clients/rest/models/cron_workflows_list.py +0 -110
  59. hatchet_sdk/v0/clients/rest/models/cron_workflows_method.py +0 -37
  60. hatchet_sdk/v0/clients/rest/models/cron_workflows_order_by_field.py +0 -37
  61. hatchet_sdk/v0/clients/rest/models/event.py +0 -143
  62. hatchet_sdk/v0/clients/rest/models/event_data.py +0 -83
  63. hatchet_sdk/v0/clients/rest/models/event_key_list.py +0 -98
  64. hatchet_sdk/v0/clients/rest/models/event_list.py +0 -110
  65. hatchet_sdk/v0/clients/rest/models/event_order_by_direction.py +0 -37
  66. hatchet_sdk/v0/clients/rest/models/event_order_by_field.py +0 -36
  67. hatchet_sdk/v0/clients/rest/models/event_update_cancel200_response.py +0 -85
  68. hatchet_sdk/v0/clients/rest/models/event_workflow_run_summary.py +0 -116
  69. hatchet_sdk/v0/clients/rest/models/events.py +0 -110
  70. hatchet_sdk/v0/clients/rest/models/get_step_run_diff_response.py +0 -100
  71. hatchet_sdk/v0/clients/rest/models/github_app_installation.py +0 -107
  72. hatchet_sdk/v0/clients/rest/models/github_branch.py +0 -86
  73. hatchet_sdk/v0/clients/rest/models/github_repo.py +0 -86
  74. hatchet_sdk/v0/clients/rest/models/info_get_version200_response.py +0 -83
  75. hatchet_sdk/v0/clients/rest/models/job.py +0 -132
  76. hatchet_sdk/v0/clients/rest/models/job_run.py +0 -176
  77. hatchet_sdk/v0/clients/rest/models/job_run_status.py +0 -41
  78. hatchet_sdk/v0/clients/rest/models/link_github_repository_request.py +0 -106
  79. hatchet_sdk/v0/clients/rest/models/list_api_tokens_response.py +0 -110
  80. hatchet_sdk/v0/clients/rest/models/list_github_app_installations_response.py +0 -112
  81. hatchet_sdk/v0/clients/rest/models/list_pull_requests_response.py +0 -100
  82. hatchet_sdk/v0/clients/rest/models/list_slack_webhooks.py +0 -110
  83. hatchet_sdk/v0/clients/rest/models/list_sns_integrations.py +0 -110
  84. hatchet_sdk/v0/clients/rest/models/log_line.py +0 -94
  85. hatchet_sdk/v0/clients/rest/models/log_line_level.py +0 -39
  86. hatchet_sdk/v0/clients/rest/models/log_line_list.py +0 -110
  87. hatchet_sdk/v0/clients/rest/models/log_line_order_by_direction.py +0 -37
  88. hatchet_sdk/v0/clients/rest/models/log_line_order_by_field.py +0 -36
  89. hatchet_sdk/v0/clients/rest/models/pagination_response.py +0 -95
  90. hatchet_sdk/v0/clients/rest/models/pull_request.py +0 -112
  91. hatchet_sdk/v0/clients/rest/models/pull_request_state.py +0 -37
  92. hatchet_sdk/v0/clients/rest/models/queue_metrics.py +0 -97
  93. hatchet_sdk/v0/clients/rest/models/rate_limit.py +0 -117
  94. hatchet_sdk/v0/clients/rest/models/rate_limit_list.py +0 -110
  95. hatchet_sdk/v0/clients/rest/models/rate_limit_order_by_direction.py +0 -37
  96. hatchet_sdk/v0/clients/rest/models/rate_limit_order_by_field.py +0 -38
  97. hatchet_sdk/v0/clients/rest/models/recent_step_runs.py +0 -118
  98. hatchet_sdk/v0/clients/rest/models/reject_invite_request.py +0 -83
  99. hatchet_sdk/v0/clients/rest/models/replay_event_request.py +0 -85
  100. hatchet_sdk/v0/clients/rest/models/replay_workflow_runs_request.py +0 -85
  101. hatchet_sdk/v0/clients/rest/models/replay_workflow_runs_response.py +0 -100
  102. hatchet_sdk/v0/clients/rest/models/rerun_step_run_request.py +0 -83
  103. hatchet_sdk/v0/clients/rest/models/schedule_workflow_run_request.py +0 -92
  104. hatchet_sdk/v0/clients/rest/models/scheduled_run_status.py +0 -42
  105. hatchet_sdk/v0/clients/rest/models/scheduled_workflows.py +0 -149
  106. hatchet_sdk/v0/clients/rest/models/scheduled_workflows_list.py +0 -110
  107. hatchet_sdk/v0/clients/rest/models/scheduled_workflows_method.py +0 -37
  108. hatchet_sdk/v0/clients/rest/models/scheduled_workflows_order_by_field.py +0 -37
  109. hatchet_sdk/v0/clients/rest/models/semaphore_slots.py +0 -113
  110. hatchet_sdk/v0/clients/rest/models/slack_webhook.py +0 -127
  111. hatchet_sdk/v0/clients/rest/models/sns_integration.py +0 -114
  112. hatchet_sdk/v0/clients/rest/models/step.py +0 -123
  113. hatchet_sdk/v0/clients/rest/models/step_run.py +0 -202
  114. hatchet_sdk/v0/clients/rest/models/step_run_archive.py +0 -142
  115. hatchet_sdk/v0/clients/rest/models/step_run_archive_list.py +0 -110
  116. hatchet_sdk/v0/clients/rest/models/step_run_diff.py +0 -91
  117. hatchet_sdk/v0/clients/rest/models/step_run_event.py +0 -122
  118. hatchet_sdk/v0/clients/rest/models/step_run_event_list.py +0 -110
  119. hatchet_sdk/v0/clients/rest/models/step_run_event_reason.py +0 -52
  120. hatchet_sdk/v0/clients/rest/models/step_run_event_severity.py +0 -38
  121. hatchet_sdk/v0/clients/rest/models/step_run_status.py +0 -44
  122. hatchet_sdk/v0/clients/rest/models/tenant.py +0 -118
  123. hatchet_sdk/v0/clients/rest/models/tenant_alert_email_group.py +0 -98
  124. hatchet_sdk/v0/clients/rest/models/tenant_alert_email_group_list.py +0 -112
  125. hatchet_sdk/v0/clients/rest/models/tenant_alerting_settings.py +0 -143
  126. hatchet_sdk/v0/clients/rest/models/tenant_invite.py +0 -120
  127. hatchet_sdk/v0/clients/rest/models/tenant_invite_list.py +0 -110
  128. hatchet_sdk/v0/clients/rest/models/tenant_list.py +0 -110
  129. hatchet_sdk/v0/clients/rest/models/tenant_member.py +0 -123
  130. hatchet_sdk/v0/clients/rest/models/tenant_member_list.py +0 -110
  131. hatchet_sdk/v0/clients/rest/models/tenant_member_role.py +0 -38
  132. hatchet_sdk/v0/clients/rest/models/tenant_queue_metrics.py +0 -116
  133. hatchet_sdk/v0/clients/rest/models/tenant_resource.py +0 -40
  134. hatchet_sdk/v0/clients/rest/models/tenant_resource_limit.py +0 -135
  135. hatchet_sdk/v0/clients/rest/models/tenant_resource_policy.py +0 -102
  136. hatchet_sdk/v0/clients/rest/models/tenant_step_run_queue_metrics.py +0 -83
  137. hatchet_sdk/v0/clients/rest/models/trigger_workflow_run_request.py +0 -91
  138. hatchet_sdk/v0/clients/rest/models/update_tenant_alert_email_group_request.py +0 -83
  139. hatchet_sdk/v0/clients/rest/models/update_tenant_invite_request.py +0 -85
  140. hatchet_sdk/v0/clients/rest/models/update_tenant_request.py +0 -137
  141. hatchet_sdk/v0/clients/rest/models/update_worker_request.py +0 -87
  142. hatchet_sdk/v0/clients/rest/models/user.py +0 -126
  143. hatchet_sdk/v0/clients/rest/models/user_change_password_request.py +0 -88
  144. hatchet_sdk/v0/clients/rest/models/user_login_request.py +0 -86
  145. hatchet_sdk/v0/clients/rest/models/user_register_request.py +0 -91
  146. hatchet_sdk/v0/clients/rest/models/user_tenant_memberships_list.py +0 -110
  147. hatchet_sdk/v0/clients/rest/models/user_tenant_public.py +0 -86
  148. hatchet_sdk/v0/clients/rest/models/webhook_worker.py +0 -100
  149. hatchet_sdk/v0/clients/rest/models/webhook_worker_create_request.py +0 -94
  150. hatchet_sdk/v0/clients/rest/models/webhook_worker_create_response.py +0 -98
  151. hatchet_sdk/v0/clients/rest/models/webhook_worker_created.py +0 -102
  152. hatchet_sdk/v0/clients/rest/models/webhook_worker_list_response.py +0 -110
  153. hatchet_sdk/v0/clients/rest/models/webhook_worker_request.py +0 -102
  154. hatchet_sdk/v0/clients/rest/models/webhook_worker_request_list_response.py +0 -104
  155. hatchet_sdk/v0/clients/rest/models/webhook_worker_request_method.py +0 -38
  156. hatchet_sdk/v0/clients/rest/models/worker.py +0 -239
  157. hatchet_sdk/v0/clients/rest/models/worker_label.py +0 -102
  158. hatchet_sdk/v0/clients/rest/models/worker_list.py +0 -110
  159. hatchet_sdk/v0/clients/rest/models/worker_runtime_info.py +0 -103
  160. hatchet_sdk/v0/clients/rest/models/worker_runtime_sdks.py +0 -38
  161. hatchet_sdk/v0/clients/rest/models/worker_type.py +0 -38
  162. hatchet_sdk/v0/clients/rest/models/workflow.py +0 -165
  163. hatchet_sdk/v0/clients/rest/models/workflow_concurrency.py +0 -107
  164. hatchet_sdk/v0/clients/rest/models/workflow_deployment_config.py +0 -136
  165. hatchet_sdk/v0/clients/rest/models/workflow_kind.py +0 -38
  166. hatchet_sdk/v0/clients/rest/models/workflow_list.py +0 -120
  167. hatchet_sdk/v0/clients/rest/models/workflow_metrics.py +0 -97
  168. hatchet_sdk/v0/clients/rest/models/workflow_run.py +0 -188
  169. hatchet_sdk/v0/clients/rest/models/workflow_run_cancel200_response.py +0 -85
  170. hatchet_sdk/v0/clients/rest/models/workflow_run_list.py +0 -110
  171. hatchet_sdk/v0/clients/rest/models/workflow_run_order_by_direction.py +0 -37
  172. hatchet_sdk/v0/clients/rest/models/workflow_run_order_by_field.py +0 -39
  173. hatchet_sdk/v0/clients/rest/models/workflow_run_shape.py +0 -186
  174. hatchet_sdk/v0/clients/rest/models/workflow_run_status.py +0 -42
  175. hatchet_sdk/v0/clients/rest/models/workflow_run_triggered_by.py +0 -112
  176. hatchet_sdk/v0/clients/rest/models/workflow_runs_cancel_request.py +0 -85
  177. hatchet_sdk/v0/clients/rest/models/workflow_runs_metrics.py +0 -94
  178. hatchet_sdk/v0/clients/rest/models/workflow_runs_metrics_counts.py +0 -104
  179. hatchet_sdk/v0/clients/rest/models/workflow_tag.py +0 -84
  180. hatchet_sdk/v0/clients/rest/models/workflow_trigger_cron_ref.py +0 -86
  181. hatchet_sdk/v0/clients/rest/models/workflow_trigger_event_ref.py +0 -86
  182. hatchet_sdk/v0/clients/rest/models/workflow_triggers.py +0 -141
  183. hatchet_sdk/v0/clients/rest/models/workflow_update_request.py +0 -85
  184. hatchet_sdk/v0/clients/rest/models/workflow_version.py +0 -170
  185. hatchet_sdk/v0/clients/rest/models/workflow_version_concurrency.py +0 -114
  186. hatchet_sdk/v0/clients/rest/models/workflow_version_definition.py +0 -85
  187. hatchet_sdk/v0/clients/rest/models/workflow_version_meta.py +0 -123
  188. hatchet_sdk/v0/clients/rest/models/workflow_workers_count.py +0 -95
  189. hatchet_sdk/v0/clients/rest/rest.py +0 -187
  190. hatchet_sdk/v0/clients/rest/tenacity_utils.py +0 -39
  191. hatchet_sdk/v0/clients/rest_client.py +0 -622
  192. hatchet_sdk/v0/clients/run_event_listener.py +0 -260
  193. hatchet_sdk/v0/clients/workflow_listener.py +0 -277
  194. hatchet_sdk/v0/connection.py +0 -63
  195. hatchet_sdk/v0/context/__init__.py +0 -1
  196. hatchet_sdk/v0/context/context.py +0 -446
  197. hatchet_sdk/v0/context/worker_context.py +0 -28
  198. hatchet_sdk/v0/features/cron.py +0 -286
  199. hatchet_sdk/v0/features/scheduled.py +0 -248
  200. hatchet_sdk/v0/hatchet.py +0 -310
  201. hatchet_sdk/v0/labels.py +0 -10
  202. hatchet_sdk/v0/loader.py +0 -244
  203. hatchet_sdk/v0/metadata.py +0 -2
  204. hatchet_sdk/v0/opentelemetry/instrumentor.py +0 -393
  205. hatchet_sdk/v0/rate_limit.py +0 -126
  206. hatchet_sdk/v0/semver.py +0 -30
  207. hatchet_sdk/v0/token.py +0 -27
  208. hatchet_sdk/v0/utils/aio_utils.py +0 -137
  209. hatchet_sdk/v0/utils/backoff.py +0 -9
  210. hatchet_sdk/v0/utils/types.py +0 -8
  211. hatchet_sdk/v0/utils/typing.py +0 -12
  212. hatchet_sdk/v0/v2/callable.py +0 -202
  213. hatchet_sdk/v0/v2/concurrency.py +0 -47
  214. hatchet_sdk/v0/v2/hatchet.py +0 -224
  215. hatchet_sdk/v0/worker/__init__.py +0 -1
  216. hatchet_sdk/v0/worker/action_listener_process.py +0 -294
  217. hatchet_sdk/v0/worker/runner/run_loop_manager.py +0 -112
  218. hatchet_sdk/v0/worker/runner/runner.py +0 -460
  219. hatchet_sdk/v0/worker/runner/utils/capture_logs.py +0 -81
  220. hatchet_sdk/v0/worker/runner/utils/error_with_traceback.py +0 -6
  221. hatchet_sdk/v0/worker/worker.py +0 -391
  222. hatchet_sdk/v0/workflow.py +0 -261
  223. hatchet_sdk/v0/workflow_run.py +0 -59
  224. {hatchet_sdk-1.18.1.dist-info → hatchet_sdk-1.19.0.dist-info}/WHEEL +0 -0
  225. {hatchet_sdk-1.18.1.dist-info → hatchet_sdk-1.19.0.dist-info}/entry_points.txt +0 -0
@@ -1,872 +0,0 @@
1
- # coding: utf-8
2
-
3
- """
4
- Hatchet API
5
-
6
- The Hatchet API
7
-
8
- The version of the OpenAPI document: 1.0.0
9
- Generated by OpenAPI Generator (https://openapi-generator.tech)
10
-
11
- Do not edit the class manually.
12
- """ # noqa: E501
13
-
14
- import warnings
15
- from typing import Any, Dict, List, Optional, Tuple, Union
16
-
17
- from pydantic import Field, StrictFloat, StrictInt, StrictStr, validate_call
18
- from typing_extensions import Annotated
19
-
20
- from hatchet_sdk.v0.clients.rest.api_client import ApiClient, RequestSerialized
21
- from hatchet_sdk.v0.clients.rest.api_response import ApiResponse
22
- from hatchet_sdk.v0.clients.rest.models.create_sns_integration_request import (
23
- CreateSNSIntegrationRequest,
24
- )
25
- from hatchet_sdk.v0.clients.rest.models.list_sns_integrations import ListSNSIntegrations
26
- from hatchet_sdk.v0.clients.rest.models.sns_integration import SNSIntegration
27
- from hatchet_sdk.v0.clients.rest.rest import RESTResponseType
28
-
29
-
30
- class SNSApi:
31
- """NOTE: This class is auto generated by OpenAPI Generator
32
- Ref: https://openapi-generator.tech
33
-
34
- Do not edit the class manually.
35
- """
36
-
37
- def __init__(self, api_client=None) -> None:
38
- if api_client is None:
39
- api_client = ApiClient.get_default()
40
- self.api_client = api_client
41
-
42
- @validate_call
43
- async def sns_create(
44
- self,
45
- tenant: Annotated[
46
- str,
47
- Field(
48
- min_length=36, strict=True, max_length=36, description="The tenant id"
49
- ),
50
- ],
51
- create_sns_integration_request: Optional[CreateSNSIntegrationRequest] = None,
52
- _request_timeout: Union[
53
- None,
54
- Annotated[StrictFloat, Field(gt=0)],
55
- Tuple[
56
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
57
- ],
58
- ] = None,
59
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
60
- _content_type: Optional[StrictStr] = None,
61
- _headers: Optional[Dict[StrictStr, Any]] = None,
62
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
63
- ) -> SNSIntegration:
64
- """Create SNS integration
65
-
66
- Create SNS integration
67
-
68
- :param tenant: The tenant id (required)
69
- :type tenant: str
70
- :param create_sns_integration_request:
71
- :type create_sns_integration_request: CreateSNSIntegrationRequest
72
- :param _request_timeout: timeout setting for this request. If one
73
- number provided, it will be total request
74
- timeout. It can also be a pair (tuple) of
75
- (connection, read) timeouts.
76
- :type _request_timeout: int, tuple(int, int), optional
77
- :param _request_auth: set to override the auth_settings for an a single
78
- request; this effectively ignores the
79
- authentication in the spec for a single request.
80
- :type _request_auth: dict, optional
81
- :param _content_type: force content-type for the request.
82
- :type _content_type: str, Optional
83
- :param _headers: set to override the headers for a single
84
- request; this effectively ignores the headers
85
- in the spec for a single request.
86
- :type _headers: dict, optional
87
- :param _host_index: set to override the host_index for a single
88
- request; this effectively ignores the host_index
89
- in the spec for a single request.
90
- :type _host_index: int, optional
91
- :return: Returns the result object.
92
- """ # noqa: E501
93
-
94
- _param = self._sns_create_serialize(
95
- tenant=tenant,
96
- create_sns_integration_request=create_sns_integration_request,
97
- _request_auth=_request_auth,
98
- _content_type=_content_type,
99
- _headers=_headers,
100
- _host_index=_host_index,
101
- )
102
-
103
- _response_types_map: Dict[str, Optional[str]] = {
104
- "201": "SNSIntegration",
105
- "400": "APIErrors",
106
- "401": "APIErrors",
107
- "405": "APIErrors",
108
- }
109
- response_data = await self.api_client.call_api(
110
- *_param, _request_timeout=_request_timeout
111
- )
112
- await response_data.read()
113
- return self.api_client.response_deserialize(
114
- response_data=response_data,
115
- response_types_map=_response_types_map,
116
- ).data
117
-
118
- @validate_call
119
- async def sns_create_with_http_info(
120
- self,
121
- tenant: Annotated[
122
- str,
123
- Field(
124
- min_length=36, strict=True, max_length=36, description="The tenant id"
125
- ),
126
- ],
127
- create_sns_integration_request: Optional[CreateSNSIntegrationRequest] = None,
128
- _request_timeout: Union[
129
- None,
130
- Annotated[StrictFloat, Field(gt=0)],
131
- Tuple[
132
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
133
- ],
134
- ] = None,
135
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
136
- _content_type: Optional[StrictStr] = None,
137
- _headers: Optional[Dict[StrictStr, Any]] = None,
138
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
139
- ) -> ApiResponse[SNSIntegration]:
140
- """Create SNS integration
141
-
142
- Create SNS integration
143
-
144
- :param tenant: The tenant id (required)
145
- :type tenant: str
146
- :param create_sns_integration_request:
147
- :type create_sns_integration_request: CreateSNSIntegrationRequest
148
- :param _request_timeout: timeout setting for this request. If one
149
- number provided, it will be total request
150
- timeout. It can also be a pair (tuple) of
151
- (connection, read) timeouts.
152
- :type _request_timeout: int, tuple(int, int), optional
153
- :param _request_auth: set to override the auth_settings for an a single
154
- request; this effectively ignores the
155
- authentication in the spec for a single request.
156
- :type _request_auth: dict, optional
157
- :param _content_type: force content-type for the request.
158
- :type _content_type: str, Optional
159
- :param _headers: set to override the headers for a single
160
- request; this effectively ignores the headers
161
- in the spec for a single request.
162
- :type _headers: dict, optional
163
- :param _host_index: set to override the host_index for a single
164
- request; this effectively ignores the host_index
165
- in the spec for a single request.
166
- :type _host_index: int, optional
167
- :return: Returns the result object.
168
- """ # noqa: E501
169
-
170
- _param = self._sns_create_serialize(
171
- tenant=tenant,
172
- create_sns_integration_request=create_sns_integration_request,
173
- _request_auth=_request_auth,
174
- _content_type=_content_type,
175
- _headers=_headers,
176
- _host_index=_host_index,
177
- )
178
-
179
- _response_types_map: Dict[str, Optional[str]] = {
180
- "201": "SNSIntegration",
181
- "400": "APIErrors",
182
- "401": "APIErrors",
183
- "405": "APIErrors",
184
- }
185
- response_data = await self.api_client.call_api(
186
- *_param, _request_timeout=_request_timeout
187
- )
188
- await response_data.read()
189
- return self.api_client.response_deserialize(
190
- response_data=response_data,
191
- response_types_map=_response_types_map,
192
- )
193
-
194
- @validate_call
195
- async def sns_create_without_preload_content(
196
- self,
197
- tenant: Annotated[
198
- str,
199
- Field(
200
- min_length=36, strict=True, max_length=36, description="The tenant id"
201
- ),
202
- ],
203
- create_sns_integration_request: Optional[CreateSNSIntegrationRequest] = None,
204
- _request_timeout: Union[
205
- None,
206
- Annotated[StrictFloat, Field(gt=0)],
207
- Tuple[
208
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
209
- ],
210
- ] = None,
211
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
212
- _content_type: Optional[StrictStr] = None,
213
- _headers: Optional[Dict[StrictStr, Any]] = None,
214
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
215
- ) -> RESTResponseType:
216
- """Create SNS integration
217
-
218
- Create SNS integration
219
-
220
- :param tenant: The tenant id (required)
221
- :type tenant: str
222
- :param create_sns_integration_request:
223
- :type create_sns_integration_request: CreateSNSIntegrationRequest
224
- :param _request_timeout: timeout setting for this request. If one
225
- number provided, it will be total request
226
- timeout. It can also be a pair (tuple) of
227
- (connection, read) timeouts.
228
- :type _request_timeout: int, tuple(int, int), optional
229
- :param _request_auth: set to override the auth_settings for an a single
230
- request; this effectively ignores the
231
- authentication in the spec for a single request.
232
- :type _request_auth: dict, optional
233
- :param _content_type: force content-type for the request.
234
- :type _content_type: str, Optional
235
- :param _headers: set to override the headers for a single
236
- request; this effectively ignores the headers
237
- in the spec for a single request.
238
- :type _headers: dict, optional
239
- :param _host_index: set to override the host_index for a single
240
- request; this effectively ignores the host_index
241
- in the spec for a single request.
242
- :type _host_index: int, optional
243
- :return: Returns the result object.
244
- """ # noqa: E501
245
-
246
- _param = self._sns_create_serialize(
247
- tenant=tenant,
248
- create_sns_integration_request=create_sns_integration_request,
249
- _request_auth=_request_auth,
250
- _content_type=_content_type,
251
- _headers=_headers,
252
- _host_index=_host_index,
253
- )
254
-
255
- _response_types_map: Dict[str, Optional[str]] = {
256
- "201": "SNSIntegration",
257
- "400": "APIErrors",
258
- "401": "APIErrors",
259
- "405": "APIErrors",
260
- }
261
- response_data = await self.api_client.call_api(
262
- *_param, _request_timeout=_request_timeout
263
- )
264
- return response_data.response
265
-
266
- def _sns_create_serialize(
267
- self,
268
- tenant,
269
- create_sns_integration_request,
270
- _request_auth,
271
- _content_type,
272
- _headers,
273
- _host_index,
274
- ) -> RequestSerialized:
275
-
276
- _host = None
277
-
278
- _collection_formats: Dict[str, str] = {}
279
-
280
- _path_params: Dict[str, str] = {}
281
- _query_params: List[Tuple[str, str]] = []
282
- _header_params: Dict[str, Optional[str]] = _headers or {}
283
- _form_params: List[Tuple[str, str]] = []
284
- _files: Dict[
285
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
286
- ] = {}
287
- _body_params: Optional[bytes] = None
288
-
289
- # process the path parameters
290
- if tenant is not None:
291
- _path_params["tenant"] = tenant
292
- # process the query parameters
293
- # process the header parameters
294
- # process the form parameters
295
- # process the body parameter
296
- if create_sns_integration_request is not None:
297
- _body_params = create_sns_integration_request
298
-
299
- # set the HTTP header `Accept`
300
- if "Accept" not in _header_params:
301
- _header_params["Accept"] = self.api_client.select_header_accept(
302
- ["application/json"]
303
- )
304
-
305
- # set the HTTP header `Content-Type`
306
- if _content_type:
307
- _header_params["Content-Type"] = _content_type
308
- else:
309
- _default_content_type = self.api_client.select_header_content_type(
310
- ["application/json"]
311
- )
312
- if _default_content_type is not None:
313
- _header_params["Content-Type"] = _default_content_type
314
-
315
- # authentication setting
316
- _auth_settings: List[str] = ["cookieAuth", "bearerAuth"]
317
-
318
- return self.api_client.param_serialize(
319
- method="POST",
320
- resource_path="/api/v1/tenants/{tenant}/sns",
321
- path_params=_path_params,
322
- query_params=_query_params,
323
- header_params=_header_params,
324
- body=_body_params,
325
- post_params=_form_params,
326
- files=_files,
327
- auth_settings=_auth_settings,
328
- collection_formats=_collection_formats,
329
- _host=_host,
330
- _request_auth=_request_auth,
331
- )
332
-
333
- @validate_call
334
- async def sns_delete(
335
- self,
336
- sns: Annotated[
337
- str,
338
- Field(
339
- min_length=36,
340
- strict=True,
341
- max_length=36,
342
- description="The SNS integration id",
343
- ),
344
- ],
345
- _request_timeout: Union[
346
- None,
347
- Annotated[StrictFloat, Field(gt=0)],
348
- Tuple[
349
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
350
- ],
351
- ] = None,
352
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
353
- _content_type: Optional[StrictStr] = None,
354
- _headers: Optional[Dict[StrictStr, Any]] = None,
355
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
356
- ) -> None:
357
- """Delete SNS integration
358
-
359
- Delete SNS integration
360
-
361
- :param sns: The SNS integration id (required)
362
- :type sns: str
363
- :param _request_timeout: timeout setting for this request. If one
364
- number provided, it will be total request
365
- timeout. It can also be a pair (tuple) of
366
- (connection, read) timeouts.
367
- :type _request_timeout: int, tuple(int, int), optional
368
- :param _request_auth: set to override the auth_settings for an a single
369
- request; this effectively ignores the
370
- authentication in the spec for a single request.
371
- :type _request_auth: dict, optional
372
- :param _content_type: force content-type for the request.
373
- :type _content_type: str, Optional
374
- :param _headers: set to override the headers for a single
375
- request; this effectively ignores the headers
376
- in the spec for a single request.
377
- :type _headers: dict, optional
378
- :param _host_index: set to override the host_index for a single
379
- request; this effectively ignores the host_index
380
- in the spec for a single request.
381
- :type _host_index: int, optional
382
- :return: Returns the result object.
383
- """ # noqa: E501
384
-
385
- _param = self._sns_delete_serialize(
386
- sns=sns,
387
- _request_auth=_request_auth,
388
- _content_type=_content_type,
389
- _headers=_headers,
390
- _host_index=_host_index,
391
- )
392
-
393
- _response_types_map: Dict[str, Optional[str]] = {
394
- "204": None,
395
- "400": "APIErrors",
396
- "401": "APIErrors",
397
- "405": "APIErrors",
398
- }
399
- response_data = await self.api_client.call_api(
400
- *_param, _request_timeout=_request_timeout
401
- )
402
- await response_data.read()
403
- return self.api_client.response_deserialize(
404
- response_data=response_data,
405
- response_types_map=_response_types_map,
406
- ).data
407
-
408
- @validate_call
409
- async def sns_delete_with_http_info(
410
- self,
411
- sns: Annotated[
412
- str,
413
- Field(
414
- min_length=36,
415
- strict=True,
416
- max_length=36,
417
- description="The SNS integration id",
418
- ),
419
- ],
420
- _request_timeout: Union[
421
- None,
422
- Annotated[StrictFloat, Field(gt=0)],
423
- Tuple[
424
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
425
- ],
426
- ] = None,
427
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
428
- _content_type: Optional[StrictStr] = None,
429
- _headers: Optional[Dict[StrictStr, Any]] = None,
430
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
431
- ) -> ApiResponse[None]:
432
- """Delete SNS integration
433
-
434
- Delete SNS integration
435
-
436
- :param sns: The SNS integration id (required)
437
- :type sns: str
438
- :param _request_timeout: timeout setting for this request. If one
439
- number provided, it will be total request
440
- timeout. It can also be a pair (tuple) of
441
- (connection, read) timeouts.
442
- :type _request_timeout: int, tuple(int, int), optional
443
- :param _request_auth: set to override the auth_settings for an a single
444
- request; this effectively ignores the
445
- authentication in the spec for a single request.
446
- :type _request_auth: dict, optional
447
- :param _content_type: force content-type for the request.
448
- :type _content_type: str, Optional
449
- :param _headers: set to override the headers for a single
450
- request; this effectively ignores the headers
451
- in the spec for a single request.
452
- :type _headers: dict, optional
453
- :param _host_index: set to override the host_index for a single
454
- request; this effectively ignores the host_index
455
- in the spec for a single request.
456
- :type _host_index: int, optional
457
- :return: Returns the result object.
458
- """ # noqa: E501
459
-
460
- _param = self._sns_delete_serialize(
461
- sns=sns,
462
- _request_auth=_request_auth,
463
- _content_type=_content_type,
464
- _headers=_headers,
465
- _host_index=_host_index,
466
- )
467
-
468
- _response_types_map: Dict[str, Optional[str]] = {
469
- "204": None,
470
- "400": "APIErrors",
471
- "401": "APIErrors",
472
- "405": "APIErrors",
473
- }
474
- response_data = await self.api_client.call_api(
475
- *_param, _request_timeout=_request_timeout
476
- )
477
- await response_data.read()
478
- return self.api_client.response_deserialize(
479
- response_data=response_data,
480
- response_types_map=_response_types_map,
481
- )
482
-
483
- @validate_call
484
- async def sns_delete_without_preload_content(
485
- self,
486
- sns: Annotated[
487
- str,
488
- Field(
489
- min_length=36,
490
- strict=True,
491
- max_length=36,
492
- description="The SNS integration id",
493
- ),
494
- ],
495
- _request_timeout: Union[
496
- None,
497
- Annotated[StrictFloat, Field(gt=0)],
498
- Tuple[
499
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
500
- ],
501
- ] = None,
502
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
503
- _content_type: Optional[StrictStr] = None,
504
- _headers: Optional[Dict[StrictStr, Any]] = None,
505
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
506
- ) -> RESTResponseType:
507
- """Delete SNS integration
508
-
509
- Delete SNS integration
510
-
511
- :param sns: The SNS integration id (required)
512
- :type sns: str
513
- :param _request_timeout: timeout setting for this request. If one
514
- number provided, it will be total request
515
- timeout. It can also be a pair (tuple) of
516
- (connection, read) timeouts.
517
- :type _request_timeout: int, tuple(int, int), optional
518
- :param _request_auth: set to override the auth_settings for an a single
519
- request; this effectively ignores the
520
- authentication in the spec for a single request.
521
- :type _request_auth: dict, optional
522
- :param _content_type: force content-type for the request.
523
- :type _content_type: str, Optional
524
- :param _headers: set to override the headers for a single
525
- request; this effectively ignores the headers
526
- in the spec for a single request.
527
- :type _headers: dict, optional
528
- :param _host_index: set to override the host_index for a single
529
- request; this effectively ignores the host_index
530
- in the spec for a single request.
531
- :type _host_index: int, optional
532
- :return: Returns the result object.
533
- """ # noqa: E501
534
-
535
- _param = self._sns_delete_serialize(
536
- sns=sns,
537
- _request_auth=_request_auth,
538
- _content_type=_content_type,
539
- _headers=_headers,
540
- _host_index=_host_index,
541
- )
542
-
543
- _response_types_map: Dict[str, Optional[str]] = {
544
- "204": None,
545
- "400": "APIErrors",
546
- "401": "APIErrors",
547
- "405": "APIErrors",
548
- }
549
- response_data = await self.api_client.call_api(
550
- *_param, _request_timeout=_request_timeout
551
- )
552
- return response_data.response
553
-
554
- def _sns_delete_serialize(
555
- self,
556
- sns,
557
- _request_auth,
558
- _content_type,
559
- _headers,
560
- _host_index,
561
- ) -> RequestSerialized:
562
-
563
- _host = None
564
-
565
- _collection_formats: Dict[str, str] = {}
566
-
567
- _path_params: Dict[str, str] = {}
568
- _query_params: List[Tuple[str, str]] = []
569
- _header_params: Dict[str, Optional[str]] = _headers or {}
570
- _form_params: List[Tuple[str, str]] = []
571
- _files: Dict[
572
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
573
- ] = {}
574
- _body_params: Optional[bytes] = None
575
-
576
- # process the path parameters
577
- if sns is not None:
578
- _path_params["sns"] = sns
579
- # process the query parameters
580
- # process the header parameters
581
- # process the form parameters
582
- # process the body parameter
583
-
584
- # set the HTTP header `Accept`
585
- if "Accept" not in _header_params:
586
- _header_params["Accept"] = self.api_client.select_header_accept(
587
- ["application/json"]
588
- )
589
-
590
- # authentication setting
591
- _auth_settings: List[str] = ["cookieAuth", "bearerAuth"]
592
-
593
- return self.api_client.param_serialize(
594
- method="DELETE",
595
- resource_path="/api/v1/sns/{sns}",
596
- path_params=_path_params,
597
- query_params=_query_params,
598
- header_params=_header_params,
599
- body=_body_params,
600
- post_params=_form_params,
601
- files=_files,
602
- auth_settings=_auth_settings,
603
- collection_formats=_collection_formats,
604
- _host=_host,
605
- _request_auth=_request_auth,
606
- )
607
-
608
- @validate_call
609
- async def sns_list(
610
- self,
611
- tenant: Annotated[
612
- str,
613
- Field(
614
- min_length=36, strict=True, max_length=36, description="The tenant id"
615
- ),
616
- ],
617
- _request_timeout: Union[
618
- None,
619
- Annotated[StrictFloat, Field(gt=0)],
620
- Tuple[
621
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
622
- ],
623
- ] = None,
624
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
625
- _content_type: Optional[StrictStr] = None,
626
- _headers: Optional[Dict[StrictStr, Any]] = None,
627
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
628
- ) -> ListSNSIntegrations:
629
- """List SNS integrations
630
-
631
- List SNS integrations
632
-
633
- :param tenant: The tenant id (required)
634
- :type tenant: str
635
- :param _request_timeout: timeout setting for this request. If one
636
- number provided, it will be total request
637
- timeout. It can also be a pair (tuple) of
638
- (connection, read) timeouts.
639
- :type _request_timeout: int, tuple(int, int), optional
640
- :param _request_auth: set to override the auth_settings for an a single
641
- request; this effectively ignores the
642
- authentication in the spec for a single request.
643
- :type _request_auth: dict, optional
644
- :param _content_type: force content-type for the request.
645
- :type _content_type: str, Optional
646
- :param _headers: set to override the headers for a single
647
- request; this effectively ignores the headers
648
- in the spec for a single request.
649
- :type _headers: dict, optional
650
- :param _host_index: set to override the host_index for a single
651
- request; this effectively ignores the host_index
652
- in the spec for a single request.
653
- :type _host_index: int, optional
654
- :return: Returns the result object.
655
- """ # noqa: E501
656
-
657
- _param = self._sns_list_serialize(
658
- tenant=tenant,
659
- _request_auth=_request_auth,
660
- _content_type=_content_type,
661
- _headers=_headers,
662
- _host_index=_host_index,
663
- )
664
-
665
- _response_types_map: Dict[str, Optional[str]] = {
666
- "200": "ListSNSIntegrations",
667
- "400": "APIErrors",
668
- "401": "APIErrors",
669
- "405": "APIErrors",
670
- }
671
- response_data = await self.api_client.call_api(
672
- *_param, _request_timeout=_request_timeout
673
- )
674
- await response_data.read()
675
- return self.api_client.response_deserialize(
676
- response_data=response_data,
677
- response_types_map=_response_types_map,
678
- ).data
679
-
680
- @validate_call
681
- async def sns_list_with_http_info(
682
- self,
683
- tenant: Annotated[
684
- str,
685
- Field(
686
- min_length=36, strict=True, max_length=36, description="The tenant id"
687
- ),
688
- ],
689
- _request_timeout: Union[
690
- None,
691
- Annotated[StrictFloat, Field(gt=0)],
692
- Tuple[
693
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
694
- ],
695
- ] = None,
696
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
697
- _content_type: Optional[StrictStr] = None,
698
- _headers: Optional[Dict[StrictStr, Any]] = None,
699
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
700
- ) -> ApiResponse[ListSNSIntegrations]:
701
- """List SNS integrations
702
-
703
- List SNS integrations
704
-
705
- :param tenant: The tenant id (required)
706
- :type tenant: str
707
- :param _request_timeout: timeout setting for this request. If one
708
- number provided, it will be total request
709
- timeout. It can also be a pair (tuple) of
710
- (connection, read) timeouts.
711
- :type _request_timeout: int, tuple(int, int), optional
712
- :param _request_auth: set to override the auth_settings for an a single
713
- request; this effectively ignores the
714
- authentication in the spec for a single request.
715
- :type _request_auth: dict, optional
716
- :param _content_type: force content-type for the request.
717
- :type _content_type: str, Optional
718
- :param _headers: set to override the headers for a single
719
- request; this effectively ignores the headers
720
- in the spec for a single request.
721
- :type _headers: dict, optional
722
- :param _host_index: set to override the host_index for a single
723
- request; this effectively ignores the host_index
724
- in the spec for a single request.
725
- :type _host_index: int, optional
726
- :return: Returns the result object.
727
- """ # noqa: E501
728
-
729
- _param = self._sns_list_serialize(
730
- tenant=tenant,
731
- _request_auth=_request_auth,
732
- _content_type=_content_type,
733
- _headers=_headers,
734
- _host_index=_host_index,
735
- )
736
-
737
- _response_types_map: Dict[str, Optional[str]] = {
738
- "200": "ListSNSIntegrations",
739
- "400": "APIErrors",
740
- "401": "APIErrors",
741
- "405": "APIErrors",
742
- }
743
- response_data = await self.api_client.call_api(
744
- *_param, _request_timeout=_request_timeout
745
- )
746
- await response_data.read()
747
- return self.api_client.response_deserialize(
748
- response_data=response_data,
749
- response_types_map=_response_types_map,
750
- )
751
-
752
- @validate_call
753
- async def sns_list_without_preload_content(
754
- self,
755
- tenant: Annotated[
756
- str,
757
- Field(
758
- min_length=36, strict=True, max_length=36, description="The tenant id"
759
- ),
760
- ],
761
- _request_timeout: Union[
762
- None,
763
- Annotated[StrictFloat, Field(gt=0)],
764
- Tuple[
765
- Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
766
- ],
767
- ] = None,
768
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
769
- _content_type: Optional[StrictStr] = None,
770
- _headers: Optional[Dict[StrictStr, Any]] = None,
771
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
772
- ) -> RESTResponseType:
773
- """List SNS integrations
774
-
775
- List SNS integrations
776
-
777
- :param tenant: The tenant id (required)
778
- :type tenant: str
779
- :param _request_timeout: timeout setting for this request. If one
780
- number provided, it will be total request
781
- timeout. It can also be a pair (tuple) of
782
- (connection, read) timeouts.
783
- :type _request_timeout: int, tuple(int, int), optional
784
- :param _request_auth: set to override the auth_settings for an a single
785
- request; this effectively ignores the
786
- authentication in the spec for a single request.
787
- :type _request_auth: dict, optional
788
- :param _content_type: force content-type for the request.
789
- :type _content_type: str, Optional
790
- :param _headers: set to override the headers for a single
791
- request; this effectively ignores the headers
792
- in the spec for a single request.
793
- :type _headers: dict, optional
794
- :param _host_index: set to override the host_index for a single
795
- request; this effectively ignores the host_index
796
- in the spec for a single request.
797
- :type _host_index: int, optional
798
- :return: Returns the result object.
799
- """ # noqa: E501
800
-
801
- _param = self._sns_list_serialize(
802
- tenant=tenant,
803
- _request_auth=_request_auth,
804
- _content_type=_content_type,
805
- _headers=_headers,
806
- _host_index=_host_index,
807
- )
808
-
809
- _response_types_map: Dict[str, Optional[str]] = {
810
- "200": "ListSNSIntegrations",
811
- "400": "APIErrors",
812
- "401": "APIErrors",
813
- "405": "APIErrors",
814
- }
815
- response_data = await self.api_client.call_api(
816
- *_param, _request_timeout=_request_timeout
817
- )
818
- return response_data.response
819
-
820
- def _sns_list_serialize(
821
- self,
822
- tenant,
823
- _request_auth,
824
- _content_type,
825
- _headers,
826
- _host_index,
827
- ) -> RequestSerialized:
828
-
829
- _host = None
830
-
831
- _collection_formats: Dict[str, str] = {}
832
-
833
- _path_params: Dict[str, str] = {}
834
- _query_params: List[Tuple[str, str]] = []
835
- _header_params: Dict[str, Optional[str]] = _headers or {}
836
- _form_params: List[Tuple[str, str]] = []
837
- _files: Dict[
838
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
839
- ] = {}
840
- _body_params: Optional[bytes] = None
841
-
842
- # process the path parameters
843
- if tenant is not None:
844
- _path_params["tenant"] = tenant
845
- # process the query parameters
846
- # process the header parameters
847
- # process the form parameters
848
- # process the body parameter
849
-
850
- # set the HTTP header `Accept`
851
- if "Accept" not in _header_params:
852
- _header_params["Accept"] = self.api_client.select_header_accept(
853
- ["application/json"]
854
- )
855
-
856
- # authentication setting
857
- _auth_settings: List[str] = ["cookieAuth", "bearerAuth"]
858
-
859
- return self.api_client.param_serialize(
860
- method="GET",
861
- resource_path="/api/v1/tenants/{tenant}/sns",
862
- path_params=_path_params,
863
- query_params=_query_params,
864
- header_params=_header_params,
865
- body=_body_params,
866
- post_params=_form_params,
867
- files=_files,
868
- auth_settings=_auth_settings,
869
- collection_formats=_collection_formats,
870
- _host=_host,
871
- _request_auth=_request_auth,
872
- )