@amigo-ai/platform-sdk 0.48.1 → 0.48.3

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.
@@ -23,32 +23,6 @@ export interface paths {
23
23
  patch?: never;
24
24
  trace?: never;
25
25
  };
26
- "/s/vcard/{workspace_slug}.vcf": {
27
- parameters: {
28
- query?: never;
29
- header?: never;
30
- path?: never;
31
- cookie?: never;
32
- };
33
- /**
34
- * Serve Vcard
35
- * @description Serve a vCard contact card for a workspace.
36
- *
37
- * Public, unauthenticated endpoint. iOS blocks clickable links in SMS
38
- * from unknown senders — sending a vCard first lets patients save the
39
- * number so subsequent SMS links render as tappable.
40
- *
41
- * Path: ``/s/vcard/{workspace_slug}.vcf``
42
- */
43
- get: operations["serve-vcard"];
44
- put?: never;
45
- post?: never;
46
- delete?: never;
47
- options?: never;
48
- head?: never;
49
- patch?: never;
50
- trace?: never;
51
- };
52
26
  "/s/{token}": {
53
27
  parameters: {
54
28
  query?: never;
@@ -6131,8 +6105,8 @@ export interface paths {
6131
6105
  get?: never;
6132
6106
  put?: never;
6133
6107
  /**
6134
- * Start a text conversation session with an entity
6135
- * @description Start an SMS, WhatsApp, or web text session with a world model entity. Resolves contact info from the entity, picks the workspace outbound number, and creates or resumes a conversation. Returns conversation_id for subsequent turns via POST /v1/{ws}/conversations/{id}/turns.
6108
+ * Start a web text conversation session with an entity
6109
+ * @description Start a web text session with a world model entity. Materializes the conversation and returns conversation_id for subsequent turns via POST /v1/{ws}/conversations/{id}/turns.
6136
6110
  */
6137
6111
  post: operations["start_text_session_v1__workspace_id__sessions_start_post"];
6138
6112
  delete?: never;
@@ -7475,9 +7449,12 @@ export interface paths {
7475
7449
  * Deliver Surface
7476
7450
  * @description Record a real delivery handoff for a surface.
7477
7451
  *
7478
- * Phone-number targets are delivered via SMS (SendBlue or Twilio).
7479
- * Email targets are delivered via Gmail API. Other targets record an
7480
- * external handoff that was completed outside platform-api.
7452
+ * Email targets are delivered through channel-manager's
7453
+ * ``POST /v1/email/send`` (CM owns SES sender identity, IP pool, DKIM,
7454
+ * suppression keyed on the surface row's ``use_case_id``). Phone-shaped
7455
+ * addresses return 422 — SMS surface delivery was removed in PR #2783.
7456
+ * Other targets record an external handoff that was completed outside
7457
+ * platform-api.
7481
7458
  *
7482
7459
  * Permissions: member, admin, owner (surfaces:write)
7483
7460
  */
@@ -10999,7 +10976,7 @@ export interface components {
10999
10976
  * Each kind maps to one or more providers.
11000
10977
  * @enum {string}
11001
10978
  */
11002
- ChannelKind: "voice" | "sms" | "whatsapp" | "imessage" | "email" | "web" | "scribe";
10979
+ ChannelKind: "voice" | "sms" | "whatsapp" | "email" | "web" | "scribe";
11003
10980
  /**
11004
10981
  * ChannelOverride
11005
10982
  * @description Per-channel behavior override for a state.
@@ -11019,7 +10996,7 @@ export interface components {
11019
10996
  * @description Delivery channels for surfaces.
11020
10997
  * @enum {string}
11021
10998
  */
11022
- ChannelType: "sms" | "whatsapp" | "imessage" | "email" | "voice" | "web";
10999
+ ChannelType: "email" | "web";
11023
11000
  /**
11024
11001
  * ChannelVoicemailStatusEvent
11025
11002
  * @description Ringless voicemail status callback projected from VoiceDrop. ``status``
@@ -12801,7 +12778,7 @@ export interface components {
12801
12778
  version_sets?: {
12802
12779
  [key: string]: components["schemas"]["VersionSet"];
12803
12780
  };
12804
- voice_config?: components["schemas"]["ServiceVoiceConfig"] | null;
12781
+ voice_config?: components["schemas"]["ServiceVoiceConfig-Input"] | null;
12805
12782
  };
12806
12783
  /** CreateSesSetupRequest */
12807
12784
  CreateSesSetupRequest: {
@@ -12963,6 +12940,8 @@ export interface components {
12963
12940
  /** Submit Button Text */
12964
12941
  submit_button_text?: string | null;
12965
12942
  title: components["schemas"]["NameString"];
12943
+ /** Use Case Id */
12944
+ use_case_id?: string | null;
12966
12945
  };
12967
12946
  /** CreateSurfaceResponse */
12968
12947
  CreateSurfaceResponse: {
@@ -12997,6 +12976,8 @@ export interface components {
12997
12976
  token?: string | null;
12998
12977
  /** Url */
12999
12978
  url?: string | null;
12979
+ /** Use Case Id */
12980
+ use_case_id?: string | null;
13000
12981
  };
13001
12982
  /** CreateToolRequest */
13002
12983
  CreateToolRequest: {
@@ -14704,6 +14685,7 @@ export interface components {
14704
14685
  name: string;
14705
14686
  /** Path */
14706
14687
  path: string;
14688
+ request_transform?: components["schemas"]["RequestTransform"] | null;
14707
14689
  /** Response Filter */
14708
14690
  response_filter?: string[] | null;
14709
14691
  /** Response Mapping */
@@ -14778,6 +14760,7 @@ export interface components {
14778
14760
  name: string;
14779
14761
  /** Path */
14780
14762
  path: string;
14763
+ request_transform?: components["schemas"]["RequestTransform"] | null;
14781
14764
  /** Response Filter */
14782
14765
  response_filter?: string[] | null;
14783
14766
  /** Response Mapping */
@@ -16776,16 +16759,16 @@ export interface components {
16776
16759
  };
16777
16760
  /**
16778
16761
  * ForwardAction
16779
- * @description Cold-transfer the caller to the inbound phone number's configured
16780
- * forwarding destination (set via `PUT /v1/{ws}/phone-numbers/{id}/forwarding`).
16762
+ * @description Cold-transfer the caller to the service's configured forwarding
16763
+ * destination (set via ``Service.voice_config.forwarding``).
16781
16764
  *
16782
16765
  * No agent-side decision and no operator dashboard required — the engine
16783
- * invokes the same forwarding callback used by the LLM-driven `forward_call`
16784
- * tool, with no location override, which falls through to the static
16785
- * `ForwardingMap` populated from the phone-number config.
16766
+ * invokes the same forwarding callback used by the LLM-driven
16767
+ * ``forward_call`` tool, with no location override, which falls through to
16768
+ * the per-service ``ServiceForwardingConfig``.
16786
16769
  *
16787
- * If forwarding is not configured for the inbound phone number, the
16788
- * dispatcher falls back to the operator path (audit event + SSE only).
16770
+ * If ``voice_config.forwarding`` is unset, the dispatcher falls back to the
16771
+ * operator path (audit event + SSE only).
16789
16772
  */
16790
16773
  ForwardAction: {
16791
16774
  /**
@@ -16825,6 +16808,12 @@ export interface components {
16825
16808
  /**
16826
16809
  * ForwardingConfigRequest
16827
16810
  * @description Call forwarding configuration for create/update requests.
16811
+ *
16812
+ * Deprecated: per-phone forwarding has moved to per-service config
16813
+ * (``Service.voice_config.forwarding``). The field is accepted for one
16814
+ * release for SDK backward-compat but is no longer read by the voice
16815
+ * agent at session time. Will be removed in a follow-up PR alongside
16816
+ * the ``platform.phone_numbers`` table drop.
16828
16817
  */
16829
16818
  ForwardingConfigRequest: {
16830
16819
  /**
@@ -17079,7 +17068,7 @@ export interface components {
17079
17068
  * @description A named gap detection rule.
17080
17069
  */
17081
17070
  "GapRequirement-Input": {
17082
- /** @default sms */
17071
+ /** @default email */
17083
17072
  channel?: components["schemas"]["ChannelType"];
17084
17073
  /**
17085
17074
  * Entity Type
@@ -17111,7 +17100,7 @@ export interface components {
17111
17100
  * @description A named gap detection rule.
17112
17101
  */
17113
17102
  "GapRequirement-Output": {
17114
- /** @default sms */
17103
+ /** @default email */
17115
17104
  channel?: components["schemas"]["ChannelType"];
17116
17105
  /**
17117
17106
  * Entity Type
@@ -17637,21 +17626,6 @@ export interface components {
17637
17626
  */
17638
17627
  turn_taking_quality?: string | null;
17639
17628
  };
17640
- /**
17641
- * InternalForwardingResponse
17642
- * @description Resolved forwarding config for a phone number.
17643
- */
17644
- InternalForwardingResponse: {
17645
- /** Forward To */
17646
- forward_to: string;
17647
- /** Should Disconnect */
17648
- should_disconnect: boolean;
17649
- /**
17650
- * Warm Transfer
17651
- * @default true
17652
- */
17653
- warm_transfer?: boolean;
17654
- };
17655
17629
  /**
17656
17630
  * InternalIntegrationResponse
17657
17631
  * @description Wire format matching platform_lib.integrations.models.IntegrationConfig.
@@ -19713,7 +19687,7 @@ export interface components {
19713
19687
  * @default true
19714
19688
  */
19715
19689
  active?: boolean;
19716
- /** @default sms */
19690
+ /** @default email */
19717
19691
  channel?: components["schemas"]["ChannelType"];
19718
19692
  /**
19719
19693
  * Consent Required
@@ -21402,7 +21376,7 @@ export interface components {
21402
21376
  * Infobip both support SMS).
21403
21377
  * @enum {string}
21404
21378
  */
21405
- ProviderType: "twilio" | "infobip" | "sendblue" | "gmail" | "websocket";
21379
+ ProviderType: "twilio" | "infobip" | "websocket";
21406
21380
  /** ProvisionResponse */
21407
21381
  ProvisionResponse: {
21408
21382
  workspace: components["schemas"]["WorkspaceResponse"];
@@ -21533,7 +21507,7 @@ export interface components {
21533
21507
  };
21534
21508
  /**
21535
21509
  * QuietHours
21536
- * @description TCPA-compliant quiet hours — no outbound SMS during this window.
21510
+ * @description Quiet hours — no outbound outreach during this window.
21537
21511
  */
21538
21512
  QuietHours: {
21539
21513
  /**
@@ -21873,6 +21847,26 @@ export interface components {
21873
21847
  /** Type */
21874
21848
  type: string;
21875
21849
  };
21850
+ /**
21851
+ * RequestTransform
21852
+ * @description Transforms outbound request body before sending to the integration endpoint.
21853
+ *
21854
+ * Applied after path-param substitution and auth-header resolution, right
21855
+ * before the HTTP call. Mirror of the response-side pipeline
21856
+ * (``response_filter`` / ``result_key`` / ``result_template``).
21857
+ *
21858
+ * Inject targets the **outermost** dict: when combined with
21859
+ * ``wrap_params_key``, injected fields sit alongside the wrapper key,
21860
+ * never inside the wrapped sub-dict.
21861
+ */
21862
+ RequestTransform: {
21863
+ /** Inject */
21864
+ inject?: {
21865
+ [key: string]: string;
21866
+ };
21867
+ /** Wrap Params Key */
21868
+ wrap_params_key?: string | null;
21869
+ };
21876
21870
  /**
21877
21871
  * ResolveTemplateRequest
21878
21872
  * @description Resolve a form template for a specific entity.
@@ -22971,7 +22965,7 @@ export interface components {
22971
22965
  version_sets: {
22972
22966
  [key: string]: components["schemas"]["VersionSet"];
22973
22967
  };
22974
- voice_config?: components["schemas"]["ServiceVoiceConfig"] | null;
22968
+ voice_config?: components["schemas"]["ServiceVoiceConfig-Output"] | null;
22975
22969
  };
22976
22970
  /** ServiceBindingRequest */
22977
22971
  ServiceBindingRequest: {
@@ -23014,6 +23008,34 @@ export interface components {
23014
23008
  */
23015
23009
  workspace_id: string;
23016
23010
  };
23011
+ /**
23012
+ * ServiceForwardingConfig
23013
+ * @description Per-service call-forwarding destination + transfer mechanism.
23014
+ *
23015
+ * Read by:
23016
+ * - LLM-driven ``forward_call`` tool (tier 3 fallback when the LLM doesn't
23017
+ * pass an explicit ``phone_number`` and no EHR location is configured).
23018
+ * - ``EscalationPolicy.ForwardAction`` — engine-fired escalation with no
23019
+ * overrides falls through to the same path.
23020
+ *
23021
+ * Distinct from ``platform_lib.phone_numbers.ForwardingConfig`` (per-phone
23022
+ * legacy shape with ``enabled``); per-service forwarding is a binary
23023
+ * presence — set means tier 3 resolves to it, None means tier 3 has no
23024
+ * static target.
23025
+ */
23026
+ ServiceForwardingConfig: {
23027
+ forward_to: components["schemas"]["PhoneE164"];
23028
+ /**
23029
+ * Should Disconnect
23030
+ * @default true
23031
+ */
23032
+ should_disconnect?: boolean;
23033
+ /**
23034
+ * Warm Transfer
23035
+ * @default true
23036
+ */
23037
+ warm_transfer?: boolean;
23038
+ };
23017
23039
  /** ServiceResponse */
23018
23040
  ServiceResponse: {
23019
23041
  /**
@@ -23088,7 +23110,7 @@ export interface components {
23088
23110
  version_sets: {
23089
23111
  [key: string]: components["schemas"]["VersionSet"];
23090
23112
  };
23091
- voice_config?: components["schemas"]["ServiceVoiceConfig"] | null;
23113
+ voice_config?: components["schemas"]["ServiceVoiceConfig-Output"] | null;
23092
23114
  /**
23093
23115
  * Workspace Id
23094
23116
  * Format: uuid
@@ -23109,7 +23131,7 @@ export interface components {
23109
23131
  * Each field is optional — None means inherit from the layer above
23110
23132
  * (workspace VoiceSettings → env vars → hardcoded defaults).
23111
23133
  */
23112
- ServiceVoiceConfig: {
23134
+ "ServiceVoiceConfig-Input": {
23113
23135
  /**
23114
23136
  * Backchannel Delay Ms
23115
23137
  * @default 400
@@ -23140,6 +23162,75 @@ export interface components {
23140
23162
  * @default false
23141
23163
  */
23142
23164
  forward_call_enabled?: boolean;
23165
+ forwarding?: components["schemas"]["ServiceForwardingConfig"] | null;
23166
+ /** Language Providers */
23167
+ language_providers?: {
23168
+ [key: string]: components["schemas"]["LanguageProviderEntry"];
23169
+ } | null;
23170
+ /** Max Buffer Delay Ms */
23171
+ max_buffer_delay_ms?: number | null;
23172
+ /** Max Response Sentences */
23173
+ max_response_sentences?: number | null;
23174
+ /** Max Response Words */
23175
+ max_response_words?: number | null;
23176
+ /** Min Tts Speed */
23177
+ min_tts_speed?: number | null;
23178
+ /** Post Eot Pause Ms */
23179
+ post_eot_pause_ms?: number | null;
23180
+ /** Progress Interval Ms */
23181
+ progress_interval_ms?: number | null;
23182
+ /** Progress Vocabulary */
23183
+ progress_vocabulary?: string[] | null;
23184
+ /** Transition Deadline Ms */
23185
+ transition_deadline_ms?: number | null;
23186
+ /** Tts Config */
23187
+ tts_config?: {
23188
+ [key: string]: unknown;
23189
+ } | null;
23190
+ /** Tts Model */
23191
+ tts_model?: ("sonic-turbo" | "sonic-3") | null;
23192
+ /** Tts Provider */
23193
+ tts_provider?: ("cartesia" | "elevenlabs" | "groq") | null;
23194
+ };
23195
+ /**
23196
+ * ServiceVoiceConfig
23197
+ * @description Per-service voice pipeline tuning. Overrides workspace/env defaults.
23198
+ *
23199
+ * Each field is optional — None means inherit from the layer above
23200
+ * (workspace VoiceSettings → env vars → hardcoded defaults).
23201
+ */
23202
+ "ServiceVoiceConfig-Output": {
23203
+ /**
23204
+ * Backchannel Delay Ms
23205
+ * @default 400
23206
+ */
23207
+ backchannel_delay_ms?: number;
23208
+ /** Barge In Cooldown S */
23209
+ barge_in_cooldown_s?: number | null;
23210
+ /** Barge In Min Speech S */
23211
+ barge_in_min_speech_s?: number | null;
23212
+ /** Eager Eot Threshold */
23213
+ eager_eot_threshold?: number | null;
23214
+ /** Empathy Hold Ms */
23215
+ empathy_hold_ms?: number | null;
23216
+ /** Eot Timeout Ms */
23217
+ eot_timeout_ms?: number | null;
23218
+ /** Filler Cooldown Ms */
23219
+ filler_cooldown_ms?: number | null;
23220
+ /**
23221
+ * Filler Style
23222
+ * @default backchannel
23223
+ * @enum {string}
23224
+ */
23225
+ filler_style?: "backchannel" | "phrase" | "silent";
23226
+ /** Filler Vocabulary */
23227
+ filler_vocabulary?: string[] | null;
23228
+ /**
23229
+ * Forward Call Enabled
23230
+ * @default false
23231
+ */
23232
+ forward_call_enabled?: boolean;
23233
+ forwarding?: components["schemas"]["ServiceForwardingConfig"] | null;
23143
23234
  /** Language Providers */
23144
23235
  language_providers?: {
23145
23236
  [key: string]: components["schemas"]["LanguageProviderEntry"];
@@ -24439,9 +24530,9 @@ export interface components {
24439
24530
  canonical_id?: components["schemas"]["CanonicalIdString"] | null;
24440
24531
  /**
24441
24532
  * Channel Kind
24442
- * @enum {string}
24533
+ * @constant
24443
24534
  */
24444
- channel_kind: "sms" | "whatsapp" | "web";
24535
+ channel_kind: "web";
24445
24536
  /**
24446
24537
  * Entity Id
24447
24538
  * @description World model entity UUID. Provide either entity_id or canonical_id.
@@ -24452,31 +24543,19 @@ export interface components {
24452
24543
  * @description Custom greeting. Agent auto-greets if omitted.
24453
24544
  */
24454
24545
  greeting?: string | null;
24455
- /**
24456
- * Idempotency Key
24457
- * @description Client-provided idempotency key for SMS/WhatsApp.
24458
- */
24459
- idempotency_key?: string | null;
24460
- /** @description E.164 phone override for SMS/WhatsApp. Resolved from entity if omitted. */
24461
- phone_to?: components["schemas"]["PhoneE164"] | null;
24462
24546
  /**
24463
24547
  * Service Id
24464
24548
  * Format: uuid
24465
24549
  */
24466
24550
  service_id: string;
24467
- /**
24468
- * Surface Id
24469
- * @description Surface to deliver inline in the conversation.
24470
- */
24471
- surface_id?: string | null;
24472
24551
  };
24473
24552
  /** StartSessionResponse */
24474
24553
  StartSessionResponse: {
24475
24554
  /**
24476
24555
  * Channel Kind
24477
- * @enum {string}
24556
+ * @constant
24478
24557
  */
24479
- channel_kind: "sms" | "whatsapp" | "web";
24558
+ channel_kind: "web";
24480
24559
  /**
24481
24560
  * Conversation Id
24482
24561
  * Format: uuid
@@ -24489,10 +24568,6 @@ export interface components {
24489
24568
  * Format: uuid
24490
24569
  */
24491
24570
  entity_id: string;
24492
- /** Phone From */
24493
- phone_from?: string | null;
24494
- /** Phone To */
24495
- phone_to?: string | null;
24496
24571
  /**
24497
24572
  * Service Id
24498
24573
  * Format: uuid
@@ -25066,6 +25141,8 @@ export interface components {
25066
25141
  } | null;
25067
25142
  /** Title */
25068
25143
  title?: string | null;
25144
+ /** Use Case Id */
25145
+ use_case_id?: string | null;
25069
25146
  };
25070
25147
  /** SurfaceReviewApprovedEvent */
25071
25148
  SurfaceReviewApprovedEvent: {
@@ -25978,6 +26055,15 @@ export interface components {
25978
26055
  integration_name?: string | null;
25979
26056
  /** Output */
25980
26057
  output?: string | null;
26058
+ /** Output Original Length */
26059
+ output_original_length?: number | null;
26060
+ /**
26061
+ * Output Truncated
26062
+ * @default false
26063
+ */
26064
+ output_truncated?: boolean;
26065
+ /** Output Truncated To */
26066
+ output_truncated_to?: number | null;
25981
26067
  /** Protocol */
25982
26068
  protocol?: string | null;
25983
26069
  /**
@@ -27400,7 +27486,7 @@ export interface components {
27400
27486
  version_sets?: {
27401
27487
  [key: string]: components["schemas"]["VersionSet"];
27402
27488
  } | null;
27403
- voice_config?: components["schemas"]["ServiceVoiceConfig"] | null;
27489
+ voice_config?: components["schemas"]["ServiceVoiceConfig-Input"] | null;
27404
27490
  };
27405
27491
  /** UpdateSkillRequest */
27406
27492
  UpdateSkillRequest: {
@@ -29157,51 +29243,6 @@ export interface operations {
29157
29243
  };
29158
29244
  };
29159
29245
  };
29160
- "serve-vcard": {
29161
- parameters: {
29162
- query?: never;
29163
- header?: never;
29164
- path: {
29165
- workspace_slug: string;
29166
- };
29167
- cookie?: never;
29168
- };
29169
- requestBody?: never;
29170
- responses: {
29171
- /** @description Successful Response */
29172
- 200: {
29173
- headers: {
29174
- [name: string]: unknown;
29175
- };
29176
- content: {
29177
- "application/json": unknown;
29178
- };
29179
- };
29180
- /** @description Workspace or phone number not found */
29181
- 404: {
29182
- headers: {
29183
- [name: string]: unknown;
29184
- };
29185
- content?: never;
29186
- };
29187
- /** @description Validation Error */
29188
- 422: {
29189
- headers: {
29190
- [name: string]: unknown;
29191
- };
29192
- content: {
29193
- "application/json": components["schemas"]["HTTPValidationError"];
29194
- };
29195
- };
29196
- /** @description Rate limited */
29197
- 429: {
29198
- headers: {
29199
- [name: string]: unknown;
29200
- };
29201
- content?: never;
29202
- };
29203
- };
29204
- };
29205
29246
  "render-surface": {
29206
29247
  parameters: {
29207
29248
  query?: never;
@@ -43714,19 +43755,14 @@ export interface operations {
43714
43755
  };
43715
43756
  content?: never;
43716
43757
  };
43717
- /** @description No outbound-capable phone number in workspace. */
43718
- 409: {
43719
- headers: {
43720
- [name: string]: unknown;
43721
- };
43722
- content?: never;
43723
- };
43724
- /** @description Entity has no phone for SMS/WhatsApp channel. */
43758
+ /** @description Validation Error */
43725
43759
  422: {
43726
43760
  headers: {
43727
43761
  [name: string]: unknown;
43728
43762
  };
43729
- content?: never;
43763
+ content: {
43764
+ "application/json": components["schemas"]["HTTPValidationError"];
43765
+ };
43730
43766
  };
43731
43767
  /** @description Agent service unavailable. */
43732
43768
  503: {