larynth 0.1.0__tar.gz
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.
- larynth-0.1.0/LICENSE +21 -0
- larynth-0.1.0/PKG-INFO +114 -0
- larynth-0.1.0/README.md +85 -0
- larynth-0.1.0/pyproject.toml +47 -0
- larynth-0.1.0/setup.cfg +4 -0
- larynth-0.1.0/src/larynth/__init__.py +23 -0
- larynth-0.1.0/src/larynth/generated/__init__.py +8 -0
- larynth-0.1.0/src/larynth/generated/api/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/create_assistant.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/create_assistant_version.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/delete_assistant.py +195 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/get_assistant.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/get_assistant_version.py +206 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/list_assistant_versions.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/list_assistants.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/publish_assistant_version.py +211 -0
- larynth-0.1.0/src/larynth/generated/api/assistants/update_assistant.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/billing/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/billing/get_auto_top_up.py +159 -0
- larynth-0.1.0/src/larynth/generated/api/billing/get_balance.py +159 -0
- larynth-0.1.0/src/larynth/generated/api/billing/list_ledger.py +298 -0
- larynth-0.1.0/src/larynth/generated/api/billing/list_rates.py +159 -0
- larynth-0.1.0/src/larynth/generated/api/calls/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/calls/create_call.py +224 -0
- larynth-0.1.0/src/larynth/generated/api/calls/create_ice_servers.py +164 -0
- larynth-0.1.0/src/larynth/generated/api/calls/create_web_call.py +233 -0
- larynth-0.1.0/src/larynth/generated/api/calls/end_call.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/calls/get_call.py +191 -0
- larynth-0.1.0/src/larynth/generated/api/calls/get_call_analysis.py +191 -0
- larynth-0.1.0/src/larynth/generated/api/calls/list_call_events.py +227 -0
- larynth-0.1.0/src/larynth/generated/api/calls/list_call_turns.py +227 -0
- larynth-0.1.0/src/larynth/generated/api/calls/list_calls.py +304 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/add_campaign_contacts.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/archive_campaign.py +197 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/create_campaign.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/get_campaign.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/get_campaign_stats.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/list_campaign_contacts.py +250 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/list_campaigns.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/pause_campaign.py +197 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/resume_campaign.py +207 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/start_campaign.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/campaigns/update_campaign.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/catalog/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/catalog/list_catalog_models.py +243 -0
- larynth-0.1.0/src/larynth/generated/api/catalog/list_catalog_voices.py +240 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/create_consent.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/create_dnc.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/create_revocation.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/list_compliance_decisions.py +314 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/list_consents.py +221 -0
- larynth-0.1.0/src/larynth/generated/api/compliance/list_dnc.py +236 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/create_contact.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/create_contact_import.py +215 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/delete_contact.py +195 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/get_contact.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/get_contact_import.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/list_contacts.py +221 -0
- larynth-0.1.0/src/larynth/generated/api/contacts/update_contact.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/create_knowledge_base.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/create_knowledge_file_source.py +219 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/create_knowledge_website_source.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/delete_knowledge_base.py +195 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/delete_knowledge_source.py +209 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/get_knowledge_base.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/get_knowledge_source.py +206 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/list_knowledge_bases.py +206 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/list_knowledge_sources.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/search_knowledge_base.py +228 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/sync_knowledge_source.py +211 -0
- larynth-0.1.0/src/larynth/generated/api/knowledge/update_knowledge_base.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/get_number.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/list_numbers.py +226 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/order_number.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/release_number.py +197 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/search_available_numbers.py +221 -0
- larynth-0.1.0/src/larynth/generated/api/numbers/update_number.py +218 -0
- larynth-0.1.0/src/larynth/generated/api/recordings/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/recordings/get_recording_audio.py +186 -0
- larynth-0.1.0/src/larynth/generated/api/recordings/list_call_recordings.py +191 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/__init__.py +1 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/create_webhook.py +196 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/delete_webhook.py +195 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/get_webhook.py +192 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/list_webhook_deliveries.py +250 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/list_webhooks.py +206 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/rotate_webhook_secret.py +197 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/test_webhook.py +219 -0
- larynth-0.1.0/src/larynth/generated/api/webhooks/update_webhook.py +218 -0
- larynth-0.1.0/src/larynth/generated/client.py +280 -0
- larynth-0.1.0/src/larynth/generated/errors.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/__init__.py +403 -0
- larynth-0.1.0/src/larynth/generated/models/add_campaign_contacts_request.py +56 -0
- larynth-0.1.0/src/larynth/generated/models/add_campaign_contacts_result.py +50 -0
- larynth-0.1.0/src/larynth/generated/models/amd_answer_headers.py +77 -0
- larynth-0.1.0/src/larynth/generated/models/assistant.py +112 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_tool.py +146 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_tool_class.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_tool_config.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_tool_json_schema.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_tool_kind.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version.py +433 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_llm_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_mode.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_s2s_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec.py +384 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec_llm_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec_mode.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec_s2s_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec_stt_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_spec_tts_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_stt_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/assistant_version_tts_params.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/auto_top_up.py +83 -0
- larynth-0.1.0/src/larynth/generated/models/available_number.py +69 -0
- larynth-0.1.0/src/larynth/generated/models/balance.py +85 -0
- larynth-0.1.0/src/larynth/generated/models/balance_currency.py +15 -0
- larynth-0.1.0/src/larynth/generated/models/call.py +503 -0
- larynth-0.1.0/src/larynth/generated/models/call_amd_early_media_tone.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/call_amd_verdict.py +24 -0
- larynth-0.1.0/src/larynth/generated/models/call_analysis.py +126 -0
- larynth-0.1.0/src/larynth/generated/models/call_analysis_data.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/call_attestation.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/call_codec.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/call_direction.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/call_event.py +83 -0
- larynth-0.1.0/src/larynth/generated/models/call_event_kind.py +35 -0
- larynth-0.1.0/src/larynth/generated/models/call_event_payload.py +47 -0
- larynth-0.1.0/src/larynth/generated/models/call_hangup_by.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/call_mode.py +14 -0
- larynth-0.1.0/src/larynth/generated/models/call_status.py +35 -0
- larynth-0.1.0/src/larynth/generated/models/call_turn.py +178 -0
- larynth-0.1.0/src/larynth/generated/models/call_turn_spec_tts.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/call_turn_speculation.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/campaign.py +287 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_amd_mode.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_contact.py +147 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_contact_enrolment.py +71 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_contact_enrolment_variables.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_contact_state.py +33 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_contact_variables.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_paused_reason.py +27 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_purpose.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_stats.py +130 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_stats_by_state.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_status.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/campaign_window.py +58 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_model.py +150 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_model_defaults.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_model_kind.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_model_params_schema.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_model_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_voice.py +125 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_voice_attributes.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/catalog_voice_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/compliance_decision.py +147 -0
- larynth-0.1.0/src/larynth/generated/models/compliance_decision_purpose.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/consent.py +188 -0
- larynth-0.1.0/src/larynth/generated/models/consent_kind.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/consent_scope_type.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/consent_source.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/contact.py +129 -0
- larynth-0.1.0/src/larynth/generated/models/contact_attributes.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/contact_import.py +187 -0
- larynth-0.1.0/src/larynth/generated/models/contact_import_consent_kind.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/contact_import_consent_source.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/contact_import_status.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/create_assistant_request.py +42 -0
- larynth-0.1.0/src/larynth/generated/models/create_call_request.py +156 -0
- larynth-0.1.0/src/larynth/generated/models/create_call_request_amd_mode.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/create_call_request_purpose.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/create_call_request_variables.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/create_campaign_request.py +245 -0
- larynth-0.1.0/src/larynth/generated/models/create_campaign_request_amd_mode.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/create_campaign_request_purpose.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/create_consent_request.py +149 -0
- larynth-0.1.0/src/larynth/generated/models/create_consent_request_kind.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/create_consent_request_scope_type.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/create_consent_request_source.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/create_contact_import_body.py +165 -0
- larynth-0.1.0/src/larynth/generated/models/create_contact_import_body_consent_kind.py +20 -0
- larynth-0.1.0/src/larynth/generated/models/create_contact_import_body_consent_source.py +24 -0
- larynth-0.1.0/src/larynth/generated/models/create_contact_request.py +115 -0
- larynth-0.1.0/src/larynth/generated/models/create_contact_request_attributes.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/create_dnc_request.py +63 -0
- larynth-0.1.0/src/larynth/generated/models/create_knowledge_base_request.py +53 -0
- larynth-0.1.0/src/larynth/generated/models/create_knowledge_file_source_body.py +87 -0
- larynth-0.1.0/src/larynth/generated/models/create_revocation_request.py +80 -0
- larynth-0.1.0/src/larynth/generated/models/create_web_call_request.py +77 -0
- larynth-0.1.0/src/larynth/generated/models/create_web_call_request_variables.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/create_webhook_request.py +75 -0
- larynth-0.1.0/src/larynth/generated/models/create_webhook_request_event_types_item.py +51 -0
- larynth-0.1.0/src/larynth/generated/models/create_website_source_request.py +71 -0
- larynth-0.1.0/src/larynth/generated/models/dnc_entry.py +131 -0
- larynth-0.1.0/src/larynth/generated/models/dnc_entry_scope.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/dnc_entry_source.py +22 -0
- larynth-0.1.0/src/larynth/generated/models/end_call_request.py +42 -0
- larynth-0.1.0/src/larynth/generated/models/error_detail.py +60 -0
- larynth-0.1.0/src/larynth/generated/models/extraction_field.py +85 -0
- larynth-0.1.0/src/larynth/generated/models/extraction_field_type.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/ice_server.py +62 -0
- larynth-0.1.0/src/larynth/generated/models/ice_servers.py +65 -0
- larynth-0.1.0/src/larynth/generated/models/interruption_profile.py +100 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_base.py +123 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_base_status.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_hit.py +74 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_search_result.py +78 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_search_result_mode.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_source.py +180 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_source_kind.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/knowledge_source_status.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/latency_settings.py +73 -0
- larynth-0.1.0/src/larynth/generated/models/ledger_entry.py +122 -0
- larynth-0.1.0/src/larynth/generated/models/ledger_entry_account.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/ledger_entry_kind.py +31 -0
- larynth-0.1.0/src/larynth/generated/models/list_assistants_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/list_calls_direction.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/list_calls_status.py +35 -0
- larynth-0.1.0/src/larynth/generated/models/list_campaign_contacts_state.py +33 -0
- larynth-0.1.0/src/larynth/generated/models/list_campaigns_status.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/list_catalog_models_kind.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/list_compliance_decisions_result.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/list_ledger_account.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/list_ledger_kind.py +31 -0
- larynth-0.1.0/src/larynth/generated/models/list_numbers_status.py +22 -0
- larynth-0.1.0/src/larynth/generated/models/list_webhook_deliveries_status.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/number.py +170 -0
- larynth-0.1.0/src/larynth/generated/models/number_route_type.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/number_routing.py +79 -0
- larynth-0.1.0/src/larynth/generated/models/number_routing_route_type.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/number_status.py +22 -0
- larynth-0.1.0/src/larynth/generated/models/order_number_request.py +90 -0
- larynth-0.1.0/src/larynth/generated/models/order_number_request_route_type.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/page_assistant.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_assistant_version.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_available_number.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_call.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_call_event.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_call_turn.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_campaign.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_campaign_contact.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_catalog_model.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_catalog_voice.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_compliance_decision.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_consent.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_contact.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_dnc_entry.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_knowledge_base.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_knowledge_source.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_ledger_entry.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_number.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_rate.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_recording.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_webhook_delivery.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/page_webhook_endpoint.py +70 -0
- larynth-0.1.0/src/larynth/generated/models/post_call_settings.py +89 -0
- larynth-0.1.0/src/larynth/generated/models/problem.py +149 -0
- larynth-0.1.0/src/larynth/generated/models/rate.py +130 -0
- larynth-0.1.0/src/larynth/generated/models/rate_currency.py +15 -0
- larynth-0.1.0/src/larynth/generated/models/rate_direction.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/rate_kind.py +15 -0
- larynth-0.1.0/src/larynth/generated/models/rate_mode.py +14 -0
- larynth-0.1.0/src/larynth/generated/models/recording.py +163 -0
- larynth-0.1.0/src/larynth/generated/models/recording_state.py +19 -0
- larynth-0.1.0/src/larynth/generated/models/retry_policy.py +69 -0
- larynth-0.1.0/src/larynth/generated/models/revocation.py +114 -0
- larynth-0.1.0/src/larynth/generated/models/revocation_channel.py +23 -0
- larynth-0.1.0/src/larynth/generated/models/test_webhook_request.py +53 -0
- larynth-0.1.0/src/larynth/generated/models/test_webhook_request_event_type.py +47 -0
- larynth-0.1.0/src/larynth/generated/models/transfer_destination.py +103 -0
- larynth-0.1.0/src/larynth/generated/models/transfer_destination_mode.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/turn_profile.py +116 -0
- larynth-0.1.0/src/larynth/generated/models/update_assistant_request.py +42 -0
- larynth-0.1.0/src/larynth/generated/models/update_campaign_request.py +229 -0
- larynth-0.1.0/src/larynth/generated/models/update_campaign_request_amd_mode.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/update_contact_request.py +104 -0
- larynth-0.1.0/src/larynth/generated/models/update_contact_request_attributes.py +45 -0
- larynth-0.1.0/src/larynth/generated/models/update_knowledge_base_request.py +51 -0
- larynth-0.1.0/src/larynth/generated/models/update_webhook_request.py +98 -0
- larynth-0.1.0/src/larynth/generated/models/update_webhook_request_event_types_item.py +51 -0
- larynth-0.1.0/src/larynth/generated/models/update_webhook_request_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/web_call.py +58 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_delivery.py +126 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_delivery_status.py +17 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_endpoint.py +134 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_endpoint_status.py +16 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_endpoint_with_secret.py +142 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_endpoint_with_secret_status.py +18 -0
- larynth-0.1.0/src/larynth/generated/models/webhook_test_result.py +43 -0
- larynth-0.1.0/src/larynth/generated/types.py +54 -0
- larynth-0.1.0/src/larynth/py.typed +0 -0
- larynth-0.1.0/src/larynth/webhooks.py +65 -0
- larynth-0.1.0/src/larynth.egg-info/PKG-INFO +114 -0
- larynth-0.1.0/src/larynth.egg-info/SOURCES.txt +304 -0
- larynth-0.1.0/src/larynth.egg-info/dependency_links.txt +1 -0
- larynth-0.1.0/src/larynth.egg-info/requires.txt +6 -0
- larynth-0.1.0/src/larynth.egg-info/top_level.txt +1 -0
- larynth-0.1.0/tests/test_smoke.py +32 -0
- larynth-0.1.0/tests/test_webhooks.py +66 -0
larynth-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Larynth
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
larynth-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: larynth
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Official Python SDK for the Larynth voice AI API and webhook signature verification
|
|
5
|
+
License-Expression: MIT
|
|
6
|
+
Project-URL: Homepage, https://docs.larynth.com/sdks/python
|
|
7
|
+
Project-URL: Documentation, https://docs.larynth.com/sdks/python
|
|
8
|
+
Project-URL: Repository, https://github.com/Larynth-Labs/larynth-python
|
|
9
|
+
Project-URL: Issues, https://github.com/Larynth-Labs/larynth-python/issues
|
|
10
|
+
Project-URL: Changelog, https://github.com/Larynth-Labs/larynth-python/blob/main/CHANGELOG.md
|
|
11
|
+
Keywords: larynth,voice,ai,telephony,sdk,webhooks
|
|
12
|
+
Classifier: Development Status :: 4 - Beta
|
|
13
|
+
Classifier: Intended Audience :: Developers
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
19
|
+
Classifier: Typing :: Typed
|
|
20
|
+
Requires-Python: >=3.11
|
|
21
|
+
Description-Content-Type: text/markdown
|
|
22
|
+
License-File: LICENSE
|
|
23
|
+
Requires-Dist: httpx<0.29,>=0.27
|
|
24
|
+
Requires-Dist: attrs>=23.2
|
|
25
|
+
Requires-Dist: python-dateutil>=2.8.2
|
|
26
|
+
Provides-Extra: test
|
|
27
|
+
Requires-Dist: pytest==8.4.2; extra == "test"
|
|
28
|
+
Dynamic: license-file
|
|
29
|
+
|
|
30
|
+
# larynth
|
|
31
|
+
|
|
32
|
+
[](https://pypi.org/project/larynth/)
|
|
33
|
+
[](https://github.com/Larynth-Labs/larynth-python/actions/workflows/ci.yml)
|
|
34
|
+
|
|
35
|
+
Python SDK for the Larynth voice AI API, with webhook signature verification. Full docs: https://docs.larynth.com/sdks/python
|
|
36
|
+
|
|
37
|
+
## Install
|
|
38
|
+
|
|
39
|
+
```sh
|
|
40
|
+
pip install larynth
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Requires Python 3.11 or newer.
|
|
44
|
+
|
|
45
|
+
> **0.x: beta, may change.** Minor versions can include breaking changes until 1.0.
|
|
46
|
+
|
|
47
|
+
## Authenticate
|
|
48
|
+
|
|
49
|
+
Create an API key in the Larynth dashboard and keep it in the environment. Never commit it.
|
|
50
|
+
|
|
51
|
+
```python
|
|
52
|
+
import os
|
|
53
|
+
|
|
54
|
+
from larynth import authenticated_client
|
|
55
|
+
|
|
56
|
+
client = authenticated_client(
|
|
57
|
+
api_key=os.environ["LARYNTH_API_KEY"],
|
|
58
|
+
base_url="https://api-us.larynth.com",
|
|
59
|
+
)
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Place a call
|
|
63
|
+
|
|
64
|
+
Every call needs an idempotency key; replays within 24 hours return the stored response.
|
|
65
|
+
|
|
66
|
+
```python
|
|
67
|
+
import uuid
|
|
68
|
+
|
|
69
|
+
from larynth.generated.api.calls import create_call
|
|
70
|
+
from larynth.generated.models import CreateCallRequest
|
|
71
|
+
|
|
72
|
+
call = create_call.sync(
|
|
73
|
+
client=client,
|
|
74
|
+
body=CreateCallRequest(
|
|
75
|
+
assistant_id=uuid.UUID("00000000-0000-0000-0000-000000000000"),
|
|
76
|
+
from_e164="+14155550100",
|
|
77
|
+
to_e164="+14155550101",
|
|
78
|
+
purpose="informational",
|
|
79
|
+
),
|
|
80
|
+
idempotency_key=str(uuid.uuid4()),
|
|
81
|
+
)
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
## List assistants
|
|
85
|
+
|
|
86
|
+
```python
|
|
87
|
+
from larynth.generated.api.assistants import list_assistants
|
|
88
|
+
|
|
89
|
+
assistants = list_assistants.sync(client=client)
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## Verify a webhook signature
|
|
93
|
+
|
|
94
|
+
Pass the raw request body, not a re-serialized one.
|
|
95
|
+
|
|
96
|
+
```python
|
|
97
|
+
import os
|
|
98
|
+
|
|
99
|
+
from larynth import WebhookVerificationError, verify
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
def handle(headers: dict[str, str], raw_body: bytes) -> int:
|
|
103
|
+
try:
|
|
104
|
+
verify(os.environ["LARYNTH_WEBHOOK_SECRET"], headers, raw_body)
|
|
105
|
+
except WebhookVerificationError:
|
|
106
|
+
return 400
|
|
107
|
+
return 200
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
## About this repository
|
|
111
|
+
|
|
112
|
+
This SDK is generated from our OpenAPI spec (`openapi/openapi.json`, synced here on every API change), so generated files are overwritten on every sync. Open issues here; pull requests for docs and examples are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md) and [SECURITY.md](SECURITY.md).
|
|
113
|
+
|
|
114
|
+
MIT licensed.
|
larynth-0.1.0/README.md
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# larynth
|
|
2
|
+
|
|
3
|
+
[](https://pypi.org/project/larynth/)
|
|
4
|
+
[](https://github.com/Larynth-Labs/larynth-python/actions/workflows/ci.yml)
|
|
5
|
+
|
|
6
|
+
Python SDK for the Larynth voice AI API, with webhook signature verification. Full docs: https://docs.larynth.com/sdks/python
|
|
7
|
+
|
|
8
|
+
## Install
|
|
9
|
+
|
|
10
|
+
```sh
|
|
11
|
+
pip install larynth
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
Requires Python 3.11 or newer.
|
|
15
|
+
|
|
16
|
+
> **0.x: beta, may change.** Minor versions can include breaking changes until 1.0.
|
|
17
|
+
|
|
18
|
+
## Authenticate
|
|
19
|
+
|
|
20
|
+
Create an API key in the Larynth dashboard and keep it in the environment. Never commit it.
|
|
21
|
+
|
|
22
|
+
```python
|
|
23
|
+
import os
|
|
24
|
+
|
|
25
|
+
from larynth import authenticated_client
|
|
26
|
+
|
|
27
|
+
client = authenticated_client(
|
|
28
|
+
api_key=os.environ["LARYNTH_API_KEY"],
|
|
29
|
+
base_url="https://api-us.larynth.com",
|
|
30
|
+
)
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Place a call
|
|
34
|
+
|
|
35
|
+
Every call needs an idempotency key; replays within 24 hours return the stored response.
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
import uuid
|
|
39
|
+
|
|
40
|
+
from larynth.generated.api.calls import create_call
|
|
41
|
+
from larynth.generated.models import CreateCallRequest
|
|
42
|
+
|
|
43
|
+
call = create_call.sync(
|
|
44
|
+
client=client,
|
|
45
|
+
body=CreateCallRequest(
|
|
46
|
+
assistant_id=uuid.UUID("00000000-0000-0000-0000-000000000000"),
|
|
47
|
+
from_e164="+14155550100",
|
|
48
|
+
to_e164="+14155550101",
|
|
49
|
+
purpose="informational",
|
|
50
|
+
),
|
|
51
|
+
idempotency_key=str(uuid.uuid4()),
|
|
52
|
+
)
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## List assistants
|
|
56
|
+
|
|
57
|
+
```python
|
|
58
|
+
from larynth.generated.api.assistants import list_assistants
|
|
59
|
+
|
|
60
|
+
assistants = list_assistants.sync(client=client)
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Verify a webhook signature
|
|
64
|
+
|
|
65
|
+
Pass the raw request body, not a re-serialized one.
|
|
66
|
+
|
|
67
|
+
```python
|
|
68
|
+
import os
|
|
69
|
+
|
|
70
|
+
from larynth import WebhookVerificationError, verify
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
def handle(headers: dict[str, str], raw_body: bytes) -> int:
|
|
74
|
+
try:
|
|
75
|
+
verify(os.environ["LARYNTH_WEBHOOK_SECRET"], headers, raw_body)
|
|
76
|
+
except WebhookVerificationError:
|
|
77
|
+
return 400
|
|
78
|
+
return 200
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
## About this repository
|
|
82
|
+
|
|
83
|
+
This SDK is generated from our OpenAPI spec (`openapi/openapi.json`, synced here on every API change), so generated files are overwritten on every sync. Open issues here; pull requests for docs and examples are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md) and [SECURITY.md](SECURITY.md).
|
|
84
|
+
|
|
85
|
+
MIT licensed.
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools==84.2.1"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "larynth"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Official Python SDK for the Larynth voice AI API and webhook signature verification"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
keywords = ["larynth", "voice", "ai", "telephony", "sdk", "webhooks"]
|
|
11
|
+
requires-python = ">=3.11"
|
|
12
|
+
license = "MIT"
|
|
13
|
+
classifiers = [
|
|
14
|
+
"Development Status :: 4 - Beta",
|
|
15
|
+
"Intended Audience :: Developers",
|
|
16
|
+
"Programming Language :: Python :: 3",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
"Programming Language :: Python :: 3.12",
|
|
19
|
+
"Programming Language :: Python :: 3.13",
|
|
20
|
+
"Programming Language :: Python :: 3.14",
|
|
21
|
+
"Typing :: Typed",
|
|
22
|
+
]
|
|
23
|
+
dependencies = [
|
|
24
|
+
"httpx>=0.27,<0.29",
|
|
25
|
+
"attrs>=23.2",
|
|
26
|
+
"python-dateutil>=2.8.2",
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
[project.urls]
|
|
30
|
+
Homepage = "https://docs.larynth.com/sdks/python"
|
|
31
|
+
Documentation = "https://docs.larynth.com/sdks/python"
|
|
32
|
+
Repository = "https://github.com/Larynth-Labs/larynth-python"
|
|
33
|
+
Issues = "https://github.com/Larynth-Labs/larynth-python/issues"
|
|
34
|
+
Changelog = "https://github.com/Larynth-Labs/larynth-python/blob/main/CHANGELOG.md"
|
|
35
|
+
|
|
36
|
+
[project.optional-dependencies]
|
|
37
|
+
test = ["pytest==8.4.2"]
|
|
38
|
+
|
|
39
|
+
[tool.setuptools.packages.find]
|
|
40
|
+
where = ["src"]
|
|
41
|
+
|
|
42
|
+
[tool.pytest.ini_options]
|
|
43
|
+
testpaths = ["tests"]
|
|
44
|
+
pythonpath = ["src"]
|
|
45
|
+
|
|
46
|
+
[tool.setuptools.package-data]
|
|
47
|
+
larynth = ["py.typed"]
|
larynth-0.1.0/setup.cfg
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
from .generated import AuthenticatedClient, Client
|
|
2
|
+
from .webhooks import (
|
|
3
|
+
DEFAULT_TOLERANCE_SECONDS,
|
|
4
|
+
SECRET_PREFIX,
|
|
5
|
+
WebhookVerificationError,
|
|
6
|
+
sign,
|
|
7
|
+
verify,
|
|
8
|
+
)
|
|
9
|
+
|
|
10
|
+
__all__ = [
|
|
11
|
+
"AuthenticatedClient",
|
|
12
|
+
"Client",
|
|
13
|
+
"DEFAULT_TOLERANCE_SECONDS",
|
|
14
|
+
"SECRET_PREFIX",
|
|
15
|
+
"WebhookVerificationError",
|
|
16
|
+
"authenticated_client",
|
|
17
|
+
"sign",
|
|
18
|
+
"verify",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def authenticated_client(api_key: str, base_url: str) -> AuthenticatedClient:
|
|
23
|
+
return AuthenticatedClient(base_url=base_url, token=api_key, raise_on_unexpected_status=True)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Contains methods for accessing the API"""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Contains endpoint functions for accessing the API"""
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ... import errors
|
|
7
|
+
from ...client import AuthenticatedClient, Client
|
|
8
|
+
from ...models.assistant import Assistant
|
|
9
|
+
from ...models.create_assistant_request import CreateAssistantRequest
|
|
10
|
+
from ...models.problem import Problem
|
|
11
|
+
from ...types import Response
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def _get_kwargs(
|
|
15
|
+
*,
|
|
16
|
+
body: CreateAssistantRequest,
|
|
17
|
+
) -> dict[str, Any]:
|
|
18
|
+
headers: dict[str, Any] = {}
|
|
19
|
+
|
|
20
|
+
_kwargs: dict[str, Any] = {
|
|
21
|
+
"method": "post",
|
|
22
|
+
"url": "/v1/assistants",
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
_kwargs["json"] = body.to_dict()
|
|
26
|
+
|
|
27
|
+
headers["Content-Type"] = "application/json"
|
|
28
|
+
|
|
29
|
+
_kwargs["headers"] = headers
|
|
30
|
+
return _kwargs
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def _parse_response(
|
|
34
|
+
*, client: AuthenticatedClient | Client, response: httpx.Response
|
|
35
|
+
) -> Assistant | Problem | None:
|
|
36
|
+
if response.status_code == 201:
|
|
37
|
+
response_201 = Assistant.from_dict(response.json())
|
|
38
|
+
|
|
39
|
+
return response_201
|
|
40
|
+
|
|
41
|
+
if response.status_code == 400:
|
|
42
|
+
response_400 = Problem.from_dict(response.json())
|
|
43
|
+
|
|
44
|
+
return response_400
|
|
45
|
+
|
|
46
|
+
if response.status_code == 401:
|
|
47
|
+
response_401 = Problem.from_dict(response.json())
|
|
48
|
+
|
|
49
|
+
return response_401
|
|
50
|
+
|
|
51
|
+
if response.status_code == 403:
|
|
52
|
+
response_403 = Problem.from_dict(response.json())
|
|
53
|
+
|
|
54
|
+
return response_403
|
|
55
|
+
|
|
56
|
+
if response.status_code == 409:
|
|
57
|
+
response_409 = Problem.from_dict(response.json())
|
|
58
|
+
|
|
59
|
+
return response_409
|
|
60
|
+
|
|
61
|
+
if response.status_code == 422:
|
|
62
|
+
response_422 = Problem.from_dict(response.json())
|
|
63
|
+
|
|
64
|
+
return response_422
|
|
65
|
+
|
|
66
|
+
if response.status_code == 429:
|
|
67
|
+
response_429 = Problem.from_dict(response.json())
|
|
68
|
+
|
|
69
|
+
return response_429
|
|
70
|
+
|
|
71
|
+
if response.status_code == 500:
|
|
72
|
+
response_500 = Problem.from_dict(response.json())
|
|
73
|
+
|
|
74
|
+
return response_500
|
|
75
|
+
|
|
76
|
+
if client.raise_on_unexpected_status:
|
|
77
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
78
|
+
else:
|
|
79
|
+
return None
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
def _build_response(
|
|
83
|
+
*, client: AuthenticatedClient | Client, response: httpx.Response
|
|
84
|
+
) -> Response[Assistant | Problem]:
|
|
85
|
+
return Response(
|
|
86
|
+
status_code=HTTPStatus(response.status_code),
|
|
87
|
+
content=response.content,
|
|
88
|
+
headers=response.headers,
|
|
89
|
+
parsed=_parse_response(client=client, response=response),
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
def sync_detailed(
|
|
94
|
+
*,
|
|
95
|
+
client: AuthenticatedClient,
|
|
96
|
+
body: CreateAssistantRequest,
|
|
97
|
+
) -> Response[Assistant | Problem]:
|
|
98
|
+
"""Create an assistant
|
|
99
|
+
|
|
100
|
+
Args:
|
|
101
|
+
body (CreateAssistantRequest):
|
|
102
|
+
|
|
103
|
+
Raises:
|
|
104
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
105
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
106
|
+
|
|
107
|
+
Returns:
|
|
108
|
+
Response[Assistant | Problem]
|
|
109
|
+
"""
|
|
110
|
+
|
|
111
|
+
kwargs = _get_kwargs(
|
|
112
|
+
body=body,
|
|
113
|
+
)
|
|
114
|
+
|
|
115
|
+
response = client.get_httpx_client().request(
|
|
116
|
+
**kwargs,
|
|
117
|
+
)
|
|
118
|
+
|
|
119
|
+
return _build_response(client=client, response=response)
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
def sync(
|
|
123
|
+
*,
|
|
124
|
+
client: AuthenticatedClient,
|
|
125
|
+
body: CreateAssistantRequest,
|
|
126
|
+
) -> Assistant | Problem | None:
|
|
127
|
+
"""Create an assistant
|
|
128
|
+
|
|
129
|
+
Args:
|
|
130
|
+
body (CreateAssistantRequest):
|
|
131
|
+
|
|
132
|
+
Raises:
|
|
133
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
134
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
135
|
+
|
|
136
|
+
Returns:
|
|
137
|
+
Assistant | Problem
|
|
138
|
+
"""
|
|
139
|
+
|
|
140
|
+
return sync_detailed(
|
|
141
|
+
client=client,
|
|
142
|
+
body=body,
|
|
143
|
+
).parsed
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
async def asyncio_detailed(
|
|
147
|
+
*,
|
|
148
|
+
client: AuthenticatedClient,
|
|
149
|
+
body: CreateAssistantRequest,
|
|
150
|
+
) -> Response[Assistant | Problem]:
|
|
151
|
+
"""Create an assistant
|
|
152
|
+
|
|
153
|
+
Args:
|
|
154
|
+
body (CreateAssistantRequest):
|
|
155
|
+
|
|
156
|
+
Raises:
|
|
157
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
158
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
159
|
+
|
|
160
|
+
Returns:
|
|
161
|
+
Response[Assistant | Problem]
|
|
162
|
+
"""
|
|
163
|
+
|
|
164
|
+
kwargs = _get_kwargs(
|
|
165
|
+
body=body,
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
response = await client.get_async_httpx_client().request(**kwargs)
|
|
169
|
+
|
|
170
|
+
return _build_response(client=client, response=response)
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
async def asyncio(
|
|
174
|
+
*,
|
|
175
|
+
client: AuthenticatedClient,
|
|
176
|
+
body: CreateAssistantRequest,
|
|
177
|
+
) -> Assistant | Problem | None:
|
|
178
|
+
"""Create an assistant
|
|
179
|
+
|
|
180
|
+
Args:
|
|
181
|
+
body (CreateAssistantRequest):
|
|
182
|
+
|
|
183
|
+
Raises:
|
|
184
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
185
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
186
|
+
|
|
187
|
+
Returns:
|
|
188
|
+
Assistant | Problem
|
|
189
|
+
"""
|
|
190
|
+
|
|
191
|
+
return (
|
|
192
|
+
await asyncio_detailed(
|
|
193
|
+
client=client,
|
|
194
|
+
body=body,
|
|
195
|
+
)
|
|
196
|
+
).parsed
|