@deepraxis/sdk 0.2.0-dev.476046b → 0.2.0-dev.49e9c46

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.
@@ -3609,7 +3609,7 @@ export type BrowserSessionCreateParams = {
3609
3609
  */
3610
3610
  projectId?: string;
3611
3611
  /**
3612
- * 谁能看到这个新会话:默认 private 只有创建者;organization 允许同组织其他成员只读观看画面。
3612
+ * 谁能看到这个新会话:默认 private 只有创建者;organization 允许同组织其他成员只读观看画面。自带浏览器(source.type 为 byob)的会话一律是 organization,传 private 也会被改成 organization,不报错。
3613
3613
  */
3614
3614
  visibility?: 'private' | 'organization';
3615
3615
  /**
@@ -3696,9 +3696,74 @@ export type BrowserSessionCreateParams = {
3696
3696
  ignoreCertificateErrors?: boolean;
3697
3697
  };
3698
3698
  /**
3699
- * 仅省略、false 或 [{type: 'none'}] 可用;其它代理配置返回 501。
3699
+ * 让会话经一个固定的外部 HTTP 代理(如住宅 IP)出网:[{type: 'external', server: 'host:port', username?, password_secret?}];省略、false 或 [{type: 'none'}] 表示不用代理。只能有一个代理条目;密码推荐用 password_secret 引用保管库(只在连接代理主机时兑换),也可以直接给明文 password,二者不能同时出现。带代理的会话一定在我们的 Chrome 容器里运行,需要组织已开通容器后端,否则返回 501 PROVIDER_UNSUPPORTED;不能与 source.type 为 cloud 或 byob 同用,返回 400 INVALID_PARAMS(格式错误、私网地址、用户名没有密码等同样返回 400,reason 写明原因)。其它代理类型和 socks5 返回 501 PROVIDER_UNSUPPORTED。要让某个账号始终从同一个出口地址出去,把代理绑定在登录态上(contexts 的 proxy),不必每次会话重复传。
3700
3700
  */
3701
- proxies?: boolean | Array<unknown>;
3701
+ proxies?: boolean | [
3702
+ {
3703
+ /**
3704
+ * 固定为 external:经一个你自己的外部 HTTP 代理出网。
3705
+ */
3706
+ type: 'external';
3707
+ /**
3708
+ * 代理地址,host:port 或 http://host:port;只支持 HTTP 代理,不接受 socks5:// 等协议,也不接受 localhost 和内网、链路本地地址。
3709
+ */
3710
+ server: string;
3711
+ /**
3712
+ * 代理用户名;有密码时才能填,填了就必须同时给出密码。
3713
+ */
3714
+ username?: string;
3715
+ /**
3716
+ * 代理密码明文,只在这次创建中使用,不会保存;推荐改用 password_secret。与 password_secret 二选一。
3717
+ */
3718
+ password?: string;
3719
+ /**
3720
+ * 推荐:引用保管库里的代理密码,只在连接这个代理的主机时兑换,不会交给网页。与 password 二选一。
3721
+ */
3722
+ password_secret?: {
3723
+ /**
3724
+ * 保存代理密码的保管库 ID,以 vlt_ 开头。
3725
+ */
3726
+ vault_id: string;
3727
+ /**
3728
+ * 保管库中该密码的密钥 ID(不是密码本身)。
3729
+ */
3730
+ secret: string;
3731
+ };
3732
+ } | {
3733
+ /**
3734
+ * 固定为 none:不用代理,与省略 proxies 相同。
3735
+ */
3736
+ type: 'none';
3737
+ }
3738
+ ];
3739
+ /**
3740
+ * 选择浏览器后端,只有 container 支持外部代理:cloud(Browser Run)和 byob 都不能用代理。{type: 'cloud'}:Browser Run,启动最快、不能用代理、自动化特征可被网站发现。{type: 'container'}:我们自己的 Chrome 容器,可带 proxies(或用登录态绑定的代理),也可不带;组织未开通容器后端时返回 501 PROVIDER_UNSUPPORTED。{type: 'byob', browser: 'byb_…'}:用户自己配对的浏览器,不能与 proxies 或登录态同用。简写 {byob: 'byb_…'} 等同最后一种。省略时按旧规则:带 proxies 进容器,否则 Browser Run。cloud 加代理、未知 type、格式错误都返回 400 INVALID_PARAMS。
3741
+ */
3742
+ source?: {
3743
+ /**
3744
+ * Browser Run。
3745
+ */
3746
+ type: 'cloud';
3747
+ } | {
3748
+ /**
3749
+ * 自家 Chrome 容器。
3750
+ */
3751
+ type: 'container';
3752
+ } | {
3753
+ /**
3754
+ * 用户自己的浏览器。
3755
+ */
3756
+ type: 'byob';
3757
+ /**
3758
+ * 自带浏览器 ID,以 byb_ 开头。
3759
+ */
3760
+ browser: string;
3761
+ } | {
3762
+ /**
3763
+ * 自带浏览器 ID,type 为 byob 的简写。
3764
+ */
3765
+ byob: string;
3766
+ };
3702
3767
  /**
3703
3768
  * 接受但忽略;不能选择区域。
3704
3769
  */
@@ -3746,9 +3811,9 @@ export type BrowserSessionCreateResult = {
3746
3811
  */
3747
3812
  region: 'ap-southeast-1';
3748
3813
  /**
3749
- * 兼容的代理流量字节数;当前未使用代理,固定返回 0。
3814
+ * 会话经代理链转发的流量字节数(上行与下行之和),容器后端的会话按它计费;Browser Run 和自带浏览器固定为 0,运行中每几分钟更新一次。
3750
3815
  */
3751
- proxyBytes: 0;
3816
+ proxyBytes: number;
3752
3817
  /**
3753
3818
  * 会话创建时刻,UTC ISO 8601 时间。
3754
3819
  */
@@ -3794,17 +3859,34 @@ export type BrowserSessionCreateResult = {
3794
3859
  */
3795
3860
  origin: 'api' | 'connect' | 'console';
3796
3861
  /**
3797
- * 会话的浏览器来源:cloud 是云浏览器,byob 是用户自己配对的浏览器(browser 为它的 ID)。
3862
+ * 会话实际使用的浏览器后端:cloud 是云浏览器(Browser Run),container 是我们自己的 Chrome 容器,byob 是用户自己配对的浏览器(browser 为它的 ID)。type 与 kind 同值,type 是公开名称,kind 为兼容旧读者保留。
3798
3863
  */
3799
3864
  source: {
3800
3865
  /**
3801
3866
  * 云浏览器会话,固定为 cloud。
3802
3867
  */
3868
+ type: 'cloud';
3869
+ /**
3870
+ * 与 type 同值。
3871
+ */
3803
3872
  kind: 'cloud';
3873
+ } | {
3874
+ /**
3875
+ * 自家 Chrome 容器会话,固定为 container。
3876
+ */
3877
+ type: 'container';
3878
+ /**
3879
+ * 与 type 同值。
3880
+ */
3881
+ kind: 'container';
3804
3882
  } | {
3805
3883
  /**
3806
3884
  * 用户自己配对的浏览器会话,固定为 byob。
3807
3885
  */
3886
+ type: 'byob';
3887
+ /**
3888
+ * 与 type 同值。
3889
+ */
3808
3890
  kind: 'byob';
3809
3891
  /**
3810
3892
  * 自带浏览器 ID,以 byb_ 开头。
@@ -3886,7 +3968,7 @@ export type BrowserError = {
3886
3968
  statusCode: number;
3887
3969
  error: string;
3888
3970
  message: string;
3889
- code: 'INVALID_PARAMS' | 'PERMISSION_DENIED' | 'NOT_IMPLEMENTED' | 'INTERNAL' | 'UNAUTHENTICATED' | 'CONNECT_SIGNATURE_INVALID' | 'SESSION_NOT_FOUND' | 'SESSION_ENDED' | 'SESSION_INVALID_STATE' | 'SESSION_NAME_IN_USE' | 'CONTEXT_NOT_FOUND' | 'BROWSER_NOT_GRANTED' | 'BROWSER_OFFLINE' | 'BROWSER_REVOKED' | 'PAIRING_NOT_FOUND' | 'BROWSER_NOT_FOUND' | 'CONTEXT_LOCKED' | 'CONTEXT_READ_ONLY' | 'HANDOFF_NOT_PENDING' | 'CONCURRENCY_LIMIT' | 'RATE_LIMITED' | 'INSUFFICIENT_BALANCE' | 'QUOTA_EXHAUSTED' | 'ACCOUNT_SUSPENDED' | 'PROVIDER_UNSUPPORTED' | 'PROVIDER_CAPACITY' | 'PROVIDER_FAILED' | 'SERVICE_UNAVAILABLE' | 'PARENT_NOT_FOUND' | 'INVALID_FILTER' | 'INVALID_PAGE_TOKEN' | 'ACTION_TAB_NOT_FOUND' | 'ACTION_NO_TAB' | 'ACTION_REF_STALE' | 'ACTION_FAILED' | 'ACTION_TIMEOUT' | 'ACTION_RESULT_TOO_LARGE';
3971
+ code: 'INVALID_PARAMS' | 'PERMISSION_DENIED' | 'NOT_IMPLEMENTED' | 'INTERNAL' | 'UNAUTHENTICATED' | 'CONNECT_SIGNATURE_INVALID' | 'SESSION_NOT_FOUND' | 'SESSION_ENDED' | 'SESSION_INVALID_STATE' | 'SESSION_NAME_IN_USE' | 'CONTEXT_NOT_FOUND' | 'BROWSER_OFFLINE' | 'BROWSER_REVOKED' | 'PAIRING_NOT_FOUND' | 'BROWSER_NOT_FOUND' | 'CONTEXT_LOCKED' | 'CONTEXT_READ_ONLY' | 'HANDOFF_NOT_PENDING' | 'CONCURRENCY_LIMIT' | 'RATE_LIMITED' | 'INSUFFICIENT_BALANCE' | 'QUOTA_EXHAUSTED' | 'ACCOUNT_SUSPENDED' | 'PROVIDER_UNSUPPORTED' | 'PROVIDER_CAPACITY' | 'PROVIDER_FAILED' | 'SERVICE_UNAVAILABLE' | 'PARENT_NOT_FOUND' | 'INVALID_FILTER' | 'INVALID_PAGE_TOKEN' | 'ACTION_TAB_NOT_FOUND' | 'ACTION_NO_TAB' | 'ACTION_REF_STALE' | 'ACTION_FAILED' | 'ACTION_TIMEOUT' | 'ACTION_RESULT_TOO_LARGE';
3890
3972
  };
3891
3973
  export type BrowserSession = {
3892
3974
  /**
@@ -3910,9 +3992,9 @@ export type BrowserSession = {
3910
3992
  */
3911
3993
  region: 'ap-southeast-1';
3912
3994
  /**
3913
- * 兼容的代理流量字节数;当前未使用代理,固定返回 0。
3995
+ * 会话经代理链转发的流量字节数(上行与下行之和),容器后端的会话按它计费;Browser Run 和自带浏览器固定为 0,运行中每几分钟更新一次。
3914
3996
  */
3915
- proxyBytes: 0;
3997
+ proxyBytes: number;
3916
3998
  /**
3917
3999
  * 会话创建时刻,UTC ISO 8601 时间。
3918
4000
  */
@@ -3958,17 +4040,34 @@ export type BrowserSession = {
3958
4040
  */
3959
4041
  origin: 'api' | 'connect' | 'console';
3960
4042
  /**
3961
- * 会话的浏览器来源:cloud 是云浏览器,byob 是用户自己配对的浏览器(browser 为它的 ID)。
4043
+ * 会话实际使用的浏览器后端:cloud 是云浏览器(Browser Run),container 是我们自己的 Chrome 容器,byob 是用户自己配对的浏览器(browser 为它的 ID)。type 与 kind 同值,type 是公开名称,kind 为兼容旧读者保留。
3962
4044
  */
3963
4045
  source: {
3964
4046
  /**
3965
4047
  * 云浏览器会话,固定为 cloud。
3966
4048
  */
4049
+ type: 'cloud';
4050
+ /**
4051
+ * 与 type 同值。
4052
+ */
3967
4053
  kind: 'cloud';
4054
+ } | {
4055
+ /**
4056
+ * 自家 Chrome 容器会话,固定为 container。
4057
+ */
4058
+ type: 'container';
4059
+ /**
4060
+ * 与 type 同值。
4061
+ */
4062
+ kind: 'container';
3968
4063
  } | {
3969
4064
  /**
3970
4065
  * 用户自己配对的浏览器会话,固定为 byob。
3971
4066
  */
4067
+ type: 'byob';
4068
+ /**
4069
+ * 与 type 同值。
4070
+ */
3972
4071
  kind: 'byob';
3973
4072
  /**
3974
4073
  * 自带浏览器 ID,以 byb_ 开头。
@@ -4052,9 +4151,9 @@ export type BrowserSessionGetResult = {
4052
4151
  */
4053
4152
  region: 'ap-southeast-1';
4054
4153
  /**
4055
- * 兼容的代理流量字节数;当前未使用代理,固定返回 0。
4154
+ * 会话经代理链转发的流量字节数(上行与下行之和),容器后端的会话按它计费;Browser Run 和自带浏览器固定为 0,运行中每几分钟更新一次。
4056
4155
  */
4057
- proxyBytes: 0;
4156
+ proxyBytes: number;
4058
4157
  /**
4059
4158
  * 会话创建时刻,UTC ISO 8601 时间。
4060
4159
  */
@@ -4100,17 +4199,34 @@ export type BrowserSessionGetResult = {
4100
4199
  */
4101
4200
  origin: 'api' | 'connect' | 'console';
4102
4201
  /**
4103
- * 会话的浏览器来源:cloud 是云浏览器,byob 是用户自己配对的浏览器(browser 为它的 ID)。
4202
+ * 会话实际使用的浏览器后端:cloud 是云浏览器(Browser Run),container 是我们自己的 Chrome 容器,byob 是用户自己配对的浏览器(browser 为它的 ID)。type 与 kind 同值,type 是公开名称,kind 为兼容旧读者保留。
4104
4203
  */
4105
4204
  source: {
4106
4205
  /**
4107
4206
  * 云浏览器会话,固定为 cloud。
4108
4207
  */
4208
+ type: 'cloud';
4209
+ /**
4210
+ * 与 type 同值。
4211
+ */
4109
4212
  kind: 'cloud';
4213
+ } | {
4214
+ /**
4215
+ * 自家 Chrome 容器会话,固定为 container。
4216
+ */
4217
+ type: 'container';
4218
+ /**
4219
+ * 与 type 同值。
4220
+ */
4221
+ kind: 'container';
4110
4222
  } | {
4111
4223
  /**
4112
4224
  * 用户自己配对的浏览器会话,固定为 byob。
4113
4225
  */
4226
+ type: 'byob';
4227
+ /**
4228
+ * 与 type 同值。
4229
+ */
4114
4230
  kind: 'byob';
4115
4231
  /**
4116
4232
  * 自带浏览器 ID,以 byb_ 开头。
@@ -4191,11 +4307,11 @@ export type BrowserSessionGetResult = {
4191
4307
  */
4192
4308
  export type BrowserSessionLiveUrls = {
4193
4309
  /**
4194
- * 会话实时画面的完整跳转地址,携带观看凭证;与 debuggerUrl 相同。
4310
+ * 与 debuggerUrl 相同:会话在 Console 的会话页地址。
4195
4311
  */
4196
4312
  debuggerFullscreenUrl: string;
4197
4313
  /**
4198
- * 会话实时画面的完整跳转地址;直接打开,勿移除查询凭证。
4314
+ * 会话在 Console 的会话页地址,发给人观看或接管。打开的人须登录 Console 且属于会话所在组织;会话创建者或在接管请求有效期内的组织成员可以点「接管」直接点击、拖动和输入,其他成员只读观看。地址不带凭证,不能嵌入 iframe。
4199
4315
  */
4200
4316
  debuggerUrl: string;
4201
4317
  /**
@@ -4223,11 +4339,11 @@ export type BrowserSessionLiveUrls = {
4223
4339
  */
4224
4340
  faviconUrl: string;
4225
4341
  /**
4226
- * 此标签页实时画面的完整跳转地址,包含观看凭证。
4342
+ * 会话在 Console 的会话页地址,与会话级 debuggerUrl 相同。
4227
4343
  */
4228
4344
  debuggerUrl: string;
4229
4345
  /**
4230
- * 此标签页实时画面的完整跳转地址,与该页 debuggerUrl 相同。
4346
+ * 与该页 debuggerUrl 相同。
4231
4347
  */
4232
4348
  debuggerFullscreenUrl: string;
4233
4349
  }>;
@@ -4311,6 +4427,36 @@ export type BrowserContextCreateResult = {
4311
4427
  * UTC timestamp when a session last started with this context; absent if it has never been used.
4312
4428
  */
4313
4429
  lastUsedAt?: string;
4430
+ /**
4431
+ * 登录态绑定的固定外部代理(只含保管库引用,不含密码);没有绑定时省略。
4432
+ */
4433
+ proxy?: {
4434
+ /**
4435
+ * 固定为 external:经一个你自己的外部 HTTP 代理出网。
4436
+ */
4437
+ type: 'external';
4438
+ /**
4439
+ * 代理地址,host:port 或 http://host:port;只支持 HTTP 代理,不接受 socks5:// 等协议,也不接受 localhost 和内网、链路本地地址。
4440
+ */
4441
+ server: string;
4442
+ /**
4443
+ * 代理用户名;有密码时才能填,填了就必须同时给出密码。
4444
+ */
4445
+ username?: string;
4446
+ /**
4447
+ * 必须用这种形式:引用保管库里的代理密码,只在连接这个代理的主机时兑换,不会交给网页。登录态里只存引用,传明文 password 返回 400 INVALID_PARAMS。
4448
+ */
4449
+ password_secret?: {
4450
+ /**
4451
+ * 保存代理密码的保管库 ID,以 vlt_ 开头。
4452
+ */
4453
+ vault_id: string;
4454
+ /**
4455
+ * 保管库中该密码的密钥 ID(不是密码本身)。
4456
+ */
4457
+ secret: string;
4458
+ };
4459
+ };
4314
4460
  /**
4315
4461
  * Empty compatibility field; context encryption keys are held by the server.
4316
4462
  */
@@ -4371,6 +4517,36 @@ export type BrowserContext = {
4371
4517
  * UTC timestamp when a session last started with this context; absent if it has never been used.
4372
4518
  */
4373
4519
  lastUsedAt?: string;
4520
+ /**
4521
+ * 登录态绑定的固定外部代理(只含保管库引用,不含密码);没有绑定时省略。
4522
+ */
4523
+ proxy?: {
4524
+ /**
4525
+ * 固定为 external:经一个你自己的外部 HTTP 代理出网。
4526
+ */
4527
+ type: 'external';
4528
+ /**
4529
+ * 代理地址,host:port 或 http://host:port;只支持 HTTP 代理,不接受 socks5:// 等协议,也不接受 localhost 和内网、链路本地地址。
4530
+ */
4531
+ server: string;
4532
+ /**
4533
+ * 代理用户名;有密码时才能填,填了就必须同时给出密码。
4534
+ */
4535
+ username?: string;
4536
+ /**
4537
+ * 必须用这种形式:引用保管库里的代理密码,只在连接这个代理的主机时兑换,不会交给网页。登录态里只存引用,传明文 password 返回 400 INVALID_PARAMS。
4538
+ */
4539
+ password_secret?: {
4540
+ /**
4541
+ * 保存代理密码的保管库 ID,以 vlt_ 开头。
4542
+ */
4543
+ vault_id: string;
4544
+ /**
4545
+ * 保管库中该密码的密钥 ID(不是密码本身)。
4546
+ */
4547
+ secret: string;
4548
+ };
4549
+ };
4374
4550
  };
4375
4551
  export type BrowserByobPairing = {
4376
4552
  /**
@@ -4411,14 +4587,6 @@ export type BrowserByobBrowser = {
4411
4587
  * 配对用的扩展 ID。
4412
4588
  */
4413
4589
  extension_id: string;
4414
- /**
4415
- * 被授权驱动这个浏览器的智能体 ID 列表;智能体不在列表里时不能打开它的会话。空数组表示没有智能体被授权。
4416
- */
4417
- granted_agents: Array<string>;
4418
- /**
4419
- * 允许智能体访问的站点列表;空数组表示不限制 http(s) 站点。这是护栏,不是数据边界。
4420
- */
4421
- allowed_sites: Array<string>;
4422
4590
  /**
4423
4591
  * 扩展的连接当前是否在线;连接对象上线之前固定为 false。
4424
4592
  */
@@ -4512,6 +4680,10 @@ export type BrowserStreamMessage = {
4512
4680
  */
4513
4681
  nextCursor: string | null;
4514
4682
  };
4683
+ /**
4684
+ * The tab in front: the newest one the browser opened or the one a client last brought to the front. null when unknown.
4685
+ */
4686
+ activePageId?: string | null;
4515
4687
  };
4516
4688
  } | {
4517
4689
  event: 'session';
@@ -4522,7 +4694,10 @@ export type BrowserStreamMessage = {
4522
4694
  } | {
4523
4695
  event: 'action';
4524
4696
  data: {
4525
- kind: 'navigate' | 'click' | 'type' | 'scroll' | 'page_opened' | 'page_closed';
4697
+ /**
4698
+ * page_activated: a client brought pageId to the front. Tab changes (page_opened, page_closed, page_activated) are never thinned out; the other kinds are sent at most four times a second.
4699
+ */
4700
+ kind: 'navigate' | 'click' | 'type' | 'scroll' | 'page_opened' | 'page_closed' | 'page_activated';
4526
4701
  pageId?: string;
4527
4702
  url?: string;
4528
4703
  x?: number;
@@ -13671,7 +13846,7 @@ export type AutomationHumanTask = {
13671
13846
  */
13672
13847
  initiator: {
13673
13848
  /**
13674
- * Initiator type: user, api_key, agent, run (a parent run) or trigger.
13849
+ * Initiator type: user, api_key, agent, run (a parent run), trigger or application.
13675
13850
  */
13676
13851
  type: 'user' | 'api_key' | 'agent' | 'run' | 'trigger';
13677
13852
  /**
@@ -19968,6 +20143,10 @@ export type DevopsPullRequest = {
19968
20143
  * The mergeability word, an open set. A GitHub project keeps GitHub's own word verbatim (clean, dirty, blocked, behind, unstable and so on), unknown when GitHub has not said. A project whose code is on our own Git gets DevOps's reading of the head against the base: clean when nothing stands in the way, behind when the head adds nothing the base lacks, dirty when both sides changed the same path since they diverged, unknown when the comparison was capped.
19969
20144
  */
19970
20145
  mergeableState: string;
20146
+ /**
20147
+ * Who this pull request's letters go to — the gate verdict, the merge, the deploy to each integration environment and an integration failure — as the description's praxis block names it with notify: agent:<id> or notify: human:<id>. Optional and never part of the gate: absent when the block names nobody or names something that is not an address. A pull request of a DevOps change that names nobody writes to the change's owner.
20148
+ */
20149
+ notify?: string;
19971
20150
  /**
19972
20151
  * The exposure the description's praxis block declares, or null when the description declares none — which is itself a failed gate check. The kind decides which other checks apply: a flag adds its key and observe window, unwired and expand-contract add a reason, expand-contract also a phase, and direct is judged by a person.
19973
20152
  */
@@ -21269,7 +21448,7 @@ export type MediaLibrary = {
21269
21448
  };
21270
21449
  export type MediaMediaError = {
21271
21450
  error: {
21272
- code: 'LIBRARY_NOT_FOUND' | 'ASSET_NOT_FOUND' | 'JOB_NOT_FOUND' | 'UNDERSTANDING_NOT_FOUND' | 'ASSET_VERSION_CHANGED' | 'LIBRARY_INVALID_STATE' | 'INVALID_PARAMS' | 'INVALID_EXPRESSION' | 'UNSUPPORTED' | 'NOT_IMPLEMENTED' | 'FILE_TOO_LARGE' | 'FILE_EMPTY' | 'FILE_NOT_READY' | 'UNSUPPORTED_MEDIA' | 'FETCH_FAILED' | 'LIMIT_EXCEEDED' | 'CHUNK_INVALID' | 'RATE_LIMITED' | 'CAPACITY' | 'UPSTREAM_FAILED' | 'CONTENT_REJECTED' | 'GENERATION_FAILED' | 'BINDING_READ_ONLY' | 'OPERATION_NOT_SUPPORTED' | 'MODEL_PENDING' | 'REFERENCE_TYPE_MISMATCH' | 'CONSENT_REQUIRED' | 'LIBRARY_IS_DEFAULT' | 'JOB_INVALID_STATE' | 'VOICE_TRAINING' | 'INSUFFICIENT_BALANCE';
21451
+ code: 'LIBRARY_NOT_FOUND' | 'ASSET_NOT_FOUND' | 'WORK_NOT_FOUND' | 'REVISION_CONFLICT' | 'JOB_NOT_FOUND' | 'UNDERSTANDING_NOT_FOUND' | 'ASSET_VERSION_CHANGED' | 'LIBRARY_INVALID_STATE' | 'INVALID_PARAMS' | 'INVALID_EXPRESSION' | 'UNSUPPORTED' | 'NOT_IMPLEMENTED' | 'FILE_TOO_LARGE' | 'FILE_EMPTY' | 'FILE_NOT_READY' | 'UNSUPPORTED_MEDIA' | 'FETCH_FAILED' | 'LIMIT_EXCEEDED' | 'CHUNK_INVALID' | 'RATE_LIMITED' | 'CAPACITY' | 'UPSTREAM_FAILED' | 'CONTENT_REJECTED' | 'GENERATION_FAILED' | 'BINDING_READ_ONLY' | 'OPERATION_NOT_SUPPORTED' | 'MODEL_PENDING' | 'REFERENCE_TYPE_MISMATCH' | 'CONSENT_REQUIRED' | 'LIBRARY_IS_DEFAULT' | 'JOB_INVALID_STATE' | 'VOICE_TRAINING' | 'INSUFFICIENT_BALANCE';
21273
21452
  message: string;
21274
21453
  details: string | null;
21275
21454
  };
@@ -22798,6 +22977,107 @@ export type MediaVoiceDesignCreateInput = {
22798
22977
  */
22799
22978
  description?: string;
22800
22979
  };
22980
+ /**
22981
+ * A work: an object of the library above its assets that orders references to them and adds a title and text. It copies no file and changes no asset.
22982
+ */
22983
+ export type MediaWork = {
22984
+ /**
22985
+ * Always work.
22986
+ */
22987
+ object: 'work';
22988
+ /**
22989
+ * Work id (wrk_…).
22990
+ */
22991
+ id: string;
22992
+ /**
22993
+ * Library the work belongs to.
22994
+ */
22995
+ library_id: MediaLibraryId;
22996
+ /**
22997
+ * The work’s kind.
22998
+ */
22999
+ kind: MediaWorkKind;
23000
+ /**
23001
+ * The title, copied from body.title.
23002
+ */
23003
+ title: string;
23004
+ /**
23005
+ * Groups the platform versions of one story; null when unset.
23006
+ */
23007
+ series: string | null;
23008
+ /**
23009
+ * The kind’s body as stored.
23010
+ */
23011
+ body: MediaWorkBody;
23012
+ /**
23013
+ * Caller data such as source, published links and numbers; changed with a JSON Merge Patch.
23014
+ */
23015
+ custom: MediaWorkCustom;
23016
+ /**
23017
+ * Asset ids the body names that have been deleted since; the body keeps them in place and the Console draws a placeholder there.
23018
+ */
23019
+ missing: Array<string>;
23020
+ /**
23021
+ * Bumped by every change; send it back as if_revision to update only an unchanged work.
23022
+ */
23023
+ revision: number;
23024
+ /**
23025
+ * Who created the work: human:<user id>, agent:<agent id> or system.
23026
+ */
23027
+ created_by: string;
23028
+ /**
23029
+ * When the work was created.
23030
+ */
23031
+ created_at: MediaIsoTimestamp;
23032
+ /**
23033
+ * When the work last changed.
23034
+ */
23035
+ updated_at: MediaIsoTimestamp;
23036
+ /**
23037
+ * Only with expand=assets: every live referenced asset by id, with its URLs and size.
23038
+ */
23039
+ assets?: {
23040
+ [key: string]: MediaWorkAsset;
23041
+ };
23042
+ };
23043
+ /**
23044
+ * Kind of work: gallery (图文), article (长文) or product_listing (商品图组). short_video is reserved.
23045
+ */
23046
+ export type MediaWorkKind = 'gallery' | 'article' | 'product_listing' | 'blocks';
23047
+ export type MediaWorkBody = MediaGalleryBody | MediaArticleBody | MediaProductListingBody | MediaBlocksBody;
23048
+ export type MediaWorkCustom = {
23049
+ [key: string]: unknown;
23050
+ };
23051
+ /**
23052
+ * A page of work summaries.
23053
+ */
23054
+ export type MediaWorkPage = {
23055
+ /**
23056
+ * Works in this page, most recently changed first.
23057
+ */
23058
+ data: Array<MediaWorkSummary>;
23059
+ /**
23060
+ * Cursor for the next page, or null when there are no more works.
23061
+ */
23062
+ next_cursor: string | null;
23063
+ };
23064
+ /**
23065
+ * The answer to deleting a work.
23066
+ */
23067
+ export type MediaDeletedWork = {
23068
+ /**
23069
+ * Id of the deleted work.
23070
+ */
23071
+ id: string;
23072
+ /**
23073
+ * Always work.
23074
+ */
23075
+ object: 'work';
23076
+ /**
23077
+ * Always true: the work is deleted; every asset it named is unchanged.
23078
+ */
23079
+ deleted: true;
23080
+ };
22801
23081
  /**
22802
23082
  * One page of type registrations; types are few enough that this face returns them in a single page.
22803
23083
  */
@@ -34932,6 +35212,14 @@ export type SandboxSandboxNetworkConfig = {
34932
35212
  rules?: {
34933
35213
  [key: string]: Array<SandboxSandboxNetworkRule>;
34934
35214
  };
35215
+ /**
35216
+ * Own face, persistent sandboxes only (autoPause: true, or ephemeral: false): true gives the sandbox one fixed public egress IP for its whole life, held through pause and resume and released when the sandbox is deleted. Without it the egress IP is not stable: it changes when a spot machine is reclaimed, when a paused machine starts again, and when the machine is rebuilt. An ephemeral sandbox returns INVALID_PARAMS; the E2B face refuses the field; it is placed only on capacity that declares static IPs, and without such capacity the create does not start (it never falls back to a changing IP). Billed as the usage item sandbox:public_ip:hours from allocation to release, paused time included, plus outbound traffic as usual.
35217
+ */
35218
+ staticEgressIp?: boolean;
35219
+ /**
35220
+ * Own face, read-only: the fixed public egress IP of a sandbox created with staticEgressIp: true, present once the machine has bound it; add this address to the IP allowlist of the service you call (for example a WeCom trusted IP list). Absent on a sandbox that did not ask for a static IP, because its public address can change.
35221
+ */
35222
+ readonly egressIp?: string;
34935
35223
  };
34936
35224
  /**
34937
35225
  * Sandbox lifecycle policy returned by sandbox info.
@@ -36642,11 +36930,11 @@ export type AutomationActionHost = 'builtin' | 'isolate' | 'sandbox';
36642
36930
  */
36643
36931
  export type AutomationSubject = {
36644
36932
  /**
36645
- * Principal type. user is a signed-in user; api_key is a platform API key; agent is an agent; run is an action performed by a run itself (for example a parent run); trigger is a trigger.
36933
+ * Principal type. user is a signed-in user; api_key is a platform API key; agent is an agent; run is an action performed by a run itself (for example a parent run); trigger is a trigger; application is an application.
36646
36934
  */
36647
36935
  type: 'user' | 'api_key' | 'agent' | 'run' | 'trigger';
36648
36936
  /**
36649
- * Principal identifier whose meaning follows type: a user, API key, agent, run or trigger id. Treat it as an opaque string.
36937
+ * Principal identifier whose meaning follows type: a user, API key, agent, run, trigger or application id. Treat it as an opaque string.
36650
36938
  */
36651
36939
  id: string;
36652
36940
  };
@@ -40205,6 +40493,10 @@ export type DevopsUnitGit = {
40205
40493
  * The ref holding the unit's work in progress, or null when none was recorded.
40206
40494
  */
40207
40495
  wipRef: string | null;
40496
+ /**
40497
+ * The branch's head on the remote as of the last fetch: the value units push wants as expectedHead. Absent before the first observation or when the branch has no upstream. Call fetch first when someone else may have pushed.
40498
+ */
40499
+ remoteHead?: string;
40208
40500
  /**
40209
40501
  * RFC 3339 UTC time these facts were observed, or null before the first observation.
40210
40502
  */
@@ -41374,7 +41666,7 @@ export type MediaGenerationType = 'image' | 'video' | 'speech' | 'music' | 'soun
41374
41666
  * Edit operations: the change this step applied to its parent asset.
41375
41667
  */
41376
41668
  export type MediaGenerationOperation = 'generate' | 'clone' | 'tag' | 'untag' | 'set_context' | 'move' | 'delete' | 'reprocess' | 'variations' | 'upscale' | 'outpaint' | 'inpaint' | 'erase' | 'replace_object' | 'recolor' | 'remove_background' | 'replace_background' | 'to_video' | 'extend' | 'edit' | 'lip_sync' | 'frame' | 'to_gif' | 'voice_change' | 'resynthesize';
41377
- export type MediaMediaErrorCode = 'LIBRARY_NOT_FOUND' | 'ASSET_NOT_FOUND' | 'JOB_NOT_FOUND' | 'UNDERSTANDING_NOT_FOUND' | 'ASSET_VERSION_CHANGED' | 'LIBRARY_INVALID_STATE' | 'INVALID_PARAMS' | 'INVALID_EXPRESSION' | 'UNSUPPORTED' | 'NOT_IMPLEMENTED' | 'FILE_TOO_LARGE' | 'FILE_EMPTY' | 'FILE_NOT_READY' | 'UNSUPPORTED_MEDIA' | 'FETCH_FAILED' | 'LIMIT_EXCEEDED' | 'CHUNK_INVALID' | 'RATE_LIMITED' | 'CAPACITY' | 'UPSTREAM_FAILED' | 'CONTENT_REJECTED' | 'GENERATION_FAILED' | 'BINDING_READ_ONLY' | 'OPERATION_NOT_SUPPORTED' | 'MODEL_PENDING' | 'REFERENCE_TYPE_MISMATCH' | 'CONSENT_REQUIRED' | 'LIBRARY_IS_DEFAULT' | 'JOB_INVALID_STATE' | 'VOICE_TRAINING' | 'INSUFFICIENT_BALANCE';
41669
+ export type MediaMediaErrorCode = 'LIBRARY_NOT_FOUND' | 'ASSET_NOT_FOUND' | 'WORK_NOT_FOUND' | 'REVISION_CONFLICT' | 'JOB_NOT_FOUND' | 'UNDERSTANDING_NOT_FOUND' | 'ASSET_VERSION_CHANGED' | 'LIBRARY_INVALID_STATE' | 'INVALID_PARAMS' | 'INVALID_EXPRESSION' | 'UNSUPPORTED' | 'NOT_IMPLEMENTED' | 'FILE_TOO_LARGE' | 'FILE_EMPTY' | 'FILE_NOT_READY' | 'UNSUPPORTED_MEDIA' | 'FETCH_FAILED' | 'LIMIT_EXCEEDED' | 'CHUNK_INVALID' | 'RATE_LIMITED' | 'CAPACITY' | 'UPSTREAM_FAILED' | 'CONTENT_REJECTED' | 'GENERATION_FAILED' | 'BINDING_READ_ONLY' | 'OPERATION_NOT_SUPPORTED' | 'MODEL_PENDING' | 'REFERENCE_TYPE_MISMATCH' | 'CONSENT_REQUIRED' | 'LIBRARY_IS_DEFAULT' | 'JOB_INVALID_STATE' | 'VOICE_TRAINING' | 'INSUFFICIENT_BALANCE';
41378
41670
  /**
41379
41671
  * State of a requested generation output.
41380
41672
  */
@@ -41720,6 +42012,192 @@ export type MediaHlsRendition = {
41720
42012
  state: MediaHlsRenditionState;
41721
42013
  };
41722
42014
  export type MediaVoiceConsentId = string;
42015
+ /**
42016
+ * One referenced asset as expand=assets returns it: enough to draw it without another call.
42017
+ */
42018
+ export type MediaWorkAsset = {
42019
+ /**
42020
+ * The asset’s material type, such as image or video.
42021
+ */
42022
+ type: MediaMaterialType;
42023
+ /**
42024
+ * Short-lived delivery URL of the asset.
42025
+ */
42026
+ url: string;
42027
+ /**
42028
+ * Short-lived URL of a small picture: the poster of a video, otherwise the asset itself.
42029
+ */
42030
+ thumbnail_url: string;
42031
+ /**
42032
+ * Width in pixels when known.
42033
+ */
42034
+ width?: number;
42035
+ /**
42036
+ * Height in pixels when known.
42037
+ */
42038
+ height?: number;
42039
+ /**
42040
+ * The asset’s display name.
42041
+ */
42042
+ display_name: string;
42043
+ };
42044
+ /**
42045
+ * Body of a gallery (图文). Order is the order of items.
42046
+ */
42047
+ export type MediaGalleryBody = {
42048
+ /**
42049
+ * Title, 1 to 100 characters.
42050
+ */
42051
+ title: string;
42052
+ /**
42053
+ * Body text, at most 10000 characters.
42054
+ */
42055
+ text?: string;
42056
+ /**
42057
+ * Topics without the # sign, at most 30 of up to 40 characters.
42058
+ */
42059
+ topics?: Array<string>;
42060
+ /**
42061
+ * Optional cover: an image or sticker asset of this library; without it the first picture is the cover.
42062
+ */
42063
+ cover?: string;
42064
+ /**
42065
+ * Pictures, videos and text segments in order, 1 to 100 entries with at least one asset; each asset appears once.
42066
+ */
42067
+ items: Array<MediaGalleryItem>;
42068
+ /**
42069
+ * Display style; defaults to xiaohongshu in the Console.
42070
+ */
42071
+ style?: MediaWorkStyle;
42072
+ };
42073
+ /**
42074
+ * Body of an article (长文). Inline images live in the Markdown as ![alt](asset:<asset_id>) and sit where they are written.
42075
+ */
42076
+ export type MediaArticleBody = {
42077
+ /**
42078
+ * Title, 1 to 200 characters.
42079
+ */
42080
+ title: string;
42081
+ /**
42082
+ * Optional summary or digest, at most 500 characters.
42083
+ */
42084
+ summary?: string;
42085
+ /**
42086
+ * Optional author name, at most 60 characters.
42087
+ */
42088
+ author?: string;
42089
+ /**
42090
+ * The article in Markdown, 1 to 100000 characters; every asset:<asset_id> image must be an image or sticker of this library.
42091
+ */
42092
+ body: string;
42093
+ /**
42094
+ * Optional cover: an image or sticker asset of this library.
42095
+ */
42096
+ cover?: string;
42097
+ /**
42098
+ * Display style; defaults to wechat_mp in the Console.
42099
+ */
42100
+ style?: MediaWorkStyle;
42101
+ };
42102
+ /**
42103
+ * Body of a product listing (商品图组). Images and copy only: price, stock and other business data are managed outside the library and are refused.
42104
+ */
42105
+ export type MediaProductListingBody = {
42106
+ /**
42107
+ * Listing title, 1 to 200 characters.
42108
+ */
42109
+ title: string;
42110
+ /**
42111
+ * Selling points in order, at most 10 of up to 100 characters.
42112
+ */
42113
+ selling_points?: Array<string>;
42114
+ /**
42115
+ * Parameter rows in order, at most 50.
42116
+ */
42117
+ attributes?: Array<MediaListingAttribute>;
42118
+ /**
42119
+ * Main images in order, 1 to 20 image or sticker assets of this library.
42120
+ */
42121
+ main: Array<string>;
42122
+ /**
42123
+ * Detail images in order, at most 100 image or sticker assets of this library.
42124
+ */
42125
+ detail?: Array<string>;
42126
+ /**
42127
+ * SKUs in order, at most 200.
42128
+ */
42129
+ skus?: Array<MediaListingSku>;
42130
+ /**
42131
+ * Optional product element (material_type product) this listing shows.
42132
+ */
42133
+ product?: string;
42134
+ /**
42135
+ * Display style; defaults to generic in the Console.
42136
+ */
42137
+ style?: MediaWorkStyle;
42138
+ };
42139
+ /**
42140
+ * Body of a general work (通用作品): Editor.js saved data plus one field of ours, a required title. Business attributes go in the work’s custom, not in a block.
42141
+ */
42142
+ export type MediaBlocksBody = {
42143
+ /**
42144
+ * The work’s title, 1 to 200 characters, written explicitly as in the other kinds; lists and sorting use it.
42145
+ */
42146
+ title: string;
42147
+ /**
42148
+ * Optional Editor.js save time in milliseconds, kept as sent.
42149
+ */
42150
+ time?: number;
42151
+ /**
42152
+ * The blocks in order, 1 to 500.
42153
+ */
42154
+ blocks: Array<MediaEditorBlock>;
42155
+ /**
42156
+ * Optional Editor.js version string, kept as sent.
42157
+ */
42158
+ version?: string;
42159
+ };
42160
+ /**
42161
+ * One work in a list.
42162
+ */
42163
+ export type MediaWorkSummary = {
42164
+ /**
42165
+ * Always work.
42166
+ */
42167
+ object: 'work';
42168
+ /**
42169
+ * Work id (wrk_…).
42170
+ */
42171
+ id: string;
42172
+ /**
42173
+ * The work’s kind.
42174
+ */
42175
+ kind: MediaWorkKind;
42176
+ /**
42177
+ * The work’s title.
42178
+ */
42179
+ title: string;
42180
+ /**
42181
+ * The work’s series, or null.
42182
+ */
42183
+ series: string | null;
42184
+ /**
42185
+ * Short-lived URL of the cover picture, or null when it is missing.
42186
+ */
42187
+ cover_url: string | null;
42188
+ /**
42189
+ * How many distinct assets the body orders, cover and product element excluded.
42190
+ */
42191
+ item_count: number;
42192
+ /**
42193
+ * How many referenced assets have been deleted since.
42194
+ */
42195
+ missing_count: number;
42196
+ /**
42197
+ * When the work last changed.
42198
+ */
42199
+ updated_at: MediaIsoTimestamp;
42200
+ };
41723
42201
  /**
41724
42202
  * A kind of entity the graph accepts, for example a file or a customer.
41725
42203
  */
@@ -48068,7 +48546,7 @@ export type DevopsPlannedSkip = {
48068
48546
  /**
48069
48547
  * Why it is left out, which is what tells a deliberate skip apart from an oversight.
48070
48548
  */
48071
- reason: 'unchanged' | 'newer_checkpoint' | 'not_requested' | 'callee_excluded' | 'artifact_identical';
48549
+ reason: 'unchanged' | 'newer_checkpoint' | 'not_requested' | 'callee_excluded' | 'not_deployed_upstream' | 'artifact_identical';
48072
48550
  };
48073
48551
  /**
48074
48552
  * The migrations one target has pending, as the plan found them.
@@ -48704,7 +49182,7 @@ export type MediaSemanticMatch = {
48704
49182
  /**
48705
49183
  * Type of change recorded for a library, asset, processing task, search index or batch.
48706
49184
  */
48707
- export type MediaMediaEventType = 'library.status_provisioning' | 'library.status_active' | 'library.status_deleting' | 'library.status_deleted' | 'library.status_failed' | 'library.restored' | 'library.updated' | 'asset.created' | 'asset.updated' | 'asset.overwritten' | 'asset.renamed' | 'asset.deleted' | 'understanding.status_ready' | 'understanding.status_failed' | 'understanding.status_unsupported' | 'search.indexed' | 'batch.succeeded' | 'batch.failed' | 'library.understanding_drained' | 'batch.created' | 'hls.requested' | 'generation.created' | 'generation.succeeded' | 'generation.failed' | 'generation.cancelled';
49185
+ export type MediaMediaEventType = 'library.status_provisioning' | 'library.status_active' | 'library.status_deleting' | 'library.status_deleted' | 'library.status_failed' | 'library.restored' | 'library.updated' | 'asset.created' | 'asset.updated' | 'asset.overwritten' | 'asset.renamed' | 'asset.deleted' | 'understanding.status_ready' | 'understanding.status_failed' | 'understanding.status_unsupported' | 'search.indexed' | 'batch.succeeded' | 'batch.failed' | 'library.understanding_drained' | 'batch.created' | 'hls.requested' | 'generation.created' | 'generation.succeeded' | 'generation.failed' | 'generation.cancelled' | 'work.created' | 'work.updated' | 'work.deleted';
48708
49186
  /**
48709
49187
  * One picture an element names, with the word the caller uses for that view.
48710
49188
  */
@@ -48800,6 +49278,75 @@ export type MediaGenerationCapabilityModel = {
48800
49278
  * Readiness of one rung or of the ladder it is part of.
48801
49279
  */
48802
49280
  export type MediaHlsRenditionState = 'processing' | 'ready' | 'failed';
49281
+ /**
49282
+ * One position of a gallery: a picture or video of this library ({asset_id, caption?}) or a text segment between pictures ({text}).
49283
+ */
49284
+ export type MediaGalleryItem = {
49285
+ /**
49286
+ * An image, sticker or video asset of this library; its position in items is its position in the gallery.
49287
+ */
49288
+ asset_id: string;
49289
+ /**
49290
+ * Optional caption for this picture, at most 1000 characters.
49291
+ */
49292
+ caption?: string;
49293
+ } | {
49294
+ /**
49295
+ * A text segment shown between pictures, at most 1000 characters.
49296
+ */
49297
+ text: string;
49298
+ };
49299
+ /**
49300
+ * Which platform look the Console draws the work in; a display hint, never a platform check.
49301
+ */
49302
+ export type MediaWorkStyle = 'xiaohongshu' | 'wechat_mp' | 'jike' | 'generic';
49303
+ /**
49304
+ * One parameter row of a listing.
49305
+ */
49306
+ export type MediaListingAttribute = {
49307
+ /**
49308
+ * Parameter name such as 容量, at most 40 characters.
49309
+ */
49310
+ name: string;
49311
+ /**
49312
+ * Parameter value such as 500ml, at most 200 characters.
49313
+ */
49314
+ value: string;
49315
+ };
49316
+ /**
49317
+ * One SKU of a listing.
49318
+ */
49319
+ export type MediaListingSku = {
49320
+ /**
49321
+ * The SKU’s value on each spec axis, such as {"颜色":"白"}; 1 to 5 axes; the keys are kept as written.
49322
+ */
49323
+ spec: {
49324
+ [key: string]: string;
49325
+ };
49326
+ /**
49327
+ * Optional picture of this SKU: an image or sticker asset of this library.
49328
+ */
49329
+ asset_id?: string;
49330
+ };
49331
+ /**
49332
+ * One Editor.js block, as Editor.js saves it. type is one of the official blocks: paragraph {text}, header {text, level 1–6}, list {style ordered|unordered|checklist, meta, items[{content, meta, items}]}, quote {text, caption, alignment left|center}, delimiter {}, image, table {withHeadings, stretched, content string[][]}, checklist {items[{text, checked}]}, warning {title, message}, embed {service, source, embed, width, height, caption}. The one departure from Editor.js: an image block is {asset_id, caption, withBorder, withBackground, stretched} and names an image or sticker asset of this library instead of file.url. Text keeps Editor.js inline HTML. Unknown types and fields are refused.
49333
+ */
49334
+ export type MediaEditorBlock = {
49335
+ /**
49336
+ * Block id, 1–64 letters, digits, _ or -, unique in the body.
49337
+ */
49338
+ id: string;
49339
+ /**
49340
+ * The official Editor.js block type.
49341
+ */
49342
+ type: 'paragraph' | 'header' | 'list' | 'quote' | 'delimiter' | 'image' | 'table' | 'checklist' | 'warning' | 'embed';
49343
+ /**
49344
+ * The block’s data in that type’s Editor.js shape.
49345
+ */
49346
+ data: {
49347
+ [key: string]: unknown;
49348
+ };
49349
+ };
48803
49350
  /**
48804
49351
  * Auto-resume enabled flag for paused sandboxes. Default false.
48805
49352
  */
@@ -50923,6 +51470,58 @@ export type UpdateMediaPipelineRequestWritable = {
50923
51470
  * Models to use for completion
50924
51471
  */
50925
51472
  export type OpenaiChatModelNamesWritable = Array<OpenaiModelName & unknown>;
51473
+ export type SandboxSandboxDetailWritable = {
51474
+ /**
51475
+ * Identifier of the template from which is the sandbox created
51476
+ */
51477
+ templateID: string;
51478
+ /**
51479
+ * Alias of the template
51480
+ */
51481
+ alias?: string;
51482
+ /**
51483
+ * Identifier of the sandbox
51484
+ */
51485
+ sandboxID: string;
51486
+ /**
51487
+ * Identifier of the client
51488
+ *
51489
+ * @deprecated
51490
+ */
51491
+ clientID: string;
51492
+ /**
51493
+ * Time when the sandbox was started
51494
+ */
51495
+ startedAt: string;
51496
+ /**
51497
+ * Time when the sandbox will expire
51498
+ */
51499
+ endAt: string;
51500
+ envdVersion: SandboxEnvdVersion;
51501
+ /**
51502
+ * Access token used for envd communication
51503
+ */
51504
+ envdAccessToken?: string;
51505
+ /**
51506
+ * Whether internet access was explicitly enabled or disabled for the sandbox. Null means it was not explicitly set.
51507
+ */
51508
+ allowInternetAccess?: boolean;
51509
+ /**
51510
+ * Base domain where the sandbox traffic is accessible
51511
+ */
51512
+ domain?: string;
51513
+ cpuCount: SandboxCpuCount;
51514
+ memoryMB: SandboxMemoryMb;
51515
+ diskSizeMB: SandboxDiskSizeMb;
51516
+ metadata?: SandboxSandboxMetadata;
51517
+ state: SandboxSandboxState;
51518
+ network?: SandboxSandboxNetworkConfigWritable;
51519
+ lifecycle?: SandboxSandboxLifecycle;
51520
+ /**
51521
+ * Volumes mounted into the sandbox.
51522
+ */
51523
+ volumeMounts?: Array<SandboxSandboxVolumeMount>;
51524
+ };
50926
51525
  /**
50927
51526
  * Free-form string key/value pairs stored with the session, changed through sessions.update patch semantics.
50928
51527
  */
@@ -51502,6 +52101,94 @@ export type MediaSemanticSearchResultWritable = {
51502
52101
  */
51503
52102
  not_ready_excluded: number;
51504
52103
  };
52104
+ /**
52105
+ * Sandbox creation request. All system communication with the sandbox is always secured; the template's envd version must support secured access.
52106
+ */
52107
+ export type SandboxNewSandboxV2Writable = {
52108
+ /**
52109
+ * Identifier of the required template
52110
+ */
52111
+ templateID: string;
52112
+ /**
52113
+ * Lifetime of the new sandbox in seconds. Defaults to 300 seconds when omitted.
52114
+ */
52115
+ timeout?: number;
52116
+ /**
52117
+ * Lifecycle declaration on the E2B-compatible face. true creates a persistent sandbox that pauses at its timeout and can be resumed; false or absent creates an ephemeral sandbox that ends at its timeout and keeps nothing. Keep true only for long-lived computers. The own face declares with ephemeral instead.
52118
+ */
52119
+ autoPause?: boolean;
52120
+ /**
52121
+ * Controls the snapshot kind taken when the sandbox auto-pauses on timeout (only relevant when autoPause is true). When false, the auto-pause drops the in-memory state and persists only the filesystem (a filesystem-only snapshot); resuming it cold-boots (reboots) the sandbox from disk. Such a snapshot cannot be auto-resumed by traffic and must be resumed explicitly, so it cannot be combined with autoResume. Defaults to true (full memory snapshot).
52122
+ */
52123
+ autoPauseMemory?: boolean;
52124
+ autoResume?: SandboxSandboxAutoResumeConfig;
52125
+ /**
52126
+ * Allow sandbox to access the internet. When set to false, it behaves the same as specifying denyOut to 0.0.0.0/0 in the network config.
52127
+ */
52128
+ allow_internet_access?: boolean;
52129
+ network?: SandboxSandboxNetworkConfigWritable;
52130
+ metadata?: SandboxSandboxMetadata;
52131
+ envVars?: SandboxEnvVars;
52132
+ mcp?: SandboxMcp;
52133
+ iam?: SandboxSandboxIam;
52134
+ /**
52135
+ * Volumes to mount into the sandbox, each with the volume name and the path inside the sandbox.
52136
+ */
52137
+ volumeMounts?: Array<SandboxSandboxVolumeMount>;
52138
+ /**
52139
+ * Own face, required unless sku is named: true for an ephemeral sandbox (ends at its timeout, never pauses, cannot be snapshotted), false for a persistent one (pauses, resumes, snapshots, mounts volumes). Leaving it out returns INVALID_PARAMS.
52140
+ */
52141
+ ephemeral?: boolean;
52142
+ /**
52143
+ * Own face: the machine size, a SKU id such as base-2c4g or, for an android phone, android-2c4g. Omitted, the template's default size is used.
52144
+ */
52145
+ size?: string;
52146
+ /**
52147
+ * Own face: a display name for the sandbox, 1 to 64 characters. Omitted, one is generated from the template.
52148
+ */
52149
+ name?: string;
52150
+ /**
52151
+ * Own face, android phones only: keep the create open until the phone is running or 55 seconds have passed since the request arrived; running out is not an error and answers the state reached.
52152
+ */
52153
+ waitForReady?: boolean;
52154
+ /**
52155
+ * Own face: what happens at the timeout. pause needs ephemeral: false; must agree with autoPause when both are sent.
52156
+ */
52157
+ onExpire?: 'kill' | 'pause';
52158
+ /**
52159
+ * Own face, persistent sandboxes only: pause after this many milliseconds without activity; null turns the idle pause off.
52160
+ */
52161
+ idleTimeout?: number;
52162
+ /**
52163
+ * Own face, persistent sandboxes only: whose activity resets idleTimeout. traffic (default) counts data-plane calls, preview traffic and live processes; caller counts only your own control-plane calls.
52164
+ */
52165
+ idleActivity?: 'traffic' | 'caller';
52166
+ /**
52167
+ * Own face: a demand-profile SKU <kind>.<image>.<size>, such as run.document.medium (someone waits; starts fast), job.base.large (background work that must not be cut off), batch.base.large (retried work that may be reclaimed) or computer.base.medium (keeps its disk). It fixes ephemeral, interruptible, size and the template, so those may be left out; any of them you also send must agree with it, otherwise the create fails with INVALID_PARAMS naming the field. The sandbox answers it back as sku and as the read-only label praxis.sku.
52168
+ */
52169
+ sku?: string;
52170
+ /**
52171
+ * Own face: the kind of sandbox you need, when you do not name a full sku. The sandbox completes <kind>.<image>.<size> from the template you start (its family, or custom for your own environment or snapshot) and the size you send, or medium. run is for work someone waits for (starts fast), job is background work that must not be cut off, batch is retried work that may be reclaimed (spot capacity), computer keeps its disk, and compat is the E2B-compatible persistent series. The kind fixes ephemeral and interruptible, so leave those out; if you also send them, or a sku of another kind, the create fails with INVALID_PARAMS naming the field. The light template always starts the light shell, whatever the kind says.
52172
+ */
52173
+ kind?: 'run' | 'job' | 'batch' | 'computer' | 'compat';
52174
+ /**
52175
+ * Own face, ephemeral sandboxes only: true says this sandbox may be reclaimed while it runs (a build or test you retry), which lets it run on cheaper spot capacity. A reclaimed sandbox ends with PROVIDER_FAILED; create it again. Absent or false keeps the usual capacity.
52176
+ */
52177
+ interruptible?: boolean;
52178
+ /**
52179
+ * Own face, persistent sandboxes only: what happens when the provider loses the machine. fail (default) ends the sandbox; rebuild starts a new machine under the same id with its state lost.
52180
+ */
52181
+ onLoss?: 'fail' | 'rebuild';
52182
+ /**
52183
+ * Own face: up to eight absolute paths to keep when the sandbox ends; each is packed as .tar.gz into File and listed on the killed event.
52184
+ */
52185
+ outputs?: Array<{
52186
+ /**
52187
+ * Absolute path of a directory or file inside the sandbox.
52188
+ */
52189
+ path: string;
52190
+ }>;
52191
+ };
51505
52192
  /**
51506
52193
  * Arguments the model passed to the tool.
51507
52194
  */
@@ -51580,6 +52267,43 @@ export type AnthropicAnonymous204Writable = {
51580
52267
  export type AnthropicAnonymous206Writable = {
51581
52268
  [key: string]: unknown;
51582
52269
  };
52270
+ /**
52271
+ * Network policy of the sandbox: public access, egress allow and deny lists and proxy.
52272
+ */
52273
+ export type SandboxSandboxNetworkConfigWritable = {
52274
+ /**
52275
+ * Specify if the sandbox URLs should be accessible only with authentication.
52276
+ */
52277
+ allowPublicTraffic?: boolean;
52278
+ /**
52279
+ * List of allowed destinations for egress traffic. Each entry can be a CIDR block (e.g. "8.8.8.8/32"), a bare IP address (e.g. "8.8.8.8"), or a domain name (e.g. "example.com", "*.example.com"). Allowed entries always take precedence over denied entries.
52280
+ */
52281
+ allowOut?: Array<string>;
52282
+ /**
52283
+ * List of denied CIDR blocks or IP addresses for egress traffic. Domain names are not supported for deny rules.
52284
+ */
52285
+ denyOut?: Array<string>;
52286
+ egressProxy?: SandboxSandboxEgressProxyConfig;
52287
+ /**
52288
+ * Specify host mask which will be used for all sandbox requests
52289
+ */
52290
+ maskRequestHost?: string;
52291
+ /**
52292
+ * Unlike E2B, network.httpsPorts is rejected; omit it when creating a sandbox.
52293
+ */
52294
+ httpsPorts?: Array<number>;
52295
+ /**
52296
+ * Per-domain transform rules applied to matching outbound HTTPS requests. Keys may be exact DNS names (for example, "api.example.com") or a leading wildcard (for example, "*.example.com"), and are normalized to lowercase on write. Wildcards match subdomains at any depth but not the apex domain; a bare "*" is invalid. Exact rules take precedence, followed by the longest matching wildcard suffix, and matching rule sets are not merged. Broad wildcards such as "*.com" are allowed and may expose transformed credentials to every matching destination the sandbox contacts. Rules do not grant network access; configure allowOut separately to permit the destination.
52297
+ *
52298
+ */
52299
+ rules?: {
52300
+ [key: string]: Array<SandboxSandboxNetworkRule>;
52301
+ };
52302
+ /**
52303
+ * Own face, persistent sandboxes only (autoPause: true, or ephemeral: false): true gives the sandbox one fixed public egress IP for its whole life, held through pause and resume and released when the sandbox is deleted. Without it the egress IP is not stable: it changes when a spot machine is reclaimed, when a paused machine starts again, and when the machine is rebuilt. An ephemeral sandbox returns INVALID_PARAMS; the E2B face refuses the field; it is placed only on capacity that declares static IPs, and without such capacity the create does not start (it never falls back to a changing IP). Billed as the usage item sandbox:public_ip:hours from allocation to release, paused time included, plus outbound traffic as usual.
52304
+ */
52305
+ staticEgressIp?: boolean;
52306
+ };
51583
52307
  /**
51584
52308
  * Free-form string key/value pairs.
51585
52309
  */
@@ -54307,6 +55031,86 @@ export type ListAgentInboxLettersResponses = {
54307
55031
  };
54308
55032
  };
54309
55033
  export type ListAgentInboxLettersResponse = ListAgentInboxLettersResponses[keyof ListAgentInboxLettersResponses];
55034
+ export type ListAgentDeviceLocalSessionsData = {
55035
+ body?: never;
55036
+ path: {
55037
+ /**
55038
+ * The BYOA agent: its agent_… id, eight character identity number or handle, from agents.list; resolved in your organization. Also accepts an 8-character identity number (0–9, A–Z); malformed, absent and foreign references return 404, and response ids always use agent_….
55039
+ */
55040
+ agent_id: string;
55041
+ /**
55042
+ * The paired desktop device (byd_ and 26 hex characters) whose sessions to list; you must be the person who paired it.
55043
+ */
55044
+ device_id: string;
55045
+ };
55046
+ query: {
55047
+ /**
55048
+ * The absolute directory on the device, exactly as the device registered it and bound it to this agent.
55049
+ */
55050
+ cwd: string;
55051
+ /**
55052
+ * The next_cursor of the previous page; leave it out for the first page.
55053
+ */
55054
+ cursor?: string;
55055
+ };
55056
+ url: '/agent/v1/agents/{agent_id}/devices/{device_id}/local-sessions';
55057
+ };
55058
+ export type ListAgentDeviceLocalSessionsErrors = {
55059
+ /**
55060
+ * INVALID_PARAMS: cwd is missing, not absolute or not bound to this agent on that device, the device is not one you paired, or a query parameter is unsupported; ASSUME_AGENT_REQUIRED: the agent is not a BYOA agent.
55061
+ */
55062
+ 400: unknown;
55063
+ /**
55064
+ * Authenticate with your own API key or a console session; an agent's or robot's credential cannot list a person's device.
55065
+ */
55066
+ 401: unknown;
55067
+ /**
55068
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
55069
+ */
55070
+ 403: AgentError;
55071
+ /**
55072
+ * AGENT_NOT_FOUND: no agent with this reference exists in your organization; list agents with agents.list.
55073
+ */
55074
+ 404: unknown;
55075
+ /**
55076
+ * DEVICE_NOT_READY: the device is offline; retry once it is connected. DEVICE_TIMEOUT (504) means it is connected but did not answer in time.
55077
+ */
55078
+ 503: unknown;
55079
+ };
55080
+ export type ListAgentDeviceLocalSessionsError = ListAgentDeviceLocalSessionsErrors[keyof ListAgentDeviceLocalSessionsErrors];
55081
+ export type ListAgentDeviceLocalSessionsResponses = {
55082
+ /**
55083
+ * One page of the device's sessions for that directory, newest first.
55084
+ */
55085
+ 200: {
55086
+ /**
55087
+ * The sessions of this page; empty when the directory has none.
55088
+ */
55089
+ data: Array<{
55090
+ /**
55091
+ * The Claude Code session id on the device; pass it as runtime.resume_session_id when creating a session to continue it.
55092
+ */
55093
+ id: string;
55094
+ /**
55095
+ * The session's title as Claude Code shows it; empty when it has none.
55096
+ */
55097
+ title: string;
55098
+ /**
55099
+ * When the session was last written to, RFC 3339; sessions are ordered newest first.
55100
+ */
55101
+ updated_at: string | null;
55102
+ /**
55103
+ * The directory the session ran in on the device.
55104
+ */
55105
+ cwd: string | null;
55106
+ }>;
55107
+ /**
55108
+ * Pass as cursor for the next page; null on the last page.
55109
+ */
55110
+ next_cursor: string | null;
55111
+ };
55112
+ };
55113
+ export type ListAgentDeviceLocalSessionsResponse = ListAgentDeviceLocalSessionsResponses[keyof ListAgentDeviceLocalSessionsResponses];
54310
55114
  export type CreateAgentLoginIntentData = {
54311
55115
  body?: never;
54312
55116
  path?: never;
@@ -55207,6 +56011,15 @@ export type ApplyAgentVersionResponses = {
55207
56011
  name: string;
55208
56012
  }>;
55209
56013
  };
56014
+ /**
56015
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
56016
+ */
56017
+ browser?: {
56018
+ /**
56019
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
56020
+ */
56021
+ byob: string;
56022
+ } | null;
55210
56023
  /**
55211
56024
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
55212
56025
  */
@@ -55592,7 +56405,7 @@ export type ApplyAgentVersionResponses = {
55592
56405
  */
55593
56406
  environment_id?: string | null;
55594
56407
  /**
55595
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
56408
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
55596
56409
  */
55597
56410
  vault_ids?: Array<string>;
55598
56411
  /**
@@ -56458,6 +57271,15 @@ export type UnarchiveAgentResponses = {
56458
57271
  name: string;
56459
57272
  }>;
56460
57273
  };
57274
+ /**
57275
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
57276
+ */
57277
+ browser?: {
57278
+ /**
57279
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
57280
+ */
57281
+ byob: string;
57282
+ } | null;
56461
57283
  /**
56462
57284
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
56463
57285
  */
@@ -56843,7 +57665,7 @@ export type UnarchiveAgentResponses = {
56843
57665
  */
56844
57666
  environment_id?: string | null;
56845
57667
  /**
56846
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
57668
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
56847
57669
  */
56848
57670
  vault_ids?: Array<string>;
56849
57671
  /**
@@ -59312,9 +60134,13 @@ export type ComputersRetrieveResponse = ComputersRetrieveResponses[keyof Compute
59312
60134
  export type ComputersUpdateData = {
59313
60135
  body: {
59314
60136
  /**
59315
- * Name of the entry or object.
60137
+ * New display name, 1 to 255 characters after trimming. Omit to keep the current name.
59316
60138
  */
59317
- name: string;
60139
+ name?: string;
60140
+ /**
60141
+ * Environment recipe the computer declares (agent.environments.list or agent.environments.create, or a built-in id). A string sets the declaration and is checked as in computers.create: an unknown, foreign or archived environment is refused. null removes the declaration. Omit to leave it unchanged. Only the record changes: the machine is not touched or restarted, so the new declaration applies from the computer's next start; restart the computer once to apply it at once.
60142
+ */
60143
+ environment_id?: string | null;
59318
60144
  };
59319
60145
  path: {
59320
60146
  /**
@@ -61484,7 +62310,7 @@ export type ComputersFilesConvertResponse = ComputersFilesConvertResponses[keyof
61484
62310
  export type ConnectComputerData = {
61485
62311
  body?: {
61486
62312
  /**
61487
- * Defaults to light. light uses the lightweight shell, or the heavy instance while it is running. heavy requests a full Linux computer for interactive programs; heavy running time counts toward the daily budget in seconds.
62313
+ * Accepted for compatibility and ignored: light and heavy both reach the same machine, because a Computer is one machine. Omit it.
61488
62314
  */
61489
62315
  need?: 'light' | 'heavy';
61490
62316
  };
@@ -69088,7 +69914,7 @@ export type BrowserListSessionsErrors = {
69088
69914
  */
69089
69915
  402: BrowserError;
69090
69916
  /**
69091
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69917
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69092
69918
  */
69093
69919
  403: BrowserError;
69094
69920
  /**
@@ -69169,7 +69995,7 @@ export type BrowserCreateSessionErrors = {
69169
69995
  */
69170
69996
  402: BrowserError;
69171
69997
  /**
69172
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69998
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69173
69999
  */
69174
70000
  403: BrowserError;
69175
70001
  /**
@@ -69255,7 +70081,7 @@ export type BrowserGetSessionErrors = {
69255
70081
  */
69256
70082
  402: BrowserError;
69257
70083
  /**
69258
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70084
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69259
70085
  */
69260
70086
  403: BrowserError;
69261
70087
  /**
@@ -69337,7 +70163,7 @@ export type BrowserCloseSessionErrors = {
69337
70163
  */
69338
70164
  402: BrowserError;
69339
70165
  /**
69340
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70166
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69341
70167
  */
69342
70168
  403: BrowserError;
69343
70169
  /**
@@ -69414,7 +70240,7 @@ export type BrowserGetDebugErrors = {
69414
70240
  */
69415
70241
  402: BrowserError;
69416
70242
  /**
69417
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70243
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69418
70244
  */
69419
70245
  403: BrowserError;
69420
70246
  /**
@@ -69504,7 +70330,7 @@ export type BrowserListEventsErrors = {
69504
70330
  */
69505
70331
  402: BrowserError;
69506
70332
  /**
69507
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70333
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69508
70334
  */
69509
70335
  403: BrowserError;
69510
70336
  /**
@@ -69754,6 +70580,78 @@ export type BrowserRunPageActionData = {
69754
70580
  * 标签页 ID,来自 tabs.list 或上一个动作的结果;省略时作用于当前标签页。
69755
70581
  */
69756
70582
  tab?: string;
70583
+ } | {
70584
+ /**
70585
+ * 动作类型,固定为 route。
70586
+ */
70587
+ type: 'route';
70588
+ /**
70589
+ * 要匹配的请求地址:glob(* 不跨 /,** 跨 /,** 匹配零段或更多路径段)或用 /…/ 包起来的正则;最多 2048 个字符,写错在注册时即返回 400 INVALID_PARAMS。
70590
+ */
70591
+ url: string;
70592
+ /**
70593
+ * 只匹配这个 HTTP 方法(不区分大小写);省略则匹配所有方法。
70594
+ */
70595
+ method?: string;
70596
+ /**
70597
+ * 标签页 ID,来自 tabs.list 或上一个动作的结果;省略时作用于当前标签页。
70598
+ */
70599
+ tab?: string;
70600
+ /**
70601
+ * 命中后的处理方式,由 kind 选择:fulfill 直接返回给定响应,abort 让请求失败,delay 按原样转发但推迟给定的毫秒数。
70602
+ */
70603
+ response: {
70604
+ /**
70605
+ * 直接返回给定响应。
70606
+ */
70607
+ kind: 'fulfill';
70608
+ /**
70609
+ * 返回的 HTTP 状态码,100 到 599。
70610
+ */
70611
+ status: number;
70612
+ /**
70613
+ * 返回的响应头,名 → 值;最多 100 项。
70614
+ */
70615
+ headers?: {
70616
+ [key: string]: string;
70617
+ };
70618
+ /**
70619
+ * 返回的响应体,最多 1000000 个字符。
70620
+ */
70621
+ body?: string;
70622
+ } | {
70623
+ /**
70624
+ * 让请求失败,页面看到一次网络错误。
70625
+ */
70626
+ kind: 'abort';
70627
+ /**
70628
+ * Playwright 的错误码;省略为 failed。
70629
+ */
70630
+ error?: 'aborted' | 'accessdenied' | 'addressunreachable' | 'blockedbyclient' | 'blockedbyresponse' | 'connectionaborted' | 'connectionclosed' | 'connectionfailed' | 'connectionrefused' | 'connectionreset' | 'internetdisconnected' | 'namenotresolved' | 'timedout' | 'failed';
70631
+ } | {
70632
+ /**
70633
+ * 按原样转发请求,但推迟给定毫秒数,用来观察页面的加载态。
70634
+ */
70635
+ kind: 'delay';
70636
+ /**
70637
+ * 推迟的毫秒数,0 到 60000;超出返回 400 INVALID_PARAMS。
70638
+ */
70639
+ ms: number;
70640
+ };
70641
+ } | {
70642
+ /**
70643
+ * 动作类型,固定为 unroute。
70644
+ */
70645
+ type: 'unroute';
70646
+ /**
70647
+ * route 动作返回的规则 ID;不存在时 removed 为 false,不报错。
70648
+ */
70649
+ routeId: string;
70650
+ } | {
70651
+ /**
70652
+ * 动作类型,固定为 routes。
70653
+ */
70654
+ type: 'routes';
69757
70655
  } | {
69758
70656
  /**
69759
70657
  * 动作类型:后退、前进或刷新当前页。
@@ -69787,7 +70685,7 @@ export type BrowserRunPageActionErrors = {
69787
70685
  */
69788
70686
  402: BrowserError;
69789
70687
  /**
69790
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70688
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
69791
70689
  */
69792
70690
  403: BrowserError;
69793
70691
  /**
@@ -69972,265 +70870,74 @@ export type BrowserRunPageActionResponses = {
69972
70870
  * 已设置的 cookie 的域。
69973
70871
  */
69974
70872
  domain: string;
69975
- };
69976
- };
69977
- export type BrowserRunPageActionResponse = BrowserRunPageActionResponses[keyof BrowserRunPageActionResponses];
69978
- export type BrowserRequestHandoffData = {
69979
- body: {
70873
+ } | {
69980
70874
  /**
69981
- * 交给人工操作者的接管说明,可为空字符串。
70875
+ * 动作类型,固定为 route。
69982
70876
  */
69983
- message: string;
70877
+ type: 'route';
69984
70878
  /**
69985
- * 接管请求有效时长,单位为毫秒;必须大于 0,可含小数。超过 3600000(60 分钟)的按 60 分钟算,返回事件里的到期时刻就是实际值。接管未完成、未到期期间,会话不按空闲回收;接管结束后重新开始计空闲。
70879
+ * 新规则的 ID,后续 unroute 用它移除;规则的作用域是会话,会话结束时随之清除。
69986
70880
  */
69987
- timeoutMs?: number;
69988
- };
69989
- path: {
70881
+ routeId: string;
70882
+ } | {
69990
70883
  /**
69991
- * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
70884
+ * 动作类型,固定为 unroute。
69992
70885
  */
69993
- sessionId: string;
69994
- };
69995
- query?: never;
69996
- url: '/browser/v1/sessions/{sessionId}/handoff';
69997
- };
69998
- export type BrowserRequestHandoffErrors = {
69999
- /**
70000
- * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
70001
- */
70002
- 400: BrowserError;
70003
- /**
70004
- * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
70005
- */
70006
- 401: BrowserError;
70007
- /**
70008
- * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
70009
- */
70010
- 402: BrowserError;
70011
- /**
70012
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70013
- */
70014
- 403: BrowserError;
70015
- /**
70016
- * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
70017
- */
70018
- 404: BrowserError;
70019
- /**
70020
- * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
70021
- */
70022
- 409: BrowserError;
70023
- /**
70024
- * BROWSER_REVOKED
70025
- */
70026
- 410: BrowserError;
70027
- /**
70028
- * ACTION_RESULT_TOO_LARGE
70029
- */
70030
- 413: BrowserError;
70031
- /**
70032
- * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
70033
- */
70034
- 429: BrowserError;
70035
- /**
70036
- * INTERNAL
70037
- */
70038
- 500: BrowserError;
70039
- /**
70040
- * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
70041
- */
70042
- 501: BrowserError;
70043
- /**
70044
- * PROVIDER_FAILED
70045
- */
70046
- 502: BrowserError;
70047
- /**
70048
- * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
70049
- */
70050
- 503: BrowserError;
70051
- /**
70052
- * ACTION_TIMEOUT
70053
- */
70054
- 504: BrowserError;
70055
- };
70056
- export type BrowserRequestHandoffError = BrowserRequestHandoffErrors[keyof BrowserRequestHandoffErrors];
70057
- export type BrowserRequestHandoffResponses = {
70058
- /**
70059
- * 请求成功。
70060
- */
70061
- 201: BrowserEventRecord;
70062
- };
70063
- export type BrowserRequestHandoffResponse = BrowserRequestHandoffResponses[keyof BrowserRequestHandoffResponses];
70064
- export type BrowserCompleteHandoffData = {
70065
- body?: never;
70066
- path: {
70886
+ type: 'unroute';
70067
70887
  /**
70068
- * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
70888
+ * 请求移除的规则 ID。
70069
70889
  */
70070
- sessionId: string;
70071
- };
70072
- query?: never;
70073
- url: '/browser/v1/sessions/{sessionId}/handoff/complete';
70074
- };
70075
- export type BrowserCompleteHandoffErrors = {
70076
- /**
70077
- * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
70078
- */
70079
- 400: BrowserError;
70080
- /**
70081
- * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
70082
- */
70083
- 401: BrowserError;
70084
- /**
70085
- * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
70086
- */
70087
- 402: BrowserError;
70088
- /**
70089
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70090
- */
70091
- 403: BrowserError;
70092
- /**
70093
- * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
70094
- */
70095
- 404: BrowserError;
70096
- /**
70097
- * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
70098
- */
70099
- 409: BrowserError;
70100
- /**
70101
- * BROWSER_REVOKED
70102
- */
70103
- 410: BrowserError;
70104
- /**
70105
- * ACTION_RESULT_TOO_LARGE
70106
- */
70107
- 413: BrowserError;
70108
- /**
70109
- * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
70110
- */
70111
- 429: BrowserError;
70112
- /**
70113
- * INTERNAL
70114
- */
70115
- 500: BrowserError;
70116
- /**
70117
- * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
70118
- */
70119
- 501: BrowserError;
70120
- /**
70121
- * PROVIDER_FAILED
70122
- */
70123
- 502: BrowserError;
70124
- /**
70125
- * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
70126
- */
70127
- 503: BrowserError;
70128
- /**
70129
- * ACTION_TIMEOUT
70130
- */
70131
- 504: BrowserError;
70132
- };
70133
- export type BrowserCompleteHandoffError = BrowserCompleteHandoffErrors[keyof BrowserCompleteHandoffErrors];
70134
- export type BrowserCompleteHandoffResponses = {
70135
- /**
70136
- * 请求成功。
70137
- */
70138
- 200: BrowserEventRecord;
70139
- };
70140
- export type BrowserCompleteHandoffResponse = BrowserCompleteHandoffResponses[keyof BrowserCompleteHandoffResponses];
70141
- export type BrowserViewerHeartbeatData = {
70142
- body: {
70890
+ routeId: string;
70143
70891
  /**
70144
- * 当前观看者的稳定标识;同一观看者重复心跳应使用相同值,长度为 1–128 个 UTF-16 代码单元。
70892
+ * 是否真的移除了一条规则;ID 不存在时为 false。
70145
70893
  */
70146
- viewerId: string;
70894
+ removed: boolean;
70895
+ } | {
70147
70896
  /**
70148
- * 观看者类型:control 是需要控制浏览器的客户端,readonly 是只读观看者。只读观看者发送 control 也会按 readonly 记录。
70897
+ * 动作类型,固定为 routes。
70149
70898
  */
70150
- kind?: 'control' | 'readonly';
70151
- };
70152
- path: {
70899
+ type: 'routes';
70153
70900
  /**
70154
- * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
70901
+ * 当前会话上的规则,按注册顺序;多条都匹配时后注册的优先。
70155
70902
  */
70156
- sessionId: string;
70903
+ routes: Array<{
70904
+ /**
70905
+ * 规则 ID,注册时由服务端生成并返回。
70906
+ */
70907
+ routeId: string;
70908
+ /**
70909
+ * 规则匹配的地址模式。
70910
+ */
70911
+ url: string;
70912
+ /**
70913
+ * 规则限定的 HTTP 方法;不限定时省略。
70914
+ */
70915
+ method?: string;
70916
+ /**
70917
+ * 规则只作用的标签页;作用于整个会话时省略。
70918
+ */
70919
+ tab?: string;
70920
+ /**
70921
+ * 规则的处理方式:kind 为 fulfill、abort 或 delay,其余字段同注册时的 response。
70922
+ */
70923
+ response: {
70924
+ [key: string]: unknown;
70925
+ };
70926
+ }>;
70157
70927
  };
70158
- query?: never;
70159
- url: '/browser/v1/sessions/{sessionId}/viewer';
70160
70928
  };
70161
- export type BrowserViewerHeartbeatErrors = {
70162
- /**
70163
- * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
70164
- */
70165
- 400: BrowserError;
70166
- /**
70167
- * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
70168
- */
70169
- 401: BrowserError;
70170
- /**
70171
- * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
70172
- */
70173
- 402: BrowserError;
70174
- /**
70175
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70176
- */
70177
- 403: BrowserError;
70178
- /**
70179
- * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
70180
- */
70181
- 404: BrowserError;
70182
- /**
70183
- * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
70184
- */
70185
- 409: BrowserError;
70186
- /**
70187
- * BROWSER_REVOKED
70188
- */
70189
- 410: BrowserError;
70190
- /**
70191
- * ACTION_RESULT_TOO_LARGE
70192
- */
70193
- 413: BrowserError;
70194
- /**
70195
- * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
70196
- */
70197
- 429: BrowserError;
70198
- /**
70199
- * INTERNAL
70200
- */
70201
- 500: BrowserError;
70202
- /**
70203
- * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
70204
- */
70205
- 501: BrowserError;
70206
- /**
70207
- * PROVIDER_FAILED
70208
- */
70209
- 502: BrowserError;
70210
- /**
70211
- * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
70212
- */
70213
- 503: BrowserError;
70214
- /**
70215
- * ACTION_TIMEOUT
70216
- */
70217
- 504: BrowserError;
70218
- };
70219
- export type BrowserViewerHeartbeatError = BrowserViewerHeartbeatErrors[keyof BrowserViewerHeartbeatErrors];
70220
- export type BrowserViewerHeartbeatResponses = {
70221
- /**
70222
- * 请求成功。
70223
- */
70224
- 200: {
70929
+ export type BrowserRunPageActionResponse = BrowserRunPageActionResponses[keyof BrowserRunPageActionResponses];
70930
+ export type BrowserRequestHandoffData = {
70931
+ body: {
70225
70932
  /**
70226
- * 心跳已被接受,成功时固定返回 true。
70933
+ * 交给人工操作者的接管说明,可为空字符串。
70227
70934
  */
70228
- ok: true;
70935
+ message: string;
70936
+ /**
70937
+ * 接管请求有效时长,单位为毫秒;必须大于 0,可含小数。超过 3600000(60 分钟)的按 60 分钟算,返回事件里的到期时刻就是实际值。接管未完成、未到期期间,会话不按空闲回收;接管结束后重新开始计空闲。
70938
+ */
70939
+ timeoutMs?: number;
70229
70940
  };
70230
- };
70231
- export type BrowserViewerHeartbeatResponse = BrowserViewerHeartbeatResponses[keyof BrowserViewerHeartbeatResponses];
70232
- export type BrowserGetSessionFrameData = {
70233
- body?: never;
70234
70941
  path: {
70235
70942
  /**
70236
70943
  * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
@@ -70238,9 +70945,9 @@ export type BrowserGetSessionFrameData = {
70238
70945
  sessionId: string;
70239
70946
  };
70240
70947
  query?: never;
70241
- url: '/browser/v1/sessions/{sessionId}/frame';
70948
+ url: '/browser/v1/sessions/{sessionId}/handoff';
70242
70949
  };
70243
- export type BrowserGetSessionFrameErrors = {
70950
+ export type BrowserRequestHandoffErrors = {
70244
70951
  /**
70245
70952
  * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
70246
70953
  */
@@ -70254,7 +70961,252 @@ export type BrowserGetSessionFrameErrors = {
70254
70961
  */
70255
70962
  402: BrowserError;
70256
70963
  /**
70257
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70964
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70965
+ */
70966
+ 403: BrowserError;
70967
+ /**
70968
+ * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
70969
+ */
70970
+ 404: BrowserError;
70971
+ /**
70972
+ * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
70973
+ */
70974
+ 409: BrowserError;
70975
+ /**
70976
+ * BROWSER_REVOKED
70977
+ */
70978
+ 410: BrowserError;
70979
+ /**
70980
+ * ACTION_RESULT_TOO_LARGE
70981
+ */
70982
+ 413: BrowserError;
70983
+ /**
70984
+ * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
70985
+ */
70986
+ 429: BrowserError;
70987
+ /**
70988
+ * INTERNAL
70989
+ */
70990
+ 500: BrowserError;
70991
+ /**
70992
+ * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
70993
+ */
70994
+ 501: BrowserError;
70995
+ /**
70996
+ * PROVIDER_FAILED
70997
+ */
70998
+ 502: BrowserError;
70999
+ /**
71000
+ * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
71001
+ */
71002
+ 503: BrowserError;
71003
+ /**
71004
+ * ACTION_TIMEOUT
71005
+ */
71006
+ 504: BrowserError;
71007
+ };
71008
+ export type BrowserRequestHandoffError = BrowserRequestHandoffErrors[keyof BrowserRequestHandoffErrors];
71009
+ export type BrowserRequestHandoffResponses = {
71010
+ /**
71011
+ * 请求成功。
71012
+ */
71013
+ 201: BrowserEventRecord;
71014
+ };
71015
+ export type BrowserRequestHandoffResponse = BrowserRequestHandoffResponses[keyof BrowserRequestHandoffResponses];
71016
+ export type BrowserCompleteHandoffData = {
71017
+ body?: never;
71018
+ path: {
71019
+ /**
71020
+ * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
71021
+ */
71022
+ sessionId: string;
71023
+ };
71024
+ query?: never;
71025
+ url: '/browser/v1/sessions/{sessionId}/handoff/complete';
71026
+ };
71027
+ export type BrowserCompleteHandoffErrors = {
71028
+ /**
71029
+ * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
71030
+ */
71031
+ 400: BrowserError;
71032
+ /**
71033
+ * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
71034
+ */
71035
+ 401: BrowserError;
71036
+ /**
71037
+ * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
71038
+ */
71039
+ 402: BrowserError;
71040
+ /**
71041
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71042
+ */
71043
+ 403: BrowserError;
71044
+ /**
71045
+ * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
71046
+ */
71047
+ 404: BrowserError;
71048
+ /**
71049
+ * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
71050
+ */
71051
+ 409: BrowserError;
71052
+ /**
71053
+ * BROWSER_REVOKED
71054
+ */
71055
+ 410: BrowserError;
71056
+ /**
71057
+ * ACTION_RESULT_TOO_LARGE
71058
+ */
71059
+ 413: BrowserError;
71060
+ /**
71061
+ * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
71062
+ */
71063
+ 429: BrowserError;
71064
+ /**
71065
+ * INTERNAL
71066
+ */
71067
+ 500: BrowserError;
71068
+ /**
71069
+ * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
71070
+ */
71071
+ 501: BrowserError;
71072
+ /**
71073
+ * PROVIDER_FAILED
71074
+ */
71075
+ 502: BrowserError;
71076
+ /**
71077
+ * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
71078
+ */
71079
+ 503: BrowserError;
71080
+ /**
71081
+ * ACTION_TIMEOUT
71082
+ */
71083
+ 504: BrowserError;
71084
+ };
71085
+ export type BrowserCompleteHandoffError = BrowserCompleteHandoffErrors[keyof BrowserCompleteHandoffErrors];
71086
+ export type BrowserCompleteHandoffResponses = {
71087
+ /**
71088
+ * 请求成功。
71089
+ */
71090
+ 200: BrowserEventRecord;
71091
+ };
71092
+ export type BrowserCompleteHandoffResponse = BrowserCompleteHandoffResponses[keyof BrowserCompleteHandoffResponses];
71093
+ export type BrowserViewerHeartbeatData = {
71094
+ body: {
71095
+ /**
71096
+ * 当前观看者的稳定标识;同一观看者重复心跳应使用相同值,长度为 1–128 个 UTF-16 代码单元。
71097
+ */
71098
+ viewerId: string;
71099
+ /**
71100
+ * 观看者类型:control 是需要控制浏览器的客户端,readonly 是只读观看者。只读观看者发送 control 也会按 readonly 记录。
71101
+ */
71102
+ kind?: 'control' | 'readonly';
71103
+ };
71104
+ path: {
71105
+ /**
71106
+ * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
71107
+ */
71108
+ sessionId: string;
71109
+ };
71110
+ query?: never;
71111
+ url: '/browser/v1/sessions/{sessionId}/viewer';
71112
+ };
71113
+ export type BrowserViewerHeartbeatErrors = {
71114
+ /**
71115
+ * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
71116
+ */
71117
+ 400: BrowserError;
71118
+ /**
71119
+ * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
71120
+ */
71121
+ 401: BrowserError;
71122
+ /**
71123
+ * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
71124
+ */
71125
+ 402: BrowserError;
71126
+ /**
71127
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71128
+ */
71129
+ 403: BrowserError;
71130
+ /**
71131
+ * SESSION_NOT_FOUND / CONTEXT_NOT_FOUND / PAIRING_NOT_FOUND / BROWSER_NOT_FOUND / PARENT_NOT_FOUND / ACTION_TAB_NOT_FOUND
71132
+ */
71133
+ 404: BrowserError;
71134
+ /**
71135
+ * SESSION_ENDED / SESSION_INVALID_STATE / SESSION_NAME_IN_USE / CONTEXT_LOCKED / HANDOFF_NOT_PENDING / ACTION_NO_TAB / ACTION_REF_STALE / ACTION_FAILED
71136
+ */
71137
+ 409: BrowserError;
71138
+ /**
71139
+ * BROWSER_REVOKED
71140
+ */
71141
+ 410: BrowserError;
71142
+ /**
71143
+ * ACTION_RESULT_TOO_LARGE
71144
+ */
71145
+ 413: BrowserError;
71146
+ /**
71147
+ * CONCURRENCY_LIMIT / RATE_LIMITED / PROVIDER_CAPACITY
71148
+ */
71149
+ 429: BrowserError;
71150
+ /**
71151
+ * INTERNAL
71152
+ */
71153
+ 500: BrowserError;
71154
+ /**
71155
+ * NOT_IMPLEMENTED / PROVIDER_UNSUPPORTED
71156
+ */
71157
+ 501: BrowserError;
71158
+ /**
71159
+ * PROVIDER_FAILED
71160
+ */
71161
+ 502: BrowserError;
71162
+ /**
71163
+ * BROWSER_OFFLINE / SERVICE_UNAVAILABLE
71164
+ */
71165
+ 503: BrowserError;
71166
+ /**
71167
+ * ACTION_TIMEOUT
71168
+ */
71169
+ 504: BrowserError;
71170
+ };
71171
+ export type BrowserViewerHeartbeatError = BrowserViewerHeartbeatErrors[keyof BrowserViewerHeartbeatErrors];
71172
+ export type BrowserViewerHeartbeatResponses = {
71173
+ /**
71174
+ * 请求成功。
71175
+ */
71176
+ 200: {
71177
+ /**
71178
+ * 心跳已被接受,成功时固定返回 true。
71179
+ */
71180
+ ok: true;
71181
+ };
71182
+ };
71183
+ export type BrowserViewerHeartbeatResponse = BrowserViewerHeartbeatResponses[keyof BrowserViewerHeartbeatResponses];
71184
+ export type BrowserGetSessionFrameData = {
71185
+ body?: never;
71186
+ path: {
71187
+ /**
71188
+ * 浏览器会话 ID;使用创建或列出会话返回的 id,以 bss_ 开头。
71189
+ */
71190
+ sessionId: string;
71191
+ };
71192
+ query?: never;
71193
+ url: '/browser/v1/sessions/{sessionId}/frame';
71194
+ };
71195
+ export type BrowserGetSessionFrameErrors = {
71196
+ /**
71197
+ * INVALID_PARAMS / INVALID_FILTER / INVALID_PAGE_TOKEN
71198
+ */
71199
+ 400: BrowserError;
71200
+ /**
71201
+ * UNAUTHENTICATED / CONNECT_SIGNATURE_INVALID
71202
+ */
71203
+ 401: BrowserError;
71204
+ /**
71205
+ * INSUFFICIENT_BALANCE / QUOTA_EXHAUSTED
71206
+ */
71207
+ 402: BrowserError;
71208
+ /**
71209
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70258
71210
  */
70259
71211
  403: BrowserError;
70260
71212
  /**
@@ -70339,7 +71291,7 @@ export type BrowserListContextsErrors = {
70339
71291
  */
70340
71292
  402: BrowserError;
70341
71293
  /**
70342
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71294
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70343
71295
  */
70344
71296
  403: BrowserError;
70345
71297
  /**
@@ -70416,6 +71368,36 @@ export type BrowserCreateContextData = {
70416
71368
  labels?: {
70417
71369
  [key: string]: string;
70418
71370
  };
71371
+ /**
71372
+ * 给登录态绑定一个固定的外部代理(如住宅 IP),使用这个登录态的会话没有写 proxies 时都经它出网,让同一账号始终从同一个出口地址出去。只存保管库引用(password_secret),不存密码;会话自己写了 proxies 时以会话的为准。需要组织已开通容器后端,否则返回 501 PROVIDER_UNSUPPORTED。
71373
+ */
71374
+ proxy?: {
71375
+ /**
71376
+ * 固定为 external:经一个你自己的外部 HTTP 代理出网。
71377
+ */
71378
+ type: 'external';
71379
+ /**
71380
+ * 代理地址,host:port 或 http://host:port;只支持 HTTP 代理,不接受 socks5:// 等协议,也不接受 localhost 和内网、链路本地地址。
71381
+ */
71382
+ server: string;
71383
+ /**
71384
+ * 代理用户名;有密码时才能填,填了就必须同时给出密码。
71385
+ */
71386
+ username?: string;
71387
+ /**
71388
+ * 必须用这种形式:引用保管库里的代理密码,只在连接这个代理的主机时兑换,不会交给网页。登录态里只存引用,传明文 password 返回 400 INVALID_PARAMS。
71389
+ */
71390
+ password_secret?: {
71391
+ /**
71392
+ * 保存代理密码的保管库 ID,以 vlt_ 开头。
71393
+ */
71394
+ vault_id: string;
71395
+ /**
71396
+ * 保管库中该密码的密钥 ID(不是密码本身)。
71397
+ */
71398
+ secret: string;
71399
+ };
71400
+ };
70419
71401
  };
70420
71402
  path?: never;
70421
71403
  query?: never;
@@ -70435,7 +71417,7 @@ export type BrowserCreateContextErrors = {
70435
71417
  */
70436
71418
  402: BrowserError;
70437
71419
  /**
70438
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71420
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70439
71421
  */
70440
71422
  403: BrowserError;
70441
71423
  /**
@@ -70512,7 +71494,7 @@ export type BrowserDeleteContextErrors = {
70512
71494
  */
70513
71495
  402: BrowserError;
70514
71496
  /**
70515
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71497
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70516
71498
  */
70517
71499
  403: BrowserError;
70518
71500
  /**
@@ -70594,7 +71576,7 @@ export type BrowserGetContextErrors = {
70594
71576
  */
70595
71577
  402: BrowserError;
70596
71578
  /**
70597
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71579
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70598
71580
  */
70599
71581
  403: BrowserError;
70600
71582
  /**
@@ -70658,6 +71640,36 @@ export type BrowserUpdateContextData = {
70658
71640
  labels?: {
70659
71641
  [key: string]: string;
70660
71642
  };
71643
+ /**
71644
+ * 给登录态绑定一个固定的外部代理(如住宅 IP),使用这个登录态的会话没有写 proxies 时都经它出网,让同一账号始终从同一个出口地址出去。只存保管库引用(password_secret),不存密码;会话自己写了 proxies 时以会话的为准。需要组织已开通容器后端,否则返回 501 PROVIDER_UNSUPPORTED。 更新时传 null 解除绑定,省略则保留原绑定。
71645
+ */
71646
+ proxy?: {
71647
+ /**
71648
+ * 固定为 external:经一个你自己的外部 HTTP 代理出网。
71649
+ */
71650
+ type: 'external';
71651
+ /**
71652
+ * 代理地址,host:port 或 http://host:port;只支持 HTTP 代理,不接受 socks5:// 等协议,也不接受 localhost 和内网、链路本地地址。
71653
+ */
71654
+ server: string;
71655
+ /**
71656
+ * 代理用户名;有密码时才能填,填了就必须同时给出密码。
71657
+ */
71658
+ username?: string;
71659
+ /**
71660
+ * 必须用这种形式:引用保管库里的代理密码,只在连接这个代理的主机时兑换,不会交给网页。登录态里只存引用,传明文 password 返回 400 INVALID_PARAMS。
71661
+ */
71662
+ password_secret?: {
71663
+ /**
71664
+ * 保存代理密码的保管库 ID,以 vlt_ 开头。
71665
+ */
71666
+ vault_id: string;
71667
+ /**
71668
+ * 保管库中该密码的密钥 ID(不是密码本身)。
71669
+ */
71670
+ secret: string;
71671
+ };
71672
+ } | null;
70661
71673
  };
70662
71674
  path: {
70663
71675
  /**
@@ -70682,7 +71694,7 @@ export type BrowserUpdateContextErrors = {
70682
71694
  */
70683
71695
  402: BrowserError;
70684
71696
  /**
70685
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71697
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70686
71698
  */
70687
71699
  403: BrowserError;
70688
71700
  /**
@@ -70754,7 +71766,7 @@ export type BrowserCreateByobPairingErrors = {
70754
71766
  */
70755
71767
  402: BrowserError;
70756
71768
  /**
70757
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71769
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70758
71770
  */
70759
71771
  403: BrowserError;
70760
71772
  /**
@@ -70835,7 +71847,7 @@ export type BrowserListByobBrowsersErrors = {
70835
71847
  */
70836
71848
  402: BrowserError;
70837
71849
  /**
70838
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71850
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70839
71851
  */
70840
71852
  403: BrowserError;
70841
71853
  /**
@@ -70921,7 +71933,7 @@ export type BrowserGetByobBrowserErrors = {
70921
71933
  */
70922
71934
  402: BrowserError;
70923
71935
  /**
70924
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71936
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
70925
71937
  */
70926
71938
  403: BrowserError;
70927
71939
  /**
@@ -70979,14 +71991,6 @@ export type BrowserUpdateByobBrowserData = {
70979
71991
  * 新的显示名称,1–80 个字符。
70980
71992
  */
70981
71993
  name?: string;
70982
- /**
70983
- * 整体替换被授权的智能体 ID 列表;传空数组撤销全部授权。
70984
- */
70985
- granted_agents?: Array<string>;
70986
- /**
70987
- * 整体替换允许站点列表;传空数组表示不限制。
70988
- */
70989
- allowed_sites?: Array<string>;
70990
71994
  };
70991
71995
  path: {
70992
71996
  /**
@@ -71011,7 +72015,7 @@ export type BrowserUpdateByobBrowserErrors = {
71011
72015
  */
71012
72016
  402: BrowserError;
71013
72017
  /**
71014
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72018
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71015
72019
  */
71016
72020
  403: BrowserError;
71017
72021
  /**
@@ -71088,7 +72092,7 @@ export type BrowserDisconnectByobBrowserErrors = {
71088
72092
  */
71089
72093
  402: BrowserError;
71090
72094
  /**
71091
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72095
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71092
72096
  */
71093
72097
  403: BrowserError;
71094
72098
  /**
@@ -71165,7 +72169,7 @@ export type BrowserReadByobPairingErrors = {
71165
72169
  */
71166
72170
  402: BrowserError;
71167
72171
  /**
71168
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72172
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71169
72173
  */
71170
72174
  403: BrowserError;
71171
72175
  /**
@@ -71242,7 +72246,7 @@ export type BrowserClaimByobPairingErrors = {
71242
72246
  */
71243
72247
  402: BrowserError;
71244
72248
  /**
71245
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72249
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71246
72250
  */
71247
72251
  403: BrowserError;
71248
72252
  /**
@@ -71351,7 +72355,7 @@ export type BrowserConnectErrors = {
71351
72355
  */
71352
72356
  402: BrowserError;
71353
72357
  /**
71354
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72358
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71355
72359
  */
71356
72360
  403: BrowserError;
71357
72361
  /**
@@ -71430,7 +72434,7 @@ export type BrowserLiveViewErrors = {
71430
72434
  */
71431
72435
  402: BrowserError;
71432
72436
  /**
71433
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72437
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71434
72438
  */
71435
72439
  403: BrowserError;
71436
72440
  /**
@@ -71500,7 +72504,7 @@ export type BrowserStreamSessionErrors = {
71500
72504
  */
71501
72505
  402: BrowserError;
71502
72506
  /**
71503
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72507
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71504
72508
  */
71505
72509
  403: BrowserError;
71506
72510
  /**
@@ -71577,7 +72581,7 @@ export type BrowserStreamSessionFramesErrors = {
71577
72581
  */
71578
72582
  402: BrowserError;
71579
72583
  /**
71580
- * PERMISSION_DENIED / BROWSER_NOT_GRANTED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
72584
+ * PERMISSION_DENIED / CONTEXT_READ_ONLY / ACCOUNT_SUSPENDED
71581
72585
  */
71582
72586
  403: BrowserError;
71583
72587
  /**
@@ -78314,7 +79318,7 @@ export type ListOrganizationCostsData = {
78314
79318
  */
78315
79319
  bucket_width: '1h' | '1d';
78316
79320
  /**
78317
- * IANA time zone name (for example Asia/Shanghai) whose local hours or days form the buckets. Defaults to UTC. Offsets such as +08:00 are rejected. The window widens to whole local buckets; a day that crosses a daylight-saving change lasts 23 or 25 hours. starting_at and ending_at stay UTC instants.
79321
+ * IANA time zone name (for example Asia/Shanghai) whose local hours or days form the buckets. Defaults to UTC. Offsets such as +08:00 are rejected. Only zones whose UTC offset is a whole number of hours across the whole window are supported; zones such as Asia/Kolkata (+05:30) or Asia/Kathmandu (+05:45) are rejected with 400 VALIDATION_ERROR, because Billing buckets in UTC hours and a local hour of those zones straddles two of them. With bucket_width=1d the window widens to whole local days, each bucket carries its real UTC starting_at and ending_at, and a day that crosses a daylight-saving change lasts 23 or 25 hours; the whole window is then answered in one page (has_more is false and page is not accepted). starting_at and ending_at stay UTC instants.
78318
79322
  *
78319
79323
  */
78320
79324
  time_zone?: string;
@@ -78432,7 +79436,7 @@ export type ListOrganizationUsageData = {
78432
79436
  */
78433
79437
  bucket_width: '1h' | '1d';
78434
79438
  /**
78435
- * IANA time zone name (for example Asia/Shanghai) whose local hours or days form the buckets. Defaults to UTC. Offsets such as +08:00 are rejected. The window widens to whole local buckets; a day that crosses a daylight-saving change lasts 23 or 25 hours. starting_at and ending_at stay UTC instants.
79439
+ * IANA time zone name (for example Asia/Shanghai) whose local hours or days form the buckets. Defaults to UTC. Offsets such as +08:00 are rejected. Only zones whose UTC offset is a whole number of hours across the whole window are supported; zones such as Asia/Kolkata (+05:30) or Asia/Kathmandu (+05:45) are rejected with 400 VALIDATION_ERROR, because Billing buckets in UTC hours and a local hour of those zones straddles two of them. With bucket_width=1d the window widens to whole local days, each bucket carries its real UTC starting_at and ending_at, and a day that crosses a daylight-saving change lasts 23 or 25 hours; the whole window is then answered in one page (has_more is false and page is not accepted). starting_at and ending_at stay UTC instants.
78436
79440
  *
78437
79441
  */
78438
79442
  time_zone?: string;
@@ -78952,11 +79956,19 @@ export type ListOrganizationNotificationLettersData = {
78952
79956
  path?: never;
78953
79957
  query?: {
78954
79958
  /**
78955
- * Only unread letters, or only read ones; omit for both.
79959
+ * received (the default) lists the letters addressed to you; sent lists the letters you wrote, scheduled ones included, in the same row shape — a script or an agent finds its own alarm clocks there. A run credential's sent list is the letters automation wrote on behalf of the person it acts for.
79960
+ */
79961
+ direction?: 'received' | 'sent';
79962
+ /**
79963
+ * Only unread letters, only read ones, or (direction=sent only) only letters written but not yet delivered, whose deliveredAt is null; omit for all. On a sent list, unread and read are the recipient's state.
79964
+ */
79965
+ status?: 'unread' | 'read' | 'scheduled';
79966
+ /**
79967
+ * Only letters of this conversation, for received and sent alike; omit for all.
78956
79968
  */
78957
- status?: 'unread' | 'read';
79969
+ thread?: string;
78958
79970
  /**
78959
- * false (the default) hides archived letters; true lists only the archived ones.
79971
+ * false (the default) hides archived letters; true lists only the archived ones. Archiving is the addressee's act, so it is ignored when direction=sent.
78960
79972
  */
78961
79973
  archived?: boolean;
78962
79974
  /**
@@ -78972,7 +79984,7 @@ export type ListOrganizationNotificationLettersData = {
78972
79984
  };
78973
79985
  export type ListOrganizationNotificationLettersErrors = {
78974
79986
  /**
78975
- * A bad `status`, `archived` or `limit`, or `INVALID_PARAMS` from the service for a cursor it did not issue (RFC 9457 problem).
79987
+ * A bad `direction`, `status` (scheduled needs direction=sent), `thread`, `archived` or `limit`, or `INVALID_PARAMS` from the service for a cursor it did not issue (RFC 9457 problem).
78976
79988
  */
78977
79989
  400: unknown;
78978
79990
  /**
@@ -79072,6 +80084,80 @@ export type ListOrganizationNotificationLettersResponses = {
79072
80084
  };
79073
80085
  };
79074
80086
  export type ListOrganizationNotificationLettersResponse = ListOrganizationNotificationLettersResponses[keyof ListOrganizationNotificationLettersResponses];
80087
+ export type CreateOrganizationNotificationLetterData = {
80088
+ body: {
80089
+ /**
80090
+ * The recipient's address: human:<user id> or agent:<agent id>, a member or an agent of this organization.
80091
+ */
80092
+ to: string;
80093
+ /**
80094
+ * The whole letter, 1 to 16000 characters.
80095
+ */
80096
+ body: string;
80097
+ /**
80098
+ * One sentence saying what the reader is asked to do or needs to know, at most 60 characters. Required when to is a person; refused, never cut, when longer.
80099
+ */
80100
+ summary?: string;
80101
+ /**
80102
+ * The letter's kind; it decides the channels. Defaults to mention.
80103
+ */
80104
+ kind?: 'notice' | 'mention' | 'decision';
80105
+ /**
80106
+ * The conversation the letter belongs to, free text; omit for none.
80107
+ */
80108
+ thread?: string;
80109
+ /**
80110
+ * When to deliver it, ISO 8601, at most 366 days ahead. A past time or no value means now.
80111
+ */
80112
+ deliver_at?: string;
80113
+ };
80114
+ path?: never;
80115
+ query?: never;
80116
+ url: '/organization/v1/notifications/letters';
80117
+ };
80118
+ export type CreateOrganizationNotificationLetterErrors = {
80119
+ /**
80120
+ * `to` is not an address, `body` is missing or too long, `summary` is missing for a person or longer than 60 characters, `kind` is unknown, or `deliver_at` is not an ISO 8601 time within 366 days (RFC 9457 problem).
80121
+ */
80122
+ 400: unknown;
80123
+ /**
80124
+ * Missing or invalid credential (RFC 9457 problem).
80125
+ */
80126
+ 401: unknown;
80127
+ /**
80128
+ * `PERMISSION_DENIED`: sending a letter needs a person, an agent or an automation run identity; an organization API key or an application cannot send (RFC 9457 problem).
80129
+ */
80130
+ 403: unknown;
80131
+ /**
80132
+ * `SUBSCRIBER_NOT_FOUND`: the recipient is not a member or an agent of this organization (RFC 9457 problem).
80133
+ */
80134
+ 404: unknown;
80135
+ /**
80136
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80137
+ */
80138
+ 502: unknown;
80139
+ };
80140
+ export type CreateOrganizationNotificationLetterResponses = {
80141
+ /**
80142
+ * The letter is written; it is delivered at deliverAt.
80143
+ */
80144
+ 200: {
80145
+ /**
80146
+ * The letter that was written: its id and the time it is delivered.
80147
+ */
80148
+ letter: {
80149
+ /**
80150
+ * The letter's id.
80151
+ */
80152
+ id: string;
80153
+ /**
80154
+ * When it is delivered: now, or the time asked for.
80155
+ */
80156
+ deliverAt: string;
80157
+ };
80158
+ };
80159
+ };
80160
+ export type CreateOrganizationNotificationLetterResponse = CreateOrganizationNotificationLetterResponses[keyof CreateOrganizationNotificationLetterResponses];
79075
80161
  export type GetOrganizationNotificationLetterData = {
79076
80162
  body?: never;
79077
80163
  path: {
@@ -79295,6 +80381,360 @@ export type ArchiveOrganizationNotificationLetterResponses = {
79295
80381
  };
79296
80382
  };
79297
80383
  export type ArchiveOrganizationNotificationLetterResponse = ArchiveOrganizationNotificationLetterResponses[keyof ArchiveOrganizationNotificationLetterResponses];
80384
+ export type ListOrganizationNotificationMessagesData = {
80385
+ body?: never;
80386
+ path?: never;
80387
+ query?: {
80388
+ /**
80389
+ * 0 (the default) lists the inbox tab, 1 lists archived messages.
80390
+ */
80391
+ archived?: '0' | '1';
80392
+ /**
80393
+ * Messages per page, 1 to 100; defaults to 20.
80394
+ */
80395
+ limit?: number;
80396
+ /**
80397
+ * Opaque nextPageToken from the previous response; omit for the first page.
80398
+ */
80399
+ page?: string;
80400
+ };
80401
+ url: '/organization/v1/notifications/messages';
80402
+ };
80403
+ export type ListOrganizationNotificationMessagesErrors = {
80404
+ /**
80405
+ * A bad `archived`, `limit` or `page`, or `INVALID_PARAMS` from the service for a cursor it did not issue (RFC 9457 problem).
80406
+ */
80407
+ 400: unknown;
80408
+ /**
80409
+ * Missing or invalid credential (RFC 9457 problem).
80410
+ */
80411
+ 401: unknown;
80412
+ /**
80413
+ * `PERMISSION_DENIED`: an agent credential has no person inbox; read its own letters instead (RFC 9457 problem).
80414
+ */
80415
+ 403: unknown;
80416
+ /**
80417
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80418
+ */
80419
+ 502: unknown;
80420
+ };
80421
+ export type ListOrganizationNotificationMessagesResponses = {
80422
+ /**
80423
+ * One page of this person's messages.
80424
+ */
80425
+ 200: {
80426
+ /**
80427
+ * The page, newest first.
80428
+ */
80429
+ items: Array<{
80430
+ /**
80431
+ * The message's resource name, subscribers/{user}/messages/{id}; pass it URL-encoded as the {name} of the other message operations.
80432
+ */
80433
+ name: string;
80434
+ /**
80435
+ * The organization the message belongs to; empty for a message that belongs to no organization.
80436
+ */
80437
+ organizationId: string;
80438
+ /**
80439
+ * The notification group the message belongs to: members, usage, alerts, agent, or nonConfigurable.
80440
+ */
80441
+ group: 'members' | 'usage' | 'alerts' | 'agent' | 'nonConfigurable';
80442
+ /**
80443
+ * The notification workflow that wrote it, as the preferences page names it.
80444
+ */
80445
+ workflow: string;
80446
+ /**
80447
+ * The message's headline, as the bell shows it.
80448
+ */
80449
+ title: string;
80450
+ /**
80451
+ * The message text.
80452
+ */
80453
+ body: string;
80454
+ /**
80455
+ * Where the bell opens this message; absent when it has no page.
80456
+ */
80457
+ actionUrl?: string;
80458
+ /**
80459
+ * Whether the bell has been opened since the message arrived.
80460
+ */
80461
+ seen: boolean;
80462
+ /**
80463
+ * Whether this person has read it.
80464
+ */
80465
+ read: boolean;
80466
+ /**
80467
+ * Whether this person archived it; archived messages are not in the inbox tab.
80468
+ */
80469
+ archived: boolean;
80470
+ /**
80471
+ * When the message arrived.
80472
+ */
80473
+ createTime: string;
80474
+ }>;
80475
+ /**
80476
+ * Pass unchanged as page for the next page; absent at the end.
80477
+ */
80478
+ nextPageToken?: string;
80479
+ };
80480
+ };
80481
+ export type ListOrganizationNotificationMessagesResponse = ListOrganizationNotificationMessagesResponses[keyof ListOrganizationNotificationMessagesResponses];
80482
+ export type DeleteOrganizationNotificationMessageData = {
80483
+ body?: never;
80484
+ path: {
80485
+ /**
80486
+ * The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded.
80487
+ */
80488
+ name: string;
80489
+ };
80490
+ query?: never;
80491
+ url: '/organization/v1/notifications/messages/{name}';
80492
+ };
80493
+ export type DeleteOrganizationNotificationMessageErrors = {
80494
+ /**
80495
+ * `name` is not subscribers/{user}/messages/{id} — `INVALID_PARAMS` (RFC 9457 problem).
80496
+ */
80497
+ 400: unknown;
80498
+ /**
80499
+ * Missing or invalid credential (RFC 9457 problem).
80500
+ */
80501
+ 401: unknown;
80502
+ /**
80503
+ * `PERMISSION_DENIED`: an agent credential has no person inbox; read its own letters instead (RFC 9457 problem).
80504
+ */
80505
+ 403: unknown;
80506
+ /**
80507
+ * No such message of yours in this organization — `MESSAGE_NOT_FOUND` (RFC 9457 problem).
80508
+ */
80509
+ 404: unknown;
80510
+ /**
80511
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80512
+ */
80513
+ 502: unknown;
80514
+ };
80515
+ export type DeleteOrganizationNotificationMessageResponses = {
80516
+ /**
80517
+ * The message is deleted.
80518
+ */
80519
+ 200: {
80520
+ /**
80521
+ * Always true: the message was deleted.
80522
+ */
80523
+ deleted: boolean;
80524
+ };
80525
+ };
80526
+ export type DeleteOrganizationNotificationMessageResponse = DeleteOrganizationNotificationMessageResponses[keyof DeleteOrganizationNotificationMessageResponses];
80527
+ export type GetOrganizationNotificationMessageData = {
80528
+ body?: never;
80529
+ path: {
80530
+ /**
80531
+ * The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded.
80532
+ */
80533
+ name: string;
80534
+ };
80535
+ query?: never;
80536
+ url: '/organization/v1/notifications/messages/{name}';
80537
+ };
80538
+ export type GetOrganizationNotificationMessageErrors = {
80539
+ /**
80540
+ * `name` is not subscribers/{user}/messages/{id} — `INVALID_PARAMS` (RFC 9457 problem).
80541
+ */
80542
+ 400: unknown;
80543
+ /**
80544
+ * Missing or invalid credential (RFC 9457 problem).
80545
+ */
80546
+ 401: unknown;
80547
+ /**
80548
+ * `PERMISSION_DENIED`: an agent credential has no person inbox; read its own letters instead (RFC 9457 problem).
80549
+ */
80550
+ 403: unknown;
80551
+ /**
80552
+ * No such message of yours in this organization — `MESSAGE_NOT_FOUND`, the same answer for another person's message and one that never existed (RFC 9457 problem).
80553
+ */
80554
+ 404: unknown;
80555
+ /**
80556
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80557
+ */
80558
+ 502: unknown;
80559
+ };
80560
+ export type GetOrganizationNotificationMessageResponses = {
80561
+ /**
80562
+ * The message.
80563
+ */
80564
+ 200: {
80565
+ /**
80566
+ * The message's resource name, subscribers/{user}/messages/{id}; pass it URL-encoded as the {name} of the other message operations.
80567
+ */
80568
+ name: string;
80569
+ /**
80570
+ * The organization the message belongs to; empty for a message that belongs to no organization.
80571
+ */
80572
+ organizationId: string;
80573
+ /**
80574
+ * The notification group the message belongs to: members, usage, alerts, agent, or nonConfigurable.
80575
+ */
80576
+ group: 'members' | 'usage' | 'alerts' | 'agent' | 'nonConfigurable';
80577
+ /**
80578
+ * The notification workflow that wrote it, as the preferences page names it.
80579
+ */
80580
+ workflow: string;
80581
+ /**
80582
+ * The message's headline, as the bell shows it.
80583
+ */
80584
+ title: string;
80585
+ /**
80586
+ * The message text.
80587
+ */
80588
+ body: string;
80589
+ /**
80590
+ * Where the bell opens this message; absent when it has no page.
80591
+ */
80592
+ actionUrl?: string;
80593
+ /**
80594
+ * Whether the bell has been opened since the message arrived.
80595
+ */
80596
+ seen: boolean;
80597
+ /**
80598
+ * Whether this person has read it.
80599
+ */
80600
+ read: boolean;
80601
+ /**
80602
+ * Whether this person archived it; archived messages are not in the inbox tab.
80603
+ */
80604
+ archived: boolean;
80605
+ /**
80606
+ * When the message arrived.
80607
+ */
80608
+ createTime: string;
80609
+ };
80610
+ };
80611
+ export type GetOrganizationNotificationMessageResponse = GetOrganizationNotificationMessageResponses[keyof GetOrganizationNotificationMessageResponses];
80612
+ export type UpdateOrganizationNotificationMessageData = {
80613
+ body: {
80614
+ /**
80615
+ * Mark the message read (true) or unread (false); omit to leave it.
80616
+ */
80617
+ read?: boolean;
80618
+ /**
80619
+ * Archive the message (true) or move it back to the inbox (false); omit to leave it.
80620
+ */
80621
+ archived?: boolean;
80622
+ };
80623
+ path: {
80624
+ /**
80625
+ * The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded.
80626
+ */
80627
+ name: string;
80628
+ };
80629
+ query?: never;
80630
+ url: '/organization/v1/notifications/messages/{name}';
80631
+ };
80632
+ export type UpdateOrganizationNotificationMessageErrors = {
80633
+ /**
80634
+ * The body is not a JSON object, names neither `read` nor `archived`, a flag is not true or false, or `name` is malformed (RFC 9457 problem).
80635
+ */
80636
+ 400: unknown;
80637
+ /**
80638
+ * Missing or invalid credential (RFC 9457 problem).
80639
+ */
80640
+ 401: unknown;
80641
+ /**
80642
+ * `PERMISSION_DENIED`: an agent credential has no person inbox; read its own letters instead (RFC 9457 problem).
80643
+ */
80644
+ 403: unknown;
80645
+ /**
80646
+ * No such message of yours in this organization — `MESSAGE_NOT_FOUND` (RFC 9457 problem).
80647
+ */
80648
+ 404: unknown;
80649
+ /**
80650
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80651
+ */
80652
+ 502: unknown;
80653
+ };
80654
+ export type UpdateOrganizationNotificationMessageResponses = {
80655
+ /**
80656
+ * The message after the change.
80657
+ */
80658
+ 200: {
80659
+ /**
80660
+ * The message's resource name, subscribers/{user}/messages/{id}; pass it URL-encoded as the {name} of the other message operations.
80661
+ */
80662
+ name: string;
80663
+ /**
80664
+ * The organization the message belongs to; empty for a message that belongs to no organization.
80665
+ */
80666
+ organizationId: string;
80667
+ /**
80668
+ * The notification group the message belongs to: members, usage, alerts, agent, or nonConfigurable.
80669
+ */
80670
+ group: 'members' | 'usage' | 'alerts' | 'agent' | 'nonConfigurable';
80671
+ /**
80672
+ * The notification workflow that wrote it, as the preferences page names it.
80673
+ */
80674
+ workflow: string;
80675
+ /**
80676
+ * The message's headline, as the bell shows it.
80677
+ */
80678
+ title: string;
80679
+ /**
80680
+ * The message text.
80681
+ */
80682
+ body: string;
80683
+ /**
80684
+ * Where the bell opens this message; absent when it has no page.
80685
+ */
80686
+ actionUrl?: string;
80687
+ /**
80688
+ * Whether the bell has been opened since the message arrived.
80689
+ */
80690
+ seen: boolean;
80691
+ /**
80692
+ * Whether this person has read it.
80693
+ */
80694
+ read: boolean;
80695
+ /**
80696
+ * Whether this person archived it; archived messages are not in the inbox tab.
80697
+ */
80698
+ archived: boolean;
80699
+ /**
80700
+ * When the message arrived.
80701
+ */
80702
+ createTime: string;
80703
+ };
80704
+ };
80705
+ export type UpdateOrganizationNotificationMessageResponse = UpdateOrganizationNotificationMessageResponses[keyof UpdateOrganizationNotificationMessageResponses];
80706
+ export type ReadAllOrganizationNotificationMessagesData = {
80707
+ body?: never;
80708
+ path?: never;
80709
+ query?: never;
80710
+ url: '/organization/v1/notifications/messages:readAll';
80711
+ };
80712
+ export type ReadAllOrganizationNotificationMessagesErrors = {
80713
+ /**
80714
+ * Missing or invalid credential (RFC 9457 problem).
80715
+ */
80716
+ 401: unknown;
80717
+ /**
80718
+ * `PERMISSION_DENIED`: an agent credential has no person inbox; read its own letters instead (RFC 9457 problem).
80719
+ */
80720
+ 403: unknown;
80721
+ /**
80722
+ * The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it.
80723
+ */
80724
+ 502: unknown;
80725
+ };
80726
+ export type ReadAllOrganizationNotificationMessagesResponses = {
80727
+ /**
80728
+ * How many messages were marked read.
80729
+ */
80730
+ 200: {
80731
+ /**
80732
+ * The number of messages that were unread and are now read.
80733
+ */
80734
+ updated: number;
80735
+ };
80736
+ };
80737
+ export type ReadAllOrganizationNotificationMessagesResponse = ReadAllOrganizationNotificationMessagesResponses[keyof ReadAllOrganizationNotificationMessagesResponses];
79298
80738
  export type GetOrganizationNotificationPreferencesData = {
79299
80739
  body?: never;
79300
80740
  path?: never;
@@ -80762,7 +82202,7 @@ export type ListByodDevicesResponses = {
80762
82202
  */
80763
82203
  id: string;
80764
82204
  /**
80765
- * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs only for an organization with the local-agent-connect flag on; windows is not supported yet.
82205
+ * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs like a phone; windows is not supported yet.
80766
82206
  */
80767
82207
  platform: 'android' | 'macos' | 'linux';
80768
82208
  /**
@@ -80810,6 +82250,10 @@ export type ListByodDevicesResponses = {
80810
82250
  */
80811
82251
  agent: string;
80812
82252
  }>;
82253
+ /**
82254
+ * The version of the envd on the desktop, as its last hello reported. Null for a phone, for a desktop that has not connected yet, and for an envd that sent no version.
82255
+ */
82256
+ envd_version: string | null;
80813
82257
  /**
80814
82258
  * Whether the desktop's envd lets a platform session run in bypassPermissions (all tool calls without asking). True unless the person ran praxis connect agent --no-bypass on that machine; a session create that asks for bypassPermissions on a device where this is false answers 400 INVALID_PARAMS. False for a phone and for a desktop that has not connected yet.
80815
82259
  */
@@ -80857,7 +82301,7 @@ export type GetByodDeviceResponses = {
80857
82301
  */
80858
82302
  id: string;
80859
82303
  /**
80860
- * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs only for an organization with the local-agent-connect flag on; windows is not supported yet.
82304
+ * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs like a phone; windows is not supported yet.
80861
82305
  */
80862
82306
  platform: 'android' | 'macos' | 'linux';
80863
82307
  /**
@@ -80905,6 +82349,10 @@ export type GetByodDeviceResponses = {
80905
82349
  */
80906
82350
  agent: string;
80907
82351
  }>;
82352
+ /**
82353
+ * The version of the envd on the desktop, as its last hello reported. Null for a phone, for a desktop that has not connected yet, and for an envd that sent no version.
82354
+ */
82355
+ envd_version: string | null;
80908
82356
  /**
80909
82357
  * Whether the desktop's envd lets a platform session run in bypassPermissions (all tool calls without asking). True unless the person ran praxis connect agent --no-bypass on that machine; a session create that asks for bypassPermissions on a device where this is false answers 400 INVALID_PARAMS. False for a phone and for a desktop that has not connected yet.
80910
82358
  */
@@ -80963,7 +82411,7 @@ export type UpdateByodDeviceResponses = {
80963
82411
  */
80964
82412
  id: string;
80965
82413
  /**
80966
- * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs only for an organization with the local-agent-connect flag on; windows is not supported yet.
82414
+ * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs like a phone; windows is not supported yet.
80967
82415
  */
80968
82416
  platform: 'android' | 'macos' | 'linux';
80969
82417
  /**
@@ -81011,6 +82459,10 @@ export type UpdateByodDeviceResponses = {
81011
82459
  */
81012
82460
  agent: string;
81013
82461
  }>;
82462
+ /**
82463
+ * The version of the envd on the desktop, as its last hello reported. Null for a phone, for a desktop that has not connected yet, and for an envd that sent no version.
82464
+ */
82465
+ envd_version: string | null;
81014
82466
  /**
81015
82467
  * Whether the desktop's envd lets a platform session run in bypassPermissions (all tool calls without asking). True unless the person ran praxis connect agent --no-bypass on that machine; a session create that asks for bypassPermissions on a device where this is false answers 400 INVALID_PARAMS. False for a phone and for a desktop that has not connected yet.
81016
82468
  */
@@ -81096,13 +82548,124 @@ export type GetByodPairingResponses = {
81096
82548
  };
81097
82549
  };
81098
82550
  export type GetByodPairingResponse = GetByodPairingResponses[keyof GetByodPairingResponses];
82551
+ export type GetByodPairingStatusData = {
82552
+ body?: never;
82553
+ path: {
82554
+ /**
82555
+ * The 8-character pairing code returned by createByodPairing. An unknown, spent or expired code answers 404.
82556
+ */
82557
+ code: string;
82558
+ };
82559
+ query?: never;
82560
+ url: '/sandbox/v1/byod/pairings/{code}/status';
82561
+ };
82562
+ export type GetByodPairingStatusErrors = {
82563
+ /**
82564
+ * Authentication required: supply an organization API key that carries a tenant.
82565
+ */
82566
+ 401: unknown;
82567
+ /**
82568
+ * NOT_FOUND: no such pairing for this organization. The code is unknown or belongs to another organization; the two are indistinguishable.
82569
+ */
82570
+ 404: unknown;
82571
+ /**
82572
+ * SERVICE_UNAVAILABLE: BYOD is not bound in this deployment, or the sandbox is not ready. Wait and retry.
82573
+ */
82574
+ 503: unknown;
82575
+ };
82576
+ export type GetByodPairingStatusResponses = {
82577
+ /**
82578
+ * One pairing of the organization.
82579
+ */
82580
+ 200: {
82581
+ /**
82582
+ * The 8-character pairing code that was asked about.
82583
+ */
82584
+ code: string;
82585
+ /**
82586
+ * When the code stops working, as an ISO-8601 timestamp.
82587
+ */
82588
+ expires_at: string;
82589
+ /**
82590
+ * The device this code registered, or null while no phone has claimed it (or when that device was disconnected since).
82591
+ */
82592
+ claimed_device: {
82593
+ /**
82594
+ * Resource type; always "byod_device".
82595
+ */
82596
+ object: 'byod_device';
82597
+ /**
82598
+ * Device id, `byd_` followed by 26 lowercase hex characters. Pass it wherever a use face takes a sandbox id, such as POST /sandbox/v1/sandboxes/{id}/act; every lifecycle operation on it answers CAPABILITY_UNSUPPORTED.
82599
+ */
82600
+ id: string;
82601
+ /**
82602
+ * The device's platform, which decides the use faces it answers. A desktop (macos, linux) pairs like a phone; windows is not supported yet.
82603
+ */
82604
+ platform: 'android' | 'macos' | 'linux';
82605
+ /**
82606
+ * Display name of the device, 1 to 64 characters. Change it with updateByodDevice; it is not an identifier.
82607
+ */
82608
+ name: string;
82609
+ /**
82610
+ * Device model the phone's app reported when it claimed the pairing, such as 23127PN0CC; empty when the app sent none.
82611
+ */
82612
+ model: string;
82613
+ /**
82614
+ * Operating-system version the app reported, such as 16; empty when the app sent none. Not the device's model.
82615
+ */
82616
+ os_version: string;
82617
+ /**
82618
+ * True while the device holds its one control connection; false when it is paired but not connected. An act on an offline device answers 503 DEVICE_NOT_READY.
82619
+ */
82620
+ online: boolean;
82621
+ /**
82622
+ * When the device last said hello or answered a ping, as an ISO-8601 timestamp; null until it first connects.
82623
+ */
82624
+ last_seen_at: string | null;
82625
+ /**
82626
+ * When the device was paired, as an ISO-8601 timestamp; the list is ordered by it, oldest first.
82627
+ */
82628
+ created_at: string;
82629
+ /**
82630
+ * What the device can be asked to do, derived from its platform: display for a phone (act, the action socket), agent for a desktop (a local coding agent session).
82631
+ */
82632
+ capabilities: Array<'display' | 'agent'>;
82633
+ /**
82634
+ * The absolute directories a desktop registered for agent sessions with its last hello; a session may only start in one of these. Empty for a phone and for a desktop that has not connected yet.
82635
+ */
82636
+ agent_dirs: Array<string>;
82637
+ /**
82638
+ * Which agent each registered directory is bound to, as the desktop's last hello reported. Empty for a phone and for a desktop that has not connected yet.
82639
+ */
82640
+ agent_bindings: Array<{
82641
+ /**
82642
+ * The absolute directory the desktop bound to an agent with praxis agent connect.
82643
+ */
82644
+ dir: string;
82645
+ /**
82646
+ * The agent the directory is bound to: its identity number or its agent id.
82647
+ */
82648
+ agent: string;
82649
+ }>;
82650
+ /**
82651
+ * The version of the envd on the desktop, as its last hello reported. Null for a phone, for a desktop that has not connected yet, and for an envd that sent no version.
82652
+ */
82653
+ envd_version: string | null;
82654
+ /**
82655
+ * Whether the desktop's envd lets a platform session run in bypassPermissions (all tool calls without asking). True unless the person ran praxis connect agent --no-bypass on that machine; a session create that asks for bypassPermissions on a device where this is false answers 400 INVALID_PARAMS. False for a phone and for a desktop that has not connected yet.
82656
+ */
82657
+ allow_bypass: boolean;
82658
+ } | null;
82659
+ };
82660
+ };
82661
+ export type GetByodPairingStatusResponse = GetByodPairingStatusResponses[keyof GetByodPairingStatusResponses];
81099
82662
  export type ClaimByodPairingData = {
81100
82663
  /**
81101
82664
  * What the phone's app knows about itself when it claims the pairing.
81102
82665
  */
81103
82666
  body: {
81104
82667
  /**
81105
- * The device's platform. macos and linux are accepted only for an organization with the local-agent-connect flag on; with it off, and for any other value, the claim answers INVALID_PARAMS.
82668
+ * The device's platform. macos and linux are accepted for every organization; any other value than android, macos or linux answers INVALID_PARAMS.
81106
82669
  */
81107
82670
  platform: 'android' | 'macos' | 'linux';
81108
82671
  /**
@@ -81133,7 +82696,7 @@ export type ClaimByodPairingData = {
81133
82696
  };
81134
82697
  export type ClaimByodPairingErrors = {
81135
82698
  /**
81136
- * INVALID_PARAMS: the body is missing, platform is not android, macos or linux, or a desktop platform was claimed where local-agent-connect is off. Fix the body and resend; the code is not spent by a refused claim.
82699
+ * INVALID_PARAMS: the body is missing, platform is not android, macos or linux. Fix the body and resend; the code is not spent by a refused claim.
81137
82700
  */
81138
82701
  400: unknown;
81139
82702
  /**
@@ -83756,8 +85319,7 @@ export type SessionsUpdateData = {
83756
85319
  */
83757
85320
  title?: null | string;
83758
85321
  /**
83759
- * Vault IDs (`vlt_*`) to attach to the session. Not yet supported;
83760
- * requests setting this field are rejected. Reserved for future use.
85322
+ * The vaults this session carries, replacing the whole set it has now, including the vaults it took from its agent when it was created: send those ids again to keep them. At most 50 ids, each a vault of your organization that is not archived. The next command the session runs sees the new set: the secrets of the vaults become environment variables on its machine and are matched against its MCP servers, as sessions.create describes.
83761
85323
  */
83762
85324
  vault_ids?: Array<string>;
83763
85325
  /**
@@ -84304,6 +85866,15 @@ export type AgentsListResponses = {
84304
85866
  name: string;
84305
85867
  }>;
84306
85868
  };
85869
+ /**
85870
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
85871
+ */
85872
+ browser?: {
85873
+ /**
85874
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
85875
+ */
85876
+ byob: string;
85877
+ } | null;
84307
85878
  /**
84308
85879
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
84309
85880
  */
@@ -84689,7 +86260,7 @@ export type AgentsListResponses = {
84689
86260
  */
84690
86261
  environment_id?: string | null;
84691
86262
  /**
84692
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
86263
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
84693
86264
  */
84694
86265
  vault_ids?: Array<string>;
84695
86266
  /**
@@ -85228,7 +86799,7 @@ export type AgentsCreateData = {
85228
86799
  */
85229
86800
  environment_id?: string | null;
85230
86801
  /**
85231
- * Default vaults of a service agent: the vault_ids a new session gets when it names none, so the agent's credentials follow the version. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself, [] included, overrides it. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. Personal agents get no default vaults: a non-empty value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.
86802
+ * Default vaults of the agent: the vault_ids every new session carries, so the agent's credentials follow the version. A department or organization rule's grants write this list on the agents it reaches (the agent's vaults become exactly the rule's set). Their secrets reach each session's machine as environment variables and match its MCP servers; sessions.create says which are skipped. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself adds its vaults to these and does not replace them; sessions already open keep the vaults they were created with. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. General and assume agents hold vaults on themselves the same way. /agent/v1 only; /anthropic neither accepts nor returns it.
85232
86803
  */
85233
86804
  vault_ids?: Array<string>;
85234
86805
  /**
@@ -85253,6 +86824,15 @@ export type AgentsCreateData = {
85253
86824
  name: string;
85254
86825
  }>;
85255
86826
  };
86827
+ /**
86828
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
86829
+ */
86830
+ browser?: {
86831
+ /**
86832
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
86833
+ */
86834
+ byob: string;
86835
+ } | null;
85256
86836
  /**
85257
86837
  * Optional tool preset. minimal enables read, glob and grep; data-editor also enables write and edit; full uses the default toolset with always_allow. Explicit tools override matching preset entries. codemode requires bash and is absent from data-editor.
85258
86838
  */
@@ -85508,6 +87088,15 @@ export type AgentsCreateResponses = {
85508
87088
  name: string;
85509
87089
  }>;
85510
87090
  };
87091
+ /**
87092
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
87093
+ */
87094
+ browser?: {
87095
+ /**
87096
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
87097
+ */
87098
+ byob: string;
87099
+ } | null;
85511
87100
  /**
85512
87101
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
85513
87102
  */
@@ -85893,7 +87482,7 @@ export type AgentsCreateResponses = {
85893
87482
  */
85894
87483
  environment_id?: string | null;
85895
87484
  /**
85896
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
87485
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
85897
87486
  */
85898
87487
  vault_ids?: Array<string>;
85899
87488
  /**
@@ -86170,6 +87759,15 @@ export type AgentsRetrieveResponses = {
86170
87759
  name: string;
86171
87760
  }>;
86172
87761
  };
87762
+ /**
87763
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
87764
+ */
87765
+ browser?: {
87766
+ /**
87767
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
87768
+ */
87769
+ byob: string;
87770
+ } | null;
86173
87771
  /**
86174
87772
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
86175
87773
  */
@@ -86555,7 +88153,7 @@ export type AgentsRetrieveResponses = {
86555
88153
  */
86556
88154
  environment_id?: string | null;
86557
88155
  /**
86558
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
88156
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
86559
88157
  */
86560
88158
  vault_ids?: Array<string>;
86561
88159
  /**
@@ -87103,7 +88701,7 @@ export type AgentsUpdateData = {
87103
88701
  */
87104
88702
  environment_id?: string | null;
87105
88703
  /**
87106
- * Default vaults of a service agent: the vault_ids a new session gets when it names none, so the agent's credentials follow the version. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself, [] included, overrides it. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. Personal agents get no default vaults: a non-empty value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.
88704
+ * Default vaults of the agent: the vault_ids every new session carries, so the agent's credentials follow the version. A department or organization rule's grants write this list on the agents it reaches (the agent's vaults become exactly the rule's set). Their secrets reach each session's machine as environment variables and match its MCP servers; sessions.create says which are skipped. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself adds its vaults to these and does not replace them; sessions already open keep the vaults they were created with. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. General and assume agents hold vaults on themselves the same way. /agent/v1 only; /anthropic neither accepts nor returns it.
87107
88705
  */
87108
88706
  vault_ids?: Array<string>;
87109
88707
  /**
@@ -87128,6 +88726,15 @@ export type AgentsUpdateData = {
87128
88726
  name: string;
87129
88727
  }>;
87130
88728
  };
88729
+ /**
88730
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
88731
+ */
88732
+ browser?: {
88733
+ /**
88734
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
88735
+ */
88736
+ byob: string;
88737
+ } | null;
87131
88738
  /**
87132
88739
  * Optional tool preset. minimal enables read, glob and grep; data-editor also enables write and edit; full uses the default toolset with always_allow. Explicit tools override matching preset entries. codemode requires bash and is absent from data-editor.
87133
88740
  */
@@ -87396,6 +89003,15 @@ export type AgentsUpdateResponses = {
87396
89003
  name: string;
87397
89004
  }>;
87398
89005
  };
89006
+ /**
89007
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
89008
+ */
89009
+ browser?: {
89010
+ /**
89011
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
89012
+ */
89013
+ byob: string;
89014
+ } | null;
87399
89015
  /**
87400
89016
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
87401
89017
  */
@@ -87781,7 +89397,7 @@ export type AgentsUpdateResponses = {
87781
89397
  */
87782
89398
  environment_id?: string | null;
87783
89399
  /**
87784
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
89400
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
87785
89401
  */
87786
89402
  vault_ids?: Array<string>;
87787
89403
  /**
@@ -88407,7 +90023,7 @@ export type AgentsArchiveResponses = {
88407
90023
  */
88408
90024
  environment_id?: string | null;
88409
90025
  /**
88410
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
90026
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
88411
90027
  */
88412
90028
  vault_ids?: Array<string>;
88413
90029
  /**
@@ -88684,6 +90300,15 @@ export type AgentsVersionsListResponses = {
88684
90300
  name: string;
88685
90301
  }>;
88686
90302
  };
90303
+ /**
90304
+ * ADR-205: which browser the agent drives. {byob: byb_…} names one of your organization's paired browsers (browser.byob.browsers.list), which the agent then drives through connect() instead of a cloud browser; null or absent is the cloud browser. The browser must belong to your organization (otherwise 400) and must grant this agent before a session can open it. Omit on update to keep it, send an object to replace it, or null to go back to the cloud browser. /agent/v1 only.
90305
+ */
90306
+ browser?: {
90307
+ /**
90308
+ * A paired browser's id (byb_ and 26 lowercase hex characters), from browser.byob.browsers.list.
90309
+ */
90310
+ byob: string;
90311
+ } | null;
88687
90312
  /**
88688
90313
  * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
88689
90314
  */
@@ -89069,7 +90694,7 @@ export type AgentsVersionsListResponses = {
89069
90694
  */
89070
90695
  environment_id?: string | null;
89071
90696
  /**
89072
- * Default vaults of this service or assume agent version: the vault_ids new sessions get when they name none. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
90697
+ * Default vaults of this service or assume agent version: the vault_ids every new session carries; a session's own vault_ids are added to them. Present for service and assume agents. Follows the version like other configuration: a version saved with apply=false does not change the vaults in effect. Versions saved before this field existed read as []. /agent/v1 only.
89073
90698
  */
89074
90699
  vault_ids?: Array<string>;
89075
90700
  /**
@@ -98929,7 +100554,7 @@ export type AutomationRunsListData = {
98929
100554
  */
98930
100555
  channel?: Array<'console' | 'api' | 'internal' | 'run' | 'trigger'>;
98931
100556
  /**
98932
- * Root initiator type: user, api_key, agent or trigger, inherited by child runs. run returns INPUT_INVALID; filter origin with channel=run or parent_run_id. Separate multiple values with commas to match any value.
100557
+ * Root initiator type: user, api_key, agent, trigger or application, inherited by child runs. run returns INPUT_INVALID; filter origin with channel=run or parent_run_id. Separate multiple values with commas to match any value.
98933
100558
  */
98934
100559
  initiator_type?: Array<'user' | 'api_key' | 'agent' | 'trigger'>;
98935
100560
  /**
@@ -113477,7 +115102,7 @@ export type DevopsUnitsPushErrors = {
113477
115102
  */
113478
115103
  404: DevopsDevOpsError;
113479
115104
  /**
113480
- * HEAD_MOVED means the change's branch on the remote is no longer the expectedHead that was sent — someone pushed to it since — so nothing was pushed; fetch the unit, reconcile your checkout and send the new head. PUSH_REJECTED_BY_HOOK means the machine's git ran a pre-push hook (lefthook, for example) and the hook refused: details.detail holds the hook's output and details.exitCode git's exit code; fix what the hook names, commit, and push again. PUSH_REJECTED_NON_FAST_FORWARD means the remote branch has commits your checkout lacks; fetch, reconcile and push again. UNIT_INVALID_STATE means the unit is not available (no machine or no checkout yet, or another transition is in flight), so there is nothing to push; read the unit's phase and retry once it has settled.
115105
+ * HEAD_MOVED means the change's branch on the remote is no longer the expectedHead that was sent — someone pushed to it since — so nothing was pushed. The message says where the remote is ("remote is at <sha7> (<full sha>) on <ref>") and details.remoteHead carries the full sha: send it as expectedHead after reconciling your checkout. PUSH_REJECTED_BY_HOOK means the machine's git ran a pre-push hook (lefthook, for example) and the hook refused: details.detail holds the hook's output and details.exitCode git's exit code; fix what the hook names, commit, and push again. PUSH_REJECTED_NON_FAST_FORWARD means the remote branch has commits your checkout lacks; fetch, reconcile and push again. UNIT_INVALID_STATE means the unit is not available (no machine or no checkout yet, or another transition is in flight), so there is nothing to push; read the unit's phase and retry once it has settled.
113481
115106
  */
113482
115107
  409: DevopsDevOpsError;
113483
115108
  /**
@@ -118580,45 +120205,509 @@ export type MediaListUnderstandingsByLibraryErrors = {
118580
120205
  */
118581
120206
  503: MediaMediaError;
118582
120207
  };
118583
- export type MediaListUnderstandingsByLibraryError = MediaListUnderstandingsByLibraryErrors[keyof MediaListUnderstandingsByLibraryErrors];
118584
- export type MediaListUnderstandingsByLibraryResponses = {
120208
+ export type MediaListUnderstandingsByLibraryError = MediaListUnderstandingsByLibraryErrors[keyof MediaListUnderstandingsByLibraryErrors];
120209
+ export type MediaListUnderstandingsByLibraryResponses = {
120210
+ /**
120211
+ * Successful response.
120212
+ */
120213
+ 200: MediaUnderstandingPage;
120214
+ };
120215
+ export type MediaListUnderstandingsByLibraryResponse = MediaListUnderstandingsByLibraryResponses[keyof MediaListUnderstandingsByLibraryResponses];
120216
+ export type MediaListJobsData = {
120217
+ body?: never;
120218
+ path: {
120219
+ /**
120220
+ * Library ID returned by creation.
120221
+ */
120222
+ library_id: string;
120223
+ };
120224
+ query?: {
120225
+ /**
120226
+ * Filter jobs by their current status.
120227
+ */
120228
+ status?: MediaJobStatus;
120229
+ /**
120230
+ * Return only the jobs started by this automation run (its root run), so one pipeline run reads as one batch.
120231
+ */
120232
+ pipeline_run_id?: string;
120233
+ /**
120234
+ * Maximum entries in this page, from 1 through 100; defaults to 100.
120235
+ */
120236
+ limit?: number;
120237
+ /**
120238
+ * Job id from the previous page’s next_cursor; omit for the first page.
120239
+ */
120240
+ cursor?: MediaJobId;
120241
+ };
120242
+ url: '/media/v1/libraries/{library_id}/jobs';
120243
+ };
120244
+ export type MediaListJobsErrors = {
120245
+ /**
120246
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120247
+ */
120248
+ 400: MediaMediaError;
120249
+ /**
120250
+ * Request failed; see the error code reference.
120251
+ */
120252
+ 402: MediaMediaError;
120253
+ /**
120254
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120255
+ */
120256
+ 403: MediaMediaError;
120257
+ /**
120258
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120259
+ */
120260
+ 404: MediaMediaError;
120261
+ /**
120262
+ * Request failed; see the error code reference.
120263
+ */
120264
+ 409: MediaMediaError;
120265
+ /**
120266
+ * The file exceeds an input limit; provide a smaller source file.
120267
+ */
120268
+ 413: MediaMediaError;
120269
+ /**
120270
+ * This media format is unsupported; provide a supported format.
120271
+ */
120272
+ 415: MediaMediaError;
120273
+ /**
120274
+ * Request failed; see the error code reference.
120275
+ */
120276
+ 422: MediaMediaError;
120277
+ /**
120278
+ * A rate limit was reached; wait before retrying.
120279
+ */
120280
+ 429: MediaMediaError;
120281
+ /**
120282
+ * The requested operation is unsupported; choose a supported method.
120283
+ */
120284
+ 501: MediaMediaError;
120285
+ /**
120286
+ * Request failed; see the error code reference.
120287
+ */
120288
+ 502: MediaMediaError;
120289
+ /**
120290
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120291
+ */
120292
+ 503: MediaMediaError;
120293
+ };
120294
+ export type MediaListJobsError = MediaListJobsErrors[keyof MediaListJobsErrors];
120295
+ export type MediaListJobsResponses = {
120296
+ /**
120297
+ * Successful response.
120298
+ */
120299
+ 200: MediaJobPage;
120300
+ };
120301
+ export type MediaListJobsResponse = MediaListJobsResponses[keyof MediaListJobsResponses];
120302
+ export type MediaCancelJobData = {
120303
+ body?: never;
120304
+ path: {
120305
+ /**
120306
+ * Library ID returned by creation.
120307
+ */
120308
+ library_id: string;
120309
+ /**
120310
+ * Job identifier returned by batch or generation creation; the job is resolved within the specified library.
120311
+ */
120312
+ job_id: string;
120313
+ };
120314
+ query?: never;
120315
+ url: '/media/v1/libraries/{library_id}/jobs/{job_id}/cancel';
120316
+ };
120317
+ export type MediaCancelJobErrors = {
120318
+ /**
120319
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120320
+ */
120321
+ 400: MediaMediaError;
120322
+ /**
120323
+ * Request failed; see the error code reference.
120324
+ */
120325
+ 402: MediaMediaError;
120326
+ /**
120327
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120328
+ */
120329
+ 403: MediaMediaError;
120330
+ /**
120331
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120332
+ */
120333
+ 404: MediaMediaError;
120334
+ /**
120335
+ * Request failed; see the error code reference.
120336
+ */
120337
+ 409: MediaMediaError;
120338
+ /**
120339
+ * The file exceeds an input limit; provide a smaller source file.
120340
+ */
120341
+ 413: MediaMediaError;
120342
+ /**
120343
+ * This media format is unsupported; provide a supported format.
120344
+ */
120345
+ 415: MediaMediaError;
120346
+ /**
120347
+ * Request failed; see the error code reference.
120348
+ */
120349
+ 422: MediaMediaError;
120350
+ /**
120351
+ * A rate limit was reached; wait before retrying.
120352
+ */
120353
+ 429: MediaMediaError;
120354
+ /**
120355
+ * The requested operation is unsupported; choose a supported method.
120356
+ */
120357
+ 501: MediaMediaError;
120358
+ /**
120359
+ * Request failed; see the error code reference.
120360
+ */
120361
+ 502: MediaMediaError;
120362
+ /**
120363
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120364
+ */
120365
+ 503: MediaMediaError;
120366
+ };
120367
+ export type MediaCancelJobError = MediaCancelJobErrors[keyof MediaCancelJobErrors];
120368
+ export type MediaCancelJobResponses = {
120369
+ /**
120370
+ * Successful response.
120371
+ */
120372
+ 200: MediaJob;
120373
+ };
120374
+ export type MediaCancelJobResponse = MediaCancelJobResponses[keyof MediaCancelJobResponses];
120375
+ export type MediaGetGenerationCapabilitiesData = {
120376
+ body?: never;
120377
+ path?: never;
120378
+ query?: never;
120379
+ url: '/media/v1/generation/capabilities';
120380
+ };
120381
+ export type MediaGetGenerationCapabilitiesErrors = {
120382
+ /**
120383
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120384
+ */
120385
+ 400: MediaMediaError;
120386
+ /**
120387
+ * Request failed; see the error code reference.
120388
+ */
120389
+ 402: MediaMediaError;
120390
+ /**
120391
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120392
+ */
120393
+ 403: MediaMediaError;
120394
+ /**
120395
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120396
+ */
120397
+ 404: MediaMediaError;
120398
+ /**
120399
+ * Request failed; see the error code reference.
120400
+ */
120401
+ 409: MediaMediaError;
120402
+ /**
120403
+ * The file exceeds an input limit; provide a smaller source file.
120404
+ */
120405
+ 413: MediaMediaError;
120406
+ /**
120407
+ * This media format is unsupported; provide a supported format.
120408
+ */
120409
+ 415: MediaMediaError;
120410
+ /**
120411
+ * Request failed; see the error code reference.
120412
+ */
120413
+ 422: MediaMediaError;
120414
+ /**
120415
+ * A rate limit was reached; wait before retrying.
120416
+ */
120417
+ 429: MediaMediaError;
120418
+ /**
120419
+ * The requested operation is unsupported; choose a supported method.
120420
+ */
120421
+ 501: MediaMediaError;
120422
+ /**
120423
+ * Request failed; see the error code reference.
120424
+ */
120425
+ 502: MediaMediaError;
120426
+ /**
120427
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120428
+ */
120429
+ 503: MediaMediaError;
120430
+ };
120431
+ export type MediaGetGenerationCapabilitiesError = MediaGetGenerationCapabilitiesErrors[keyof MediaGetGenerationCapabilitiesErrors];
120432
+ export type MediaGetGenerationCapabilitiesResponses = {
120433
+ /**
120434
+ * Successful response.
120435
+ */
120436
+ 200: MediaGenerationCapabilities;
120437
+ };
120438
+ export type MediaGetGenerationCapabilitiesResponse = MediaGetGenerationCapabilitiesResponses[keyof MediaGetGenerationCapabilitiesResponses];
120439
+ export type MediaAlignAssetData = {
120440
+ /**
120441
+ * Align two recordings by their sound. The route names the source asset; this body names the reference to align against it. The result is an analysis, not a new asset: nothing is stored, the source is never changed, and the completed job carries the answer in result.
120442
+ */
120443
+ body: {
120444
+ /**
120445
+ * Asset to align against the one the route names. It must be an audio or video asset of the same library, otherwise the request is refused with REFERENCE_TYPE_MISMATCH before a job exists.
120446
+ */
120447
+ reference_asset_id: string;
120448
+ /**
120449
+ * Largest offset to search for, in seconds; omit it to let the model search its full range. Zero and negative values are refused with INVALID_PARAMS.
120450
+ */
120451
+ max_offset_seconds?: number;
120452
+ /**
120453
+ * Stable key so a retried request reuses the same job instead of analysing and charging again; reusing it with different content is rejected.
120454
+ */
120455
+ idempotency_key?: string;
120456
+ };
120457
+ headers?: {
120458
+ /**
120459
+ * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
120460
+ */
120461
+ 'Idempotency-Key'?: string;
120462
+ };
120463
+ path: {
120464
+ /**
120465
+ * Library ID returned by creation.
120466
+ */
120467
+ library_id: string;
120468
+ /**
120469
+ * 32-character asset ID.
120470
+ */
120471
+ asset_id: string;
120472
+ };
120473
+ query?: never;
120474
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/align';
120475
+ };
120476
+ export type MediaAlignAssetErrors = {
120477
+ /**
120478
+ * REFERENCE_TYPE_MISMATCH: the source asset or the reference asset is not an audio or video asset; both must be one of the two. INVALID_PARAMS: reference_asset_id is missing, max_offset_seconds is zero or negative, or the request names an alignment model the generation capabilities do not offer. OPERATION_NOT_SUPPORTED: the platform has published no alignment model, so the request is refused with the model field named. Correct the reported field; nothing was analysed and nothing was charged.
120479
+ */
120480
+ 400: MediaMediaError;
120481
+ /**
120482
+ * INSUFFICIENT_BALANCE: the organization balance cannot cover the estimated cost of this generation or edit; top up and resubmit. Nothing was generated and nothing was charged for this request.
120483
+ */
120484
+ 402: MediaMediaError;
120485
+ /**
120486
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120487
+ */
120488
+ 403: MediaMediaError;
120489
+ /**
120490
+ * ASSET_NOT_FOUND: the source or the reference asset is missing, deleted or belongs to another library, or the addressed library was not found; verify the identifiers with libraries and assets. A reference asset that cannot be reached answers the same way, never as a hint that it exists elsewhere.
120491
+ */
120492
+ 404: MediaMediaError;
120493
+ /**
120494
+ * MODEL_PENDING or JOB_INVALID_STATE: the chosen model is not ready for this library, or the job cannot start from its current state; wait for the model to become available, or start a new job rather than resuming this one.
120495
+ */
120496
+ 409: MediaMediaError;
120497
+ /**
120498
+ * The file exceeds an input limit; provide a smaller source file.
120499
+ */
120500
+ 413: MediaMediaError;
120501
+ /**
120502
+ * This media format is unsupported; provide a supported format.
120503
+ */
120504
+ 415: MediaMediaError;
120505
+ /**
120506
+ * CONTENT_REJECTED: the provider refused the prompt or the source image under its content policy; change the prompt or the source before retrying. Nothing was generated and nothing was charged.
120507
+ */
120508
+ 422: MediaMediaError;
120509
+ /**
120510
+ * RATE_LIMITED: this library already has its maximum number of running jobs of this type and 50 more waiting, or the provider is throttling requests; Retry-After gives the seconds to wait before retrying. Below that a job past the running limit is accepted and waits (queue_reason concurrency) instead of being refused.
120511
+ */
120512
+ 429: MediaMediaError;
120513
+ /**
120514
+ * The requested operation is unsupported; choose a supported method.
120515
+ */
120516
+ 501: MediaMediaError;
120517
+ /**
120518
+ * Request failed; see the error code reference.
120519
+ */
120520
+ 502: MediaMediaError;
120521
+ /**
120522
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120523
+ */
120524
+ 503: MediaMediaError;
120525
+ };
120526
+ export type MediaAlignAssetError = MediaAlignAssetErrors[keyof MediaAlignAssetErrors];
120527
+ export type MediaAlignAssetResponses = {
120528
+ /**
120529
+ * The alignment job is queued. Poll GET /media/v1/libraries/{library_id}/jobs/{job_id} until its status is completed or failed; a completed job carries the answer in result as offset_seconds and confidence, so a caller holding both recordings knows which one to slide. No asset is stored and nothing is overwritten. An alignment with the same source, reference and params answers the job already completed instead of analysing and charging again.
120530
+ */
120531
+ 202: MediaJob;
120532
+ };
120533
+ export type MediaAlignAssetResponse = MediaAlignAssetResponses[keyof MediaAlignAssetResponses];
120534
+ export type MediaGetHlsRenditionsData = {
120535
+ body?: never;
120536
+ path: {
120537
+ /**
120538
+ * Library ID returned by creation.
120539
+ */
120540
+ library_id: string;
120541
+ /**
120542
+ * 32-character asset ID.
120543
+ */
120544
+ asset_id: string;
120545
+ };
120546
+ query?: never;
120547
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/hls';
120548
+ };
120549
+ export type MediaGetHlsRenditionsErrors = {
120550
+ /**
120551
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120552
+ */
120553
+ 400: MediaMediaError;
120554
+ /**
120555
+ * Request failed; see the error code reference.
120556
+ */
120557
+ 402: MediaMediaError;
120558
+ /**
120559
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120560
+ */
120561
+ 403: MediaMediaError;
120562
+ /**
120563
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120564
+ */
120565
+ 404: MediaMediaError;
120566
+ /**
120567
+ * Request failed; see the error code reference.
120568
+ */
120569
+ 409: MediaMediaError;
120570
+ /**
120571
+ * The file exceeds an input limit; provide a smaller source file.
120572
+ */
120573
+ 413: MediaMediaError;
120574
+ /**
120575
+ * This media format is unsupported; provide a supported format.
120576
+ */
120577
+ 415: MediaMediaError;
120578
+ /**
120579
+ * Request failed; see the error code reference.
120580
+ */
120581
+ 422: MediaMediaError;
120582
+ /**
120583
+ * A rate limit was reached; wait before retrying.
120584
+ */
120585
+ 429: MediaMediaError;
120586
+ /**
120587
+ * The requested operation is unsupported; choose a supported method.
120588
+ */
120589
+ 501: MediaMediaError;
120590
+ /**
120591
+ * Request failed; see the error code reference.
120592
+ */
120593
+ 502: MediaMediaError;
120594
+ /**
120595
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120596
+ */
120597
+ 503: MediaMediaError;
120598
+ };
120599
+ export type MediaGetHlsRenditionsError = MediaGetHlsRenditionsErrors[keyof MediaGetHlsRenditionsErrors];
120600
+ export type MediaGetHlsRenditionsResponses = {
120601
+ /**
120602
+ * Successful response.
120603
+ */
120604
+ 200: MediaHlsLadder;
120605
+ };
120606
+ export type MediaGetHlsRenditionsResponse = MediaGetHlsRenditionsResponses[keyof MediaGetHlsRenditionsResponses];
120607
+ export type MediaRequestHlsRenditionsData = {
120608
+ /**
120609
+ * Which clarity rungs to build for the asset. Omit heights to build the whole ladder.
120610
+ */
120611
+ body: {
120612
+ /**
120613
+ * The clarity rungs to build: a non-empty subset of 480, 720 and 1080 with no repeats. Omitted or empty builds all three. The ladder never upscales, so a rung above the source’s short side is dropped.
120614
+ */
120615
+ heights?: Array<480 | 720 | 1080>;
120616
+ };
120617
+ path: {
120618
+ /**
120619
+ * Library ID returned by creation.
120620
+ */
120621
+ library_id: string;
120622
+ /**
120623
+ * 32-character asset ID.
120624
+ */
120625
+ asset_id: string;
120626
+ };
120627
+ query?: never;
120628
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/hls';
120629
+ };
120630
+ export type MediaRequestHlsRenditionsErrors = {
120631
+ /**
120632
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120633
+ */
120634
+ 400: MediaMediaError;
120635
+ /**
120636
+ * Request failed; see the error code reference.
120637
+ */
120638
+ 402: MediaMediaError;
120639
+ /**
120640
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
120641
+ */
120642
+ 403: MediaMediaError;
120643
+ /**
120644
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120645
+ */
120646
+ 404: MediaMediaError;
120647
+ /**
120648
+ * Request failed; see the error code reference.
120649
+ */
120650
+ 409: MediaMediaError;
120651
+ /**
120652
+ * The file exceeds an input limit; provide a smaller source file.
120653
+ */
120654
+ 413: MediaMediaError;
120655
+ /**
120656
+ * This media format is unsupported; provide a supported format.
120657
+ */
120658
+ 415: MediaMediaError;
120659
+ /**
120660
+ * Request failed; see the error code reference.
120661
+ */
120662
+ 422: MediaMediaError;
120663
+ /**
120664
+ * A rate limit was reached; wait before retrying.
120665
+ */
120666
+ 429: MediaMediaError;
120667
+ /**
120668
+ * The requested operation is unsupported; choose a supported method.
120669
+ */
120670
+ 501: MediaMediaError;
120671
+ /**
120672
+ * Request failed; see the error code reference.
120673
+ */
120674
+ 502: MediaMediaError;
120675
+ /**
120676
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120677
+ */
120678
+ 503: MediaMediaError;
120679
+ };
120680
+ export type MediaRequestHlsRenditionsError = MediaRequestHlsRenditionsErrors[keyof MediaRequestHlsRenditionsErrors];
120681
+ export type MediaRequestHlsRenditionsResponses = {
118585
120682
  /**
118586
120683
  * Successful response.
118587
120684
  */
118588
- 200: MediaUnderstandingPage;
120685
+ 202: MediaHlsLadder;
118589
120686
  };
118590
- export type MediaListUnderstandingsByLibraryResponse = MediaListUnderstandingsByLibraryResponses[keyof MediaListUnderstandingsByLibraryResponses];
118591
- export type MediaListJobsData = {
118592
- body?: never;
118593
- path: {
120687
+ export type MediaRequestHlsRenditionsResponse = MediaRequestHlsRenditionsResponses[keyof MediaRequestHlsRenditionsResponses];
120688
+ export type MediaCreateVoiceData = {
120689
+ /**
120690
+ * Exactly one of the two voice shapes: consent_id with samples (a consented voice) or design_asset_id (a generated voice).
120691
+ */
120692
+ body: MediaVoiceCloneInput | MediaVoiceDesignCreateInput;
120693
+ headers?: {
118594
120694
  /**
118595
- * Library ID returned by creation.
120695
+ * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
118596
120696
  */
118597
- library_id: string;
120697
+ 'Idempotency-Key'?: string;
118598
120698
  };
118599
- query?: {
118600
- /**
118601
- * Filter jobs by their current status.
118602
- */
118603
- status?: MediaJobStatus;
118604
- /**
118605
- * Return only the jobs started by this automation run (its root run), so one pipeline run reads as one batch.
118606
- */
118607
- pipeline_run_id?: string;
118608
- /**
118609
- * Maximum entries in this page, from 1 through 100; defaults to 100.
118610
- */
118611
- limit?: number;
120699
+ path: {
118612
120700
  /**
118613
- * Job id from the previous page’s next_cursor; omit for the first page.
120701
+ * Library ID returned by creation.
118614
120702
  */
118615
- cursor?: MediaJobId;
120703
+ library_id: string;
118616
120704
  };
118617
- url: '/media/v1/libraries/{library_id}/jobs';
120705
+ query?: never;
120706
+ url: '/media/v1/libraries/{library_id}/voices';
118618
120707
  };
118619
- export type MediaListJobsErrors = {
120708
+ export type MediaCreateVoiceErrors = {
118620
120709
  /**
118621
- * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120710
+ * Request failed; see the error code reference.
118622
120711
  */
118623
120712
  400: MediaMediaError;
118624
120713
  /**
@@ -118626,11 +120715,11 @@ export type MediaListJobsErrors = {
118626
120715
  */
118627
120716
  402: MediaMediaError;
118628
120717
  /**
118629
- * This credential has read-only access to the library; use a write-capable binding for mutations.
120718
+ * Request failed; see the error code reference.
118630
120719
  */
118631
120720
  403: MediaMediaError;
118632
120721
  /**
118633
- * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120722
+ * Request failed; see the error code reference.
118634
120723
  */
118635
120724
  404: MediaMediaError;
118636
120725
  /**
@@ -118638,11 +120727,11 @@ export type MediaListJobsErrors = {
118638
120727
  */
118639
120728
  409: MediaMediaError;
118640
120729
  /**
118641
- * The file exceeds an input limit; provide a smaller source file.
120730
+ * Request failed; see the error code reference.
118642
120731
  */
118643
120732
  413: MediaMediaError;
118644
120733
  /**
118645
- * This media format is unsupported; provide a supported format.
120734
+ * Request failed; see the error code reference.
118646
120735
  */
118647
120736
  415: MediaMediaError;
118648
120737
  /**
@@ -118650,11 +120739,11 @@ export type MediaListJobsErrors = {
118650
120739
  */
118651
120740
  422: MediaMediaError;
118652
120741
  /**
118653
- * A rate limit was reached; wait before retrying.
120742
+ * Request failed; see the error code reference.
118654
120743
  */
118655
120744
  429: MediaMediaError;
118656
120745
  /**
118657
- * The requested operation is unsupported; choose a supported method.
120746
+ * Request failed; see the error code reference.
118658
120747
  */
118659
120748
  501: MediaMediaError;
118660
120749
  /**
@@ -118662,36 +120751,58 @@ export type MediaListJobsErrors = {
118662
120751
  */
118663
120752
  502: MediaMediaError;
118664
120753
  /**
118665
- * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120754
+ * Request failed; see the error code reference.
118666
120755
  */
118667
120756
  503: MediaMediaError;
118668
120757
  };
118669
- export type MediaListJobsError = MediaListJobsErrors[keyof MediaListJobsErrors];
118670
- export type MediaListJobsResponses = {
120758
+ export type MediaCreateVoiceError = MediaCreateVoiceErrors[keyof MediaCreateVoiceErrors];
120759
+ export type MediaCreateVoiceResponses = {
118671
120760
  /**
118672
120761
  * Successful response.
118673
120762
  */
118674
- 200: MediaJobPage;
120763
+ 202: MediaJob;
118675
120764
  };
118676
- export type MediaListJobsResponse = MediaListJobsResponses[keyof MediaListJobsResponses];
118677
- export type MediaCancelJobData = {
118678
- body?: never;
120765
+ export type MediaCreateVoiceResponse = MediaCreateVoiceResponses[keyof MediaCreateVoiceResponses];
120766
+ export type MediaDesignVoiceData = {
120767
+ /**
120768
+ * One voice-design run: what the voice should sound like and the line the previews speak.
120769
+ */
120770
+ body: {
120771
+ /**
120772
+ * Text description of the voice to design, 1 to 500 characters. The model makes every preview from it; a description that fails review answers CONTENT_REJECTED.
120773
+ */
120774
+ description: string;
120775
+ /**
120776
+ * Line each preview speaks, 15 to 200 characters: long enough to hear the voice, short enough for one model call.
120777
+ */
120778
+ preview_text: string;
120779
+ /**
120780
+ * Language the previews speak: zh or en only.
120781
+ */
120782
+ language: 'zh' | 'en';
120783
+ /**
120784
+ * How many preview recordings to design, 1 to 3; defaults to 3. Each one is stored as an audio asset.
120785
+ */
120786
+ count?: number;
120787
+ };
120788
+ headers?: {
120789
+ /**
120790
+ * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
120791
+ */
120792
+ 'Idempotency-Key'?: string;
120793
+ };
118679
120794
  path: {
118680
120795
  /**
118681
120796
  * Library ID returned by creation.
118682
120797
  */
118683
120798
  library_id: string;
118684
- /**
118685
- * Job identifier returned by batch or generation creation; the job is resolved within the specified library.
118686
- */
118687
- job_id: string;
118688
120799
  };
118689
120800
  query?: never;
118690
- url: '/media/v1/libraries/{library_id}/jobs/{job_id}/cancel';
120801
+ url: '/media/v1/libraries/{library_id}/voices/designs';
118691
120802
  };
118692
- export type MediaCancelJobErrors = {
120803
+ export type MediaDesignVoiceErrors = {
118693
120804
  /**
118694
- * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
120805
+ * Request failed; see the error code reference.
118695
120806
  */
118696
120807
  400: MediaMediaError;
118697
120808
  /**
@@ -118699,11 +120810,11 @@ export type MediaCancelJobErrors = {
118699
120810
  */
118700
120811
  402: MediaMediaError;
118701
120812
  /**
118702
- * This credential has read-only access to the library; use a write-capable binding for mutations.
120813
+ * Request failed; see the error code reference.
118703
120814
  */
118704
120815
  403: MediaMediaError;
118705
120816
  /**
118706
- * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
120817
+ * Request failed; see the error code reference.
118707
120818
  */
118708
120819
  404: MediaMediaError;
118709
120820
  /**
@@ -118711,11 +120822,11 @@ export type MediaCancelJobErrors = {
118711
120822
  */
118712
120823
  409: MediaMediaError;
118713
120824
  /**
118714
- * The file exceeds an input limit; provide a smaller source file.
120825
+ * Request failed; see the error code reference.
118715
120826
  */
118716
120827
  413: MediaMediaError;
118717
120828
  /**
118718
- * This media format is unsupported; provide a supported format.
120829
+ * Request failed; see the error code reference.
118719
120830
  */
118720
120831
  415: MediaMediaError;
118721
120832
  /**
@@ -118723,11 +120834,11 @@ export type MediaCancelJobErrors = {
118723
120834
  */
118724
120835
  422: MediaMediaError;
118725
120836
  /**
118726
- * A rate limit was reached; wait before retrying.
120837
+ * Request failed; see the error code reference.
118727
120838
  */
118728
120839
  429: MediaMediaError;
118729
120840
  /**
118730
- * The requested operation is unsupported; choose a supported method.
120841
+ * Request failed; see the error code reference.
118731
120842
  */
118732
120843
  501: MediaMediaError;
118733
120844
  /**
@@ -118735,25 +120846,51 @@ export type MediaCancelJobErrors = {
118735
120846
  */
118736
120847
  502: MediaMediaError;
118737
120848
  /**
118738
- * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
120849
+ * Request failed; see the error code reference.
118739
120850
  */
118740
120851
  503: MediaMediaError;
118741
120852
  };
118742
- export type MediaCancelJobError = MediaCancelJobErrors[keyof MediaCancelJobErrors];
118743
- export type MediaCancelJobResponses = {
120853
+ export type MediaDesignVoiceError = MediaDesignVoiceErrors[keyof MediaDesignVoiceErrors];
120854
+ export type MediaDesignVoiceResponses = {
118744
120855
  /**
118745
120856
  * Successful response.
118746
120857
  */
118747
- 200: MediaJob;
120858
+ 202: MediaJob;
118748
120859
  };
118749
- export type MediaCancelJobResponse = MediaCancelJobResponses[keyof MediaCancelJobResponses];
118750
- export type MediaGetGenerationCapabilitiesData = {
120860
+ export type MediaDesignVoiceResponse = MediaDesignVoiceResponses[keyof MediaDesignVoiceResponses];
120861
+ export type MediaListWorksData = {
118751
120862
  body?: never;
118752
- path?: never;
118753
- query?: never;
118754
- url: '/media/v1/generation/capabilities';
120863
+ path: {
120864
+ /**
120865
+ * Library ID returned by creation.
120866
+ */
120867
+ library_id: string;
120868
+ };
120869
+ query?: {
120870
+ /**
120871
+ * Only works of this kind: gallery, article, product_listing or blocks.
120872
+ */
120873
+ kind?: 'gallery' | 'article' | 'product_listing' | 'blocks';
120874
+ /**
120875
+ * Only works of this series.
120876
+ */
120877
+ series?: string;
120878
+ /**
120879
+ * Only works whose title contains this text, at most 100 characters.
120880
+ */
120881
+ q?: string;
120882
+ /**
120883
+ * Maximum entries in this page, from 1 through 100; defaults to 100.
120884
+ */
120885
+ limit?: number;
120886
+ /**
120887
+ * Cursor from the previous next_cursor.
120888
+ */
120889
+ cursor?: string;
120890
+ };
120891
+ url: '/media/v1/libraries/{library_id}/works';
118755
120892
  };
118756
- export type MediaGetGenerationCapabilitiesErrors = {
120893
+ export type MediaListWorksErrors = {
118757
120894
  /**
118758
120895
  * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
118759
120896
  */
@@ -118803,58 +120940,52 @@ export type MediaGetGenerationCapabilitiesErrors = {
118803
120940
  */
118804
120941
  503: MediaMediaError;
118805
120942
  };
118806
- export type MediaGetGenerationCapabilitiesError = MediaGetGenerationCapabilitiesErrors[keyof MediaGetGenerationCapabilitiesErrors];
118807
- export type MediaGetGenerationCapabilitiesResponses = {
120943
+ export type MediaListWorksError = MediaListWorksErrors[keyof MediaListWorksErrors];
120944
+ export type MediaListWorksResponses = {
118808
120945
  /**
118809
120946
  * Successful response.
118810
120947
  */
118811
- 200: MediaGenerationCapabilities;
120948
+ 200: MediaWorkPage;
118812
120949
  };
118813
- export type MediaGetGenerationCapabilitiesResponse = MediaGetGenerationCapabilitiesResponses[keyof MediaGetGenerationCapabilitiesResponses];
118814
- export type MediaAlignAssetData = {
120950
+ export type MediaListWorksResponse = MediaListWorksResponses[keyof MediaListWorksResponses];
120951
+ export type MediaCreateWorkData = {
118815
120952
  /**
118816
- * Align two recordings by their sound. The route names the source asset; this body names the reference to align against it. The result is an analysis, not a new asset: nothing is stored, the source is never changed, and the completed job carries the answer in result.
120953
+ * A new work: its kind and its whole body, with an optional series and custom fields.
118817
120954
  */
118818
120955
  body: {
118819
120956
  /**
118820
- * Asset to align against the one the route names. It must be an audio or video asset of the same library, otherwise the request is refused with REFERENCE_TYPE_MISMATCH before a job exists.
120957
+ * The work’s kind; it decides which body fields are accepted.
118821
120958
  */
118822
- reference_asset_id: string;
120959
+ kind: MediaWorkKind;
118823
120960
  /**
118824
- * Largest offset to search for, in seconds; omit it to let the model search its full range. Zero and negative values are refused with INVALID_PARAMS.
120961
+ * The kind’s body. Every asset it names must be a live asset of this library of the fitting type, or the request is refused with ASSET_NOT_FOUND or REFERENCE_TYPE_MISMATCH naming every bad reference, and nothing is saved.
118825
120962
  */
118826
- max_offset_seconds?: number;
120963
+ body: MediaWorkBody;
118827
120964
  /**
118828
- * Stable key so a retried request reuses the same job instead of analysing and charging again; reusing it with different content is rejected.
120965
+ * Groups the platform versions of one story: 1 to 64 characters of a-z, 0-9, _ and -.
118829
120966
  */
118830
- idempotency_key?: string;
118831
- };
118832
- headers?: {
120967
+ series?: string;
118833
120968
  /**
118834
- * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
120969
+ * Caller data such as source, published links and numbers; at most 50 keys and 16 KB as JSON.
118835
120970
  */
118836
- 'Idempotency-Key'?: string;
120971
+ custom?: MediaWorkCustom;
118837
120972
  };
118838
120973
  path: {
118839
120974
  /**
118840
120975
  * Library ID returned by creation.
118841
120976
  */
118842
120977
  library_id: string;
118843
- /**
118844
- * 32-character asset ID.
118845
- */
118846
- asset_id: string;
118847
120978
  };
118848
120979
  query?: never;
118849
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}/align';
120980
+ url: '/media/v1/libraries/{library_id}/works';
118850
120981
  };
118851
- export type MediaAlignAssetErrors = {
120982
+ export type MediaCreateWorkErrors = {
118852
120983
  /**
118853
- * REFERENCE_TYPE_MISMATCH: the source asset or the reference asset is not an audio or video asset; both must be one of the two. INVALID_PARAMS: reference_asset_id is missing, max_offset_seconds is zero or negative, or the request names an alignment model the generation capabilities do not offer. OPERATION_NOT_SUPPORTED: the platform has published no alignment model, so the request is refused with the model field named. Correct the reported field; nothing was analysed and nothing was charged.
120984
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
118854
120985
  */
118855
120986
  400: MediaMediaError;
118856
120987
  /**
118857
- * INSUFFICIENT_BALANCE: the organization balance cannot cover the estimated cost of this generation or edit; top up and resubmit. Nothing was generated and nothing was charged for this request.
120988
+ * Request failed; see the error code reference.
118858
120989
  */
118859
120990
  402: MediaMediaError;
118860
120991
  /**
@@ -118862,11 +120993,11 @@ export type MediaAlignAssetErrors = {
118862
120993
  */
118863
120994
  403: MediaMediaError;
118864
120995
  /**
118865
- * ASSET_NOT_FOUND: the source or the reference asset is missing, deleted or belongs to another library, or the addressed library was not found; verify the identifiers with libraries and assets. A reference asset that cannot be reached answers the same way, never as a hint that it exists elsewhere.
120996
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
118866
120997
  */
118867
120998
  404: MediaMediaError;
118868
120999
  /**
118869
- * MODEL_PENDING or JOB_INVALID_STATE: the chosen model is not ready for this library, or the job cannot start from its current state; wait for the model to become available, or start a new job rather than resuming this one.
121000
+ * Request failed; see the error code reference.
118870
121001
  */
118871
121002
  409: MediaMediaError;
118872
121003
  /**
@@ -118878,11 +121009,11 @@ export type MediaAlignAssetErrors = {
118878
121009
  */
118879
121010
  415: MediaMediaError;
118880
121011
  /**
118881
- * CONTENT_REJECTED: the provider refused the prompt or the source image under its content policy; change the prompt or the source before retrying. Nothing was generated and nothing was charged.
121012
+ * Request failed; see the error code reference.
118882
121013
  */
118883
121014
  422: MediaMediaError;
118884
121015
  /**
118885
- * RATE_LIMITED: this library already has its maximum number of running jobs of this type and 50 more waiting, or the provider is throttling requests; Retry-After gives the seconds to wait before retrying. Below that a job past the running limit is accepted and waits (queue_reason concurrency) instead of being refused.
121016
+ * A rate limit was reached; wait before retrying.
118886
121017
  */
118887
121018
  429: MediaMediaError;
118888
121019
  /**
@@ -118898,15 +121029,15 @@ export type MediaAlignAssetErrors = {
118898
121029
  */
118899
121030
  503: MediaMediaError;
118900
121031
  };
118901
- export type MediaAlignAssetError = MediaAlignAssetErrors[keyof MediaAlignAssetErrors];
118902
- export type MediaAlignAssetResponses = {
121032
+ export type MediaCreateWorkError = MediaCreateWorkErrors[keyof MediaCreateWorkErrors];
121033
+ export type MediaCreateWorkResponses = {
118903
121034
  /**
118904
- * The alignment job is queued. Poll GET /media/v1/libraries/{library_id}/jobs/{job_id} until its status is completed or failed; a completed job carries the answer in result as offset_seconds and confidence, so a caller holding both recordings knows which one to slide. No asset is stored and nothing is overwritten. An alignment with the same source, reference and params answers the job already completed instead of analysing and charging again.
121035
+ * Successful response.
118905
121036
  */
118906
- 202: MediaJob;
121037
+ 200: MediaWork;
118907
121038
  };
118908
- export type MediaAlignAssetResponse = MediaAlignAssetResponses[keyof MediaAlignAssetResponses];
118909
- export type MediaGetHlsRenditionsData = {
121039
+ export type MediaCreateWorkResponse = MediaCreateWorkResponses[keyof MediaCreateWorkResponses];
121040
+ export type MediaDeleteWorkData = {
118910
121041
  body?: never;
118911
121042
  path: {
118912
121043
  /**
@@ -118914,14 +121045,14 @@ export type MediaGetHlsRenditionsData = {
118914
121045
  */
118915
121046
  library_id: string;
118916
121047
  /**
118917
- * 32-character asset ID.
121048
+ * Work id (wrk_…) returned by creation or listing.
118918
121049
  */
118919
- asset_id: string;
121050
+ work_id: string;
118920
121051
  };
118921
121052
  query?: never;
118922
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}/hls';
121053
+ url: '/media/v1/libraries/{library_id}/works/{work_id}';
118923
121054
  };
118924
- export type MediaGetHlsRenditionsErrors = {
121055
+ export type MediaDeleteWorkErrors = {
118925
121056
  /**
118926
121057
  * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
118927
121058
  */
@@ -118971,38 +121102,35 @@ export type MediaGetHlsRenditionsErrors = {
118971
121102
  */
118972
121103
  503: MediaMediaError;
118973
121104
  };
118974
- export type MediaGetHlsRenditionsError = MediaGetHlsRenditionsErrors[keyof MediaGetHlsRenditionsErrors];
118975
- export type MediaGetHlsRenditionsResponses = {
121105
+ export type MediaDeleteWorkError = MediaDeleteWorkErrors[keyof MediaDeleteWorkErrors];
121106
+ export type MediaDeleteWorkResponses = {
118976
121107
  /**
118977
121108
  * Successful response.
118978
121109
  */
118979
- 200: MediaHlsLadder;
121110
+ 200: MediaDeletedWork;
118980
121111
  };
118981
- export type MediaGetHlsRenditionsResponse = MediaGetHlsRenditionsResponses[keyof MediaGetHlsRenditionsResponses];
118982
- export type MediaRequestHlsRenditionsData = {
118983
- /**
118984
- * Which clarity rungs to build for the asset. Omit heights to build the whole ladder.
118985
- */
118986
- body: {
118987
- /**
118988
- * The clarity rungs to build: a non-empty subset of 480, 720 and 1080 with no repeats. Omitted or empty builds all three. The ladder never upscales, so a rung above the source’s short side is dropped.
118989
- */
118990
- heights?: Array<480 | 720 | 1080>;
118991
- };
121112
+ export type MediaDeleteWorkResponse = MediaDeleteWorkResponses[keyof MediaDeleteWorkResponses];
121113
+ export type MediaGetWorkData = {
121114
+ body?: never;
118992
121115
  path: {
118993
121116
  /**
118994
121117
  * Library ID returned by creation.
118995
121118
  */
118996
121119
  library_id: string;
118997
121120
  /**
118998
- * 32-character asset ID.
121121
+ * Work id (wrk_…) returned by creation or listing.
118999
121122
  */
119000
- asset_id: string;
121123
+ work_id: string;
119001
121124
  };
119002
- query?: never;
119003
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}/hls';
121125
+ query?: {
121126
+ /**
121127
+ * assets returns every referenced asset with its URLs and size.
121128
+ */
121129
+ expand?: string;
121130
+ };
121131
+ url: '/media/v1/libraries/{library_id}/works/{work_id}';
119004
121132
  };
119005
- export type MediaRequestHlsRenditionsErrors = {
121133
+ export type MediaGetWorkErrors = {
119006
121134
  /**
119007
121135
  * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
119008
121136
  */
@@ -119052,37 +121180,52 @@ export type MediaRequestHlsRenditionsErrors = {
119052
121180
  */
119053
121181
  503: MediaMediaError;
119054
121182
  };
119055
- export type MediaRequestHlsRenditionsError = MediaRequestHlsRenditionsErrors[keyof MediaRequestHlsRenditionsErrors];
119056
- export type MediaRequestHlsRenditionsResponses = {
121183
+ export type MediaGetWorkError = MediaGetWorkErrors[keyof MediaGetWorkErrors];
121184
+ export type MediaGetWorkResponses = {
119057
121185
  /**
119058
121186
  * Successful response.
119059
121187
  */
119060
- 202: MediaHlsLadder;
121188
+ 200: MediaWork;
119061
121189
  };
119062
- export type MediaRequestHlsRenditionsResponse = MediaRequestHlsRenditionsResponses[keyof MediaRequestHlsRenditionsResponses];
119063
- export type MediaCreateVoiceData = {
121190
+ export type MediaGetWorkResponse = MediaGetWorkResponses[keyof MediaGetWorkResponses];
121191
+ export type MediaUpdateWorkData = {
119064
121192
  /**
119065
- * Exactly one of the two voice shapes: consent_id with samples (a consented voice) or design_asset_id (a generated voice).
121193
+ * Changes to a work. Send only what changes.
119066
121194
  */
119067
- body: MediaVoiceCloneInput | MediaVoiceDesignCreateInput;
119068
- headers?: {
121195
+ body: {
119069
121196
  /**
119070
- * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
121197
+ * A whole new body for the same kind; it replaces the old one and is checked like a new one.
119071
121198
  */
119072
- 'Idempotency-Key'?: string;
121199
+ body?: MediaWorkBody;
121200
+ /**
121201
+ * A new series, or null to clear it.
121202
+ */
121203
+ series?: string | null;
121204
+ /**
121205
+ * A JSON Merge Patch (RFC 7396): keys you send are set, keys set to null are removed, keys you leave out are kept.
121206
+ */
121207
+ custom?: MediaWorkCustom;
121208
+ /**
121209
+ * Apply the change only if the work is still at this revision; otherwise the answer is 409 REVISION_CONFLICT with the current revision.
121210
+ */
121211
+ if_revision?: number;
119073
121212
  };
119074
121213
  path: {
119075
121214
  /**
119076
121215
  * Library ID returned by creation.
119077
121216
  */
119078
121217
  library_id: string;
121218
+ /**
121219
+ * Work id (wrk_…) returned by creation or listing.
121220
+ */
121221
+ work_id: string;
119079
121222
  };
119080
121223
  query?: never;
119081
- url: '/media/v1/libraries/{library_id}/voices';
121224
+ url: '/media/v1/libraries/{library_id}/works/{work_id}';
119082
121225
  };
119083
- export type MediaCreateVoiceErrors = {
121226
+ export type MediaUpdateWorkErrors = {
119084
121227
  /**
119085
- * Request failed; see the error code reference.
121228
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
119086
121229
  */
119087
121230
  400: MediaMediaError;
119088
121231
  /**
@@ -119090,11 +121233,11 @@ export type MediaCreateVoiceErrors = {
119090
121233
  */
119091
121234
  402: MediaMediaError;
119092
121235
  /**
119093
- * Request failed; see the error code reference.
121236
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
119094
121237
  */
119095
121238
  403: MediaMediaError;
119096
121239
  /**
119097
- * Request failed; see the error code reference.
121240
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
119098
121241
  */
119099
121242
  404: MediaMediaError;
119100
121243
  /**
@@ -119102,11 +121245,11 @@ export type MediaCreateVoiceErrors = {
119102
121245
  */
119103
121246
  409: MediaMediaError;
119104
121247
  /**
119105
- * Request failed; see the error code reference.
121248
+ * The file exceeds an input limit; provide a smaller source file.
119106
121249
  */
119107
121250
  413: MediaMediaError;
119108
121251
  /**
119109
- * Request failed; see the error code reference.
121252
+ * This media format is unsupported; provide a supported format.
119110
121253
  */
119111
121254
  415: MediaMediaError;
119112
121255
  /**
@@ -119114,11 +121257,11 @@ export type MediaCreateVoiceErrors = {
119114
121257
  */
119115
121258
  422: MediaMediaError;
119116
121259
  /**
119117
- * Request failed; see the error code reference.
121260
+ * A rate limit was reached; wait before retrying.
119118
121261
  */
119119
121262
  429: MediaMediaError;
119120
121263
  /**
119121
- * Request failed; see the error code reference.
121264
+ * The requested operation is unsupported; choose a supported method.
119122
121265
  */
119123
121266
  501: MediaMediaError;
119124
121267
  /**
@@ -119126,58 +121269,45 @@ export type MediaCreateVoiceErrors = {
119126
121269
  */
119127
121270
  502: MediaMediaError;
119128
121271
  /**
119129
- * Request failed; see the error code reference.
121272
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
119130
121273
  */
119131
121274
  503: MediaMediaError;
119132
121275
  };
119133
- export type MediaCreateVoiceError = MediaCreateVoiceErrors[keyof MediaCreateVoiceErrors];
119134
- export type MediaCreateVoiceResponses = {
121276
+ export type MediaUpdateWorkError = MediaUpdateWorkErrors[keyof MediaUpdateWorkErrors];
121277
+ export type MediaUpdateWorkResponses = {
119135
121278
  /**
119136
121279
  * Successful response.
119137
121280
  */
119138
- 202: MediaJob;
121281
+ 200: MediaWork;
119139
121282
  };
119140
- export type MediaCreateVoiceResponse = MediaCreateVoiceResponses[keyof MediaCreateVoiceResponses];
119141
- export type MediaDesignVoiceData = {
119142
- /**
119143
- * One voice-design run: what the voice should sound like and the line the previews speak.
119144
- */
119145
- body: {
119146
- /**
119147
- * Text description of the voice to design, 1 to 500 characters. The model makes every preview from it; a description that fails review answers CONTENT_REJECTED.
119148
- */
119149
- description: string;
119150
- /**
119151
- * Line each preview speaks, 15 to 200 characters: long enough to hear the voice, short enough for one model call.
119152
- */
119153
- preview_text: string;
121283
+ export type MediaUpdateWorkResponse = MediaUpdateWorkResponses[keyof MediaUpdateWorkResponses];
121284
+ export type MediaListAssetWorksData = {
121285
+ body?: never;
121286
+ path: {
119154
121287
  /**
119155
- * Language the previews speak: zh or en only.
121288
+ * Library ID returned by creation.
119156
121289
  */
119157
- language: 'zh' | 'en';
121290
+ library_id: string;
119158
121291
  /**
119159
- * How many preview recordings to design, 1 to 3; defaults to 3. Each one is stored as an audio asset.
121292
+ * 32-character asset ID.
119160
121293
  */
119161
- count?: number;
121294
+ asset_id: string;
119162
121295
  };
119163
- headers?: {
121296
+ query?: {
119164
121297
  /**
119165
- * Stable key for retrying the same request without creating or charging for another job; reusing it with different request content is rejected. Send it here or as idempotency_key in the body, never both with different values.
121298
+ * Maximum entries in this page, from 1 through 100; defaults to 100.
119166
121299
  */
119167
- 'Idempotency-Key'?: string;
119168
- };
119169
- path: {
121300
+ limit?: number;
119170
121301
  /**
119171
- * Library ID returned by creation.
121302
+ * Cursor from the previous next_cursor.
119172
121303
  */
119173
- library_id: string;
121304
+ cursor?: string;
119174
121305
  };
119175
- query?: never;
119176
- url: '/media/v1/libraries/{library_id}/voices/designs';
121306
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/works';
119177
121307
  };
119178
- export type MediaDesignVoiceErrors = {
121308
+ export type MediaListAssetWorksErrors = {
119179
121309
  /**
119180
- * Request failed; see the error code reference.
121310
+ * A selector, cursor, limit or other parameter is invalid; correct the reported field before retrying.
119181
121311
  */
119182
121312
  400: MediaMediaError;
119183
121313
  /**
@@ -119185,11 +121315,11 @@ export type MediaDesignVoiceErrors = {
119185
121315
  */
119186
121316
  402: MediaMediaError;
119187
121317
  /**
119188
- * Request failed; see the error code reference.
121318
+ * This credential has read-only access to the library; use a write-capable binding for mutations.
119189
121319
  */
119190
121320
  403: MediaMediaError;
119191
121321
  /**
119192
- * Request failed; see the error code reference.
121322
+ * The library or asset is missing, deleted or belongs to another tenant; verify its identifier and owner.
119193
121323
  */
119194
121324
  404: MediaMediaError;
119195
121325
  /**
@@ -119197,11 +121327,11 @@ export type MediaDesignVoiceErrors = {
119197
121327
  */
119198
121328
  409: MediaMediaError;
119199
121329
  /**
119200
- * Request failed; see the error code reference.
121330
+ * The file exceeds an input limit; provide a smaller source file.
119201
121331
  */
119202
121332
  413: MediaMediaError;
119203
121333
  /**
119204
- * Request failed; see the error code reference.
121334
+ * This media format is unsupported; provide a supported format.
119205
121335
  */
119206
121336
  415: MediaMediaError;
119207
121337
  /**
@@ -119209,11 +121339,11 @@ export type MediaDesignVoiceErrors = {
119209
121339
  */
119210
121340
  422: MediaMediaError;
119211
121341
  /**
119212
- * Request failed; see the error code reference.
121342
+ * A rate limit was reached; wait before retrying.
119213
121343
  */
119214
121344
  429: MediaMediaError;
119215
121345
  /**
119216
- * Request failed; see the error code reference.
121346
+ * The requested operation is unsupported; choose a supported method.
119217
121347
  */
119218
121348
  501: MediaMediaError;
119219
121349
  /**
@@ -119221,18 +121351,18 @@ export type MediaDesignVoiceErrors = {
119221
121351
  */
119222
121352
  502: MediaMediaError;
119223
121353
  /**
119224
- * Request failed; see the error code reference.
121354
+ * Historical projections are still being initialized, or library storage is temporarily unavailable; retry shortly and check failureSummary counts_complete.
119225
121355
  */
119226
121356
  503: MediaMediaError;
119227
121357
  };
119228
- export type MediaDesignVoiceError = MediaDesignVoiceErrors[keyof MediaDesignVoiceErrors];
119229
- export type MediaDesignVoiceResponses = {
121358
+ export type MediaListAssetWorksError = MediaListAssetWorksErrors[keyof MediaListAssetWorksErrors];
121359
+ export type MediaListAssetWorksResponses = {
119230
121360
  /**
119231
121361
  * Successful response.
119232
121362
  */
119233
- 202: MediaJob;
121363
+ 200: MediaWorkPage;
119234
121364
  };
119235
- export type MediaDesignVoiceResponse = MediaDesignVoiceResponses[keyof MediaDesignVoiceResponses];
121365
+ export type MediaListAssetWorksResponse = MediaListAssetWorksResponses[keyof MediaListAssetWorksResponses];
119236
121366
  export type OntologyListTypesData = {
119237
121367
  body?: never;
119238
121368
  path?: never;
@@ -121192,7 +123322,7 @@ export type GetSandboxV1SandboxesResponses = {
121192
123322
  };
121193
123323
  export type GetSandboxV1SandboxesResponse = GetSandboxV1SandboxesResponses[keyof GetSandboxV1SandboxesResponses];
121194
123324
  export type PostSandboxV1SandboxesData = {
121195
- body: SandboxNewSandboxV2;
123325
+ body: SandboxNewSandboxV2Writable;
121196
123326
  path?: never;
121197
123327
  query?: never;
121198
123328
  url: '/sandbox/v1/sandboxes';