octostar-python-client 0.1.759__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (257) hide show
  1. octostar/__init__.py +9 -0
  2. octostar/api/__init__.py +1 -0
  3. octostar/api/apps/__init__.py +0 -0
  4. octostar/api/apps/deploy_app.py +210 -0
  5. octostar/api/apps/execute_app_job.py +188 -0
  6. octostar/api/apps/get_app_logs.py +210 -0
  7. octostar/api/apps/get_apps_url.py +188 -0
  8. octostar/api/apps/get_job_logs.py +210 -0
  9. octostar/api/apps/get_job_progress.py +162 -0
  10. octostar/api/apps/kill_job.py +160 -0
  11. octostar/api/apps/list_app_jobs.py +276 -0
  12. octostar/api/apps/list_apps.py +251 -0
  13. octostar/api/apps/set_job_progress.py +216 -0
  14. octostar/api/apps/undeploy_app.py +160 -0
  15. octostar/api/metadata/__init__.py +0 -0
  16. octostar/api/metadata/get_version.py +232 -0
  17. octostar/api/metadata/get_whoami.py +232 -0
  18. octostar/api/notifications/__init__.py +0 -0
  19. octostar/api/notifications/delete_stream.py +222 -0
  20. octostar/api/notifications/get_subscriptions.py +240 -0
  21. octostar/api/notifications/publish_notification.py +275 -0
  22. octostar/api/notifications/pull_events_from_stream.py +282 -0
  23. octostar/api/notifications/push_event_to_stream.py +265 -0
  24. octostar/api/notifications/toast.py +264 -0
  25. octostar/api/ontology/__init__.py +0 -0
  26. octostar/api/ontology/fetch_ontology_data.py +275 -0
  27. octostar/api/ontology/get_ontologies.py +237 -0
  28. octostar/api/ontology/multi_query.py +297 -0
  29. octostar/api/ontology/query.py +276 -0
  30. octostar/api/pipeline/__init__.py +1 -0
  31. octostar/api/pipeline/get_processing_status.py +185 -0
  32. octostar/api/pipeline/update_processing_status.py +164 -0
  33. octostar/api/search/__init__.py +0 -0
  34. octostar/api/search/get_annotations.py +153 -0
  35. octostar/api/workspace_data/__init__.py +0 -0
  36. octostar/api/workspace_data/delete_blob.py +212 -0
  37. octostar/api/workspace_data/delete_entities.py +326 -0
  38. octostar/api/workspace_data/download_blob.py +235 -0
  39. octostar/api/workspace_data/get_attachment.py +336 -0
  40. octostar/api/workspace_data/get_files_tree.py +397 -0
  41. octostar/api/workspace_data/upload_blob.py +235 -0
  42. octostar/api/workspace_data/upsert_entities.py +284 -0
  43. octostar/api/workspace_permissions/__init__.py +0 -0
  44. octostar/api/workspace_permissions/get_permissions.py +325 -0
  45. octostar/api/workspace_tags/__init__.py +0 -0
  46. octostar/api/workspace_tags/delete_tag_from_entities.py +141 -0
  47. octostar/api/workspace_tags/tag_entities.py +180 -0
  48. octostar/client.py +492 -0
  49. octostar/errors.py +50 -0
  50. octostar/models/__init__.py +249 -0
  51. octostar/models/acknowledgement.py +74 -0
  52. octostar/models/acknowledgement_with_data.py +82 -0
  53. octostar/models/app_status.py +239 -0
  54. octostar/models/app_status_annotations.py +66 -0
  55. octostar/models/app_status_labels.py +69 -0
  56. octostar/models/app_with_url.py +82 -0
  57. octostar/models/child_processing_status.py +118 -0
  58. octostar/models/delete_entities_response_401.py +74 -0
  59. octostar/models/delete_entities_response_409.py +82 -0
  60. octostar/models/delete_entities_response_500.py +82 -0
  61. octostar/models/delete_stream_response_401.py +74 -0
  62. octostar/models/delete_tag_from_entities_response_401.py +74 -0
  63. octostar/models/deploy_app_json_body.py +90 -0
  64. octostar/models/deploy_app_json_body_secrets.py +65 -0
  65. octostar/models/deploy_app_response_200.py +98 -0
  66. octostar/models/deploy_app_response_200_data.py +60 -0
  67. octostar/models/deploy_app_response_400.py +82 -0
  68. octostar/models/deploy_app_response_403.py +82 -0
  69. octostar/models/deploy_app_response_404.py +82 -0
  70. octostar/models/deploy_app_response_409.py +82 -0
  71. octostar/models/deploy_app_response_500.py +82 -0
  72. octostar/models/entity.py +80 -0
  73. octostar/models/entity_response.py +99 -0
  74. octostar/models/entity_response_s3_urls.py +93 -0
  75. octostar/models/entity_response_s3_urls_additional_property.py +105 -0
  76. octostar/models/entity_response_s3_urls_additional_property_fields.py +114 -0
  77. octostar/models/execute_app_job_json_body.py +151 -0
  78. octostar/models/execute_app_job_json_body_annotation.py +65 -0
  79. octostar/models/execute_app_job_response_401.py +74 -0
  80. octostar/models/fetch_ontology_data_response_200.py +60 -0
  81. octostar/models/fetch_ontology_data_response_401.py +74 -0
  82. octostar/models/fetch_ontology_data_response_500.py +82 -0
  83. octostar/models/get_app_logs_response_401.py +74 -0
  84. octostar/models/get_app_logs_response_404.py +74 -0
  85. octostar/models/get_app_logs_response_500.py +82 -0
  86. octostar/models/get_apps_url_json_body.py +76 -0
  87. octostar/models/get_apps_url_response_401.py +74 -0
  88. octostar/models/get_apps_url_response_500.py +82 -0
  89. octostar/models/get_attachment_response_200.py +74 -0
  90. octostar/models/get_attachment_response_401.py +74 -0
  91. octostar/models/get_files_tree_response_200.py +106 -0
  92. octostar/models/get_files_tree_response_200_status.py +8 -0
  93. octostar/models/get_files_tree_response_400.py +111 -0
  94. octostar/models/get_files_tree_response_400_data.py +60 -0
  95. octostar/models/get_files_tree_response_400_status.py +8 -0
  96. octostar/models/get_files_tree_response_401.py +74 -0
  97. octostar/models/get_files_tree_response_500.py +111 -0
  98. octostar/models/get_files_tree_response_500_data.py +60 -0
  99. octostar/models/get_files_tree_response_500_status.py +8 -0
  100. octostar/models/get_job_logs_response_401.py +74 -0
  101. octostar/models/get_job_logs_response_404.py +74 -0
  102. octostar/models/get_job_logs_response_500.py +82 -0
  103. octostar/models/get_job_progress_response_401.py +74 -0
  104. octostar/models/get_object_response_401.py +74 -0
  105. octostar/models/get_ontologies_response_401.py +74 -0
  106. octostar/models/get_ontologies_response_500.py +81 -0
  107. octostar/models/get_permissions_response_200.py +98 -0
  108. octostar/models/get_permissions_response_400.py +82 -0
  109. octostar/models/get_permissions_response_401.py +74 -0
  110. octostar/models/get_permissions_response_500.py +82 -0
  111. octostar/models/get_processing_status_response_200.py +104 -0
  112. octostar/models/get_processing_status_response_200_data.py +87 -0
  113. octostar/models/get_processing_status_response_400.py +82 -0
  114. octostar/models/get_processing_status_response_500.py +82 -0
  115. octostar/models/get_subscriptions_response_200_item.py +74 -0
  116. octostar/models/get_version_response_200.py +74 -0
  117. octostar/models/get_version_response_404.py +74 -0
  118. octostar/models/get_whoami_response_200.py +129 -0
  119. octostar/models/get_whoami_response_401.py +74 -0
  120. octostar/models/insert_entity.py +114 -0
  121. octostar/models/insert_entity_base.py +266 -0
  122. octostar/models/insert_entity_relationships_item.py +107 -0
  123. octostar/models/insert_entity_request.py +94 -0
  124. octostar/models/internal_server_error.py +82 -0
  125. octostar/models/job_execution_result.py +146 -0
  126. octostar/models/job_status.py +196 -0
  127. octostar/models/job_status_labels.py +60 -0
  128. octostar/models/job_with_url.py +82 -0
  129. octostar/models/kill_job_response_401.py +74 -0
  130. octostar/models/list_app_jobs_response_401.py +74 -0
  131. octostar/models/list_app_jobs_response_500.py +82 -0
  132. octostar/models/list_apps_response_401.py +74 -0
  133. octostar/models/list_apps_response_500.py +82 -0
  134. octostar/models/multi_query_json_body.py +100 -0
  135. octostar/models/multi_query_json_body_queries_item.py +80 -0
  136. octostar/models/multi_query_response_400.py +82 -0
  137. octostar/models/multi_query_response_401.py +74 -0
  138. octostar/models/not_found_error.py +74 -0
  139. octostar/models/octostar_event.py +96 -0
  140. octostar/models/octostar_event_octostar_payload.py +100 -0
  141. octostar/models/octostar_event_octostar_payload_level.py +11 -0
  142. octostar/models/os_notification.py +122 -0
  143. octostar/models/processing_status.py +262 -0
  144. octostar/models/processing_status_code.py +14 -0
  145. octostar/models/progress_request.py +73 -0
  146. octostar/models/publish_notification_response_401.py +74 -0
  147. octostar/models/pull_events_from_stream_response_401.py +74 -0
  148. octostar/models/push_event_to_stream_response_401.py +74 -0
  149. octostar/models/query_json_body.py +101 -0
  150. octostar/models/query_json_body_params.py +60 -0
  151. octostar/models/query_response_400.py +82 -0
  152. octostar/models/query_response_401.py +74 -0
  153. octostar/models/set_job_progress_response_401.py +74 -0
  154. octostar/models/string_to_value_label_map.py +99 -0
  155. octostar/models/string_to_value_label_map_data.py +89 -0
  156. octostar/models/string_to_value_label_map_data_additional_property.py +80 -0
  157. octostar/models/successful_get_tags.py +103 -0
  158. octostar/models/successful_insertion.py +98 -0
  159. octostar/models/tag_entities_response_401.py +74 -0
  160. octostar/models/toast_level.py +11 -0
  161. octostar/models/toast_response_401.py +74 -0
  162. octostar/models/undeploy_app_response_401.py +74 -0
  163. octostar/models/update_processing_status_response_200.py +82 -0
  164. octostar/models/update_processing_status_response_400.py +82 -0
  165. octostar/models/update_processing_status_response_500.py +82 -0
  166. octostar/models/upsert_entities_response_401.py +74 -0
  167. octostar/models/upsert_entity.py +114 -0
  168. octostar/models/upsert_entity_base.py +266 -0
  169. octostar/models/upsert_entity_relationships_item.py +107 -0
  170. octostar/py.typed +1 -0
  171. octostar/types.py +54 -0
  172. octostar/utils/__init__.py +15 -0
  173. octostar/utils/chat/__init__.py +0 -0
  174. octostar/utils/chat/chat.py +513 -0
  175. octostar/utils/chat/detokenize.py +105 -0
  176. octostar/utils/chat/get_default_model.py +50 -0
  177. octostar/utils/chat/list_models.py +91 -0
  178. octostar/utils/chat/tokenize.py +105 -0
  179. octostar/utils/commons.py +226 -0
  180. octostar/utils/exceptions.py +134 -0
  181. octostar/utils/jobs/__init__.py +0 -0
  182. octostar/utils/jobs/apps/__init__.py +0 -0
  183. octostar/utils/jobs/apps/deploy_app.py +81 -0
  184. octostar/utils/jobs/apps/execute_app_job.py +114 -0
  185. octostar/utils/jobs/apps/get_app_logs.py +113 -0
  186. octostar/utils/jobs/apps/get_app_secret.py +102 -0
  187. octostar/utils/jobs/apps/get_apps_url.py +73 -0
  188. octostar/utils/jobs/apps/list_app_jobs.py +62 -0
  189. octostar/utils/jobs/apps/list_apps.py +126 -0
  190. octostar/utils/jobs/apps/undeploy_app.py +48 -0
  191. octostar/utils/jobs/get_job_logs.py +113 -0
  192. octostar/utils/jobs/get_job_progress.py +76 -0
  193. octostar/utils/jobs/kill_job.py +47 -0
  194. octostar/utils/jobs/set_job_progress.py +67 -0
  195. octostar/utils/meta/__init__.py +0 -0
  196. octostar/utils/meta/get_version.py +30 -0
  197. octostar/utils/meta/get_whoami.py +30 -0
  198. octostar/utils/notifications/__init__.py +0 -0
  199. octostar/utils/notifications/delete_stream.py +58 -0
  200. octostar/utils/notifications/get_my_subscriptions.py +49 -0
  201. octostar/utils/notifications/publish_notification.py +73 -0
  202. octostar/utils/notifications/pull_event_from_stream.py +63 -0
  203. octostar/utils/notifications/pull_events_from_stream.py +64 -0
  204. octostar/utils/notifications/push_event_to_stream.py +109 -0
  205. octostar/utils/notifications/push_events_to_stream.py +137 -0
  206. octostar/utils/notifications/toast.py +92 -0
  207. octostar/utils/ontology/__init__.py +10 -0
  208. octostar/utils/ontology/fetch_ontology_data.py +141 -0
  209. octostar/utils/ontology/get_ontologies.py +55 -0
  210. octostar/utils/ontology/multiquery_ontology.py +287 -0
  211. octostar/utils/ontology/query_ontology.py +186 -0
  212. octostar/utils/pipeline/__init__.py +1 -0
  213. octostar/utils/pipeline/get_processing_status.py +230 -0
  214. octostar/utils/pipeline/update_processing_status.py +286 -0
  215. octostar/utils/search/__init__.py +11 -0
  216. octostar/utils/search/bulk_update.py +138 -0
  217. octostar/utils/search/count.py +117 -0
  218. octostar/utils/search/get_entity_annotations.py +304 -0
  219. octostar/utils/search/get_index_definition.py +111 -0
  220. octostar/utils/search/multi_search.py +129 -0
  221. octostar/utils/workspace/__init__.py +0 -0
  222. octostar/utils/workspace/delete_entities.py +247 -0
  223. octostar/utils/workspace/delete_entity.py +81 -0
  224. octostar/utils/workspace/delete_relationship.py +78 -0
  225. octostar/utils/workspace/delete_relationships.py +85 -0
  226. octostar/utils/workspace/delete_temporary_blob.py +85 -0
  227. octostar/utils/workspace/extract_entities.py +140 -0
  228. octostar/utils/workspace/get_filepath_from_item.py +85 -0
  229. octostar/utils/workspace/get_filepaths_from_items.py +100 -0
  230. octostar/utils/workspace/get_files_tree.py +102 -0
  231. octostar/utils/workspace/get_item_from_filepath.py +102 -0
  232. octostar/utils/workspace/get_items_from_filepaths.py +108 -0
  233. octostar/utils/workspace/linkcharts/__init__.py +0 -0
  234. octostar/utils/workspace/linkcharts/create_linkchart.py +241 -0
  235. octostar/utils/workspace/permissions/PermissionLevel.py +8 -0
  236. octostar/utils/workspace/permissions/__init__.py +1 -0
  237. octostar/utils/workspace/permissions/get_permissions.py +81 -0
  238. octostar/utils/workspace/read_attachment.py +284 -0
  239. octostar/utils/workspace/read_file.py +113 -0
  240. octostar/utils/workspace/read_temporary_blob.py +428 -0
  241. octostar/utils/workspace/saved_searches/__init__.py +0 -0
  242. octostar/utils/workspace/saved_searches/create_saved_search.py +183 -0
  243. octostar/utils/workspace/tags/__init__.py +0 -0
  244. octostar/utils/workspace/tags/delete_tag_from_entities.py +96 -0
  245. octostar/utils/workspace/tags/tag_entities.py +175 -0
  246. octostar/utils/workspace/upsert_entities.py +268 -0
  247. octostar/utils/workspace/upsert_entity.py +110 -0
  248. octostar/utils/workspace/upsert_relationship.py +128 -0
  249. octostar/utils/workspace/upsert_relationships.py +194 -0
  250. octostar/utils/workspace/write_attachment.py +263 -0
  251. octostar/utils/workspace/write_file.py +335 -0
  252. octostar/utils/workspace/write_temporary_blob.py +218 -0
  253. octostar_python_client-0.1.759.dist-info/METADATA +159 -0
  254. octostar_python_client-0.1.759.dist-info/RECORD +257 -0
  255. octostar_python_client-0.1.759.dist-info/WHEEL +5 -0
  256. octostar_python_client-0.1.759.dist-info/licenses/LICENSE +21 -0
  257. octostar_python_client-0.1.759.dist-info/top_level.txt +1 -0
