structifyai 1.180.0__py3-none-any.whl → 1.182.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. structify/_base_client.py +5 -2
  2. structify/_compat.py +3 -3
  3. structify/_utils/_json.py +35 -0
  4. structify/_version.py +1 -1
  5. structify/resources/__init__.py +0 -2
  6. structify/resources/connector_catalog/admin.py +76 -0
  7. structify/resources/polars.py +2 -7
  8. structify/resources/sessions.py +83 -0
  9. structify/resources/teams.py +12 -76
  10. structify/resources/wiki.py +9 -10
  11. structify/resources/workflow.py +7 -1
  12. structify/types/__init__.py +5 -4
  13. structify/types/admin/admin_sandbox.py +0 -2
  14. structify/types/{team_create_link_code_params.py → cell_edit_param.py} +7 -3
  15. structify/types/chat_create_session_params.py +1 -0
  16. structify/types/code_generate_code_params.py +1 -0
  17. structify/types/dashboard_component.py +7 -45
  18. structify/types/dashboard_component_param.py +8 -52
  19. structify/types/dashboard_page.py +3 -3
  20. structify/types/dashboard_page_param.py +3 -3
  21. structify/types/job_event_body.py +4 -0
  22. structify/types/parquet_edit_param.py +29 -0
  23. structify/types/session_edit_node_output_params.py +14 -0
  24. structify/types/session_edit_node_output_response.py +11 -0
  25. structify/types/team_update_params.py +6 -0
  26. structify/types/usage_group_key.py +1 -0
  27. structify/types/user_info.py +4 -0
  28. structify/types/wiki_list_response.py +3 -22
  29. structify/types/{wiki_create_response.py → wiki_page.py} +2 -2
  30. structify/types/wiki_page_with_references.py +2 -18
  31. structify/types/workflow_run_params.py +3 -0
  32. structify/types/workflow_session_node.py +2 -0
  33. {structifyai-1.180.0.dist-info → structifyai-1.182.0.dist-info}/METADATA +1 -1
  34. {structifyai-1.180.0.dist-info → structifyai-1.182.0.dist-info}/RECORD +36 -36
  35. structify/resources/external.py +0 -99
  36. structify/resources/external_dataframe_proxy.py +0 -290
  37. structify/types/teams_link_code_response.py +0 -13
  38. structify/types/wiki_update_response.py +0 -23
  39. {structifyai-1.180.0.dist-info → structifyai-1.182.0.dist-info}/WHEEL +0 -0
  40. {structifyai-1.180.0.dist-info → structifyai-1.182.0.dist-info}/licenses/LICENSE +0 -0
@@ -1,7 +1,7 @@
1
1
  structify/__init__.py,sha256=iTxRcLR7HWp1YeRMIYsfnXOaE6rQpTsJ0FXNHDHndu0,2730
2
- structify/_base_client.py,sha256=SJoa_GzUHzS9A-EM09RC4sfh191TJYQ_H2s_dte3NmE,73412
2
+ structify/_base_client.py,sha256=9-g71mAkrPd3uh-o7Y3R7BZg9O4GCVSVJu7rohgbaDY,73661
3
3
  structify/_client.py,sha256=grGQVWPspa6PqFIcGB4wsQy2O43wCV1wNDN627Db7Ac,57347
4
- structify/_compat.py,sha256=DQBVORjFb33zch24jzkhM14msvnzY7mmSmgDLaVFUM8,6562
4
+ structify/_compat.py,sha256=teO44AYozpv2wFRrUi7brcZfGPpFSERQZ4fcdX6zVvs,6627
5
5
  structify/_constants.py,sha256=S14PFzyN9-I31wiV7SmIlL5Ga0MLHxdvegInGdXH7tM,462
6
6
  structify/_exceptions.py,sha256=azVty2y26_7gMMJfJIn5F7FEDvdfHwPrrRUuQ8gdrns,3226
7
7
  structify/_files.py,sha256=I95i1rbKWr7Aay6h6lDfmDI8XtSGUVB_9DC5opBzYnU,3620
@@ -11,12 +11,13 @@ structify/_resource.py,sha256=tJi4pDQooQZ_zJwEwrLj-U-ye2hC-cbmr1GzIwCT10Y,1118
11
11
  structify/_response.py,sha256=RuNhMDiZUdPqEbmFJHDVI4FMPDszk8QjK9LVWm1Fagk,28806
12
12
  structify/_streaming.py,sha256=n4C9M7ITmANYn9LaWHNoqJdIIyF7svLco2qst7u3M7U,10233
13
13
  structify/_types.py,sha256=jj4p-m3vpUma0AdhPWIaljHZXeb4RKnrAusjVdpDy5Y,7597
14
- structify/_version.py,sha256=j3DkUZvs9-jBxvatoUgZdstV_KU-5yKarYbkIEqKmIQ,163
14
+ structify/_version.py,sha256=ILPrQ9kM5sEQ2errwpkce8Q0g-d5KtnWYy6YrauEuRI,163
15
15
  structify/pagination.py,sha256=ycybhWcpKk4ztsMcCA6C0WZiJejGrSx6bSr8LLskJUY,4346
16
16
  structify/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
17
17
  structify/_utils/__init__.py,sha256=7fch0GT9zpNnErbciSpUNa-SjTxxjY6kxHxKMOM4AGs,2305
18
18
  structify/_utils/_compat.py,sha256=D8gtAvjJQrDWt9upS0XaG9Rr5l1QhiAx_I_1utT_tt0,1195
19
19
  structify/_utils/_datetime_parse.py,sha256=bABTs0Bc6rabdFvnIwXjEhWL15TcRgWZ_6XGTqN8xUk,4204
20
+ structify/_utils/_json.py,sha256=bl95uuIWwgSfXX-gP1trK_lDAPwJujYfJ05Cxo2SEC4,962
20
21
  structify/_utils/_logs.py,sha256=1bVeMaco4ZZE0QXtuCgDMrrFtpCiumVQHm18T1Yhi9c,783
21
22
  structify/_utils/_proxy.py,sha256=aglnj2yBTDyGX9Akk2crZHrl10oqRmceUy2Zp008XEs,1975
22
23
  structify/_utils/_reflection.py,sha256=ZmGkIgT_PuwedyNBrrKGbxoWtkpytJNU1uU4QHnmEMU,1364
@@ -29,31 +30,29 @@ structify/_utils/_utils.py,sha256=ugfUaneOK7I8h9b3656flwf5u_kthY0gvNuqvgOLoSU,12
29
30
  structify/lib/.keep,sha256=wuNrz-5SXo3jJaJOJgz4vFHM41YH_g20F5cRQo0vLes,224
30
31
  structify/lib/__init__.py,sha256=Ueo7RB2lM1a3wkuifgjgBpqwQxhQUHJzvGorfJAfuUc,187
31
32
  structify/lib/cost_confirmation.py,sha256=LvE76RQ0zVU17-qcYvQiH6NBtORIA7m4b72f1_YLMUg,2069
