@niadra/sdk 0.9.1 → 0.10.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.
Files changed (86) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/dist/ai-sdk.d.cts +3 -3
  3. package/dist/ai-sdk.d.ts +3 -3
  4. package/dist/anthropic.d.cts +4 -4
  5. package/dist/anthropic.d.ts +4 -4
  6. package/dist/bedrock.d.cts +4 -4
  7. package/dist/bedrock.d.ts +4 -4
  8. package/dist/cli.js +319 -96
  9. package/dist/cli.js.map +1 -1
  10. package/dist/{client-CWMxmJHs.d.cts → client-rmWhZJOx.d.cts} +190 -7
  11. package/dist/{client-CWMxmJHs.d.ts → client-rmWhZJOx.d.ts} +190 -7
  12. package/dist/cloudflare-agents.d.cts +3 -3
  13. package/dist/cloudflare-agents.d.ts +3 -3
  14. package/dist/elevenlabs.cjs +7 -5
  15. package/dist/elevenlabs.cjs.map +1 -1
  16. package/dist/elevenlabs.d.cts +5 -5
  17. package/dist/elevenlabs.d.ts +5 -5
  18. package/dist/elevenlabs.js +7 -5
  19. package/dist/elevenlabs.js.map +1 -1
  20. package/dist/genkit.d.cts +3 -3
  21. package/dist/genkit.d.ts +3 -3
  22. package/dist/google-adk.cjs +7 -5
  23. package/dist/google-adk.cjs.map +1 -1
  24. package/dist/google-adk.d.cts +3 -3
  25. package/dist/google-adk.d.ts +3 -3
  26. package/dist/google-adk.js +7 -5
  27. package/dist/google-adk.js.map +1 -1
  28. package/dist/google-genai.d.cts +4 -4
  29. package/dist/google-genai.d.ts +4 -4
  30. package/dist/index.cjs +329 -98
  31. package/dist/index.cjs.map +1 -1
  32. package/dist/index.d.cts +13 -5
  33. package/dist/index.d.ts +13 -5
  34. package/dist/index.js +329 -98
  35. package/dist/index.js.map +1 -1
  36. package/dist/{intercept-CGngQI8B.d.cts → intercept-C0XODsy9.d.cts} +1 -1
  37. package/dist/{intercept-Bv0nLpSw.d.ts → intercept-veMDudKV.d.ts} +1 -1
  38. package/dist/langchain.cjs.map +1 -1
  39. package/dist/langchain.d.cts +3 -3
  40. package/dist/langchain.d.ts +3 -3
  41. package/dist/langchain.js.map +1 -1
  42. package/dist/livekit.cjs +10 -2
  43. package/dist/livekit.cjs.map +1 -1
  44. package/dist/livekit.d.cts +3 -3
  45. package/dist/livekit.d.ts +3 -3
  46. package/dist/livekit.js +10 -2
  47. package/dist/livekit.js.map +1 -1
  48. package/dist/llamaindex.d.cts +3 -3
  49. package/dist/llamaindex.d.ts +3 -3
  50. package/dist/mastra.d.cts +3 -3
  51. package/dist/mastra.d.ts +3 -3
  52. package/dist/openai-agents.d.cts +3 -3
  53. package/dist/openai-agents.d.ts +3 -3
  54. package/dist/retell.cjs +7 -5
  55. package/dist/retell.cjs.map +1 -1
  56. package/dist/retell.d.cts +5 -5
  57. package/dist/retell.d.ts +5 -5
  58. package/dist/retell.js +7 -5
  59. package/dist/retell.js.map +1 -1
  60. package/dist/{shared-B4Ef2Wpg.d.ts → shared-Cs7h5C4Y.d.ts} +1 -1
  61. package/dist/{shared-Cq8mz-7m.d.cts → shared-zaTBum17.d.cts} +1 -1
  62. package/dist/strands.d.cts +3 -3
  63. package/dist/strands.d.ts +3 -3
  64. package/dist/twilio.cjs +10 -2
  65. package/dist/twilio.cjs.map +1 -1
  66. package/dist/twilio.d.cts +4 -4
  67. package/dist/twilio.d.ts +4 -4
  68. package/dist/twilio.js +10 -2
  69. package/dist/twilio.js.map +1 -1
  70. package/dist/vapi.cjs +7 -5
  71. package/dist/vapi.cjs.map +1 -1
  72. package/dist/vapi.d.cts +5 -5
  73. package/dist/vapi.d.ts +5 -5
  74. package/dist/vapi.js +7 -5
  75. package/dist/vapi.js.map +1 -1
  76. package/dist/voltagent.d.cts +3 -3
  77. package/dist/voltagent.d.ts +3 -3
  78. package/dist/{webhook-z2TjUzjv.d.ts → webhook-2V5QgnKI.d.ts} +1 -1
  79. package/dist/{webhook-jTx_SegV.d.cts → webhook-CX7nvQig.d.cts} +1 -1
  80. package/dist/whatsapp.cjs +10 -2
  81. package/dist/whatsapp.cjs.map +1 -1
  82. package/dist/whatsapp.d.cts +2 -2
  83. package/dist/whatsapp.d.ts +2 -2
  84. package/dist/whatsapp.js +10 -2
  85. package/dist/whatsapp.js.map +1 -1
  86. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -4,6 +4,65 @@ All notable changes to this package are documented here. The format follows [Kee
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.10.3] - 2026-10-03
8
+
9
+ ### Added
10
+
11
+ - `keepWarm` (on by default): while a conversation or task is open (created and not ended) and the client was
12
+ used in the last 10 minutes, the client sends `GET /healthz` every 100 s when nothing else went out for 90 s,
13
+ one attempt with a 2-second budget, so the connection to the region stays open. A turn after a long pause no
14
+ longer pays TCP, TLS and often DNS again. The pings are not the client's use, the timer is `unref()`'d, and a
15
+ conversation nobody holds any more stops them. `keepWarm: false` never pings.
16
+
17
+ ## [0.10.2] - 2026-10-03
18
+
19
+ ### Changed
20
+
21
+ - The client measures the round trip to the region once when it starts (`GET /healthz`, twice), not only for
22
+ voice, which also opens the connection the first read uses. `timeouts.context` and `timeouts.navigation` left
23
+ at their defaults take the measured round trip on top: from Sao Paulo (170 ms to us-east-2) every chat read
24
+ with the defaults ran out of time. A value you set stays a ceiling, and the client logs one warning when the
25
+ round trip plus 50 ms exceeds it. The voice budgets are unchanged, and their warnings now come only once the
26
+ client reads in voice. `voice: { probe: false }` measures nothing.
27
+
28
+ ## [0.10.1] - 2026-10-03
29
+
30
+ ### Added
31
+
32
+ - `contextUse({ since, until, group_by, source_id, channel, view, experiment_group })`: the context-use report
33
+ (`GET /v1/context-use`) as `ContextUseReport`, with its buckets typed and the other blocks passing through.
34
+ A key of an `analyst` source with the `analytics` scope reads every source of the space.
35
+ - `link({ person, organization, role })` and `endLink(linkId)`: a system of record that knows who works for whom
36
+ (a CRM, an HR system) links a person to the account or partner they act for, and ends the link, with a key
37
+ that has the `identity:link` scope instead of `admin`. `can_see_contacts` still needs `admin`. `Link` and
38
+ `LinkRequest` are the types.
39
+
40
+ ## [0.10.0] - 2026-10-03
41
+
42
+ ### Added
43
+
44
+ - `open(id, { about })`: with the person bound in `subject`, also an item of the organization they act for that
45
+ their view shows (the pack's account block). `tools()` bound with `about` passes it, so the kit reaches what
46
+ the pack shows.
47
+ - `about_unlinked` on `ContextResponse`, `SearchResponse` and `TimelineResponse`: `about` named an organization
48
+ with no active link to the subject, and the read went on with the subject's own memory. A conversation or a
49
+ task warns once through its `logger`.
50
+ - `explain(error)`: an API refusal for a log line, with its code, detail and request id. A coordination check
51
+ takes the client's `logger`, and `HistoryItemKind` includes `system_event`.
52
+
53
+ ### Changed
54
+
55
+ - An API error's `message` ends with the request id: `422 invalid_input: <detail> (request <id>)`.
56
+ - `govIdHmac` and `orgRegistryHmac` take the document number itself; the space keeps only a keyed hash of it.
57
+ - Idle connections are kept for `keepAliveMs` between turns, and a call that has to open a connection gets
58
+ `timeouts.connect` (1,000 ms by default) on top of its method's budget, once per cold period, so a first read
59
+ after idle no longer times out on the TLS handshake.
60
+ - A coordination check the API refuses (400, 401, 403 or 422) is `invalid_request`, never `unchecked`: an
61
+ outbound contact is deferred and an inbound one allowed, and `strict` throws. Refusals of background writes
62
+ (the outbox, turn records) log the problem's detail and request id.
63
+ - The tool definitions follow the server's: the timeline tool says it also lists the open items, facts,
64
+ patterns or objects `filters.item_kinds` names.
65
+
7
66
  ## [0.9.1] - 2026-10-02
8
67
 
9
68
  ### Changed
package/dist/ai-sdk.d.cts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { ToolSet } from 'ai';
2
- import { f as ModelUsage, fZ as TurnParams, fS as TurnFrame } from './client-CWMxmJHs.cjs';
3
- import { a as ProofSource, A as AgentMemoryOption, b as Session, S as SessionResolver } from './shared-Cq8mz-7m.cjs';
4
- export { P as Proof, c as attestationProof } from './shared-Cq8mz-7m.cjs';
2
+ import { f as ModelUsage, g5 as TurnParams, f_ as TurnFrame } from './client-rmWhZJOx.cjs';
3
+ import { a as ProofSource, A as AgentMemoryOption, b as Session, S as SessionResolver } from './shared-zaTBum17.cjs';
4
+ export { P as Proof, c as attestationProof } from './shared-zaTBum17.cjs';
5
5
 
6
6
  /**
7
7
  * Niadra for the Vercel AI SDK (`ai` 5, 6 and 7), the idiomatic way: a language model middleware
package/dist/ai-sdk.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { ToolSet } from 'ai';
2
- import { f as ModelUsage, fZ as TurnParams, fS as TurnFrame } from './client-CWMxmJHs.js';
3
- import { a as ProofSource, A as AgentMemoryOption, b as Session, S as SessionResolver } from './shared-B4Ef2Wpg.js';
4
- export { P as Proof, c as attestationProof } from './shared-B4Ef2Wpg.js';
2
+ import { f as ModelUsage, g5 as TurnParams, f_ as TurnFrame } from './client-rmWhZJOx.js';
3
+ import { a as ProofSource, A as AgentMemoryOption, b as Session, S as SessionResolver } from './shared-Cs7h5C4Y.js';
4
+ export { P as Proof, c as attestationProof } from './shared-Cs7h5C4Y.js';
5
5
 
6
6
  /**
7
7
  * Niadra for the Vercel AI SDK (`ai` 5, 6 and 7), the idiomatic way: a language model middleware
@@ -1,7 +1,7 @@
1
- import { W as WrapOptions } from './intercept-CGngQI8B.cjs';
2
- import { S as SessionResolver } from './shared-Cq8mz-7m.cjs';
3
- export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-Cq8mz-7m.cjs';
4
- import './client-CWMxmJHs.cjs';
1
+ import { W as WrapOptions } from './intercept-C0XODsy9.cjs';
2
+ import { S as SessionResolver } from './shared-zaTBum17.cjs';
3
+ export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-zaTBum17.cjs';
4
+ import './client-rmWhZJOx.cjs';
5
5
 
6
6
  /**
7
7
  * Niadra for the Anthropic TypeScript SDK (`@anthropic-ai/sdk`), as `wrap()` is for OpenAI.
@@ -1,7 +1,7 @@
1
- import { W as WrapOptions } from './intercept-Bv0nLpSw.js';
2
- import { S as SessionResolver } from './shared-B4Ef2Wpg.js';
3
- export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-B4Ef2Wpg.js';
4
- import './client-CWMxmJHs.js';
1
+ import { W as WrapOptions } from './intercept-veMDudKV.js';
2
+ import { S as SessionResolver } from './shared-Cs7h5C4Y.js';
3
+ export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-Cs7h5C4Y.js';
4
+ import './client-rmWhZJOx.js';
5
5
 
6
6
  /**
7
7
  * Niadra for the Anthropic TypeScript SDK (`@anthropic-ai/sdk`), as `wrap()` is for OpenAI.
@@ -1,7 +1,7 @@
1
- import { f as ModelUsage } from './client-CWMxmJHs.cjs';
2
- import { W as WrapOptions } from './intercept-CGngQI8B.cjs';
3
- import { S as SessionResolver } from './shared-Cq8mz-7m.cjs';
4
- export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-Cq8mz-7m.cjs';
1
+ import { f as ModelUsage } from './client-rmWhZJOx.cjs';
2
+ import { W as WrapOptions } from './intercept-C0XODsy9.cjs';
3
+ import { S as SessionResolver } from './shared-zaTBum17.cjs';
4
+ export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-zaTBum17.cjs';
5
5
 
6
6
  /**
7
7
  * Niadra for Amazon Bedrock's Converse API (`@aws-sdk/client-bedrock-runtime`), as `wrap()` is for
package/dist/bedrock.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { f as ModelUsage } from './client-CWMxmJHs.js';
2
- import { W as WrapOptions } from './intercept-Bv0nLpSw.js';
3
- import { S as SessionResolver } from './shared-B4Ef2Wpg.js';
4
- export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-B4Ef2Wpg.js';
1
+ import { f as ModelUsage } from './client-rmWhZJOx.js';
2
+ import { W as WrapOptions } from './intercept-veMDudKV.js';
3
+ import { S as SessionResolver } from './shared-Cs7h5C4Y.js';
4
+ export { A as AgentMemoryOption, P as Proof, a as ProofSource, b as Session, c as attestationProof } from './shared-Cs7h5C4Y.js';
5
5
 
6
6
  /**
7
7
  * Niadra for Amazon Bedrock's Converse API (`@aws-sdk/client-bedrock-runtime`), as `wrap()` is for