@aperture-browser/api-schema 0.0.0-init.0

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/dist/index.js ADDED
@@ -0,0 +1,1684 @@
1
+ import * as Data from "effect/Data";
2
+ import * as Effect from "effect/Effect";
3
+ import * as Schema from "effect/Schema";
4
+ import * as HttpClientError from "effect/unstable/http/HttpClientError";
5
+ import * as HttpClientRequest from "effect/unstable/http/HttpClientRequest";
6
+ import * as HttpClientResponse from "effect/unstable/http/HttpClientResponse";
7
+ //#region src/api.gen.ts
8
+ const Health = Schema.Struct({
9
+ "status": Schema.Literal("ok").annotate({ "description": "Process health. A successful response currently reports `ok`." }),
10
+ "color": Schema.Literals(["blue", "green"]).annotate({ "description": "Deployment color of the process that handled the request." }),
11
+ "role": Schema.Literals(["active", "inactive"]).annotate({ "description": "Whether this deployment color currently serves active traffic." }),
12
+ "version": Schema.String.annotate({
13
+ "description": "Build or release version embedded in the running binary.",
14
+ "examples": ["1.4.0"]
15
+ }),
16
+ "activeColor": Schema.Literals(["blue", "green"]).annotate({ "description": "Deployment color currently selected as active." })
17
+ }).annotate({
18
+ "description": "Local deployment health and blue-green role information.",
19
+ "examples": [{
20
+ "status": "ok",
21
+ "color": "blue",
22
+ "role": "active",
23
+ "version": "1.4.0",
24
+ "activeColor": "blue"
25
+ }],
26
+ "identifier": "Health"
27
+ });
28
+ const UUIDv7 = Schema.String.annotate({
29
+ "description": "Time-ordered UUID version 7 generated by Aperture.",
30
+ "examples": ["019f6cf0-0000-7000-8000-000000000001"],
31
+ "format": "uuid",
32
+ "identifier": "UUIDv7"
33
+ });
34
+ const PrincipalType = Schema.Literals([
35
+ "api_token",
36
+ "user",
37
+ "system"
38
+ ]).annotate({
39
+ "description": "Stable category of the authenticated or audited actor.",
40
+ "examples": ["api_token"],
41
+ "identifier": "PrincipalType"
42
+ });
43
+ const AuthorityType = Schema.Literals(["system_admin", "tenant"]).annotate({
44
+ "description": "Authorization boundary. `system_admin` principals may administer the deployment and select tenants. `tenant` principals act within one effective tenant.\n",
45
+ "examples": ["tenant"],
46
+ "identifier": "AuthorityType"
47
+ });
48
+ const Scope = Schema.Literals([
49
+ "system:admin",
50
+ "sessions:read",
51
+ "sessions:write",
52
+ "snapshots:read",
53
+ "snapshots:write",
54
+ "tenant:write",
55
+ "tenants:write"
56
+ ]).annotate({
57
+ "description": "Permission granted to a principal. `system:admin` implies every scope. Tenant credentials and memberships cannot receive `system:admin` or `tenants:write`.\n",
58
+ "examples": ["sessions:write"],
59
+ "identifier": "Scope"
60
+ });
61
+ const ResourceMode = Schema.Literals(["all", "allowlist"]).annotate({
62
+ "description": "Whether a tenant API token can access every tenant resource or only explicit grants.",
63
+ "default": "all",
64
+ "examples": ["allowlist"],
65
+ "identifier": "ResourceMode"
66
+ });
67
+ const ResourceType = Schema.Literals(["session", "snapshot"]).annotate({
68
+ "description": "Tenant resource category accepted by API token allowlists.",
69
+ "examples": ["session"],
70
+ "identifier": "ResourceType"
71
+ });
72
+ const ErrorDetail = Schema.Struct({
73
+ "code": Schema.String.annotate({
74
+ "description": "Stable code enumerated by each operation response.",
75
+ "examples": ["insufficient_scope"]
76
+ }),
77
+ "message": Schema.String.annotate({
78
+ "description": "Human-readable explanation. It may include resource or validation context.",
79
+ "examples": ["insufficient scope"]
80
+ })
81
+ }).annotate({
82
+ "description": "Stable machine-readable error code with a human-readable explanation.",
83
+ "identifier": "ErrorDetail"
84
+ });
85
+ const BrowserChannel = Schema.Struct({ "name": Schema.String.annotate({
86
+ "description": "Configured browser channel name.",
87
+ "examples": ["chromium"]
88
+ }) }).annotate({
89
+ "description": "Browser runtime selectable when creating a session.",
90
+ "identifier": "BrowserChannel"
91
+ });
92
+ const PageMeta = Schema.Struct({
93
+ "limit": Schema.Number.annotate({
94
+ "description": "Effective page size after applying the default and maximum.",
95
+ "examples": [50]
96
+ }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })).check(Schema.isLessThanOrEqualTo(100).annotate({ "expected": "a value less than or equal to 100" })),
97
+ "nextCursor": Schema.optionalKey(Schema.String.annotate({
98
+ "description": "Opaque cursor for the next page. Omitted when there is no next page.",
99
+ "examples": ["eyJjcmVhdGVkQXQiOiIyMDI2LTA3LTE3VDEyOjAwOjAwWiIsImlkIjoiMDE5ZjZjZjAtMDAwMC03MDAwLTgwMDAtMDAwMDAwMDAwMDAwIn0"]
100
+ })),
101
+ "hasMore": Schema.Boolean.annotate({
102
+ "description": "Whether another page is available.",
103
+ "examples": [true]
104
+ })
105
+ }).annotate({
106
+ "description": "Cursor pagination metadata for a newest-first result page.",
107
+ "identifier": "PageMeta"
108
+ });
109
+ const TenantInput = Schema.Struct({ "displayName": Schema.String.annotate({
110
+ "description": "Human-readable tenant name. Leading and trailing whitespace is removed and whitespace-only values are rejected.",
111
+ "examples": ["Example engineering"]
112
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })) }).annotate({
113
+ "description": "Tenant fields accepted by create and update operations.",
114
+ "identifier": "TenantInput"
115
+ });
116
+ const UserInput = Schema.Struct({
117
+ "email": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
118
+ "description": "Optional normalized login and contact email.",
119
+ "format": "email"
120
+ })),
121
+ "displayName": Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
122
+ "isSystemAdmin": Schema.Boolean.annotate({ "description": "Grants deployment-wide administration independently of tenant memberships." })
123
+ }).annotate({ "identifier": "UserInput" });
124
+ const UserInvitation = Schema.Struct({
125
+ "token": Schema.String.annotate({ "description": "Raw setup token. Store and transmit it as a secret." }),
126
+ "expiresAt": Schema.String.annotate({ "format": "date-time" })
127
+ }).annotate({
128
+ "description": "One-time account setup secret returned only when created.",
129
+ "identifier": "UserInvitation"
130
+ });
131
+ const TenantScope = Schema.Literals([
132
+ "sessions:read",
133
+ "sessions:write",
134
+ "snapshots:read",
135
+ "snapshots:write",
136
+ "tenant:write"
137
+ ]).annotate({
138
+ "description": "Scope allowed on a tenant-bound API token.",
139
+ "examples": ["sessions:write"],
140
+ "identifier": "TenantScope"
141
+ });
142
+ const SessionStatus = Schema.Literals([
143
+ "creating",
144
+ "running",
145
+ "suspended",
146
+ "deleted",
147
+ "expired",
148
+ "failed"
149
+ ]).annotate({
150
+ "description": "Session lifecycle state:\n\n- `creating`: browser startup is in progress; the CDP endpoint does not answer yet.\n- `running`: browser and routing are available and the CDP endpoint answers.\n- `suspended`: browser is intentionally stopped while retained state remains available.\n- `deleted`: session is soft-deleted and may be reopened while retained.\n- `expired`: retention elapsed and the session can no longer be used.\n- `failed`: startup or reopen failed; retained state may still be reopenable.\n",
151
+ "examples": ["running"],
152
+ "identifier": "SessionStatus"
153
+ });
154
+ const IceServer = Schema.Struct({
155
+ "urls": Schema.Array(Schema.String).annotate({
156
+ "description": "STUN or TURN server URLs.",
157
+ "examples": [["turn:turn.example.com:3478?transport=udp"]]
158
+ }),
159
+ "username": Schema.optionalKey(Schema.String.annotate({
160
+ "description": "TURN username. Omitted when the server does not require authentication.",
161
+ "examples": ["aperture-session"]
162
+ })),
163
+ "credential": Schema.optionalKey(Schema.String.annotate({
164
+ "description": "TURN credential. Treat it as a secret and do not persist it in logs.",
165
+ "examples": ["REDACTED"]
166
+ }))
167
+ }).annotate({
168
+ "description": "ICE server configuration supplied to WebRTC consumers.",
169
+ "identifier": "IceServer"
170
+ });
171
+ const StringMap = Schema.Record(Schema.String, Schema.String).annotate({
172
+ "description": "Arbitrary string key-value metadata. Tag-writing operations additionally reject blank keys and blank values.",
173
+ "examples": [{
174
+ "environment": "production",
175
+ "region": "eu-west-1"
176
+ }],
177
+ "identifier": "StringMap"
178
+ });
179
+ const SessionCollaborationCapabilities = Schema.Struct({
180
+ "editorToken": Schema.String.annotate({ "examples": ["ape_019f6cf0000070008000000000000010_REDACTED"] }),
181
+ "viewerToken": Schema.String.annotate({ "examples": ["apv_019f6cf0000070008000000000000010_REDACTED"] })
182
+ }).annotate({
183
+ "description": "Owner-visible role-scoped secrets used to build collaboration links.",
184
+ "identifier": "SessionCollaborationCapabilities"
185
+ });
186
+ const SessionProxy = Schema.Struct({
187
+ "upstream": Schema.Literals([
188
+ "direct",
189
+ "proxy",
190
+ "tunnel"
191
+ ]).annotate({
192
+ "description": "Upstream strategy for new connections.",
193
+ "examples": ["tunnel"]
194
+ }),
195
+ "url": Schema.optionalKey(Schema.String.annotate({
196
+ "description": "Generic upstream proxy URL. Omitted unless `upstream` is `proxy`. The password is masked, so this value cannot be replayed as a write.",
197
+ "examples": ["socks5://user:pass@proxy.example.com:1080"]
198
+ })),
199
+ "tunnel": Schema.optionalKey(Schema.Struct({ "url": Schema.optionalKey(Schema.String.annotate({
200
+ "description": "Compound tunnel URL.",
201
+ "examples": ["wss+yamux+socks5://tunnel.example.com/t/019f6cf0-0000-7000-8000-000000000010"]
202
+ })) }).annotate({ "description": "Tunnel endpoint. Omitted unless `upstream` is `tunnel`. The secret is never returned." })),
203
+ "bypass": Schema.optionalKey(Schema.String.annotate({
204
+ "description": "Extra `--proxy-bypass-list` entries.",
205
+ "examples": ["*.internal.example.com"]
206
+ }))
207
+ }).annotate({
208
+ "description": "Stored session egress proxy assignment. Secrets are write-only — tunnel auth never appears here, and an upstream proxy URL comes back with its password masked.",
209
+ "identifier": "SessionProxy"
210
+ });
211
+ const BrowserConfig = Schema.Struct({
212
+ "channel": Schema.String.annotate({
213
+ "description": "Channel returned by `GET /api/browser/channels`.",
214
+ "examples": ["chromium"]
215
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
216
+ "args": Schema.optionalKey(Schema.Array(Schema.String).annotate({
217
+ "description": "Additional Chromium command-line arguments. Aperture rejects arguments that conflict with supervisor-owned behavior or deployment policy.",
218
+ "examples": [["--lang=en-US"]]
219
+ }))
220
+ }).annotate({
221
+ "description": "Browser runtime configuration used to create or reopen the session.",
222
+ "identifier": "BrowserConfig"
223
+ });
224
+ const BrowserStorageEntry = Schema.Struct({
225
+ "name": Schema.String,
226
+ "value": Schema.String.annotate({ "description": "Browser storage value. Never log this field." })
227
+ }).annotate({ "identifier": "BrowserStorageEntry" });
228
+ const InitialBrowserScrollPosition = Schema.Struct({
229
+ "x": Schema.Number.check(Schema.isFinite().annotate({ "expected": "a finite number" })),
230
+ "y": Schema.Number.check(Schema.isFinite().annotate({ "expected": "a finite number" }))
231
+ }).annotate({ "identifier": "InitialBrowserScrollPosition" });
232
+ const InitialBrowserElementPathStep = Schema.Struct({
233
+ "tag": Schema.String.check(Schema.isPattern(/* @__PURE__ */ new RegExp("^[a-z][a-z0-9-]*$")).annotate({ "expected": "a string matching the RegExp ^[a-z][a-z0-9-]*$" })),
234
+ "index": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))
235
+ }).annotate({ "identifier": "InitialBrowserElementPathStep" });
236
+ const InitialBrowserControlSelection = Schema.Struct({
237
+ "start": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" })),
238
+ "end": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" })),
239
+ "direction": Schema.Literals([
240
+ "forward",
241
+ "backward",
242
+ "none"
243
+ ])
244
+ }).annotate({ "identifier": "InitialBrowserControlSelection" });
245
+ const BrowserCookieSameSite = Schema.Literals([
246
+ "Strict",
247
+ "Lax",
248
+ "None"
249
+ ]).annotate({ "identifier": "BrowserCookieSameSite" });
250
+ const InitialBrowserCookiePartitionKey = Schema.Struct({
251
+ "topLevelSite": Schema.String.annotate({ "format": "uri" }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^https?:\\/\\/[^/]+$")).annotate({ "expected": "a string matching the RegExp ^https?:\\/\\/[^/]+$" })),
252
+ "hasCrossSiteAncestor": Schema.optionalKey(Schema.Boolean)
253
+ }).annotate({ "identifier": "InitialBrowserCookiePartitionKey" });
254
+ const InitialIndexedDBKeyPath = Schema.Struct({
255
+ "kind": Schema.Literals([
256
+ "none",
257
+ "string",
258
+ "array"
259
+ ]),
260
+ "value": Schema.optionalKey(Schema.Array(Schema.String))
261
+ }).annotate({
262
+ "description": "Object-store key path. String paths contain one value; array paths contain at least one.",
263
+ "identifier": "InitialIndexedDBKeyPath"
264
+ });
265
+ const InitialIndexedDBIndexKeyPath = Schema.Struct({
266
+ "kind": Schema.Literals(["string", "array"]),
267
+ "value": Schema.Array(Schema.String).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" }))
268
+ }).annotate({
269
+ "description": "Index key path. String paths contain one value; array paths contain at least one.",
270
+ "identifier": "InitialIndexedDBIndexKeyPath"
271
+ });
272
+ const InitialIndexedDBRecord = Schema.Struct({
273
+ "key": Schema.String.annotate({ "description": "JSON-encoded structured-clone key." }),
274
+ "value": Schema.String.annotate({ "description": "JSON-encoded structured-clone value." })
275
+ }).annotate({ "identifier": "InitialIndexedDBRecord" });
276
+ const InitialOPFSFile = Schema.Struct({
277
+ "path": Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })),
278
+ "body": Schema.String.annotate({ "contentEncoding": "base64" })
279
+ }).annotate({ "identifier": "InitialOPFSFile" });
280
+ const ProxyTunnelConfig = Schema.Struct({
281
+ "url": Schema.optionalKey(Schema.String.annotate({
282
+ "description": "Compound tunnel URL (`ws+yamux+socks5://` or `wss+yamux+socks5://`).",
283
+ "examples": ["wss+yamux+socks5://tunnel.example.com/t/019f6cf0-0000-7000-8000-000000000010"]
284
+ })),
285
+ "auth": Schema.optionalKey(Schema.String.annotate({
286
+ "description": "Per-assignment bearer secret for the tunnel handshake. Write-only; never returned.",
287
+ "examples": ["REDACTED"]
288
+ }))
289
+ }).annotate({
290
+ "description": "Tunnel endpoint for the `tunnel` upstream. Minted by the tunnel operator.",
291
+ "identifier": "ProxyTunnelConfig"
292
+ });
293
+ const CursorVisibility = Schema.Struct({ "visible": Schema.Boolean.annotate({ "description": "Whether to include the remote cursor in live streams and recordings." }) }).annotate({
294
+ "description": "Whether the remote browser cursor is composited into session media.",
295
+ "identifier": "CursorVisibility"
296
+ });
297
+ const Recording = Schema.Struct({
298
+ "recordingId": Schema.String.annotate({
299
+ "description": "Stable recording identifier retained across target changes.",
300
+ "format": "uuid"
301
+ }),
302
+ "mode": Schema.Literals(["tab", "viewer"]).annotate({ "description": "Tab recordings stay on their specified top-level target; viewer recordings follow a live session client's selected top-level target and cannot be explicitly retargeted." }),
303
+ "targetId": Schema.String.annotate({ "description": "Identifier of the top-level target currently recorded." }),
304
+ "captureGeneration": Schema.Number.annotate({
305
+ "description": "Assignment generation for the current top-level target.",
306
+ "format": "int64"
307
+ }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" })),
308
+ "status": Schema.Literals([
309
+ "starting",
310
+ "running",
311
+ "stopped",
312
+ "failed"
313
+ ]),
314
+ "stopReason": Schema.optionalKey(Schema.String.annotate({ "description": "Lifecycle reason recorded after the recording stops or fails." })),
315
+ "relativePath": Schema.String.annotate({
316
+ "description": "Path below the session root; absolute host paths are never exposed.",
317
+ "examples": ["recordings/recording-550e8400-e29b-41d4-a716-446655440000.webm"]
318
+ }),
319
+ "startedAt": Schema.String.annotate({ "format": "date-time" }),
320
+ "stoppedAt": Schema.optionalKey(Schema.String.annotate({ "format": "date-time" })),
321
+ "sizeBytes": Schema.optionalKey(Schema.Number.annotate({ "format": "int64" }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
322
+ "fps": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })),
323
+ "bitrateKbps": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })),
324
+ "codec": Schema.Literals(["vp8", "h264-va"])
325
+ }).annotate({
326
+ "description": "One logical recording of a top-level target.",
327
+ "identifier": "Recording"
328
+ });
329
+ const CreateSessionRecordingInput = Schema.Struct({
330
+ "targetId": Schema.String.annotate({ "description": "Identifier of the ready top-level target to record." }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })),
331
+ "fps": Schema.optionalKey(Schema.Number.annotate({
332
+ "description": "Requested frames per second. Omit or use a non-positive value for the instance default.",
333
+ "examples": [60]
334
+ }).check(Schema.isInt().annotate({ "expected": "an integer" }))),
335
+ "bitrateKbps": Schema.optionalKey(Schema.Number.annotate({
336
+ "description": "Requested video bitrate in kilobits per second. Omit or use a non-positive value for the instance default.",
337
+ "examples": [6e3]
338
+ }).check(Schema.isInt().annotate({ "expected": "an integer" }))),
339
+ "codec": Schema.optionalKey(Schema.Literals(["vp8", "h264-va"]).annotate({
340
+ "description": "Video codec. Omit for the instance default.",
341
+ "examples": ["vp8"]
342
+ }))
343
+ }).annotate({
344
+ "description": "Top-level target and optional recording settings.",
345
+ "identifier": "CreateSessionRecordingInput"
346
+ });
347
+ const RetargetSessionRecordingInput = Schema.Struct({ "targetId": Schema.String.annotate({ "description": "Identifier of the ready destination top-level target." }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })) }).annotate({
348
+ "description": "Destination for a running tab recording.",
349
+ "identifier": "RetargetSessionRecordingInput"
350
+ });
351
+ const SessionFile = Schema.Struct({
352
+ "name": Schema.String.annotate({
353
+ "description": "File name without directory components.",
354
+ "examples": ["screencast-20260801T120000Z.webm"]
355
+ }),
356
+ "relativePath": Schema.String.annotate({
357
+ "description": "Path below the session root. The first component is `downloads` or `recordings`.",
358
+ "examples": ["recordings/screencast-20260801T120000Z.webm"]
359
+ }),
360
+ "size": Schema.Number.annotate({
361
+ "description": "File size in bytes.",
362
+ "examples": [1048576],
363
+ "format": "int64"
364
+ }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" })),
365
+ "modifiedAt": Schema.String.annotate({
366
+ "description": "Last file modification time.",
367
+ "examples": ["2026-08-01T12:05:00Z"],
368
+ "format": "date-time"
369
+ }),
370
+ "mimeType": Schema.String.annotate({
371
+ "description": "Detected media type.",
372
+ "examples": ["video/webm"]
373
+ })
374
+ }).annotate({
375
+ "description": "Regular file retained with a browser session.",
376
+ "identifier": "SessionFile"
377
+ });
378
+ const SessionFileDownloadURLInput = Schema.Struct({
379
+ "relativePath": Schema.String.annotate({
380
+ "description": "Path from a `SessionFile` result.",
381
+ "examples": ["recordings/screencast-20260801T120000Z.webm"]
382
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })),
383
+ "ttlSeconds": Schema.optionalKey(Schema.Number.annotate({
384
+ "description": "Requested lifetime in seconds. Omit it to use `signed_file_url_ttl`; values above `signed_file_url_max_ttl` are rejected.",
385
+ "examples": [900]
386
+ }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })))
387
+ }).annotate({
388
+ "description": "Session file path and requested signed URL lifetime.",
389
+ "identifier": "SessionFileDownloadURLInput"
390
+ });
391
+ const SessionFileDownloadURL = Schema.Struct({
392
+ "url": Schema.String.annotate({
393
+ "description": "URL containing a path-bound `apf_` token.",
394
+ "examples": ["https://aperture.example.com/sessions/019f6cf0-0000-7000-8000-000000000010/files/recordings/screencast-20260801T120000Z.webm?token=apf_REDACTED"],
395
+ "format": "uri"
396
+ }),
397
+ "expiresAt": Schema.String.annotate({
398
+ "description": "Time after which the URL is rejected.",
399
+ "examples": ["2026-08-01T12:20:00Z"],
400
+ "format": "date-time"
401
+ })
402
+ }).annotate({
403
+ "description": "Signed attachment URL for one session file.",
404
+ "identifier": "SessionFileDownloadURL"
405
+ });
406
+ const UpdateSnapshotInput = Schema.Struct({ "description": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
407
+ "description": "New description. Send `null` to clear it; an empty string is stored as an empty description.",
408
+ "examples": ["Updated signed-in state"]
409
+ })) }).annotate({
410
+ "description": "Replacement snapshot description.",
411
+ "identifier": "UpdateSnapshotInput"
412
+ });
413
+ const Tenant = Schema.Struct({
414
+ "id": Schema.suspend(() => UUIDv7).annotate({ "description": "Tenant identifier." }),
415
+ "displayName": Schema.String.annotate({
416
+ "description": "Human-readable tenant name.",
417
+ "examples": ["Example engineering"]
418
+ }),
419
+ "createdAt": Schema.String.annotate({
420
+ "description": "Time the tenant was created.",
421
+ "examples": ["2026-07-17T12:00:00Z"],
422
+ "format": "date-time"
423
+ }),
424
+ "deletedAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
425
+ "description": "Soft-deactivation time, or `null` for an active tenant.",
426
+ "examples": [null],
427
+ "format": "date-time"
428
+ }))
429
+ }).annotate({
430
+ "description": "Tenant account. Deletion is a reversible soft deactivation.",
431
+ "identifier": "Tenant"
432
+ });
433
+ const User = Schema.Struct({
434
+ "id": UUIDv7,
435
+ "email": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({ "format": "email" })),
436
+ "displayName": Schema.String,
437
+ "isSystemAdmin": Schema.Boolean,
438
+ "createdAt": Schema.String.annotate({ "format": "date-time" }),
439
+ "updatedAt": Schema.String.annotate({ "format": "date-time" }),
440
+ "disabledAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({ "format": "date-time" })),
441
+ "passwordSetupStatus": Schema.optionalKey(Schema.Literals([
442
+ "available",
443
+ "configured",
444
+ "email_required",
445
+ "user_disabled",
446
+ "login_disabled"
447
+ ]).annotate({ "description": "Password setup state included by the get-user operation." }))
448
+ }).annotate({ "identifier": "User" });
449
+ const SessionBulkInput = Schema.Struct({ "ids": Schema.Array(UUIDv7).annotate({
450
+ "description": "Up to 100 unique UUIDv7 values. An empty array is valid.",
451
+ "examples": [["019f6cf0-0000-7000-8000-000000000010", "019f6cf0-0000-7000-8000-000000000011"]]
452
+ }).check(Schema.isMaxLength(100).annotate({ "expected": "a value with a length of at most 100" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })) }).annotate({
453
+ "description": "Ordered session IDs for a tenant-scoped bulk lookup. Missing, foreign, and deleted IDs are omitted from the result.",
454
+ "identifier": "SessionBulkInput"
455
+ });
456
+ const Event = Schema.Struct({
457
+ "id": Schema.suspend(() => UUIDv7).annotate({ "description": "Event identifier." }),
458
+ "tenantId": Schema.suspend(() => UUIDv7).annotate({ "description": "Tenant that owns the event." }),
459
+ "resourceType": Schema.String.annotate({
460
+ "description": "Resource category associated with the event. Currently session events are the primary source; new categories may be added.",
461
+ "examples": ["session"]
462
+ }),
463
+ "resourceId": Schema.String.annotate({
464
+ "description": "Identifier of the associated resource. Its format depends on `resourceType`.",
465
+ "examples": ["019f6cf0-0000-7000-8000-000000000010"]
466
+ }),
467
+ "type": Schema.String.annotate({
468
+ "description": "Extensible event type used for programmatic handling.",
469
+ "examples": ["session.token_rotated"]
470
+ }),
471
+ "message": Schema.String.annotate({
472
+ "description": "Human-readable event summary.",
473
+ "examples": ["session token rotated"]
474
+ }),
475
+ "data": Schema.Record(Schema.String, Schema.Json.annotate({ "expected": "JSON value" })).annotate({
476
+ "description": "Event-specific JSON payload, such as error details or upload metadata.",
477
+ "examples": [{ "reason": "manual rotation" }]
478
+ }),
479
+ "createdAt": Schema.String.annotate({
480
+ "description": "Time the event was recorded.",
481
+ "examples": ["2026-07-17T12:30:00Z"],
482
+ "format": "date-time"
483
+ })
484
+ }).annotate({
485
+ "description": "Immutable tenant-scoped audit or lifecycle event.",
486
+ "identifier": "Event"
487
+ });
488
+ const AuditEvent = Schema.Struct({
489
+ "id": UUIDv7,
490
+ "actorType": PrincipalType,
491
+ "actorId": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])),
492
+ "tenantId": Schema.optionalKey(Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" })),
493
+ "action": Schema.String.annotate({ "examples": ["tenant_membership.upserted"] }),
494
+ "resourceType": Schema.String.annotate({ "examples": ["tenant_membership"] }),
495
+ "resourceId": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])),
496
+ "data": Schema.Record(Schema.String, Schema.Json.annotate({ "expected": "JSON value" })),
497
+ "createdAt": Schema.String.annotate({ "format": "date-time" })
498
+ }).annotate({ "identifier": "AuditEvent" });
499
+ const ResourceGrant = Schema.Struct({
500
+ "resourceType": ResourceType,
501
+ "resourceId": UUIDv7
502
+ }).annotate({
503
+ "description": "Access to one existing tenant session or snapshot by its stable UUIDv7 identifier.",
504
+ "identifier": "ResourceGrant"
505
+ });
506
+ const Error = Schema.Struct({ "error": ErrorDetail }).annotate({
507
+ "description": "Standard error envelope returned by REST API operations.",
508
+ "identifier": "Error"
509
+ });
510
+ const BrowserChannels = Schema.Struct({ "channels": Schema.Array(BrowserChannel) }).annotate({
511
+ "description": "Browser channels enabled on this deployment.",
512
+ "examples": [{ "channels": [{ "name": "chromium" }] }],
513
+ "identifier": "BrowserChannels"
514
+ });
515
+ const TenantMembership = Schema.Struct({
516
+ "tenantId": UUIDv7,
517
+ "userId": UUIDv7,
518
+ "scopes": Schema.Array(TenantScope).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
519
+ "createdAt": Schema.String.annotate({ "format": "date-time" }),
520
+ "updatedAt": Schema.String.annotate({ "format": "date-time" })
521
+ }).annotate({ "identifier": "TenantMembership" });
522
+ const TenantMembershipInput = Schema.Struct({ "scopes": Schema.Array(TenantScope).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })) }).annotate({ "identifier": "TenantMembershipInput" });
523
+ const SessionMedia = Schema.Struct({
524
+ "mode": Schema.Literals(["auto", "cdp"]).annotate({
525
+ "description": "Configured media mode. `auto` enables deployment-selected media support; `cdp` exposes Chrome DevTools access only.",
526
+ "examples": ["auto"]
527
+ }),
528
+ "webrtcProducer": Schema.Boolean.annotate({
529
+ "description": "Whether the compositor WebRTC producer is available for this session.",
530
+ "examples": [true]
531
+ }),
532
+ "iceServers": Schema.optionalKey(Schema.Array(IceServer).annotate({ "description": "ICE configuration for WebRTC setup. Omitted when WebRTC is unavailable or does not need configured ICE servers." }))
533
+ }).annotate({
534
+ "description": "Media capabilities currently available for the session.",
535
+ "identifier": "SessionMedia"
536
+ });
537
+ const InitialCacheStorageEntry = Schema.Struct({
538
+ "url": Schema.String.annotate({ "format": "uri" }),
539
+ "requestHeaders": StringMap,
540
+ "responseHeaders": StringMap,
541
+ "responseStatus": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(100).annotate({ "expected": "a value greater than or equal to 100" })).check(Schema.isLessThanOrEqualTo(599).annotate({ "expected": "a value less than or equal to 599" })),
542
+ "responseStatusText": Schema.String,
543
+ "responseBody": Schema.String.annotate({ "contentEncoding": "base64" })
544
+ }).annotate({ "identifier": "InitialCacheStorageEntry" });
545
+ const ReplaceTagsInput = Schema.Struct({ "tags": Schema.suspend(() => StringMap).annotate({ "description": "Complete tag map. Keys and values must contain non-whitespace characters." }) }).annotate({
546
+ "description": "Complete replacement tag set. The map may be empty to clear all tags.",
547
+ "examples": [{ "tags": {
548
+ "environment": "production",
549
+ "region": "eu-west-1"
550
+ } }],
551
+ "identifier": "ReplaceTagsInput"
552
+ });
553
+ const PromoteSessionInput = Schema.Struct({
554
+ "name": Schema.String.annotate({
555
+ "description": "Tenant-unique snapshot name. Leading and trailing whitespace is removed.",
556
+ "examples": ["signed-in-base"]
557
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
558
+ "description": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
559
+ "description": "Optional snapshot description. `null` creates the snapshot without a description.",
560
+ "examples": ["Signed-in storefront state for checkout tests"]
561
+ })),
562
+ "force": Schema.optionalKey(Schema.Boolean.annotate({
563
+ "description": "Deleted snapshot names are reused automatically. Set `true` to replace an active snapshot, which is renamed to its tombstone name and retained for the configured snapshot retention period.",
564
+ "default": false
565
+ })),
566
+ "tags": Schema.optionalKey(Schema.suspend(() => StringMap).annotate({ "description": "Initial complete tag map for the new snapshot." }))
567
+ }).annotate({
568
+ "description": "Snapshot metadata created from a stopped, retained session.",
569
+ "examples": [{
570
+ "name": "signed-in-base",
571
+ "description": "Signed-in storefront state for checkout tests",
572
+ "force": false,
573
+ "tags": {
574
+ "application": "storefront",
575
+ "environment": "staging"
576
+ }
577
+ }],
578
+ "identifier": "PromoteSessionInput"
579
+ });
580
+ const Snapshot = Schema.Struct({
581
+ "id": Schema.suspend(() => UUIDv7).annotate({ "description": "Snapshot identifier." }),
582
+ "name": Schema.String.annotate({
583
+ "description": "Human-selected tenant-unique snapshot name.",
584
+ "examples": ["signed-in-base"]
585
+ }),
586
+ "tenantId": Schema.suspend(() => UUIDv7).annotate({ "description": "Tenant that owns the snapshot." }),
587
+ "description": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
588
+ "description": "Operator-provided description, or `null` when none is set.",
589
+ "examples": ["Signed-in storefront state for checkout tests"]
590
+ })),
591
+ "parentSnapshotId": Schema.optionalKey(Schema.suspend(() => UUIDv7).annotate({ "description": "Base snapshot from which the source session was created. Omitted for snapshots without a parent." })),
592
+ "promotedFromSessionId": Schema.optionalKey(Schema.suspend(() => UUIDv7).annotate({ "description": "Session whose retained overlay produced this snapshot. Omitted when lineage is unavailable." })),
593
+ "createdAt": Schema.String.annotate({
594
+ "description": "Time the snapshot was created.",
595
+ "examples": ["2026-07-17T12:45:00Z"],
596
+ "format": "date-time"
597
+ }),
598
+ "deletedAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
599
+ "description": "Soft-deletion time, or `null` for an active snapshot.",
600
+ "examples": [null],
601
+ "format": "date-time"
602
+ })),
603
+ "expiresAt": Schema.optionalKey(Schema.String.annotate({
604
+ "description": "Purge eligibility time for a deleted snapshot. Omitted for active snapshots.",
605
+ "examples": ["2026-08-16T12:45:00Z"],
606
+ "format": "date-time"
607
+ })),
608
+ "tags": Schema.optionalKey(Schema.suspend(() => StringMap).annotate({ "description": "Snapshot metadata tags. Omitted when no tags are set." }))
609
+ }).annotate({
610
+ "description": "Reusable retained browser filesystem state. Deletion is soft until the retention deadline.",
611
+ "identifier": "Snapshot"
612
+ });
613
+ const InitialTargetStorageOrigin = Schema.Struct({
614
+ "origin": Schema.String.annotate({ "format": "uri" }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^https?:\\/\\/[^/]+$")).annotate({ "expected": "a string matching the RegExp ^https?:\\/\\/[^/]+$" })),
615
+ "entries": Schema.Array(BrowserStorageEntry)
616
+ }).annotate({ "identifier": "InitialTargetStorageOrigin" });
617
+ const InitialBrowserElementLocator = Schema.Struct({
618
+ "tag": Schema.String.check(Schema.isPattern(/* @__PURE__ */ new RegExp("^[a-z][a-z0-9-]*$")).annotate({ "expected": "a string matching the RegExp ^[a-z][a-z0-9-]*$" })),
619
+ "id": Schema.optionalKey(Schema.String),
620
+ "name": Schema.optionalKey(Schema.String),
621
+ "inputType": Schema.optionalKey(Schema.String),
622
+ "autocomplete": Schema.optionalKey(Schema.String),
623
+ "ariaLabel": Schema.optionalKey(Schema.String),
624
+ "placeholder": Schema.optionalKey(Schema.String),
625
+ "path": Schema.Array(InitialBrowserElementPathStep).check(Schema.isMaxLength(256).annotate({ "expected": "a value with a length of at most 256" }))
626
+ }).annotate({
627
+ "description": "Semantic element identity with a structural fallback. It is not a CSS selector.",
628
+ "identifier": "InitialBrowserElementLocator"
629
+ });
630
+ const InitialBrowserCookie = Schema.Struct({
631
+ "name": Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })),
632
+ "value": Schema.String.annotate({ "description": "Cookie value. Never log this field." }),
633
+ "domain": Schema.String.annotate({ "examples": [".example.com"] }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })),
634
+ "hostOnly": Schema.optionalKey(Schema.Boolean.annotate({
635
+ "description": "Scope the cookie to exactly `domain`, without subdomains. `domain` must then be a plain hostname.",
636
+ "default": false
637
+ })),
638
+ "path": Schema.String.annotate({ "examples": ["/"] }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^\\/")).annotate({ "expected": "a string matching the RegExp ^\\/" })),
639
+ "expires": Schema.optionalKey(Schema.Number.annotate({ "description": "Unix timestamp in seconds. Omit for a session cookie." }).check(Schema.isFinite().annotate({ "expected": "a finite number" })).check(Schema.isGreaterThan(0).annotate({ "expected": "a value greater than 0" }))),
640
+ "httpOnly": Schema.optionalKey(Schema.Boolean.annotate({ "default": false })),
641
+ "secure": Schema.optionalKey(Schema.Boolean.annotate({ "default": false })),
642
+ "sameSite": Schema.optionalKey(BrowserCookieSameSite),
643
+ "partitionKey": Schema.optionalKey(InitialBrowserCookiePartitionKey)
644
+ }).annotate({
645
+ "description": "Cookie imported into the new browser profile.",
646
+ "identifier": "InitialBrowserCookie"
647
+ });
648
+ const InitialIndexedDBIndex = Schema.Struct({
649
+ "name": Schema.String,
650
+ "keyPath": InitialIndexedDBIndexKeyPath,
651
+ "unique": Schema.Boolean,
652
+ "multiEntry": Schema.Boolean
653
+ }).annotate({ "identifier": "InitialIndexedDBIndex" });
654
+ const ProxyConfig = Schema.Struct({
655
+ "upstream": Schema.optionalKey(Schema.Literals([
656
+ "direct",
657
+ "proxy",
658
+ "tunnel"
659
+ ]).annotate({
660
+ "description": "Upstream strategy for new connections. Defaults to `direct`.",
661
+ "examples": ["tunnel"]
662
+ })),
663
+ "url": Schema.optionalKey(Schema.String.annotate({
664
+ "description": "Generic upstream proxy URL (`http`, `https`, `socks`, `socks5`, `socks5h`). Required when `upstream` is `proxy`. Credentials go in the userinfo (`socks5://user:pass@host:1080`) and are sent as Basic `Proxy-Authorization` for `http`/`https` or RFC 1929 username/password for the socks schemes. An omitted port defaults to 1080 (socks), 80 (http) or 443 (https).",
665
+ "examples": ["socks5://user:pass@proxy.example.com:1080"]
666
+ })),
667
+ "tunnel": Schema.optionalKey(ProxyTunnelConfig),
668
+ "bypass": Schema.optionalKey(Schema.String.annotate({
669
+ "description": "Extra `--proxy-bypass-list` entries. Loopback is always bypassed.",
670
+ "examples": ["*.internal.example.com"]
671
+ }))
672
+ }).annotate({
673
+ "description": "Session egress proxy assignment. Omitted for direct egress.",
674
+ "identifier": "ProxyConfig"
675
+ });
676
+ const UpdateProxyAssignment = Schema.Struct({
677
+ "upstream": Schema.optionalKey(Schema.Literals([
678
+ "direct",
679
+ "proxy",
680
+ "tunnel"
681
+ ]).annotate({
682
+ "description": "Upstream strategy for new connections. Defaults to `direct`.",
683
+ "examples": ["tunnel"]
684
+ })),
685
+ "url": Schema.optionalKey(Schema.String.annotate({
686
+ "description": "Generic upstream proxy URL (`http`, `https`, `socks`, `socks5`, `socks5h`). Required when `upstream` is `proxy`. Credentials go in the userinfo (`socks5://user:pass@host:1080`) and are sent as Basic `Proxy-Authorization` for `http`/`https` or RFC 1929 username/password for the socks schemes. An omitted port defaults to 1080 (socks), 80 (http) or 443 (https).",
687
+ "examples": ["socks5://user:pass@proxy.example.com:1080"]
688
+ })),
689
+ "tunnel": Schema.optionalKey(ProxyTunnelConfig),
690
+ "bypass": Schema.optionalKey(Schema.String.annotate({
691
+ "description": "Extra `--proxy-bypass-list` entries. Loopback is always bypassed.",
692
+ "examples": ["*.internal.example.com"]
693
+ })),
694
+ "drain": Schema.optionalKey(Schema.Boolean.annotate({
695
+ "description": "Reset live tunnel streams instead of letting them drain. New connections use the new assignment either way.",
696
+ "examples": [false]
697
+ }))
698
+ }).annotate({
699
+ "description": "Replacement session egress proxy assignment.",
700
+ "identifier": "UpdateProxyAssignment"
701
+ });
702
+ const TenantPage = Schema.Struct({
703
+ "data": Schema.Array(Tenant),
704
+ "meta": PageMeta
705
+ }).annotate({
706
+ "description": "Cursor-paginated tenants.",
707
+ "identifier": "TenantPage"
708
+ });
709
+ const UserPage = Schema.Struct({
710
+ "data": Schema.Array(User),
711
+ "meta": PageMeta
712
+ }).annotate({ "identifier": "UserPage" });
713
+ const EventPage = Schema.Struct({
714
+ "data": Schema.Array(Event),
715
+ "meta": PageMeta
716
+ }).annotate({
717
+ "description": "Cursor-paginated tenant events.",
718
+ "identifier": "EventPage"
719
+ });
720
+ const AuditEventPage = Schema.Struct({
721
+ "data": Schema.Array(AuditEvent),
722
+ "meta": PageMeta
723
+ }).annotate({ "identifier": "AuditEventPage" });
724
+ const Principal = Schema.Struct({
725
+ "type": PrincipalType,
726
+ "id": Schema.String.annotate({ "description": "Stable identifier of the authenticated subject." }),
727
+ "authMethod": Schema.Literals([
728
+ "api_token",
729
+ "oidc",
730
+ "passkey",
731
+ "password"
732
+ ]).annotate({ "description": "Authentication mechanism used for this request." }),
733
+ "tokenId": Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "Identifier of the API token used for authentication, or `null` for account-backed sessions." }),
734
+ "userId": Schema.optionalKey(Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "User identifier for account-backed authentication, or `null` for API tokens." })),
735
+ "name": Schema.String.annotate({
736
+ "description": "Display name of the authenticated credential or user.",
737
+ "examples": ["deployment automation"]
738
+ }),
739
+ "authorityType": AuthorityType,
740
+ "tenantId": Schema.optionalKey(Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "Effective tenant for tenant authority, or `null` when no tenant is selected." })),
741
+ "scopes": Schema.Array(Scope).annotate({ "description": "Scopes granted to the authenticated principal." }).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
742
+ "resourceMode": ResourceMode,
743
+ "resourceGrants": Schema.Array(ResourceGrant).annotate({ "description": "Explicit grants when `resourceMode` is `allowlist`; empty when it is `all`." }).check(Schema.isUnique().annotate({ "expected": "an array with unique items" }))
744
+ }).annotate({
745
+ "description": "Authenticated subject identity and authorization context.",
746
+ "identifier": "Principal"
747
+ });
748
+ const Token = Schema.Struct({
749
+ "id": Schema.suspend(() => UUIDv7).annotate({ "description": "Token identifier. This is not the bearer secret." }),
750
+ "authorityType": AuthorityType,
751
+ "tenantId": Schema.optionalKey(Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "Bound tenant for a tenant token, or `null` for a system administrator token." })),
752
+ "name": Schema.String.annotate({
753
+ "description": "Operator-assigned token name, unique within its authority and tenant context.",
754
+ "examples": ["ci automation"]
755
+ }),
756
+ "scopes": Schema.Array(Scope).annotate({ "description": "Unique scopes granted to the token." }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
757
+ "createdAt": Schema.String.annotate({
758
+ "description": "Time the token was created.",
759
+ "examples": ["2026-07-17T12:00:00Z"],
760
+ "format": "date-time"
761
+ }),
762
+ "createdByType": Schema.suspend(() => PrincipalType).annotate({ "description": "Principal category that created the token." }),
763
+ "createdById": Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "User or API token identifier that created the token, or `null` for trusted local system actions." }),
764
+ "parentTokenId": Schema.Union([UUIDv7, Schema.Null], { mode: "oneOf" }).annotate({ "description": "API token used to delegate this token, or `null` when a user or trusted local system created it." }),
765
+ "resourceMode": ResourceMode,
766
+ "resourceGrants": Schema.Array(ResourceGrant).annotate({ "description": "Explicit session and snapshot grants when `resourceMode` is `allowlist`." }).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
767
+ "expiresAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
768
+ "description": "Authentication expiry time, or `null` when the token does not expire automatically.",
769
+ "examples": ["2026-08-17T12:00:00Z"],
770
+ "format": "date-time"
771
+ })),
772
+ "revokedAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
773
+ "description": "Revocation time, or `null` while the token is active.",
774
+ "examples": [null],
775
+ "format": "date-time"
776
+ }))
777
+ }).annotate({
778
+ "description": "API token metadata. The raw bearer secret is never included in this schema.",
779
+ "identifier": "Token"
780
+ });
781
+ const CreateAdminTokenInput = Schema.Union([Schema.Struct({
782
+ "name": Schema.String.annotate({
783
+ "description": "Operator-assigned name. Leading and trailing whitespace is removed.",
784
+ "examples": ["platform admin"]
785
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
786
+ "authorityType": Schema.Literal("system_admin"),
787
+ "scopes": Schema.Array(Scope).annotate({
788
+ "description": "Must include `system:admin`.",
789
+ "examples": [["system:admin"]]
790
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
791
+ "expiresAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
792
+ "description": "Optional RFC3339 timestamp. Omit or send `null` for no automatic expiry.",
793
+ "examples": ["2026-08-17T12:00:00Z"],
794
+ "format": "date-time"
795
+ })),
796
+ "resourceMode": Schema.optionalKey(Schema.Literal("all").annotate({
797
+ "description": "System administrator tokens cannot use resource allowlists.",
798
+ "default": "all"
799
+ })),
800
+ "resourceGrants": Schema.optionalKey(Schema.Array(ResourceGrant).annotate({ "description": "Must be empty for a system administrator token." }).check(Schema.isMaxLength(0).annotate({ "expected": "a value with a length of at most 0" })))
801
+ }), Schema.Struct({
802
+ "name": Schema.String.annotate({
803
+ "description": "Operator-assigned name. Leading and trailing whitespace is removed.",
804
+ "examples": ["tenant automation"]
805
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
806
+ "authorityType": Schema.Literal("tenant"),
807
+ "tenantId": Schema.suspend(() => UUIDv7).annotate({ "description": "Active tenant to bind permanently to the token." }),
808
+ "scopes": Schema.Array(TenantScope).annotate({
809
+ "description": "Tenant-compatible scopes. `system:admin` and `tenants:write` are rejected.",
810
+ "examples": [["sessions:read", "sessions:write"]]
811
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
812
+ "expiresAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
813
+ "description": "Optional RFC3339 timestamp. Omit or send `null` for no automatic expiry.",
814
+ "examples": ["2026-08-17T12:00:00Z"],
815
+ "format": "date-time"
816
+ })),
817
+ "resourceMode": Schema.optionalKey(ResourceMode),
818
+ "resourceGrants": Schema.optionalKey(Schema.Array(ResourceGrant).annotate({ "description": "Existing tenant resources granted when `resourceMode` is `allowlist`; must be empty for `all`." }).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })))
819
+ })], { mode: "oneOf" }).annotate({
820
+ "description": "Token definition accepted by the system administrator token endpoint.",
821
+ "identifier": "CreateAdminTokenInput"
822
+ });
823
+ const CreateTenantTokenInput = Schema.Struct({
824
+ "name": Schema.String.annotate({
825
+ "description": "Operator-assigned name. Leading and trailing whitespace is removed.",
826
+ "examples": ["browser worker"]
827
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isPattern(/* @__PURE__ */ new RegExp(".*\\S.*")).annotate({ "expected": "a string matching the RegExp .*\\S.*" })),
828
+ "scopes": Schema.Array(TenantScope).annotate({
829
+ "description": "Tenant-compatible scopes. `system:admin` and `tenants:write` are rejected.",
830
+ "examples": [["sessions:read", "sessions:write"]]
831
+ }).check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })),
832
+ "expiresAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
833
+ "description": "Optional RFC3339 timestamp. Omit or send `null` for no automatic expiry.",
834
+ "examples": ["2026-08-17T12:00:00Z"],
835
+ "format": "date-time"
836
+ })),
837
+ "resourceMode": Schema.optionalKey(ResourceMode),
838
+ "resourceGrants": Schema.optionalKey(Schema.Array(ResourceGrant).annotate({ "description": "Existing tenant resources granted when `resourceMode` is `allowlist`; must be empty for `all`." }).check(Schema.isUnique().annotate({ "expected": "an array with unique items" })))
839
+ }).annotate({
840
+ "description": "Token definition automatically bound to the authenticated tenant.",
841
+ "identifier": "CreateTenantTokenInput"
842
+ });
843
+ const Session = Schema.Struct({
844
+ "id": Schema.suspend(() => UUIDv7).annotate({ "description": "Session identifier." }),
845
+ "tenantId": Schema.suspend(() => UUIDv7).annotate({ "description": "Tenant that owns the session." }),
846
+ "baseSnapshotName": Schema.optionalKey(Schema.String.annotate({
847
+ "description": "Snapshot name used as the session base. Omitted for a blank session.",
848
+ "examples": ["signed-in-base"]
849
+ })),
850
+ "label": Schema.optionalKey(Schema.String.annotate({
851
+ "description": "Optional operator-facing session label.",
852
+ "examples": ["checkout smoke test"]
853
+ })),
854
+ "status": SessionStatus,
855
+ "browserChannel": Schema.optionalKey(Schema.String.annotate({
856
+ "description": "Browser channel used to create and reopen the session.",
857
+ "examples": ["chromium"]
858
+ })),
859
+ "media": SessionMedia,
860
+ "createdAt": Schema.String.annotate({
861
+ "description": "Time the session record was created.",
862
+ "examples": ["2026-07-17T12:00:00Z"],
863
+ "format": "date-time"
864
+ }),
865
+ "startedAt": Schema.optionalKey(Schema.String.annotate({
866
+ "description": "Most recent successful browser start time. Omitted before startup succeeds.",
867
+ "examples": ["2026-07-17T12:00:03Z"],
868
+ "format": "date-time"
869
+ })),
870
+ "stoppedAt": Schema.optionalKey(Schema.String.annotate({
871
+ "description": "Most recent browser stop time. Omitted while no stop has occurred.",
872
+ "examples": ["2026-07-17T13:00:00Z"],
873
+ "format": "date-time"
874
+ })),
875
+ "deletedAt": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
876
+ "description": "Soft-deletion time, or `null` for a session that has not been deleted.",
877
+ "examples": [null],
878
+ "format": "date-time"
879
+ })),
880
+ "expiresAt": Schema.String.annotate({
881
+ "description": "Retention deadline after which the session and its overlay may be purged. This is not token expiry.",
882
+ "examples": ["2026-07-24T12:00:00Z"],
883
+ "format": "date-time"
884
+ }),
885
+ "lastConnectedAt": Schema.optionalKey(Schema.String.annotate({
886
+ "description": "Most recent routed client activity time. Omitted until a client connects.",
887
+ "examples": ["2026-07-17T12:30:00Z"],
888
+ "format": "date-time"
889
+ })),
890
+ "suspendedAt": Schema.optionalKey(Schema.String.annotate({
891
+ "description": "Most recent suspension time. Omitted unless the session is suspended.",
892
+ "examples": ["2026-07-17T13:00:00Z"],
893
+ "format": "date-time"
894
+ })),
895
+ "tags": Schema.optionalKey(Schema.suspend(() => StringMap).annotate({ "description": "Session metadata tags. Omitted when no tags are set." })),
896
+ "cdpUrl": Schema.optionalKey(Schema.String.annotate({
897
+ "description": "Authenticated Chrome DevTools endpoint. Omitted when the session is not currently routable. Use it with `sessionToken`.",
898
+ "examples": ["https://aperture.example.com/cdp/019f6cf0-0000-7000-8000-000000000010"],
899
+ "format": "uri"
900
+ })),
901
+ "sessionToken": Schema.optionalKey(Schema.String.annotate({
902
+ "description": "Session access secret returned when live access credentials are available. Rotation invalidates the previous token immediately.",
903
+ "examples": ["aps_019f6cf0000070008000000000000010_REDACTED"]
904
+ })),
905
+ "collaboration": Schema.optionalKey(SessionCollaborationCapabilities),
906
+ "proxy": Schema.optionalKey(SessionProxy)
907
+ }).annotate({
908
+ "description": "Browser session state, retention metadata, tags, and currently available access credentials.",
909
+ "identifier": "Session"
910
+ });
911
+ const InitialCacheStorageCache = Schema.Struct({
912
+ "name": Schema.String,
913
+ "entries": Schema.Array(InitialCacheStorageEntry)
914
+ }).annotate({ "identifier": "InitialCacheStorageCache" });
915
+ const SnapshotMutation = Schema.Struct({ "snapshot": Snapshot }).annotate({
916
+ "description": "Snapshot returned after a mutation.",
917
+ "identifier": "SnapshotMutation"
918
+ });
919
+ const SnapshotPage = Schema.Struct({
920
+ "data": Schema.Array(Snapshot),
921
+ "meta": PageMeta
922
+ }).annotate({
923
+ "description": "Cursor-paginated snapshots.",
924
+ "identifier": "SnapshotPage"
925
+ });
926
+ const InitialBrowserControlState = Schema.Struct({
927
+ "locator": InitialBrowserElementLocator,
928
+ "value": Schema.String,
929
+ "checked": Schema.optionalKey(Schema.Boolean),
930
+ "selectedIndices": Schema.optionalKey(Schema.Array(Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" })))),
931
+ "selection": Schema.optionalKey(InitialBrowserControlSelection)
932
+ }).annotate({ "identifier": "InitialBrowserControlState" });
933
+ const InitialBrowserContentEditableState = Schema.Struct({
934
+ "locator": InitialBrowserElementLocator,
935
+ "html": Schema.String
936
+ }).annotate({ "identifier": "InitialBrowserContentEditableState" });
937
+ const InitialBrowserElementScrollPosition = Schema.Struct({
938
+ "locator": InitialBrowserElementLocator,
939
+ "x": Schema.Number.check(Schema.isFinite().annotate({ "expected": "a finite number" })),
940
+ "y": Schema.Number.check(Schema.isFinite().annotate({ "expected": "a finite number" }))
941
+ }).annotate({ "identifier": "InitialBrowserElementScrollPosition" });
942
+ const InitialBrowserSelectionEndpoint = Schema.Struct({
943
+ "locator": InitialBrowserElementLocator,
944
+ "nodePath": Schema.Array(Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))).check(Schema.isMaxLength(256).annotate({ "expected": "a value with a length of at most 256" })),
945
+ "offset": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))
946
+ }).annotate({ "identifier": "InitialBrowserSelectionEndpoint" });
947
+ const InitialIndexedDBObjectStore = Schema.Struct({
948
+ "name": Schema.String,
949
+ "keyPath": InitialIndexedDBKeyPath,
950
+ "autoIncrement": Schema.Boolean,
951
+ "indexes": Schema.Array(InitialIndexedDBIndex),
952
+ "records": Schema.Array(InitialIndexedDBRecord)
953
+ }).annotate({ "identifier": "InitialIndexedDBObjectStore" });
954
+ const AuthMe = Schema.Struct({
955
+ "principal": Principal,
956
+ "selectedTenant": Schema.Union([Tenant, Schema.Null], { mode: "oneOf" }).annotate({ "description": "Effective tenant, or `null` when the principal has not selected one." }),
957
+ "availableTenants": Schema.Array(Tenant).annotate({ "description": "Active tenant memberships available to an account-backed principal. API-token principals return an empty array." })
958
+ }).annotate({
959
+ "description": "Current principal and its effective tenant selection.",
960
+ "identifier": "AuthMe"
961
+ });
962
+ const TokenPage = Schema.Struct({
963
+ "data": Schema.Array(Token),
964
+ "meta": PageMeta
965
+ }).annotate({
966
+ "description": "Cursor-paginated API token metadata without bearer secrets.",
967
+ "identifier": "TokenPage"
968
+ });
969
+ const CreateTokenResponse = Schema.Struct({
970
+ "token": Token,
971
+ "rawToken": Schema.String.annotate({
972
+ "description": "One-time Aperture API bearer token. Store it immediately; later reads return only token metadata.",
973
+ "examples": ["apt_019f6cf0000070008000000000000002_REDACTED"]
974
+ })
975
+ }).annotate({
976
+ "description": "Created token metadata and its one-time bearer secret.",
977
+ "identifier": "CreateTokenResponse"
978
+ });
979
+ const SessionPage = Schema.Struct({
980
+ "data": Schema.Array(Session),
981
+ "meta": PageMeta
982
+ }).annotate({
983
+ "description": "Cursor-paginated browser sessions.",
984
+ "identifier": "SessionPage"
985
+ });
986
+ const CreateSessionResult = Schema.Struct({
987
+ "session": Session,
988
+ "cdpUrl": Schema.String.annotate({
989
+ "description": "Authenticated Chrome DevTools endpoint for the new session.",
990
+ "examples": ["https://aperture.example.com/cdp/019f6cf0-0000-7000-8000-000000000010"],
991
+ "format": "uri"
992
+ }),
993
+ "sessionToken": Schema.String.annotate({
994
+ "description": "Initial session access secret. Store it immediately.",
995
+ "examples": ["aps_019f6cf0000070008000000000000010_REDACTED"]
996
+ })
997
+ }).annotate({
998
+ "description": "Newly created session and its one-time initial access credentials.",
999
+ "identifier": "CreateSessionResult"
1000
+ });
1001
+ const SessionBulkResponse = Schema.Struct({ "sessions": Schema.Array(Session) }).annotate({
1002
+ "description": "Sessions found for the requested IDs, preserving request order.",
1003
+ "identifier": "SessionBulkResponse"
1004
+ });
1005
+ const SessionMutation = Schema.Struct({
1006
+ "session": Session,
1007
+ "cdpUrl": Schema.optionalKey(Schema.String.annotate({
1008
+ "description": "Current Chrome DevTools endpoint. Omitted by operations that do not expose live access.",
1009
+ "examples": ["https://aperture.example.com/cdp/019f6cf0-0000-7000-8000-000000000010"],
1010
+ "format": "uri"
1011
+ })),
1012
+ "sessionToken": Schema.optionalKey(Schema.String.annotate({
1013
+ "description": "Current raw session access secret. Omitted by operations that do not expose or replace credentials.",
1014
+ "examples": ["aps_019f6cf0000070008000000000000010_REDACTED"]
1015
+ }))
1016
+ }).annotate({
1017
+ "description": "Updated session and operation-specific live access credentials when available.",
1018
+ "identifier": "SessionMutation"
1019
+ });
1020
+ const InitialBrowserDocumentSelection = Schema.Struct({
1021
+ "anchor": InitialBrowserSelectionEndpoint,
1022
+ "focus": InitialBrowserSelectionEndpoint
1023
+ }).annotate({ "identifier": "InitialBrowserDocumentSelection" });
1024
+ const InitialIndexedDBDatabase = Schema.Struct({
1025
+ "name": Schema.String,
1026
+ "version": Schema.Number.check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })),
1027
+ "objectStores": Schema.Array(InitialIndexedDBObjectStore)
1028
+ }).annotate({ "identifier": "InitialIndexedDBDatabase" });
1029
+ const InitialBrowserDocumentState = Schema.Struct({
1030
+ "version": Schema.Literal(1),
1031
+ "windowName": Schema.optionalKey(Schema.String),
1032
+ "historyState": Schema.optionalKey(Schema.String.annotate({ "description": "JSON-encoded structured-clone history state." })),
1033
+ "controls": Schema.Array(InitialBrowserControlState).check(Schema.isMaxLength(1e4).annotate({ "expected": "a value with a length of at most 10000" })),
1034
+ "contentEditables": Schema.Array(InitialBrowserContentEditableState).check(Schema.isMaxLength(1e4).annotate({ "expected": "a value with a length of at most 10000" })),
1035
+ "scrollPositions": Schema.Array(InitialBrowserElementScrollPosition).check(Schema.isMaxLength(1e4).annotate({ "expected": "a value with a length of at most 10000" })),
1036
+ "focus": Schema.optionalKey(InitialBrowserElementLocator),
1037
+ "selection": Schema.optionalKey(InitialBrowserDocumentSelection)
1038
+ }).annotate({
1039
+ "description": "Sensitive top-document state replayed during initial navigation.",
1040
+ "identifier": "InitialBrowserDocumentState"
1041
+ });
1042
+ const InitialStorageOrigin = Schema.Struct({
1043
+ "origin": Schema.String.annotate({
1044
+ "examples": ["https://example.com"],
1045
+ "format": "uri"
1046
+ }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^https?:\\/\\/[^/]+$")).annotate({ "expected": "a string matching the RegExp ^https?:\\/\\/[^/]+$" })),
1047
+ "ancestorOrigins": Schema.optionalKey(Schema.Array(Schema.String.annotate({ "format": "uri" }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^https?:\\/\\/[^/]+$")).annotate({ "expected": "a string matching the RegExp ^https?:\\/\\/[^/]+$" }))).annotate({ "description": "Top-down HTTP origin chain for partitioned storage. Omitted for a top-level origin." }).check(Schema.isMaxLength(32).annotate({ "expected": "a value with a length of at most 32" }))),
1048
+ "localStorage": Schema.Array(BrowserStorageEntry),
1049
+ "indexedDB": Schema.optionalKey(Schema.Array(InitialIndexedDBDatabase)),
1050
+ "cacheStorage": Schema.optionalKey(Schema.Array(InitialCacheStorageCache)),
1051
+ "opfs": Schema.optionalKey(Schema.Array(InitialOPFSFile))
1052
+ }).annotate({
1053
+ "description": "Profile-scoped browser storage imported for one exact HTTP origin and ancestor partition.",
1054
+ "identifier": "InitialStorageOrigin"
1055
+ });
1056
+ const InitialBrowserTarget = Schema.Struct({
1057
+ "url": Schema.String.annotate({
1058
+ "description": "Absolute HTTP or HTTPS URL without embedded credentials.",
1059
+ "examples": ["https://example.com/account"],
1060
+ "format": "uri"
1061
+ }).check(Schema.isPattern(/* @__PURE__ */ new RegExp("^https?:\\/\\/")).annotate({ "expected": "a string matching the RegExp ^https?:\\/\\/" })),
1062
+ "sessionStorage": Schema.optionalKey(Schema.Array(InitialTargetStorageOrigin).annotate({ "description": "Per-origin session storage installed in target frames before page scripts execute." })),
1063
+ "scroll": Schema.optionalKey(InitialBrowserScrollPosition),
1064
+ "documentState": Schema.optionalKey(InitialBrowserDocumentState),
1065
+ "openerTargetIndex": Schema.optionalKey(Schema.Number.annotate({ "description": "Index of another initial target that opened this target." }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1066
+ "active": Schema.optionalKey(Schema.Boolean.annotate({
1067
+ "description": "Select this target for the first connected session client. At most one target may be active.",
1068
+ "default": false
1069
+ }))
1070
+ }).annotate({
1071
+ "description": "HTTP page and target-scoped state opened during session creation.",
1072
+ "identifier": "InitialBrowserTarget"
1073
+ });
1074
+ const InitialBrowserStorageState = Schema.Struct({
1075
+ "cookies": Schema.Array(InitialBrowserCookie).check(Schema.isMaxLength(1e4).annotate({ "expected": "a value with a length of at most 10000" })),
1076
+ "origins": Schema.Array(InitialStorageOrigin).check(Schema.isMaxLength(100).annotate({ "expected": "a value with a length of at most 100" }))
1077
+ }).annotate({
1078
+ "description": "Profile-scoped browser storage imported before initial browser targets are opened.",
1079
+ "identifier": "InitialBrowserStorageState"
1080
+ });
1081
+ const CreateSessionInput = Schema.Struct({
1082
+ "baseSnapshotName": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
1083
+ "description": "Active snapshot used as the browser filesystem base. Omit, send `null`, or send an empty value for a blank session.",
1084
+ "examples": ["signed-in-base"]
1085
+ })),
1086
+ "label": Schema.optionalKey(Schema.Union([Schema.String, Schema.Null]).annotate({
1087
+ "description": "Optional operator-facing label for the session.",
1088
+ "examples": ["checkout smoke test"]
1089
+ })),
1090
+ "browser": BrowserConfig,
1091
+ "initialTargets": Schema.optionalKey(Schema.Array(InitialBrowserTarget).annotate({ "description": "Browser targets that replace the browser's startup page after storage import. Result order follows input order; opener dependencies may be created first." }).check(Schema.isMaxLength(50).annotate({ "expected": "a value with a length of at most 50" }))),
1092
+ "storageState": Schema.optionalKey(InitialBrowserStorageState),
1093
+ "tags": Schema.optionalKey(Schema.suspend(() => StringMap).annotate({ "description": "Initial session tags." })),
1094
+ "proxy": Schema.optionalKey(ProxyConfig)
1095
+ }).annotate({
1096
+ "description": "Configuration for a new retained browser session.",
1097
+ "examples": [{
1098
+ "baseSnapshotName": "signed-in-base",
1099
+ "label": "checkout smoke test",
1100
+ "browser": {
1101
+ "channel": "chromium",
1102
+ "args": ["--lang=en-US"]
1103
+ },
1104
+ "initialTargets": [{ "url": "https://example.com/account" }],
1105
+ "storageState": {
1106
+ "cookies": [],
1107
+ "origins": [{
1108
+ "origin": "https://example.com",
1109
+ "localStorage": [{
1110
+ "name": "access-token",
1111
+ "value": "REDACTED"
1112
+ }]
1113
+ }]
1114
+ },
1115
+ "tags": {
1116
+ "environment": "staging",
1117
+ "suite": "checkout"
1118
+ }
1119
+ }],
1120
+ "identifier": "CreateSessionInput"
1121
+ });
1122
+ const GetHealth200 = Health;
1123
+ const GetCurrentPrincipalParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1124
+ const GetCurrentPrincipal200 = AuthMe;
1125
+ const GetCurrentPrincipaldefault = Error;
1126
+ const ListBrowserChannels200 = BrowserChannels;
1127
+ const ListBrowserChannelsdefault = Error;
1128
+ const ListTenantsParams = Schema.Struct({
1129
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1130
+ "cursor": Schema.optionalKey(Schema.String),
1131
+ "deleted": Schema.optionalKey(Schema.Literals([
1132
+ "active",
1133
+ "deleted",
1134
+ "all"
1135
+ ]).annotate({ "default": "active" })),
1136
+ "includeDeleted": Schema.optionalKey(Schema.Boolean.annotate({ "default": false }))
1137
+ });
1138
+ const ListTenants200 = TenantPage;
1139
+ const ListTenantsdefault = Error;
1140
+ const CreateTenantRequestJson = TenantInput;
1141
+ const CreateTenant201 = Tenant;
1142
+ const CreateTenantdefault = Error;
1143
+ const DeleteTenant200 = Tenant;
1144
+ const DeleteTenantdefault = Error;
1145
+ const UpdateTenantRequestJson = TenantInput;
1146
+ const UpdateTenant200 = Tenant;
1147
+ const UpdateTenantdefault = Error;
1148
+ const RestoreTenant200 = Tenant;
1149
+ const RestoreTenantdefault = Error;
1150
+ const ListUsersParams = Schema.Struct({
1151
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1152
+ "cursor": Schema.optionalKey(Schema.String),
1153
+ "query": Schema.optionalKey(Schema.String),
1154
+ "disabled": Schema.optionalKey(Schema.Literals([
1155
+ "active",
1156
+ "disabled",
1157
+ "all"
1158
+ ]).annotate({ "default": "active" }))
1159
+ });
1160
+ const ListUsers200 = UserPage;
1161
+ const ListUsersdefault = Error;
1162
+ const CreateUserRequestJson = UserInput;
1163
+ const CreateUser201 = User;
1164
+ const CreateUserdefault = Error;
1165
+ const GetUser200 = User;
1166
+ const GetUserdefault = Error;
1167
+ const DisableUser200 = User;
1168
+ const DisableUserdefault = Error;
1169
+ const UpdateUserRequestJson = UserInput;
1170
+ const UpdateUser200 = User;
1171
+ const UpdateUserdefault = Error;
1172
+ const RestoreUser200 = User;
1173
+ const RestoreUserdefault = Error;
1174
+ const CreateUserInvitation201 = UserInvitation;
1175
+ const CreateUserInvitationdefault = Error;
1176
+ const ListUserMemberships200 = Schema.Array(TenantMembership);
1177
+ const ListUserMembershipsdefault = Error;
1178
+ const ListTenantMemberships200 = Schema.Array(TenantMembership);
1179
+ const ListTenantMembershipsdefault = Error;
1180
+ const UpsertTenantMembershipRequestJson = TenantMembershipInput;
1181
+ const UpsertTenantMembership200 = TenantMembership;
1182
+ const UpsertTenantMembershipdefault = Error;
1183
+ const DeleteTenantMembershipdefault = Error;
1184
+ const ListAuditEventsParams = Schema.Struct({
1185
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1186
+ "cursor": Schema.optionalKey(Schema.String),
1187
+ "tenantId": Schema.optionalKey(UUIDv7),
1188
+ "actorType": Schema.optionalKey(PrincipalType),
1189
+ "actorId": Schema.optionalKey(Schema.String),
1190
+ "action": Schema.optionalKey(Schema.String),
1191
+ "resourceType": Schema.optionalKey(Schema.String),
1192
+ "resourceId": Schema.optionalKey(Schema.String)
1193
+ });
1194
+ const ListAuditEvents200 = AuditEventPage;
1195
+ const ListAuditEventsdefault = Error;
1196
+ const ListAdminTokensParams = Schema.Struct({
1197
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1198
+ "cursor": Schema.optionalKey(Schema.String),
1199
+ "authorityType": Schema.optionalKey(AuthorityType),
1200
+ "tenantId": Schema.optionalKey(UUIDv7),
1201
+ "name": Schema.optionalKey(Schema.String),
1202
+ "scope": Schema.optionalKey(Scope),
1203
+ "revoked": Schema.optionalKey(Schema.Literals([
1204
+ "active",
1205
+ "revoked",
1206
+ "all"
1207
+ ]).annotate({ "default": "all" }))
1208
+ });
1209
+ const ListAdminTokens200 = TokenPage;
1210
+ const ListAdminTokensdefault = Error;
1211
+ const CreateAdminTokenRequestJson = CreateAdminTokenInput;
1212
+ const CreateAdminToken201 = CreateTokenResponse;
1213
+ const CreateAdminTokendefault = Error;
1214
+ const RevokeAdminTokendefault = Error;
1215
+ const GetTenant200 = Tenant;
1216
+ const GetTenantdefault = Error;
1217
+ const UpdateSelectedTenantRequestJson = TenantInput;
1218
+ const UpdateSelectedTenant200 = Tenant;
1219
+ const UpdateSelectedTenantdefault = Error;
1220
+ const ListTenantTokensParams = Schema.Struct({
1221
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1222
+ "cursor": Schema.optionalKey(Schema.String),
1223
+ "name": Schema.optionalKey(Schema.String),
1224
+ "scope": Schema.optionalKey(Scope),
1225
+ "revoked": Schema.optionalKey(Schema.Literals([
1226
+ "active",
1227
+ "revoked",
1228
+ "all"
1229
+ ]).annotate({ "default": "all" }))
1230
+ });
1231
+ const ListTenantTokens200 = TokenPage;
1232
+ const ListTenantTokensdefault = Error;
1233
+ const CreateTenantTokenRequestJson = CreateTenantTokenInput;
1234
+ const CreateTenantToken201 = CreateTokenResponse;
1235
+ const CreateTenantTokendefault = Error;
1236
+ const RevokeTenantTokendefault = Error;
1237
+ const ListSessionsParams = Schema.Struct({
1238
+ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7),
1239
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1240
+ "cursor": Schema.optionalKey(Schema.String),
1241
+ "includeDeleted": Schema.optionalKey(Schema.Boolean.annotate({ "default": false })),
1242
+ "status": Schema.optionalKey(SessionStatus),
1243
+ "tagKey": Schema.optionalKey(Schema.Array(Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })))),
1244
+ "tagValue": Schema.optionalKey(Schema.Array(Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })))),
1245
+ "tagOperator": Schema.optionalKey(Schema.Array(Schema.Literals([
1246
+ "eq",
1247
+ "neq",
1248
+ "in",
1249
+ "not_in"
1250
+ ])))
1251
+ });
1252
+ const ListSessions200 = SessionPage;
1253
+ const ListSessionsdefault = Error;
1254
+ const CreateSessionParams = Schema.Struct({
1255
+ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7),
1256
+ "waitForReady": Schema.optionalKey(Schema.Boolean.annotate({ "default": true }))
1257
+ });
1258
+ const CreateSessionRequestJson = CreateSessionInput;
1259
+ const CreateSession201 = CreateSessionResult;
1260
+ const CreateSessiondefault = Error;
1261
+ const GetSessionsBulkParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1262
+ const GetSessionsBulkRequestJson = SessionBulkInput;
1263
+ const GetSessionsBulk200 = SessionBulkResponse;
1264
+ const GetSessionsBulkdefault = Error;
1265
+ const GetSessionParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1266
+ const GetSession200 = Session;
1267
+ const GetSessiondefault = Error;
1268
+ const DeleteSessionParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1269
+ const DeleteSession200 = SessionMutation;
1270
+ const DeleteSessiondefault = Error;
1271
+ const ReplaceSessionTagsParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1272
+ const ReplaceSessionTagsRequestJson = ReplaceTagsInput;
1273
+ const ReplaceSessionTags200 = SessionMutation;
1274
+ const ReplaceSessionTagsdefault = Error;
1275
+ const UpdateSessionProxyParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1276
+ const UpdateSessionProxyRequestJson = UpdateProxyAssignment;
1277
+ const UpdateSessionProxy200 = SessionMutation;
1278
+ const UpdateSessionProxydefault = Error;
1279
+ const SuspendSessionParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1280
+ const SuspendSession200 = SessionMutation;
1281
+ const SuspendSessiondefault = Error;
1282
+ const ReopenSessionParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1283
+ const ReopenSession200 = SessionMutation;
1284
+ const ReopenSessiondefault = Error;
1285
+ const RotateSessionTokenParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1286
+ const RotateSessionToken200 = SessionMutation;
1287
+ const RotateSessionTokendefault = Error;
1288
+ const RotateCollaborationCapabilityParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1289
+ const RotateCollaborationCapability200 = SessionMutation;
1290
+ const RotateCollaborationCapabilitydefault = Error;
1291
+ const GetSessionCursorParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1292
+ const GetSessionCursor200 = CursorVisibility;
1293
+ const GetSessionCursordefault = Error;
1294
+ const SetSessionCursorParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1295
+ const SetSessionCursorRequestJson = CursorVisibility;
1296
+ const SetSessionCursor200 = CursorVisibility;
1297
+ const SetSessionCursordefault = Error;
1298
+ const ListSessionRecordingsParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1299
+ const ListSessionRecordings200 = Schema.Array(Recording);
1300
+ const ListSessionRecordingsdefault = Error;
1301
+ const CreateSessionRecordingParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1302
+ const CreateSessionRecordingRequestJson = CreateSessionRecordingInput;
1303
+ const CreateSessionRecording201 = Recording;
1304
+ const CreateSessionRecordingdefault = Error;
1305
+ const GetSessionRecordingParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1306
+ const GetSessionRecording200 = Recording;
1307
+ const GetSessionRecordingdefault = Error;
1308
+ const RetargetSessionRecordingParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1309
+ const RetargetSessionRecordingRequestJson = RetargetSessionRecordingInput;
1310
+ const RetargetSessionRecording200 = Recording;
1311
+ const RetargetSessionRecordingdefault = Error;
1312
+ const StopSessionRecordingParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1313
+ const StopSessionRecording200 = SessionFile;
1314
+ const StopSessionRecordingdefault = Error;
1315
+ const CreateSessionFileDownloadURLParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1316
+ const CreateSessionFileDownloadURLRequestJson = SessionFileDownloadURLInput;
1317
+ const CreateSessionFileDownloadURL200 = SessionFileDownloadURL;
1318
+ const CreateSessionFileDownloadURLdefault = Error;
1319
+ const PromoteSessionParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1320
+ const PromoteSessionRequestJson = PromoteSessionInput;
1321
+ const PromoteSession200 = SnapshotMutation;
1322
+ const PromoteSessiondefault = Error;
1323
+ const ListSnapshotsParams = Schema.Struct({
1324
+ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7),
1325
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1326
+ "cursor": Schema.optionalKey(Schema.String),
1327
+ "name": Schema.optionalKey(Schema.String),
1328
+ "deleted": Schema.optionalKey(Schema.Literals([
1329
+ "active",
1330
+ "deleted",
1331
+ "all"
1332
+ ]).annotate({ "default": "active" })),
1333
+ "includeDeleted": Schema.optionalKey(Schema.Boolean.annotate({ "default": false })),
1334
+ "tagKey": Schema.optionalKey(Schema.Array(Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })))),
1335
+ "tagValue": Schema.optionalKey(Schema.Array(Schema.String.check(Schema.isMinLength(1).annotate({ "expected": "a value with a length of at least 1" })))),
1336
+ "tagOperator": Schema.optionalKey(Schema.Array(Schema.Literals([
1337
+ "eq",
1338
+ "neq",
1339
+ "in",
1340
+ "not_in"
1341
+ ])))
1342
+ });
1343
+ const ListSnapshots200 = SnapshotPage;
1344
+ const ListSnapshotsdefault = Error;
1345
+ const DeleteSnapshotParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1346
+ const DeleteSnapshot200 = SnapshotMutation;
1347
+ const DeleteSnapshotdefault = Error;
1348
+ const UpdateSnapshotParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1349
+ const UpdateSnapshotRequestJson = UpdateSnapshotInput;
1350
+ const UpdateSnapshot200 = SnapshotMutation;
1351
+ const UpdateSnapshotdefault = Error;
1352
+ const ReplaceSnapshotTagsParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1353
+ const ReplaceSnapshotTagsRequestJson = ReplaceTagsInput;
1354
+ const ReplaceSnapshotTags200 = SnapshotMutation;
1355
+ const ReplaceSnapshotTagsdefault = Error;
1356
+ const RestoreSnapshotParams = Schema.Struct({ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7) });
1357
+ const RestoreSnapshot200 = SnapshotMutation;
1358
+ const RestoreSnapshotdefault = Error;
1359
+ const ListEventsParams = Schema.Struct({
1360
+ "X-Aperture-Tenant-Id": Schema.optionalKey(UUIDv7),
1361
+ "limit": Schema.optionalKey(Schema.Number.annotate({ "default": 50 }).check(Schema.isInt().annotate({ "expected": "an integer" })).check(Schema.isGreaterThanOrEqualTo(0).annotate({ "expected": "a value greater than or equal to 0" }))),
1362
+ "cursor": Schema.optionalKey(Schema.String),
1363
+ "resourceType": Schema.optionalKey(Schema.String),
1364
+ "resourceId": Schema.optionalKey(Schema.String)
1365
+ });
1366
+ const ListEvents200 = EventPage;
1367
+ const ListEventsdefault = Error;
1368
+ const make = (httpClient, options = {}) => {
1369
+ const unexpectedStatus = (response) => Effect.flatMap(Effect.orElseSucceed(response.json, () => "Unexpected status code"), (description) => Effect.fail(new HttpClientError.HttpClientError({ reason: new HttpClientError.StatusCodeError({
1370
+ request: response.request,
1371
+ response,
1372
+ description: typeof description === "string" ? description : JSON.stringify(description)
1373
+ }) })));
1374
+ const withResponse = (config) => (f) => {
1375
+ const withOptionalResponse = config?.includeResponse ? (response) => Effect.map(f(response), (a) => [a, response]) : (response) => f(response);
1376
+ return options?.transformClient ? (request) => Effect.flatMap(Effect.flatMap(options.transformClient(httpClient), (client) => client.execute(request)), withOptionalResponse) : (request) => Effect.flatMap(httpClient.execute(request), withOptionalResponse);
1377
+ };
1378
+ const __encodePathParam = encodeURIComponent;
1379
+ const __makePathRequest = (method, parameters, getPath) => Effect.suspend(() => {
1380
+ const fail = (description, cause) => Effect.fail(new HttpClientError.HttpClientError({ reason: new HttpClientError.InvalidUrlError({
1381
+ request: method(""),
1382
+ cause,
1383
+ description
1384
+ }) }));
1385
+ if (parameters.some((value) => value === "" || /^(?:\.|%2e){1,2}$/i.test(value))) return fail("Path parameters must be non-empty and cannot be dot segments");
1386
+ let path;
1387
+ try {
1388
+ path = getPath();
1389
+ } catch (cause) {
1390
+ return fail("Failed to encode path parameter", cause);
1391
+ }
1392
+ if (path.split("/").some((segment) => /^(?:\.|%2e){1,2}$/i.test(segment))) return fail("Request paths cannot contain dot segments");
1393
+ return Effect.succeed(method(path));
1394
+ });
1395
+ const decodeSuccess = (schema) => (response) => HttpClientResponse.schemaBodyJson(schema)(response);
1396
+ return {
1397
+ httpClient,
1398
+ "getHealth": (options) => HttpClientRequest.get("/api/health").pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1399
+ "2xx": decodeSuccess(GetHealth200),
1400
+ orElse: unexpectedStatus
1401
+ }))),
1402
+ "getCurrentPrincipal": (options) => HttpClientRequest.get("/api/auth/me").pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1403
+ "2xx": decodeSuccess(GetCurrentPrincipal200),
1404
+ orElse: unexpectedStatus
1405
+ }))),
1406
+ "listBrowserChannels": (options) => HttpClientRequest.get("/api/browser/channels").pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1407
+ "2xx": decodeSuccess(ListBrowserChannels200),
1408
+ orElse: unexpectedStatus
1409
+ }))),
1410
+ "listTenants": (options) => HttpClientRequest.get("/api/admin/tenants").pipe(HttpClientRequest.setUrlParams({
1411
+ "limit": options?.params?.["limit"],
1412
+ "cursor": options?.params?.["cursor"],
1413
+ "deleted": options?.params?.["deleted"],
1414
+ "includeDeleted": options?.params?.["includeDeleted"]
1415
+ }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1416
+ "2xx": decodeSuccess(ListTenants200),
1417
+ orElse: unexpectedStatus
1418
+ }))),
1419
+ "createTenant": (options) => HttpClientRequest.post("/api/admin/tenants").pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1420
+ "2xx": decodeSuccess(CreateTenant201),
1421
+ orElse: unexpectedStatus
1422
+ }))),
1423
+ "deleteTenant": (tenantId, options) => __makePathRequest(HttpClientRequest.delete, [tenantId], () => "/api/admin/tenants/" + __encodePathParam(tenantId)).pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1424
+ "2xx": decodeSuccess(DeleteTenant200),
1425
+ orElse: unexpectedStatus
1426
+ }))))),
1427
+ "updateTenant": (tenantId, options) => __makePathRequest(HttpClientRequest.patch, [tenantId], () => "/api/admin/tenants/" + __encodePathParam(tenantId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1428
+ "2xx": decodeSuccess(UpdateTenant200),
1429
+ orElse: unexpectedStatus
1430
+ }))))),
1431
+ "restoreTenant": (tenantId, options) => __makePathRequest(HttpClientRequest.post, [tenantId], () => "/api/admin/tenants/" + __encodePathParam(tenantId) + "/restore").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1432
+ "2xx": decodeSuccess(RestoreTenant200),
1433
+ orElse: unexpectedStatus
1434
+ }))))),
1435
+ "listUsers": (options) => HttpClientRequest.get("/api/admin/users").pipe(HttpClientRequest.setUrlParams({
1436
+ "limit": options?.params?.["limit"],
1437
+ "cursor": options?.params?.["cursor"],
1438
+ "query": options?.params?.["query"],
1439
+ "disabled": options?.params?.["disabled"]
1440
+ }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1441
+ "2xx": decodeSuccess(ListUsers200),
1442
+ orElse: unexpectedStatus
1443
+ }))),
1444
+ "createUser": (options) => HttpClientRequest.post("/api/admin/users").pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1445
+ "2xx": decodeSuccess(CreateUser201),
1446
+ orElse: unexpectedStatus
1447
+ }))),
1448
+ "getUser": (userId, options) => __makePathRequest(HttpClientRequest.get, [userId], () => "/api/admin/users/" + __encodePathParam(userId)).pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1449
+ "2xx": decodeSuccess(GetUser200),
1450
+ orElse: unexpectedStatus
1451
+ }))))),
1452
+ "disableUser": (userId, options) => __makePathRequest(HttpClientRequest.delete, [userId], () => "/api/admin/users/" + __encodePathParam(userId)).pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1453
+ "2xx": decodeSuccess(DisableUser200),
1454
+ orElse: unexpectedStatus
1455
+ }))))),
1456
+ "updateUser": (userId, options) => __makePathRequest(HttpClientRequest.patch, [userId], () => "/api/admin/users/" + __encodePathParam(userId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1457
+ "2xx": decodeSuccess(UpdateUser200),
1458
+ orElse: unexpectedStatus
1459
+ }))))),
1460
+ "restoreUser": (userId, options) => __makePathRequest(HttpClientRequest.post, [userId], () => "/api/admin/users/" + __encodePathParam(userId) + "/restore").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1461
+ "2xx": decodeSuccess(RestoreUser200),
1462
+ orElse: unexpectedStatus
1463
+ }))))),
1464
+ "createUserInvitation": (userId, options) => __makePathRequest(HttpClientRequest.post, [userId], () => "/api/admin/users/" + __encodePathParam(userId) + "/invitation").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1465
+ "2xx": decodeSuccess(CreateUserInvitation201),
1466
+ orElse: unexpectedStatus
1467
+ }))))),
1468
+ "listUserMemberships": (userId, options) => __makePathRequest(HttpClientRequest.get, [userId], () => "/api/admin/users/" + __encodePathParam(userId) + "/memberships").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1469
+ "2xx": decodeSuccess(ListUserMemberships200),
1470
+ orElse: unexpectedStatus
1471
+ }))))),
1472
+ "listTenantMemberships": (tenantId, options) => __makePathRequest(HttpClientRequest.get, [tenantId], () => "/api/admin/tenants/" + __encodePathParam(tenantId) + "/memberships").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1473
+ "2xx": decodeSuccess(ListTenantMemberships200),
1474
+ orElse: unexpectedStatus
1475
+ }))))),
1476
+ "upsertTenantMembership": (tenantId, userId, options) => __makePathRequest(HttpClientRequest.put, [tenantId, userId], () => "/api/admin/tenants/" + __encodePathParam(tenantId) + "/memberships/" + __encodePathParam(userId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1477
+ "2xx": decodeSuccess(UpsertTenantMembership200),
1478
+ orElse: unexpectedStatus
1479
+ }))))),
1480
+ "deleteTenantMembership": (tenantId, userId, options) => __makePathRequest(HttpClientRequest.delete, [tenantId, userId], () => "/api/admin/tenants/" + __encodePathParam(tenantId) + "/memberships/" + __encodePathParam(userId)).pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1481
+ "2xx": decodeSuccess(DeleteTenantMembershipdefault),
1482
+ "204": () => Effect.void,
1483
+ orElse: unexpectedStatus
1484
+ }))))),
1485
+ "listAuditEvents": (options) => HttpClientRequest.get("/api/admin/audit-events").pipe(HttpClientRequest.setUrlParams({
1486
+ "limit": options?.params?.["limit"],
1487
+ "cursor": options?.params?.["cursor"],
1488
+ "tenantId": options?.params?.["tenantId"],
1489
+ "actorType": options?.params?.["actorType"],
1490
+ "actorId": options?.params?.["actorId"],
1491
+ "action": options?.params?.["action"],
1492
+ "resourceType": options?.params?.["resourceType"],
1493
+ "resourceId": options?.params?.["resourceId"]
1494
+ }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1495
+ "2xx": decodeSuccess(ListAuditEvents200),
1496
+ orElse: unexpectedStatus
1497
+ }))),
1498
+ "listAdminTokens": (options) => HttpClientRequest.get("/api/admin/tokens").pipe(HttpClientRequest.setUrlParams({
1499
+ "limit": options?.params?.["limit"],
1500
+ "cursor": options?.params?.["cursor"],
1501
+ "authorityType": options?.params?.["authorityType"],
1502
+ "tenantId": options?.params?.["tenantId"],
1503
+ "name": options?.params?.["name"],
1504
+ "scope": options?.params?.["scope"],
1505
+ "revoked": options?.params?.["revoked"]
1506
+ }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1507
+ "2xx": decodeSuccess(ListAdminTokens200),
1508
+ orElse: unexpectedStatus
1509
+ }))),
1510
+ "createAdminToken": (options) => HttpClientRequest.post("/api/admin/tokens").pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1511
+ "2xx": decodeSuccess(CreateAdminToken201),
1512
+ orElse: unexpectedStatus
1513
+ }))),
1514
+ "revokeAdminToken": (tokenId, options) => __makePathRequest(HttpClientRequest.post, [tokenId], () => "/api/admin/tokens/" + __encodePathParam(tokenId) + "/revoke").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1515
+ "2xx": decodeSuccess(RevokeAdminTokendefault),
1516
+ "204": () => Effect.void,
1517
+ orElse: unexpectedStatus
1518
+ }))))),
1519
+ "getTenant": (options) => HttpClientRequest.get("/api/tenant").pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1520
+ "2xx": decodeSuccess(GetTenant200),
1521
+ orElse: unexpectedStatus
1522
+ }))),
1523
+ "updateSelectedTenant": (options) => HttpClientRequest.patch("/api/tenant").pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1524
+ "2xx": decodeSuccess(UpdateSelectedTenant200),
1525
+ orElse: unexpectedStatus
1526
+ }))),
1527
+ "listTenantTokens": (options) => HttpClientRequest.get("/api/tenant/tokens").pipe(HttpClientRequest.setUrlParams({
1528
+ "limit": options?.params?.["limit"],
1529
+ "cursor": options?.params?.["cursor"],
1530
+ "name": options?.params?.["name"],
1531
+ "scope": options?.params?.["scope"],
1532
+ "revoked": options?.params?.["revoked"]
1533
+ }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1534
+ "2xx": decodeSuccess(ListTenantTokens200),
1535
+ orElse: unexpectedStatus
1536
+ }))),
1537
+ "createTenantToken": (options) => HttpClientRequest.post("/api/tenant/tokens").pipe(HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1538
+ "2xx": decodeSuccess(CreateTenantToken201),
1539
+ orElse: unexpectedStatus
1540
+ }))),
1541
+ "revokeTenantToken": (tokenId, options) => __makePathRequest(HttpClientRequest.post, [tokenId], () => "/api/tenant/tokens/" + __encodePathParam(tokenId) + "/revoke").pipe(Effect.flatMap((request) => request.pipe(withResponse(options?.config)(HttpClientResponse.matchStatus({
1542
+ "2xx": decodeSuccess(RevokeTenantTokendefault),
1543
+ "204": () => Effect.void,
1544
+ orElse: unexpectedStatus
1545
+ }))))),
1546
+ "listSessions": (options) => HttpClientRequest.get("/api/sessions").pipe(HttpClientRequest.setUrlParams({
1547
+ "limit": options?.params?.["limit"],
1548
+ "cursor": options?.params?.["cursor"],
1549
+ "includeDeleted": options?.params?.["includeDeleted"],
1550
+ "status": options?.params?.["status"],
1551
+ "tagKey": options?.params?.["tagKey"],
1552
+ "tagValue": options?.params?.["tagValue"],
1553
+ "tagOperator": options?.params?.["tagOperator"]
1554
+ }), HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1555
+ "2xx": decodeSuccess(ListSessions200),
1556
+ orElse: unexpectedStatus
1557
+ }))),
1558
+ "createSession": (options) => HttpClientRequest.post("/api/sessions").pipe(HttpClientRequest.setUrlParams({ "waitForReady": options.params?.["waitForReady"] }), HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1559
+ "2xx": decodeSuccess(CreateSession201),
1560
+ orElse: unexpectedStatus
1561
+ }))),
1562
+ "getSessionsBulk": (options) => HttpClientRequest.post("/api/sessions/bulk").pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1563
+ "2xx": decodeSuccess(GetSessionsBulk200),
1564
+ orElse: unexpectedStatus
1565
+ }))),
1566
+ "getSession": (sessionId, options) => __makePathRequest(HttpClientRequest.get, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1567
+ "2xx": decodeSuccess(GetSession200),
1568
+ orElse: unexpectedStatus
1569
+ }))))),
1570
+ "deleteSession": (sessionId, options) => __makePathRequest(HttpClientRequest.delete, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1571
+ "2xx": decodeSuccess(DeleteSession200),
1572
+ orElse: unexpectedStatus
1573
+ }))))),
1574
+ "replaceSessionTags": (sessionId, options) => __makePathRequest(HttpClientRequest.put, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/tags").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1575
+ "2xx": decodeSuccess(ReplaceSessionTags200),
1576
+ orElse: unexpectedStatus
1577
+ }))))),
1578
+ "updateSessionProxy": (sessionId, options) => __makePathRequest(HttpClientRequest.put, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/proxy").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1579
+ "2xx": decodeSuccess(UpdateSessionProxy200),
1580
+ orElse: unexpectedStatus
1581
+ }))))),
1582
+ "suspendSession": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/suspend").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1583
+ "2xx": decodeSuccess(SuspendSession200),
1584
+ orElse: unexpectedStatus
1585
+ }))))),
1586
+ "reopenSession": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/reopen").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1587
+ "2xx": decodeSuccess(ReopenSession200),
1588
+ orElse: unexpectedStatus
1589
+ }))))),
1590
+ "rotateSessionToken": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/session-token/rotate").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1591
+ "2xx": decodeSuccess(RotateSessionToken200),
1592
+ orElse: unexpectedStatus
1593
+ }))))),
1594
+ "rotateCollaborationCapability": (sessionId, role, options) => __makePathRequest(HttpClientRequest.post, [sessionId, role], () => "/api/sessions/" + __encodePathParam(sessionId) + "/collaboration-capabilities/" + __encodePathParam(role) + "/rotate").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1595
+ "2xx": decodeSuccess(RotateCollaborationCapability200),
1596
+ orElse: unexpectedStatus
1597
+ }))))),
1598
+ "getSessionCursor": (sessionId, options) => __makePathRequest(HttpClientRequest.get, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/cursor").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1599
+ "2xx": decodeSuccess(GetSessionCursor200),
1600
+ orElse: unexpectedStatus
1601
+ }))))),
1602
+ "setSessionCursor": (sessionId, options) => __makePathRequest(HttpClientRequest.put, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/cursor").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1603
+ "2xx": decodeSuccess(SetSessionCursor200),
1604
+ orElse: unexpectedStatus
1605
+ }))))),
1606
+ "listSessionRecordings": (sessionId, options) => __makePathRequest(HttpClientRequest.get, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/recordings").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1607
+ "2xx": decodeSuccess(ListSessionRecordings200),
1608
+ orElse: unexpectedStatus
1609
+ }))))),
1610
+ "createSessionRecording": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/recordings").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1611
+ "2xx": decodeSuccess(CreateSessionRecording201),
1612
+ orElse: unexpectedStatus
1613
+ }))))),
1614
+ "getSessionRecording": (sessionId, recordingId, options) => __makePathRequest(HttpClientRequest.get, [sessionId, recordingId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/recordings/" + __encodePathParam(recordingId)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1615
+ "2xx": decodeSuccess(GetSessionRecording200),
1616
+ orElse: unexpectedStatus
1617
+ }))))),
1618
+ "retargetSessionRecording": (sessionId, recordingId, options) => __makePathRequest(HttpClientRequest.post, [sessionId, recordingId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/recordings/" + __encodePathParam(recordingId) + "/retarget").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1619
+ "2xx": decodeSuccess(RetargetSessionRecording200),
1620
+ orElse: unexpectedStatus
1621
+ }))))),
1622
+ "stopSessionRecording": (sessionId, recordingId, options) => __makePathRequest(HttpClientRequest.post, [sessionId, recordingId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/recordings/" + __encodePathParam(recordingId) + "/stop").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1623
+ "2xx": decodeSuccess(StopSessionRecording200),
1624
+ orElse: unexpectedStatus
1625
+ }))))),
1626
+ "createSessionFileDownloadURL": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/files/download-url").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1627
+ "2xx": decodeSuccess(CreateSessionFileDownloadURL200),
1628
+ orElse: unexpectedStatus
1629
+ }))))),
1630
+ "promoteSession": (sessionId, options) => __makePathRequest(HttpClientRequest.post, [sessionId], () => "/api/sessions/" + __encodePathParam(sessionId) + "/promote").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1631
+ "2xx": decodeSuccess(PromoteSession200),
1632
+ orElse: unexpectedStatus
1633
+ }))))),
1634
+ "listSnapshots": (options) => HttpClientRequest.get("/api/snapshots").pipe(HttpClientRequest.setUrlParams({
1635
+ "limit": options?.params?.["limit"],
1636
+ "cursor": options?.params?.["cursor"],
1637
+ "name": options?.params?.["name"],
1638
+ "deleted": options?.params?.["deleted"],
1639
+ "includeDeleted": options?.params?.["includeDeleted"],
1640
+ "tagKey": options?.params?.["tagKey"],
1641
+ "tagValue": options?.params?.["tagValue"],
1642
+ "tagOperator": options?.params?.["tagOperator"]
1643
+ }), HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1644
+ "2xx": decodeSuccess(ListSnapshots200),
1645
+ orElse: unexpectedStatus
1646
+ }))),
1647
+ "deleteSnapshot": (name, options) => __makePathRequest(HttpClientRequest.delete, [name], () => "/api/snapshots/" + __encodePathParam(name)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1648
+ "2xx": decodeSuccess(DeleteSnapshot200),
1649
+ orElse: unexpectedStatus
1650
+ }))))),
1651
+ "updateSnapshot": (name, options) => __makePathRequest(HttpClientRequest.patch, [name], () => "/api/snapshots/" + __encodePathParam(name)).pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1652
+ "2xx": decodeSuccess(UpdateSnapshot200),
1653
+ orElse: unexpectedStatus
1654
+ }))))),
1655
+ "replaceSnapshotTags": (name, options) => __makePathRequest(HttpClientRequest.put, [name], () => "/api/snapshots/" + __encodePathParam(name) + "/tags").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), HttpClientRequest.bodyJsonUnsafe(options.payload), withResponse(options.config)(HttpClientResponse.matchStatus({
1656
+ "2xx": decodeSuccess(ReplaceSnapshotTags200),
1657
+ orElse: unexpectedStatus
1658
+ }))))),
1659
+ "restoreSnapshot": (name, options) => __makePathRequest(HttpClientRequest.post, [name], () => "/api/snapshots/" + __encodePathParam(name) + "/restore").pipe(Effect.flatMap((request) => request.pipe(HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1660
+ "2xx": decodeSuccess(RestoreSnapshot200),
1661
+ orElse: unexpectedStatus
1662
+ }))))),
1663
+ "listEvents": (options) => HttpClientRequest.get("/api/events").pipe(HttpClientRequest.setUrlParams({
1664
+ "limit": options?.params?.["limit"],
1665
+ "cursor": options?.params?.["cursor"],
1666
+ "resourceType": options?.params?.["resourceType"],
1667
+ "resourceId": options?.params?.["resourceId"]
1668
+ }), HttpClientRequest.setHeaders({ "X-Aperture-Tenant-Id": options?.params?.["X-Aperture-Tenant-Id"] ?? void 0 }), withResponse(options?.config)(HttpClientResponse.matchStatus({
1669
+ "2xx": decodeSuccess(ListEvents200),
1670
+ orElse: unexpectedStatus
1671
+ })))
1672
+ };
1673
+ };
1674
+ var ApertureApiErrorImpl = class extends Data.Error {};
1675
+ const ApertureApiError = (tag, cause, response) => new ApertureApiErrorImpl({
1676
+ _tag: tag,
1677
+ cause,
1678
+ response,
1679
+ request: response.request
1680
+ });
1681
+ //#endregion
1682
+ export { ApertureApiError, AuditEvent, AuditEventPage, AuthMe, AuthorityType, BrowserChannel, BrowserChannels, BrowserConfig, BrowserCookieSameSite, BrowserStorageEntry, CreateAdminToken201, CreateAdminTokenInput, CreateAdminTokenRequestJson, CreateAdminTokendefault, CreateSession201, CreateSessionFileDownloadURL200, CreateSessionFileDownloadURLParams, CreateSessionFileDownloadURLRequestJson, CreateSessionFileDownloadURLdefault, CreateSessionInput, CreateSessionParams, CreateSessionRecording201, CreateSessionRecordingInput, CreateSessionRecordingParams, CreateSessionRecordingRequestJson, CreateSessionRecordingdefault, CreateSessionRequestJson, CreateSessionResult, CreateSessiondefault, CreateTenant201, CreateTenantRequestJson, CreateTenantToken201, CreateTenantTokenInput, CreateTenantTokenRequestJson, CreateTenantTokendefault, CreateTenantdefault, CreateTokenResponse, CreateUser201, CreateUserInvitation201, CreateUserInvitationdefault, CreateUserRequestJson, CreateUserdefault, CursorVisibility, DeleteSession200, DeleteSessionParams, DeleteSessiondefault, DeleteSnapshot200, DeleteSnapshotParams, DeleteSnapshotdefault, DeleteTenant200, DeleteTenantMembershipdefault, DeleteTenantdefault, DisableUser200, DisableUserdefault, Error, ErrorDetail, Event, EventPage, GetCurrentPrincipal200, GetCurrentPrincipalParams, GetCurrentPrincipaldefault, GetHealth200, GetSession200, GetSessionCursor200, GetSessionCursorParams, GetSessionCursordefault, GetSessionParams, GetSessionRecording200, GetSessionRecordingParams, GetSessionRecordingdefault, GetSessiondefault, GetSessionsBulk200, GetSessionsBulkParams, GetSessionsBulkRequestJson, GetSessionsBulkdefault, GetTenant200, GetTenantdefault, GetUser200, GetUserdefault, Health, IceServer, InitialBrowserContentEditableState, InitialBrowserControlSelection, InitialBrowserControlState, InitialBrowserCookie, InitialBrowserCookiePartitionKey, InitialBrowserDocumentSelection, InitialBrowserDocumentState, InitialBrowserElementLocator, InitialBrowserElementPathStep, InitialBrowserElementScrollPosition, InitialBrowserScrollPosition, InitialBrowserSelectionEndpoint, InitialBrowserStorageState, InitialBrowserTarget, InitialCacheStorageCache, InitialCacheStorageEntry, InitialIndexedDBDatabase, InitialIndexedDBIndex, InitialIndexedDBIndexKeyPath, InitialIndexedDBKeyPath, InitialIndexedDBObjectStore, InitialIndexedDBRecord, InitialOPFSFile, InitialStorageOrigin, InitialTargetStorageOrigin, ListAdminTokens200, ListAdminTokensParams, ListAdminTokensdefault, ListAuditEvents200, ListAuditEventsParams, ListAuditEventsdefault, ListBrowserChannels200, ListBrowserChannelsdefault, ListEvents200, ListEventsParams, ListEventsdefault, ListSessionRecordings200, ListSessionRecordingsParams, ListSessionRecordingsdefault, ListSessions200, ListSessionsParams, ListSessionsdefault, ListSnapshots200, ListSnapshotsParams, ListSnapshotsdefault, ListTenantMemberships200, ListTenantMembershipsdefault, ListTenantTokens200, ListTenantTokensParams, ListTenantTokensdefault, ListTenants200, ListTenantsParams, ListTenantsdefault, ListUserMemberships200, ListUserMembershipsdefault, ListUsers200, ListUsersParams, ListUsersdefault, PageMeta, Principal, PrincipalType, PromoteSession200, PromoteSessionInput, PromoteSessionParams, PromoteSessionRequestJson, PromoteSessiondefault, ProxyConfig, ProxyTunnelConfig, Recording, ReopenSession200, ReopenSessionParams, ReopenSessiondefault, ReplaceSessionTags200, ReplaceSessionTagsParams, ReplaceSessionTagsRequestJson, ReplaceSessionTagsdefault, ReplaceSnapshotTags200, ReplaceSnapshotTagsParams, ReplaceSnapshotTagsRequestJson, ReplaceSnapshotTagsdefault, ReplaceTagsInput, ResourceGrant, ResourceMode, ResourceType, RestoreSnapshot200, RestoreSnapshotParams, RestoreSnapshotdefault, RestoreTenant200, RestoreTenantdefault, RestoreUser200, RestoreUserdefault, RetargetSessionRecording200, RetargetSessionRecordingInput, RetargetSessionRecordingParams, RetargetSessionRecordingRequestJson, RetargetSessionRecordingdefault, RevokeAdminTokendefault, RevokeTenantTokendefault, RotateCollaborationCapability200, RotateCollaborationCapabilityParams, RotateCollaborationCapabilitydefault, RotateSessionToken200, RotateSessionTokenParams, RotateSessionTokendefault, Scope, Session, SessionBulkInput, SessionBulkResponse, SessionCollaborationCapabilities, SessionFile, SessionFileDownloadURL, SessionFileDownloadURLInput, SessionMedia, SessionMutation, SessionPage, SessionProxy, SessionStatus, SetSessionCursor200, SetSessionCursorParams, SetSessionCursorRequestJson, SetSessionCursordefault, Snapshot, SnapshotMutation, SnapshotPage, StopSessionRecording200, StopSessionRecordingParams, StopSessionRecordingdefault, StringMap, SuspendSession200, SuspendSessionParams, SuspendSessiondefault, Tenant, TenantInput, TenantMembership, TenantMembershipInput, TenantPage, TenantScope, Token, TokenPage, UUIDv7, UpdateProxyAssignment, UpdateSelectedTenant200, UpdateSelectedTenantRequestJson, UpdateSelectedTenantdefault, UpdateSessionProxy200, UpdateSessionProxyParams, UpdateSessionProxyRequestJson, UpdateSessionProxydefault, UpdateSnapshot200, UpdateSnapshotInput, UpdateSnapshotParams, UpdateSnapshotRequestJson, UpdateSnapshotdefault, UpdateTenant200, UpdateTenantRequestJson, UpdateTenantdefault, UpdateUser200, UpdateUserRequestJson, UpdateUserdefault, UpsertTenantMembership200, UpsertTenantMembershipRequestJson, UpsertTenantMembershipdefault, User, UserInput, UserInvitation, UserPage, make };
1683
+
1684
+ //# sourceMappingURL=index.js.map