32
- structify/resources/__init__.py,sha256=uEPBix75KmHK4iO50jocLO_psMYaebe-jkemfOjlz_U,12597
33
+ structify/resources/__init__.py,sha256=vJMl_aqZBcQ2lbdPwc3Z_MfccZVwVIkYtkff002C9BU,12534
33
34
  structify/resources/chat.py,sha256=RIYa-2vgc1I2G52cp5Ak6sIBJf04TWbH5IoGd-r38Co,91243
34
35
  structify/resources/code.py,sha256=geloVbg4Bul_2OOFJ9OfaGOafRaN2PtQcerttBKnyZE,11634
35
36
  structify/resources/documents.py,sha256=QBuL5NQyW1XrncP4tjyb9yLFgqPgWCXa8Zj1uESy5j8,18180
36
37
  structify/resources/entities.py,sha256=Fz4yCEdsxs-62bjmkYZY9Ku_tzDe73Q4xfqv_XHGe_M,81990
37
- structify/resources/external.py,sha256=lVZCAEwNKTSGSZasGFibDmIC9N6MseJRkgBFCNvgcQU,3556
38
- structify/resources/external_dataframe_proxy.py,sha256=DSn0YwWIembR__ZtDxVCJtyY3v4bXX6S5OTTw0mMGd0,11819
39
38
  structify/resources/jobs.py,sha256=gO1aSByi1dMvW90UDsMmNhLHFCOY4ENLkZcAx4gbLHY,30108
40
39
  structify/resources/match.py,sha256=gDWEWnKwEoLbheQAMFltJCk2ysa_L9AuJMOaauM7c4Y,12248
41
40
  structify/resources/nango.py,sha256=Zl0M1XhlVe61jHVd-SdYI9uEbEhIRmskvlk7Xp0Lh8g,9166
42
- structify/resources/polars.py,sha256=9uluqVdLXu5ZpR9-v7B6i3TJVV47zKtILOJwAzz5lkU,60817
41
+ structify/resources/polars.py,sha256=3rxzm4hg3qWxm6Ho_UcBrTEXlzL4tICr3Zj2L913IY8,60606
43
42
  structify/resources/projects.py,sha256=YDikBDB9D1EXyZ2GyRx4GlpQ83snw51YlNuU1sLHqho,14117
44
43
  structify/resources/public_sessions.py,sha256=_JmssE0MMjeGdxT0FWtrkcceSV4skeEkVGYeO2FkJes,9976
45
44
  structify/resources/sandbox.py,sha256=KgpZ623G6T_3_oovCgjlxO81M63NanMBAezVDdesOCc,12807
46
45
  structify/resources/scrape.py,sha256=vAEjjOqH0gVOlEs_JvHLMQ-W9zfF28vwdm45CCO2bSs,12119
47
46
  structify/resources/server.py,sha256=39G3yhj3NYWgnLq0PdS86lwDvXK6MIWAIl7G0ZLMJro,4934
48
- structify/resources/sessions.py,sha256=TWTnvSVuh_oIhXB2LCq9FP8gcwN1Sf_2kKmWX_jBoLs,66746
47
+ structify/resources/sessions.py,sha256=eGdSNP4UAjf2zFyh71RE0ZJ9rD3d00d8ztI2vodzL8k,70325
49
48
  structify/resources/slack.py,sha256=AIHLIzIKAHiw4HwLHlHQcqQYROBaqNA6ceuYpOGPbVo,13038
50
49
  structify/resources/sources.py,sha256=K5jLPKu3LNH5vKL9V1NQlHaG8UI982H74enN_cjdf-0,13181
51
50
  structify/resources/structure.py,sha256=jXcVdUuNc6Q-HwUhSDcsJONbBqRf_FcPAjNtjXYxrdo,33124
52
- structify/resources/teams.py,sha256=W1Isf2lXDLB-xdzgR8qJwCrziElOY25OcsQfIBKQ1Sc,55575
51
+ structify/resources/teams.py,sha256=ynbuFJmPtchriPPVXcwIlcaghaXncsGge6vnCuXPDN8,53156
53
52
  structify/resources/whitelabel.py,sha256=0TQ3HJccdflpAVcHqydizT4RznkRvZBRP0--0szjDps,12865
54
53
  structify/resources/whitelabel_service.py,sha256=cqGBpRegtJRjt5WFNPCXTwyGKHTAbBUrhJP1UroEhVQ,9439
55
- structify/resources/wiki.py,sha256=sFS6i3etYwiQB9iRbdxhQr3y9C9jeVLx6hWCQhu7Tdc,19762
56
- structify/resources/workflow.py,sha256=D8gnt22usKoY9iA3HTNlbQyWTykNUXl2m3rFsPAKZZc,9273
54
+ structify/resources/wiki.py,sha256=QaaFQOAaB5u3Ft3EKwM1XxVK7EHG1bjSlWp6zFugaLE,19601
55
+ structify/resources/workflow.py,sha256=UmCzU150KeJxWL8XI7jAoPsbXBu4qyEN_L4KiiDXxog,9540
57
56
  structify/resources/workflow_schedule.py,sha256=bP7rxm0OsW27zt2Y5EF7EILfFzP3lKFIaRRr_8MbZvA,29807
58
57
  structify/resources/admin/__init__.py,sha256=QbNLwto24WRX1DgTltNy7lRPrwp4bgRla_pmd0fRedM,4362
59
58
  structify/resources/admin/admin.py,sha256=pRiBhmMOpM_k7aYtKA9yl1tfF5kz_KsTe4K-7GIvXMA,11549
@@ -66,7 +65,7 @@ structify/resources/admin/sandbox.py,sha256=BHk78aJIExnz_dNxmD0ZQ9VERQj7IYE0i3mp
66
65
  structify/resources/admin/teams.py,sha256=-xR3N8tGF2uI4SMHwsLnAf6q36z42hLHAWDPA8vXASo,25921
67
66
  structify/resources/admin/users.py,sha256=F0xis-9-Wo5qQHLGvAnJ9Ekao4Ssew043z9sCbOeEH8,17496
68
67
  structify/resources/connector_catalog/__init__.py,sha256=uwvbyu4gu4pZ_px3-Nhhh2lxiosNwQGlqW-IIbbWgx8,1120
69
- structify/resources/connector_catalog/admin.py,sha256=2ob0yPRr_zyoHGs-XTIupwCCnO9LgddXP-ToAJtTxmw,60801
68
+ structify/resources/connector_catalog/admin.py,sha256=2PdxfKYa5prqw1loqF-OAW7eLf2C4Ij08S2ZiCQgcPc,63807
70
69
  structify/resources/connector_catalog/connector_catalog.py,sha256=0cl-NXRalMWtcsWXkKEAPlxZ_slhR1VW4FsPBE81iWY,15533
71
70
  structify/resources/connectors/__init__.py,sha256=XshER9L_6E2kY_zKa1VTkY_UmEIAoi3MkeFYJdGGH0U,1133
