@anthropic-ai/sdk 0.94.0 → 0.95.1
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.
- package/CHANGELOG.md +21 -0
- package/bin/migration-config.json +185 -0
- package/client.d.mts +7 -4
- package/client.d.mts.map +1 -1
- package/client.d.ts +7 -4
- package/client.d.ts.map +1 -1
- package/client.js +5 -4
- package/client.js.map +1 -1
- package/client.mjs +5 -4
- package/client.mjs.map +1 -1
- package/core/streaming.d.mts.map +1 -1
- package/core/streaming.d.ts.map +1 -1
- package/core/streaming.js +15 -1
- package/core/streaming.js.map +1 -1
- package/core/streaming.mjs +15 -1
- package/core/streaming.mjs.map +1 -1
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +7 -0
- package/internal/qs/formats.d.ts.map +1 -0
- package/internal/qs/formats.js +13 -0
- package/internal/qs/formats.js.map +1 -0
- package/internal/qs/formats.mjs +9 -0
- package/internal/qs/formats.mjs.map +1 -0
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts +10 -0
- package/internal/qs/index.d.ts.map +1 -0
- package/internal/qs/index.js +14 -0
- package/internal/qs/index.js.map +1 -0
- package/internal/qs/index.mjs +10 -0
- package/internal/qs/index.mjs.map +1 -0
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts +3 -0
- package/internal/qs/stringify.d.ts.map +1 -0
- package/internal/qs/stringify.js +277 -0
- package/internal/qs/stringify.js.map +1 -0
- package/internal/qs/stringify.mjs +274 -0
- package/internal/qs/stringify.mjs.map +1 -0
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/types.d.ts +57 -0
- package/internal/qs/types.d.ts.map +1 -0
- package/internal/qs/types.js +3 -0
- package/internal/qs/types.js.map +1 -0
- package/internal/qs/types.mjs +2 -0
- package/internal/qs/types.mjs.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +15 -0
- package/internal/qs/utils.d.ts.map +1 -0
- package/internal/qs/utils.js +230 -0
- package/internal/qs/utils.js.map +1 -0
- package/internal/qs/utils.mjs +217 -0
- package/internal/qs/utils.mjs.map +1 -0
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +3 -2
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +3 -2
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/query.d.mts +0 -3
- package/internal/utils/query.d.mts.map +1 -1
- package/internal/utils/query.d.ts +0 -3
- package/internal/utils/query.d.ts.map +1 -1
- package/internal/utils/query.js +3 -16
- package/internal/utils/query.js.map +1 -1
- package/internal/utils/query.mjs +2 -16
- package/internal/utils/query.mjs.map +1 -1
- package/package.json +2 -1
- package/resources/beta/agents/agents.d.mts +60 -1
- package/resources/beta/agents/agents.d.mts.map +1 -1
- package/resources/beta/agents/agents.d.ts +60 -1
- package/resources/beta/agents/agents.d.ts.map +1 -1
- package/resources/beta/agents/agents.js.map +1 -1
- package/resources/beta/agents/agents.mjs.map +1 -1
- package/resources/beta/agents/index.d.mts +1 -1
- package/resources/beta/agents/index.d.mts.map +1 -1
- package/resources/beta/agents/index.d.ts +1 -1
- package/resources/beta/agents/index.d.ts.map +1 -1
- package/resources/beta/agents/index.js.map +1 -1
- package/resources/beta/agents/index.mjs.map +1 -1
- package/resources/beta/beta.d.mts +9 -5
- package/resources/beta/beta.d.mts.map +1 -1
- package/resources/beta/beta.d.ts +9 -5
- package/resources/beta/beta.d.ts.map +1 -1
- package/resources/beta/beta.js +4 -0
- package/resources/beta/beta.js.map +1 -1
- package/resources/beta/beta.mjs +4 -0
- package/resources/beta/beta.mjs.map +1 -1
- package/resources/beta/index.d.mts +3 -2
- package/resources/beta/index.d.mts.map +1 -1
- package/resources/beta/index.d.ts +3 -2
- package/resources/beta/index.d.ts.map +1 -1
- package/resources/beta/index.js +3 -1
- package/resources/beta/index.js.map +1 -1
- package/resources/beta/index.mjs +1 -0
- package/resources/beta/index.mjs.map +1 -1
- package/resources/beta/messages/messages.d.mts +88 -0
- package/resources/beta/messages/messages.d.mts.map +1 -1
- package/resources/beta/messages/messages.d.ts +88 -0
- package/resources/beta/messages/messages.d.ts.map +1 -1
- package/resources/beta/messages/messages.js.map +1 -1
- package/resources/beta/messages/messages.mjs.map +1 -1
- package/resources/beta/sessions/events.d.mts +436 -5
- package/resources/beta/sessions/events.d.mts.map +1 -1
- package/resources/beta/sessions/events.d.ts +436 -5
- package/resources/beta/sessions/events.d.ts.map +1 -1
- package/resources/beta/sessions/index.d.mts +3 -2
- package/resources/beta/sessions/index.d.mts.map +1 -1
- package/resources/beta/sessions/index.d.ts +3 -2
- package/resources/beta/sessions/index.d.ts.map +1 -1
- package/resources/beta/sessions/index.js +3 -1
- package/resources/beta/sessions/index.js.map +1 -1
- package/resources/beta/sessions/index.mjs +1 -0
- package/resources/beta/sessions/index.mjs.map +1 -1
- package/resources/beta/sessions/sessions.d.mts +99 -3
- package/resources/beta/sessions/sessions.d.mts.map +1 -1
- package/resources/beta/sessions/sessions.d.ts +99 -3
- package/resources/beta/sessions/sessions.d.ts.map +1 -1
- package/resources/beta/sessions/sessions.js +4 -0
- package/resources/beta/sessions/sessions.js.map +1 -1
- package/resources/beta/sessions/sessions.mjs +4 -0
- package/resources/beta/sessions/sessions.mjs.map +1 -1
- package/resources/beta/sessions/threads/events.d.mts +64 -0
- package/resources/beta/sessions/threads/events.d.mts.map +1 -0
- package/resources/beta/sessions/threads/events.d.ts +64 -0
- package/resources/beta/sessions/threads/events.d.ts.map +1 -0
- package/resources/beta/sessions/threads/events.js +60 -0
- package/resources/beta/sessions/threads/events.js.map +1 -0
- package/resources/beta/sessions/threads/events.mjs +56 -0
- package/resources/beta/sessions/threads/events.mjs.map +1 -0
- package/resources/beta/sessions/threads/index.d.mts +3 -0
- package/resources/beta/sessions/threads/index.d.mts.map +1 -0
- package/resources/beta/sessions/threads/index.d.ts +3 -0
- package/resources/beta/sessions/threads/index.d.ts.map +1 -0
- package/resources/beta/sessions/threads/index.js +9 -0
- package/resources/beta/sessions/threads/index.js.map +1 -0
- package/resources/beta/sessions/threads/index.mjs +4 -0
- package/resources/beta/sessions/threads/index.mjs.map +1 -0
- package/resources/beta/sessions/threads/threads.d.mts +203 -0
- package/resources/beta/sessions/threads/threads.d.mts.map +1 -0
- package/resources/beta/sessions/threads/threads.d.ts +203 -0
- package/resources/beta/sessions/threads/threads.d.ts.map +1 -0
- package/resources/beta/sessions/threads/threads.js +88 -0
- package/resources/beta/sessions/threads/threads.js.map +1 -0
- package/resources/beta/sessions/threads/threads.mjs +83 -0
- package/resources/beta/sessions/threads/threads.mjs.map +1 -0
- package/resources/beta/sessions/threads.d.mts +2 -0
- package/resources/beta/sessions/threads.d.mts.map +1 -0
- package/resources/beta/sessions/threads.d.ts +2 -0
- package/resources/beta/sessions/threads.d.ts.map +1 -0
- package/resources/beta/sessions/threads.js +6 -0
- package/resources/beta/sessions/threads.js.map +1 -0
- package/resources/beta/sessions/threads.mjs +3 -0
- package/resources/beta/sessions/threads.mjs.map +1 -0
- package/resources/beta/user-profiles.d.mts +36 -0
- package/resources/beta/user-profiles.d.mts.map +1 -1
- package/resources/beta/user-profiles.d.ts +36 -0
- package/resources/beta/user-profiles.d.ts.map +1 -1
- package/resources/beta/vaults/credentials.d.mts +109 -1
- package/resources/beta/vaults/credentials.d.mts.map +1 -1
- package/resources/beta/vaults/credentials.d.ts +109 -1
- package/resources/beta/vaults/credentials.d.ts.map +1 -1
- package/resources/beta/vaults/credentials.js +22 -0
- package/resources/beta/vaults/credentials.js.map +1 -1
- package/resources/beta/vaults/credentials.mjs +22 -0
- package/resources/beta/vaults/credentials.mjs.map +1 -1
- package/resources/beta/vaults/index.d.mts +1 -1
- package/resources/beta/vaults/index.d.mts.map +1 -1
- package/resources/beta/vaults/index.d.ts +1 -1
- package/resources/beta/vaults/index.d.ts.map +1 -1
- package/resources/beta/vaults/index.js.map +1 -1
- package/resources/beta/vaults/index.mjs.map +1 -1
- package/resources/beta/vaults/vaults.d.mts +2 -2
- package/resources/beta/vaults/vaults.d.mts.map +1 -1
- package/resources/beta/vaults/vaults.d.ts +2 -2
- package/resources/beta/vaults/vaults.d.ts.map +1 -1
- package/resources/beta/vaults/vaults.js.map +1 -1
- package/resources/beta/vaults/vaults.mjs.map +1 -1
- package/resources/beta/webhooks.d.mts +256 -0
- package/resources/beta/webhooks.d.mts.map +1 -0
- package/resources/beta/webhooks.d.ts +256 -0
- package/resources/beta/webhooks.d.ts.map +1 -0
- package/resources/beta/webhooks.js +20 -0
- package/resources/beta/webhooks.js.map +1 -0
- package/resources/beta/webhooks.mjs +16 -0
- package/resources/beta/webhooks.mjs.map +1 -0
- package/resources/messages/messages.d.mts +88 -0
- package/resources/messages/messages.d.mts.map +1 -1
- package/resources/messages/messages.d.ts +88 -0
- package/resources/messages/messages.d.ts.map +1 -1
- package/resources/messages/messages.js.map +1 -1
- package/resources/messages/messages.mjs.map +1 -1
- package/src/client.ts +17 -4
- package/src/core/streaming.ts +15 -1
- package/src/internal/qs/LICENSE.md +13 -0
- package/src/internal/qs/README.md +3 -0
- package/src/internal/qs/formats.ts +10 -0
- package/src/internal/qs/index.ts +13 -0
- package/src/internal/qs/stringify.ts +385 -0
- package/src/internal/qs/types.ts +71 -0
- package/src/internal/qs/utils.ts +265 -0
- package/src/internal/utils/log.ts +2 -1
- package/src/internal/utils/query.ts +2 -18
- package/src/resources/beta/agents/agents.ts +74 -0
- package/src/resources/beta/agents/index.ts +4 -0
- package/src/resources/beta/beta.ts +80 -1
- package/src/resources/beta/index.ts +37 -0
- package/src/resources/beta/messages/messages.ts +88 -0
- package/src/resources/beta/sessions/events.ts +565 -3
- package/src/resources/beta/sessions/index.ts +34 -0
- package/src/resources/beta/sessions/sessions.ts +179 -0
- package/src/resources/beta/sessions/threads/events.ts +107 -0
- package/src/resources/beta/sessions/threads/index.ts +16 -0
- package/src/resources/beta/sessions/threads/threads.ts +344 -0
- package/src/resources/beta/sessions/threads.ts +3 -0
- package/src/resources/beta/user-profiles.ts +42 -0
- package/src/resources/beta/vaults/credentials.ts +150 -0
- package/src/resources/beta/vaults/index.ts +6 -0
- package/src/resources/beta/vaults/vaults.ts +12 -0
- package/src/resources/beta/webhooks.ts +417 -0
- package/src/resources/messages/messages.ts +88 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -0,0 +1,417 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
|
+
import { Webhook } from 'standardwebhooks';
|
|
5
|
+
|
|
6
|
+
export class Webhooks extends APIResource {
|
|
7
|
+
unwrap(
|
|
8
|
+
body: string,
|
|
9
|
+
{ headers, key }: { headers: Record<string, string>; key?: string },
|
|
10
|
+
): UnwrapWebhookEvent {
|
|
11
|
+
if (headers !== undefined) {
|
|
12
|
+
const keyStr: string | null = key === undefined ? this._client.webhookKey : key;
|
|
13
|
+
if (keyStr === null) throw new Error('Webhook key must not be null in order to unwrap');
|
|
14
|
+
const wh = new Webhook(keyStr);
|
|
15
|
+
wh.verify(body, headers);
|
|
16
|
+
}
|
|
17
|
+
return JSON.parse(body) as UnwrapWebhookEvent;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface BetaWebhookEvent {
|
|
22
|
+
/**
|
|
23
|
+
* Unique event identifier for idempotency.
|
|
24
|
+
*/
|
|
25
|
+
id: string;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* RFC 3339 timestamp when the event occurred.
|
|
29
|
+
*/
|
|
30
|
+
created_at: string;
|
|
31
|
+
|
|
32
|
+
data: BetaWebhookEventData;
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Object type. Always `event` for webhook payloads.
|
|
36
|
+
*/
|
|
37
|
+
type: 'event';
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export type BetaWebhookEventData =
|
|
41
|
+
| BetaWebhookSessionCreatedEventData
|
|
42
|
+
| BetaWebhookSessionPendingEventData
|
|
43
|
+
| BetaWebhookSessionRunningEventData
|
|
44
|
+
| BetaWebhookSessionIdledEventData
|
|
45
|
+
| BetaWebhookSessionRequiresActionEventData
|
|
46
|
+
| BetaWebhookSessionArchivedEventData
|
|
47
|
+
| BetaWebhookSessionDeletedEventData
|
|
48
|
+
| BetaWebhookSessionStatusRescheduledEventData
|
|
49
|
+
| BetaWebhookSessionStatusRunStartedEventData
|
|
50
|
+
| BetaWebhookSessionStatusIdledEventData
|
|
51
|
+
| BetaWebhookSessionStatusTerminatedEventData
|
|
52
|
+
| BetaWebhookSessionThreadCreatedEventData
|
|
53
|
+
| BetaWebhookSessionThreadIdledEventData
|
|
54
|
+
| BetaWebhookSessionThreadTerminatedEventData
|
|
55
|
+
| BetaWebhookSessionOutcomeEvaluationEndedEventData
|
|
56
|
+
| BetaWebhookVaultCreatedEventData
|
|
57
|
+
| BetaWebhookVaultArchivedEventData
|
|
58
|
+
| BetaWebhookVaultDeletedEventData
|
|
59
|
+
| BetaWebhookVaultCredentialCreatedEventData
|
|
60
|
+
| BetaWebhookVaultCredentialArchivedEventData
|
|
61
|
+
| BetaWebhookVaultCredentialDeletedEventData
|
|
62
|
+
| BetaWebhookVaultCredentialRefreshFailedEventData;
|
|
63
|
+
|
|
64
|
+
export interface BetaWebhookSessionArchivedEventData {
|
|
65
|
+
/**
|
|
66
|
+
* ID of the resource that triggered the event.
|
|
67
|
+
*/
|
|
68
|
+
id: string;
|
|
69
|
+
|
|
70
|
+
organization_id: string;
|
|
71
|
+
|
|
72
|
+
type: 'session.archived';
|
|
73
|
+
|
|
74
|
+
workspace_id: string;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export interface BetaWebhookSessionCreatedEventData {
|
|
78
|
+
/**
|
|
79
|
+
* ID of the resource that triggered the event.
|
|
80
|
+
*/
|
|
81
|
+
id: string;
|
|
82
|
+
|
|
83
|
+
organization_id: string;
|
|
84
|
+
|
|
85
|
+
type: 'session.created';
|
|
86
|
+
|
|
87
|
+
workspace_id: string;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export interface BetaWebhookSessionDeletedEventData {
|
|
91
|
+
/**
|
|
92
|
+
* ID of the resource that triggered the event.
|
|
93
|
+
*/
|
|
94
|
+
id: string;
|
|
95
|
+
|
|
96
|
+
organization_id: string;
|
|
97
|
+
|
|
98
|
+
type: 'session.deleted';
|
|
99
|
+
|
|
100
|
+
workspace_id: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export interface BetaWebhookSessionIdledEventData {
|
|
104
|
+
/**
|
|
105
|
+
* ID of the resource that triggered the event.
|
|
106
|
+
*/
|
|
107
|
+
id: string;
|
|
108
|
+
|
|
109
|
+
organization_id: string;
|
|
110
|
+
|
|
111
|
+
type: 'session.idled';
|
|
112
|
+
|
|
113
|
+
workspace_id: string;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export interface BetaWebhookSessionOutcomeEvaluationEndedEventData {
|
|
117
|
+
/**
|
|
118
|
+
* ID of the resource that triggered the event.
|
|
119
|
+
*/
|
|
120
|
+
id: string;
|
|
121
|
+
|
|
122
|
+
organization_id: string;
|
|
123
|
+
|
|
124
|
+
type: 'session.outcome_evaluation_ended';
|
|
125
|
+
|
|
126
|
+
workspace_id: string;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
export interface BetaWebhookSessionPendingEventData {
|
|
130
|
+
/**
|
|
131
|
+
* ID of the resource that triggered the event.
|
|
132
|
+
*/
|
|
133
|
+
id: string;
|
|
134
|
+
|
|
135
|
+
organization_id: string;
|
|
136
|
+
|
|
137
|
+
type: 'session.pending';
|
|
138
|
+
|
|
139
|
+
workspace_id: string;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
export interface BetaWebhookSessionRequiresActionEventData {
|
|
143
|
+
/**
|
|
144
|
+
* ID of the resource that triggered the event.
|
|
145
|
+
*/
|
|
146
|
+
id: string;
|
|
147
|
+
|
|
148
|
+
organization_id: string;
|
|
149
|
+
|
|
150
|
+
type: 'session.requires_action';
|
|
151
|
+
|
|
152
|
+
workspace_id: string;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
export interface BetaWebhookSessionRunningEventData {
|
|
156
|
+
/**
|
|
157
|
+
* ID of the resource that triggered the event.
|
|
158
|
+
*/
|
|
159
|
+
id: string;
|
|
160
|
+
|
|
161
|
+
organization_id: string;
|
|
162
|
+
|
|
163
|
+
type: 'session.running';
|
|
164
|
+
|
|
165
|
+
workspace_id: string;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
export interface BetaWebhookSessionStatusIdledEventData {
|
|
169
|
+
/**
|
|
170
|
+
* ID of the resource that triggered the event.
|
|
171
|
+
*/
|
|
172
|
+
id: string;
|
|
173
|
+
|
|
174
|
+
organization_id: string;
|
|
175
|
+
|
|
176
|
+
type: 'session.status_idled';
|
|
177
|
+
|
|
178
|
+
workspace_id: string;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export interface BetaWebhookSessionStatusRescheduledEventData {
|
|
182
|
+
/**
|
|
183
|
+
* ID of the resource that triggered the event.
|
|
184
|
+
*/
|
|
185
|
+
id: string;
|
|
186
|
+
|
|
187
|
+
organization_id: string;
|
|
188
|
+
|
|
189
|
+
type: 'session.status_rescheduled';
|
|
190
|
+
|
|
191
|
+
workspace_id: string;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
export interface BetaWebhookSessionStatusRunStartedEventData {
|
|
195
|
+
/**
|
|
196
|
+
* ID of the resource that triggered the event.
|
|
197
|
+
*/
|
|
198
|
+
id: string;
|
|
199
|
+
|
|
200
|
+
organization_id: string;
|
|
201
|
+
|
|
202
|
+
type: 'session.status_run_started';
|
|
203
|
+
|
|
204
|
+
workspace_id: string;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export interface BetaWebhookSessionStatusTerminatedEventData {
|
|
208
|
+
/**
|
|
209
|
+
* ID of the resource that triggered the event.
|
|
210
|
+
*/
|
|
211
|
+
id: string;
|
|
212
|
+
|
|
213
|
+
organization_id: string;
|
|
214
|
+
|
|
215
|
+
type: 'session.status_terminated';
|
|
216
|
+
|
|
217
|
+
workspace_id: string;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
export interface BetaWebhookSessionThreadCreatedEventData {
|
|
221
|
+
/**
|
|
222
|
+
* ID of the resource that triggered the event.
|
|
223
|
+
*/
|
|
224
|
+
id: string;
|
|
225
|
+
|
|
226
|
+
organization_id: string;
|
|
227
|
+
|
|
228
|
+
type: 'session.thread_created';
|
|
229
|
+
|
|
230
|
+
workspace_id: string;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
export interface BetaWebhookSessionThreadIdledEventData {
|
|
234
|
+
/**
|
|
235
|
+
* ID of the resource that triggered the event.
|
|
236
|
+
*/
|
|
237
|
+
id: string;
|
|
238
|
+
|
|
239
|
+
organization_id: string;
|
|
240
|
+
|
|
241
|
+
type: 'session.thread_idled';
|
|
242
|
+
|
|
243
|
+
workspace_id: string;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
export interface BetaWebhookSessionThreadTerminatedEventData {
|
|
247
|
+
/**
|
|
248
|
+
* ID of the resource that triggered the event.
|
|
249
|
+
*/
|
|
250
|
+
id: string;
|
|
251
|
+
|
|
252
|
+
organization_id: string;
|
|
253
|
+
|
|
254
|
+
type: 'session.thread_terminated';
|
|
255
|
+
|
|
256
|
+
workspace_id: string;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
export interface BetaWebhookVaultArchivedEventData {
|
|
260
|
+
/**
|
|
261
|
+
* ID of the resource that triggered the event.
|
|
262
|
+
*/
|
|
263
|
+
id: string;
|
|
264
|
+
|
|
265
|
+
organization_id: string;
|
|
266
|
+
|
|
267
|
+
type: 'vault.archived';
|
|
268
|
+
|
|
269
|
+
workspace_id: string;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
export interface BetaWebhookVaultCreatedEventData {
|
|
273
|
+
/**
|
|
274
|
+
* ID of the resource that triggered the event.
|
|
275
|
+
*/
|
|
276
|
+
id: string;
|
|
277
|
+
|
|
278
|
+
organization_id: string;
|
|
279
|
+
|
|
280
|
+
type: 'vault.created';
|
|
281
|
+
|
|
282
|
+
workspace_id: string;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
export interface BetaWebhookVaultCredentialArchivedEventData {
|
|
286
|
+
/**
|
|
287
|
+
* ID of the resource that triggered the event.
|
|
288
|
+
*/
|
|
289
|
+
id: string;
|
|
290
|
+
|
|
291
|
+
organization_id: string;
|
|
292
|
+
|
|
293
|
+
type: 'vault_credential.archived';
|
|
294
|
+
|
|
295
|
+
/**
|
|
296
|
+
* ID of the vault that owns this credential.
|
|
297
|
+
*/
|
|
298
|
+
vault_id: string;
|
|
299
|
+
|
|
300
|
+
workspace_id: string;
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
export interface BetaWebhookVaultCredentialCreatedEventData {
|
|
304
|
+
/**
|
|
305
|
+
* ID of the resource that triggered the event.
|
|
306
|
+
*/
|
|
307
|
+
id: string;
|
|
308
|
+
|
|
309
|
+
organization_id: string;
|
|
310
|
+
|
|
311
|
+
type: 'vault_credential.created';
|
|
312
|
+
|
|
313
|
+
/**
|
|
314
|
+
* ID of the vault that owns this credential.
|
|
315
|
+
*/
|
|
316
|
+
vault_id: string;
|
|
317
|
+
|
|
318
|
+
workspace_id: string;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export interface BetaWebhookVaultCredentialDeletedEventData {
|
|
322
|
+
/**
|
|
323
|
+
* ID of the resource that triggered the event.
|
|
324
|
+
*/
|
|
325
|
+
id: string;
|
|
326
|
+
|
|
327
|
+
organization_id: string;
|
|
328
|
+
|
|
329
|
+
type: 'vault_credential.deleted';
|
|
330
|
+
|
|
331
|
+
/**
|
|
332
|
+
* ID of the vault that owns this credential.
|
|
333
|
+
*/
|
|
334
|
+
vault_id: string;
|
|
335
|
+
|
|
336
|
+
workspace_id: string;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
export interface BetaWebhookVaultCredentialRefreshFailedEventData {
|
|
340
|
+
/**
|
|
341
|
+
* ID of the resource that triggered the event.
|
|
342
|
+
*/
|
|
343
|
+
id: string;
|
|
344
|
+
|
|
345
|
+
organization_id: string;
|
|
346
|
+
|
|
347
|
+
type: 'vault_credential.refresh_failed';
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* ID of the vault that owns this credential.
|
|
351
|
+
*/
|
|
352
|
+
vault_id: string;
|
|
353
|
+
|
|
354
|
+
workspace_id: string;
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
export interface BetaWebhookVaultDeletedEventData {
|
|
358
|
+
/**
|
|
359
|
+
* ID of the resource that triggered the event.
|
|
360
|
+
*/
|
|
361
|
+
id: string;
|
|
362
|
+
|
|
363
|
+
organization_id: string;
|
|
364
|
+
|
|
365
|
+
type: 'vault.deleted';
|
|
366
|
+
|
|
367
|
+
workspace_id: string;
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
export interface UnwrapWebhookEvent {
|
|
371
|
+
/**
|
|
372
|
+
* Unique event identifier for idempotency.
|
|
373
|
+
*/
|
|
374
|
+
id: string;
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* RFC 3339 timestamp when the event occurred.
|
|
378
|
+
*/
|
|
379
|
+
created_at: string;
|
|
380
|
+
|
|
381
|
+
data: BetaWebhookEventData;
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* Object type. Always `event` for webhook payloads.
|
|
385
|
+
*/
|
|
386
|
+
type: 'event';
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
export declare namespace Webhooks {
|
|
390
|
+
export {
|
|
391
|
+
type BetaWebhookEvent as BetaWebhookEvent,
|
|
392
|
+
type BetaWebhookEventData as BetaWebhookEventData,
|
|
393
|
+
type BetaWebhookSessionArchivedEventData as BetaWebhookSessionArchivedEventData,
|
|
394
|
+
type BetaWebhookSessionCreatedEventData as BetaWebhookSessionCreatedEventData,
|
|
395
|
+
type BetaWebhookSessionDeletedEventData as BetaWebhookSessionDeletedEventData,
|
|
396
|
+
type BetaWebhookSessionIdledEventData as BetaWebhookSessionIdledEventData,
|
|
397
|
+
type BetaWebhookSessionOutcomeEvaluationEndedEventData as BetaWebhookSessionOutcomeEvaluationEndedEventData,
|
|
398
|
+
type BetaWebhookSessionPendingEventData as BetaWebhookSessionPendingEventData,
|
|
399
|
+
type BetaWebhookSessionRequiresActionEventData as BetaWebhookSessionRequiresActionEventData,
|
|
400
|
+
type BetaWebhookSessionRunningEventData as BetaWebhookSessionRunningEventData,
|
|
401
|
+
type BetaWebhookSessionStatusIdledEventData as BetaWebhookSessionStatusIdledEventData,
|
|
402
|
+
type BetaWebhookSessionStatusRescheduledEventData as BetaWebhookSessionStatusRescheduledEventData,
|
|
403
|
+
type BetaWebhookSessionStatusRunStartedEventData as BetaWebhookSessionStatusRunStartedEventData,
|
|
404
|
+
type BetaWebhookSessionStatusTerminatedEventData as BetaWebhookSessionStatusTerminatedEventData,
|
|
405
|
+
type BetaWebhookSessionThreadCreatedEventData as BetaWebhookSessionThreadCreatedEventData,
|
|
406
|
+
type BetaWebhookSessionThreadIdledEventData as BetaWebhookSessionThreadIdledEventData,
|
|
407
|
+
type BetaWebhookSessionThreadTerminatedEventData as BetaWebhookSessionThreadTerminatedEventData,
|
|
408
|
+
type BetaWebhookVaultArchivedEventData as BetaWebhookVaultArchivedEventData,
|
|
409
|
+
type BetaWebhookVaultCreatedEventData as BetaWebhookVaultCreatedEventData,
|
|
410
|
+
type BetaWebhookVaultCredentialArchivedEventData as BetaWebhookVaultCredentialArchivedEventData,
|
|
411
|
+
type BetaWebhookVaultCredentialCreatedEventData as BetaWebhookVaultCredentialCreatedEventData,
|
|
412
|
+
type BetaWebhookVaultCredentialDeletedEventData as BetaWebhookVaultCredentialDeletedEventData,
|
|
413
|
+
type BetaWebhookVaultCredentialRefreshFailedEventData as BetaWebhookVaultCredentialRefreshFailedEventData,
|
|
414
|
+
type BetaWebhookVaultDeletedEventData as BetaWebhookVaultDeletedEventData,
|
|
415
|
+
type UnwrapWebhookEvent as UnwrapWebhookEvent,
|
|
416
|
+
};
|
|
417
|
+
}
|
|
@@ -337,30 +337,66 @@ export interface CitationCharLocationParam {
|
|
|
337
337
|
}
|
|
338
338
|
|
|
339
339
|
export interface CitationContentBlockLocation {
|
|
340
|
+
/**
|
|
341
|
+
* The full text of the cited block range, concatenated.
|
|
342
|
+
*
|
|
343
|
+
* Always equals the contents of `content[start_block_index:end_block_index]`
|
|
344
|
+
* joined together. The text block is the minimal citable unit; this field is never
|
|
345
|
+
* a substring of a single block. Not counted toward output tokens, and not counted
|
|
346
|
+
* toward input tokens when sent back in subsequent turns.
|
|
347
|
+
*/
|
|
340
348
|
cited_text: string;
|
|
341
349
|
|
|
342
350
|
document_index: number;
|
|
343
351
|
|
|
344
352
|
document_title: string | null;
|
|
345
353
|
|
|
354
|
+
/**
|
|
355
|
+
* Exclusive 0-based end index of the cited block range in the source's `content`
|
|
356
|
+
* array.
|
|
357
|
+
*
|
|
358
|
+
* Always greater than `start_block_index`; a single-block citation has
|
|
359
|
+
* `end_block_index = start_block_index + 1`.
|
|
360
|
+
*/
|
|
346
361
|
end_block_index: number;
|
|
347
362
|
|
|
348
363
|
file_id: string | null;
|
|
349
364
|
|
|
365
|
+
/**
|
|
366
|
+
* 0-based index of the first cited block in the source's `content` array.
|
|
367
|
+
*/
|
|
350
368
|
start_block_index: number;
|
|
351
369
|
|
|
352
370
|
type: 'content_block_location';
|
|
353
371
|
}
|
|
354
372
|
|
|
355
373
|
export interface CitationContentBlockLocationParam {
|
|
374
|
+
/**
|
|
375
|
+
* The full text of the cited block range, concatenated.
|
|
376
|
+
*
|
|
377
|
+
* Always equals the contents of `content[start_block_index:end_block_index]`
|
|
378
|
+
* joined together. The text block is the minimal citable unit; this field is never
|
|
379
|
+
* a substring of a single block. Not counted toward output tokens, and not counted
|
|
380
|
+
* toward input tokens when sent back in subsequent turns.
|
|
381
|
+
*/
|
|
356
382
|
cited_text: string;
|
|
357
383
|
|
|
358
384
|
document_index: number;
|
|
359
385
|
|
|
360
386
|
document_title: string | null;
|
|
361
387
|
|
|
388
|
+
/**
|
|
389
|
+
* Exclusive 0-based end index of the cited block range in the source's `content`
|
|
390
|
+
* array.
|
|
391
|
+
*
|
|
392
|
+
* Always greater than `start_block_index`; a single-block citation has
|
|
393
|
+
* `end_block_index = start_block_index + 1`.
|
|
394
|
+
*/
|
|
362
395
|
end_block_index: number;
|
|
363
396
|
|
|
397
|
+
/**
|
|
398
|
+
* 0-based index of the first cited block in the source's `content` array.
|
|
399
|
+
*/
|
|
364
400
|
start_block_index: number;
|
|
365
401
|
|
|
366
402
|
type: 'content_block_location';
|
|
@@ -397,14 +433,40 @@ export interface CitationPageLocationParam {
|
|
|
397
433
|
}
|
|
398
434
|
|
|
399
435
|
export interface CitationSearchResultLocationParam {
|
|
436
|
+
/**
|
|
437
|
+
* The full text of the cited block range, concatenated.
|
|
438
|
+
*
|
|
439
|
+
* Always equals the contents of `content[start_block_index:end_block_index]`
|
|
440
|
+
* joined together. The text block is the minimal citable unit; this field is never
|
|
441
|
+
* a substring of a single block. Not counted toward output tokens, and not counted
|
|
442
|
+
* toward input tokens when sent back in subsequent turns.
|
|
443
|
+
*/
|
|
400
444
|
cited_text: string;
|
|
401
445
|
|
|
446
|
+
/**
|
|
447
|
+
* Exclusive 0-based end index of the cited block range in the source's `content`
|
|
448
|
+
* array.
|
|
449
|
+
*
|
|
450
|
+
* Always greater than `start_block_index`; a single-block citation has
|
|
451
|
+
* `end_block_index = start_block_index + 1`.
|
|
452
|
+
*/
|
|
402
453
|
end_block_index: number;
|
|
403
454
|
|
|
455
|
+
/**
|
|
456
|
+
* 0-based index of the cited search result among all `search_result` content
|
|
457
|
+
* blocks in the request, in the order they appear across messages and tool
|
|
458
|
+
* results.
|
|
459
|
+
*
|
|
460
|
+
* Counted separately from `document_index`; server-side web search results are not
|
|
461
|
+
* included in this count.
|
|
462
|
+
*/
|
|
404
463
|
search_result_index: number;
|
|
405
464
|
|
|
406
465
|
source: string;
|
|
407
466
|
|
|
467
|
+
/**
|
|
468
|
+
* 0-based index of the first cited block in the source's `content` array.
|
|
469
|
+
*/
|
|
408
470
|
start_block_index: number;
|
|
409
471
|
|
|
410
472
|
title: string | null;
|
|
@@ -444,14 +506,40 @@ export interface CitationsDelta {
|
|
|
444
506
|
}
|
|
445
507
|
|
|
446
508
|
export interface CitationsSearchResultLocation {
|
|
509
|
+
/**
|
|
510
|
+
* The full text of the cited block range, concatenated.
|
|
511
|
+
*
|
|
512
|
+
* Always equals the contents of `content[start_block_index:end_block_index]`
|
|
513
|
+
* joined together. The text block is the minimal citable unit; this field is never
|
|
514
|
+
* a substring of a single block. Not counted toward output tokens, and not counted
|
|
515
|
+
* toward input tokens when sent back in subsequent turns.
|
|
516
|
+
*/
|
|
447
517
|
cited_text: string;
|
|
448
518
|
|
|
519
|
+
/**
|
|
520
|
+
* Exclusive 0-based end index of the cited block range in the source's `content`
|
|
521
|
+
* array.
|
|
522
|
+
*
|
|
523
|
+
* Always greater than `start_block_index`; a single-block citation has
|
|
524
|
+
* `end_block_index = start_block_index + 1`.
|
|
525
|
+
*/
|
|
449
526
|
end_block_index: number;
|
|
450
527
|
|
|
528
|
+
/**
|
|
529
|
+
* 0-based index of the cited search result among all `search_result` content
|
|
530
|
+
* blocks in the request, in the order they appear across messages and tool
|
|
531
|
+
* results.
|
|
532
|
+
*
|
|
533
|
+
* Counted separately from `document_index`; server-side web search results are not
|
|
534
|
+
* included in this count.
|
|
535
|
+
*/
|
|
451
536
|
search_result_index: number;
|
|
452
537
|
|
|
453
538
|
source: string;
|
|
454
539
|
|
|
540
|
+
/**
|
|
541
|
+
* 0-based index of the first cited block in the source's `content` array.
|
|
542
|
+
*/
|
|
455
543
|
start_block_index: number;
|
|
456
544
|
|
|
457
545
|
title: string | null;
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.95.1'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.95.1";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.95.1";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.95.1'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|