@deepraxis/sdk 0.2.0-dev.c2bf6fc → 0.2.0-dev.c9360ec
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/METHODS.md +28 -1
- package/dist/generated/index.d.ts +2 -2
- package/dist/generated/index.js +1 -1
- package/dist/generated/sdk.gen.d.ts +81 -9
- package/dist/generated/sdk.gen.js +216 -8
- package/dist/generated/types.gen.d.ts +1863 -209
- package/dist/helpers/browser-actions.d.ts +2 -0
- package/dist/helpers/browser-actions.js +2 -0
- package/dist/helpers/browser-connect.d.ts +10 -1
- package/dist/helpers/browser-connect.js +29 -6
- package/dist/helpers/browser-decisions.d.ts +2 -0
- package/dist/helpers/browser-decisions.js +7 -0
- package/dist/helpers/browser-documentation.d.ts +1 -1
- package/dist/helpers/browser-documentation.js +1 -0
- package/dist/operations.generated.js +466 -16
- package/dist/resources.generated.d.ts +66 -0
- package/dist/resources.generated.js +18 -0
- package/package.json +1 -1
|
@@ -5380,7 +5380,7 @@ export const operations = [
|
|
|
5380
5380
|
"trigger"
|
|
5381
5381
|
],
|
|
5382
5382
|
"required": false,
|
|
5383
|
-
"description": "Root initiator type: user, api_key, agent or
|
|
5383
|
+
"description": "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."
|
|
5384
5384
|
},
|
|
5385
5385
|
{
|
|
5386
5386
|
"name": "initiator",
|
|
@@ -7831,7 +7831,7 @@ export const operations = [
|
|
|
7831
7831
|
"resource": "browser.connect",
|
|
7832
7832
|
"method": "retrieve",
|
|
7833
7833
|
"summary": "连接云端浏览器",
|
|
7834
|
-
"description": "CDP WebSocket:不填 session 或 name 时新开;session 连接已有会话;name 有就连接、没有就新开。session 与 name 不可同时提供。新建参数在连接已有会话时忽略。使用 Authorization: Bearer API_KEY,或直接使用创建会话返回的带 signingKey 的 connectUrl。连上后发送 CDP 命令 Praxis.getSession,获取 sessionId、liveViewUrl、consoleUrl
|
|
7834
|
+
"description": "CDP WebSocket:不填 session 或 name 时新开;session 连接已有会话;name 有就连接、没有就新开。session 与 name 不可同时提供。新建参数在连接已有会话时忽略。使用 Authorization: Bearer API_KEY,或直接使用创建会话返回的带 signingKey 的 connectUrl。连上后发送 CDP 命令 Praxis.getSession,获取 sessionId、liveViewUrl、consoleUrl(两者都是该会话在 Console 的会话页)。这是完整 CDP 连接:真手指或指针事件(Emulation.setTouchEmulationEnabled 加 Input.dispatchTouchEvent、拖拽用的 Input.dispatchMouseEvent)只能从这里发,页面动作接口只做按 ref 的语义动作。要挂指定登录态,可用 context 参数,或直接连接 sessions.create 返回的 connectUrl。",
|
|
7835
7835
|
"http": "GET",
|
|
7836
7836
|
"path": "/browser/v1/connect",
|
|
7837
7837
|
"streaming": "no",
|
|
@@ -7956,6 +7956,12 @@ export const operations = [
|
|
|
7956
7956
|
"type": "object",
|
|
7957
7957
|
"required": false,
|
|
7958
7958
|
"description": "自定义字符串标签;最多 32 项,键最多 128 个 UTF-8 字节,值最多 1024 个 UTF-8 字节。"
|
|
7959
|
+
},
|
|
7960
|
+
{
|
|
7961
|
+
"name": "proxy",
|
|
7962
|
+
"type": "object",
|
|
7963
|
+
"required": false,
|
|
7964
|
+
"description": "给登录态绑定一个固定的外部代理(如住宅 IP),使用这个登录态的会话没有写 proxies 时都经它出网,让同一账号始终从同一个出口地址出去。只存保管库引用(password_secret),不存密码;会话自己写了 proxies 时以会话的为准。需要组织已开通容器后端,否则返回 501 PROVIDER_UNSUPPORTED。"
|
|
7959
7965
|
}
|
|
7960
7966
|
]
|
|
7961
7967
|
}
|
|
@@ -8027,6 +8033,12 @@ export const operations = [
|
|
|
8027
8033
|
"type": "object",
|
|
8028
8034
|
"required": false,
|
|
8029
8035
|
"description": "自定义字符串标签;最多 32 项,键最多 128 个 UTF-8 字节,值最多 1024 个 UTF-8 字节。 更新时整体替换;空对象清除标签,省略则保留。"
|
|
8036
|
+
},
|
|
8037
|
+
{
|
|
8038
|
+
"name": "proxy",
|
|
8039
|
+
"type": "object",
|
|
8040
|
+
"required": false,
|
|
8041
|
+
"description": "给登录态绑定一个固定的外部代理(如住宅 IP),使用这个登录态的会话没有写 proxies 时都经它出网,让同一账号始终从同一个出口地址出去。只存保管库引用(password_secret),不存密码;会话自己写了 proxies 时以会话的为准。需要组织已开通容器后端,否则返回 501 PROVIDER_UNSUPPORTED。 更新时传 null 解除绑定,省略则保留原绑定。"
|
|
8030
8042
|
}
|
|
8031
8043
|
]
|
|
8032
8044
|
}
|
|
@@ -8035,7 +8047,7 @@ export const operations = [
|
|
|
8035
8047
|
"resource": "browser.live",
|
|
8036
8048
|
"method": "retrieve",
|
|
8037
8049
|
"summary": "打开实时浏览器画面",
|
|
8038
|
-
"description": "
|
|
8050
|
+
"description": "旧版 debug 返回的带 t 凭证的地址,凭证在有效期内时跳转到该会话在 Console 的会话页。debug 现在直接返回 Console 会话页地址,新代码不要拼这个地址。",
|
|
8039
8051
|
"http": "GET",
|
|
8040
8052
|
"path": "/browser/v1/live/{sessionId}/{pageId}",
|
|
8041
8053
|
"streaming": "no",
|
|
@@ -8133,7 +8145,7 @@ export const operations = [
|
|
|
8133
8145
|
"resource": "browser.sessions",
|
|
8134
8146
|
"method": "create",
|
|
8135
8147
|
"summary": "创建浏览器会话",
|
|
8136
|
-
"description": "创建云端 Chrome,返回自带凭证的 connectUrl;带 name 时按名字幂等:本账户已有同名且 RUNNING(未在释放中)、挂载的登录态与本次相同(都没挂也算相同)的会话,就直接返回这个会话(HTTP 200,reused=true,不新开、不计费),同名但登录态不同返回 409 SESSION_NAME_IN_USE(消息写明已有会话的 id),同名会话已在释放或已结束则新开;不带 name 时每次都新开(HTTP 201,reused=false)。同一件事请固定一个会话名并复用,不要每步新开再关闭:频繁新开会话对网站来说像同一账号不断换新设备登录,容易触发风控。persist 写入租约仍只属于这一个会话。它是一条完整 CDP 连接,真指针事件(触摸、拖拽、按坐标点击)从那里发送,页面动作接口只做按 ref 的语义动作。API 会话默认断开后结束;最长 6
|
|
8148
|
+
"description": "创建云端 Chrome,返回自带凭证的 connectUrl;带 name 时按名字幂等:本账户已有同名且 RUNNING(未在释放中)、挂载的登录态与本次相同(都没挂也算相同)的会话,就直接返回这个会话(HTTP 200,reused=true,不新开、不计费),同名但登录态不同返回 409 SESSION_NAME_IN_USE(消息写明已有会话的 id),同名会话已在释放或已结束则新开;不带 name 时每次都新开(HTTP 201,reused=false)。同一件事请固定一个会话名并复用,不要每步新开再关闭:频繁新开会话对网站来说像同一账号不断换新设备登录,容易触发风控。persist 写入租约仍只属于这一个会话。它是一条完整 CDP 连接,真指针事件(触摸、拖拽、按坐标点击)从那里发送,页面动作接口只做按 ref 的语义动作。API 会话默认断开后结束;最长 6 小时。请求体里不认识的字段返回 400 INVALID_PARAMS 并写明字段名,不会被静默忽略;登录态写在 browserSettings.context({ id, persist }),写在顶层会被拒绝。运行中服务每 60 秒做一次健康检查(Browser.getVersion,超时 10 秒),连续 2 次失败即以 closeReason=watchdog 结束会话,keepAlive=true 也不豁免;该事件记录判据读数。",
|
|
8137
8149
|
"http": "POST",
|
|
8138
8150
|
"path": "/browser/v1/sessions",
|
|
8139
8151
|
"streaming": "no",
|
|
@@ -8181,13 +8193,13 @@ export const operations = [
|
|
|
8181
8193
|
"name": "proxies",
|
|
8182
8194
|
"type": "object",
|
|
8183
8195
|
"required": false,
|
|
8184
|
-
"description": "
|
|
8196
|
+
"description": "让会话经一个固定的外部 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),不必每次会话重复传。"
|
|
8185
8197
|
},
|
|
8186
8198
|
{
|
|
8187
8199
|
"name": "source",
|
|
8188
8200
|
"type": "object",
|
|
8189
8201
|
"required": false,
|
|
8190
|
-
"description": "
|
|
8202
|
+
"description": "选择浏览器后端,只有 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。"
|
|
8191
8203
|
},
|
|
8192
8204
|
{
|
|
8193
8205
|
"name": "region",
|
|
@@ -18833,7 +18845,7 @@ export const operations = [
|
|
|
18833
18845
|
"resource": "devops.units",
|
|
18834
18846
|
"method": "push",
|
|
18835
18847
|
"summary": "Push a unit's branch",
|
|
18836
|
-
"description": "Publish the unit's local commits to the remote for the change: the machine itself holds no git credential and cannot reach the remote, so this verb is the way work done on a unit lands. ref says what to push — branch for the change's own branch, wip for this unit's own refs/praxis/wip/<change>, or a full ref name; anything else (the default branch, another change's branch, a tag, another unit's wip ref) is refused with 400 PUSH_REF_FORBIDDEN and nothing is pushed. expectedHead is the commit you believe the remote branch is at now; DevOps checks it before signing anything, and a remote that has moved since answers 409 HEAD_MOVED with nothing pushed,
|
|
18848
|
+
"description": "Publish the unit's local commits to the remote for the change: the machine itself holds no git credential and cannot reach the remote, so this verb is the way work done on a unit lands. ref says what to push — branch for the change's own branch, wip for this unit's own refs/praxis/wip/<change>, or a full ref name; anything else (the default branch, another change's branch, a tag, another unit's wip ref) is refused with 400 PUSH_REF_FORBIDDEN and nothing is pushed. expectedHead is the commit you believe the remote branch is at now; DevOps checks it before signing anything, and a remote that has moved since answers 409 HEAD_MOVED with nothing pushed, naming the head it is at now in the message and in details.remoteHead. Read the starting value from the unit's git.remoteHead (fetch first when someone else may have pushed). For branch the call also takes a lease on that head, so the push cannot silently overwrite work that landed in between; wip is this change's own ref and is force-pushed. On success the answer is pushedSha, the commit that landed. Commit inside the machine first, through the sandbox instance API — this verb pushes commits, it does not create them. The unit must be available with a machine and a checkout, or the call answers 409 UNIT_INVALID_STATE; a push that git refuses inside the machine answers with the cause in the error message and in details.detail (the last 4000 characters of git's output, credentials redacted) and details.exitCode (git's exit code): 409 PUSH_REJECTED_BY_HOOK when a pre-push hook such as lefthook rejected it, so read the hook output, fix the content and push again, 409 PUSH_REJECTED_NON_FAST_FORWARD when the remote moved ahead, so fetch and reconcile, 409 HEAD_MOVED when the lease on expectedHead no longer holds, and 500 PUSH_FAILED for anything else. Do not retry the same push unchanged.",
|
|
18837
18849
|
"http": "POST",
|
|
18838
18850
|
"path": "/devops/v1/units/{id}:push",
|
|
18839
18851
|
"streaming": "no",
|
|
@@ -21168,6 +21180,42 @@ export const operations = [
|
|
|
21168
21180
|
],
|
|
21169
21181
|
"query": []
|
|
21170
21182
|
},
|
|
21183
|
+
{
|
|
21184
|
+
"resource": "media.libraries.assets.works",
|
|
21185
|
+
"method": "list",
|
|
21186
|
+
"summary": "List works using an asset",
|
|
21187
|
+
"description": "List the works whose body names one asset, as work summaries, most recently changed first. Check it before deleting an asset: the delete is never blocked, and those works would then show the asset as missing.",
|
|
21188
|
+
"http": "GET",
|
|
21189
|
+
"path": "/media/v1/libraries/{library_id}/assets/{asset_id}/works",
|
|
21190
|
+
"streaming": "no",
|
|
21191
|
+
"pagination": true,
|
|
21192
|
+
"pathParams": [
|
|
21193
|
+
{
|
|
21194
|
+
"name": "library_id",
|
|
21195
|
+
"sdkName": "library_id",
|
|
21196
|
+
"description": "Library ID returned by creation."
|
|
21197
|
+
},
|
|
21198
|
+
{
|
|
21199
|
+
"name": "asset_id",
|
|
21200
|
+
"sdkName": "asset_id",
|
|
21201
|
+
"description": "32-character asset ID."
|
|
21202
|
+
}
|
|
21203
|
+
],
|
|
21204
|
+
"query": [
|
|
21205
|
+
{
|
|
21206
|
+
"name": "limit",
|
|
21207
|
+
"type": "integer",
|
|
21208
|
+
"required": false,
|
|
21209
|
+
"description": "Maximum entries in this page, from 1 through 100; defaults to 100."
|
|
21210
|
+
},
|
|
21211
|
+
{
|
|
21212
|
+
"name": "cursor",
|
|
21213
|
+
"type": "string",
|
|
21214
|
+
"required": false,
|
|
21215
|
+
"description": "Cursor from the previous next_cursor."
|
|
21216
|
+
}
|
|
21217
|
+
]
|
|
21218
|
+
},
|
|
21171
21219
|
{
|
|
21172
21220
|
"resource": "media.libraries.assets",
|
|
21173
21221
|
"method": "batch",
|
|
@@ -22437,6 +22485,215 @@ export const operations = [
|
|
|
22437
22485
|
]
|
|
22438
22486
|
}
|
|
22439
22487
|
},
|
|
22488
|
+
{
|
|
22489
|
+
"resource": "media.libraries.works",
|
|
22490
|
+
"method": "list",
|
|
22491
|
+
"summary": "List works",
|
|
22492
|
+
"description": "List the works of a library as summaries, most recently changed first: id, kind, title, series, cover_url, item_count, missing_count and updated_at. Filter with kind and series (for example all platform versions of one story), match the title with q, and continue with next_cursor.",
|
|
22493
|
+
"http": "GET",
|
|
22494
|
+
"path": "/media/v1/libraries/{library_id}/works",
|
|
22495
|
+
"streaming": "no",
|
|
22496
|
+
"pagination": true,
|
|
22497
|
+
"pathParams": [
|
|
22498
|
+
{
|
|
22499
|
+
"name": "library_id",
|
|
22500
|
+
"sdkName": "library_id",
|
|
22501
|
+
"description": "Library ID returned by creation."
|
|
22502
|
+
}
|
|
22503
|
+
],
|
|
22504
|
+
"query": [
|
|
22505
|
+
{
|
|
22506
|
+
"name": "kind",
|
|
22507
|
+
"type": "string",
|
|
22508
|
+
"enum": [
|
|
22509
|
+
"gallery",
|
|
22510
|
+
"article",
|
|
22511
|
+
"product_listing",
|
|
22512
|
+
"blocks"
|
|
22513
|
+
],
|
|
22514
|
+
"required": false,
|
|
22515
|
+
"description": "Only works of this kind: gallery, article, product_listing or blocks."
|
|
22516
|
+
},
|
|
22517
|
+
{
|
|
22518
|
+
"name": "series",
|
|
22519
|
+
"type": "string",
|
|
22520
|
+
"required": false,
|
|
22521
|
+
"description": "Only works of this series."
|
|
22522
|
+
},
|
|
22523
|
+
{
|
|
22524
|
+
"name": "q",
|
|
22525
|
+
"type": "string",
|
|
22526
|
+
"required": false,
|
|
22527
|
+
"description": "Only works whose title contains this text, at most 100 characters."
|
|
22528
|
+
},
|
|
22529
|
+
{
|
|
22530
|
+
"name": "limit",
|
|
22531
|
+
"type": "integer",
|
|
22532
|
+
"required": false,
|
|
22533
|
+
"description": "Maximum entries in this page, from 1 through 100; defaults to 100."
|
|
22534
|
+
},
|
|
22535
|
+
{
|
|
22536
|
+
"name": "cursor",
|
|
22537
|
+
"type": "string",
|
|
22538
|
+
"required": false,
|
|
22539
|
+
"description": "Cursor from the previous next_cursor."
|
|
22540
|
+
}
|
|
22541
|
+
]
|
|
22542
|
+
},
|
|
22543
|
+
{
|
|
22544
|
+
"resource": "media.libraries.works",
|
|
22545
|
+
"method": "create",
|
|
22546
|
+
"summary": "Create work",
|
|
22547
|
+
"description": "Create a work in a library: a gallery (图文), an article (长文), a product listing (商品图组) or a general work (blocks, 通用作品, Editor.js saved data whose image blocks name library assets in data.asset_id) that orders references to assets of this same library and adds a title and text. Upload or generate the pictures first, then send kind and body. In an article an inline image is written  where it should appear. Every asset the body names must be a live image or sticker of this library (a gallery item may also be a video), or the request is refused naming every bad reference and nothing is saved. Price, stock and other unknown fields are refused. Several platform versions of one story are several works with the same series. A work copies no file and changes no asset; creating one is free. Answers 201 with the work. Example: POST /media/v1/libraries/default/works with {\"kind\":\"gallery\",\"series\":\"ai-diary-01\",\"body\":{\"title\":\"AI 创业第一天就踩坑\",\"items\":[{\"asset_id\":\"<asset id>\"}]}}.",
|
|
22548
|
+
"http": "POST",
|
|
22549
|
+
"path": "/media/v1/libraries/{library_id}/works",
|
|
22550
|
+
"streaming": "no",
|
|
22551
|
+
"pagination": false,
|
|
22552
|
+
"pathParams": [
|
|
22553
|
+
{
|
|
22554
|
+
"name": "library_id",
|
|
22555
|
+
"sdkName": "library_id",
|
|
22556
|
+
"description": "Library ID returned by creation."
|
|
22557
|
+
}
|
|
22558
|
+
],
|
|
22559
|
+
"query": [],
|
|
22560
|
+
"body": {
|
|
22561
|
+
"required": true,
|
|
22562
|
+
"fields": [
|
|
22563
|
+
{
|
|
22564
|
+
"name": "kind",
|
|
22565
|
+
"type": "string",
|
|
22566
|
+
"enum": [
|
|
22567
|
+
"gallery",
|
|
22568
|
+
"article",
|
|
22569
|
+
"product_listing",
|
|
22570
|
+
"blocks"
|
|
22571
|
+
],
|
|
22572
|
+
"required": true,
|
|
22573
|
+
"description": "Kind of work: gallery (图文), article (长文) or product_listing (商品图组). short_video is reserved."
|
|
22574
|
+
},
|
|
22575
|
+
{
|
|
22576
|
+
"name": "body",
|
|
22577
|
+
"type": "object",
|
|
22578
|
+
"required": true
|
|
22579
|
+
},
|
|
22580
|
+
{
|
|
22581
|
+
"name": "series",
|
|
22582
|
+
"type": "string",
|
|
22583
|
+
"required": false,
|
|
22584
|
+
"description": "Groups the platform versions of one story: 1 to 64 characters of a-z, 0-9, _ and -."
|
|
22585
|
+
},
|
|
22586
|
+
{
|
|
22587
|
+
"name": "custom",
|
|
22588
|
+
"type": "object",
|
|
22589
|
+
"required": false
|
|
22590
|
+
}
|
|
22591
|
+
]
|
|
22592
|
+
}
|
|
22593
|
+
},
|
|
22594
|
+
{
|
|
22595
|
+
"resource": "media.libraries.works",
|
|
22596
|
+
"method": "delete",
|
|
22597
|
+
"summary": "Delete work",
|
|
22598
|
+
"description": "Delete a work. Only the work goes: every asset it named stays in the library unchanged.",
|
|
22599
|
+
"http": "DELETE",
|
|
22600
|
+
"path": "/media/v1/libraries/{library_id}/works/{work_id}",
|
|
22601
|
+
"streaming": "no",
|
|
22602
|
+
"pagination": false,
|
|
22603
|
+
"pathParams": [
|
|
22604
|
+
{
|
|
22605
|
+
"name": "library_id",
|
|
22606
|
+
"sdkName": "library_id",
|
|
22607
|
+
"description": "Library ID returned by creation."
|
|
22608
|
+
},
|
|
22609
|
+
{
|
|
22610
|
+
"name": "work_id",
|
|
22611
|
+
"sdkName": "work_id",
|
|
22612
|
+
"description": "Work id (wrk_…) returned by creation or listing."
|
|
22613
|
+
}
|
|
22614
|
+
],
|
|
22615
|
+
"query": []
|
|
22616
|
+
},
|
|
22617
|
+
{
|
|
22618
|
+
"resource": "media.libraries.works",
|
|
22619
|
+
"method": "retrieve",
|
|
22620
|
+
"summary": "Get work",
|
|
22621
|
+
"description": "Read one work with its body, custom fields, revision and missing (asset ids deleted since; the body keeps them in place). Add expand=assets to receive every referenced asset’s type, short-lived url, thumbnail_url and size in the same answer, which is what a publish script needs to send the work out. Use work_id from creation or listing.",
|
|
22622
|
+
"http": "GET",
|
|
22623
|
+
"path": "/media/v1/libraries/{library_id}/works/{work_id}",
|
|
22624
|
+
"streaming": "no",
|
|
22625
|
+
"pagination": false,
|
|
22626
|
+
"pathParams": [
|
|
22627
|
+
{
|
|
22628
|
+
"name": "library_id",
|
|
22629
|
+
"sdkName": "library_id",
|
|
22630
|
+
"description": "Library ID returned by creation."
|
|
22631
|
+
},
|
|
22632
|
+
{
|
|
22633
|
+
"name": "work_id",
|
|
22634
|
+
"sdkName": "work_id",
|
|
22635
|
+
"description": "Work id (wrk_…) returned by creation or listing."
|
|
22636
|
+
}
|
|
22637
|
+
],
|
|
22638
|
+
"query": [
|
|
22639
|
+
{
|
|
22640
|
+
"name": "expand",
|
|
22641
|
+
"type": "string",
|
|
22642
|
+
"required": false,
|
|
22643
|
+
"description": "assets returns every referenced asset with its URLs and size."
|
|
22644
|
+
}
|
|
22645
|
+
]
|
|
22646
|
+
},
|
|
22647
|
+
{
|
|
22648
|
+
"resource": "media.libraries.works",
|
|
22649
|
+
"method": "update",
|
|
22650
|
+
"summary": "Update work",
|
|
22651
|
+
"description": "Change a work. body replaces the whole body and is checked like a new one; series replaces the series and null clears it; custom is a JSON Merge Patch (RFC 7396), so a script writing back its published link and numbers sends only its own keys and never erases keys another script wrote, and null removes a key. Send if_revision with the revision you read to apply the change only if nobody changed the work since; otherwise the answer is 409 REVISION_CONFLICT. Example: PATCH /media/v1/libraries/default/works/<work id> with {\"custom\":{\"published_url\":\"https://…\",\"stats\":{\"likes\":120}}}.",
|
|
22652
|
+
"http": "PATCH",
|
|
22653
|
+
"path": "/media/v1/libraries/{library_id}/works/{work_id}",
|
|
22654
|
+
"streaming": "no",
|
|
22655
|
+
"pagination": false,
|
|
22656
|
+
"pathParams": [
|
|
22657
|
+
{
|
|
22658
|
+
"name": "library_id",
|
|
22659
|
+
"sdkName": "library_id",
|
|
22660
|
+
"description": "Library ID returned by creation."
|
|
22661
|
+
},
|
|
22662
|
+
{
|
|
22663
|
+
"name": "work_id",
|
|
22664
|
+
"sdkName": "work_id",
|
|
22665
|
+
"description": "Work id (wrk_…) returned by creation or listing."
|
|
22666
|
+
}
|
|
22667
|
+
],
|
|
22668
|
+
"query": [],
|
|
22669
|
+
"body": {
|
|
22670
|
+
"required": true,
|
|
22671
|
+
"fields": [
|
|
22672
|
+
{
|
|
22673
|
+
"name": "body",
|
|
22674
|
+
"type": "object",
|
|
22675
|
+
"required": false
|
|
22676
|
+
},
|
|
22677
|
+
{
|
|
22678
|
+
"name": "series",
|
|
22679
|
+
"type": "string",
|
|
22680
|
+
"required": false,
|
|
22681
|
+
"description": "A new series, or null to clear it."
|
|
22682
|
+
},
|
|
22683
|
+
{
|
|
22684
|
+
"name": "custom",
|
|
22685
|
+
"type": "object",
|
|
22686
|
+
"required": false
|
|
22687
|
+
},
|
|
22688
|
+
{
|
|
22689
|
+
"name": "if_revision",
|
|
22690
|
+
"type": "number",
|
|
22691
|
+
"required": false,
|
|
22692
|
+
"description": "Apply the change only if the work is still at this revision; otherwise the answer is 409 REVISION_CONFLICT with the current revision."
|
|
22693
|
+
}
|
|
22694
|
+
]
|
|
22695
|
+
}
|
|
22696
|
+
},
|
|
22440
22697
|
{
|
|
22441
22698
|
"resource": "media.pipelines",
|
|
22442
22699
|
"method": "list",
|
|
@@ -26072,7 +26329,7 @@ export const operations = [
|
|
|
26072
26329
|
"resource": "organization.costs",
|
|
26073
26330
|
"method": "list",
|
|
26074
26331
|
"summary": "List Organization Costs",
|
|
26075
|
-
"description": "Billed cost per time bucket per group (AWS GetCostAndUsage shape). Buckets are whole
|
|
26332
|
+
"description": "Billed cost per time bucket per group (AWS GetCostAndUsage shape). Buckets are whole hour or day periods in time_zone (UTC by default); a window is answered over the aligned envelope covering it. Amounts are exact decimal strings in the currency the organization was charged in (BillingCurrency, CNY or USD); a group charged in two currencies is two results. estimated is always false: charges are final when they are recorded. Windows span at most 93 days; longer ranges belong to the charges export.\n",
|
|
26076
26333
|
"http": "GET",
|
|
26077
26334
|
"path": "/organization/v1/costs",
|
|
26078
26335
|
"streaming": "no",
|
|
@@ -26105,7 +26362,7 @@ export const operations = [
|
|
|
26105
26362
|
"name": "time_zone",
|
|
26106
26363
|
"type": "string",
|
|
26107
26364
|
"required": false,
|
|
26108
|
-
"description": "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.
|
|
26365
|
+
"description": "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.\n"
|
|
26109
26366
|
},
|
|
26110
26367
|
{
|
|
26111
26368
|
"name": "group_by",
|
|
@@ -26471,29 +26728,46 @@ export const operations = [
|
|
|
26471
26728
|
{
|
|
26472
26729
|
"resource": "organization.notifications.letters",
|
|
26473
26730
|
"method": "list",
|
|
26474
|
-
"summary": "List the letters addressed to you",
|
|
26475
|
-
"description": "The letters this person received in this organization, newest first, as the notification center lists them (ADR-193 §5, #4107): the sender, the summary and the whole body are the copy this reader receives — every human:/agent: address is rendered as the directory's display name, and one the directory cannot name reads 「未知成员」, never an address or an internal id. Also the kind, when it arrived, whether it is read, and one line saying why it reached this person. The address is the credential's own and is never a request field. Details stay whole in body; open one by its id. Pass next_cursor unchanged as cursor; null ends the list. Read-only; no usage charge.",
|
|
26731
|
+
"summary": "List the letters addressed to you, or the ones you sent",
|
|
26732
|
+
"description": "The letters this person received (or, with direction=sent, wrote) in this organization, newest first, as the notification center lists them (ADR-193 §5, #4107): the sender, the summary and the whole body are the copy this reader receives — every human:/agent: address is rendered as the directory's display name, and one the directory cannot name reads 「未知成员」, never an address or an internal id. Also the kind, when it arrived, whether it is read, and one line saying why it reached this person. The address is the credential's own and is never a request field. Details stay whole in body; open one by its id. Pass next_cursor unchanged as cursor; null ends the list. Read-only; no usage charge.",
|
|
26476
26733
|
"http": "GET",
|
|
26477
26734
|
"path": "/organization/v1/notifications/letters",
|
|
26478
26735
|
"streaming": "no",
|
|
26479
26736
|
"pagination": false,
|
|
26480
26737
|
"pathParams": [],
|
|
26481
26738
|
"query": [
|
|
26739
|
+
{
|
|
26740
|
+
"name": "direction",
|
|
26741
|
+
"type": "string",
|
|
26742
|
+
"enum": [
|
|
26743
|
+
"received",
|
|
26744
|
+
"sent"
|
|
26745
|
+
],
|
|
26746
|
+
"required": false,
|
|
26747
|
+
"description": "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."
|
|
26748
|
+
},
|
|
26482
26749
|
{
|
|
26483
26750
|
"name": "status",
|
|
26484
26751
|
"type": "string",
|
|
26485
26752
|
"enum": [
|
|
26486
26753
|
"unread",
|
|
26487
|
-
"read"
|
|
26754
|
+
"read",
|
|
26755
|
+
"scheduled"
|
|
26488
26756
|
],
|
|
26489
26757
|
"required": false,
|
|
26490
|
-
"description": "Only unread letters, or only
|
|
26758
|
+
"description": "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."
|
|
26759
|
+
},
|
|
26760
|
+
{
|
|
26761
|
+
"name": "thread",
|
|
26762
|
+
"type": "string",
|
|
26763
|
+
"required": false,
|
|
26764
|
+
"description": "Only letters of this conversation, for received and sent alike; omit for all."
|
|
26491
26765
|
},
|
|
26492
26766
|
{
|
|
26493
26767
|
"name": "archived",
|
|
26494
26768
|
"type": "boolean",
|
|
26495
26769
|
"required": false,
|
|
26496
|
-
"description": "false (the default) hides archived letters; true lists only the archived ones."
|
|
26770
|
+
"description": "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."
|
|
26497
26771
|
},
|
|
26498
26772
|
{
|
|
26499
26773
|
"name": "limit",
|
|
@@ -26509,6 +26783,64 @@ export const operations = [
|
|
|
26509
26783
|
}
|
|
26510
26784
|
]
|
|
26511
26785
|
},
|
|
26786
|
+
{
|
|
26787
|
+
"resource": "organization.notifications.letters",
|
|
26788
|
+
"method": "create",
|
|
26789
|
+
"summary": "Send a letter to a person or an agent",
|
|
26790
|
+
"description": "Write one letter to a member or an agent of this organization, for an automation script or an outside caller that needs to reach someone, or to leave itself an alarm: a letter to your own address is allowed and arrives at its deliver_at. The sender is the credential's own and is never a request field — a person writes as themselves, an agent as itself, and an automation run (a scheduled or service-started one included) as the platform's automation sender with the run recorded in the letter's source; a `sender` in the body is ignored. Any other credential (an organization API key, an application) has no address to write from and is refused with 403. The recipient must belong to this organization: a person or agent of another organization answers 404 without saying whether it exists. A letter to a person needs a summary of at most 60 characters — one sentence saying what the reader must do or know; a longer one is refused, never cut. An agent's letter may leave summary out and the first line of body stands in. Repeating the same letter (same recipient, kind, thread, body and time) returns the same id and writes it once. Usage charge: none.",
|
|
26791
|
+
"http": "POST",
|
|
26792
|
+
"path": "/organization/v1/notifications/letters",
|
|
26793
|
+
"streaming": "no",
|
|
26794
|
+
"pagination": false,
|
|
26795
|
+
"pathParams": [],
|
|
26796
|
+
"query": [],
|
|
26797
|
+
"body": {
|
|
26798
|
+
"required": true,
|
|
26799
|
+
"fields": [
|
|
26800
|
+
{
|
|
26801
|
+
"name": "to",
|
|
26802
|
+
"type": "string",
|
|
26803
|
+
"required": true,
|
|
26804
|
+
"description": "The recipient's address: human:<user id> or agent:<agent id>, a member or an agent of this organization."
|
|
26805
|
+
},
|
|
26806
|
+
{
|
|
26807
|
+
"name": "body",
|
|
26808
|
+
"type": "string",
|
|
26809
|
+
"required": true,
|
|
26810
|
+
"description": "The whole letter, 1 to 16000 characters."
|
|
26811
|
+
},
|
|
26812
|
+
{
|
|
26813
|
+
"name": "summary",
|
|
26814
|
+
"type": "string",
|
|
26815
|
+
"required": false,
|
|
26816
|
+
"description": "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."
|
|
26817
|
+
},
|
|
26818
|
+
{
|
|
26819
|
+
"name": "kind",
|
|
26820
|
+
"type": "string",
|
|
26821
|
+
"enum": [
|
|
26822
|
+
"notice",
|
|
26823
|
+
"mention",
|
|
26824
|
+
"decision"
|
|
26825
|
+
],
|
|
26826
|
+
"required": false,
|
|
26827
|
+
"description": "The letter's kind; it decides the channels. Defaults to mention."
|
|
26828
|
+
},
|
|
26829
|
+
{
|
|
26830
|
+
"name": "thread",
|
|
26831
|
+
"type": "string",
|
|
26832
|
+
"required": false,
|
|
26833
|
+
"description": "The conversation the letter belongs to, free text; omit for none."
|
|
26834
|
+
},
|
|
26835
|
+
{
|
|
26836
|
+
"name": "deliver_at",
|
|
26837
|
+
"type": "string",
|
|
26838
|
+
"required": false,
|
|
26839
|
+
"description": "When to deliver it, ISO 8601, at most 366 days ahead. A past time or no value means now."
|
|
26840
|
+
}
|
|
26841
|
+
]
|
|
26842
|
+
}
|
|
26843
|
+
},
|
|
26512
26844
|
{
|
|
26513
26845
|
"resource": "organization.notifications.letters",
|
|
26514
26846
|
"method": "retrieve",
|
|
@@ -26591,6 +26923,124 @@ export const operations = [
|
|
|
26591
26923
|
]
|
|
26592
26924
|
}
|
|
26593
26925
|
},
|
|
26926
|
+
{
|
|
26927
|
+
"resource": "organization.notifications.messages",
|
|
26928
|
+
"method": "list",
|
|
26929
|
+
"summary": "List your bell messages",
|
|
26930
|
+
"description": "The calling person's bell messages in this organization, newest first: the inbox tab by default, or the archive tab with archived=1. The person is always the credential's own; the request cannot name another member. Pass nextPageToken unchanged as page for the next page; it is absent on the last one. Read-only; no usage charge.",
|
|
26931
|
+
"http": "GET",
|
|
26932
|
+
"path": "/organization/v1/notifications/messages",
|
|
26933
|
+
"streaming": "no",
|
|
26934
|
+
"pagination": false,
|
|
26935
|
+
"pathParams": [],
|
|
26936
|
+
"query": [
|
|
26937
|
+
{
|
|
26938
|
+
"name": "archived",
|
|
26939
|
+
"type": "string",
|
|
26940
|
+
"enum": [
|
|
26941
|
+
"0",
|
|
26942
|
+
"1"
|
|
26943
|
+
],
|
|
26944
|
+
"required": false,
|
|
26945
|
+
"description": "0 (the default) lists the inbox tab, 1 lists archived messages."
|
|
26946
|
+
},
|
|
26947
|
+
{
|
|
26948
|
+
"name": "limit",
|
|
26949
|
+
"type": "integer",
|
|
26950
|
+
"required": false,
|
|
26951
|
+
"description": "Messages per page, 1 to 100; defaults to 20."
|
|
26952
|
+
},
|
|
26953
|
+
{
|
|
26954
|
+
"name": "page",
|
|
26955
|
+
"type": "string",
|
|
26956
|
+
"required": false,
|
|
26957
|
+
"description": "Opaque nextPageToken from the previous response; omit for the first page."
|
|
26958
|
+
}
|
|
26959
|
+
]
|
|
26960
|
+
},
|
|
26961
|
+
{
|
|
26962
|
+
"resource": "organization.notifications.messages",
|
|
26963
|
+
"method": "delete",
|
|
26964
|
+
"summary": "Delete one of your bell messages",
|
|
26965
|
+
"description": "Delete one of the calling person's own bell messages for good. A message that is not theirs — another person's, another organization's — answers 404 exactly as one that does not exist, and nothing is deleted. Deleting a message does not delete the letter or notice it announced. No usage charge.",
|
|
26966
|
+
"http": "DELETE",
|
|
26967
|
+
"path": "/organization/v1/notifications/messages/{name}",
|
|
26968
|
+
"streaming": "no",
|
|
26969
|
+
"pagination": false,
|
|
26970
|
+
"pathParams": [
|
|
26971
|
+
{
|
|
26972
|
+
"name": "name",
|
|
26973
|
+
"sdkName": "name",
|
|
26974
|
+
"description": "The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded."
|
|
26975
|
+
}
|
|
26976
|
+
],
|
|
26977
|
+
"query": []
|
|
26978
|
+
},
|
|
26979
|
+
{
|
|
26980
|
+
"resource": "organization.notifications.messages",
|
|
26981
|
+
"method": "retrieve",
|
|
26982
|
+
"summary": "Open one of your bell messages",
|
|
26983
|
+
"description": "One bell message of the calling person by its name. A message that is not theirs — another person's, another organization's — answers 404 exactly as one that does not exist, without saying which. Read-only; no usage charge.",
|
|
26984
|
+
"http": "GET",
|
|
26985
|
+
"path": "/organization/v1/notifications/messages/{name}",
|
|
26986
|
+
"streaming": "no",
|
|
26987
|
+
"pagination": false,
|
|
26988
|
+
"pathParams": [
|
|
26989
|
+
{
|
|
26990
|
+
"name": "name",
|
|
26991
|
+
"sdkName": "name",
|
|
26992
|
+
"description": "The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded."
|
|
26993
|
+
}
|
|
26994
|
+
],
|
|
26995
|
+
"query": []
|
|
26996
|
+
},
|
|
26997
|
+
{
|
|
26998
|
+
"resource": "organization.notifications.messages",
|
|
26999
|
+
"method": "update",
|
|
27000
|
+
"summary": "Mark one of your bell messages read or archived",
|
|
27001
|
+
"description": "Change the read or archived flag of one of the calling person's own bell messages and return it. Name at least one flag. Reading a message also tells the notification still waiting on it, so it is not emailed later as unread. A message that is not theirs answers 404 like one that does not exist. No usage charge.",
|
|
27002
|
+
"http": "POST",
|
|
27003
|
+
"path": "/organization/v1/notifications/messages/{name}",
|
|
27004
|
+
"streaming": "no",
|
|
27005
|
+
"pagination": false,
|
|
27006
|
+
"pathParams": [
|
|
27007
|
+
{
|
|
27008
|
+
"name": "name",
|
|
27009
|
+
"sdkName": "name",
|
|
27010
|
+
"description": "The message's `name` from the messages list, subscribers/{user}/messages/{id}, URL-encoded."
|
|
27011
|
+
}
|
|
27012
|
+
],
|
|
27013
|
+
"query": [],
|
|
27014
|
+
"body": {
|
|
27015
|
+
"required": true,
|
|
27016
|
+
"fields": [
|
|
27017
|
+
{
|
|
27018
|
+
"name": "read",
|
|
27019
|
+
"type": "boolean",
|
|
27020
|
+
"required": false,
|
|
27021
|
+
"description": "Mark the message read (true) or unread (false); omit to leave it."
|
|
27022
|
+
},
|
|
27023
|
+
{
|
|
27024
|
+
"name": "archived",
|
|
27025
|
+
"type": "boolean",
|
|
27026
|
+
"required": false,
|
|
27027
|
+
"description": "Archive the message (true) or move it back to the inbox (false); omit to leave it."
|
|
27028
|
+
}
|
|
27029
|
+
]
|
|
27030
|
+
}
|
|
27031
|
+
},
|
|
27032
|
+
{
|
|
27033
|
+
"resource": "organization.notifications.messages",
|
|
27034
|
+
"method": "readAll",
|
|
27035
|
+
"summary": "Mark all your unread bell messages read",
|
|
27036
|
+
"description": "Mark every unread, unarchived bell message of the calling person in this organization as read, and tell the notifications still waiting on them. Nothing of anyone else's is touched. Returns how many messages changed; 0 when there was nothing unread. No usage charge.",
|
|
27037
|
+
"http": "POST",
|
|
27038
|
+
"path": "/organization/v1/notifications/messages:readAll",
|
|
27039
|
+
"streaming": "no",
|
|
27040
|
+
"pagination": false,
|
|
27041
|
+
"pathParams": [],
|
|
27042
|
+
"query": []
|
|
27043
|
+
},
|
|
26594
27044
|
{
|
|
26595
27045
|
"resource": "organization.notifications",
|
|
26596
27046
|
"method": "retrieveOrganizationDefault",
|
|
@@ -26702,7 +27152,7 @@ export const operations = [
|
|
|
26702
27152
|
"resource": "organization.usage",
|
|
26703
27153
|
"method": "list",
|
|
26704
27154
|
"summary": "List Organization Usage",
|
|
26705
|
-
"description": "Consumed quantity per time bucket per group. Buckets are whole
|
|
27155
|
+
"description": "Consumed quantity per time bucket per group. Buckets are whole hour or day periods in time_zone (UTC by default) covering the requested window. Each result carries exactly one ConsumedQuantity + ConsumedUnit — quantities of different units are never added together.\n",
|
|
26706
27156
|
"http": "GET",
|
|
26707
27157
|
"path": "/organization/v1/usage",
|
|
26708
27158
|
"streaming": "no",
|
|
@@ -26735,7 +27185,7 @@ export const operations = [
|
|
|
26735
27185
|
"name": "time_zone",
|
|
26736
27186
|
"type": "string",
|
|
26737
27187
|
"required": false,
|
|
26738
|
-
"description": "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.
|
|
27188
|
+
"description": "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.\n"
|
|
26739
27189
|
},
|
|
26740
27190
|
{
|
|
26741
27191
|
"name": "group_by",
|