structifyai 1.158.0__py3-none-any.whl → 1.176.1__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 (364) hide show
  1. structify/_base_client.py +140 -11
  2. structify/_client.py +1116 -253
  3. structify/_models.py +16 -1
  4. structify/_streaming.py +12 -10
  5. structify/_types.py +12 -2
  6. structify/_version.py +1 -1
  7. structify/lib/__init__.py +5 -0
  8. structify/lib/cost_confirmation.py +63 -0
  9. structify/pagination.py +63 -1
  10. structify/resources/__init__.py +57 -27
  11. structify/resources/admin/__init__.py +26 -40
  12. structify/resources/admin/admin.py +39 -71
  13. structify/resources/admin/chat_templates.py +382 -0
  14. structify/resources/admin/jobs.py +76 -3
  15. structify/resources/admin/sandbox.py +184 -0
  16. structify/resources/admin/teams.py +88 -0
  17. structify/resources/admin/users.py +28 -238
  18. structify/resources/chat.py +232 -0
  19. structify/resources/connector_catalog/__init__.py +33 -0
  20. structify/resources/connector_catalog/admin.py +1510 -0
  21. structify/resources/connector_catalog/connector_catalog.py +394 -0
  22. structify/resources/connectors/__init__.py +33 -0
  23. structify/resources/{connectors.py → connectors/connectors.py} +1155 -325
  24. structify/resources/connectors/type_snippets.py +169 -0
  25. structify/resources/datasets/datasets.py +0 -4
  26. structify/resources/documents.py +1 -123
  27. structify/resources/external.py +35 -2
  28. structify/resources/jobs.py +19 -336
  29. structify/resources/nango.py +234 -0
  30. structify/resources/polars.py +225 -103
  31. structify/resources/sandbox.py +13 -110
  32. structify/resources/scrape.py +0 -16
  33. structify/resources/sessions.py +241 -153
  34. structify/resources/slack.py +1 -151
  35. structify/resources/structure.py +120 -48
  36. structify/resources/teams.py +96 -0
  37. structify/resources/user/__init__.py +14 -0
  38. structify/resources/user/api_keys.py +380 -0
  39. structify/resources/user/user.py +209 -2
  40. structify/resources/whitelabel.py +294 -187
  41. structify/resources/whitelabel_service.py +222 -0
  42. structify/resources/{report.py → wiki.py} +237 -210
  43. structify/resources/workflow_schedule.py +4 -5
  44. structify/types/__init__.py +67 -36
  45. structify/types/add_member_response.py +35 -4
  46. structify/types/admin/__init__.py +13 -88
  47. structify/types/admin/admin_dataset_return.py +6 -0
  48. structify/types/admin/{user_get_credits_response.py → admin_delete_jobs_response.py} +3 -3
  49. structify/types/admin/admin_list_jobs_response.py +35 -1
  50. structify/types/admin/admin_sandbox.py +38 -0
  51. structify/types/admin/chat_template_create_params.py +21 -0
  52. structify/types/admin/{human_llm_start_next_job_params.py → chat_template_list_params.py} +3 -3
  53. structify/types/admin/{human_llm_get_jobs_response.py → chat_template_list_response.py} +3 -3
  54. structify/types/admin/chat_template_update_params.py +22 -0
  55. structify/types/admin/{user_add_credits_response.py → expire_grants_response.py} +5 -3
  56. structify/types/admin/impersonate_response.py +17 -0
  57. structify/types/admin/{next_action_get_batched_training_data_params.py → job_delete_params.py} +2 -2
  58. structify/types/admin/{user_get_credits_params.py → sandbox_list_params.py} +4 -4
  59. structify/types/admin/sandbox_type.py +7 -0
  60. structify/types/admin/{user_set_credits_params.py → team_expire_grants_params.py} +4 -4
  61. structify/types/admin/user.py +16 -0
  62. structify/types/admin/user_create_params.py +1 -0
  63. structify/types/admin/{training_dataset_delete_params.py → user_impersonate_params.py} +3 -3
  64. structify/types/admin/user_list_response.py +14 -4
  65. structify/types/admin_grant_access_response.py +2 -0
  66. structify/types/{slack_user_mapping_response.py → admin_issue_found_response.py} +3 -5
  67. structify/types/chat_add_git_commit_response.py +2 -0
  68. structify/types/{admin/human_llm_get_next_step_params.py → chat_admin_issue_found_params.py} +4 -4
  69. structify/types/chat_create_session_params.py +7 -0
  70. structify/types/chat_dependency.py +17 -0
  71. structify/types/chat_event.py +51 -239
  72. structify/types/chat_get_git_commit_response.py +2 -0
  73. structify/types/chat_get_session_timeline_response.py +31 -1
  74. structify/types/{job_get_steps_response.py → chat_list_templates_response.py} +3 -3
  75. structify/types/chat_prompt.py +2 -0
  76. structify/types/chat_revert_to_commit_response.py +2 -0
  77. structify/types/chat_session.py +14 -0
  78. structify/types/chat_session_with_messages.py +33 -1
  79. structify/types/chat_template.py +31 -0
  80. structify/types/chat_update_session_params.py +2 -0
  81. structify/types/code_generate_code_params.py +7 -0
  82. structify/types/connector.py +16 -25
  83. structify/types/connector_auth_method.py +29 -0
  84. structify/types/connector_auth_method_with_fields.py +15 -0
  85. structify/types/connector_catalog/__init__.py +32 -0
  86. structify/types/connector_catalog/admin_batch_create_credential_fields_params.py +14 -0
  87. structify/types/connector_catalog/admin_batch_create_credential_fields_response.py +10 -0
  88. structify/types/connector_catalog/admin_batch_create_scopes_params.py +14 -0
  89. structify/types/connector_catalog/admin_create_auth_method_params.py +22 -0
  90. structify/types/connector_catalog/admin_create_catalog_params.py +22 -0
  91. structify/types/connector_catalog/admin_create_credential_field_params.py +28 -0
  92. structify/types/connector_catalog/admin_create_scope_params.py +19 -0
  93. structify/types/connector_catalog/admin_list_nango_pending_response.py +10 -0
  94. structify/types/{admin/training_dataset_get_datum_info_params.py → connector_catalog/admin_list_scopes_params.py} +3 -3
  95. structify/types/connector_catalog/admin_update_auth_method_params.py +16 -0
  96. structify/types/connector_catalog/admin_update_catalog_params.py +20 -0
  97. structify/types/connector_catalog/admin_update_credential_field_params.py +26 -0
  98. structify/types/connector_catalog/admin_update_scope_params.py +18 -0
  99. structify/types/connector_catalog/admin_upload_logo_params.py +13 -0
  100. structify/types/connector_catalog/batch_create_scopes_response.py +12 -0
  101. structify/types/connector_catalog/connector_auth_method_scope.py +25 -0
  102. structify/types/connector_catalog/connector_catalog.py +26 -0
  103. structify/types/connector_catalog/create_credential_field_request_param.py +28 -0
  104. structify/types/connector_catalog/create_scope_request_param.py +19 -0
  105. structify/types/connector_catalog/list_scopes_response.py +12 -0
  106. structify/types/connector_catalog/pending_nango_integration.py +17 -0
  107. structify/types/{admin/user_set_credits_response.py → connector_catalog/upload_logo_response.py} +3 -3
  108. structify/types/connector_catalog_list_params.py +20 -0
  109. structify/types/connector_catalog_list_response.py +22 -0
  110. structify/types/connector_catalog_with_methods.py +15 -0
  111. structify/types/connector_category.py +7 -0
  112. structify/types/connector_create_params.py +11 -25
  113. structify/types/connector_credential_field.py +34 -0
  114. structify/types/connector_delete_schema_object_params.py +35 -0
  115. structify/types/connector_explore_params.py +19 -0
  116. structify/types/connector_explorer_chat.py +9 -84
  117. structify/types/connector_get_clarification_requests_response.py +36 -0
  118. structify/types/connector_get_response.py +2 -0
  119. structify/types/connector_list_with_snippets_params.py +12 -0
  120. structify/types/connector_list_with_snippets_response.py +10 -0
  121. structify/types/connector_search_tables_params.py +15 -0
  122. structify/types/connector_search_tables_response.py +160 -0
  123. structify/types/connector_store_response.py +21 -0
  124. structify/types/connector_summaries_params.py +15 -0
  125. structify/types/connector_summaries_response.py +10 -0
  126. structify/types/connector_summary.py +16 -0
  127. structify/types/connector_table_info.py +15 -0
  128. structify/types/connector_update_column_params.py +12 -0
  129. structify/types/connector_update_params.py +4 -25
  130. structify/types/connector_update_table_params.py +14 -0
  131. structify/types/connector_with_secrets.py +2 -0
  132. structify/types/connector_with_snippets.py +11 -0
  133. structify/types/connectors/__init__.py +6 -0
  134. structify/types/connectors/snippet.py +20 -0
  135. structify/types/connectors/type_snippet_upsert_params.py +12 -0
  136. structify/types/create_chat_session_response.py +2 -0
  137. structify/types/dataset_create_params.py +0 -2
  138. structify/types/dataset_descriptor.py +6 -0
  139. structify/types/dataset_descriptor_param.py +6 -0
  140. structify/types/dataset_get_response.py +6 -0
  141. structify/types/dataset_list_response.py +6 -0
  142. structify/types/dataset_view_table_response.py +3 -1
  143. structify/types/delete_chat_session_response.py +2 -0
  144. structify/types/delete_schema_object_request_param.py +35 -0
  145. structify/types/delete_schema_object_response.py +13 -0
  146. structify/types/edge_spec_param.py +13 -0
  147. structify/types/entity_get_source_entities_response.py +0 -2
  148. structify/types/entity_list_jobs_response.py +3 -3
  149. structify/types/entity_view_response.py +0 -2
  150. structify/types/estimate_cost_response.py +9 -0
  151. structify/types/exploration_phase_id.py +79 -0
  152. structify/types/finalize_dag_response.py +11 -0
  153. structify/types/get_chat_session_response.py +14 -6
  154. structify/types/get_dependencies_response.py +15 -0
  155. structify/types/get_job_events_response.py +20 -0
  156. structify/types/get_node_response.py +10 -0
  157. structify/types/job_cancel_response.py +3 -3
  158. structify/types/job_event_body.py +108 -1
  159. structify/types/job_get_source_entities_response.py +0 -2
  160. structify/types/job_list_params.py +1 -1
  161. structify/types/job_list_response.py +35 -1
  162. structify/types/knowledge_graph.py +6 -0
  163. structify/types/knowledge_graph_param.py +6 -0
  164. structify/types/list_chat_sessions_response.py +2 -0
  165. structify/types/list_collaborators_response.py +4 -0
  166. structify/types/list_tables_response.py +12 -0
  167. structify/types/llm_information_store.py +62 -28
  168. structify/types/merge_config.py +2 -0
  169. structify/types/merge_config_param.py +2 -0
  170. structify/types/message.py +2 -0
  171. structify/types/nango_create_session_params.py +21 -0
  172. structify/types/nango_create_session_response.py +15 -0
  173. structify/types/nango_list_integrations_response.py +28 -0
  174. structify/types/{session_create_node_params.py → node_spec_param.py} +4 -4
  175. structify/types/refresh_session_response.py +15 -0
  176. structify/types/sandbox.py +8 -2
  177. structify/types/sandbox_get_params.py +2 -1
  178. structify/types/scrape_list_params.py +1 -22
  179. structify/types/scrape_list_response.py +2 -0
  180. structify/types/scrape_scrape_params.py +1 -14
  181. structify/types/scrape_scrape_response.py +2 -0
  182. structify/types/select_team_response.py +3 -1
  183. structify/types/{connector_approve_version_params.py → session_confirm_node_params.py} +3 -3
  184. structify/types/session_finalize_dag_params.py +20 -0
  185. structify/types/session_get_events_response.py +2 -0
  186. structify/types/session_request_confirmation_params.py +13 -0
  187. structify/types/session_upload_node_output_data_params.py +3 -0
  188. structify/types/slack_event_payload_param.py +18 -2
  189. structify/types/slack_events_params.py +18 -2
  190. structify/types/source_list_response.py +0 -2
  191. structify/types/structure_enhance_property_params.py +2 -17
  192. structify/types/structure_enhance_relationship_params.py +2 -17
  193. structify/types/structure_find_relationship_params.py +2 -18
  194. structify/types/structure_pdf_params.py +22 -0
  195. structify/types/structure_pdf_response.py +11 -0
  196. structify/types/structure_run_async_params.py +10 -17
  197. structify/types/table.py +2 -0
  198. structify/types/table_param.py +2 -0
  199. structify/types/team.py +14 -0
  200. structify/types/{admin/training_dataset_remove_datum_params.py → team_create_link_code_params.py} +3 -3
  201. structify/types/team_update_params.py +10 -0
  202. structify/types/team_wiki_page.py +28 -0
  203. structify/types/teams_link_code_response.py +13 -0
  204. structify/types/token_response.py +6 -2
  205. structify/types/tool_invocation.py +468 -0
  206. structify/types/tool_result.py +99 -0
  207. structify/types/update_table_response.py +46 -0
  208. structify/types/usage_group_key.py +14 -1
  209. structify/types/user/__init__.py +4 -0
  210. structify/types/{admin/training_dataset_size_params.py → user/api_key_create_params.py} +5 -5
  211. structify/types/user/api_key_info.py +24 -0
  212. structify/types/user/create_api_key_response.py +12 -0
  213. structify/types/user/list_api_keys_response.py +12 -0
  214. structify/types/user_enrich_params.py +11 -0
  215. structify/types/user_info.py +22 -0
  216. structify/types/user_refresh_params.py +13 -0
  217. structify/types/user_transactions_response.py +5 -5
  218. structify/types/user_update_params.py +32 -12
  219. structify/types/user_usage_response.py +0 -2
  220. structify/types/wiki_connector_reference.py +63 -0
  221. structify/types/wiki_create_params.py +16 -0
  222. structify/types/{admin/training_dataset_list_response.py → wiki_list_response.py} +4 -2
  223. structify/types/wiki_page_with_references.py +12 -0
  224. structify/types/wiki_update_params.py +16 -0
  225. structify/types/workflow_dag.py +2 -0
  226. structify/types/workflow_node_execution_status.py +3 -1
  227. structify/types/workflow_schedule_info.py +2 -2
  228. structify/types/workflow_session_node.py +10 -0
  229. {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/METADATA +67 -4
  230. structifyai-1.176.1.dist-info/RECORD +496 -0
  231. {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/licenses/LICENSE +1 -1
  232. structify/resources/admin/human_llm.py +0 -819
  233. structify/resources/admin/next_action.py +0 -656
  234. structify/resources/admin/training_datasets.py +0 -2028
  235. structify/resources/external/__init__.py +0 -61
  236. structify/resources/external/external.py +0 -166
  237. structify/resources/external/news.py +0 -519
  238. structify/resources/external/people.py +0 -998
  239. structify/resources/external/search_api.py +0 -1525
  240. structify/types/active_version_data.py +0 -21
  241. structify/types/active_version_response.py +0 -13
  242. structify/types/admin/action_training_data_entry.py +0 -219
  243. structify/types/admin/action_training_data_response.py +0 -12
  244. structify/types/admin/datum_status.py +0 -19
  245. structify/types/admin/delete_action_training_data_response.py +0 -9
  246. structify/types/admin/human_llm_add_search_for_job_params.py +0 -13
  247. structify/types/admin/human_llm_add_to_dataset_params.py +0 -186
  248. structify/types/admin/human_llm_finish_job_params.py +0 -13
  249. structify/types/admin/human_llm_get_jobs_params.py +0 -12
  250. structify/types/admin/human_llm_get_next_step_response.py +0 -196
  251. structify/types/admin/human_llm_job.py +0 -73
  252. structify/types/admin/human_llm_prelabel_step_response.py +0 -184
  253. structify/types/admin/human_llm_update_step_params.py +0 -186
  254. structify/types/admin/labeling_stats.py +0 -24
  255. structify/types/admin/next_action_add_training_datum_params.py +0 -203
  256. structify/types/admin/next_action_delete_training_data_params.py +0 -12
  257. structify/types/admin/next_action_get_training_data_params.py +0 -25
  258. structify/types/admin/next_action_get_training_datum_params.py +0 -12
  259. structify/types/admin/next_action_label_training_datum_params.py +0 -90
  260. structify/types/admin/step_choices.py +0 -32
  261. structify/types/admin/training_dataset_add_datum_params.py +0 -13
  262. structify/types/admin/training_dataset_add_params.py +0 -12
  263. structify/types/admin/training_dataset_download_datum_params.py +0 -13
  264. structify/types/admin/training_dataset_get_labeller_stats_params.py +0 -23
  265. structify/types/admin/training_dataset_get_labeller_stats_response.py +0 -10
  266. structify/types/admin/training_dataset_get_next_for_labeling_params.py +0 -15
  267. structify/types/admin/training_dataset_get_next_for_qa_params.py +0 -18
  268. structify/types/admin/training_dataset_get_next_suspicious_params.py +0 -23
  269. structify/types/admin/training_dataset_label_datum_params.py +0 -188
  270. structify/types/admin/training_dataset_list_datums_params.py +0 -17
  271. structify/types/admin/training_dataset_list_datums_response.py +0 -33
  272. structify/types/admin/training_dataset_mark_datum_suspicious_params.py +0 -19
  273. structify/types/admin/training_dataset_size_response.py +0 -37
  274. structify/types/admin/training_dataset_suspicious_count_params.py +0 -23
  275. structify/types/admin/training_dataset_suspicious_count_response.py +0 -9
  276. structify/types/admin/training_dataset_switch_dataset_params.py +0 -13
  277. structify/types/admin/training_dataset_update_datum_status_params.py +0 -18
  278. structify/types/admin/training_dataset_upload_labeled_step_params.py +0 -15
  279. structify/types/admin/training_dataset_verify_datum_params.py +0 -17
  280. structify/types/admin/training_datum_response.py +0 -405
  281. structify/types/admin/user_add_credits_params.py +0 -18
  282. structify/types/chat_prompt_param.py +0 -255
  283. structify/types/connector_column_descriptor.py +0 -21
  284. structify/types/connector_relational_database_descriptor.py +0 -13
  285. structify/types/connector_table_descriptor.py +0 -22
  286. structify/types/document_structure_params.py +0 -21
  287. structify/types/document_structure_response.py +0 -8
  288. structify/types/execution_step.py +0 -198
  289. structify/types/external/__init__.py +0 -96
  290. structify/types/external/companies_search_response.py +0 -28
  291. structify/types/external/company_search_result.py +0 -69
  292. structify/types/external/enriched_organization.py +0 -69
  293. structify/types/external/everything_response.py +0 -19
  294. structify/types/external/google_maps_result.py +0 -38
  295. structify/types/external/google_search_response.py +0 -19
  296. structify/types/external/google_search_result.py +0 -21
  297. structify/types/external/job_posting.py +0 -54
  298. structify/types/external/job_postings_response.py +0 -19
  299. structify/types/external/location_coordinates.py +0 -13
  300. structify/types/external/location_response.py +0 -16
  301. structify/types/external/location_result.py +0 -24
  302. structify/types/external/news_article.py +0 -33
  303. structify/types/external/news_everything_params.py +0 -45
  304. structify/types/external/news_source.py +0 -15
  305. structify/types/external/news_source_detail.py +0 -28
  306. structify/types/external/news_sources_params.py +0 -19
  307. structify/types/external/news_top_headlines_params.py +0 -28
  308. structify/types/external/organization_detail.py +0 -87
  309. structify/types/external/people_match_response.py +0 -18
  310. structify/types/external/people_search_response.py +0 -28
  311. structify/types/external/person_companies_search_params.py +0 -63
  312. structify/types/external/person_match.py +0 -60
  313. structify/types/external/person_organization_job_postings_params.py +0 -16
  314. structify/types/external/person_organizations_enrich_params.py +0 -16
  315. structify/types/external/person_people_match_params.py +0 -49
  316. structify/types/external/person_people_search_params.py +0 -57
  317. structify/types/external/person_search_result.py +0 -48
  318. structify/types/external/search_api_google_flights_calendar_params.py +0 -28
  319. structify/types/external/search_api_google_flights_calendar_response.py +0 -8
  320. structify/types/external/search_api_google_flights_location_search_params.py +0 -16
  321. structify/types/external/search_api_google_flights_location_search_response.py +0 -8
  322. structify/types/external/search_api_google_flights_search_params.py +0 -43
  323. structify/types/external/search_api_google_flights_search_response.py +0 -8
  324. structify/types/external/search_api_google_maps_place_details_params.py +0 -16
  325. structify/types/external/search_api_google_maps_place_details_response.py +0 -8
  326. structify/types/external/search_api_google_maps_place_photos_params.py +0 -16
  327. structify/types/external/search_api_google_maps_place_photos_response.py +0 -8
  328. structify/types/external/search_api_google_maps_place_reviews_params.py +0 -19
  329. structify/types/external/search_api_google_maps_place_reviews_response.py +0 -8
  330. structify/types/external/search_api_google_maps_search_params.py +0 -22
  331. structify/types/external/search_api_google_maps_search_response.py +0 -10
  332. structify/types/external/search_api_google_scholar_author_search_params.py +0 -22
  333. structify/types/external/search_api_google_scholar_author_search_response.py +0 -8
  334. structify/types/external/search_api_google_scholar_citations_params.py +0 -22
  335. structify/types/external/search_api_google_scholar_citations_response.py +0 -8
  336. structify/types/external/search_api_google_scholar_search_params.py +0 -28
  337. structify/types/external/search_api_google_scholar_search_response.py +0 -8
  338. structify/types/external/search_api_google_search_params.py +0 -25
  339. structify/types/external/search_api_location_search_params.py +0 -22
  340. structify/types/external/sources_response.py +0 -16
  341. structify/types/external/top_headlines_response.py +0 -19
  342. structify/types/job_delete_response.py +0 -7
  343. structify/types/job_get_response.py +0 -62
  344. structify/types/job_get_step_graph_response.py +0 -233
  345. structify/types/job_get_step_response.py +0 -196
  346. structify/types/message_param.py +0 -35
  347. structify/types/pending_version_response.py +0 -21
  348. structify/types/report_missing_params.py +0 -18
  349. structify/types/report_missing_response.py +0 -7
  350. structify/types/report_relationship_params.py +0 -18
  351. structify/types/report_relationship_response.py +0 -7
  352. structify/types/report_step_params.py +0 -15
  353. structify/types/report_step_response.py +0 -7
  354. structify/types/report_wrong_params.py +0 -18
  355. structify/types/report_wrong_response.py +0 -7
  356. structify/types/sandbox_create_params.py +0 -20
  357. structify/types/session_create_edge_params.py +0 -13
  358. structify/types/slack_connection_status.py +0 -15
  359. structify/types/slack_user_mapping_params.py +0 -18
  360. structify/types/tool_metadata_param.py +0 -17
  361. structify/types/user_team.py +0 -35
  362. structify/types/workflow_schedule_get_response.py +0 -10
  363. structifyai-1.158.0.dist-info/RECORD +0 -530
  364. {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/WHEEL +0 -0
@@ -1,998 +0,0 @@
1
- # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- from __future__ import annotations
4
-
5
- from typing import Optional
6
-
7
- import httpx
8
-
9
- from ..._types import Body, Omit, Query, Headers, NotGiven, SequenceNotStr, omit, not_given
10
- from ..._utils import maybe_transform, async_maybe_transform
11
- from ..._compat import cached_property
12
- from ..._resource import SyncAPIResource, AsyncAPIResource
13
- from ..._response import (
14
- to_raw_response_wrapper,
15
- to_streamed_response_wrapper,
16
- async_to_raw_response_wrapper,
17
- async_to_streamed_response_wrapper,
18
- )
19
- from ..._base_client import make_request_options
20
- from ...types.external import (
21
- person_people_match_params,
22
- person_people_search_params,
23
- person_companies_search_params,
24
- person_organizations_enrich_params,
25
- person_organization_job_postings_params,
26
- )
27
- from ...types.external.organization_detail import OrganizationDetail
28
- from ...types.external.enriched_organization import EnrichedOrganization
29
- from ...types.external.job_postings_response import JobPostingsResponse
30
- from ...types.external.people_match_response import PeopleMatchResponse
31
- from ...types.external.people_search_response import PeopleSearchResponse
32
- from ...types.external.companies_search_response import CompaniesSearchResponse
33
-
34
- __all__ = ["PeopleResource", "AsyncPeopleResource"]
35
-
36
-
37
- class PeopleResource(SyncAPIResource):
38
- @cached_property
39
- def with_raw_response(self) -> PeopleResourceWithRawResponse:
40
- """
41
- This property can be used as a prefix for any HTTP method call to return
42
- the raw response object instead of the parsed content.
43
-
44
- For more information, see https://www.github.com/StructifyAI/structify-python#accessing-raw-response-data-eg-headers
45
- """
46
- return PeopleResourceWithRawResponse(self)
47
-
48
- @cached_property
49
- def with_streaming_response(self) -> PeopleResourceWithStreamingResponse:
50
- """
51
- An alternative to `.with_raw_response` that doesn't eagerly read the response body.
52
-
53
- For more information, see https://www.github.com/StructifyAI/structify-python#with_streaming_response
54
- """
55
- return PeopleResourceWithStreamingResponse(self)
56
-
57
- def companies_search(
58
- self,
59
- *,
60
- organization_department_headcount_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
61
- organization_founded_year_max: Optional[int] | Omit = omit,
62
- organization_founded_year_min: Optional[int] | Omit = omit,
63
- organization_locations: Optional[SequenceNotStr[str]] | Omit = omit,
64
- organization_naics_codes: Optional[SequenceNotStr[str]] | Omit = omit,
65
- organization_not_ids: Optional[SequenceNotStr[str]] | Omit = omit,
66
- organization_num_employees_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
67
- organization_revenue_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
68
- organization_sic_codes: Optional[SequenceNotStr[str]] | Omit = omit,
69
- organization_technologies: Optional[SequenceNotStr[str]] | Omit = omit,
70
- page: Optional[int] | Omit = omit,
71
- per_page: Optional[int] | Omit = omit,
72
- q_keywords: Optional[str] | Omit = omit,
73
- q_organization_industry_tag_ids: Optional[SequenceNotStr[str]] | Omit = omit,
74
- q_organization_keyword_tags: Optional[SequenceNotStr[str]] | Omit = omit,
75
- sort_ascending: Optional[bool] | Omit = omit,
76
- sort_by_field: Optional[str] | Omit = omit,
77
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
78
- # The extra values given here take precedence over values defined on the client or passed to this method.
79
- extra_headers: Headers | None = None,
80
- extra_query: Query | None = None,
81
- extra_body: Body | None = None,
82
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
83
- ) -> CompaniesSearchResponse:
84
- """
85
- Search for companies using various filters and criteria
86
-
87
- Args:
88
- organization_department_headcount_ranges: Organization department headcount ranges
89
-
90
- organization_founded_year_max: Organization founded year maximum
91
-
92
- organization_founded_year_min: Organization founded year minimum
93
-
94
- organization_locations: Organization locations
95
-
96
- organization_naics_codes: Organization NAICS codes
97
-
98
- organization_not_ids: Organization ids to exclude
99
-
100
- organization_num_employees_ranges: Organization num employees ranges
101
-
102
- organization_revenue_ranges: Organization revenue ranges
103
-
104
- organization_sic_codes: Organization SIC codes
105
-
106
- organization_technologies: Organization technologies
107
-
108
- page: Page number (default: 1)
109
-
110
- per_page: Number of results per page (max 200)
111
-
112
- q_keywords: Keywords to search for
113
-
114
- q_organization_industry_tag_ids: Organization industries
115
-
116
- q_organization_keyword_tags: Organization keyword tags
117
-
118
- sort_ascending: Sort ascending
119
-
120
- sort_by_field: Sort by field
121
-
122
- extra_headers: Send extra headers
123
-
124
- extra_query: Add additional query parameters to the request
125
-
126
- extra_body: Add additional JSON properties to the request
127
-
128
- timeout: Override the client-level default timeout for this request, in seconds
129
- """
130
- return self._post(
131
- "/external/people/mixed_companies/search",
132
- body=maybe_transform(
133
- {
134
- "organization_department_headcount_ranges": organization_department_headcount_ranges,
135
- "organization_founded_year_max": organization_founded_year_max,
136
- "organization_founded_year_min": organization_founded_year_min,
137
- "organization_locations": organization_locations,
138
- "organization_naics_codes": organization_naics_codes,
139
- "organization_not_ids": organization_not_ids,
140
- "organization_num_employees_ranges": organization_num_employees_ranges,
141
- "organization_revenue_ranges": organization_revenue_ranges,
142
- "organization_sic_codes": organization_sic_codes,
143
- "organization_technologies": organization_technologies,
144
- "page": page,
145
- "per_page": per_page,
146
- "q_keywords": q_keywords,
147
- "q_organization_industry_tag_ids": q_organization_industry_tag_ids,
148
- "q_organization_keyword_tags": q_organization_keyword_tags,
149
- "sort_ascending": sort_ascending,
150
- "sort_by_field": sort_by_field,
151
- },
152
- person_companies_search_params.PersonCompaniesSearchParams,
153
- ),
154
- options=make_request_options(
155
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
156
- ),
157
- cast_to=CompaniesSearchResponse,
158
- )
159
-
160
- def organization_detail(
161
- self,
162
- id: str,
163
- *,
164
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
165
- # The extra values given here take precedence over values defined on the client or passed to this method.
166
- extra_headers: Headers | None = None,
167
- extra_query: Query | None = None,
168
- extra_body: Body | None = None,
169
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
170
- ) -> OrganizationDetail:
171
- """
172
- Retrieve detailed information about a specific organization
173
-
174
- Args:
175
- extra_headers: Send extra headers
176
-
177
- extra_query: Add additional query parameters to the request
178
-
179
- extra_body: Add additional JSON properties to the request
180
-
181
- timeout: Override the client-level default timeout for this request, in seconds
182
- """
183
- if not id:
184
- raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
185
- return self._get(
186
- f"/external/people/organizations/{id}",
187
- options=make_request_options(
188
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
189
- ),
190
- cast_to=OrganizationDetail,
191
- )
192
-
193
- def organization_job_postings(
194
- self,
195
- organization_id: str,
196
- *,
197
- page: Optional[int] | Omit = omit,
198
- per_page: Optional[int] | Omit = omit,
199
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
200
- # The extra values given here take precedence over values defined on the client or passed to this method.
201
- extra_headers: Headers | None = None,
202
- extra_query: Query | None = None,
203
- extra_body: Body | None = None,
204
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
205
- ) -> JobPostingsResponse:
206
- """
207
- Retrieve job postings for a specific organization
208
-
209
- Args:
210
- page: Page number
211
-
212
- per_page: Results per page
213
-
214
- extra_headers: Send extra headers
215
-
216
- extra_query: Add additional query parameters to the request
217
-
218
- extra_body: Add additional JSON properties to the request
219
-
220
- timeout: Override the client-level default timeout for this request, in seconds
221
- """
222
- if not organization_id:
223
- raise ValueError(f"Expected a non-empty value for `organization_id` but received {organization_id!r}")
224
- return self._get(
225
- f"/external/people/organizations/{organization_id}/job_postings",
226
- options=make_request_options(
227
- extra_headers=extra_headers,
228
- extra_query=extra_query,
229
- extra_body=extra_body,
230
- timeout=timeout,
231
- query=maybe_transform(
232
- {
233
- "page": page,
234
- "per_page": per_page,
235
- },
236
- person_organization_job_postings_params.PersonOrganizationJobPostingsParams,
237
- ),
238
- ),
239
- cast_to=JobPostingsResponse,
240
- )
241
-
242
- def organizations_enrich(
243
- self,
244
- *,
245
- domain: Optional[str] | Omit = omit,
246
- organization_name: Optional[str] | Omit = omit,
247
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
248
- # The extra values given here take precedence over values defined on the client or passed to this method.
249
- extra_headers: Headers | None = None,
250
- extra_query: Query | None = None,
251
- extra_body: Body | None = None,
252
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
253
- ) -> EnrichedOrganization:
254
- """
255
- Enrich organization data using Apollo.io's organization enrichment
256
-
257
- Args:
258
- domain: Organization domain
259
-
260
- organization_name: Organization name
261
-
262
- extra_headers: Send extra headers
263
-
264
- extra_query: Add additional query parameters to the request
265
-
266
- extra_body: Add additional JSON properties to the request
267
-
268
- timeout: Override the client-level default timeout for this request, in seconds
269
- """
270
- return self._get(
271
- "/external/people/organizations/enrich",
272
- options=make_request_options(
273
- extra_headers=extra_headers,
274
- extra_query=extra_query,
275
- extra_body=extra_body,
276
- timeout=timeout,
277
- query=maybe_transform(
278
- {
279
- "domain": domain,
280
- "organization_name": organization_name,
281
- },
282
- person_organizations_enrich_params.PersonOrganizationsEnrichParams,
283
- ),
284
- ),
285
- cast_to=EnrichedOrganization,
286
- )
287
-
288
- def people_match(
289
- self,
290
- *,
291
- company_domain: Optional[str] | Omit = omit,
292
- company_name: Optional[str] | Omit = omit,
293
- email: Optional[str] | Omit = omit,
294
- first_name: Optional[str] | Omit = omit,
295
- last_name: Optional[str] | Omit = omit,
296
- linkedin_url: Optional[str] | Omit = omit,
297
- location: Optional[str] | Omit = omit,
298
- name: Optional[str] | Omit = omit,
299
- phone: Optional[str] | Omit = omit,
300
- reveal_personal_emails: Optional[bool] | Omit = omit,
301
- reveal_phone_number: Optional[bool] | Omit = omit,
302
- reveal_professional_emails: Optional[bool] | Omit = omit,
303
- title: Optional[str] | Omit = omit,
304
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
305
- # The extra values given here take precedence over values defined on the client or passed to this method.
306
- extra_headers: Headers | None = None,
307
- extra_query: Query | None = None,
308
- extra_body: Body | None = None,
309
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
310
- ) -> PeopleMatchResponse:
311
- """
312
- Enrich a single person's profile data using Apollo.io's person matching
313
-
314
- Args:
315
- company_domain: Company domain
316
-
317
- company_name: Company name
318
-
319
- email: Email address
320
-
321
- first_name: First name
322
-
323
- last_name: Last name
324
-
325
- linkedin_url: LinkedIn URL
326
-
327
- location: Location (city, state, country)
328
-
329
- name: Full name (alternative to first/last)
330
-
331
- phone: Phone number
332
-
333
- reveal_personal_emails: Whether to reveal personal email
334
-
335
- reveal_phone_number: Whether to reveal phone numbers
336
-
337
- reveal_professional_emails: Whether to reveal work email
338
-
339
- title: Job title
340
-
341
- extra_headers: Send extra headers
342
-
343
- extra_query: Add additional query parameters to the request
344
-
345
- extra_body: Add additional JSON properties to the request
346
-
347
- timeout: Override the client-level default timeout for this request, in seconds
348
- """
349
- return self._post(
350
- "/external/people/people/match",
351
- body=maybe_transform(
352
- {
353
- "company_domain": company_domain,
354
- "company_name": company_name,
355
- "email": email,
356
- "first_name": first_name,
357
- "last_name": last_name,
358
- "linkedin_url": linkedin_url,
359
- "location": location,
360
- "name": name,
361
- "phone": phone,
362
- "reveal_personal_emails": reveal_personal_emails,
363
- "reveal_phone_number": reveal_phone_number,
364
- "reveal_professional_emails": reveal_professional_emails,
365
- "title": title,
366
- },
367
- person_people_match_params.PersonPeopleMatchParams,
368
- ),
369
- options=make_request_options(
370
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
371
- ),
372
- cast_to=PeopleMatchResponse,
373
- )
374
-
375
- def people_search(
376
- self,
377
- *,
378
- contact_email_status: Optional[SequenceNotStr[str]] | Omit = omit,
379
- organization_ids: Optional[SequenceNotStr[str]] | Omit = omit,
380
- organization_locations: Optional[SequenceNotStr[str]] | Omit = omit,
381
- organization_num_employees_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
382
- page: Optional[int] | Omit = omit,
383
- per_page: Optional[int] | Omit = omit,
384
- person_departments: Optional[SequenceNotStr[str]] | Omit = omit,
385
- person_locations: Optional[SequenceNotStr[str]] | Omit = omit,
386
- person_seniorities: Optional[SequenceNotStr[str]] | Omit = omit,
387
- person_titles: Optional[SequenceNotStr[str]] | Omit = omit,
388
- q_keywords: Optional[str] | Omit = omit,
389
- q_organization_industry_tag_ids: Optional[SequenceNotStr[str]] | Omit = omit,
390
- reveal_personal_emails: Optional[bool] | Omit = omit,
391
- reveal_phone_number: Optional[bool] | Omit = omit,
392
- reveal_professional_emails: Optional[bool] | Omit = omit,
393
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
394
- # The extra values given here take precedence over values defined on the client or passed to this method.
395
- extra_headers: Headers | None = None,
396
- extra_query: Query | None = None,
397
- extra_body: Body | None = None,
398
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
399
- ) -> PeopleSearchResponse:
400
- """
401
- Search for people using various filters and criteria
402
-
403
- Args:
404
- contact_email_status: Contact email status
405
-
406
- organization_ids: Organization ids
407
-
408
- organization_locations: Organization locations
409
-
410
- organization_num_employees_ranges: Organization num employees ranges
411
-
412
- page: Page number (default: 1)
413
-
414
- per_page: Number of results per page (max 200)
415
-
416
- person_departments: Person departments
417
-
418
- person_locations: Person locations
419
-
420
- person_seniorities: Person seniorities
421
-
422
- person_titles: Person titles to include
423
-
424
- q_keywords: Keywords
425
-
426
- q_organization_industry_tag_ids: Organization industries
427
-
428
- reveal_personal_emails: Reveal personal emails
429
-
430
- reveal_phone_number: Reveal phone numbers
431
-
432
- reveal_professional_emails: Reveal work emails
433
-
434
- extra_headers: Send extra headers
435
-
436
- extra_query: Add additional query parameters to the request
437
-
438
- extra_body: Add additional JSON properties to the request
439
-
440
- timeout: Override the client-level default timeout for this request, in seconds
441
- """
442
- return self._post(
443
- "/external/people/mixed_people/search",
444
- body=maybe_transform(
445
- {
446
- "contact_email_status": contact_email_status,
447
- "organization_ids": organization_ids,
448
- "organization_locations": organization_locations,
449
- "organization_num_employees_ranges": organization_num_employees_ranges,
450
- "page": page,
451
- "per_page": per_page,
452
- "person_departments": person_departments,
453
- "person_locations": person_locations,
454
- "person_seniorities": person_seniorities,
455
- "person_titles": person_titles,
456
- "q_keywords": q_keywords,
457
- "q_organization_industry_tag_ids": q_organization_industry_tag_ids,
458
- "reveal_personal_emails": reveal_personal_emails,
459
- "reveal_phone_number": reveal_phone_number,
460
- "reveal_professional_emails": reveal_professional_emails,
461
- },
462
- person_people_search_params.PersonPeopleSearchParams,
463
- ),
464
- options=make_request_options(
465
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
466
- ),
467
- cast_to=PeopleSearchResponse,
468
- )
469
-
470
-
471
- class AsyncPeopleResource(AsyncAPIResource):
472
- @cached_property
473
- def with_raw_response(self) -> AsyncPeopleResourceWithRawResponse:
474
- """
475
- This property can be used as a prefix for any HTTP method call to return
476
- the raw response object instead of the parsed content.
477
-
478
- For more information, see https://www.github.com/StructifyAI/structify-python#accessing-raw-response-data-eg-headers
479
- """
480
- return AsyncPeopleResourceWithRawResponse(self)
481
-
482
- @cached_property
483
- def with_streaming_response(self) -> AsyncPeopleResourceWithStreamingResponse:
484
- """
485
- An alternative to `.with_raw_response` that doesn't eagerly read the response body.
486
-
487
- For more information, see https://www.github.com/StructifyAI/structify-python#with_streaming_response
488
- """
489
- return AsyncPeopleResourceWithStreamingResponse(self)
490
-
491
- async def companies_search(
492
- self,
493
- *,
494
- organization_department_headcount_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
495
- organization_founded_year_max: Optional[int] | Omit = omit,
496
- organization_founded_year_min: Optional[int] | Omit = omit,
497
- organization_locations: Optional[SequenceNotStr[str]] | Omit = omit,
498
- organization_naics_codes: Optional[SequenceNotStr[str]] | Omit = omit,
499
- organization_not_ids: Optional[SequenceNotStr[str]] | Omit = omit,
500
- organization_num_employees_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
501
- organization_revenue_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
502
- organization_sic_codes: Optional[SequenceNotStr[str]] | Omit = omit,
503
- organization_technologies: Optional[SequenceNotStr[str]] | Omit = omit,
504
- page: Optional[int] | Omit = omit,
505
- per_page: Optional[int] | Omit = omit,
506
- q_keywords: Optional[str] | Omit = omit,
507
- q_organization_industry_tag_ids: Optional[SequenceNotStr[str]] | Omit = omit,
508
- q_organization_keyword_tags: Optional[SequenceNotStr[str]] | Omit = omit,
509
- sort_ascending: Optional[bool] | Omit = omit,
510
- sort_by_field: Optional[str] | Omit = omit,
511
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
512
- # The extra values given here take precedence over values defined on the client or passed to this method.
513
- extra_headers: Headers | None = None,
514
- extra_query: Query | None = None,
515
- extra_body: Body | None = None,
516
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
517
- ) -> CompaniesSearchResponse:
518
- """
519
- Search for companies using various filters and criteria
520
-
521
- Args:
522
- organization_department_headcount_ranges: Organization department headcount ranges
523
-
524
- organization_founded_year_max: Organization founded year maximum
525
-
526
- organization_founded_year_min: Organization founded year minimum
527
-
528
- organization_locations: Organization locations
529
-
530
- organization_naics_codes: Organization NAICS codes
531
-
532
- organization_not_ids: Organization ids to exclude
533
-
534
- organization_num_employees_ranges: Organization num employees ranges
535
-
536
- organization_revenue_ranges: Organization revenue ranges
537
-
538
- organization_sic_codes: Organization SIC codes
539
-
540
- organization_technologies: Organization technologies
541
-
542
- page: Page number (default: 1)
543
-
544
- per_page: Number of results per page (max 200)
545
-
546
- q_keywords: Keywords to search for
547
-
548
- q_organization_industry_tag_ids: Organization industries
549
-
550
- q_organization_keyword_tags: Organization keyword tags
551
-
552
- sort_ascending: Sort ascending
553
-
554
- sort_by_field: Sort by field
555
-
556
- extra_headers: Send extra headers
557
-
558
- extra_query: Add additional query parameters to the request
559
-
560
- extra_body: Add additional JSON properties to the request
561
-
562
- timeout: Override the client-level default timeout for this request, in seconds
563
- """
564
- return await self._post(
565
- "/external/people/mixed_companies/search",
566
- body=await async_maybe_transform(
567
- {
568
- "organization_department_headcount_ranges": organization_department_headcount_ranges,
569
- "organization_founded_year_max": organization_founded_year_max,
570
- "organization_founded_year_min": organization_founded_year_min,
571
- "organization_locations": organization_locations,
572
- "organization_naics_codes": organization_naics_codes,
573
- "organization_not_ids": organization_not_ids,
574
- "organization_num_employees_ranges": organization_num_employees_ranges,
575
- "organization_revenue_ranges": organization_revenue_ranges,
576
- "organization_sic_codes": organization_sic_codes,
577
- "organization_technologies": organization_technologies,
578
- "page": page,
579
- "per_page": per_page,
580
- "q_keywords": q_keywords,
581
- "q_organization_industry_tag_ids": q_organization_industry_tag_ids,
582
- "q_organization_keyword_tags": q_organization_keyword_tags,
583
- "sort_ascending": sort_ascending,
584
- "sort_by_field": sort_by_field,
585
- },
586
- person_companies_search_params.PersonCompaniesSearchParams,
587
- ),
588
- options=make_request_options(
589
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
590
- ),
591
- cast_to=CompaniesSearchResponse,
592
- )
593
-
594
- async def organization_detail(
595
- self,
596
- id: str,
597
- *,
598
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
599
- # The extra values given here take precedence over values defined on the client or passed to this method.
600
- extra_headers: Headers | None = None,
601
- extra_query: Query | None = None,
602
- extra_body: Body | None = None,
603
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
604
- ) -> OrganizationDetail:
605
- """
606
- Retrieve detailed information about a specific organization
607
-
608
- Args:
609
- extra_headers: Send extra headers
610
-
611
- extra_query: Add additional query parameters to the request
612
-
613
- extra_body: Add additional JSON properties to the request
614
-
615
- timeout: Override the client-level default timeout for this request, in seconds
616
- """
617
- if not id:
618
- raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
619
- return await self._get(
620
- f"/external/people/organizations/{id}",
621
- options=make_request_options(
622
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
623
- ),
624
- cast_to=OrganizationDetail,
625
- )
626
-
627
- async def organization_job_postings(
628
- self,
629
- organization_id: str,
630
- *,
631
- page: Optional[int] | Omit = omit,
632
- per_page: Optional[int] | Omit = omit,
633
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
634
- # The extra values given here take precedence over values defined on the client or passed to this method.
635
- extra_headers: Headers | None = None,
636
- extra_query: Query | None = None,
637
- extra_body: Body | None = None,
638
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
639
- ) -> JobPostingsResponse:
640
- """
641
- Retrieve job postings for a specific organization
642
-
643
- Args:
644
- page: Page number
645
-
646
- per_page: Results per page
647
-
648
- extra_headers: Send extra headers
649
-
650
- extra_query: Add additional query parameters to the request
651
-
652
- extra_body: Add additional JSON properties to the request
653
-
654
- timeout: Override the client-level default timeout for this request, in seconds
655
- """
656
- if not organization_id:
657
- raise ValueError(f"Expected a non-empty value for `organization_id` but received {organization_id!r}")
658
- return await self._get(
659
- f"/external/people/organizations/{organization_id}/job_postings",
660
- options=make_request_options(
661
- extra_headers=extra_headers,
662
- extra_query=extra_query,
663
- extra_body=extra_body,
664
- timeout=timeout,
665
- query=await async_maybe_transform(
666
- {
667
- "page": page,
668
- "per_page": per_page,
669
- },
670
- person_organization_job_postings_params.PersonOrganizationJobPostingsParams,
671
- ),
672
- ),
673
- cast_to=JobPostingsResponse,
674
- )
675
-
676
- async def organizations_enrich(
677
- self,
678
- *,
679
- domain: Optional[str] | Omit = omit,
680
- organization_name: Optional[str] | Omit = omit,
681
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
682
- # The extra values given here take precedence over values defined on the client or passed to this method.
683
- extra_headers: Headers | None = None,
684
- extra_query: Query | None = None,
685
- extra_body: Body | None = None,
686
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
687
- ) -> EnrichedOrganization:
688
- """
689
- Enrich organization data using Apollo.io's organization enrichment
690
-
691
- Args:
692
- domain: Organization domain
693
-
694
- organization_name: Organization name
695
-
696
- extra_headers: Send extra headers
697
-
698
- extra_query: Add additional query parameters to the request
699
-
700
- extra_body: Add additional JSON properties to the request
701
-
702
- timeout: Override the client-level default timeout for this request, in seconds
703
- """
704
- return await self._get(
705
- "/external/people/organizations/enrich",
706
- options=make_request_options(
707
- extra_headers=extra_headers,
708
- extra_query=extra_query,
709
- extra_body=extra_body,
710
- timeout=timeout,
711
- query=await async_maybe_transform(
712
- {
713
- "domain": domain,
714
- "organization_name": organization_name,
715
- },
716
- person_organizations_enrich_params.PersonOrganizationsEnrichParams,
717
- ),
718
- ),
719
- cast_to=EnrichedOrganization,
720
- )
721
-
722
- async def people_match(
723
- self,
724
- *,
725
- company_domain: Optional[str] | Omit = omit,
726
- company_name: Optional[str] | Omit = omit,
727
- email: Optional[str] | Omit = omit,
728
- first_name: Optional[str] | Omit = omit,
729
- last_name: Optional[str] | Omit = omit,
730
- linkedin_url: Optional[str] | Omit = omit,
731
- location: Optional[str] | Omit = omit,
732
- name: Optional[str] | Omit = omit,
733
- phone: Optional[str] | Omit = omit,
734
- reveal_personal_emails: Optional[bool] | Omit = omit,
735
- reveal_phone_number: Optional[bool] | Omit = omit,
736
- reveal_professional_emails: Optional[bool] | Omit = omit,
737
- title: Optional[str] | Omit = omit,
738
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
739
- # The extra values given here take precedence over values defined on the client or passed to this method.
740
- extra_headers: Headers | None = None,
741
- extra_query: Query | None = None,
742
- extra_body: Body | None = None,
743
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
744
- ) -> PeopleMatchResponse:
745
- """
746
- Enrich a single person's profile data using Apollo.io's person matching
747
-
748
- Args:
749
- company_domain: Company domain
750
-
751
- company_name: Company name
752
-
753
- email: Email address
754
-
755
- first_name: First name
756
-
757
- last_name: Last name
758
-
759
- linkedin_url: LinkedIn URL
760
-
761
- location: Location (city, state, country)
762
-
763
- name: Full name (alternative to first/last)
764
-
765
- phone: Phone number
766
-
767
- reveal_personal_emails: Whether to reveal personal email
768
-
769
- reveal_phone_number: Whether to reveal phone numbers
770
-
771
- reveal_professional_emails: Whether to reveal work email
772
-
773
- title: Job title
774
-
775
- extra_headers: Send extra headers
776
-
777
- extra_query: Add additional query parameters to the request
778
-
779
- extra_body: Add additional JSON properties to the request
780
-
781
- timeout: Override the client-level default timeout for this request, in seconds
782
- """
783
- return await self._post(
784
- "/external/people/people/match",
785
- body=await async_maybe_transform(
786
- {
787
- "company_domain": company_domain,
788
- "company_name": company_name,
789
- "email": email,
790
- "first_name": first_name,
791
- "last_name": last_name,
792
- "linkedin_url": linkedin_url,
793
- "location": location,
794
- "name": name,
795
- "phone": phone,
796
- "reveal_personal_emails": reveal_personal_emails,
797
- "reveal_phone_number": reveal_phone_number,
798
- "reveal_professional_emails": reveal_professional_emails,
799
- "title": title,
800
- },
801
- person_people_match_params.PersonPeopleMatchParams,
802
- ),
803
- options=make_request_options(
804
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
805
- ),
806
- cast_to=PeopleMatchResponse,
807
- )
808
-
809
- async def people_search(
810
- self,
811
- *,
812
- contact_email_status: Optional[SequenceNotStr[str]] | Omit = omit,
813
- organization_ids: Optional[SequenceNotStr[str]] | Omit = omit,
814
- organization_locations: Optional[SequenceNotStr[str]] | Omit = omit,
815
- organization_num_employees_ranges: Optional[SequenceNotStr[str]] | Omit = omit,
816
- page: Optional[int] | Omit = omit,
817
- per_page: Optional[int] | Omit = omit,
818
- person_departments: Optional[SequenceNotStr[str]] | Omit = omit,
819
- person_locations: Optional[SequenceNotStr[str]] | Omit = omit,
820
- person_seniorities: Optional[SequenceNotStr[str]] | Omit = omit,
821
- person_titles: Optional[SequenceNotStr[str]] | Omit = omit,
822
- q_keywords: Optional[str] | Omit = omit,
823
- q_organization_industry_tag_ids: Optional[SequenceNotStr[str]] | Omit = omit,
824
- reveal_personal_emails: Optional[bool] | Omit = omit,
825
- reveal_phone_number: Optional[bool] | Omit = omit,
826
- reveal_professional_emails: Optional[bool] | Omit = omit,
827
- # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
828
- # The extra values given here take precedence over values defined on the client or passed to this method.
829
- extra_headers: Headers | None = None,
830
- extra_query: Query | None = None,
831
- extra_body: Body | None = None,
832
- timeout: float | httpx.Timeout | None | NotGiven = not_given,
833
- ) -> PeopleSearchResponse:
834
- """
835
- Search for people using various filters and criteria
836
-
837
- Args:
838
- contact_email_status: Contact email status
839
-
840
- organization_ids: Organization ids
841
-
842
- organization_locations: Organization locations
843
-
844
- organization_num_employees_ranges: Organization num employees ranges
845
-
846
- page: Page number (default: 1)
847
-
848
- per_page: Number of results per page (max 200)
849
-
850
- person_departments: Person departments
851
-
852
- person_locations: Person locations
853
-
854
- person_seniorities: Person seniorities
855
-
856
- person_titles: Person titles to include
857
-
858
- q_keywords: Keywords
859
-
860
- q_organization_industry_tag_ids: Organization industries
861
-
862
- reveal_personal_emails: Reveal personal emails
863
-
864
- reveal_phone_number: Reveal phone numbers
865
-
866
- reveal_professional_emails: Reveal work emails
867
-
868
- extra_headers: Send extra headers
869
-
870
- extra_query: Add additional query parameters to the request
871
-
872
- extra_body: Add additional JSON properties to the request
873
-
874
- timeout: Override the client-level default timeout for this request, in seconds
875
- """
876
- return await self._post(
877
- "/external/people/mixed_people/search",
878
- body=await async_maybe_transform(
879
- {
880
- "contact_email_status": contact_email_status,
881
- "organization_ids": organization_ids,
882
- "organization_locations": organization_locations,
883
- "organization_num_employees_ranges": organization_num_employees_ranges,
884
- "page": page,
885
- "per_page": per_page,
886
- "person_departments": person_departments,
887
- "person_locations": person_locations,
888
- "person_seniorities": person_seniorities,
889
- "person_titles": person_titles,
890
- "q_keywords": q_keywords,
891
- "q_organization_industry_tag_ids": q_organization_industry_tag_ids,
892
- "reveal_personal_emails": reveal_personal_emails,
893
- "reveal_phone_number": reveal_phone_number,
894
- "reveal_professional_emails": reveal_professional_emails,
895
- },
896
- person_people_search_params.PersonPeopleSearchParams,
897
- ),
898
- options=make_request_options(
899
- extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
900
- ),
901
- cast_to=PeopleSearchResponse,
902
- )
903
-
904
-
905
- class PeopleResourceWithRawResponse:
906
- def __init__(self, people: PeopleResource) -> None:
907
- self._people = people
908
-
909
- self.companies_search = to_raw_response_wrapper(
910
- people.companies_search,
911
- )
912
- self.organization_detail = to_raw_response_wrapper(
913
- people.organization_detail,
914
- )
915
- self.organization_job_postings = to_raw_response_wrapper(
916
- people.organization_job_postings,
917
- )
918
- self.organizations_enrich = to_raw_response_wrapper(
919
- people.organizations_enrich,
920
- )
921
- self.people_match = to_raw_response_wrapper(
922
- people.people_match,
923
- )
924
- self.people_search = to_raw_response_wrapper(
925
- people.people_search,
926
- )
927
-
928
-
929
- class AsyncPeopleResourceWithRawResponse:
930
- def __init__(self, people: AsyncPeopleResource) -> None:
931
- self._people = people
932
-
933
- self.companies_search = async_to_raw_response_wrapper(
934
- people.companies_search,
935
- )
936
- self.organization_detail = async_to_raw_response_wrapper(
937
- people.organization_detail,
938
- )
939
- self.organization_job_postings = async_to_raw_response_wrapper(
940
- people.organization_job_postings,
941
- )
942
- self.organizations_enrich = async_to_raw_response_wrapper(
943
- people.organizations_enrich,
944
- )
945
- self.people_match = async_to_raw_response_wrapper(
946
- people.people_match,
947
- )
948
- self.people_search = async_to_raw_response_wrapper(
949
- people.people_search,
950
- )
951
-
952
-
953
- class PeopleResourceWithStreamingResponse:
954
- def __init__(self, people: PeopleResource) -> None:
955
- self._people = people
956
-
957
- self.companies_search = to_streamed_response_wrapper(
958
- people.companies_search,
959
- )
960
- self.organization_detail = to_streamed_response_wrapper(
961
- people.organization_detail,
962
- )
963
- self.organization_job_postings = to_streamed_response_wrapper(
964
- people.organization_job_postings,
965
- )
966
- self.organizations_enrich = to_streamed_response_wrapper(
967
- people.organizations_enrich,
968
- )
969
- self.people_match = to_streamed_response_wrapper(
970
- people.people_match,
971
- )
972
- self.people_search = to_streamed_response_wrapper(
973
- people.people_search,
974
- )
975
-
976
-
977
- class AsyncPeopleResourceWithStreamingResponse:
978
- def __init__(self, people: AsyncPeopleResource) -> None:
979
- self._people = people
980
-
981
- self.companies_search = async_to_streamed_response_wrapper(
982
- people.companies_search,
983
- )
984
- self.organization_detail = async_to_streamed_response_wrapper(
985
- people.organization_detail,
986
- )
987
- self.organization_job_postings = async_to_streamed_response_wrapper(
988
- people.organization_job_postings,
989
- )
990
- self.organizations_enrich = async_to_streamed_response_wrapper(
991
- people.organizations_enrich,
992
- )
993
- self.people_match = async_to_streamed_response_wrapper(
994
- people.people_match,
995
- )
996
- self.people_search = async_to_streamed_response_wrapper(
997
- people.people_search,
998
- )