From d3668ffda36ea3aaa6b04b620b49aafb18385baa Mon Sep 17 00:00:00 2001
From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com>
Date: Wed, 8 Apr 2026 19:47:23 +0000
Subject: [PATCH] SDK regeneration
---
poetry.lock | 96 +++----
pyproject.toml | 2 +-
reference.md | 159 ++++++++--
src/polytomic/__init__.py | 14 +-
src/polytomic/bulk_sync/client.py | 15 +-
src/polytomic/bulk_sync/executions/client.py | 6 +-
src/polytomic/bulk_sync/schedules/client.py | 2 +-
src/polytomic/bulk_sync/types/__init__.py | 4 +-
...2create_bulk_sync_request_schemas_item.py} | 0
...2update_bulk_sync_request_schemas_item.py} | 0
src/polytomic/client.py | 8 +-
src/polytomic/connections/client.py | 272 ++++++++++++++++--
src/polytomic/core/client_wrapper.py | 8 +-
src/polytomic/events/client.py | 4 +
src/polytomic/jobs/client.py | 16 +-
src/polytomic/model_sync/client.py | 2 +
src/polytomic/model_sync/executions/client.py | 2 +-
src/polytomic/model_sync/targets/client.py | 8 +-
src/polytomic/models/client.py | 14 +-
src/polytomic/notifications/client.py | 2 +-
src/polytomic/organization/client.py | 61 ++++
src/polytomic/query_runner/client.py | 14 +-
src/polytomic/schemas/client.py | 2 +-
src/polytomic/types/__init__.py | 60 ++--
.../types/bulk_output_disposition.py | 5 +
src/polytomic/types/bulk_resync_mode.py | 5 +
src/polytomic/types/bulk_schema.py | 14 +-
.../types/bulk_schema_execution_status.py | 4 +-
src/polytomic/types/bulk_sync_dest.py | 7 +-
src/polytomic/types/bulk_sync_execution.py | 2 +
.../types/bulk_sync_ingestion_status.py | 28 ++
src/polytomic/types/bulk_sync_response.py | 6 +-
src/polytomic/types/bulk_sync_source.py | 2 +
.../types/bulk_sync_status_response.py | 2 +
.../types/connection_response_schema.py | 12 +-
src/polytomic/types/connection_type.py | 2 +-
src/polytomic/types/enrichment.py | 4 +-
src/polytomic/types/ingestion_status_level.py | 5 +
src/polytomic/types/jsonschema_schema.py | 2 +-
src/polytomic/types/model_field.py | 4 +-
src/polytomic/types/model_response.py | 6 +-
src/polytomic/types/model_sample.py | 2 +-
src/polytomic/types/model_sync_mode.py | 2 +-
src/polytomic/types/model_sync_response.py | 6 +-
...common_output_actor.py => output_actor.py} | 2 +-
src/polytomic/types/schema_configuration.py | 2 +-
...onnection_form.py => v2connection_form.py} | 0
...te_shared_connection_response_envelope.py} | 0
...uration.py => v2enricher_configuration.py} | 0
...icher_mapping.py => v2enricher_mapping.py} | 0
...on_log_type.py => v2execution_log_type.py} | 0
...ichment_input_fields_response_envelope.py} | 0
...g_github_com_invopop_jsonschema_schema.py} | 0
..._2_sample_record.py => v2sample_record.py} | 0
... => v2schema_configuration_fields_item.py} | 0
.../types/v3bulk_sync_source_capabilities.py | 19 ++
..._logs.py => v4bulk_sync_execution_logs.py} | 0
...=> v4bulk_sync_execution_logs_envelope.py} | 2 +-
...ule_api.py => v4bulk_sync_schedule_api.py} | 0
...lope.py => v4export_sync_logs_envelope.py} | 2 +-
...onse.py => v4export_sync_logs_response.py} | 0
...=> v4global_error_subscribers_response.py} | 0
...nvelope.py => v4query_results_envelope.py} | 2 +-
...ry_envelope.py => v4run_query_envelope.py} | 2 +-
..._query_result.py => v4run_query_result.py} | 2 +-
..._target_creator.py => v4target_creator.py} | 0
... => v4target_objects_response_envelope.py} | 2 +-
..._values.py => v4target_property_values.py} | 0
...y => v4target_property_values_envelope.py} | 2 +-
...eld_request.py => v4user_field_request.py} | 0
src/polytomic/users/client.py | 68 +++--
71 files changed, 789 insertions(+), 207 deletions(-)
rename src/polytomic/bulk_sync/types/{v_2_create_bulk_sync_request_schemas_item.py => v2create_bulk_sync_request_schemas_item.py} (100%)
rename src/polytomic/bulk_sync/types/{v_2_update_bulk_sync_request_schemas_item.py => v2update_bulk_sync_request_schemas_item.py} (100%)
create mode 100644 src/polytomic/types/bulk_output_disposition.py
create mode 100644 src/polytomic/types/bulk_resync_mode.py
create mode 100644 src/polytomic/types/bulk_sync_ingestion_status.py
create mode 100644 src/polytomic/types/ingestion_status_level.py
rename src/polytomic/types/{common_output_actor.py => output_actor.py} (93%)
rename src/polytomic/types/{v_2_connection_form.py => v2connection_form.py} (100%)
rename src/polytomic/types/{v_2_create_shared_connection_response_envelope.py => v2create_shared_connection_response_envelope.py} (100%)
rename src/polytomic/types/{v_2_enricher_configuration.py => v2enricher_configuration.py} (100%)
rename src/polytomic/types/{v_2_enricher_mapping.py => v2enricher_mapping.py} (100%)
rename src/polytomic/types/{v_2_execution_log_type.py => v2execution_log_type.py} (100%)
rename src/polytomic/types/{v_2_get_enrichment_input_fields_response_envelope.py => v2get_enrichment_input_fields_response_envelope.py} (100%)
rename src/polytomic/types/{v_2_ordered_map_string_github_com_invopop_jsonschema_schema.py => v2ordered_map_string_github_com_invopop_jsonschema_schema.py} (100%)
rename src/polytomic/types/{v_2_sample_record.py => v2sample_record.py} (100%)
rename src/polytomic/types/{v_2_schema_configuration_fields_item.py => v2schema_configuration_fields_item.py} (100%)
create mode 100644 src/polytomic/types/v3bulk_sync_source_capabilities.py
rename src/polytomic/types/{v_4_bulk_sync_execution_logs.py => v4bulk_sync_execution_logs.py} (100%)
rename src/polytomic/types/{v_4_bulk_sync_execution_logs_envelope.py => v4bulk_sync_execution_logs_envelope.py} (90%)
rename src/polytomic/types/{v_4_bulk_sync_schedule_api.py => v4bulk_sync_schedule_api.py} (100%)
rename src/polytomic/types/{v_4_export_sync_logs_envelope.py => v4export_sync_logs_envelope.py} (91%)
rename src/polytomic/types/{v_4_export_sync_logs_response.py => v4export_sync_logs_response.py} (100%)
rename src/polytomic/types/{v_4_global_error_subscribers_response.py => v4global_error_subscribers_response.py} (100%)
rename src/polytomic/types/{v_4_query_results_envelope.py => v4query_results_envelope.py} (93%)
rename src/polytomic/types/{v_4_run_query_envelope.py => v4run_query_envelope.py} (92%)
rename src/polytomic/types/{v_4_run_query_result.py => v4run_query_result.py} (92%)
rename src/polytomic/types/{v_4_target_creator.py => v4target_creator.py} (100%)
rename src/polytomic/types/{v_4_target_objects_response_envelope.py => v4target_objects_response_envelope.py} (93%)
rename src/polytomic/types/{v_4_target_property_values.py => v4target_property_values.py} (100%)
rename src/polytomic/types/{v_4_target_property_values_envelope.py => v4target_property_values_envelope.py} (90%)
rename src/polytomic/types/{v_4_user_field_request.py => v4user_field_request.py} (100%)
diff --git a/poetry.lock b/poetry.lock
index ea2269c..892a010 100644
--- a/poetry.lock
+++ b/poetry.lock
@@ -476,58 +476,58 @@ files = [
[[package]]
name = "tomli"
-version = "2.4.0"
+version = "2.4.1"
description = "A lil' TOML parser"
optional = false
python-versions = ">=3.8"
files = [
- {file = "tomli-2.4.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:b5ef256a3fd497d4973c11bf142e9ed78b150d36f5773f1ca6088c230ffc5867"},
- {file = "tomli-2.4.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:5572e41282d5268eb09a697c89a7bee84fae66511f87533a6f88bd2f7b652da9"},
- {file = "tomli-2.4.0-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:551e321c6ba03b55676970b47cb1b73f14a0a4dce6a3e1a9458fd6d921d72e95"},
- {file = "tomli-2.4.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:5e3f639a7a8f10069d0e15408c0b96a2a828cfdec6fca05296ebcdcc28ca7c76"},
- {file = "tomli-2.4.0-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:1b168f2731796b045128c45982d3a4874057626da0e2ef1fdd722848b741361d"},
- {file = "tomli-2.4.0-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:133e93646ec4300d651839d382d63edff11d8978be23da4cc106f5a18b7d0576"},
- {file = "tomli-2.4.0-cp311-cp311-win32.whl", hash = "sha256:b6c78bdf37764092d369722d9946cb65b8767bfa4110f902a1b2542d8d173c8a"},
- {file = "tomli-2.4.0-cp311-cp311-win_amd64.whl", hash = "sha256:d3d1654e11d724760cdb37a3d7691f0be9db5fbdaef59c9f532aabf87006dbaa"},
- {file = "tomli-2.4.0-cp311-cp311-win_arm64.whl", hash = "sha256:cae9c19ed12d4e8f3ebf46d1a75090e4c0dc16271c5bce1c833ac168f08fb614"},
- {file = "tomli-2.4.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:920b1de295e72887bafa3ad9f7a792f811847d57ea6b1215154030cf131f16b1"},
- {file = "tomli-2.4.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7d6d9a4aee98fac3eab4952ad1d73aee87359452d1c086b5ceb43ed02ddb16b8"},
- {file = "tomli-2.4.0-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:36b9d05b51e65b254ea6c2585b59d2c4cb91c8a3d91d0ed0f17591a29aaea54a"},
- {file = "tomli-2.4.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:1c8a885b370751837c029ef9bc014f27d80840e48bac415f3412e6593bbc18c1"},
- {file = "tomli-2.4.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:8768715ffc41f0008abe25d808c20c3d990f42b6e2e58305d5da280ae7d1fa3b"},
- {file = "tomli-2.4.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:7b438885858efd5be02a9a133caf5812b8776ee0c969fea02c45e8e3f296ba51"},
- {file = "tomli-2.4.0-cp312-cp312-win32.whl", hash = "sha256:0408e3de5ec77cc7f81960c362543cbbd91ef883e3138e81b729fc3eea5b9729"},
- {file = "tomli-2.4.0-cp312-cp312-win_amd64.whl", hash = "sha256:685306e2cc7da35be4ee914fd34ab801a6acacb061b6a7abca922aaf9ad368da"},
- {file = "tomli-2.4.0-cp312-cp312-win_arm64.whl", hash = "sha256:5aa48d7c2356055feef06a43611fc401a07337d5b006be13a30f6c58f869e3c3"},
- {file = "tomli-2.4.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:84d081fbc252d1b6a982e1870660e7330fb8f90f676f6e78b052ad4e64714bf0"},
- {file = "tomli-2.4.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:9a08144fa4cba33db5255f9b74f0b89888622109bd2776148f2597447f92a94e"},
- {file = "tomli-2.4.0-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:c73add4bb52a206fd0c0723432db123c0c75c280cbd67174dd9d2db228ebb1b4"},
- {file = "tomli-2.4.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:1fb2945cbe303b1419e2706e711b7113da57b7db31ee378d08712d678a34e51e"},
- {file = "tomli-2.4.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:bbb1b10aa643d973366dc2cb1ad94f99c1726a02343d43cbc011edbfac579e7c"},
- {file = "tomli-2.4.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4cbcb367d44a1f0c2be408758b43e1ffb5308abe0ea222897d6bfc8e8281ef2f"},
- {file = "tomli-2.4.0-cp313-cp313-win32.whl", hash = "sha256:7d49c66a7d5e56ac959cb6fc583aff0651094ec071ba9ad43df785abc2320d86"},
- {file = "tomli-2.4.0-cp313-cp313-win_amd64.whl", hash = "sha256:3cf226acb51d8f1c394c1b310e0e0e61fecdd7adcb78d01e294ac297dd2e7f87"},
- {file = "tomli-2.4.0-cp313-cp313-win_arm64.whl", hash = "sha256:d20b797a5c1ad80c516e41bc1fb0443ddb5006e9aaa7bda2d71978346aeb9132"},
- {file = "tomli-2.4.0-cp314-cp314-macosx_10_15_x86_64.whl", hash = "sha256:26ab906a1eb794cd4e103691daa23d95c6919cc2fa9160000ac02370cc9dd3f6"},
- {file = "tomli-2.4.0-cp314-cp314-macosx_11_0_arm64.whl", hash = "sha256:20cedb4ee43278bc4f2fee6cb50daec836959aadaf948db5172e776dd3d993fc"},
- {file = "tomli-2.4.0-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:39b0b5d1b6dd03684b3fb276407ebed7090bbec989fa55838c98560c01113b66"},
- {file = "tomli-2.4.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:a26d7ff68dfdb9f87a016ecfd1e1c2bacbe3108f4e0f8bcd2228ef9a766c787d"},
- {file = "tomli-2.4.0-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:20ffd184fb1df76a66e34bd1b36b4a4641bd2b82954befa32fe8163e79f1a702"},
- {file = "tomli-2.4.0-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:75c2f8bbddf170e8effc98f5e9084a8751f8174ea6ccf4fca5398436e0320bc8"},
- {file = "tomli-2.4.0-cp314-cp314-win32.whl", hash = "sha256:31d556d079d72db7c584c0627ff3a24c5d3fb4f730221d3444f3efb1b2514776"},
- {file = "tomli-2.4.0-cp314-cp314-win_amd64.whl", hash = "sha256:43e685b9b2341681907759cf3a04e14d7104b3580f808cfde1dfdb60ada85475"},
- {file = "tomli-2.4.0-cp314-cp314-win_arm64.whl", hash = "sha256:3d895d56bd3f82ddd6faaff993c275efc2ff38e52322ea264122d72729dca2b2"},
- {file = "tomli-2.4.0-cp314-cp314t-macosx_10_15_x86_64.whl", hash = "sha256:5b5807f3999fb66776dbce568cc9a828544244a8eb84b84b9bafc080c99597b9"},
- {file = "tomli-2.4.0-cp314-cp314t-macosx_11_0_arm64.whl", hash = "sha256:c084ad935abe686bd9c898e62a02a19abfc9760b5a79bc29644463eaf2840cb0"},
- {file = "tomli-2.4.0-cp314-cp314t-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:0f2e3955efea4d1cfbcb87bc321e00dc08d2bcb737fd1d5e398af111d86db5df"},
- {file = "tomli-2.4.0-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:0e0fe8a0b8312acf3a88077a0802565cb09ee34107813bba1c7cd591fa6cfc8d"},
- {file = "tomli-2.4.0-cp314-cp314t-musllinux_1_2_aarch64.whl", hash = "sha256:413540dce94673591859c4c6f794dfeaa845e98bf35d72ed59636f869ef9f86f"},
- {file = "tomli-2.4.0-cp314-cp314t-musllinux_1_2_x86_64.whl", hash = "sha256:0dc56fef0e2c1c470aeac5b6ca8cc7b640bb93e92d9803ddaf9ea03e198f5b0b"},
- {file = "tomli-2.4.0-cp314-cp314t-win32.whl", hash = "sha256:d878f2a6707cc9d53a1be1414bbb419e629c3d6e67f69230217bb663e76b5087"},
- {file = "tomli-2.4.0-cp314-cp314t-win_amd64.whl", hash = "sha256:2add28aacc7425117ff6364fe9e06a183bb0251b03f986df0e78e974047571fd"},
- {file = "tomli-2.4.0-cp314-cp314t-win_arm64.whl", hash = "sha256:2b1e3b80e1d5e52e40e9b924ec43d81570f0e7d09d11081b797bc4692765a3d4"},
- {file = "tomli-2.4.0-py3-none-any.whl", hash = "sha256:1f776e7d669ebceb01dee46484485f43a4048746235e683bcdffacdf1fb4785a"},
- {file = "tomli-2.4.0.tar.gz", hash = "sha256:aa89c3f6c277dd275d8e243ad24f3b5e701491a860d5121f2cdd399fbb31fc9c"},
+ {file = "tomli-2.4.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:f8f0fc26ec2cc2b965b7a3b87cd19c5c6b8c5e5f436b984e85f486d652285c30"},
+ {file = "tomli-2.4.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:4ab97e64ccda8756376892c53a72bd1f964e519c77236368527f758fbc36a53a"},
+ {file = "tomli-2.4.1-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:96481a5786729fd470164b47cdb3e0e58062a496f455ee41b4403be77cb5a076"},
+ {file = "tomli-2.4.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:5a881ab208c0baf688221f8cecc5401bd291d67e38a1ac884d6736cbcd8247e9"},
+ {file = "tomli-2.4.1-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:47149d5bd38761ac8be13a84864bf0b7b70bc051806bc3669ab1cbc56216b23c"},
+ {file = "tomli-2.4.1-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:ec9bfaf3ad2df51ace80688143a6a4ebc09a248f6ff781a9945e51937008fcbc"},
+ {file = "tomli-2.4.1-cp311-cp311-win32.whl", hash = "sha256:ff2983983d34813c1aeb0fa89091e76c3a22889ee83ab27c5eeb45100560c049"},
+ {file = "tomli-2.4.1-cp311-cp311-win_amd64.whl", hash = "sha256:5ee18d9ebdb417e384b58fe414e8d6af9f4e7a0ae761519fb50f721de398dd4e"},
+ {file = "tomli-2.4.1-cp311-cp311-win_arm64.whl", hash = "sha256:c2541745709bad0264b7d4705ad453b76ccd191e64aa6f0fc66b69a293a45ece"},
+ {file = "tomli-2.4.1-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:c742f741d58a28940ce01d58f0ab2ea3ced8b12402f162f4d534dfe18ba1cd6a"},
+ {file = "tomli-2.4.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7f86fd587c4ed9dd76f318225e7d9b29cfc5a9d43de44e5754db8d1128487085"},
+ {file = "tomli-2.4.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:ff18e6a727ee0ab0388507b89d1bc6a22b138d1e2fa56d1ad494586d61d2eae9"},
+ {file = "tomli-2.4.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:136443dbd7e1dee43c68ac2694fde36b2849865fa258d39bf822c10e8068eac5"},
+ {file = "tomli-2.4.1-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:5e262d41726bc187e69af7825504c933b6794dc3fbd5945e41a79bb14c31f585"},
+ {file = "tomli-2.4.1-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:5cb41aa38891e073ee49d55fbc7839cfdb2bc0e600add13874d048c94aadddd1"},
+ {file = "tomli-2.4.1-cp312-cp312-win32.whl", hash = "sha256:da25dc3563bff5965356133435b757a795a17b17d01dbc0f42fb32447ddfd917"},
+ {file = "tomli-2.4.1-cp312-cp312-win_amd64.whl", hash = "sha256:52c8ef851d9a240f11a88c003eacb03c31fc1c9c4ec64a99a0f922b93874fda9"},
+ {file = "tomli-2.4.1-cp312-cp312-win_arm64.whl", hash = "sha256:f758f1b9299d059cc3f6546ae2af89670cb1c4d48ea29c3cacc4fe7de3058257"},
+ {file = "tomli-2.4.1-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:36d2bd2ad5fb9eaddba5226aa02c8ec3fa4f192631e347b3ed28186d43be6b54"},
+ {file = "tomli-2.4.1-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:eb0dc4e38e6a1fd579e5d50369aa2e10acfc9cace504579b2faabb478e76941a"},
+ {file = "tomli-2.4.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:c7f2c7f2b9ca6bdeef8f0fa897f8e05085923eb091721675170254cbc5b02897"},
+ {file = "tomli-2.4.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:f3c6818a1a86dd6dca7ddcaaf76947d5ba31aecc28cb1b67009a5877c9a64f3f"},
+ {file = "tomli-2.4.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:d312ef37c91508b0ab2cee7da26ec0b3ed2f03ce12bd87a588d771ae15dcf82d"},
+ {file = "tomli-2.4.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:51529d40e3ca50046d7606fa99ce3956a617f9b36380da3b7f0dd3dd28e68cb5"},
+ {file = "tomli-2.4.1-cp313-cp313-win32.whl", hash = "sha256:2190f2e9dd7508d2a90ded5ed369255980a1bcdd58e52f7fe24b8162bf9fedbd"},
+ {file = "tomli-2.4.1-cp313-cp313-win_amd64.whl", hash = "sha256:8d65a2fbf9d2f8352685bc1364177ee3923d6baf5e7f43ea4959d7d8bc326a36"},
+ {file = "tomli-2.4.1-cp313-cp313-win_arm64.whl", hash = "sha256:4b605484e43cdc43f0954ddae319fb75f04cc10dd80d830540060ee7cd0243cd"},
+ {file = "tomli-2.4.1-cp314-cp314-macosx_10_15_x86_64.whl", hash = "sha256:fd0409a3653af6c147209d267a0e4243f0ae46b011aa978b1080359fddc9b6cf"},
+ {file = "tomli-2.4.1-cp314-cp314-macosx_11_0_arm64.whl", hash = "sha256:a120733b01c45e9a0c34aeef92bf0cf1d56cfe81ed9d47d562f9ed591a9828ac"},
+ {file = "tomli-2.4.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:559db847dc486944896521f68d8190be1c9e719fced785720d2216fe7022b662"},
+ {file = "tomli-2.4.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:01f520d4f53ef97964a240a035ec2a869fe1a37dde002b57ebc4417a27ccd853"},
+ {file = "tomli-2.4.1-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:7f94b27a62cfad8496c8d2513e1a222dd446f095fca8987fceef261225538a15"},
+ {file = "tomli-2.4.1-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:ede3e6487c5ef5d28634ba3f31f989030ad6af71edfb0055cbbd14189ff240ba"},
+ {file = "tomli-2.4.1-cp314-cp314-win32.whl", hash = "sha256:3d48a93ee1c9b79c04bb38772ee1b64dcf18ff43085896ea460ca8dec96f35f6"},
+ {file = "tomli-2.4.1-cp314-cp314-win_amd64.whl", hash = "sha256:88dceee75c2c63af144e456745e10101eb67361050196b0b6af5d717254dddf7"},
+ {file = "tomli-2.4.1-cp314-cp314-win_arm64.whl", hash = "sha256:b8c198f8c1805dc42708689ed6864951fd2494f924149d3e4bce7710f8eb5232"},
+ {file = "tomli-2.4.1-cp314-cp314t-macosx_10_15_x86_64.whl", hash = "sha256:d4d8fe59808a54658fcc0160ecfb1b30f9089906c50b23bcb4c69eddc19ec2b4"},
+ {file = "tomli-2.4.1-cp314-cp314t-macosx_11_0_arm64.whl", hash = "sha256:7008df2e7655c495dd12d2a4ad038ff878d4ca4b81fccaf82b714e07eae4402c"},
+ {file = "tomli-2.4.1-cp314-cp314t-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:1d8591993e228b0c930c4bb0db464bdad97b3289fb981255d6c9a41aedc84b2d"},
+ {file = "tomli-2.4.1-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:734e20b57ba95624ecf1841e72b53f6e186355e216e5412de414e3c51e5e3c41"},
+ {file = "tomli-2.4.1-cp314-cp314t-musllinux_1_2_aarch64.whl", hash = "sha256:8a650c2dbafa08d42e51ba0b62740dae4ecb9338eefa093aa5c78ceb546fcd5c"},
+ {file = "tomli-2.4.1-cp314-cp314t-musllinux_1_2_x86_64.whl", hash = "sha256:504aa796fe0569bb43171066009ead363de03675276d2d121ac1a4572397870f"},
+ {file = "tomli-2.4.1-cp314-cp314t-win32.whl", hash = "sha256:b1d22e6e9387bf4739fbe23bfa80e93f6b0373a7f1b96c6227c32bef95a4d7a8"},
+ {file = "tomli-2.4.1-cp314-cp314t-win_amd64.whl", hash = "sha256:2c1c351919aca02858f740c6d33adea0c5deea37f9ecca1cc1ef9e884a619d26"},
+ {file = "tomli-2.4.1-cp314-cp314t-win_arm64.whl", hash = "sha256:eab21f45c7f66c13f2a9e0e1535309cee140182a9cdae1e041d02e47291e8396"},
+ {file = "tomli-2.4.1-py3-none-any.whl", hash = "sha256:0d85819802132122da43cb86656f8d1f8c6587d54ae7dcaf30e90533028b49fe"},
+ {file = "tomli-2.4.1.tar.gz", hash = "sha256:7c7e1a961a0b2f2472c1ac5b69affa0ae1132c39adcb67aba98568702b9cc23f"},
]
[[package]]
diff --git a/pyproject.toml b/pyproject.toml
index 45c15a6..9ed158f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -3,7 +3,7 @@ name = "polytomic"
[tool.poetry]
name = "polytomic"
-version = "1.16.1"
+version = "0.0.0"
description = ""
readme = "README.md"
authors = []
diff --git a/reference.md b/reference.md
index 4a96a24..f98192a 100644
--- a/reference.md
+++ b/reference.md
@@ -843,7 +843,15 @@ client.bulk_sync.start(
-
-**resync:** `typing.Optional[bool]`
+**resync:** `typing.Optional[bool]` — Deprecated: use resync_mode instead. Equivalent to resync_mode=rebuild.
+
+
+
+
+
+-
+
+**resync_mode:** `typing.Optional[BulkResyncMode]`
@@ -1953,10 +1961,26 @@ client.connections.get_parameter_values(
-client.connections.api_v_2_create_shared_connection(...)
+client.connections.create_shared_connection(...)
-
+#### 📝 Description
+
+
+-
+
+
+-
+
+> 🚧 Requires partner key
+>
+> Shared connections can only be created by using [partner keys](https://apidocs.polytomic.com/guides/obtaining-api-keys#partner-keys).
+
+
+
+
+
#### 🔌 Usage
@@ -1972,9 +1996,9 @@ client = Polytomic(
version="YOUR_VERSION",
token="YOUR_TOKEN",
)
-client.connections.api_v_2_create_shared_connection(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
- organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+client.connections.create_shared_connection(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ child_organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
```
@@ -1991,7 +2015,7 @@ client.connections.api_v_2_create_shared_connection(
-
-**id:** `str`
+**parent_connection_id:** `str`
@@ -1999,7 +2023,7 @@ client.connections.api_v_2_create_shared_connection(
-
-**organization_id:** `str`
+**child_organization_id:** `str`
@@ -2023,6 +2047,63 @@ client.connections.api_v_2_create_shared_connection(
+
+
+
+
+client.connections.list_shared_connections(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from polytomic import Polytomic
+
+client = Polytomic(
+ version="YOUR_VERSION",
+ token="YOUR_TOKEN",
+)
+client.connections.list_shared_connections(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**parent_connection_id:** `str`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
@@ -2032,6 +2113,20 @@ client.connections.api_v_2_create_shared_connection(
-
+#### 📝 Description
+
+
+-
+
+
+-
+
+Submit a query for asynchronous execution against the connection. The initial response may only contain the query task id and status. Poll GET /api/queries/{id} with the returned id to retrieve completion status, fields, and results.
+
+
+
+
+
#### 🔌 Usage
@@ -2098,6 +2193,20 @@ client.query_runner.run_query(
-
+#### 📝 Description
+
+
+-
+
+
+-
+
+Fetch the latest status for a submitted query and, once complete, return fields and paginated results. Use the query id returned by POST /api/connections/{connection_id}/query.
+
+
+
+
+
#### 🔌 Usage
@@ -2115,6 +2224,7 @@ client = Polytomic(
)
client.query_runner.get_query(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ page="page",
)
```
@@ -2888,6 +2998,7 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.models.preview(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -3090,6 +3201,7 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.models.create(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -3246,6 +3358,7 @@ client = Polytomic(
)
client.models.get(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
```
@@ -3484,6 +3597,7 @@ client = Polytomic(
)
client.models.remove(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
```
@@ -3563,6 +3677,7 @@ client = Polytomic(
)
client.models.sample(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
```
@@ -3759,6 +3874,7 @@ client = Polytomic(
)
client.model_sync.list(
active=True,
+ mode="create",
target_connection_id="0b155265-c537-44c9-9359-a3ceb468a4da",
)
@@ -4742,12 +4858,14 @@ client = Polytomic(
)
client.events.list(
organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
starting_after=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
ending_before=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
+ limit=1,
)
```
@@ -4884,8 +5002,8 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.jobs.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
type="createmodel",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
```
@@ -4902,7 +5020,7 @@ client.jobs.get(
-
-**id:** `str`
+**type:** `str`
@@ -4910,7 +5028,7 @@ client.jobs.get(
-
-**type:** `str`
+**id:** `str`
@@ -5700,8 +5818,8 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.users.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
```
@@ -5718,7 +5836,7 @@ client.users.get(
-
-**id:** `str`
+**org_id:** `str`
@@ -5726,7 +5844,7 @@ client.users.get(
-
-**org_id:** `str`
+**id:** `str`
@@ -5766,8 +5884,8 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.users.update(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
email="mail@example.com",
)
@@ -5785,7 +5903,7 @@ client.users.update(
-
-**id:** `str`
+**org_id:** `str`
@@ -5793,7 +5911,7 @@ client.users.update(
-
-**org_id:** `str`
+**id:** `str`
@@ -5857,8 +5975,8 @@ client = Polytomic(
token="YOUR_TOKEN",
)
client.users.remove(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
```
@@ -5875,7 +5993,7 @@ client.users.remove(
-
-**id:** `str`
+**org_id:** `str`
@@ -5883,7 +6001,7 @@ client.users.remove(
-
-**org_id:** `str`
+**id:** `str`
@@ -6887,6 +7005,7 @@ client = Polytomic(
client.bulk_sync.executions.export_logs(
sync_id="248df4b7-aa70-47b8-a036-33ac447e668d",
execution_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ notify=True,
)
```
@@ -7689,6 +7808,8 @@ client = Polytomic(
)
client.model_sync.targets.get_target(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
+ search="search",
)
```
diff --git a/src/polytomic/__init__.py b/src/polytomic/__init__.py
index 4b4bd97..f962753 100644
--- a/src/polytomic/__init__.py
+++ b/src/polytomic/__init__.py
@@ -18,6 +18,8 @@
BulkItemizedSchedule,
BulkMultiScheduleConfiguration,
BulkNormalizeNames,
+ BulkOutputDisposition,
+ BulkResyncMode,
BulkSchedule,
BulkScheduleSyncMode,
BulkSchema,
@@ -33,6 +35,7 @@
BulkSyncExecutionEnvelope,
BulkSyncExecutionStatus,
BulkSyncFailedEvent,
+ BulkSyncIngestionStatus,
BulkSyncListEnvelope,
BulkSyncMode,
BulkSyncResponse,
@@ -51,7 +54,6 @@
CancelBulkSyncResponseEnvelope,
CancelModelSyncResponse,
CancelModelSyncResponseEnvelope,
- CommonOutputActor,
ConfigurationValue,
ConnectCardResponse,
ConnectCardResponseEnvelope,
@@ -91,6 +93,7 @@
GetModelSyncSourceMetaEnvelope,
Identity,
IdentityFunction,
+ IngestionStatusLevel,
JobResponse,
JobResponseEnvelope,
JsonschemaDefinitions,
@@ -123,6 +126,7 @@
Organization,
OrganizationEnvelope,
OrganizationsEnvelope,
+ OutputActor,
Override,
Pagination,
PaginationDetails,
@@ -186,6 +190,7 @@
V2OrderedMapStringGithubComInvopopJsonschemaSchema,
V2SampleRecord,
V2SchemaConfigurationFieldsItem,
+ V3BulkSyncSourceCapabilities,
V4BulkSyncExecutionLogs,
V4BulkSyncExecutionLogsEnvelope,
V4BulkSyncScheduleApi,
@@ -255,6 +260,8 @@
"BulkItemizedSchedule",
"BulkMultiScheduleConfiguration",
"BulkNormalizeNames",
+ "BulkOutputDisposition",
+ "BulkResyncMode",
"BulkSchedule",
"BulkScheduleSyncMode",
"BulkSchema",
@@ -270,6 +277,7 @@
"BulkSyncExecutionEnvelope",
"BulkSyncExecutionStatus",
"BulkSyncFailedEvent",
+ "BulkSyncIngestionStatus",
"BulkSyncListEnvelope",
"BulkSyncMode",
"BulkSyncResponse",
@@ -288,7 +296,6 @@
"CancelBulkSyncResponseEnvelope",
"CancelModelSyncResponse",
"CancelModelSyncResponseEnvelope",
- "CommonOutputActor",
"ConfigurationValue",
"ConflictError",
"ConnectCardResponse",
@@ -330,6 +337,7 @@
"GetModelSyncSourceMetaEnvelope",
"Identity",
"IdentityFunction",
+ "IngestionStatusLevel",
"InternalServerError",
"JobResponse",
"JobResponseEnvelope",
@@ -364,6 +372,7 @@
"Organization",
"OrganizationEnvelope",
"OrganizationsEnvelope",
+ "OutputActor",
"Override",
"Pagination",
"PaginationDetails",
@@ -433,6 +442,7 @@
"V2SampleRecord",
"V2SchemaConfigurationFieldsItem",
"V2UpdateBulkSyncRequestSchemasItem",
+ "V3BulkSyncSourceCapabilities",
"V4BulkSyncExecutionLogs",
"V4BulkSyncExecutionLogsEnvelope",
"V4BulkSyncScheduleApi",
diff --git a/src/polytomic/bulk_sync/client.py b/src/polytomic/bulk_sync/client.py
index 564a555..3b99d92 100644
--- a/src/polytomic/bulk_sync/client.py
+++ b/src/polytomic/bulk_sync/client.py
@@ -19,7 +19,7 @@
import datetime as dt
from ..types.bulk_sync_mode import BulkSyncMode
from ..types.bulk_normalize_names import BulkNormalizeNames
-from .types.v_2_create_bulk_sync_request_schemas_item import V2CreateBulkSyncRequestSchemasItem
+from .types.v2create_bulk_sync_request_schemas_item import V2CreateBulkSyncRequestSchemasItem
from ..types.bulk_sync_response_envelope import BulkSyncResponseEnvelope
from ..core.serialization import convert_and_respect_annotation_metadata
from ..errors.bad_request_error import BadRequestError
@@ -27,10 +27,11 @@
from ..errors.unprocessable_entity_error import UnprocessableEntityError
from ..core.jsonable_encoder import jsonable_encoder
from ..errors.not_found_error import NotFoundError
-from .types.v_2_update_bulk_sync_request_schemas_item import V2UpdateBulkSyncRequestSchemasItem
+from .types.v2update_bulk_sync_request_schemas_item import V2UpdateBulkSyncRequestSchemasItem
from ..types.activate_sync_envelope import ActivateSyncEnvelope
from ..types.cancel_bulk_sync_response_envelope import CancelBulkSyncResponseEnvelope
from ..types.bulk_fetch_mode import BulkFetchMode
+from ..types.bulk_resync_mode import BulkResyncMode
from ..types.bulk_sync_execution_envelope import BulkSyncExecutionEnvelope
from ..errors.conflict_error import ConflictError
from ..types.bulk_sync_status_envelope import BulkSyncStatusEnvelope
@@ -898,6 +899,7 @@ def start(
*,
fetch_mode: typing.Optional[BulkFetchMode] = OMIT,
resync: typing.Optional[bool] = OMIT,
+ resync_mode: typing.Optional[BulkResyncMode] = OMIT,
schemas: typing.Optional[typing.Sequence[str]] = OMIT,
test: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
@@ -910,6 +912,9 @@ def start(
fetch_mode : typing.Optional[BulkFetchMode]
resync : typing.Optional[bool]
+ Deprecated: use resync_mode instead. Equivalent to resync_mode=rebuild.
+
+ resync_mode : typing.Optional[BulkResyncMode]
schemas : typing.Optional[typing.Sequence[str]]
@@ -941,6 +946,7 @@ def start(
json={
"fetch_mode": fetch_mode,
"resync": resync,
+ "resync_mode": resync_mode,
"schemas": schemas,
"test": test,
},
@@ -2163,6 +2169,7 @@ async def start(
*,
fetch_mode: typing.Optional[BulkFetchMode] = OMIT,
resync: typing.Optional[bool] = OMIT,
+ resync_mode: typing.Optional[BulkResyncMode] = OMIT,
schemas: typing.Optional[typing.Sequence[str]] = OMIT,
test: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
@@ -2175,6 +2182,9 @@ async def start(
fetch_mode : typing.Optional[BulkFetchMode]
resync : typing.Optional[bool]
+ Deprecated: use resync_mode instead. Equivalent to resync_mode=rebuild.
+
+ resync_mode : typing.Optional[BulkResyncMode]
schemas : typing.Optional[typing.Sequence[str]]
@@ -2214,6 +2224,7 @@ async def main() -> None:
json={
"fetch_mode": fetch_mode,
"resync": resync,
+ "resync_mode": resync_mode,
"schemas": schemas,
"test": test,
},
diff --git a/src/polytomic/bulk_sync/executions/client.py b/src/polytomic/bulk_sync/executions/client.py
index 5396342..22a9d27 100644
--- a/src/polytomic/bulk_sync/executions/client.py
+++ b/src/polytomic/bulk_sync/executions/client.py
@@ -17,8 +17,8 @@
from ...types.cancel_bulk_sync_response_envelope import CancelBulkSyncResponseEnvelope
from ...errors.forbidden_error import ForbiddenError
from ...errors.internal_server_error import InternalServerError
-from ...types.v_4_bulk_sync_execution_logs_envelope import V4BulkSyncExecutionLogsEnvelope
-from ...types.v_4_export_sync_logs_envelope import V4ExportSyncLogsEnvelope
+from ...types.v4bulk_sync_execution_logs_envelope import V4BulkSyncExecutionLogsEnvelope
+from ...types.v4export_sync_logs_envelope import V4ExportSyncLogsEnvelope
from ...errors.bad_request_error import BadRequestError
from ...core.client_wrapper import AsyncClientWrapper
@@ -473,6 +473,7 @@ def export_logs(
client.bulk_sync.executions.export_logs(
sync_id="248df4b7-aa70-47b8-a036-33ac447e668d",
execution_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ notify=True,
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -1033,6 +1034,7 @@ async def main() -> None:
await client.bulk_sync.executions.export_logs(
sync_id="248df4b7-aa70-47b8-a036-33ac447e668d",
execution_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ notify=True,
)
diff --git a/src/polytomic/bulk_sync/schedules/client.py b/src/polytomic/bulk_sync/schedules/client.py
index 2d941ad..c0943c9 100644
--- a/src/polytomic/bulk_sync/schedules/client.py
+++ b/src/polytomic/bulk_sync/schedules/client.py
@@ -14,7 +14,7 @@
from ...errors.internal_server_error import InternalServerError
from json.decoder import JSONDecodeError
from ...core.api_error import ApiError as core_api_error_ApiError
-from ...types.v_4_bulk_sync_schedule_api import V4BulkSyncScheduleApi
+from ...types.v4bulk_sync_schedule_api import V4BulkSyncScheduleApi
from ...types.schedule_envelope import ScheduleEnvelope
from ...core.serialization import convert_and_respect_annotation_metadata
from ...errors.bad_request_error import BadRequestError
diff --git a/src/polytomic/bulk_sync/types/__init__.py b/src/polytomic/bulk_sync/types/__init__.py
index 09a2010..c6510c5 100644
--- a/src/polytomic/bulk_sync/types/__init__.py
+++ b/src/polytomic/bulk_sync/types/__init__.py
@@ -1,6 +1,6 @@
# This file was auto-generated by Fern from our API Definition.
-from .v_2_create_bulk_sync_request_schemas_item import V2CreateBulkSyncRequestSchemasItem
-from .v_2_update_bulk_sync_request_schemas_item import V2UpdateBulkSyncRequestSchemasItem
+from .v2create_bulk_sync_request_schemas_item import V2CreateBulkSyncRequestSchemasItem
+from .v2update_bulk_sync_request_schemas_item import V2UpdateBulkSyncRequestSchemasItem
__all__ = ["V2CreateBulkSyncRequestSchemasItem", "V2UpdateBulkSyncRequestSchemasItem"]
diff --git a/src/polytomic/bulk_sync/types/v_2_create_bulk_sync_request_schemas_item.py b/src/polytomic/bulk_sync/types/v2create_bulk_sync_request_schemas_item.py
similarity index 100%
rename from src/polytomic/bulk_sync/types/v_2_create_bulk_sync_request_schemas_item.py
rename to src/polytomic/bulk_sync/types/v2create_bulk_sync_request_schemas_item.py
diff --git a/src/polytomic/bulk_sync/types/v_2_update_bulk_sync_request_schemas_item.py b/src/polytomic/bulk_sync/types/v2update_bulk_sync_request_schemas_item.py
similarity index 100%
rename from src/polytomic/bulk_sync/types/v_2_update_bulk_sync_request_schemas_item.py
rename to src/polytomic/bulk_sync/types/v2update_bulk_sync_request_schemas_item.py
diff --git a/src/polytomic/client.py b/src/polytomic/client.py
index f0762a7..5518539 100644
--- a/src/polytomic/client.py
+++ b/src/polytomic/client.py
@@ -53,7 +53,7 @@ class Polytomic:
- version : typing.Optional[str]
+ version : typing.Optional[typing.Any]
token : typing.Union[str, typing.Callable[[], str]]
timeout : typing.Optional[float]
The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
@@ -79,7 +79,7 @@ def __init__(
*,
base_url: typing.Optional[str] = None,
environment: PolytomicEnvironment = PolytomicEnvironment.DEFAULT,
- version: typing.Optional[str] = None,
+ version: typing.Optional[typing.Any] = None,
token: typing.Union[str, typing.Callable[[], str]],
timeout: typing.Optional[float] = None,
follow_redirects: typing.Optional[bool] = True,
@@ -131,7 +131,7 @@ class AsyncPolytomic:
- version : typing.Optional[str]
+ version : typing.Optional[typing.Any]
token : typing.Union[str, typing.Callable[[], str]]
timeout : typing.Optional[float]
The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
@@ -157,7 +157,7 @@ def __init__(
*,
base_url: typing.Optional[str] = None,
environment: PolytomicEnvironment = PolytomicEnvironment.DEFAULT,
- version: typing.Optional[str] = None,
+ version: typing.Optional[typing.Any] = None,
token: typing.Union[str, typing.Callable[[], str]],
timeout: typing.Optional[float] = None,
follow_redirects: typing.Optional[bool] = True,
diff --git a/src/polytomic/connections/client.py b/src/polytomic/connections/client.py
index 37a3eba..ef7a867 100644
--- a/src/polytomic/connections/client.py
+++ b/src/polytomic/connections/client.py
@@ -22,7 +22,7 @@
from ..errors.unprocessable_entity_error import UnprocessableEntityError
from ..types.connect_card_response_envelope import ConnectCardResponseEnvelope
from ..types.connection_response_envelope import ConnectionResponseEnvelope
-from ..types.v_2_create_shared_connection_response_envelope import V2CreateSharedConnectionResponseEnvelope
+from ..types.v2create_shared_connection_response_envelope import V2CreateSharedConnectionResponseEnvelope
from ..core.client_wrapper import AsyncClientWrapper
# this is used as the default value for optional parameters
@@ -1145,20 +1145,24 @@ def get_parameter_values(
raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
- def api_v_2_create_shared_connection(
+ def create_shared_connection(
self,
- id: str,
+ parent_connection_id: str,
*,
- organization_id: str,
+ child_organization_id: str,
name: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> V2CreateSharedConnectionResponseEnvelope:
"""
+ > 🚧 Requires partner key
+ >
+ > Shared connections can only be created by using [partner keys](https://apidocs.polytomic.com/guides/obtaining-api-keys#partner-keys).
+
Parameters
----------
- id : str
+ parent_connection_id : str
- organization_id : str
+ child_organization_id : str
name : typing.Optional[str]
@@ -1178,17 +1182,17 @@ def api_v_2_create_shared_connection(
version="YOUR_VERSION",
token="YOUR_TOKEN",
)
- client.connections.api_v_2_create_shared_connection(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
- organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ client.connections.create_shared_connection(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ child_organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
"""
_response = self._client_wrapper.httpx_client.request(
- f"api/connections/{jsonable_encoder(id)}/share",
+ f"api/connections/{jsonable_encoder(parent_connection_id)}/share",
method="POST",
json={
+ "child_organization_id": child_organization_id,
"name": name,
- "organization_id": organization_id,
},
headers={
"content-type": "application/json",
@@ -1235,6 +1239,113 @@ def api_v_2_create_shared_connection(
),
)
)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
+ raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
+
+ def list_shared_connections(
+ self, parent_connection_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> ConnectionListResponseEnvelope:
+ """
+ Parameters
+ ----------
+ parent_connection_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ ConnectionListResponseEnvelope
+ OK
+
+ Examples
+ --------
+ from polytomic import Polytomic
+
+ client = Polytomic(
+ version="YOUR_VERSION",
+ token="YOUR_TOKEN",
+ )
+ client.connections.list_shared_connections(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ )
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"api/connections/{jsonable_encoder(parent_connection_id)}/shared",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ return typing.cast(
+ ConnectionListResponseEnvelope,
+ parse_obj_as(
+ type_=ConnectionListResponseEnvelope, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ typing.cast(
+ RestErrResponse,
+ parse_obj_as(
+ type_=RestErrResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 500:
raise InternalServerError(
typing.cast(
@@ -2459,20 +2570,24 @@ async def main() -> None:
raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
- async def api_v_2_create_shared_connection(
+ async def create_shared_connection(
self,
- id: str,
+ parent_connection_id: str,
*,
- organization_id: str,
+ child_organization_id: str,
name: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> V2CreateSharedConnectionResponseEnvelope:
"""
+ > 🚧 Requires partner key
+ >
+ > Shared connections can only be created by using [partner keys](https://apidocs.polytomic.com/guides/obtaining-api-keys#partner-keys).
+
Parameters
----------
- id : str
+ parent_connection_id : str
- organization_id : str
+ child_organization_id : str
name : typing.Optional[str]
@@ -2497,20 +2612,20 @@ async def api_v_2_create_shared_connection(
async def main() -> None:
- await client.connections.api_v_2_create_shared_connection(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
- organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ await client.connections.create_shared_connection(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ child_organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
asyncio.run(main())
"""
_response = await self._client_wrapper.httpx_client.request(
- f"api/connections/{jsonable_encoder(id)}/share",
+ f"api/connections/{jsonable_encoder(parent_connection_id)}/share",
method="POST",
json={
+ "child_organization_id": child_organization_id,
"name": name,
- "organization_id": organization_id,
},
headers={
"content-type": "application/json",
@@ -2557,6 +2672,121 @@ async def main() -> None:
),
)
)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
+ raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
+
+ async def list_shared_connections(
+ self, parent_connection_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> ConnectionListResponseEnvelope:
+ """
+ Parameters
+ ----------
+ parent_connection_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ ConnectionListResponseEnvelope
+ OK
+
+ Examples
+ --------
+ import asyncio
+
+ from polytomic import AsyncPolytomic
+
+ client = AsyncPolytomic(
+ version="YOUR_VERSION",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.connections.list_shared_connections(
+ parent_connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"api/connections/{jsonable_encoder(parent_connection_id)}/shared",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ return typing.cast(
+ ConnectionListResponseEnvelope,
+ parse_obj_as(
+ type_=ConnectionListResponseEnvelope, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ typing.cast(
+ RestErrResponse,
+ parse_obj_as(
+ type_=RestErrResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 500:
raise InternalServerError(
typing.cast(
diff --git a/src/polytomic/core/client_wrapper.py b/src/polytomic/core/client_wrapper.py
index 2d15ba6..221e1e0 100644
--- a/src/polytomic/core/client_wrapper.py
+++ b/src/polytomic/core/client_wrapper.py
@@ -10,7 +10,7 @@ class BaseClientWrapper:
def __init__(
self,
*,
- version: typing.Optional[str] = None,
+ version: typing.Optional[typing.Any] = None,
token: typing.Union[str, typing.Callable[[], str]],
base_url: str,
timeout: typing.Optional[float] = None,
@@ -24,7 +24,7 @@ def get_headers(self) -> typing.Dict[str, str]:
headers: typing.Dict[str, str] = {
"X-Fern-Language": "Python",
"X-Fern-SDK-Name": "polytomic",
- "X-Fern-SDK-Version": "1.16.1",
+ "X-Fern-SDK-Version": "0.0.0",
}
if self._version is not None:
headers["X-Polytomic-Version"] = self._version
@@ -48,7 +48,7 @@ class SyncClientWrapper(BaseClientWrapper):
def __init__(
self,
*,
- version: typing.Optional[str] = None,
+ version: typing.Optional[typing.Any] = None,
token: typing.Union[str, typing.Callable[[], str]],
base_url: str,
timeout: typing.Optional[float] = None,
@@ -67,7 +67,7 @@ class AsyncClientWrapper(BaseClientWrapper):
def __init__(
self,
*,
- version: typing.Optional[str] = None,
+ version: typing.Optional[typing.Any] = None,
token: typing.Union[str, typing.Callable[[], str]],
base_url: str,
timeout: typing.Optional[float] = None,
diff --git a/src/polytomic/events/client.py b/src/polytomic/events/client.py
index 01d4d77..5e1399b 100644
--- a/src/polytomic/events/client.py
+++ b/src/polytomic/events/client.py
@@ -65,12 +65,14 @@ def list(
)
client.events.list(
organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
starting_after=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
ending_before=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
+ limit=1,
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -232,12 +234,14 @@ async def list(
async def main() -> None:
await client.events.list(
organization_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
starting_after=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
ending_before=datetime.datetime.fromisoformat(
"2020-01-01 00:00:00+00:00",
),
+ limit=1,
)
diff --git a/src/polytomic/jobs/client.py b/src/polytomic/jobs/client.py
index 32ba6b8..8b8141f 100644
--- a/src/polytomic/jobs/client.py
+++ b/src/polytomic/jobs/client.py
@@ -22,15 +22,15 @@ def __init__(self, *, client_wrapper: SyncClientWrapper):
self._client_wrapper = client_wrapper
def get(
- self, id: str, type: str, *, request_options: typing.Optional[RequestOptions] = None
+ self, type: str, id: str, *, request_options: typing.Optional[RequestOptions] = None
) -> JobResponseEnvelope:
"""
Parameters
----------
- id : str
-
type : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -48,8 +48,8 @@ def get(
token="YOUR_TOKEN",
)
client.jobs.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
type="createmodel",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -117,15 +117,15 @@ def __init__(self, *, client_wrapper: AsyncClientWrapper):
self._client_wrapper = client_wrapper
async def get(
- self, id: str, type: str, *, request_options: typing.Optional[RequestOptions] = None
+ self, type: str, id: str, *, request_options: typing.Optional[RequestOptions] = None
) -> JobResponseEnvelope:
"""
Parameters
----------
- id : str
-
type : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -148,8 +148,8 @@ async def get(
async def main() -> None:
await client.jobs.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
type="createmodel",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
diff --git a/src/polytomic/model_sync/client.py b/src/polytomic/model_sync/client.py
index b5a0048..227bc19 100644
--- a/src/polytomic/model_sync/client.py
+++ b/src/polytomic/model_sync/client.py
@@ -296,6 +296,7 @@ def list(
)
client.model_sync.list(
active=True,
+ mode="create",
target_connection_id="0b155265-c537-44c9-9359-a3ceb468a4da",
)
"""
@@ -1732,6 +1733,7 @@ async def list(
async def main() -> None:
await client.model_sync.list(
active=True,
+ mode="create",
target_connection_id="0b155265-c537-44c9-9359-a3ceb468a4da",
)
diff --git a/src/polytomic/model_sync/executions/client.py b/src/polytomic/model_sync/executions/client.py
index a1e1140..883bc7a 100644
--- a/src/polytomic/model_sync/executions/client.py
+++ b/src/polytomic/model_sync/executions/client.py
@@ -17,7 +17,7 @@
from ...types.execution_status import ExecutionStatus
from ...errors.bad_request_error import BadRequestError
from ...errors.forbidden_error import ForbiddenError
-from ...types.v_2_execution_log_type import V2ExecutionLogType
+from ...types.v2execution_log_type import V2ExecutionLogType
from ...types.execution_logs_response_envelope import ExecutionLogsResponseEnvelope
from ...core.client_wrapper import AsyncClientWrapper
diff --git a/src/polytomic/model_sync/targets/client.py b/src/polytomic/model_sync/targets/client.py
index 59dcf67..92bfe91 100644
--- a/src/polytomic/model_sync/targets/client.py
+++ b/src/polytomic/model_sync/targets/client.py
@@ -16,8 +16,8 @@
from json.decoder import JSONDecodeError
from ...core.api_error import ApiError as core_api_error_ApiError
from ...types.target_response_envelope import TargetResponseEnvelope
-from ...types.v_4_target_objects_response_envelope import V4TargetObjectsResponseEnvelope
-from ...types.v_4_target_property_values_envelope import V4TargetPropertyValuesEnvelope
+from ...types.v4target_objects_response_envelope import V4TargetObjectsResponseEnvelope
+from ...types.v4target_property_values_envelope import V4TargetPropertyValuesEnvelope
from ...core.client_wrapper import AsyncClientWrapper
@@ -60,6 +60,8 @@ def get_target(
)
client.model_sync.targets.get_target(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
+ search="search",
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -528,6 +530,8 @@ async def get_target(
async def main() -> None:
await client.model_sync.targets.get_target(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ type="type",
+ search="search",
)
diff --git a/src/polytomic/models/client.py b/src/polytomic/models/client.py
index 45efe7f..ed46ed1 100644
--- a/src/polytomic/models/client.py
+++ b/src/polytomic/models/client.py
@@ -15,8 +15,8 @@
from ..errors.internal_server_error import InternalServerError
from json.decoder import JSONDecodeError
from ..core.api_error import ApiError as core_api_error_ApiError
-from ..types.v_2_enricher_configuration import V2EnricherConfiguration
-from ..types.v_2_get_enrichment_input_fields_response_envelope import V2GetEnrichmentInputFieldsResponseEnvelope
+from ..types.v2enricher_configuration import V2EnricherConfiguration
+from ..types.v2get_enrichment_input_fields_response_envelope import V2GetEnrichmentInputFieldsResponseEnvelope
from ..types.model_model_field_request import ModelModelFieldRequest
from ..types.enrichment import Enrichment
from ..types.model_relation import ModelRelation
@@ -306,6 +306,7 @@ def preview(
token="YOUR_TOKEN",
)
client.models.preview(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -519,6 +520,7 @@ def create(
token="YOUR_TOKEN",
)
client.models.create(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -635,6 +637,7 @@ def get(
)
client.models.get(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -880,6 +883,7 @@ def remove(
)
client.models.remove(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -968,6 +972,7 @@ def sample(
)
client.models.sample(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -1330,6 +1335,7 @@ async def preview(
async def main() -> None:
await client.models.preview(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -1559,6 +1565,7 @@ async def create(
async def main() -> None:
await client.models.create(
+ async_=True,
configuration={"table": "public.users"},
connection_id="248df4b7-aa70-47b8-a036-33ac447e668d",
name="Users",
@@ -1683,6 +1690,7 @@ async def get(
async def main() -> None:
await client.models.get(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
@@ -1944,6 +1952,7 @@ async def remove(
async def main() -> None:
await client.models.remove(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
@@ -2040,6 +2049,7 @@ async def sample(
async def main() -> None:
await client.models.sample(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ async_=True,
)
diff --git a/src/polytomic/notifications/client.py b/src/polytomic/notifications/client.py
index aed56ee..290abf1 100644
--- a/src/polytomic/notifications/client.py
+++ b/src/polytomic/notifications/client.py
@@ -3,7 +3,7 @@
import typing
from ..core.client_wrapper import SyncClientWrapper
from ..core.request_options import RequestOptions
-from ..types.v_4_global_error_subscribers_response import V4GlobalErrorSubscribersResponse
+from ..types.v4global_error_subscribers_response import V4GlobalErrorSubscribersResponse
from ..core.pydantic_utilities import parse_obj_as
from ..errors.unauthorized_error import UnauthorizedError
from ..types.rest_err_response import RestErrResponse
diff --git a/src/polytomic/organization/client.py b/src/polytomic/organization/client.py
index 8929e07..8ef7eea 100644
--- a/src/polytomic/organization/client.py
+++ b/src/polytomic/organization/client.py
@@ -15,6 +15,7 @@
from ..errors.conflict_error import ConflictError
from ..errors.unprocessable_entity_error import UnprocessableEntityError
from ..core.jsonable_encoder import jsonable_encoder
+from ..errors.forbidden_error import ForbiddenError
from ..errors.not_found_error import NotFoundError
from ..core.client_wrapper import AsyncClientWrapper
@@ -266,6 +267,16 @@ def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = Non
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(
@@ -371,6 +382,16 @@ def update(
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 409:
raise ConflictError(
typing.cast(
@@ -453,6 +474,16 @@ def remove(self, id: str, *, request_options: typing.Optional[RequestOptions] =
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(
@@ -747,6 +778,16 @@ async def main() -> None:
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(
@@ -860,6 +901,16 @@ async def main() -> None:
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 409:
raise ConflictError(
typing.cast(
@@ -950,6 +1001,16 @@ async def main() -> None:
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(
diff --git a/src/polytomic/query_runner/client.py b/src/polytomic/query_runner/client.py
index cd5fc5b..c5e5d63 100644
--- a/src/polytomic/query_runner/client.py
+++ b/src/polytomic/query_runner/client.py
@@ -3,7 +3,7 @@
import typing
from ..core.client_wrapper import SyncClientWrapper
from ..core.request_options import RequestOptions
-from ..types.v_4_run_query_envelope import V4RunQueryEnvelope
+from ..types.v4run_query_envelope import V4RunQueryEnvelope
from ..core.jsonable_encoder import jsonable_encoder
from ..core.pydantic_utilities import parse_obj_as
from ..errors.bad_request_error import BadRequestError
@@ -14,7 +14,7 @@
from ..errors.internal_server_error import InternalServerError
from json.decoder import JSONDecodeError
from ..core.api_error import ApiError as core_api_error_ApiError
-from ..types.v_4_query_results_envelope import V4QueryResultsEnvelope
+from ..types.v4query_results_envelope import V4QueryResultsEnvelope
from ..core.client_wrapper import AsyncClientWrapper
# this is used as the default value for optional parameters
@@ -33,6 +33,8 @@ def run_query(
request_options: typing.Optional[RequestOptions] = None,
) -> V4RunQueryEnvelope:
"""
+ Submit a query for asynchronous execution against the connection. The initial response may only contain the query task id and status. Poll GET /api/queries/{id} with the returned id to retrieve completion status, fields, and results.
+
Parameters
----------
connection_id : str
@@ -132,6 +134,8 @@ def get_query(
self, id: str, *, page: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
) -> V4QueryResultsEnvelope:
"""
+ Fetch the latest status for a submitted query and, once complete, return fields and paginated results. Use the query id returned by POST /api/connections/{connection_id}/query.
+
Parameters
----------
id : str
@@ -156,6 +160,7 @@ def get_query(
)
client.query_runner.get_query(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ page="page",
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -233,6 +238,8 @@ async def run_query(
request_options: typing.Optional[RequestOptions] = None,
) -> V4RunQueryEnvelope:
"""
+ Submit a query for asynchronous execution against the connection. The initial response may only contain the query task id and status. Poll GET /api/queries/{id} with the returned id to retrieve completion status, fields, and results.
+
Parameters
----------
connection_id : str
@@ -340,6 +347,8 @@ async def get_query(
self, id: str, *, page: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
) -> V4QueryResultsEnvelope:
"""
+ Fetch the latest status for a submitted query and, once complete, return fields and paginated results. Use the query id returned by POST /api/connections/{connection_id}/query.
+
Parameters
----------
id : str
@@ -369,6 +378,7 @@ async def get_query(
async def main() -> None:
await client.query_runner.get_query(
id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ page="page",
)
diff --git a/src/polytomic/schemas/client.py b/src/polytomic/schemas/client.py
index 04edb01..448e76c 100644
--- a/src/polytomic/schemas/client.py
+++ b/src/polytomic/schemas/client.py
@@ -2,7 +2,7 @@
import typing
from ..core.client_wrapper import SyncClientWrapper
-from ..types.v_4_user_field_request import V4UserFieldRequest
+from ..types.v4user_field_request import V4UserFieldRequest
from ..core.request_options import RequestOptions
from ..core.jsonable_encoder import jsonable_encoder
from ..core.serialization import convert_and_respect_annotation_metadata
diff --git a/src/polytomic/types/__init__.py b/src/polytomic/types/__init__.py
index 149f3e1..ead462d 100644
--- a/src/polytomic/types/__init__.py
+++ b/src/polytomic/types/__init__.py
@@ -18,6 +18,8 @@
from .bulk_itemized_schedule import BulkItemizedSchedule
from .bulk_multi_schedule_configuration import BulkMultiScheduleConfiguration
from .bulk_normalize_names import BulkNormalizeNames
+from .bulk_output_disposition import BulkOutputDisposition
+from .bulk_resync_mode import BulkResyncMode
from .bulk_schedule import BulkSchedule
from .bulk_schedule_sync_mode import BulkScheduleSyncMode
from .bulk_schema import BulkSchema
@@ -33,6 +35,7 @@
from .bulk_sync_execution_envelope import BulkSyncExecutionEnvelope
from .bulk_sync_execution_status import BulkSyncExecutionStatus
from .bulk_sync_failed_event import BulkSyncFailedEvent
+from .bulk_sync_ingestion_status import BulkSyncIngestionStatus
from .bulk_sync_list_envelope import BulkSyncListEnvelope
from .bulk_sync_mode import BulkSyncMode
from .bulk_sync_response import BulkSyncResponse
@@ -51,7 +54,6 @@
from .cancel_bulk_sync_response_envelope import CancelBulkSyncResponseEnvelope
from .cancel_model_sync_response import CancelModelSyncResponse
from .cancel_model_sync_response_envelope import CancelModelSyncResponseEnvelope
-from .common_output_actor import CommonOutputActor
from .configuration_value import ConfigurationValue
from .connect_card_response import ConnectCardResponse
from .connect_card_response_envelope import ConnectCardResponseEnvelope
@@ -91,6 +93,7 @@
from .get_model_sync_source_meta_envelope import GetModelSyncSourceMetaEnvelope
from .identity import Identity
from .identity_function import IdentityFunction
+from .ingestion_status_level import IngestionStatusLevel
from .job_response import JobResponse
from .job_response_envelope import JobResponseEnvelope
from .jsonschema_definitions import JsonschemaDefinitions
@@ -123,6 +126,7 @@
from .organization import Organization
from .organization_envelope import OrganizationEnvelope
from .organizations_envelope import OrganizationsEnvelope
+from .output_actor import OutputActor
from .override import Override
from .pagination import Pagination
from .pagination_details import PaginationDetails
@@ -176,31 +180,32 @@
from .user_envelope import UserEnvelope
from .util_enum_value import UtilEnumValue
from .util_field_type import UtilFieldType
-from .v_2_connection_form import V2ConnectionForm
-from .v_2_create_shared_connection_response_envelope import V2CreateSharedConnectionResponseEnvelope
-from .v_2_enricher_configuration import V2EnricherConfiguration
-from .v_2_enricher_mapping import V2EnricherMapping
-from .v_2_execution_log_type import V2ExecutionLogType
-from .v_2_get_enrichment_input_fields_response_envelope import V2GetEnrichmentInputFieldsResponseEnvelope
-from .v_2_ordered_map_string_github_com_invopop_jsonschema_schema import (
+from .v2connection_form import V2ConnectionForm
+from .v2create_shared_connection_response_envelope import V2CreateSharedConnectionResponseEnvelope
+from .v2enricher_configuration import V2EnricherConfiguration
+from .v2enricher_mapping import V2EnricherMapping
+from .v2execution_log_type import V2ExecutionLogType
+from .v2get_enrichment_input_fields_response_envelope import V2GetEnrichmentInputFieldsResponseEnvelope
+from .v2ordered_map_string_github_com_invopop_jsonschema_schema import (
V2OrderedMapStringGithubComInvopopJsonschemaSchema,
)
-from .v_2_sample_record import V2SampleRecord
-from .v_2_schema_configuration_fields_item import V2SchemaConfigurationFieldsItem
-from .v_4_bulk_sync_execution_logs import V4BulkSyncExecutionLogs
-from .v_4_bulk_sync_execution_logs_envelope import V4BulkSyncExecutionLogsEnvelope
-from .v_4_bulk_sync_schedule_api import V4BulkSyncScheduleApi
-from .v_4_export_sync_logs_envelope import V4ExportSyncLogsEnvelope
-from .v_4_export_sync_logs_response import V4ExportSyncLogsResponse
-from .v_4_global_error_subscribers_response import V4GlobalErrorSubscribersResponse
-from .v_4_query_results_envelope import V4QueryResultsEnvelope
-from .v_4_run_query_envelope import V4RunQueryEnvelope
-from .v_4_run_query_result import V4RunQueryResult
-from .v_4_target_creator import V4TargetCreator
-from .v_4_target_objects_response_envelope import V4TargetObjectsResponseEnvelope
-from .v_4_target_property_values import V4TargetPropertyValues
-from .v_4_target_property_values_envelope import V4TargetPropertyValuesEnvelope
-from .v_4_user_field_request import V4UserFieldRequest
+from .v2sample_record import V2SampleRecord
+from .v2schema_configuration_fields_item import V2SchemaConfigurationFieldsItem
+from .v3bulk_sync_source_capabilities import V3BulkSyncSourceCapabilities
+from .v4bulk_sync_execution_logs import V4BulkSyncExecutionLogs
+from .v4bulk_sync_execution_logs_envelope import V4BulkSyncExecutionLogsEnvelope
+from .v4bulk_sync_schedule_api import V4BulkSyncScheduleApi
+from .v4export_sync_logs_envelope import V4ExportSyncLogsEnvelope
+from .v4export_sync_logs_response import V4ExportSyncLogsResponse
+from .v4global_error_subscribers_response import V4GlobalErrorSubscribersResponse
+from .v4query_results_envelope import V4QueryResultsEnvelope
+from .v4run_query_envelope import V4RunQueryEnvelope
+from .v4run_query_result import V4RunQueryResult
+from .v4target_creator import V4TargetCreator
+from .v4target_objects_response_envelope import V4TargetObjectsResponseEnvelope
+from .v4target_property_values import V4TargetPropertyValues
+from .v4target_property_values_envelope import V4TargetPropertyValuesEnvelope
+from .v4user_field_request import V4UserFieldRequest
from .webhook import Webhook
from .webhook_envelope import WebhookEnvelope
from .webhook_list_envelope import WebhookListEnvelope
@@ -224,6 +229,8 @@
"BulkItemizedSchedule",
"BulkMultiScheduleConfiguration",
"BulkNormalizeNames",
+ "BulkOutputDisposition",
+ "BulkResyncMode",
"BulkSchedule",
"BulkScheduleSyncMode",
"BulkSchema",
@@ -239,6 +246,7 @@
"BulkSyncExecutionEnvelope",
"BulkSyncExecutionStatus",
"BulkSyncFailedEvent",
+ "BulkSyncIngestionStatus",
"BulkSyncListEnvelope",
"BulkSyncMode",
"BulkSyncResponse",
@@ -257,7 +265,6 @@
"CancelBulkSyncResponseEnvelope",
"CancelModelSyncResponse",
"CancelModelSyncResponseEnvelope",
- "CommonOutputActor",
"ConfigurationValue",
"ConnectCardResponse",
"ConnectCardResponseEnvelope",
@@ -297,6 +304,7 @@
"GetModelSyncSourceMetaEnvelope",
"Identity",
"IdentityFunction",
+ "IngestionStatusLevel",
"JobResponse",
"JobResponseEnvelope",
"JsonschemaDefinitions",
@@ -329,6 +337,7 @@
"Organization",
"OrganizationEnvelope",
"OrganizationsEnvelope",
+ "OutputActor",
"Override",
"Pagination",
"PaginationDetails",
@@ -392,6 +401,7 @@
"V2OrderedMapStringGithubComInvopopJsonschemaSchema",
"V2SampleRecord",
"V2SchemaConfigurationFieldsItem",
+ "V3BulkSyncSourceCapabilities",
"V4BulkSyncExecutionLogs",
"V4BulkSyncExecutionLogsEnvelope",
"V4BulkSyncScheduleApi",
diff --git a/src/polytomic/types/bulk_output_disposition.py b/src/polytomic/types/bulk_output_disposition.py
new file mode 100644
index 0000000..9cf01ca
--- /dev/null
+++ b/src/polytomic/types/bulk_output_disposition.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+BulkOutputDisposition = typing.Union[typing.Literal["retain", "truncate", "rebuild"], typing.Any]
diff --git a/src/polytomic/types/bulk_resync_mode.py b/src/polytomic/types/bulk_resync_mode.py
new file mode 100644
index 0000000..575044c
--- /dev/null
+++ b/src/polytomic/types/bulk_resync_mode.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+BulkResyncMode = typing.Union[typing.Literal["refetch", "resync", "rebuild"], typing.Any]
diff --git a/src/polytomic/types/bulk_schema.py b/src/polytomic/types/bulk_schema.py
index 22ce3f7..b2a573b 100644
--- a/src/polytomic/types/bulk_schema.py
+++ b/src/polytomic/types/bulk_schema.py
@@ -4,17 +4,25 @@
import typing
import datetime as dt
from .bulk_field import BulkField
+import pydantic
from .bulk_filter import BulkFilter
from ..core.pydantic_utilities import IS_PYDANTIC_V2
-import pydantic
class BulkSchema(UniversalBaseModel):
data_cutoff_timestamp: typing.Optional[dt.datetime] = None
disable_data_cutoff: typing.Optional[bool] = None
enabled: typing.Optional[bool] = None
- fields: typing.Optional[typing.List[BulkField]] = None
- filters: typing.Optional[typing.List[BulkFilter]] = None
+ fields: typing.Optional[typing.List[BulkField]] = pydantic.Field(default=None)
+ """
+ fields is not populated on the list endpoint and will be removed in a future version; retrieve individual schemas for fields.
+ """
+
+ filters: typing.Optional[typing.List[BulkFilter]] = pydantic.Field(default=None)
+ """
+ filters is not populated on the list endpoint and will be removed in a future version; retrieve individual schemas for filters.
+ """
+
id: typing.Optional[str] = None
output_name: typing.Optional[str] = None
partition_key: typing.Optional[str] = None
diff --git a/src/polytomic/types/bulk_schema_execution_status.py b/src/polytomic/types/bulk_schema_execution_status.py
index 7e4a084..06153f9 100644
--- a/src/polytomic/types/bulk_schema_execution_status.py
+++ b/src/polytomic/types/bulk_schema_execution_status.py
@@ -3,6 +3,8 @@
import typing
BulkSchemaExecutionStatus = typing.Union[
- typing.Literal["created", "scheduled", "running", "exporting", "canceled", "completed", "failed", "interrupted"],
+ typing.Literal[
+ "created", "scheduled", "running", "exporting", "canceled", "completed", "failed", "interrupted", "processing"
+ ],
typing.Any,
]
diff --git a/src/polytomic/types/bulk_sync_dest.py b/src/polytomic/types/bulk_sync_dest.py
index 2a9540e..5c3f26b 100644
--- a/src/polytomic/types/bulk_sync_dest.py
+++ b/src/polytomic/types/bulk_sync_dest.py
@@ -3,13 +3,18 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
from .supported_bulk_mode import SupportedBulkMode
-from ..core.pydantic_utilities import IS_PYDANTIC_V2
+from .bulk_resync_mode import BulkResyncMode
import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2
class BulkSyncDest(UniversalBaseModel):
configuration: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
modes: typing.Optional[typing.List[SupportedBulkMode]] = None
+ supported_resync_modes: typing.Optional[typing.List[BulkResyncMode]] = pydantic.Field(default=None)
+ """
+ Resync modes supported by this destination (refetch, resync, rebuild).
+ """
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/polytomic/types/bulk_sync_execution.py b/src/polytomic/types/bulk_sync_execution.py
index 40e2a4b..578c822 100644
--- a/src/polytomic/types/bulk_sync_execution.py
+++ b/src/polytomic/types/bulk_sync_execution.py
@@ -4,6 +4,7 @@
import typing
import datetime as dt
from .bulk_fetch_mode import BulkFetchMode
+from .bulk_output_disposition import BulkOutputDisposition
from .bulk_sync_schema_execution import BulkSyncSchemaExecution
from .bulk_execution_status import BulkExecutionStatus
from ..core.pydantic_utilities import IS_PYDANTIC_V2
@@ -19,6 +20,7 @@ class BulkSyncExecution(UniversalBaseModel):
is_partial: typing.Optional[bool] = None
is_resync: typing.Optional[bool] = None
is_test: typing.Optional[bool] = None
+ output_disposition: typing.Optional[BulkOutputDisposition] = None
record_count: typing.Optional[int] = None
schemas: typing.Optional[typing.List[BulkSyncSchemaExecution]] = None
started_at: typing.Optional[dt.datetime] = None
diff --git a/src/polytomic/types/bulk_sync_ingestion_status.py b/src/polytomic/types/bulk_sync_ingestion_status.py
new file mode 100644
index 0000000..b39cd86
--- /dev/null
+++ b/src/polytomic/types/bulk_sync_ingestion_status.py
@@ -0,0 +1,28 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from ..core.pydantic_utilities import UniversalBaseModel
+import typing
+import datetime as dt
+from .ingestion_status_level import IngestionStatusLevel
+from ..core.pydantic_utilities import IS_PYDANTIC_V2
+import pydantic
+
+
+class BulkSyncIngestionStatus(UniversalBaseModel):
+ enabled: typing.Optional[bool] = None
+ highwater_mark: typing.Optional[str] = None
+ is_running: typing.Optional[bool] = None
+ position: typing.Optional[str] = None
+ position_time: typing.Optional[dt.datetime] = None
+ status: typing.Optional[IngestionStatusLevel] = None
+ status_message: typing.Optional[str] = None
+ updated_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/polytomic/types/bulk_sync_response.py b/src/polytomic/types/bulk_sync_response.py
index 1331e4e..9e86520 100644
--- a/src/polytomic/types/bulk_sync_response.py
+++ b/src/polytomic/types/bulk_sync_response.py
@@ -8,7 +8,7 @@
from .bulk_discover import BulkDiscover
import pydantic
import datetime as dt
-from .common_output_actor import CommonOutputActor
+from .output_actor import OutputActor
from .bulk_sync_mode import BulkSyncMode
from .bulk_normalize_names import BulkNormalizeNames
from ..core.pydantic_utilities import IS_PYDANTIC_V2
@@ -24,7 +24,7 @@ class BulkSyncResponse(UniversalBaseModel):
"""
created_at: typing.Optional[dt.datetime] = None
- created_by: typing.Optional[CommonOutputActor] = None
+ created_by: typing.Optional[OutputActor] = None
data_cutoff_timestamp: typing.Optional[dt.datetime] = None
destination_configuration: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(
default=None
@@ -67,7 +67,7 @@ class BulkSyncResponse(UniversalBaseModel):
source_connection_id: typing.Optional[str] = None
updated_at: typing.Optional[dt.datetime] = None
- updated_by: typing.Optional[CommonOutputActor] = None
+ updated_by: typing.Optional[OutputActor] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/polytomic/types/bulk_sync_source.py b/src/polytomic/types/bulk_sync_source.py
index 969fc68..c2cbdd4 100644
--- a/src/polytomic/types/bulk_sync_source.py
+++ b/src/polytomic/types/bulk_sync_source.py
@@ -2,12 +2,14 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
+from .v3bulk_sync_source_capabilities import V3BulkSyncSourceCapabilities
from .schema import Schema
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
class BulkSyncSource(UniversalBaseModel):
+ capabilities: typing.Optional[V3BulkSyncSourceCapabilities] = None
configuration: typing.Optional[typing.Optional[typing.Any]] = None
schemas: typing.Optional[typing.List[Schema]] = None
diff --git a/src/polytomic/types/bulk_sync_status_response.py b/src/polytomic/types/bulk_sync_status_response.py
index 680022f..4c4bbac 100644
--- a/src/polytomic/types/bulk_sync_status_response.py
+++ b/src/polytomic/types/bulk_sync_status_response.py
@@ -3,6 +3,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
from .bulk_sync_execution import BulkSyncExecution
+from .bulk_sync_ingestion_status import BulkSyncIngestionStatus
import datetime as dt
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
@@ -10,6 +11,7 @@
class BulkSyncStatusResponse(UniversalBaseModel):
current_execution: typing.Optional[BulkSyncExecution] = None
+ ingestion_status: typing.Optional[BulkSyncIngestionStatus] = None
last_execution: typing.Optional[BulkSyncExecution] = None
next_execution_time: typing.Optional[dt.datetime] = None
diff --git a/src/polytomic/types/connection_response_schema.py b/src/polytomic/types/connection_response_schema.py
index c6400d4..f6534fc 100644
--- a/src/polytomic/types/connection_response_schema.py
+++ b/src/polytomic/types/connection_response_schema.py
@@ -1,23 +1,27 @@
# This file was auto-generated by Fern from our API Definition.
from ..core.pydantic_utilities import UniversalBaseModel
+import typing_extensions
import typing
+from ..core.serialization import FieldMetadata
import pydantic
import datetime as dt
-from .common_output_actor import CommonOutputActor
+from .output_actor import OutputActor
from .connection_type_schema import ConnectionTypeSchema
from ..core.pydantic_utilities import IS_PYDANTIC_V2
class ConnectionResponseSchema(UniversalBaseModel):
- api_calls_last_24_hours: typing.Optional[int] = pydantic.Field(default=None)
+ api_calls_last24hours: typing_extensions.Annotated[
+ typing.Optional[int], FieldMetadata(alias="api_calls_last_24_hours")
+ ] = pydantic.Field(default=None)
"""
API calls made to service in the last 24h (supported integrations only).
"""
configuration: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
created_at: typing.Optional[dt.datetime] = None
- created_by: typing.Optional[CommonOutputActor] = None
+ created_by: typing.Optional[OutputActor] = None
id: typing.Optional[str] = None
name: typing.Optional[str] = None
organization_id: typing.Optional[str] = None
@@ -32,7 +36,7 @@ class ConnectionResponseSchema(UniversalBaseModel):
status_error: typing.Optional[str] = None
type: typing.Optional[ConnectionTypeSchema] = None
updated_at: typing.Optional[dt.datetime] = None
- updated_by: typing.Optional[CommonOutputActor] = None
+ updated_by: typing.Optional[OutputActor] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/polytomic/types/connection_type.py b/src/polytomic/types/connection_type.py
index fe2bd1f..9e4fd64 100644
--- a/src/polytomic/types/connection_type.py
+++ b/src/polytomic/types/connection_type.py
@@ -4,7 +4,7 @@
from .backend_connection_capabilities import BackendConnectionCapabilities
import typing_extensions
import typing
-from .v_2_connection_form import V2ConnectionForm
+from .v2connection_form import V2ConnectionForm
from ..core.serialization import FieldMetadata
from .backend_o_auth_prompt import BackendOAuthPrompt
from ..core.pydantic_utilities import IS_PYDANTIC_V2
diff --git a/src/polytomic/types/enrichment.py b/src/polytomic/types/enrichment.py
index 7def672..d326c4e 100644
--- a/src/polytomic/types/enrichment.py
+++ b/src/polytomic/types/enrichment.py
@@ -2,10 +2,10 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_2_enricher_configuration import V2EnricherConfiguration
+from .v2enricher_configuration import V2EnricherConfiguration
import pydantic
from .model_field import ModelField
-from .v_2_enricher_mapping import V2EnricherMapping
+from .v2enricher_mapping import V2EnricherMapping
from ..core.pydantic_utilities import IS_PYDANTIC_V2
diff --git a/src/polytomic/types/ingestion_status_level.py b/src/polytomic/types/ingestion_status_level.py
new file mode 100644
index 0000000..7f782a8
--- /dev/null
+++ b/src/polytomic/types/ingestion_status_level.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+IngestionStatusLevel = typing.Union[typing.Literal["ok", "warning", "error"], typing.Any]
diff --git a/src/polytomic/types/jsonschema_schema.py b/src/polytomic/types/jsonschema_schema.py
index cc657fb..335b46c 100644
--- a/src/polytomic/types/jsonschema_schema.py
+++ b/src/polytomic/types/jsonschema_schema.py
@@ -5,7 +5,7 @@
import typing_extensions
import typing
from ..core.serialization import FieldMetadata
-from .v_2_ordered_map_string_github_com_invopop_jsonschema_schema import (
+from .v2ordered_map_string_github_com_invopop_jsonschema_schema import (
V2OrderedMapStringGithubComInvopopJsonschemaSchema,
)
from ..core.pydantic_utilities import IS_PYDANTIC_V2
diff --git a/src/polytomic/types/model_field.py b/src/polytomic/types/model_field.py
index aa4a1c9..efd5007 100644
--- a/src/polytomic/types/model_field.py
+++ b/src/polytomic/types/model_field.py
@@ -3,14 +3,14 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
import datetime as dt
-from .common_output_actor import CommonOutputActor
+from .output_actor import OutputActor
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
class ModelField(UniversalBaseModel):
created_at: typing.Optional[dt.datetime] = None
- created_by: typing.Optional[CommonOutputActor] = None
+ created_by: typing.Optional[OutputActor] = None
description: typing.Optional[str] = None
example: typing.Optional[typing.Optional[typing.Any]] = None
id: typing.Optional[str] = None
diff --git a/src/polytomic/types/model_response.py b/src/polytomic/types/model_response.py
index d4e1f71..e094abe 100644
--- a/src/polytomic/types/model_response.py
+++ b/src/polytomic/types/model_response.py
@@ -3,7 +3,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
import datetime as dt
-from .common_output_actor import CommonOutputActor
+from .output_actor import OutputActor
from .enrichment import Enrichment
from .model_field import ModelField
from .label_label import LabelLabel
@@ -16,7 +16,7 @@ class ModelResponse(UniversalBaseModel):
configuration: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
connection_id: typing.Optional[str] = None
created_at: typing.Optional[dt.datetime] = None
- created_by: typing.Optional[CommonOutputActor] = None
+ created_by: typing.Optional[OutputActor] = None
enricher: typing.Optional[Enrichment] = None
fields: typing.Optional[typing.List[ModelField]] = None
id: typing.Optional[str] = None
@@ -29,7 +29,7 @@ class ModelResponse(UniversalBaseModel):
tracking_columns: typing.Optional[typing.List[str]] = None
type: typing.Optional[str] = None
updated_at: typing.Optional[dt.datetime] = None
- updated_by: typing.Optional[CommonOutputActor] = None
+ updated_by: typing.Optional[OutputActor] = None
version: typing.Optional[int] = None
if IS_PYDANTIC_V2:
diff --git a/src/polytomic/types/model_sample.py b/src/polytomic/types/model_sample.py
index 10ce391..d07a40b 100644
--- a/src/polytomic/types/model_sample.py
+++ b/src/polytomic/types/model_sample.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_2_sample_record import V2SampleRecord
+from .v2sample_record import V2SampleRecord
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/model_sync_mode.py b/src/polytomic/types/model_sync_mode.py
index 7a21004..5836db1 100644
--- a/src/polytomic/types/model_sync_mode.py
+++ b/src/polytomic/types/model_sync_mode.py
@@ -3,5 +3,5 @@
import typing
ModelSyncMode = typing.Union[
- typing.Literal["create", "update", "updateOrCreate", "replace", "append", "remove"], typing.Any
+ typing.Literal["create", "update", "updateOrCreate", "replace", "append", "remove", "snapshot"], typing.Any
]
diff --git a/src/polytomic/types/model_sync_response.py b/src/polytomic/types/model_sync_response.py
index 57e0e83..bdc1663 100644
--- a/src/polytomic/types/model_sync_response.py
+++ b/src/polytomic/types/model_sync_response.py
@@ -3,7 +3,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
import datetime as dt
-from .common_output_actor import CommonOutputActor
+from .output_actor import OutputActor
from .model_sync_field import ModelSyncField
from .filter import Filter
from .identity import Identity
@@ -18,7 +18,7 @@
class ModelSyncResponse(UniversalBaseModel):
active: typing.Optional[bool] = None
created_at: typing.Optional[dt.datetime] = None
- created_by: typing.Optional[CommonOutputActor] = None
+ created_by: typing.Optional[OutputActor] = None
encryption_passphrase: typing.Optional[str] = None
fields: typing.Optional[typing.List[ModelSyncField]] = None
filter_logic: typing.Optional[str] = None
@@ -42,7 +42,7 @@ class ModelSyncResponse(UniversalBaseModel):
sync_all_records: typing.Optional[bool] = None
target: typing.Optional[Target] = None
updated_at: typing.Optional[dt.datetime] = None
- updated_by: typing.Optional[CommonOutputActor] = None
+ updated_by: typing.Optional[OutputActor] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/polytomic/types/common_output_actor.py b/src/polytomic/types/output_actor.py
similarity index 93%
rename from src/polytomic/types/common_output_actor.py
rename to src/polytomic/types/output_actor.py
index fc1b01c..cdd8009 100644
--- a/src/polytomic/types/common_output_actor.py
+++ b/src/polytomic/types/output_actor.py
@@ -6,7 +6,7 @@
import pydantic
-class CommonOutputActor(UniversalBaseModel):
+class OutputActor(UniversalBaseModel):
id: typing.Optional[str] = None
name: typing.Optional[str] = None
type: typing.Optional[str] = None
diff --git a/src/polytomic/types/schema_configuration.py b/src/polytomic/types/schema_configuration.py
index 530c3f4..36bf064 100644
--- a/src/polytomic/types/schema_configuration.py
+++ b/src/polytomic/types/schema_configuration.py
@@ -4,7 +4,7 @@
import typing
import datetime as dt
import pydantic
-from .v_2_schema_configuration_fields_item import V2SchemaConfigurationFieldsItem
+from .v2schema_configuration_fields_item import V2SchemaConfigurationFieldsItem
from .bulk_filter import BulkFilter
from ..core.pydantic_utilities import IS_PYDANTIC_V2
diff --git a/src/polytomic/types/v_2_connection_form.py b/src/polytomic/types/v2connection_form.py
similarity index 100%
rename from src/polytomic/types/v_2_connection_form.py
rename to src/polytomic/types/v2connection_form.py
diff --git a/src/polytomic/types/v_2_create_shared_connection_response_envelope.py b/src/polytomic/types/v2create_shared_connection_response_envelope.py
similarity index 100%
rename from src/polytomic/types/v_2_create_shared_connection_response_envelope.py
rename to src/polytomic/types/v2create_shared_connection_response_envelope.py
diff --git a/src/polytomic/types/v_2_enricher_configuration.py b/src/polytomic/types/v2enricher_configuration.py
similarity index 100%
rename from src/polytomic/types/v_2_enricher_configuration.py
rename to src/polytomic/types/v2enricher_configuration.py
diff --git a/src/polytomic/types/v_2_enricher_mapping.py b/src/polytomic/types/v2enricher_mapping.py
similarity index 100%
rename from src/polytomic/types/v_2_enricher_mapping.py
rename to src/polytomic/types/v2enricher_mapping.py
diff --git a/src/polytomic/types/v_2_execution_log_type.py b/src/polytomic/types/v2execution_log_type.py
similarity index 100%
rename from src/polytomic/types/v_2_execution_log_type.py
rename to src/polytomic/types/v2execution_log_type.py
diff --git a/src/polytomic/types/v_2_get_enrichment_input_fields_response_envelope.py b/src/polytomic/types/v2get_enrichment_input_fields_response_envelope.py
similarity index 100%
rename from src/polytomic/types/v_2_get_enrichment_input_fields_response_envelope.py
rename to src/polytomic/types/v2get_enrichment_input_fields_response_envelope.py
diff --git a/src/polytomic/types/v_2_ordered_map_string_github_com_invopop_jsonschema_schema.py b/src/polytomic/types/v2ordered_map_string_github_com_invopop_jsonschema_schema.py
similarity index 100%
rename from src/polytomic/types/v_2_ordered_map_string_github_com_invopop_jsonschema_schema.py
rename to src/polytomic/types/v2ordered_map_string_github_com_invopop_jsonschema_schema.py
diff --git a/src/polytomic/types/v_2_sample_record.py b/src/polytomic/types/v2sample_record.py
similarity index 100%
rename from src/polytomic/types/v_2_sample_record.py
rename to src/polytomic/types/v2sample_record.py
diff --git a/src/polytomic/types/v_2_schema_configuration_fields_item.py b/src/polytomic/types/v2schema_configuration_fields_item.py
similarity index 100%
rename from src/polytomic/types/v_2_schema_configuration_fields_item.py
rename to src/polytomic/types/v2schema_configuration_fields_item.py
diff --git a/src/polytomic/types/v3bulk_sync_source_capabilities.py b/src/polytomic/types/v3bulk_sync_source_capabilities.py
new file mode 100644
index 0000000..e749a4c
--- /dev/null
+++ b/src/polytomic/types/v3bulk_sync_source_capabilities.py
@@ -0,0 +1,19 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from ..core.pydantic_utilities import UniversalBaseModel
+import typing
+from ..core.pydantic_utilities import IS_PYDANTIC_V2
+import pydantic
+
+
+class V3BulkSyncSourceCapabilities(UniversalBaseModel):
+ supports_tracking_fields: typing.Optional[bool] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/polytomic/types/v_4_bulk_sync_execution_logs.py b/src/polytomic/types/v4bulk_sync_execution_logs.py
similarity index 100%
rename from src/polytomic/types/v_4_bulk_sync_execution_logs.py
rename to src/polytomic/types/v4bulk_sync_execution_logs.py
diff --git a/src/polytomic/types/v_4_bulk_sync_execution_logs_envelope.py b/src/polytomic/types/v4bulk_sync_execution_logs_envelope.py
similarity index 90%
rename from src/polytomic/types/v_4_bulk_sync_execution_logs_envelope.py
rename to src/polytomic/types/v4bulk_sync_execution_logs_envelope.py
index dc1a325..0107fa9 100644
--- a/src/polytomic/types/v_4_bulk_sync_execution_logs_envelope.py
+++ b/src/polytomic/types/v4bulk_sync_execution_logs_envelope.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_4_bulk_sync_execution_logs import V4BulkSyncExecutionLogs
+from .v4bulk_sync_execution_logs import V4BulkSyncExecutionLogs
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_bulk_sync_schedule_api.py b/src/polytomic/types/v4bulk_sync_schedule_api.py
similarity index 100%
rename from src/polytomic/types/v_4_bulk_sync_schedule_api.py
rename to src/polytomic/types/v4bulk_sync_schedule_api.py
diff --git a/src/polytomic/types/v_4_export_sync_logs_envelope.py b/src/polytomic/types/v4export_sync_logs_envelope.py
similarity index 91%
rename from src/polytomic/types/v_4_export_sync_logs_envelope.py
rename to src/polytomic/types/v4export_sync_logs_envelope.py
index c4d35c0..3d7ca23 100644
--- a/src/polytomic/types/v_4_export_sync_logs_envelope.py
+++ b/src/polytomic/types/v4export_sync_logs_envelope.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_4_export_sync_logs_response import V4ExportSyncLogsResponse
+from .v4export_sync_logs_response import V4ExportSyncLogsResponse
from .job_response import JobResponse
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_export_sync_logs_response.py b/src/polytomic/types/v4export_sync_logs_response.py
similarity index 100%
rename from src/polytomic/types/v_4_export_sync_logs_response.py
rename to src/polytomic/types/v4export_sync_logs_response.py
diff --git a/src/polytomic/types/v_4_global_error_subscribers_response.py b/src/polytomic/types/v4global_error_subscribers_response.py
similarity index 100%
rename from src/polytomic/types/v_4_global_error_subscribers_response.py
rename to src/polytomic/types/v4global_error_subscribers_response.py
diff --git a/src/polytomic/types/v_4_query_results_envelope.py b/src/polytomic/types/v4query_results_envelope.py
similarity index 93%
rename from src/polytomic/types/v_4_query_results_envelope.py
rename to src/polytomic/types/v4query_results_envelope.py
index ddadfc2..24e00e7 100644
--- a/src/polytomic/types/v_4_query_results_envelope.py
+++ b/src/polytomic/types/v4query_results_envelope.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_4_run_query_result import V4RunQueryResult
+from .v4run_query_result import V4RunQueryResult
from .pagination import Pagination
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_run_query_envelope.py b/src/polytomic/types/v4run_query_envelope.py
similarity index 92%
rename from src/polytomic/types/v_4_run_query_envelope.py
rename to src/polytomic/types/v4run_query_envelope.py
index 9e16f20..ec8352b 100644
--- a/src/polytomic/types/v_4_run_query_envelope.py
+++ b/src/polytomic/types/v4run_query_envelope.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_4_run_query_result import V4RunQueryResult
+from .v4run_query_result import V4RunQueryResult
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_run_query_result.py b/src/polytomic/types/v4run_query_result.py
similarity index 92%
rename from src/polytomic/types/v_4_run_query_result.py
rename to src/polytomic/types/v4run_query_result.py
index f33eaae..a3d3580 100644
--- a/src/polytomic/types/v_4_run_query_result.py
+++ b/src/polytomic/types/v4run_query_result.py
@@ -26,7 +26,7 @@ class V4RunQueryResult(UniversalBaseModel):
id: typing.Optional[str] = pydantic.Field(default=None)
"""
- The ID of the query task.
+ The ID of the query task. Poll GET /api/queries/{id} until the task reaches done or failed to retrieve results.
"""
results: typing.Optional[typing.List[typing.Dict[str, typing.Optional[typing.Any]]]] = pydantic.Field(default=None)
diff --git a/src/polytomic/types/v_4_target_creator.py b/src/polytomic/types/v4target_creator.py
similarity index 100%
rename from src/polytomic/types/v_4_target_creator.py
rename to src/polytomic/types/v4target_creator.py
diff --git a/src/polytomic/types/v_4_target_objects_response_envelope.py b/src/polytomic/types/v4target_objects_response_envelope.py
similarity index 93%
rename from src/polytomic/types/v_4_target_objects_response_envelope.py
rename to src/polytomic/types/v4target_objects_response_envelope.py
index 178d0f9..144febe 100644
--- a/src/polytomic/types/v_4_target_objects_response_envelope.py
+++ b/src/polytomic/types/v4target_objects_response_envelope.py
@@ -3,7 +3,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
from .target_object import TargetObject
-from .v_4_target_creator import V4TargetCreator
+from .v4target_creator import V4TargetCreator
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_target_property_values.py b/src/polytomic/types/v4target_property_values.py
similarity index 100%
rename from src/polytomic/types/v_4_target_property_values.py
rename to src/polytomic/types/v4target_property_values.py
diff --git a/src/polytomic/types/v_4_target_property_values_envelope.py b/src/polytomic/types/v4target_property_values_envelope.py
similarity index 90%
rename from src/polytomic/types/v_4_target_property_values_envelope.py
rename to src/polytomic/types/v4target_property_values_envelope.py
index 1986743..9a97e3a 100644
--- a/src/polytomic/types/v_4_target_property_values_envelope.py
+++ b/src/polytomic/types/v4target_property_values_envelope.py
@@ -2,7 +2,7 @@
from ..core.pydantic_utilities import UniversalBaseModel
import typing
-from .v_4_target_property_values import V4TargetPropertyValues
+from .v4target_property_values import V4TargetPropertyValues
from ..core.pydantic_utilities import IS_PYDANTIC_V2
import pydantic
diff --git a/src/polytomic/types/v_4_user_field_request.py b/src/polytomic/types/v4user_field_request.py
similarity index 100%
rename from src/polytomic/types/v_4_user_field_request.py
rename to src/polytomic/types/v4user_field_request.py
diff --git a/src/polytomic/users/client.py b/src/polytomic/users/client.py
index a1cf052..96b2fd5 100644
--- a/src/polytomic/users/client.py
+++ b/src/polytomic/users/client.py
@@ -211,14 +211,14 @@ def create(
raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
- def get(self, id: str, org_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> UserEnvelope:
+ def get(self, org_id: str, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> UserEnvelope:
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -236,8 +236,8 @@ def get(self, id: str, org_id: str, *, request_options: typing.Optional[RequestO
token="YOUR_TOKEN",
)
client.users.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -301,8 +301,8 @@ def get(self, id: str, org_id: str, *, request_options: typing.Optional[RequestO
def update(
self,
- id: str,
org_id: str,
+ id: str,
*,
email: str,
role: typing.Optional[str] = OMIT,
@@ -312,10 +312,10 @@ def update(
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
email : str
role : typing.Optional[str]
@@ -339,8 +339,8 @@ def update(
token="YOUR_TOKEN",
)
client.users.update(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
email="mail@example.com",
)
"""
@@ -412,14 +412,14 @@ def update(
raise core_api_error_ApiError(status_code=_response.status_code, body=_response.text)
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
- def remove(self, id: str, org_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> UserEnvelope:
+ def remove(self, org_id: str, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> UserEnvelope:
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -437,8 +437,8 @@ def remove(self, id: str, org_id: str, *, request_options: typing.Optional[Reque
token="YOUR_TOKEN",
)
client.users.remove(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
"""
_response = self._client_wrapper.httpx_client.request(
@@ -570,6 +570,16 @@ def create_api_key(
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(
@@ -801,15 +811,15 @@ async def main() -> None:
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
async def get(
- self, id: str, org_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ self, org_id: str, id: str, *, request_options: typing.Optional[RequestOptions] = None
) -> UserEnvelope:
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -832,8 +842,8 @@ async def get(
async def main() -> None:
await client.users.get(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
@@ -900,8 +910,8 @@ async def main() -> None:
async def update(
self,
- id: str,
org_id: str,
+ id: str,
*,
email: str,
role: typing.Optional[str] = OMIT,
@@ -911,10 +921,10 @@ async def update(
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
email : str
role : typing.Optional[str]
@@ -943,8 +953,8 @@ async def update(
async def main() -> None:
await client.users.update(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
email="mail@example.com",
)
@@ -1020,15 +1030,15 @@ async def main() -> None:
raise core_api_error_ApiError(status_code=_response.status_code, body=_response_json)
async def remove(
- self, id: str, org_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ self, org_id: str, id: str, *, request_options: typing.Optional[RequestOptions] = None
) -> UserEnvelope:
"""
Parameters
----------
- id : str
-
org_id : str
+ id : str
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -1051,8 +1061,8 @@ async def remove(
async def main() -> None:
await client.users.remove(
- id="248df4b7-aa70-47b8-a036-33ac447e668d",
org_id="248df4b7-aa70-47b8-a036-33ac447e668d",
+ id="248df4b7-aa70-47b8-a036-33ac447e668d",
)
@@ -1195,6 +1205,16 @@ async def main() -> None:
),
)
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ typing.cast(
+ types_api_error_ApiError,
+ parse_obj_as(
+ type_=types_api_error_ApiError, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ )
if _response.status_code == 404:
raise NotFoundError(
typing.cast(