72
71
  structify/resources/connectors/connectors.py,sha256=GO6LloGr2mm1eJk-QDDgS8ANuBOneo4cX-ajmTG5Mbo,103070
@@ -78,12 +77,13 @@ structify/resources/user/__init__.py,sha256=vkGsM7uGlBXVVwuEZlICVLlIY3F75n_MIMpm
78
77
  structify/resources/user/api_keys.py,sha256=LgKvDGkHPGIumWmEsPCA1XYAKNuRN48nqG6anv8AVHE,14331
79
78
  structify/resources/user/stripe.py,sha256=MazkGQ5VuNY7TxMPXxJULBVerMGmOXaEcXpfQsUYoNs,13574
80
79
  structify/resources/user/user.py,sha256=Hk8D5KB8in-A9eJSYFIosILz4HgSWDwDDAVIQeQ8Sew,25411
81
- structify/types/__init__.py,sha256=Gm7OWeLpLh0Z3gAvf_m_GIZQTTz29k-o3cih1i4tTGQ,28588
80
+ structify/types/__init__.py,sha256=F6_BVplbMAjn_AXb6rTMWfNfaPq4VW7hFrFZKFm1m_0,28645
82
81
  structify/types/accept_invitation_response.py,sha256=hWIn0Sscg7U0uOqoZA5SG8ENZQuM0tsbgOlrJbcW37s,260
83
82
  structify/types/add_member_response.py,sha256=_YjqwGpsfdR9Dw6SAQ99TveFSD8Hov1IjVPMH2KC3CM,882
84
83
  structify/types/admin_grant_access_response.py,sha256=xCPdmejgZs1oXOsfgbW-cYKZa8getHRotRnsCav5QPU,390
85
84
  structify/types/admin_issue_found_response.py,sha256=b8O7QVfXlRflcx3Rb6Cwf35LBxv_5bTXhCRkPfnHXbk,222
86
85
  structify/types/autofix_context.py,sha256=E4Dc7VjDiblbW8UBXBOz-iNjznAQiZ7tMs3J7sHGSI8,245
86
+ structify/types/cell_edit_param.py,sha256=Ra5V8Jc44KP4u6uhpSuPhJKezxJXTSxT7cn3q36WcPo,336
87
87
  structify/types/chat_add_collaborator_params.py,sha256=FyKIC2eOgSx0e-jeomFovoJs_eJStulK3zCZQtxl2M8,383
88
88
  structify/types/chat_add_git_commit_params.py,sha256=y4HmhC4jLX7GFatchxl__4ztkuQwhxc6NU0-j_YGZQo,352
89
89
  structify/types/chat_add_git_commit_response.py,sha256=T2hCiHvxd3LvIIYqsDyIZommTtyygveda-3AIEZy2mQ,431
@@ -91,7 +91,7 @@ structify/types/chat_admin_issue_found_params.py,sha256=N5YMgm6O-Yr3sXZb2sWDHdyN
91
91
  structify/types/chat_copy_node_output_by_code_hash_params.py,sha256=gP4V2Y0_Rb4-kwoEceClJLgjVdWv7bgcI4qqQIvdNv8,356
92
92
  structify/types/chat_copy_node_output_by_code_hash_response.py,sha256=Cst1RK9jDrMAKEyzLIk5_-D6YUbO-AIVllYui2sy2aQ,272
93
93
  structify/types/chat_copy_params.py,sha256=tfA3jdduKDJeHiYjWWKdHifRMp1sCGyGQcYHFuMFdnE,425
94
- structify/types/chat_create_session_params.py,sha256=tyt7TJt03vz9-Jw4QU8UbvdbTiPMPK5843gNJQ5Dck8,1885
94
+ structify/types/chat_create_session_params.py,sha256=yW0VCTUZvm49h5E9ILsOT-GqQrJ3cl03NZBhGVq3HCk,1932
95
95
  structify/types/chat_delete_files_params.py,sha256=Rv24bWe1CK524xobl9-_APx5GG8KTqIwEtUgYIUlMXc,343
96
96
  structify/types/chat_delete_files_response.py,sha256=ZoFJjfZqn_rVuwiFhsuFigN_AQHh_DRkb5KRj7J_49g,225
97
97
  structify/types/chat_dependency.py,sha256=J8JLY6kBjFt4dgf-_Vk_HEjxS5R6_6VnTQue2JzZRug,415
@@ -115,7 +115,7 @@ structify/types/chat_update_session_favorite_params.py,sha256=UNi0YujSs1gCSry2jK
115
115
  structify/types/chat_update_session_params.py,sha256=5NQZx-j-W2xQGlX0GU-9vwyQt0QunlifWY2MpRtrEv8,382
116
116
  structify/types/chat_update_visibility_params.py,sha256=uWtgq4zb_TSO4hIsY0FmdWaljB_20wpjl6IQhRMibTg,361
117
117
  structify/types/chat_visibility.py,sha256=GpTgjpcupE1z9Iul8fxOrlMoP_2wjQ_7Z0rJ2y9qO5Q,244
118
- structify/types/code_generate_code_params.py,sha256=K44J7mgJT6491hb-nLLARwkDsC7TMl2XIxuIIQZCoFw,2393
118
+ structify/types/code_generate_code_params.py,sha256=qLGX2QrJSxAe31RPL8s0K3U7BnoHkJHTZkkvg0CFyTA,2440
119
119
  structify/types/code_interrupt_generation_params.py,sha256=1Y9VOgObIJFyYgAEkUuWZRKKV5-4HcoRA6p5iSEnF3s,410
120
120
  structify/types/connector.py,sha256=hqfk8x1ZM39idvAd4wXLm1QNrnT3kRgxEuhk8O28-B0,1069
121
121
  structify/types/connector_add_schema_object_params.py,sha256=9mnIPgBHlfAlyhsDAjGQUBfm0ar17o2z0GdQHsRL1ts,1187
@@ -156,10 +156,10 @@ structify/types/create_team_response.py,sha256=mx1zK2SVOkJhbMGn84U-ZLopAOJc5s7cE
156
156
  structify/types/credits_usage_response.py,sha256=O9ts7pDvcLYq8ROfrjdoNoKjITGdpYECNTOGIMxXgsQ,395
157
157
  structify/types/credits_usage_timeseries_point.py,sha256=YYlcuWQtsuYspxEy3Upxa4p81ERaP0KRWpVpIJxdsQ8,320
158
158
  structify/types/dashboard.py,sha256=vW4mMWHP8RZCTWhTewtxNhRlvVOqpyYWx8kJ2LsyaR0,583
