kodexa 7.0.10668104287__py3-none-any.whl → 7.0.10779333544__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/platform/client.py CHANGED
@@ -5289,6 +5289,7 @@ class DocumentStoreEndpoint(StoreEndpoint):
5289
5289
  object_path: Optional[str] = None,
5290
5290
  replace=False,
5291
5291
  additional_metadata: Optional[dict] = None,
5292
+ external_data: Optional[dict] = None,
5292
5293
  ):
5293
5294
  """
5294
5295
  Upload a file to the store.
@@ -5298,6 +5299,7 @@ class DocumentStoreEndpoint(StoreEndpoint):
5298
5299
  object_path (Optional[str]): The path to the object (Default is the same the file path).
5299
5300
  replace (bool): Replace the file if it already exists (Default False).
5300
5301
  additional_metadata (Optional[dict]): Additional metadata to add to the file (Default None).
5302
+ external_data (Optional[dict]): External data to add to the file (Default None).
5301
5303
  """
5302
5304
  if Path(file_path).is_file():
5303
5305
  logger.info(f"Uploading {file_path}")
@@ -5307,6 +5309,7 @@ class DocumentStoreEndpoint(StoreEndpoint):
5307
5309
  content=path_content,
5308
5310
  replace=replace,
5309
5311
  additional_metadata=additional_metadata,
5312
+ external_data=external_data
5310
5313
  )
5311
5314
  else:
5312
5315
  raise Exception(f"{file_path} is not a file")
@@ -5317,6 +5320,7 @@ class DocumentStoreEndpoint(StoreEndpoint):
5317
5320
  content,
5318
5321
  replace=False,
5319
5322
  additional_metadata: Optional[dict] = None,
5323
+ external_data: Optional[dict] = None,
5320
5324
  ) -> DocumentFamilyEndpoint:
5321
5325
  """
5322
5326
  Put the content into the store at the given path.
@@ -5326,6 +5330,7 @@ class DocumentStoreEndpoint(StoreEndpoint):
5326
5330
  content: The content for that object.
5327
5331
  replace (bool): Replace the content if it exists.
5328
5332
  additional_metadata (Optional[dict]): Additional metadata to store with the document (not it can't include 'path').
5333
+ external_data (Optional[dict]): External data to store with the document.
5329
5334
 
5330
5335
  Returns:
5331
5336
  DocumentFamilyEndpoint: The document family that was created.
@@ -5335,6 +5340,9 @@ class DocumentStoreEndpoint(StoreEndpoint):
5335
5340
  if additional_metadata is None:
5336
5341
  additional_metadata = {}
5337
5342
 
5343
+ if external_data is None:
5344
+ additional_metadata["externalData"] = json.dumps(external_data)
5345
+
5338
5346
  if replace and self.client.exists(
5339
5347
  f"/api/stores/{self.ref.replace(':', '/')}/fs", params={"path": path}
5340
5348
  ):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: kodexa
3
- Version: 7.0.10668104287
3
+ Version: 7.0.10779333544
4
4
  Summary: Python SDK for the Kodexa Platform
5
5
  Author: Austin Redenbaugh
6
6
  Author-email: austin@kodexa.com
@@ -17,7 +17,7 @@ kodexa/model/persistence.py,sha256=w4WGS_qH1iowH8-ZMawZBZ2RFW3bNvmFy5fgSwr6VmQ,6
17
17
  kodexa/pipeline/__init__.py,sha256=sA7f5D6qkdMrpp2xTIeefnrUBI6xxEEWostvxfX_1Cs,236
18
18
  kodexa/pipeline/pipeline.py,sha256=ZYpJAWcwV4YRK589DUhU0vXGQlkNSj4J2TsGbYqTLjo,25221
19
19
  kodexa/platform/__init__.py,sha256=1O3oiWMg292NPL_NacKDnK1T3_R6cMorrPRue_9e-O4,216
20
- kodexa/platform/client.py,sha256=GCOlFN7BgnCDEg4MNiLgDmSCHGglWdMeCrQQH6y2_oM,222182
20
+ kodexa/platform/client.py,sha256=QasJ7fpIUByaIF-8Flo0ZCnr3vwNtI4NqMiYAGH0FAo,222620
21
21
  kodexa/platform/interaction.py,sha256=6zpcwXKNZstUGNS6m4JsoRXAqCZPJHWI-ZN3co8nnF0,1055
22
22
  kodexa/platform/kodexa.py,sha256=RVtArtzn1TVhBf3NGC4xe-ZO-VEVDIC3RjLhR06p-uU,34033
23
23
  kodexa/selectors/__init__.py,sha256=xA9-4vpyaAZWPSk3bh2kvDLkdv6XEmm7PjFbpziiTIk,100
@@ -42,7 +42,7 @@ kodexa/testing/test_utils.py,sha256=DrLCkHxdb6AbZ-X3WmTMbQmnVIm55VEBL8MjtUK9POs,
42
42
  kodexa/training/__init__.py,sha256=xs2L62YpRkIRfslQwtQZ5Yxjhm7sLzX2TrVX6EuBnZQ,52
43
43
  kodexa/training/train_utils.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
44
44
  kodexa/utils/__init__.py,sha256=Pnim1o9_db5YEnNvDTxpM7HG-qTlL6n8JwFwOafU9wo,5928
45
- kodexa-7.0.10668104287.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
46
- kodexa-7.0.10668104287.dist-info/METADATA,sha256=mu-2vpI0y0Sxmu89LMw1mAjpz_A-Z_X9Vvon3_JBk5s,3533
47
- kodexa-7.0.10668104287.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
48
- kodexa-7.0.10668104287.dist-info/RECORD,,
45
+ kodexa-7.0.10779333544.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
46
+ kodexa-7.0.10779333544.dist-info/METADATA,sha256=oqcy8F5XSpCB8JumbGcSuwMMX3pO8YM8av0Vb1RzbLw,3533
47
+ kodexa-7.0.10779333544.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
48
+ kodexa-7.0.10779333544.dist-info/RECORD,,