kodexa 7.0.9821365257__py3-none-any.whl → 7.0.9962385482__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.
kodexa/model/objects.py CHANGED
@@ -3851,6 +3851,18 @@ class DocumentEmbedding(BaseModel):
3851
3851
  node_uuid: Optional[str] = Field(None, alias="nodeUuid")
3852
3852
 
3853
3853
 
3854
+ class DocumentExternalData(BaseModel):
3855
+ model_config = ConfigDict(
3856
+ populate_by_name=True,
3857
+ use_enum_values=True,
3858
+ arbitrary_types_allowed=True,
3859
+ protected_namespaces=("model_config",),
3860
+ )
3861
+
3862
+ external_data: Optional[Dict[str, Any]] = Field(None, alias="externalData")
3863
+ document_family: Optional[DocumentFamily] = Field(None, alias="documentFamily")
3864
+
3865
+
3854
3866
  class DocumentFamily(BaseModel):
3855
3867
  """
3856
3868
 
kodexa/platform/client.py CHANGED
@@ -86,6 +86,7 @@ from kodexa.model.objects import (
86
86
  PageExtensionPack,
87
87
  PageOrganization,
88
88
  DocumentFamilyStatistics, MessageContext, PagePrompt, Prompt, GuidanceSet, PageGuidanceSet, DocumentEmbedding,
89
+ DocumentExternalData,
89
90
  )
90
91
 
91
92
  logger = logging.getLogger()
@@ -4456,6 +4457,28 @@ class DocumentFamilyEndpoint(DocumentFamily, ClientEndpoint):
4456
4457
  response = self.client.get(url)
4457
4458
  process_response(response)
4458
4459
 
4460
+ def get_external_data(self) -> DocumentExternalData:
4461
+ """
4462
+ Get the external data of the document family.
4463
+
4464
+ Returns:
4465
+ DocumentExternalData: The external data of the document family.
4466
+ """
4467
+ url = f"/api/documentFamilies/{self.id}/externalData"
4468
+ response = self.client.get(url)
4469
+ return DocumentExternalData.model_validate(response.json())
4470
+
4471
+ def update_external_data(self, external_data: DocumentExternalData):
4472
+ """
4473
+ Update the external data of the document family.
4474
+
4475
+ Args:
4476
+ external_data (DocumentExternalData): The external data to update.
4477
+ """
4478
+ url = f"/api/documentFamilies/{self.id}/externalData"
4479
+ response = self.client.put(url, body=external_data.model_dump(mode="json", by_alias=True))
4480
+ process_response(response)
4481
+
4459
4482
  def export(self) -> bytes:
4460
4483
  """
4461
4484
  Export the document family as bytes.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: kodexa
3
- Version: 7.0.9821365257
3
+ Version: 7.0.9962385482
4
4
  Summary: Python SDK for the Kodexa Platform
5
5
  Author: Austin Redenbaugh
6
6
  Author-email: austin@kodexa.com
@@ -9,12 +9,12 @@ kodexa/model/entities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3h
9
9
  kodexa/model/entities/product.py,sha256=ZDpHuBE_9FJ-klnkyBvTfPwYOqBkM1wraZMtHqNA8FQ,3526
10
10
  kodexa/model/entities/product_subscription.py,sha256=UcmWR-qgLfdV7VCtJNwzgkanoS8nBSL6ngVuxQUK1M8,3810
11
11
  kodexa/model/model.py,sha256=BURhrOEVTTlKkDJho5CEFeLR9Dyq157mztlvbAdL1d4,115769
12
- kodexa/model/objects.py,sha256=Rxa9gljfs2bq2UrRfsDJKerBvlEA8WY5wiDriqROBYU,175797
12
+ kodexa/model/objects.py,sha256=1do5qAkQu-zVnkRpfWkDaEJk-qlgTL_mLhYIlXjg-ec,176187
13
13
  kodexa/model/persistence.py,sha256=sx5FwTSsWMdAZpAs0-6PqyULHkQyNQClApUKJZ-ly8M,62032
14
14
  kodexa/pipeline/__init__.py,sha256=sA7f5D6qkdMrpp2xTIeefnrUBI6xxEEWostvxfX_1Cs,236
15
15
  kodexa/pipeline/pipeline.py,sha256=ZYpJAWcwV4YRK589DUhU0vXGQlkNSj4J2TsGbYqTLjo,25221
16
16
  kodexa/platform/__init__.py,sha256=1O3oiWMg292NPL_NacKDnK1T3_R6cMorrPRue_9e-O4,216
17
- kodexa/platform/client.py,sha256=htzLV7xdiYIdO5d8essrjtRhUgUQwVc7sAKHO8ijqjQ,221173
17
+ kodexa/platform/client.py,sha256=ZctQyY_iHmEO7ukPeiyBAD-Ad1mMQhSXJr7-d5JNLzQ,222044
18
18
  kodexa/platform/interaction.py,sha256=6zpcwXKNZstUGNS6m4JsoRXAqCZPJHWI-ZN3co8nnF0,1055
19
19
  kodexa/platform/kodexa.py,sha256=Bvf6x43FWsFuAuQ4N8TvjSZq6niEtBTESmFCWVPASeQ,34024
20
20
  kodexa/selectors/__init__.py,sha256=xA9-4vpyaAZWPSk3bh2kvDLkdv6XEmm7PjFbpziiTIk,100
@@ -38,7 +38,7 @@ kodexa/testing/test_components.py,sha256=g5lP-GY0nTHuH5cIEw45vIejEeBaWkPKQGHL36j
38
38
  kodexa/testing/test_utils.py,sha256=DrLCkHxdb6AbZ-X3WmTMbQmnVIm55VEBL8MjtUK9POs,14021
39
39
  kodexa/training/__init__.py,sha256=xs2L62YpRkIRfslQwtQZ5Yxjhm7sLzX2TrVX6EuBnZQ,52
40
40
  kodexa/training/train_utils.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
41
- kodexa-7.0.9821365257.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
42
- kodexa-7.0.9821365257.dist-info/METADATA,sha256=BsIl0NIubn2MCkzp2f1loXEFYeGpuWXXWUZ2a-6uFSA,3486
43
- kodexa-7.0.9821365257.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
44
- kodexa-7.0.9821365257.dist-info/RECORD,,
41
+ kodexa-7.0.9962385482.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
42
+ kodexa-7.0.9962385482.dist-info/METADATA,sha256=cHyEzjNUb9IfAq9JTHKGV6T8NyCkl6gVnCzUXEkmoys,3486
43
+ kodexa-7.0.9962385482.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
44
+ kodexa-7.0.9962385482.dist-info/RECORD,,