159
- structify/types/dashboard_component.py,sha256=F-qV0WvWNPUb9MP1MjLUNK1UBlFG2p_TVbMBPv3_9JY,1632
160
- structify/types/dashboard_component_param.py,sha256=rvuSDuPApM6BufdeY2SZY3095hvFoJQB8ZJNEUuxOD4,1877
161
- structify/types/dashboard_page.py,sha256=VN8Yq_ufQNJHozBVXUjkqtBvTjYdwDNlaW969ZYuHYs,2190
162
- structify/types/dashboard_page_param.py,sha256=8Bz8tfhjJDYrT-j7-oI9zd0Bb2--lmIXJC7B9KTOxEc,2472
159
+ structify/types/dashboard_component.py,sha256=aMqud95c0AkIgsSsY4HCBagZ9eteBwgmgw45UQCNmdk,671
160
+ structify/types/dashboard_component_param.py,sha256=aRXT2O0YG1crpzv8J5c7LLCQDFobcDoAJq59e5jRong,753
161
+ structify/types/dashboard_page.py,sha256=5TIBxquMXBeoV9Mic0qORQTxCDeKXEU7db8xbevoiZ8,2207
162
+ structify/types/dashboard_page_param.py,sha256=NqGPNGQyTQFuW7H-rhM7I7UuQZYu4aagBsrh3qR1hNU,2472
163
163
  structify/types/dashboard_param.py,sha256=XNvfcb6dKVam7qNxQCJZrNtPIt16M8_xNguOs3EYO_o,697
164
164
  structify/types/dataset_add_property_params.py,sha256=jKruESCLtFzH0uer5jh-uCqv1FFov6MOaa5u-W1rQYc,641
165
165
  structify/types/dataset_count_missing_embeddings_params.py,sha256=w3ZUrh8B9QKEKC87ZKIH6L01SjtMHZ-BIFh6JvI8EcQ,317
@@ -264,7 +264,7 @@ structify/types/granularity.py,sha256=At6biWApGE7uE8jr5KnHP9Jr1yPFkuqLwXjExaswtB
264
264
  structify/types/image.py,sha256=FpYU3gDZnet0wO17e2uHzcyRUD6E1ssSgv63Ew0DzjU,269
265
265
  structify/types/invitation_details_response.py,sha256=TmyeM4mW4Kb6L0d7Ook9cH3g8vzfQYPnvZDIBdgVAO4,272
266
266
  structify/types/job_cancel_response.py,sha256=y8M8qPkcXT-pTi4IwQ0JBJQzXeAQIs3u2OsaVeGBTtc,1224
267
- structify/types/job_event_body.py,sha256=pO11fTm5sGvQ6cx7NvWTitUaunSqdRo-d5tkyh4KPsk,3906
267
+ structify/types/job_event_body.py,sha256=HjkafxlGmXkIlG90rpbGPCT6D910wKmppnObq5RWhb4,4004
268
268
  structify/types/job_get_scrapers_response.py,sha256=JsbPIyUlLS3iZNyYulU8X7eF_XOmhRqYjoiGh8lnfQg,774
269
269
  structify/types/job_get_source_entities_response.py,sha256=vlGKFkMKjII48EexIEBbls6-PAVYDDkmR1__aKjuiUo,3379
270
270
  structify/types/job_list_params.py,sha256=i_MYi4vIFC6Dq5I4E4htYwZejqRE5qAf2lgg_SRBuKg,1012
@@ -290,6 +290,7 @@ structify/types/nango_create_session_params.py,sha256=S-cFduHSo4Xo_9H8OMobe4w3fN
290
290
  structify/types/nango_create_session_response.py,sha256=vR-6ZliJVNcWDVEulY0FrfjWHvjLUgheylbmv49WU-E,336
291
291
  structify/types/nango_list_integrations_response.py,sha256=vOkt-fFfoB5c1Lq8eU8O47uYL8yaoS7ts4exhVtjJww,670
292
292
  structify/types/node_spec_param.py,sha256=5IBn7iljb1KP3J-JOjWqC8RZyJpJtFDivpQ5Mbfbyiw,432
293
+ structify/types/parquet_edit_param.py,sha256=Q5peybrFKn4APflzV-4ADh-rO7VjrlWXJZHWIf6u4ak,721
293
294
  structify/types/project.py,sha256=FGidpktcJ1b902oyYYgcWifAzBhDzzDFUC1mJ_acJ2U,450
294
295
  structify/types/project_collaborator_input_param.py,sha256=im-J3ioTcmR-R3pJxQ6wSIdJC70ILGmDF59zpBVuJes,391
295
296
  structify/types/project_get_response.py,sha256=CkZRyaA4xlJfqsJGrwM5vzQNqUEfRzqfpgWvpBbv_Z4,287
@@ -318,6 +319,8 @@ structify/types/select_team_response.py,sha256=oeaOS6JMvl60Ub3ERg9qHDgGHjgWiMVFJ
318
319
  structify/types/server_information.py,sha256=JLj58jDeeXB4QlYxDNpNUivEHTGQlohOKf9RRbJIJmc,207
319
320
  structify/types/session_confirm_node_params.py,sha256=rLI5622Gm7BG6TZsWR29bqafVOwOs-TdS0jLOMxoEQI,301
320
321
  structify/types/session_create_session_params.py,sha256=f1p_2GNHMLX_JJE81qx2oi-uUpWHLFhvf4GauU68KbY,379
322
+ structify/types/session_edit_node_output_params.py,sha256=5HPYI6rEdKmYJr8autChGW_I2nHlDN07sFQDOzPWvYk,403
323
+ structify/types/session_edit_node_output_response.py,sha256=jPJIwHIObOqSEJTHM4dP-wOgfisgwKp5TeOhb4YZH0g,283
321
324
  structify/types/session_finalize_dag_params.py,sha256=A7bRmRwWeWei59ePU5r5H-aZbBsqmjDjK-GA3l2ixfs,716
322
325
  structify/types/session_get_events_params.py,sha256=cwtwE54FsCPi09H27SbPTq4XEL8fQ611INVEjHLPvUE,433
323
326
  structify/types/session_get_events_response.py,sha256=77FUiIRnZFnLu8oXIUoRuzlPrSKo4U5fhw6lSb9zb0U,1083
@@ -361,16 +364,14 @@ structify/types/table_param.py,sha256=l3Xfw-bNgtgDwAtHw7pQLUReAmVz2SdHXedCGhvD-k
361
364
  structify/types/team.py,sha256=A8IKadmDAYUEbv0TZacN7PXx_dw_AmyN_ThjGuIoDuc,688
362
365
  structify/types/team_accept_invitation_params.py,sha256=szwKVdKklkjcFIjTwFJFnpojwI1S9gykppaHMGMa45k,300
363
366
  structify/types/team_add_member_params.py,sha256=Tam3Nsx-ZyAANjGVOkrGpdmakiNd-q8WopnZk6pPVJY,349
364
- structify/types/team_create_link_code_params.py,sha256=IXOQuTc04EFq549vNBwg2IxFzk_x10H3kCnXDBGcMbY,298
365
367
  structify/types/team_create_params.py,sha256=vjpDIzXKCstCDIsRh_kdYoe-tAvICG49rchcNshuye8,339
366
368
  structify/types/team_create_project_params.py,sha256=zTy_1_g1BYw6xVIt4HkkWg2iw5uJ5KJ1wU8Vi0nfy7s,353