@@ -0,0 +1,122 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ Type,
5
+ TypeVar,
6
+ Tuple,
7
+ Optional,
8
+ BinaryIO,
9
+ TextIO,
10
+ TYPE_CHECKING,
11
+ )
12
+
13
+ from typing import List
14
+
15
+
16
+ import attr
17
+
18
+ from ..types import UNSET, Unset
19
+
20
+ from typing import Union
21
+ from ..types import UNSET, Unset
22
+
23
+
24
+ T = TypeVar("T", bound="OsNotification")
25
+
26
+
27
+ @attr.s(auto_attribs=True)
28
+ class OsNotification:
29
+ """
30
+ ### Attributes:
31
+ * `channel (Union[Unset, str])`: None
32
+ * `workspace_id (Union[Unset, str])`: None
33
+ * `title (Union[Unset, str])`: None
34
+ * `body (Union[Unset, str])`: None
35
+ * `result_url (Union[Unset, str])`: None
36
+ * `type (Union[Unset, str])`: None
37
+ * `expires_at (Union[Unset, str])`: None
38
+ """
39
+
40
+ channel: Union[Unset, str] = UNSET
41
+ workspace_id: Union[Unset, str] = UNSET
42
+ title: Union[Unset, str] = UNSET
43
+ body: Union[Unset, str] = UNSET
44
+ result_url: Union[Unset, str] = UNSET
45
+ type: Union[Unset, str] = UNSET
46
+ expires_at: Union[Unset, str] = UNSET
47
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
48
+
49
+ def to_dict(self) -> Dict[str, Any]:
50
+ channel = self.channel
51
+ workspace_id = self.workspace_id
52
+ title = self.title
53
+ body = self.body
54
+ result_url = self.result_url
55
+ type = self.type
56
+ expires_at = self.expires_at
57
+
58
+ field_dict: Dict[str, Any] = {}
59
+ field_dict.update(self.additional_properties)
60
+ field_dict.update({})
61
+ if channel is not UNSET:
62
+ field_dict["channel"] = channel
63
+ if workspace_id is not UNSET:
64
+ field_dict["workspace_id"] = workspace_id
65
+ if title is not UNSET:
66
+ field_dict["title"] = title
67
+ if body is not UNSET:
68
+ field_dict["body"] = body
69
+ if result_url is not UNSET:
70
+ field_dict["result_url"] = result_url
71
+ if type is not UNSET:
72
+ field_dict["type"] = type
73
+ if expires_at is not UNSET:
74
+ field_dict["expires_at"] = expires_at
75
+
76
+ return field_dict
77
+
78
+ @classmethod
79
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
80
+ d = src_dict.copy()
81
+ channel = d.pop("channel", UNSET)
82
+
83
+ workspace_id = d.pop("workspace_id", UNSET)
84
+
85
+ title = d.pop("title", UNSET)
86
+
87
+ body = d.pop("body", UNSET)
88
+
89
+ result_url = d.pop("result_url", UNSET)
90
+
91
+ type = d.pop("type", UNSET)
92
+
93
+ expires_at = d.pop("expires_at", UNSET)
94
+
95
+ os_notification = cls(
96
+ channel=channel,
97
+ workspace_id=workspace_id,
98
+ title=title,
99
+ body=body,
100
+ result_url=result_url,
101
+ type=type,
102
+ expires_at=expires_at,
103
+ )
104
+
105
+ os_notification.additional_properties = d
106
+ return os_notification
107
+
108
+ @property
109
+ def additional_keys(self) -> List[str]:
110
+ return list(self.additional_properties.keys())
111
+
112
+ def __getitem__(self, key: str) -> Any:
113
+ return self.additional_properties[key]
114
+
115
+ def __setitem__(self, key: str, value: Any) -> None:
116
+ self.additional_properties[key] = value
117
+
118
+ def __delitem__(self, key: str) -> None:
119
+ del self.additional_properties[key]
120
+
121
+ def __contains__(self, key: str) -> bool:
122
+ return key in self.additional_properties
@@ -0,0 +1,262 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ List,
5
+ Type,
6
+ TypeVar,
7
+ Union,
8
+ )
9
+
10
+ import attr
11
+
12
+ from ..models.child_processing_status import ChildProcessingStatus
13
+ from ..models.processing_status_code import ProcessingStatusCode
14
+ from ..types import UNSET, Unset
15
+
16
+ APPEND_TOKEN = "$append"
17
+
18
+ T = TypeVar("T", bound="ProcessingStatus")
19
+
20
+
21
+ def _serialize_appendable_list(
22
+ value: Union[Unset, None, List[Union[str, ChildProcessingStatus, Dict[str, Any]]]],
23
+ ) -> Union[Unset, None, List[Any]]:
24
+ if isinstance(value, Unset):
25
+ return UNSET
26
+ if value is None:
27
+ return None
28
+ serialized: List[Any] = []
29
+ for item in value:
30
+ if isinstance(item, str):
31
+ serialized.append(item)
32
+ elif isinstance(item, ChildProcessingStatus):
33
+ serialized.append(item.to_dict())
34
+ else:
35
+ serialized.append(item)
36
+ return serialized
37
+
38
+
39
+ def _deserialize_appendable_list(
40
+ value: Any,
41
+ ) -> Union[Unset, None, List[Union[str, ChildProcessingStatus, Dict[str, Any]]]]:
42
+ if isinstance(value, Unset):
43
+ return UNSET
44
+ if value is None:
45
+ return None
46
+ out: List[Union[str, ChildProcessingStatus, Dict[str, Any]]] = []
47
+ for item in value:
48
+ if isinstance(item, str):
49
+ out.append(item)
50
+ elif isinstance(item, dict):
51
+ out.append(ChildProcessingStatus.from_dict(item))
52
+ else:
53
+ out.append(item)
54
+ return out
55
+
56
+
57
+ @attr.s(auto_attribs=True)
58
+ class ProcessingStatus:
59
+ """
60
+ Processing status for an entity in the NiFi pipeline.
61
+
62
+ Note: `timeout` is a caching field - it is NOT stored in the actual status data.
63
+ The ontology is determined from the x-ontology header, not from this model.
64
+
65
+ Required identity fields on every write:
66
+ - `entity_id`: the entity UID.
67
+ - `entity_type`: the entity type/concept. Treated as fundamental
68
+ identity (mirroring `entity_id`) -- the per-workspace stats
69
+ aggregation, the fragment-exclusion filter, and the recursive
70
+ rollup all read it without a presence check, so producers MUST
71
+ send it on every status write (including parent updates that
72
+ only append to `fragment_errors` / `fragment_warnings`).
73
+
74
+ Trust contract on read: the persisted status snapshot is fully
75
+ trustworthy only when `status_code` is **`COMPLETED`** or
76
+ **`FAILED`** (non-stale terminal states). `STALE` is also terminal
77
+ but signals an unsettled prior run -- the redeploy cleanup
78
+ transitions stuck-partial roots to `STALE` so a fresh run can
79
+ reprocess them, and whatever `detailed_status` is attached
80
+ reflects whatever the previous run managed to write before being
81
+ torn down. Callers that need a definitive answer should gate on
82
+ `status_code in {COMPLETED, FAILED}`.
83
+
84
+ fragment_errors / fragment_warnings / warnings each support two modes
85
+ via the `$append` sentinel-token convention:
86
+ - ["$append", err1, err2] -> append err1, err2 to existing list
87
+ - [err1, err2] -> replace entire list
88
+ - [] or None -> clear the list
89
+ - UNSET / omitted -> no change
90
+
91
+ ### Attributes:
92
+ * `entity_id (str)`: Identifier of the entity (required)
93
+ * `entity_type (str)`: Type of the entity (required)
94
+ * `status_code (Union[Unset, ProcessingStatusCode])`: Processing status code (optional)
95
+ * `entity_label (Union[Unset, str])`: Human-readable label for the entity
96
+ * `reason (Union[Unset, str])`: Reason for the status
97
+ * `timeout (Union[Unset, int])`: Redis cache TTL in seconds (not stored in status)
98
+ * `timestamp (Union[Unset, str])`: ISO timestamp when status was last updated
99
+ * `do_not_reindex_before (Union[Unset, str])`: UTC timestamp before which reindexing is rejected
100
+ * `do_not_update_before (Union[Unset, str])`: UTC timestamp; stale updates with older value are silently nooped
101
+ * `n_child_fragments (Union[Unset, int])`: Direct-child fragment count declared by this entity.
102
+ * `source_entity_uid (Union[Unset, str])`: Global-root UID. Required on every fragment write.
103
+ * `os_parent_uid (Union[Unset, str])`: Direct-parent UID. Required on every fragment write.
104
+ * `os_workspace (Union[Unset, str])`: Workspace UID; required for per-workspace stats bucketing.
105
+ * `fragment_errors (Union[Unset, None, List])`: Fragment processor errors, with optional $append token
106
+ * `fragment_warnings (Union[Unset, None, List])`: Fragment processor warnings, with optional $append token
107
+ * `warnings (Union[Unset, None, List])`: Entity-level warnings, with optional $append token
108
+ """
109
+
110
+ entity_id: str
111
+ entity_type: str
112
+ status_code: Union[Unset, ProcessingStatusCode] = UNSET
113
+ entity_label: Union[Unset, str] = UNSET
114
+ reason: Union[Unset, str] = UNSET
115
+ timeout: Union[Unset, int] = UNSET
116
+ timestamp: Union[Unset, str] = UNSET
117
+ do_not_reindex_before: Union[Unset, str] = UNSET
118
+ do_not_update_before: Union[Unset, str] = UNSET
119
+ n_child_fragments: Union[Unset, int] = UNSET
120
+ source_entity_uid: Union[Unset, str] = UNSET
121
+ os_parent_uid: Union[Unset, str] = UNSET
122
+ os_workspace: Union[Unset, str] = UNSET
123
+ fragment_errors: Union[
124
+ Unset, None, List[Union[str, ChildProcessingStatus, Dict[str, Any]]]
125
+ ] = UNSET
126
+ fragment_warnings: Union[
127
+ Unset, None, List[Union[str, ChildProcessingStatus, Dict[str, Any]]]
128
+ ] = UNSET
129
+ warnings: Union[
130
+ Unset, None, List[Union[str, ChildProcessingStatus, Dict[str, Any]]]
131
+ ] = UNSET
132
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
133
+
134
+ def to_dict(self) -> Dict[str, Any]:
135
+ entity_id = self.entity_id
136
+ entity_type = self.entity_type
137
+
138
+ status_code: Union[Unset, str] = UNSET
139
+ if not isinstance(self.status_code, Unset):
140
+ status_code = self.status_code.value
141
+
142
+ entity_label = self.entity_label
143
+ reason = self.reason
144
+ timeout = self.timeout
145
+ timestamp = self.timestamp
146
+ do_not_reindex_before = self.do_not_reindex_before
147
+ do_not_update_before = self.do_not_update_before
148
+ n_child_fragments = self.n_child_fragments
149
+ source_entity_uid = self.source_entity_uid
150
+ os_parent_uid = self.os_parent_uid
151
+ os_workspace = self.os_workspace
152
+
153
+ fragment_errors = _serialize_appendable_list(self.fragment_errors)
154
+ fragment_warnings = _serialize_appendable_list(self.fragment_warnings)
155
+ warnings = _serialize_appendable_list(self.warnings)
156
+
157
+ field_dict: Dict[str, Any] = {}
158
+ field_dict.update(self.additional_properties)
159
+ field_dict.update(
160
+ {
161
+ "entity_id": entity_id,
162
+ "entity_type": entity_type,
163
+ }
164
+ )
165
+ if status_code is not UNSET:
166
+ field_dict["status_code"] = status_code
167
+ if entity_label is not UNSET:
168
+ field_dict["entity_label"] = entity_label
169
+ if reason is not UNSET:
170
+ field_dict["reason"] = reason
171
+ if timeout is not UNSET:
172
+ field_dict["timeout"] = timeout
173
+ if timestamp is not UNSET:
174
+ field_dict["timestamp"] = timestamp
175
+ if do_not_reindex_before is not UNSET:
176
+ field_dict["do_not_reindex_before"] = do_not_reindex_before
177
+ if do_not_update_before is not UNSET:
178
+ field_dict["do_not_update_before"] = do_not_update_before
179
+ if n_child_fragments is not UNSET:
180
+ field_dict["n_child_fragments"] = n_child_fragments
181
+ if source_entity_uid is not UNSET:
182
+ field_dict["source_entity_uid"] = source_entity_uid
183
+ if os_parent_uid is not UNSET:
184
+ field_dict["os_parent_uid"] = os_parent_uid
185
+ if os_workspace is not UNSET:
186
+ field_dict["os_workspace"] = os_workspace
187
+ if not isinstance(fragment_errors, Unset):
188
+ field_dict["fragment_errors"] = fragment_errors
189
+ if not isinstance(fragment_warnings, Unset):
190
+ field_dict["fragment_warnings"] = fragment_warnings
191
+ if not isinstance(warnings, Unset):
192
+ field_dict["warnings"] = warnings
193
+
194
+ return field_dict
195
+
196
+ @classmethod
197
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
198
+ d = src_dict.copy()
199
+ entity_id = d.pop("entity_id")
200
+ entity_type = d.pop("entity_type")
201
+
202
+ _status_code = d.pop("status_code", UNSET)
203
+ status_code: Union[Unset, ProcessingStatusCode]
204
+ if isinstance(_status_code, Unset):
205
+ status_code = UNSET
206
+ else:
207
+ status_code = ProcessingStatusCode(_status_code)
208
+
209
+ entity_label = d.pop("entity_label", UNSET)
210
+ reason = d.pop("reason", UNSET)
211
+ timeout = d.pop("timeout", UNSET)
212
+ timestamp = d.pop("timestamp", UNSET)
213
+ do_not_reindex_before = d.pop("do_not_reindex_before", UNSET)
214
+ do_not_update_before = d.pop("do_not_update_before", UNSET)
215
+ n_child_fragments = d.pop("n_child_fragments", UNSET)
216
+ source_entity_uid = d.pop("source_entity_uid", UNSET)
217
+ os_parent_uid = d.pop("os_parent_uid", UNSET)
218
+ os_workspace = d.pop("os_workspace", UNSET)
219
+
220
+ fragment_errors = _deserialize_appendable_list(d.pop("fragment_errors", UNSET))
221
+ fragment_warnings = _deserialize_appendable_list(
222
+ d.pop("fragment_warnings", UNSET)
223
+ )
224
+ warnings = _deserialize_appendable_list(d.pop("warnings", UNSET))
225
+
226
+ processing_status = cls(
227
+ entity_id=entity_id,
228
+ entity_type=entity_type,
229
+ status_code=status_code,
230
+ entity_label=entity_label,
231
+ reason=reason,
232
+ timeout=timeout,
233
+ timestamp=timestamp,
234
+ do_not_reindex_before=do_not_reindex_before,
235
+ do_not_update_before=do_not_update_before,
236
+ n_child_fragments=n_child_fragments,
237
+ source_entity_uid=source_entity_uid,
238
+ os_parent_uid=os_parent_uid,
239
+ os_workspace=os_workspace,
240
+ fragment_errors=fragment_errors,
241
+ fragment_warnings=fragment_warnings,
242
+ warnings=warnings,
243
+ )
244
+
245
+ processing_status.additional_properties = d
246
+ return processing_status
247
+
248
+ @property
249
+ def additional_keys(self) -> List[str]:
250
+ return list(self.additional_properties.keys())
251
+
252
+ def __getitem__(self, key: str) -> Any:
253
+ return self.additional_properties[key]
254
+
255
+ def __setitem__(self, key: str, value: Any) -> None:
256
+ self.additional_properties[key] = value
257
+
258
+ def __delitem__(self, key: str) -> None:
259
+ del self.additional_properties[key]
260
+
261
+ def __contains__(self, key: str) -> bool:
262
+ return key in self.additional_properties
@@ -0,0 +1,14 @@
1
+ from enum import Enum
2
+
3
+
4
+ class ProcessingStatusCode(str, Enum):
5
+ """Possible statuses of a NiFi pipeline task."""
6
+
7
+ RUNNING = "RUNNING"
8
+ COMPLETED = "COMPLETED"
9
+ FAILED = "FAILED"
10
+ STALE = "STALE"
11
+ UNKNOWN = "UNKNOWN"
12
+
13
+ def __str__(self) -> str:
14
+ return str(self.value)
@@ -0,0 +1,73 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ Type,
5
+ TypeVar,
6
+ Tuple,
7
+ Optional,
8
+ BinaryIO,
9
+ TextIO,
10
+ TYPE_CHECKING,
11
+ )
12
+
13
+ from typing import List
14
+
15
+
16
+ import attr
17
+
18
+ from ..types import UNSET, Unset
19
+
20
+
21
+ T = TypeVar("T", bound="ProgressRequest")
22
+
23
+
24
+ @attr.s(auto_attribs=True)
25
+ class ProgressRequest:
26
+ """
27
+ ### Attributes:
28
+ * `progress (str)`: The progress value string to set for the job.
29
+ """
30
+
31
+ progress: str
32
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
33
+
34
+ def to_dict(self) -> Dict[str, Any]:
35
+ progress = self.progress
36
+
37
+ field_dict: Dict[str, Any] = {}
38
+ field_dict.update(self.additional_properties)
39
+ field_dict.update(
40
+ {
41
+ "progress": progress,
42
+ }
43
+ )
44
+
45
+ return field_dict
46
+
47
+ @classmethod
48
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
49
+ d = src_dict.copy()
50
+ progress = d.pop("progress")
51
+
52
+ progress_request = cls(
53
+ progress=progress,
54
+ )
55
+
56
+ progress_request.additional_properties = d
57
+ return progress_request
58
+
59
+ @property
60
+ def additional_keys(self) -> List[str]:
61
+ return list(self.additional_properties.keys())
62
+
63
+ def __getitem__(self, key: str) -> Any:
64
+ return self.additional_properties[key]
65
+
66
+ def __setitem__(self, key: str, value: Any) -> None:
67
+ self.additional_properties[key] = value
68
+
69
+ def __delitem__(self, key: str) -> None:
70
+ del self.additional_properties[key]
71
+
72
+ def __contains__(self, key: str) -> bool:
73
+ return key in self.additional_properties
@@ -0,0 +1,74 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ Type,
5
+ TypeVar,
6
+ Tuple,
7
+ Optional,
8
+ BinaryIO,
9
+ TextIO,
10
+ TYPE_CHECKING,
11
+ )
12
+
13
+ from typing import List
14
+
15
+
16
+ import attr
17
+
18
+ from ..types import UNSET, Unset
19
+
20
+ from typing import Union
21
+ from ..types import UNSET, Unset
22
+
23
+
24
+ T = TypeVar("T", bound="PublishNotificationResponse401")
25
+
26
+
27
+ @attr.s(auto_attribs=True)
28
+ class PublishNotificationResponse401:
29
+ """
30
+ ### Attributes:
31
+ * `message (Union[Unset, str])`: None
32
+ """
33
+
34
+ message: Union[Unset, str] = UNSET
35
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
36
+
37
+ def to_dict(self) -> Dict[str, Any]:
38
+ message = self.message
39
+
40
+ field_dict: Dict[str, Any] = {}
41
+ field_dict.update(self.additional_properties)
42
+ field_dict.update({})
43
+ if message is not UNSET:
44
+ field_dict["message"] = message
45
+
46
+ return field_dict
47
+
48
+ @classmethod
49
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
50
+ d = src_dict.copy()
51
+ message = d.pop("message", UNSET)
52
+
53
+ publish_notification_response_401 = cls(
54
+ message=message,
55
+ )
56
+
57
+ publish_notification_response_401.additional_properties = d
58
+ return publish_notification_response_401
59
+
60
+ @property
61
+ def additional_keys(self) -> List[str]:
62
+ return list(self.additional_properties.keys())
63
+
64
+ def __getitem__(self, key: str) -> Any:
65
+ return self.additional_properties[key]
66
+
67
+ def __setitem__(self, key: str, value: Any) -> None:
68
+ self.additional_properties[key] = value
69
+
70
+ def __delitem__(self, key: str) -> None:
71
+ del self.additional_properties[key]
72
+
73
+ def __contains__(self, key: str) -> bool:
74
+ return key in self.additional_properties
@@ -0,0 +1,74 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ Type,
5
+ TypeVar,
6
+ Tuple,
7
+ Optional,
8
+ BinaryIO,
9
+ TextIO,
10
+ TYPE_CHECKING,
11
+ )
12
+
13
+ from typing import List
14
+
15
+
16
+ import attr
17
+
18
+ from ..types import UNSET, Unset
19
+
20
+ from typing import Union
21
+ from ..types import UNSET, Unset
22
+
23
+
24
+ T = TypeVar("T", bound="PullEventsFromStreamResponse401")
25
+
26
+
27
+ @attr.s(auto_attribs=True)
28
+ class PullEventsFromStreamResponse401:
29
+ """
30
+ ### Attributes:
31
+ * `message (Union[Unset, str])`: None
32
+ """
33
+
34
+ message: Union[Unset, str] = UNSET
35
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
36
+
37
+ def to_dict(self) -> Dict[str, Any]:
38
+ message = self.message
39
+
40
+ field_dict: Dict[str, Any] = {}
41
+ field_dict.update(self.additional_properties)
42
+ field_dict.update({})
43
+ if message is not UNSET:
44
+ field_dict["message"] = message
45
+
46
+ return field_dict
47
+
48
+ @classmethod
49
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
50
+ d = src_dict.copy()
51
+ message = d.pop("message", UNSET)
52
+
53
+ pull_events_from_stream_response_401 = cls(
54
+ message=message,
55
+ )
56
+
57
+ pull_events_from_stream_response_401.additional_properties = d
58
+ return pull_events_from_stream_response_401
59
+
60
+ @property
61
+ def additional_keys(self) -> List[str]:
62
+ return list(self.additional_properties.keys())
63
+
64
+ def __getitem__(self, key: str) -> Any:
65
+ return self.additional_properties[key]
66
+
67
+ def __setitem__(self, key: str, value: Any) -> None:
68
+ self.additional_properties[key] = value
69
+
70
+ def __delitem__(self, key: str) -> None:
71
+ del self.additional_properties[key]
72
+
73
+ def __contains__(self, key: str) -> bool:
74
+ return key in self.additional_properties
@@ -0,0 +1,74 @@
1
+ from typing import (
2
+ Any,
3
+ Dict,
4
+ Type,
5
+ TypeVar,
6
+ Tuple,
7
+ Optional,
8
+ BinaryIO,
9
+ TextIO,
10
+ TYPE_CHECKING,
11
+ )
12
+
13
+ from typing import List
14
+
15
+
16
+ import attr
17
+
18
+ from ..types import UNSET, Unset
19
+
20
+ from typing import Union
21
+ from ..types import UNSET, Unset
22
+
23
+
24
+ T = TypeVar("T", bound="PushEventToStreamResponse401")
25
+
26
+
27
+ @attr.s(auto_attribs=True)
28
+ class PushEventToStreamResponse401:
29
+ """
30
+ ### Attributes:
31
+ * `message (Union[Unset, str])`: None
32
+ """
33
+
34
+ message: Union[Unset, str] = UNSET
35
+ additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
36
+
37
+ def to_dict(self) -> Dict[str, Any]:
38
+ message = self.message
39
+
40
+ field_dict: Dict[str, Any] = {}
41
+ field_dict.update(self.additional_properties)
42
+ field_dict.update({})
43
+ if message is not UNSET:
44
+ field_dict["message"] = message
45
+
46
+ return field_dict
47
+
48
+ @classmethod
49
+ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
50
+ d = src_dict.copy()
51
+ message = d.pop("message", UNSET)
52
+
53
+ push_event_to_stream_response_401 = cls(
54
+ message=message,
55
+ )
56
+
57
+ push_event_to_stream_response_401.additional_properties = d
58
+ return push_event_to_stream_response_401
59
+
60
+ @property
61
+ def additional_keys(self) -> List[str]:
62
+ return list(self.additional_properties.keys())
63
+
64
+ def __getitem__(self, key: str) -> Any:
65
+ return self.additional_properties[key]
66
+
67
+ def __setitem__(self, key: str, value: Any) -> None:
68
+ self.additional_properties[key] = value
69
+
70
+ def __delitem__(self, key: str) -> None:
71
+ del self.additional_properties[key]
72
+
73
+ def __contains__(self, key: str) -> bool:
74
+ return key in self.additional_properties