367
369
  structify/types/team_credits_usage_params.py,sha256=or8q9PVvAB7fgRfqDuQjZ6xoyUEapZ8q8cZcpMrO-Bc,799
368
370
  structify/types/team_role.py,sha256=xlMM8_rJ_7N77mkUaH709rcCLKN6IvjfqUdxHRguMxs,232
369
371
  structify/types/team_subscription_status.py,sha256=6ZPOvV0DSr0G0INYit4MZIz414r4AW5LPGdT4rvj_x0,619
370
372
  structify/types/team_update_member_role_params.py,sha256=K7_ylgRKDTOT3yqqyhpUCV9AQllv3VII0OiVS8CxehI,365
371
- structify/types/team_update_params.py,sha256=02KyDHm0xqZgdy6HgHNLCBcOSyMSrYh3dt8o-eVjrzQ,512
373
+ structify/types/team_update_params.py,sha256=bDSzUPGujnxHEBZGX6xuR5JEBTVcj9vgaZBKvW6OPMM,620
372
374
  structify/types/team_with_role.py,sha256=t-UgnD90UmxlMpLHdxN8L7kK7VxMVLj-PM26NvkV_2U,327
373
- structify/types/teams_link_code_response.py,sha256=p81nvCP4KeGVUgQiiaFwAlLMRaGnG4Iv7rp03WFG0uA,269
374
375
  structify/types/token_response.py,sha256=N75RMh9ZF05z5Ubc_Pu2pePe3MN7Yqn2GB1FJ8FQJZ0,408
375
376
  structify/types/tool_invocation.py,sha256=HCc_nFmfjm5MnoDKDbtnh7TIvLEH7gvsBI4IIU0AxO4,7995
376
377
  structify/types/tool_metadata.py,sha256=drtuS9ZQm4cB2KScB1pycX1ifjhGwSUMJm9TFv1SHuI,382
@@ -379,9 +380,9 @@ structify/types/update_member_role_response.py,sha256=q1jTM0lFmzvH8ki7GcSQAh-5cN
379
380
  structify/types/update_table_response.py,sha256=ypJEzW8JcLOmLpoZq46i7ADFUkHqBGeo0AhtiSq8HAk,1156
380
381
  structify/types/update_team_response.py,sha256=AOm2-jzpjF3UVRh3msyc8W00l-hNpk_SqmMI3oK_YBE,230
381
382
  structify/types/update_visibility_response.py,sha256=veHlq90QKDCiY__DLHGQQloyZhxy6wSJ_6bPn18bisY,279
382
- structify/types/usage_group_key.py,sha256=vOoCW73KNK4BG6KXLPCF9D7J6JjJBssFvhDdDPlkHpo,380
383
+ structify/types/usage_group_key.py,sha256=l4N9cfbG__fU40DvRg06Ni3Y62m2LcG_aTskrRy54qc,393
383
384
  structify/types/user_enrich_params.py,sha256=bXOLnyPxG-iqFk1KZCjRGpcy8osRs6QYEVLtN_7HXf8,280
384
- structify/types/user_info.py,sha256=L2FckSvAPuRpgwNgwOoYF2WYwHrHmuDDAehq3-EeUWQ,1562
385
+ structify/types/user_info.py,sha256=psldAc_hgXf6U2q9cb8oGtcbmcNCm-eCfCKF-aFIZYo,1646
385
386
  structify/types/user_refresh_params.py,sha256=_YdNJ1SZg78JkhfLGiuMq-NsN7zAlF0DG3GvDaaMOpY,324
386
387
  structify/types/user_survey_submit_params.py,sha256=YLrpWzTb-RHA_uHM02O36ZPnXbtakoLrqQIoMcxBjWo,340
387
388
  structify/types/user_transactions_response.py,sha256=2Us052s3oqN0dF0h8oBKJlSebaxBd-arIY-6499lkcc,628
@@ -390,15 +391,14 @@ structify/types/user_usage_params.py,sha256=9pIC03UG1gStMjuSTIp2FFgFqmBWTFvIgYcw
390
391
  structify/types/user_usage_response.py,sha256=EDuJrPsWkTQOMImx7EARAzL_lO23AeW_-rRWXGAArJ0,263
391
392
  structify/types/wiki_connector_reference.py,sha256=jktQImwtOU3P7f3zEhy0PnVFeU6lWwrBdnmr7nPSSDo,1222
392
393
  structify/types/wiki_create_params.py,sha256=wUyt-E2oh2GX-3tOKFDyJut9dkbHM6db2ZUGIh5aisA,334
393
- structify/types/wiki_create_response.py,sha256=9orww-rrlX6Zo-s5XwjE-BnnegupLPjxp3Zqt5twZWc,332
394
- structify/types/wiki_list_response.py,sha256=3cy30Y1gBEwAuB62oDhPElgl3u3l_PIT2B80v7tFmYY,480
395
- structify/types/wiki_page_with_references.py,sha256=-miBnm2uYg3nucEaWK2gGcd8s4K_r9AywwHAUZrEgPQ,472
394
+ structify/types/wiki_list_response.py,sha256=DcHNchfsr_rDzkSQ6QM7zTCyBdtS7Ztq_0l3f32mV0M,262
395
+ structify/types/wiki_page.py,sha256=o2qw0fXEAaiXlOperWkvgpZGvIy_BS9RUdHd4n9fivk,312
396
+ structify/types/wiki_page_with_references.py,sha256=aEd9DEVQBJlOt97RW8qfXSn86a091wecQ5xPLsiP5hE,330
396
397
  structify/types/wiki_update_params.py,sha256=a44DcH_jAgtjJ0C73CmBvSqPekITPWMCJSe4Jip0rMM,398
397
- structify/types/wiki_update_response.py,sha256=nhyZEDGz_Mvr3FQMxNDF5Z07TE82Gcj0FLWwZE87tsQ,332
398
398
  structify/types/workflow_dag.py,sha256=rgyIEaVDhEQNR_P-miSrt6N2YjjAJDku2XbkXEkFxbM,829
399
399
  structify/types/workflow_node_execution_status.py,sha256=YXJLd-P4SGdu_IsJjyO44IRYoO4Bm0zEIjUhCSy_HFY,316
400
400
  structify/types/workflow_node_log.py,sha256=I3VRmr9hE3yYLbBZ9zJ1JnF_JPi153gzuZeDhDwkvRI,311
401
- structify/types/workflow_run_params.py,sha256=eYW64PomqPjLbAAuE7NpChEAFZBAh6rAClpSCYS9NGs,328
401
+ structify/types/workflow_run_params.py,sha256=yJhzDhfL2_5SLX7No6dhBBE_7McOhBjP919pKwyXwoo,393
402
402
  structify/types/workflow_schedule_create_params.py,sha256=2OZKy4ByS6LvsI99JiqqDMvlwlRI5pYoavevIzaEsgE,401
403
403
  structify/types/workflow_schedule_get_all_response.py,sha256=uUrte1Rh2l7-zuv2zaqatQ9YePB-bBBGqAJgM_wn2PQ,327
404
404
  structify/types/workflow_schedule_get_sessions_params.py,sha256=ukfQvSOzQyCQXvMu4Lwpy_MzpZ33V-6BsO9Z6z0KEzM,311
@@ -407,13 +407,13 @@ structify/types/workflow_schedule_pause_params.py,sha256=BvVMvxYjjIAsMDWWPnO2Ea0
407
407
  structify/types/workflow_schedule_update_params.py,sha256=Yuv_g631os89OlBPRyNvdh10iX8qfmEiSyqtzjo_vpA,419
408
408
  structify/types/workflow_session.py,sha256=TowRK1sUm0sFlN2DTV6wAnFkFFl3U70svD8V2JnCdHA,622
409
409
  structify/types/workflow_session_edge.py,sha256=GDlkWnOwnArC80Q1e04FfBkREOvh5HSs7Ij4K2rNR1Q,334
410
- structify/types/workflow_session_node.py,sha256=dSC6uG4Rhf7vo5hXVsuOfPBAjPj26bQNEy_FGUKAqkE,1159
410
+ structify/types/workflow_session_node.py,sha256=boj6HlUMVFxTqItMINCB3TnqdfYTXUzO0qEyLppfDwg,1186
411
411
  structify/types/workflow_stop_params.py,sha256=DLTGDSENmcdNQoV_LnsL0lvf3i3NtupkpiBGBpZakUs,298
412
412
  structify/types/admin/__init__.py,sha256=nXPN4Q3xY3UQU9c6bmfep1li_pnj9j9N8HMSBgGXfbU,3802
413
413
  structify/types/admin/admin_dataset_return.py,sha256=hRSCIBTiaCb1O1lcxsKyxnzGiYuIUEvnMxXkNbyj4_U,495
414
414
  structify/types/admin/admin_delete_jobs_response.py,sha256=c3IO7bCqAoEN9PHYM88gO0JT0e6hCaHyIBtxC84Tw38,225
415
415
  structify/types/admin/admin_list_jobs_response.py,sha256=27IoyuBSaBJPnSSyiZt3q5dHfeyBzrGtnq7nGvJcapM,4867
416
- structify/types/admin/admin_sandbox.py,sha256=Wn1TwugdP-eF2usCaTivYxwSB5OXI6gfXGg8XKROstk,761
416
+ structify/types/admin/admin_sandbox.py,sha256=09l7jdLalqFo9Su30kGeLINZ8Onx9SWBdWtDUTZpEsk,738
417
417
  structify/types/admin/admin_teams_list_response.py,sha256=FDrXxx3dQKuHuLfByYzaS5EzZYkZAtyJH7E7t6UoUX4,1167
418
418
  structify/types/admin/cancel_subscription_response.py,sha256=ph43hCKHtpjp2eSV9X9eitJA-mpnrRdjwe8KxPLJdKY,246
419
419
  structify/types/admin/chat_template_create_params.py,sha256=GCP3Uhb1_wPfaC4iFkQF2oTualQhEUAajblKymgsQuc,459
@@ -499,7 +499,7 @@ structify/types/user/stripe_create_portal_session_params.py,sha256=5AYRC8z_SlKmd
499
499
  structify/types/user/stripe_create_session_params.py,sha256=DFcNLNzEWeupkGQ9J5PafsuL_bIU9cLEIhAmFPsRlfo,387
500
500
  structify/types/user/stripe_create_subscription_params.py,sha256=d8HfiC94gJbG-cC_WvBz6xYCvxKJO_EP2yyVmVvufrU,424
501
501
  structify/types/user/subscription_plan.py,sha256=qKJMM-zPpYolYC1DlypOwPpxlyJBLkQqFK_0VpwktJs,222
502
- structifyai-1.180.0.dist-info/METADATA,sha256=NSQ4LhG54Fu6IpiUXqzd-xIm3yuSIZWbMbJo1GDg1aM,16399
503
- structifyai-1.180.0.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
504
- structifyai-1.180.0.dist-info/licenses/LICENSE,sha256=9CwgrmGz3rZSTT-KqGc1gua-7g8B4ThTgMtUgPALh5c,11339
505
- structifyai-1.180.0.dist-info/RECORD,,
502
+ structifyai-1.182.0.dist-info/METADATA,sha256=OUt8pCxjTpI633M1ELpNKm4_MjaIGJo2f6aqV6dchTk,16399
503
+ structifyai-1.182.0.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
504
+ structifyai-1.182.0.dist-info/licenses/LICENSE,sha256=9CwgrmGz3rZSTT-KqGc1gua-7g8B4ThTgMtUgPALh5c,11339
505
+ structifyai-1.182.0.dist-info/RECORD,,
@@ -1,99 +0,0 @@
1
- # External services namespace for Structify Python client
2
-
3
- from __future__ import annotations
4
-
5
- from typing import Any, Dict, List, cast
6
-
7
- import polars as pl
8
-
9
- from .._base_client import make_request_options
10
- from .whitelabel_service import WhitelabelServiceResource, whitelabel_method
11
-
12
- __all__ = ["ExternalResource"]
13
-
14
-
15
- class ExternalServiceResource(WhitelabelServiceResource):
16
- def __init__(self, client: Any, service_name: str) -> None:
17
- super().__init__(client)
18
- self._service_name = service_name
19
-
20
- def __getattr__(self, name: str) -> Any:
21
- if name.startswith("_"):
22
- raise AttributeError(name)
23
-
24
- def method(**kwargs: Any) -> Any:
25
- return self._post(
26
- f"/external/{self._service_name}/{name}",
27
- body=kwargs,
28
- cast_to=object,
29
- options=make_request_options(),
30
- )
31
-
32
- return method
33
-
34
-
35
- class ExternalResource(WhitelabelServiceResource):
36
- """
37
- Container for all external/whitelabel services.
38
-
39
- This provides a namespace for external services that are
40
- separate from the core Structify functionality.
41
- """
42
-
43
- @property
44
- def news(self) -> ExternalServiceResource:
45
- return ExternalServiceResource(self._client, "news")
46
-
47
- @property
48
- def people(self) -> ExternalServiceResource:
49
- return ExternalServiceResource(self._client, "people")
50
-
51
- @property
52
- def search_api(self) -> ExternalServiceResource:
53
- return ExternalServiceResource(self._client, "search_api")
54
-
55
- @whitelabel_method("/external/search")
56
- def search(
57
- self,
58
- *,
59
- df: pl.DataFrame,
60
- query_column: str = "query",
61
- num_results: int = 10,
62
- banned_domains: List[str] | None = None,
63
- ) -> pl.DataFrame:
64
- """
65
- Search for information using external search service.
66
-
67
- Args:
68
- df: DataFrame containing search queries
69
- query_column: Name of the column containing search queries (default: "query")
70
- num_results: Number of results to return per query (default: 10)
71
- banned_domains: List of domains to exclude from results (optional)
72
-
73
- Returns:
74
- DataFrame with search results, including a 'query' column to track which search produced each result
75
- """
76
- # Extract unique queries from the DataFrame
77
- queries = df[query_column].unique().to_list()
78
-
79
- # Return the parameters for the whitelabel decorator to process
80
- return {"queries": queries, "num_results": num_results, "banned_domains": banned_domains or []} # type: ignore[return-value]
81
-
82
- def _post_process_search(self, response: Any, queries: List[str]) -> pl.DataFrame: # noqa: ARG002
83
- """Post-process search results into DataFrame format."""
84
- results: List[Dict[str, Any]] = []
85
-
86
- if isinstance(response, list):
87
- # If response is already a list, it's the processed results
88
- results = cast(List[Dict[str, Any]], response)
89
- elif isinstance(response, dict) and "results" in response:
90
- # If response is wrapped in a results key
91
- results = cast(List[Dict[str, Any]], response["results"])
92
-
93
- # Convert to DataFrame with proper schema
94
- if results:
95
- return pl.DataFrame(
96
- results, schema={"query": pl.Utf8, "url": pl.Utf8, "title": pl.Utf8, "description": pl.Utf8}
97
- )
98
- else:
99
- return pl.DataFrame(schema={"query": pl.Utf8, "url": pl.Utf8, "title": pl.Utf8, "description": pl.Utf8})
@@ -1,290 +0,0 @@
1
- # Dynamic proxy for adding DataFrame batch processing to all external endpoints
2
-
3
- from __future__ import annotations
4
-
5
- import re
6
- from typing import Any, Dict, List, Callable, Optional
7
- from dataclasses import field, dataclass
8
- from concurrent.futures import Future, ThreadPoolExecutor
9
-
10
- import polars as pl
11
- from pydantic import BaseModel
12
-
13
- from .external import ExternalResource
14
-
15
- __all__ = ["ServicesProxy"]
16
-
17
-
18
- @dataclass
19
- class EndpointConfig:
20
- """Configuration for how to process API responses into DataFrames"""
21
- expand_path: Optional[str] = None # Path to list to expand (e.g., 'organic_results')
22
- properties: List[str] = field(default_factory=lambda: []) # Properties to extract (relative to expanded items)
23
-
24
-
25
- # Configuration for each endpoint - how to transform responses into clean DataFrames
26
- ENDPOINT_CONFIGS = {
27
- # News endpoints
28
- 'news.top_headlines': EndpointConfig(
29
- expand_path='articles',
30
- properties=['title', 'url', 'content', 'publishedAt', 'source.name', 'author']
31
- ),
32
- 'news.everything': EndpointConfig(
33
- expand_path='articles',
34
- properties=['title', 'url', 'content', 'publishedAt', 'source.name', 'author']
35
- ),
36
- 'news.sources': EndpointConfig(
37
- expand_path='sources',
38
- properties=['id', 'name', 'description', 'url', 'category', 'country', 'language']
39
- ),
40
-
41
- # Search API endpoints
42
- 'search_api.google_search': EndpointConfig(
43
- expand_path='organic_results',
44
- properties=['link', 'title', 'snippet', 'display_link']
45
- ),
46
- 'search_api.google_maps_search': EndpointConfig(
47
- # Direct list response - no expand_path needed
48
- properties=['name', 'address', 'rating', 'place_id', 'types']
49
- ),
50
- 'search_api.google_maps_place_details': EndpointConfig(
51
- properties=['name', 'formatted_address', 'rating', 'user_ratings_total', 'price_level', 'website']
52
- ),
53
- 'search_api.google_maps_place_reviews': EndpointConfig(
54
- expand_path='reviews',
55
- properties=['author_name', 'rating', 'text', 'time', 'relative_time_description']
56
- ),
57
- 'search_api.google_maps_place_photos': EndpointConfig(
58
- expand_path='photos',
59
- properties=['photo_reference', 'height', 'width', 'html_attributions']
60
- ),
61
- 'search_api.google_flights_search': EndpointConfig(
62
- expand_path='flights',
63
- properties=['price', 'departure_time', 'arrival_time', 'airline', 'flight_number', 'duration']
64
- ),
65
- 'search_api.google_flights_calendar': EndpointConfig(
66
- expand_path='calendar_results',
67
- properties=['date', 'price', 'departure_time', 'arrival_time']
68
- ),
69
- 'search_api.google_flights_location_search': EndpointConfig(
70
- expand_path='locations',
71
- properties=['name', 'code', 'city', 'country']
72
- ),
73
- 'search_api.google_scholar_search': EndpointConfig(
74
- expand_path='organic_results',
75
- properties=['title', 'link', 'snippet', 'publication_info', 'citation_count']
76
- ),
77
- 'search_api.google_scholar_author_search': EndpointConfig(
78
- expand_path='authors',
79
- properties=['name', 'affiliation', 'citations', 'h_index', 'i10_index']
80
- ),
81
- 'search_api.google_scholar_citations': EndpointConfig(
82
- expand_path='citations',
83
- properties=['title', 'authors', 'publication', 'year', 'citation_count']
84
- ),
85
- 'search_api.location_search': EndpointConfig(
86
- expand_path='locations',
87
- properties=['name', 'display_name', 'lat', 'lon', 'country', 'state']
88
- ),
89
-
90
- # People endpoints
91
- 'people.people_search': EndpointConfig(
92
- expand_path='people',
93
- properties=['name', 'title', 'company', 'location', 'linkedin_url']
94
- ),
95
- 'people.people_match': EndpointConfig(
96
- expand_path='matches',
97
- properties=['name', 'confidence_score', 'linkedin_url', 'company', 'title']
98
- ),
99
- 'people.companies_search': EndpointConfig(
100
- expand_path='companies',
101
- properties=['name', 'domain', 'industry', 'size', 'linkedin_url', 'description']
102
- ),
103
- 'people.organizations_enrich': EndpointConfig(
104
- properties=['name', 'domain', 'industry', 'employee_count', 'description', 'linkedin_url']
105
- ),
106
- 'people.organization_detail': EndpointConfig(
107
- properties=['name', 'domain', 'industry', 'employee_count', 'description', 'founded']
108
- ),
109
- 'people.organization_job_postings': EndpointConfig(
110
- expand_path='job_postings',
111
- properties=['title', 'company', 'location', 'description', 'posted_date', 'url']
112
- ),
113
- }
114
-
115
-
116
- class EndpointProxy:
117
- """
118
- Proxy for individual service endpoints (e.g., news, people, search_api).
119
-
120
- Intercepts method calls and automatically detects DataFrame inputs,
121
- processing each row as a parallel API call.
122
- """
123
-
124
- def __init__(self, service: Any):
125
- self._service = service
126
- self._client = getattr(service, '_client', None)
127
-
128
- def __getattr__(self, name: str) -> Any:
129
- # Get the original method/attribute
130
- original_attr = getattr(self._service, name)
131
-
132
- # If it's not callable, return as-is
133
- if not callable(original_attr):
134
- return original_attr
135
-
136
- # If it's a special method, return as-is
137
- if name.startswith('_') or name in ['with_raw_response', 'with_streaming_response']:
138
- return original_attr
139
-
140
- # Return a wrapped version that supports DataFrame batch processing
141
- def wrapped_method(*args: Any, **kwargs: Any) -> Any:
142
- # Check if first argument is a DataFrame
143
- if args and isinstance(args[0], pl.DataFrame):
144
- df = args[0]
145
- return self._batch_process_dataframe(name, df)
146
- else:
147
- # Regular method call - delegate to original
148
- return original_attr(*args, **kwargs)
149
-
150
- return wrapped_method
151
-
152
- def _batch_process_dataframe(self, method_name: str, df: pl.DataFrame) -> pl.DataFrame:
153
- """Process DataFrame rows as parallel API calls."""
154
- THREAD_POOL_SIZE = 20
155
-
156
- if df.is_empty():
157
- return df.clear()
158
-
159
- rows = df.to_dicts()
160
-
161
- # Get the original method once
162
- original_method = getattr(self._service, method_name)
163
-
164
- # Execute parallel requests
165
- with ThreadPoolExecutor(max_workers=THREAD_POOL_SIZE) as executor:
166
- futures: List[Future[Any]] = []
167
- for row in rows:
168
- future = executor.submit(self._execute_single_request, original_method, row)
169
- futures.append(future)
170
-
171
- # Process results using endpoint configuration
172
- all_results: List[Dict[str, Any]] = []
173
- for i, future in enumerate(futures):
174
- try:
175
- result = future.result()
176
- processed_rows = self._process_response(method_name, result, rows[i])
177
- all_results.extend(processed_rows)
178
- except Exception as e:
179
- # Add error row with query context
180
- error_row: Dict[str, Any] = {"error": str(e)}
181
- error_row.update({f"query_{k}": v for k, v in rows[i].items()})
182
- all_results.append(error_row)
183
-
184
- return pl.DataFrame(all_results) if all_results else pl.DataFrame()
185
-
186
- def _execute_single_request(self, original_method: Callable[..., Any], payload: Dict[str, Any]) -> Any:
187
- """Execute a single API request."""
188
- # Call the original method with the payload as keyword arguments
189
- return original_method(**payload)
190
-
191
- def _process_response(self, method_name: str, result: BaseModel, original_query_row: Dict[str, Any]) -> List[Dict[str, Any]]:
192
- """Process API response using endpoint configuration to create clean DataFrame rows."""
193
-
194
- # Build endpoint key (e.g., 'search_api.google_search')
195
- # Convert class name to resource name by removing 'Resource' suffix and converting to snake_case
196
- class_name = self._service.__class__.__name__
197
- resource_name = class_name.replace('Resource', '')
198
- # Convert from PascalCase to snake_case
199
- resource_name = re.sub(r'([A-Z]+)([A-Z][a-z])', r'\1_\2', resource_name)
200
- resource_name = re.sub(r'([a-z\d])([A-Z])', r'\1_\2', resource_name)
201
- resource_name = resource_name.lower()
202
- endpoint_key = f"{resource_name}.{method_name}"
203
-
204
- # Get configuration for this endpoint
205
- config = ENDPOINT_CONFIGS.get(endpoint_key, EndpointConfig())
206
-
207
- # Convert Pydantic model to dict
208
- data: Any = result.model_dump()
209
-
210
- # Determine what to iterate over
211
- items: List[Dict[str, Any]]
212
- if config.expand_path:
213
- # Extract list from the specified path
214
- extracted = self._get_by_path(data, config.expand_path)
215
- if not isinstance(extracted, list):
216
- raise ValueError(f"Expected list at path '{config.expand_path}', got {type(extracted).__name__}")
217
- items = extracted # type: ignore[assignment]
218
- elif isinstance(data, list):
219
- # Direct list response
220
- items = data # type: ignore[assignment]
221
- else:
222
- # Single dict response
223
- items = [data]
224
-
225
- # Extract properties from each item
226
- processed_rows: List[Dict[str, Any]] = []
227
- for item in items:
228
- if config.properties:
229
- # Extract only specified properties
230
- row: Dict[str, Any] = {}
231
- for prop_path in config.properties:
232
- value = self._get_by_path(item, prop_path)
233
- # Use last part of path as column name (e.g., 'source.name' -> 'name')
234
- col_name = prop_path.split('.')[-1]
235
- row[col_name] = value
236
- else:
237
- # No properties specified - use whole item
238
- row = item # type: ignore[assignment]
239
-
240
- # Add original query data with 'query_' prefix
241
- row.update({f"query_{k}": v for k, v in original_query_row.items()})
242
- processed_rows.append(row)
243
-
244
- return processed_rows
245
-
246
- def _get_by_path(self, data: Any, path: str) -> Any:
247
- """Get value from nested dict using dot notation (e.g., 'source.name')."""
248
- if not path:
249
- return data
250
-
251
- current = data
252
- for key in path.split('.'):
253
- if isinstance(current, dict):
254
- current = current.get(key) # type: ignore[union-attr]
255
- else:
256
- return None
257
- if current is None:
258
- return None
259
- return current # type: ignore[return-value]
260
-
261
-
262
-
263
- class ServicesProxy:
264
- """
265
- Proxy for the main ExternalResource that wraps all service endpoints
266
- with DataFrame batch processing capability.
267
- """
268
-
269
- def __init__(self, client: Any) -> None:
270
- self._client = client
271
- self._external_resource = ExternalResource(client)
272
-
273
- @property
274
- def news(self) -> EndpointProxy:
275
- """News API with DataFrame batch processing."""
276
- return EndpointProxy(self._external_resource.news)
277
-
278
- @property
279
- def people(self) -> EndpointProxy:
280
- """People/Apollo API with DataFrame batch processing."""
281
- return EndpointProxy(self._external_resource.people)
282
-
283
- @property
284
- def search_api(self) -> EndpointProxy:
285
- """Search API with DataFrame batch processing."""
286
- return EndpointProxy(self._external_resource.search_api)
287
-
288
- def __getattr__(self, name: str) -> Any:
289
- """Delegate any other attributes to the original external resource."""
290
- return getattr(self._external_resource, name)
@@ -1,13 +0,0 @@
1
- # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- from datetime import datetime
4
-
5
- from .._models import BaseModel
6
-
7
- __all__ = ["TeamsLinkCodeResponse"]
8
-
9
-
10
- class TeamsLinkCodeResponse(BaseModel):
11
- code: str
12
-
13
- expires_at: datetime
@@ -1,23 +0,0 @@
1
- # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- from .._models import BaseModel
4
-
5
- __all__ = ["WikiUpdateResponse"]
6
-
7
-
8
- class WikiUpdateResponse(BaseModel):
9
- id: str
10
-
11
- created_at: str
12
-
13
- markdown: str
14
-
15
- slug: str
16
-
17
- team_id: str
18
-
19
- title: str
20
-
21
- updated_at: str
22
-
23
- version: int