@aperture-browser/executor-client 0.0.0-init.0 → 0.0.0-nightly.150.87635522cd00

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.
@@ -0,0 +1,1514 @@
1
+ import { GenEnum, GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
2
+ import { Duration, Timestamp } from "@bufbuild/protobuf/wkt";
3
+ import * as Schema from "effect/Schema";
4
+ import * as Context from "effect/Context";
5
+ import * as Effect from "effect/Effect";
6
+ import * as Layer from "effect/Layer";
7
+ import * as Stream from "effect/Stream";
8
+ import { Message, MessageInitShape } from "@bufbuild/protobuf";
9
+
10
+ //#region src/gen/aperture/executor/v1/executor_pb.d.ts
11
+ declare namespace executor_pb_d_exports {
12
+ export { CreateSessionRequest, CreateSessionRequestSchema, CreateSessionResponse, CreateSessionResponseSchema, CreateSnapshotRequest, CreateSnapshotRequestSchema, CreateSnapshotResponse, CreateSnapshotResponseSchema, DeleteSessionRequest, DeleteSessionRequestSchema, DeleteSessionResponse, DeleteSessionResponseSchema, DeleteSnapshotRequest, DeleteSnapshotRequestSchema, DeleteSnapshotResponse, DeleteSnapshotResponseSchema, Dns, DnsRecord, DnsRecordSchema, DnsSchema, Endpoints, EndpointsSchema, EvictSessionRequest, EvictSessionRequestSchema, EvictSessionResponse, EvictSessionResponseSchema, Executor$1 as Executor, ExecutorSchema, ExecutorService, Feature, FeatureSchema, Features, FeaturesSchema, GetExecutorRequest, GetExecutorRequestSchema, GetExecutorResponse, GetExecutorResponseSchema, GetSessionRequest, GetSessionRequestSchema, GetSessionResponse, GetSessionResponseSchema, GetSnapshotRequest, GetSnapshotRequestSchema, GetSnapshotResponse, GetSnapshotResponseSchema, Limits, LimitsSchema, ListSessionsRequest, ListSessionsRequestSchema, ListSessionsResponse, ListSessionsResponseSchema, ListSnapshotsRequest, ListSnapshotsRequestSchema, ListSnapshotsResponse, ListSnapshotsResponseSchema, ListStoredSessionsRequest, ListStoredSessionsRequestSchema, ListStoredSessionsResponse, ListStoredSessionsResponseSchema, Network, NetworkSchema, NetworkTcp, NetworkTcpSchema, NetworkUdp, NetworkUdpSchema, ProxyConfig, ProxyConfigSchema, ProxyRule, ProxyRuleSchema, ProxyUpstream, ProxyUpstreamSchema, ResumeSessionRequest, ResumeSessionRequestSchema, ResumeSessionResponse, ResumeSessionResponseSchema, Session, SessionSchema, SessionState, SessionStateSchema, Snapshot, SnapshotSchema, StoredSession, StoredSessionSchema, SuspendSessionRequest, SuspendSessionRequestSchema, SuspendSessionResponse, SuspendSessionResponseSchema, UpdateSessionProxyRequest, UpdateSessionProxyRequestSchema, UpdateSessionProxyResponse, UpdateSessionProxyResponseSchema, Usage, UsageSchema, WatchSessionsRequest, WatchSessionsRequestSchema, WatchSessionsResponse, WatchSessionsResponseSchema, file_aperture_executor_v1_executor };
13
+ }
14
+ /**
15
+ * Describes the file aperture/executor/v1/executor.proto.
16
+ */
17
+ declare const file_aperture_executor_v1_executor: GenFile;
18
+ /**
19
+ * @generated from message aperture.executor.v1.Executor
20
+ */
21
+ type Executor$1 = Message<"aperture.executor.v1.Executor"> & {
22
+ /**
23
+ * @generated from field: string version = 1;
24
+ */
25
+ version: string;
26
+ /**
27
+ * What its sessions offer unless they say otherwise, and the most one may offer.
28
+ *
29
+ * @generated from field: repeated aperture.executor.v1.Feature features = 2;
30
+ */
31
+ features: Feature[];
32
+ /**
33
+ * The network its sessions' browsers have unless they say otherwise, and the most one
34
+ * may have.
35
+ *
36
+ * @generated from field: aperture.executor.v1.Network network = 3;
37
+ */
38
+ network?: Network | undefined;
39
+ /**
40
+ * The limits of a session that has none of its own.
41
+ *
42
+ * @generated from field: aperture.executor.v1.Limits limits = 4;
43
+ */
44
+ limits?: Limits | undefined;
45
+ /**
46
+ * Whether it holds sessions to limits on what they use, and counts what they use.
47
+ *
48
+ * @generated from field: bool holds_resources = 5;
49
+ */
50
+ holdsResources: boolean;
51
+ /**
52
+ * Whether its snapshots are kept where other nodes find them: a session is created
53
+ * from one of them on any node that names the same place.
54
+ *
55
+ * @generated from field: bool shares_snapshots = 6;
56
+ */
57
+ sharesSnapshots: boolean;
58
+ };
59
+ /**
60
+ * Describes the message aperture.executor.v1.Executor.
61
+ * Use `create(ExecutorSchema)` to create a new message.
62
+ */
63
+ declare const ExecutorSchema: GenMessage<Executor$1>;
64
+ /**
65
+ * @generated from message aperture.executor.v1.GetExecutorRequest
66
+ */
67
+ type GetExecutorRequest = Message<"aperture.executor.v1.GetExecutorRequest"> & {};
68
+ /**
69
+ * Describes the message aperture.executor.v1.GetExecutorRequest.
70
+ * Use `create(GetExecutorRequestSchema)` to create a new message.
71
+ */
72
+ declare const GetExecutorRequestSchema: GenMessage<GetExecutorRequest>;
73
+ /**
74
+ * @generated from message aperture.executor.v1.GetExecutorResponse
75
+ */
76
+ type GetExecutorResponse = Message<"aperture.executor.v1.GetExecutorResponse"> & {
77
+ /**
78
+ * @generated from field: aperture.executor.v1.Executor executor = 1;
79
+ */
80
+ executor?: Executor$1 | undefined;
81
+ };
82
+ /**
83
+ * Describes the message aperture.executor.v1.GetExecutorResponse.
84
+ * Use `create(GetExecutorResponseSchema)` to create a new message.
85
+ */
86
+ declare const GetExecutorResponseSchema: GenMessage<GetExecutorResponse>;
87
+ /**
88
+ * @generated from message aperture.executor.v1.Features
89
+ */
90
+ type Features = Message<"aperture.executor.v1.Features"> & {
91
+ /**
92
+ * @generated from field: repeated aperture.executor.v1.Feature on = 1;
93
+ */
94
+ on: Feature[];
95
+ };
96
+ /**
97
+ * Describes the message aperture.executor.v1.Features.
98
+ * Use `create(FeaturesSchema)` to create a new message.
99
+ */
100
+ declare const FeaturesSchema: GenMessage<Features>;
101
+ /**
102
+ * @generated from message aperture.executor.v1.Network
103
+ */
104
+ type Network = Message<"aperture.executor.v1.Network"> & {
105
+ /**
106
+ * @generated from field: aperture.executor.v1.NetworkTcp tcp = 1;
107
+ */
108
+ tcp: NetworkTcp;
109
+ /**
110
+ * @generated from field: aperture.executor.v1.NetworkUdp udp = 2;
111
+ */
112
+ udp: NetworkUdp;
113
+ };
114
+ /**
115
+ * Describes the message aperture.executor.v1.Network.
116
+ * Use `create(NetworkSchema)` to create a new message.
117
+ */
118
+ declare const NetworkSchema: GenMessage<Network>;
119
+ /**
120
+ * @generated from message aperture.executor.v1.Session
121
+ */
122
+ type Session = Message<"aperture.executor.v1.Session"> & {
123
+ /**
124
+ * @generated from field: string id = 1;
125
+ */
126
+ id: string;
127
+ /**
128
+ * @generated from field: aperture.executor.v1.SessionState state = 2;
129
+ */
130
+ state: SessionState;
131
+ /**
132
+ * The snapshot the session was created from.
133
+ *
134
+ * @generated from field: optional string snapshot_id = 3;
135
+ */
136
+ snapshotId?: string | undefined;
137
+ /**
138
+ * @generated from field: google.protobuf.Timestamp created_at = 4;
139
+ */
140
+ createdAt?: Timestamp | undefined;
141
+ /**
142
+ * Set while the session is running.
143
+ *
144
+ * @generated from field: optional aperture.executor.v1.Endpoints endpoints = 5;
145
+ */
146
+ endpoints?: Endpoints | undefined;
147
+ /**
148
+ * @generated from field: optional string failure = 6;
149
+ */
150
+ failure?: string | undefined;
151
+ /**
152
+ * The limits the session is held to: its own where it has them, the executor's where it
153
+ * does not. One that is left out is not held.
154
+ *
155
+ * @generated from field: aperture.executor.v1.Limits limits = 7;
156
+ */
157
+ limits?: Limits | undefined;
158
+ /**
159
+ * What the session uses, while it runs on an executor that counts it.
160
+ *
161
+ * @generated from field: optional aperture.executor.v1.Usage usage = 8;
162
+ */
163
+ usage?: Usage | undefined;
164
+ /**
165
+ * Since when nobody uses the session, while it runs and nobody does: no client is
166
+ * connected to it, and this is when the last one left or the last request for it came.
167
+ *
168
+ * @generated from field: optional google.protobuf.Timestamp idle_since = 9;
169
+ */
170
+ idleSince?: Timestamp | undefined;
171
+ /**
172
+ * The session was suspended for sitting idle. It is resumed when someone reaches it:
173
+ * on any of its endpoints, which answer once it runs. A session that was suspended on
174
+ * request is not.
175
+ *
176
+ * @generated from field: bool asleep = 10;
177
+ */
178
+ asleep: boolean;
179
+ /**
180
+ * What the session offers when it runs.
181
+ *
182
+ * @generated from field: repeated aperture.executor.v1.Feature features = 11;
183
+ */
184
+ features: Feature[];
185
+ /**
186
+ * The network its browser has when it runs.
187
+ *
188
+ * @generated from field: aperture.executor.v1.Network network = 12;
189
+ */
190
+ network?: Network | undefined;
191
+ };
192
+ /**
193
+ * Describes the message aperture.executor.v1.Session.
194
+ * Use `create(SessionSchema)` to create a new message.
195
+ */
196
+ declare const SessionSchema: GenMessage<Session>;
197
+ /**
198
+ * What a session may use, and how long it may sit idle. Resources are held only by an
199
+ * executor that has a control group of its own to divide.
200
+ *
201
+ * @generated from message aperture.executor.v1.Limits
202
+ */
203
+ type Limits = Message<"aperture.executor.v1.Limits"> & {
204
+ /**
205
+ * Bytes of memory. A session that needs more loses a process, most likely a tab.
206
+ *
207
+ * @generated from field: optional uint64 memory_bytes = 1;
208
+ */
209
+ memoryBytes?: bigint | undefined;
210
+ /**
211
+ * Bytes of swap a session with a memory limit may use on top of it. It may use none
212
+ * unless this says so; a session without a memory limit swaps as the node lets it.
213
+ *
214
+ * @generated from field: optional uint64 swap_bytes = 5;
215
+ */
216
+ swapBytes?: bigint | undefined;
217
+ /**
218
+ * Processors' worth of time: 1.5 is a processor and a half.
219
+ *
220
+ * @generated from field: optional double cpus = 2;
221
+ */
222
+ cpus?: number | undefined;
223
+ /**
224
+ * Processes and threads.
225
+ *
226
+ * @generated from field: optional uint64 tasks = 3;
227
+ */
228
+ tasks?: bigint | undefined;
229
+ /**
230
+ * How long nobody may use the session before the executor suspends it, to resume it
231
+ * when someone reaches it again. A session that records, edits a recording or
232
+ * downloads is in use.
233
+ *
234
+ * @generated from field: optional google.protobuf.Duration suspend_idle_after = 4;
235
+ */
236
+ suspendIdleAfter?: Duration | undefined;
237
+ };
238
+ /**
239
+ * Describes the message aperture.executor.v1.Limits.
240
+ * Use `create(LimitsSchema)` to create a new message.
241
+ */
242
+ declare const LimitsSchema: GenMessage<Limits>;
243
+ /**
244
+ * @generated from message aperture.executor.v1.Usage
245
+ */
246
+ type Usage = Message<"aperture.executor.v1.Usage"> & {
247
+ /**
248
+ * @generated from field: uint64 memory_bytes = 1;
249
+ */
250
+ memoryBytes: bigint;
251
+ /**
252
+ * The most it used since it was started.
253
+ *
254
+ * @generated from field: uint64 memory_peak_bytes = 2;
255
+ */
256
+ memoryPeakBytes: bigint;
257
+ /**
258
+ * Processor time since it was started.
259
+ *
260
+ * @generated from field: google.protobuf.Duration cpu_time = 3;
261
+ */
262
+ cpuTime?: Duration | undefined;
263
+ /**
264
+ * @generated from field: uint64 tasks = 4;
265
+ */
266
+ tasks: bigint;
267
+ /**
268
+ * Processes the session lost to its memory limit since it was started.
269
+ *
270
+ * @generated from field: uint64 oom_kills = 5;
271
+ */
272
+ oomKills: bigint;
273
+ };
274
+ /**
275
+ * Describes the message aperture.executor.v1.Usage.
276
+ * Use `create(UsageSchema)` to create a new message.
277
+ */
278
+ declare const UsageSchema: GenMessage<Usage>;
279
+ /**
280
+ * Where a running session is reached: the executor's paths of it.
281
+ *
282
+ * @generated from message aperture.executor.v1.Endpoints
283
+ */
284
+ type Endpoints = Message<"aperture.executor.v1.Endpoints"> & {
285
+ /**
286
+ * The browser's CDP WebSocket. `<cdp_path>/json/version` and the other discovery routes
287
+ * are below it.
288
+ *
289
+ * @generated from field: string cdp_path = 1;
290
+ */
291
+ cdpPath: string;
292
+ /**
293
+ * The session itself, whose own routes are below it: `<path>/ws` is the session socket,
294
+ * which carries `aperture.live.v1`, `<path>/targets/<id>/screenshot.png` is a browser
295
+ * target as it looks now, `<path>/files/...` are its files, and `<path>/` is a page that
296
+ * shows the session, unless the executor leaves that out.
297
+ *
298
+ * @generated from field: string path = 2;
299
+ */
300
+ path: string;
301
+ /**
302
+ * The session's automation, an MCP server over Streamable HTTP.
303
+ *
304
+ * @generated from field: string mcp_path = 3;
305
+ */
306
+ mcpPath: string;
307
+ /**
308
+ * Where a client attaches the session's local tunnel: a WebSocket with the subprotocol
309
+ * `aperture-tunnel.v1`, whose binary messages carry yamux; the session opens a stream
310
+ * for every connection its rules route `via: local` and asks on it, as a SOCKS5 client,
311
+ * for the connection to be made on the client's machine.
312
+ *
313
+ * @generated from field: string tunnel_path = 4;
314
+ */
315
+ tunnelPath: string;
316
+ };
317
+ /**
318
+ * Describes the message aperture.executor.v1.Endpoints.
319
+ * Use `create(EndpointsSchema)` to create a new message.
320
+ */
321
+ declare const EndpointsSchema: GenMessage<Endpoints>;
322
+ /**
323
+ * How a session's browser connections are routed. The first rule that matches a
324
+ * connection decides; one no rule matches is made from the node.
325
+ *
326
+ * @generated from message aperture.executor.v1.ProxyConfig
327
+ */
328
+ type ProxyConfig = Message<"aperture.executor.v1.ProxyConfig"> & {
329
+ /**
330
+ * The upstreams rules can route through, by name.
331
+ *
332
+ * @generated from field: map<string, aperture.executor.v1.ProxyUpstream> upstreams = 1;
333
+ */
334
+ upstreams: {
335
+ [key: string]: ProxyUpstream;
336
+ };
337
+ /**
338
+ * @generated from field: repeated aperture.executor.v1.ProxyRule rules = 2;
339
+ */
340
+ rules: ProxyRule[];
341
+ /**
342
+ * How the session resolves names. Left out, it asks the node's own resolvers.
343
+ *
344
+ * @generated from field: optional aperture.executor.v1.Dns dns = 3;
345
+ */
346
+ dns?: Dns | undefined;
347
+ };
348
+ /**
349
+ * Describes the message aperture.executor.v1.ProxyConfig.
350
+ * Use `create(ProxyConfigSchema)` to create a new message.
351
+ */
352
+ declare const ProxyConfigSchema: GenMessage<ProxyConfig>;
353
+ /**
354
+ * For the names the session resolves itself: those of connections made from its node, and
355
+ * those its browser asks for when it has a network of its own. A proxy or a tunnel
356
+ * resolves what goes through it.
357
+ *
358
+ * @generated from message aperture.executor.v1.Dns
359
+ */
360
+ type Dns = Message<"aperture.executor.v1.Dns"> & {
361
+ /**
362
+ * The addresses of the resolvers to ask; the node's own when there are none.
363
+ *
364
+ * @generated from field: repeated string servers = 1;
365
+ */
366
+ servers: string[];
367
+ /**
368
+ * The first record that covers a name gives its addresses.
369
+ *
370
+ * @generated from field: repeated aperture.executor.v1.DnsRecord records = 2;
371
+ */
372
+ records: DnsRecord[];
373
+ };
374
+ /**
375
+ * Describes the message aperture.executor.v1.Dns.
376
+ * Use `create(DnsSchema)` to create a new message.
377
+ */
378
+ declare const DnsSchema: GenMessage<Dns>;
379
+ /**
380
+ * @generated from message aperture.executor.v1.DnsRecord
381
+ */
382
+ type DnsRecord = Message<"aperture.executor.v1.DnsRecord"> & {
383
+ /**
384
+ * A name as in a rule's match: exact, `*.suffix` or `*`.
385
+ *
386
+ * @generated from field: string name = 1;
387
+ */
388
+ name: string;
389
+ /**
390
+ * @generated from field: repeated string addresses = 2;
391
+ */
392
+ addresses: string[];
393
+ };
394
+ /**
395
+ * Describes the message aperture.executor.v1.DnsRecord.
396
+ * Use `create(DnsRecordSchema)` to create a new message.
397
+ */
398
+ declare const DnsRecordSchema: GenMessage<DnsRecord>;
399
+ /**
400
+ * @generated from message aperture.executor.v1.ProxyUpstream
401
+ */
402
+ type ProxyUpstream = Message<"aperture.executor.v1.ProxyUpstream"> & {
403
+ /**
404
+ * A proxy, with its credentials in the URL (`socks5://`, `http://`, `https://`), or a
405
+ * tunnel the session dials (`ws+yamux+socks5://`, `wss+yamux+socks5://`).
406
+ *
407
+ * @generated from field: string url = 1;
408
+ */
409
+ url: string;
410
+ /**
411
+ * The secret a tunnel is dialed with. Required for a tunnel, and only for one.
412
+ *
413
+ * @generated from field: optional string auth = 2;
414
+ */
415
+ auth?: string | undefined;
416
+ };
417
+ /**
418
+ * Describes the message aperture.executor.v1.ProxyUpstream.
419
+ * Use `create(ProxyUpstreamSchema)` to create a new message.
420
+ */
421
+ declare const ProxyUpstreamSchema: GenMessage<ProxyUpstream>;
422
+ /**
423
+ * @generated from message aperture.executor.v1.ProxyRule
424
+ */
425
+ type ProxyRule = Message<"aperture.executor.v1.ProxyRule"> & {
426
+ /**
427
+ * `host` or `host:port`; the host is exact, `*.suffix` for subdomains, `*` for any host
428
+ * but localhost, an address, or a network (`10.0.0.0/8`) for the addresses in it. What
429
+ * is IPv6 takes a port in brackets: `[::1]:443`.
430
+ *
431
+ * @generated from field: string match = 1;
432
+ */
433
+ match: string;
434
+ /**
435
+ * `direct`, `refuse`, `local` (the tunnel a client attached), an upstream's name, or a
436
+ * proxy's URL.
437
+ *
438
+ * @generated from field: string via = 2;
439
+ */
440
+ via: string;
441
+ /**
442
+ * `host` or `host:port`: where the connections are made instead of where the browser
443
+ * named.
444
+ *
445
+ * @generated from field: optional string to = 3;
446
+ */
447
+ to?: string | undefined;
448
+ /**
449
+ * The session answers the browser's TLS itself, with a certificate of its own that the
450
+ * session's browser takes for the name, and passes on what is inside: a server that
451
+ * speaks no TLS is `https://` to the session's pages. Such a rule is for port 443 unless
452
+ * its match names another.
453
+ *
454
+ * @generated from field: bool tls = 4;
455
+ */
456
+ tls: boolean;
457
+ };
458
+ /**
459
+ * Describes the message aperture.executor.v1.ProxyRule.
460
+ * Use `create(ProxyRuleSchema)` to create a new message.
461
+ */
462
+ declare const ProxyRuleSchema: GenMessage<ProxyRule>;
463
+ /**
464
+ * @generated from message aperture.executor.v1.Snapshot
465
+ */
466
+ type Snapshot = Message<"aperture.executor.v1.Snapshot"> & {
467
+ /**
468
+ * @generated from field: string id = 1;
469
+ */
470
+ id: string;
471
+ /**
472
+ * @generated from field: optional string name = 2;
473
+ */
474
+ name?: string | undefined;
475
+ /**
476
+ * The session it was taken of.
477
+ *
478
+ * @generated from field: string session_id = 3;
479
+ */
480
+ sessionId: string;
481
+ /**
482
+ * @generated from field: google.protobuf.Timestamp created_at = 4;
483
+ */
484
+ createdAt?: Timestamp | undefined;
485
+ };
486
+ /**
487
+ * Describes the message aperture.executor.v1.Snapshot.
488
+ * Use `create(SnapshotSchema)` to create a new message.
489
+ */
490
+ declare const SnapshotSchema: GenMessage<Snapshot>;
491
+ /**
492
+ * @generated from message aperture.executor.v1.CreateSessionRequest
493
+ */
494
+ type CreateSessionRequest = Message<"aperture.executor.v1.CreateSessionRequest"> & {
495
+ /**
496
+ * @generated from field: optional string snapshot_id = 1;
497
+ */
498
+ snapshotId?: string | undefined;
499
+ /**
500
+ * Create the session without starting its browser.
501
+ *
502
+ * @generated from field: bool suspended = 2;
503
+ */
504
+ suspended: boolean;
505
+ /**
506
+ * @generated from field: optional aperture.executor.v1.ProxyConfig proxy = 3;
507
+ */
508
+ proxy?: ProxyConfig | undefined;
509
+ /**
510
+ * The session's own limits. One that is left out is the executor's; zero is none, also
511
+ * where the executor has one.
512
+ *
513
+ * @generated from field: aperture.executor.v1.Limits limits = 4;
514
+ */
515
+ limits?: Limits | undefined;
516
+ /**
517
+ * What the session offers: these and nothing else. Left out, all that the executor
518
+ * lets sessions offer. One the executor does not let sessions offer is refused.
519
+ *
520
+ * @generated from field: optional aperture.executor.v1.Features features = 5;
521
+ */
522
+ features?: Features | undefined;
523
+ /**
524
+ * The network the session's browser has. What is left unspecified is as the executor
525
+ * has it; `direct` where the executor has it otherwise is refused.
526
+ *
527
+ * @generated from field: aperture.executor.v1.Network network = 6;
528
+ */
529
+ network?: Network | undefined;
530
+ /**
531
+ * Cookies and the storage of origins for the session's browser to start with, over
532
+ * what its snapshot has: the JSON a session's `storage-state` route gives. Not for a
533
+ * session that is created suspended. A session that does not take it is not created.
534
+ *
535
+ * @generated from field: optional string storage_state = 7;
536
+ */
537
+ storageState?: string | undefined;
538
+ };
539
+ /**
540
+ * Describes the message aperture.executor.v1.CreateSessionRequest.
541
+ * Use `create(CreateSessionRequestSchema)` to create a new message.
542
+ */
543
+ declare const CreateSessionRequestSchema: GenMessage<CreateSessionRequest>;
544
+ /**
545
+ * @generated from message aperture.executor.v1.CreateSessionResponse
546
+ */
547
+ type CreateSessionResponse = Message<"aperture.executor.v1.CreateSessionResponse"> & {
548
+ /**
549
+ * @generated from field: aperture.executor.v1.Session session = 1;
550
+ */
551
+ session?: Session | undefined;
552
+ };
553
+ /**
554
+ * Describes the message aperture.executor.v1.CreateSessionResponse.
555
+ * Use `create(CreateSessionResponseSchema)` to create a new message.
556
+ */
557
+ declare const CreateSessionResponseSchema: GenMessage<CreateSessionResponse>;
558
+ /**
559
+ * @generated from message aperture.executor.v1.GetSessionRequest
560
+ */
561
+ type GetSessionRequest = Message<"aperture.executor.v1.GetSessionRequest"> & {
562
+ /**
563
+ * @generated from field: string id = 1;
564
+ */
565
+ id: string;
566
+ };
567
+ /**
568
+ * Describes the message aperture.executor.v1.GetSessionRequest.
569
+ * Use `create(GetSessionRequestSchema)` to create a new message.
570
+ */
571
+ declare const GetSessionRequestSchema: GenMessage<GetSessionRequest>;
572
+ /**
573
+ * @generated from message aperture.executor.v1.GetSessionResponse
574
+ */
575
+ type GetSessionResponse = Message<"aperture.executor.v1.GetSessionResponse"> & {
576
+ /**
577
+ * @generated from field: aperture.executor.v1.Session session = 1;
578
+ */
579
+ session?: Session | undefined;
580
+ };
581
+ /**
582
+ * Describes the message aperture.executor.v1.GetSessionResponse.
583
+ * Use `create(GetSessionResponseSchema)` to create a new message.
584
+ */
585
+ declare const GetSessionResponseSchema: GenMessage<GetSessionResponse>;
586
+ /**
587
+ * @generated from message aperture.executor.v1.ListSessionsRequest
588
+ */
589
+ type ListSessionsRequest = Message<"aperture.executor.v1.ListSessionsRequest"> & {};
590
+ /**
591
+ * Describes the message aperture.executor.v1.ListSessionsRequest.
592
+ * Use `create(ListSessionsRequestSchema)` to create a new message.
593
+ */
594
+ declare const ListSessionsRequestSchema: GenMessage<ListSessionsRequest>;
595
+ /**
596
+ * @generated from message aperture.executor.v1.ListSessionsResponse
597
+ */
598
+ type ListSessionsResponse = Message<"aperture.executor.v1.ListSessionsResponse"> & {
599
+ /**
600
+ * @generated from field: repeated aperture.executor.v1.Session sessions = 1;
601
+ */
602
+ sessions: Session[];
603
+ };
604
+ /**
605
+ * Describes the message aperture.executor.v1.ListSessionsResponse.
606
+ * Use `create(ListSessionsResponseSchema)` to create a new message.
607
+ */
608
+ declare const ListSessionsResponseSchema: GenMessage<ListSessionsResponse>;
609
+ /**
610
+ * @generated from message aperture.executor.v1.SuspendSessionRequest
611
+ */
612
+ type SuspendSessionRequest = Message<"aperture.executor.v1.SuspendSessionRequest"> & {
613
+ /**
614
+ * @generated from field: string id = 1;
615
+ */
616
+ id: string;
617
+ };
618
+ /**
619
+ * Describes the message aperture.executor.v1.SuspendSessionRequest.
620
+ * Use `create(SuspendSessionRequestSchema)` to create a new message.
621
+ */
622
+ declare const SuspendSessionRequestSchema: GenMessage<SuspendSessionRequest>;
623
+ /**
624
+ * @generated from message aperture.executor.v1.SuspendSessionResponse
625
+ */
626
+ type SuspendSessionResponse = Message<"aperture.executor.v1.SuspendSessionResponse"> & {
627
+ /**
628
+ * @generated from field: aperture.executor.v1.Session session = 1;
629
+ */
630
+ session?: Session | undefined;
631
+ };
632
+ /**
633
+ * Describes the message aperture.executor.v1.SuspendSessionResponse.
634
+ * Use `create(SuspendSessionResponseSchema)` to create a new message.
635
+ */
636
+ declare const SuspendSessionResponseSchema: GenMessage<SuspendSessionResponse>;
637
+ /**
638
+ * @generated from message aperture.executor.v1.ResumeSessionRequest
639
+ */
640
+ type ResumeSessionRequest = Message<"aperture.executor.v1.ResumeSessionRequest"> & {
641
+ /**
642
+ * @generated from field: string id = 1;
643
+ */
644
+ id: string;
645
+ /**
646
+ * Resume the session although another node says it has it, for a node that died with
647
+ * the session on it: the session is as it was last suspended. Only executors that say
648
+ * which sessions they have refuse one for that.
649
+ *
650
+ * @generated from field: bool takeover = 2;
651
+ */
652
+ takeover: boolean;
653
+ };
654
+ /**
655
+ * Describes the message aperture.executor.v1.ResumeSessionRequest.
656
+ * Use `create(ResumeSessionRequestSchema)` to create a new message.
657
+ */
658
+ declare const ResumeSessionRequestSchema: GenMessage<ResumeSessionRequest>;
659
+ /**
660
+ * @generated from message aperture.executor.v1.ResumeSessionResponse
661
+ */
662
+ type ResumeSessionResponse = Message<"aperture.executor.v1.ResumeSessionResponse"> & {
663
+ /**
664
+ * @generated from field: aperture.executor.v1.Session session = 1;
665
+ */
666
+ session?: Session | undefined;
667
+ };
668
+ /**
669
+ * Describes the message aperture.executor.v1.ResumeSessionResponse.
670
+ * Use `create(ResumeSessionResponseSchema)` to create a new message.
671
+ */
672
+ declare const ResumeSessionResponseSchema: GenMessage<ResumeSessionResponse>;
673
+ /**
674
+ * @generated from message aperture.executor.v1.UpdateSessionProxyRequest
675
+ */
676
+ type UpdateSessionProxyRequest = Message<"aperture.executor.v1.UpdateSessionProxyRequest"> & {
677
+ /**
678
+ * @generated from field: string id = 1;
679
+ */
680
+ id: string;
681
+ /**
682
+ * Left out, everything goes direct again.
683
+ *
684
+ * @generated from field: optional aperture.executor.v1.ProxyConfig proxy = 2;
685
+ */
686
+ proxy?: ProxyConfig | undefined;
687
+ };
688
+ /**
689
+ * Describes the message aperture.executor.v1.UpdateSessionProxyRequest.
690
+ * Use `create(UpdateSessionProxyRequestSchema)` to create a new message.
691
+ */
692
+ declare const UpdateSessionProxyRequestSchema: GenMessage<UpdateSessionProxyRequest>;
693
+ /**
694
+ * @generated from message aperture.executor.v1.UpdateSessionProxyResponse
695
+ */
696
+ type UpdateSessionProxyResponse = Message<"aperture.executor.v1.UpdateSessionProxyResponse"> & {};
697
+ /**
698
+ * Describes the message aperture.executor.v1.UpdateSessionProxyResponse.
699
+ * Use `create(UpdateSessionProxyResponseSchema)` to create a new message.
700
+ */
701
+ declare const UpdateSessionProxyResponseSchema: GenMessage<UpdateSessionProxyResponse>;
702
+ /**
703
+ * @generated from message aperture.executor.v1.DeleteSessionRequest
704
+ */
705
+ type DeleteSessionRequest = Message<"aperture.executor.v1.DeleteSessionRequest"> & {
706
+ /**
707
+ * @generated from field: string id = 1;
708
+ */
709
+ id: string;
710
+ };
711
+ /**
712
+ * Describes the message aperture.executor.v1.DeleteSessionRequest.
713
+ * Use `create(DeleteSessionRequestSchema)` to create a new message.
714
+ */
715
+ declare const DeleteSessionRequestSchema: GenMessage<DeleteSessionRequest>;
716
+ /**
717
+ * @generated from message aperture.executor.v1.DeleteSessionResponse
718
+ */
719
+ type DeleteSessionResponse = Message<"aperture.executor.v1.DeleteSessionResponse"> & {};
720
+ /**
721
+ * Describes the message aperture.executor.v1.DeleteSessionResponse.
722
+ * Use `create(DeleteSessionResponseSchema)` to create a new message.
723
+ */
724
+ declare const DeleteSessionResponseSchema: GenMessage<DeleteSessionResponse>;
725
+ /**
726
+ * @generated from message aperture.executor.v1.WatchSessionsRequest
727
+ */
728
+ type WatchSessionsRequest = Message<"aperture.executor.v1.WatchSessionsRequest"> & {};
729
+ /**
730
+ * Describes the message aperture.executor.v1.WatchSessionsRequest.
731
+ * Use `create(WatchSessionsRequestSchema)` to create a new message.
732
+ */
733
+ declare const WatchSessionsRequestSchema: GenMessage<WatchSessionsRequest>;
734
+ /**
735
+ * @generated from message aperture.executor.v1.WatchSessionsResponse
736
+ */
737
+ type WatchSessionsResponse = Message<"aperture.executor.v1.WatchSessionsResponse"> & {
738
+ /**
739
+ * @generated from oneof aperture.executor.v1.WatchSessionsResponse.event
740
+ */
741
+ event: {
742
+ /**
743
+ * A session as it is now: one there was when the watching began, a new one, or one
744
+ * that changed.
745
+ *
746
+ * @generated from field: aperture.executor.v1.Session session = 1;
747
+ */
748
+ value: Session;
749
+ case: "session";
750
+ } | {
751
+ /**
752
+ * The id of a session this node has no more: deleted, or evicted.
753
+ *
754
+ * @generated from field: string gone = 2;
755
+ */
756
+ value: string;
757
+ case: "gone";
758
+ } | {
759
+ case: undefined;
760
+ value?: undefined;
761
+ };
762
+ };
763
+ /**
764
+ * Describes the message aperture.executor.v1.WatchSessionsResponse.
765
+ * Use `create(WatchSessionsResponseSchema)` to create a new message.
766
+ */
767
+ declare const WatchSessionsResponseSchema: GenMessage<WatchSessionsResponse>;
768
+ /**
769
+ * @generated from message aperture.executor.v1.EvictSessionRequest
770
+ */
771
+ type EvictSessionRequest = Message<"aperture.executor.v1.EvictSessionRequest"> & {
772
+ /**
773
+ * @generated from field: string id = 1;
774
+ */
775
+ id: string;
776
+ };
777
+ /**
778
+ * Describes the message aperture.executor.v1.EvictSessionRequest.
779
+ * Use `create(EvictSessionRequestSchema)` to create a new message.
780
+ */
781
+ declare const EvictSessionRequestSchema: GenMessage<EvictSessionRequest>;
782
+ /**
783
+ * @generated from message aperture.executor.v1.EvictSessionResponse
784
+ */
785
+ type EvictSessionResponse = Message<"aperture.executor.v1.EvictSessionResponse"> & {};
786
+ /**
787
+ * Describes the message aperture.executor.v1.EvictSessionResponse.
788
+ * Use `create(EvictSessionResponseSchema)` to create a new message.
789
+ */
790
+ declare const EvictSessionResponseSchema: GenMessage<EvictSessionResponse>;
791
+ /**
792
+ * @generated from message aperture.executor.v1.ListStoredSessionsRequest
793
+ */
794
+ type ListStoredSessionsRequest = Message<"aperture.executor.v1.ListStoredSessionsRequest"> & {};
795
+ /**
796
+ * Describes the message aperture.executor.v1.ListStoredSessionsRequest.
797
+ * Use `create(ListStoredSessionsRequestSchema)` to create a new message.
798
+ */
799
+ declare const ListStoredSessionsRequestSchema: GenMessage<ListStoredSessionsRequest>;
800
+ /**
801
+ * @generated from message aperture.executor.v1.ListStoredSessionsResponse
802
+ */
803
+ type ListStoredSessionsResponse = Message<"aperture.executor.v1.ListStoredSessionsResponse"> & {
804
+ /**
805
+ * @generated from field: repeated aperture.executor.v1.StoredSession sessions = 1;
806
+ */
807
+ sessions: StoredSession[];
808
+ };
809
+ /**
810
+ * Describes the message aperture.executor.v1.ListStoredSessionsResponse.
811
+ * Use `create(ListStoredSessionsResponseSchema)` to create a new message.
812
+ */
813
+ declare const ListStoredSessionsResponseSchema: GenMessage<ListStoredSessionsResponse>;
814
+ /**
815
+ * A session as it is where nodes share sessions.
816
+ *
817
+ * @generated from message aperture.executor.v1.StoredSession
818
+ */
819
+ type StoredSession = Message<"aperture.executor.v1.StoredSession"> & {
820
+ /**
821
+ * @generated from field: string id = 1;
822
+ */
823
+ id: string;
824
+ /**
825
+ * @generated from field: optional string snapshot_id = 2;
826
+ */
827
+ snapshotId?: string | undefined;
828
+ /**
829
+ * @generated from field: google.protobuf.Timestamp created_at = 3;
830
+ */
831
+ createdAt?: Timestamp | undefined;
832
+ /**
833
+ * The node that says it has the session, where nodes say so and one does.
834
+ *
835
+ * @generated from field: optional string held_by = 4;
836
+ */
837
+ heldBy?: string | undefined;
838
+ };
839
+ /**
840
+ * Describes the message aperture.executor.v1.StoredSession.
841
+ * Use `create(StoredSessionSchema)` to create a new message.
842
+ */
843
+ declare const StoredSessionSchema: GenMessage<StoredSession>;
844
+ /**
845
+ * @generated from message aperture.executor.v1.CreateSnapshotRequest
846
+ */
847
+ type CreateSnapshotRequest = Message<"aperture.executor.v1.CreateSnapshotRequest"> & {
848
+ /**
849
+ * @generated from field: string session_id = 1;
850
+ */
851
+ sessionId: string;
852
+ /**
853
+ * @generated from field: optional string name = 2;
854
+ */
855
+ name?: string | undefined;
856
+ };
857
+ /**
858
+ * Describes the message aperture.executor.v1.CreateSnapshotRequest.
859
+ * Use `create(CreateSnapshotRequestSchema)` to create a new message.
860
+ */
861
+ declare const CreateSnapshotRequestSchema: GenMessage<CreateSnapshotRequest>;
862
+ /**
863
+ * @generated from message aperture.executor.v1.CreateSnapshotResponse
864
+ */
865
+ type CreateSnapshotResponse = Message<"aperture.executor.v1.CreateSnapshotResponse"> & {
866
+ /**
867
+ * @generated from field: aperture.executor.v1.Snapshot snapshot = 1;
868
+ */
869
+ snapshot?: Snapshot | undefined;
870
+ };
871
+ /**
872
+ * Describes the message aperture.executor.v1.CreateSnapshotResponse.
873
+ * Use `create(CreateSnapshotResponseSchema)` to create a new message.
874
+ */
875
+ declare const CreateSnapshotResponseSchema: GenMessage<CreateSnapshotResponse>;
876
+ /**
877
+ * @generated from message aperture.executor.v1.GetSnapshotRequest
878
+ */
879
+ type GetSnapshotRequest = Message<"aperture.executor.v1.GetSnapshotRequest"> & {
880
+ /**
881
+ * @generated from field: string id = 1;
882
+ */
883
+ id: string;
884
+ };
885
+ /**
886
+ * Describes the message aperture.executor.v1.GetSnapshotRequest.
887
+ * Use `create(GetSnapshotRequestSchema)` to create a new message.
888
+ */
889
+ declare const GetSnapshotRequestSchema: GenMessage<GetSnapshotRequest>;
890
+ /**
891
+ * @generated from message aperture.executor.v1.GetSnapshotResponse
892
+ */
893
+ type GetSnapshotResponse = Message<"aperture.executor.v1.GetSnapshotResponse"> & {
894
+ /**
895
+ * @generated from field: aperture.executor.v1.Snapshot snapshot = 1;
896
+ */
897
+ snapshot?: Snapshot | undefined;
898
+ };
899
+ /**
900
+ * Describes the message aperture.executor.v1.GetSnapshotResponse.
901
+ * Use `create(GetSnapshotResponseSchema)` to create a new message.
902
+ */
903
+ declare const GetSnapshotResponseSchema: GenMessage<GetSnapshotResponse>;
904
+ /**
905
+ * @generated from message aperture.executor.v1.ListSnapshotsRequest
906
+ */
907
+ type ListSnapshotsRequest = Message<"aperture.executor.v1.ListSnapshotsRequest"> & {};
908
+ /**
909
+ * Describes the message aperture.executor.v1.ListSnapshotsRequest.
910
+ * Use `create(ListSnapshotsRequestSchema)` to create a new message.
911
+ */
912
+ declare const ListSnapshotsRequestSchema: GenMessage<ListSnapshotsRequest>;
913
+ /**
914
+ * @generated from message aperture.executor.v1.ListSnapshotsResponse
915
+ */
916
+ type ListSnapshotsResponse = Message<"aperture.executor.v1.ListSnapshotsResponse"> & {
917
+ /**
918
+ * @generated from field: repeated aperture.executor.v1.Snapshot snapshots = 1;
919
+ */
920
+ snapshots: Snapshot[];
921
+ };
922
+ /**
923
+ * Describes the message aperture.executor.v1.ListSnapshotsResponse.
924
+ * Use `create(ListSnapshotsResponseSchema)` to create a new message.
925
+ */
926
+ declare const ListSnapshotsResponseSchema: GenMessage<ListSnapshotsResponse>;
927
+ /**
928
+ * @generated from message aperture.executor.v1.DeleteSnapshotRequest
929
+ */
930
+ type DeleteSnapshotRequest = Message<"aperture.executor.v1.DeleteSnapshotRequest"> & {
931
+ /**
932
+ * @generated from field: string id = 1;
933
+ */
934
+ id: string;
935
+ };
936
+ /**
937
+ * Describes the message aperture.executor.v1.DeleteSnapshotRequest.
938
+ * Use `create(DeleteSnapshotRequestSchema)` to create a new message.
939
+ */
940
+ declare const DeleteSnapshotRequestSchema: GenMessage<DeleteSnapshotRequest>;
941
+ /**
942
+ * @generated from message aperture.executor.v1.DeleteSnapshotResponse
943
+ */
944
+ type DeleteSnapshotResponse = Message<"aperture.executor.v1.DeleteSnapshotResponse"> & {};
945
+ /**
946
+ * Describes the message aperture.executor.v1.DeleteSnapshotResponse.
947
+ * Use `create(DeleteSnapshotResponseSchema)` to create a new message.
948
+ */
949
+ declare const DeleteSnapshotResponseSchema: GenMessage<DeleteSnapshotResponse>;
950
+ /**
951
+ * @generated from enum aperture.executor.v1.SessionState
952
+ */
953
+ declare enum SessionState {
954
+ /**
955
+ * @generated from enum value: SESSION_STATE_UNSPECIFIED = 0;
956
+ */
957
+ UNSPECIFIED = 0,
958
+ /**
959
+ * No browser runs; the profile is kept.
960
+ *
961
+ * @generated from enum value: SESSION_STATE_SUSPENDED = 1;
962
+ */
963
+ SUSPENDED = 1,
964
+ /**
965
+ * @generated from enum value: SESSION_STATE_STARTING = 2;
966
+ */
967
+ STARTING = 2,
968
+ /**
969
+ * @generated from enum value: SESSION_STATE_RUNNING = 3;
970
+ */
971
+ RUNNING = 3,
972
+ /**
973
+ * @generated from enum value: SESSION_STATE_SUSPENDING = 4;
974
+ */
975
+ SUSPENDING = 4,
976
+ /**
977
+ * The browser ended without being asked to; `failure` says how. The profile is kept.
978
+ *
979
+ * @generated from enum value: SESSION_STATE_FAILED = 5;
980
+ */
981
+ FAILED = 5
982
+ }
983
+ /**
984
+ * Describes the enum aperture.executor.v1.SessionState.
985
+ */
986
+ declare const SessionStateSchema: GenEnum<SessionState>;
987
+ /**
988
+ * Something a session offers besides its picture and input.
989
+ *
990
+ * @generated from enum aperture.executor.v1.Feature
991
+ */
992
+ declare enum Feature {
993
+ /**
994
+ * @generated from enum value: FEATURE_UNSPECIFIED = 0;
995
+ */
996
+ UNSPECIFIED = 0,
997
+ /**
998
+ * Its tabs are heard.
999
+ *
1000
+ * @generated from enum value: FEATURE_SOUND = 1;
1001
+ */
1002
+ SOUND = 1,
1003
+ /**
1004
+ * Clients put files into it, for pages that ask for some.
1005
+ *
1006
+ * @generated from enum value: FEATURE_UPLOADS = 2;
1007
+ */
1008
+ UPLOADS = 2,
1009
+ /**
1010
+ * Its browser downloads files.
1011
+ *
1012
+ * @generated from enum value: FEATURE_DOWNLOADS = 3;
1013
+ */
1014
+ DOWNLOADS = 3,
1015
+ /**
1016
+ * Its tabs are recorded and screenshots kept.
1017
+ *
1018
+ * @generated from enum value: FEATURE_RECORDINGS = 4;
1019
+ */
1020
+ RECORDINGS = 4,
1021
+ /**
1022
+ * What is copied passes between it and its clients.
1023
+ *
1024
+ * @generated from enum value: FEATURE_CLIPBOARD = 5;
1025
+ */
1026
+ CLIPBOARD = 5,
1027
+ /**
1028
+ * Its automation endpoint is served.
1029
+ *
1030
+ * @generated from enum value: FEATURE_MCP = 6;
1031
+ */
1032
+ MCP = 6,
1033
+ /**
1034
+ * Its browser's DevTools endpoint is served.
1035
+ *
1036
+ * @generated from enum value: FEATURE_CDP = 7;
1037
+ */
1038
+ CDP = 7,
1039
+ /**
1040
+ * Clients attach tunnels.
1041
+ *
1042
+ * @generated from enum value: FEATURE_TUNNEL = 8;
1043
+ */
1044
+ TUNNEL = 8
1045
+ }
1046
+ /**
1047
+ * Describes the enum aperture.executor.v1.Feature.
1048
+ */
1049
+ declare const FeatureSchema: GenEnum<Feature>;
1050
+ /**
1051
+ * Where the TCP of a session's browser goes.
1052
+ *
1053
+ * @generated from enum aperture.executor.v1.NetworkTcp
1054
+ */
1055
+ declare enum NetworkTcp {
1056
+ /**
1057
+ * @generated from enum value: NETWORK_TCP_UNSPECIFIED = 0;
1058
+ */
1059
+ UNSPECIFIED = 0,
1060
+ /**
1061
+ * Nowhere but through the session's proxy, which holds it to the session's rules.
1062
+ *
1063
+ * @generated from enum value: NETWORK_TCP_PROXIED = 1;
1064
+ */
1065
+ PROXIED = 1,
1066
+ /**
1067
+ * Out as well: pages still load through the proxy, but nothing holds the browser to it,
1068
+ * and what goes around it reaches the node's network too.
1069
+ *
1070
+ * @generated from enum value: NETWORK_TCP_DIRECT = 2;
1071
+ */
1072
+ DIRECT = 2
1073
+ }
1074
+ /**
1075
+ * Describes the enum aperture.executor.v1.NetworkTcp.
1076
+ */
1077
+ declare const NetworkTcpSchema: GenEnum<NetworkTcp>;
1078
+ /**
1079
+ * Where the UDP of a session's browser goes, which a proxy does not carry.
1080
+ *
1081
+ * @generated from enum aperture.executor.v1.NetworkUdp
1082
+ */
1083
+ declare enum NetworkUdp {
1084
+ /**
1085
+ * @generated from enum value: NETWORK_UDP_UNSPECIFIED = 0;
1086
+ */
1087
+ UNSPECIFIED = 0,
1088
+ /**
1089
+ * Nowhere: WebRTC has no way out.
1090
+ *
1091
+ * @generated from enum value: NETWORK_UDP_NONE = 1;
1092
+ */
1093
+ NONE = 1,
1094
+ /**
1095
+ * Out, held to nothing, the node's network included.
1096
+ *
1097
+ * @generated from enum value: NETWORK_UDP_DIRECT = 2;
1098
+ */
1099
+ DIRECT = 2
1100
+ }
1101
+ /**
1102
+ * Describes the enum aperture.executor.v1.NetworkUdp.
1103
+ */
1104
+ declare const NetworkUdpSchema: GenEnum<NetworkUdp>;
1105
+ /**
1106
+ * What one node does on request: browser sessions and the snapshots taken of them, on the
1107
+ * node's own storage.
1108
+ *
1109
+ * @generated from service aperture.executor.v1.ExecutorService
1110
+ */
1111
+ declare const ExecutorService: GenService<{
1112
+ /**
1113
+ * What this executor is and what its sessions may have.
1114
+ *
1115
+ * @generated from rpc aperture.executor.v1.ExecutorService.GetExecutor
1116
+ */
1117
+ getExecutor: {
1118
+ methodKind: "unary";
1119
+ input: typeof GetExecutorRequestSchema;
1120
+ output: typeof GetExecutorResponseSchema;
1121
+ };
1122
+ /**
1123
+ * Creates a session, from a snapshot or empty, and starts its browser unless asked not to.
1124
+ *
1125
+ * @generated from rpc aperture.executor.v1.ExecutorService.CreateSession
1126
+ */
1127
+ createSession: {
1128
+ methodKind: "unary";
1129
+ input: typeof CreateSessionRequestSchema;
1130
+ output: typeof CreateSessionResponseSchema;
1131
+ };
1132
+ /**
1133
+ * @generated from rpc aperture.executor.v1.ExecutorService.GetSession
1134
+ */
1135
+ getSession: {
1136
+ methodKind: "unary";
1137
+ input: typeof GetSessionRequestSchema;
1138
+ output: typeof GetSessionResponseSchema;
1139
+ };
1140
+ /**
1141
+ * @generated from rpc aperture.executor.v1.ExecutorService.ListSessions
1142
+ */
1143
+ listSessions: {
1144
+ methodKind: "unary";
1145
+ input: typeof ListSessionsRequestSchema;
1146
+ output: typeof ListSessionsResponseSchema;
1147
+ };
1148
+ /**
1149
+ * Stops the session's browser and keeps its profile.
1150
+ *
1151
+ * @generated from rpc aperture.executor.v1.ExecutorService.SuspendSession
1152
+ */
1153
+ suspendSession: {
1154
+ methodKind: "unary";
1155
+ input: typeof SuspendSessionRequestSchema;
1156
+ output: typeof SuspendSessionResponseSchema;
1157
+ };
1158
+ /**
1159
+ * Starts the browser of a suspended or failed session on the profile it left.
1160
+ *
1161
+ * @generated from rpc aperture.executor.v1.ExecutorService.ResumeSession
1162
+ */
1163
+ resumeSession: {
1164
+ methodKind: "unary";
1165
+ input: typeof ResumeSessionRequestSchema;
1166
+ output: typeof ResumeSessionResponseSchema;
1167
+ };
1168
+ /**
1169
+ * Sets how the session's browser connections are routed, for a running session at once:
1170
+ * connections made from then on go by the new rules, and open ones stay as they are.
1171
+ *
1172
+ * @generated from rpc aperture.executor.v1.ExecutorService.UpdateSessionProxy
1173
+ */
1174
+ updateSessionProxy: {
1175
+ methodKind: "unary";
1176
+ input: typeof UpdateSessionProxyRequestSchema;
1177
+ output: typeof UpdateSessionProxyResponseSchema;
1178
+ };
1179
+ /**
1180
+ * Stops the session and removes its profile and files. Snapshots taken of it stay.
1181
+ *
1182
+ * @generated from rpc aperture.executor.v1.ExecutorService.DeleteSession
1183
+ */
1184
+ deleteSession: {
1185
+ methodKind: "unary";
1186
+ input: typeof DeleteSessionRequestSchema;
1187
+ output: typeof DeleteSessionResponseSchema;
1188
+ };
1189
+ /**
1190
+ * The node's sessions as they change: each as it is now, then each again when what
1191
+ * `GetSession` tells of it becomes another, and a word of each that is gone. What a
1192
+ * session uses is not a change. It goes on until whoever watches leaves.
1193
+ *
1194
+ * @generated from rpc aperture.executor.v1.ExecutorService.WatchSessions
1195
+ */
1196
+ watchSessions: {
1197
+ methodKind: "server_streaming";
1198
+ input: typeof WatchSessionsRequestSchema;
1199
+ output: typeof WatchSessionsResponseSchema;
1200
+ };
1201
+ /**
1202
+ * Drops this node's copy of a session that is at rest where nodes share sessions: the
1203
+ * session stays there, for whichever node resumes it. Refused for a session that runs,
1204
+ * for one whose state here is not the one that is there, and on a node that shares none.
1205
+ *
1206
+ * @generated from rpc aperture.executor.v1.ExecutorService.EvictSession
1207
+ */
1208
+ evictSession: {
1209
+ methodKind: "unary";
1210
+ input: typeof EvictSessionRequestSchema;
1211
+ output: typeof EvictSessionResponseSchema;
1212
+ };
1213
+ /**
1214
+ * The sessions where nodes share them, whichever node has them or none. Refused on a
1215
+ * node that shares none.
1216
+ *
1217
+ * @generated from rpc aperture.executor.v1.ExecutorService.ListStoredSessions
1218
+ */
1219
+ listStoredSessions: {
1220
+ methodKind: "unary";
1221
+ input: typeof ListStoredSessionsRequestSchema;
1222
+ output: typeof ListStoredSessionsResponseSchema;
1223
+ };
1224
+ /**
1225
+ * Keeps the session's profile as it is now. A running session is suspended for the
1226
+ * moment it takes and resumed after.
1227
+ *
1228
+ * @generated from rpc aperture.executor.v1.ExecutorService.CreateSnapshot
1229
+ */
1230
+ createSnapshot: {
1231
+ methodKind: "unary";
1232
+ input: typeof CreateSnapshotRequestSchema;
1233
+ output: typeof CreateSnapshotResponseSchema;
1234
+ };
1235
+ /**
1236
+ * @generated from rpc aperture.executor.v1.ExecutorService.GetSnapshot
1237
+ */
1238
+ getSnapshot: {
1239
+ methodKind: "unary";
1240
+ input: typeof GetSnapshotRequestSchema;
1241
+ output: typeof GetSnapshotResponseSchema;
1242
+ };
1243
+ /**
1244
+ * @generated from rpc aperture.executor.v1.ExecutorService.ListSnapshots
1245
+ */
1246
+ listSnapshots: {
1247
+ methodKind: "unary";
1248
+ input: typeof ListSnapshotsRequestSchema;
1249
+ output: typeof ListSnapshotsResponseSchema;
1250
+ };
1251
+ /**
1252
+ * Sessions created from the snapshot keep working.
1253
+ *
1254
+ * @generated from rpc aperture.executor.v1.ExecutorService.DeleteSnapshot
1255
+ */
1256
+ deleteSnapshot: {
1257
+ methodKind: "unary";
1258
+ input: typeof DeleteSnapshotRequestSchema;
1259
+ output: typeof DeleteSnapshotResponseSchema;
1260
+ };
1261
+ }>;
1262
+ //#endregion
1263
+ //#region src/errors.d.ts
1264
+ /** A Connect error code. */
1265
+ declare const ExecutorErrorCode: Schema.Literals<readonly ["canceled", "unknown", "invalid_argument", "deadline_exceeded", "not_found", "already_exists", "permission_denied", "resource_exhausted", "failed_precondition", "aborted", "out_of_range", "unimplemented", "internal", "unavailable", "data_loss", "unauthenticated"]>;
1266
+ type ExecutorErrorCode = typeof ExecutorErrorCode.Type;
1267
+ declare const ExecutorError_base: Schema.Class<ExecutorError, Schema.TaggedStruct<"ExecutorError", {
1268
+ readonly code: Schema.Literals<readonly ["canceled", "unknown", "invalid_argument", "deadline_exceeded", "not_found", "already_exists", "permission_denied", "resource_exhausted", "failed_precondition", "aborted", "out_of_range", "unimplemented", "internal", "unavailable", "data_loss", "unauthenticated"]>;
1269
+ readonly message: Schema.String;
1270
+ readonly cause: Schema.optional<Schema.Defect>;
1271
+ }>, import("effect/Cause").YieldableError>;
1272
+ /** A request to the executor that could not be made, or that the executor refused. */
1273
+ declare class ExecutorError extends ExecutorError_base {
1274
+ /** What a call that did not give its answer failed with. */
1275
+ static from(cause: unknown): ExecutorError;
1276
+ }
1277
+ //#endregion
1278
+ //#region src/executor.d.ts
1279
+ /** Where an executor is and what lets a caller in. */
1280
+ interface Address {
1281
+ /** The executor's base, such as `https://node.example`. */
1282
+ readonly url: string;
1283
+ /** The operator token. */
1284
+ readonly token: string;
1285
+ }
1286
+ type CreateSession = MessageInitShape<typeof CreateSessionRequestSchema>;
1287
+ type CreateSnapshot = MessageInitShape<typeof CreateSnapshotRequestSchema>;
1288
+ type ProxyConfigInit = MessageInitShape<typeof ProxyConfigSchema>;
1289
+ /** One executor's client. */
1290
+ declare const make: (address: Address) => {
1291
+ /** What the executor is and what its sessions may have. */get: Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Executor"> & {
1292
+ version: string;
1293
+ features: Feature[];
1294
+ network?: Network | undefined;
1295
+ limits?: Limits | undefined;
1296
+ holdsResources: boolean;
1297
+ sharesSnapshots: boolean;
1298
+ }, ExecutorError, never>;
1299
+ sessions: {
1300
+ /** Creates a session, from a snapshot or empty, and starts its browser unless asked not to. */create: (request?: CreateSession) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1301
+ id: string;
1302
+ state: SessionState;
1303
+ snapshotId?: string | undefined;
1304
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1305
+ endpoints?: Endpoints | undefined;
1306
+ failure?: string | undefined;
1307
+ limits?: Limits | undefined;
1308
+ usage?: Usage | undefined;
1309
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1310
+ asleep: boolean;
1311
+ features: Feature[];
1312
+ network?: Network | undefined;
1313
+ }, ExecutorError, never>;
1314
+ get: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1315
+ id: string;
1316
+ state: SessionState;
1317
+ snapshotId?: string | undefined;
1318
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1319
+ endpoints?: Endpoints | undefined;
1320
+ failure?: string | undefined;
1321
+ limits?: Limits | undefined;
1322
+ usage?: Usage | undefined;
1323
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1324
+ asleep: boolean;
1325
+ features: Feature[];
1326
+ network?: Network | undefined;
1327
+ }, ExecutorError, never>;
1328
+ list: Effect.Effect<Session[], ExecutorError, never>; /** Stops the session's browser and keeps its profile. */
1329
+ suspend: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1330
+ id: string;
1331
+ state: SessionState;
1332
+ snapshotId?: string | undefined;
1333
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1334
+ endpoints?: Endpoints | undefined;
1335
+ failure?: string | undefined;
1336
+ limits?: Limits | undefined;
1337
+ usage?: Usage | undefined;
1338
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1339
+ asleep: boolean;
1340
+ features: Feature[];
1341
+ network?: Network | undefined;
1342
+ }, ExecutorError, never>;
1343
+ /**
1344
+ * Starts the browser of a suspended or failed session on the profile it left. As a
1345
+ * takeover, also when another node says it has the session.
1346
+ */
1347
+ resume: (id: string, options?: {
1348
+ readonly takeover?: boolean;
1349
+ }) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1350
+ id: string;
1351
+ state: SessionState;
1352
+ snapshotId?: string | undefined;
1353
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1354
+ endpoints?: Endpoints | undefined;
1355
+ failure?: string | undefined;
1356
+ limits?: Limits | undefined;
1357
+ usage?: Usage | undefined;
1358
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1359
+ asleep: boolean;
1360
+ features: Feature[];
1361
+ network?: Network | undefined;
1362
+ }, ExecutorError, never>;
1363
+ /**
1364
+ * Sets how the session's browser connections are routed. Without a configuration,
1365
+ * everything goes direct again.
1366
+ */
1367
+ setProxy: (id: string, proxy?: ProxyConfigInit) => Effect.Effect<void, ExecutorError, never>; /** Stops the session and removes its profile and files. Snapshots taken of it stay. */
1368
+ delete: (id: string) => Effect.Effect<void, ExecutorError, never>;
1369
+ /**
1370
+ * The node's sessions as they change: each as it is now, then each again when what
1371
+ * `get` tells of it becomes another, and the id of each that is gone. It goes on
1372
+ * until whoever runs the stream stops.
1373
+ */
1374
+ watch: Stream.Stream<WatchSessionsResponse, ExecutorError, never>;
1375
+ /**
1376
+ * Drops the node's copy of a session that is at rest where nodes share sessions: the
1377
+ * session stays there, for whichever node resumes it.
1378
+ */
1379
+ evict: (id: string) => Effect.Effect<void, ExecutorError, never>; /** The sessions where nodes share them, whichever node has them or none. */
1380
+ stored: Effect.Effect<StoredSession[], ExecutorError, never>;
1381
+ };
1382
+ snapshots: {
1383
+ /** Keeps the session's profile as it is now. */create: (request: CreateSnapshot) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Snapshot"> & {
1384
+ id: string;
1385
+ name?: string | undefined;
1386
+ sessionId: string;
1387
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1388
+ }, ExecutorError, never>;
1389
+ get: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Snapshot"> & {
1390
+ id: string;
1391
+ name?: string | undefined;
1392
+ sessionId: string;
1393
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1394
+ }, ExecutorError, never>;
1395
+ list: Effect.Effect<Snapshot[], ExecutorError, never>; /** Sessions created from the snapshot keep working. */
1396
+ delete: (id: string) => Effect.Effect<void, ExecutorError, never>;
1397
+ };
1398
+ };
1399
+ type ExecutorClient = ReturnType<typeof make>;
1400
+ declare const Executor_base: Context.ServiceClass<Executor, "@aperture-browser/executor-client/Executor", {
1401
+ /** What the executor is and what its sessions may have. */get: Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Executor"> & {
1402
+ version: string;
1403
+ features: Feature[];
1404
+ network?: Network | undefined;
1405
+ limits?: Limits | undefined;
1406
+ holdsResources: boolean;
1407
+ sharesSnapshots: boolean;
1408
+ }, ExecutorError, never>;
1409
+ sessions: {
1410
+ /** Creates a session, from a snapshot or empty, and starts its browser unless asked not to. */create: (request?: CreateSession) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1411
+ id: string;
1412
+ state: SessionState;
1413
+ snapshotId?: string | undefined;
1414
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1415
+ endpoints?: Endpoints | undefined;
1416
+ failure?: string | undefined;
1417
+ limits?: Limits | undefined;
1418
+ usage?: Usage | undefined;
1419
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1420
+ asleep: boolean;
1421
+ features: Feature[];
1422
+ network?: Network | undefined;
1423
+ }, ExecutorError, never>;
1424
+ get: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1425
+ id: string;
1426
+ state: SessionState;
1427
+ snapshotId?: string | undefined;
1428
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1429
+ endpoints?: Endpoints | undefined;
1430
+ failure?: string | undefined;
1431
+ limits?: Limits | undefined;
1432
+ usage?: Usage | undefined;
1433
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1434
+ asleep: boolean;
1435
+ features: Feature[];
1436
+ network?: Network | undefined;
1437
+ }, ExecutorError, never>;
1438
+ list: Effect.Effect<Session[], ExecutorError, never>; /** Stops the session's browser and keeps its profile. */
1439
+ suspend: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1440
+ id: string;
1441
+ state: SessionState;
1442
+ snapshotId?: string | undefined;
1443
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1444
+ endpoints?: Endpoints | undefined;
1445
+ failure?: string | undefined;
1446
+ limits?: Limits | undefined;
1447
+ usage?: Usage | undefined;
1448
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1449
+ asleep: boolean;
1450
+ features: Feature[];
1451
+ network?: Network | undefined;
1452
+ }, ExecutorError, never>;
1453
+ /**
1454
+ * Starts the browser of a suspended or failed session on the profile it left. As a
1455
+ * takeover, also when another node says it has the session.
1456
+ */
1457
+ resume: (id: string, options?: {
1458
+ readonly takeover?: boolean;
1459
+ }) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Session"> & {
1460
+ id: string;
1461
+ state: SessionState;
1462
+ snapshotId?: string | undefined;
1463
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1464
+ endpoints?: Endpoints | undefined;
1465
+ failure?: string | undefined;
1466
+ limits?: Limits | undefined;
1467
+ usage?: Usage | undefined;
1468
+ idleSince?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1469
+ asleep: boolean;
1470
+ features: Feature[];
1471
+ network?: Network | undefined;
1472
+ }, ExecutorError, never>;
1473
+ /**
1474
+ * Sets how the session's browser connections are routed. Without a configuration,
1475
+ * everything goes direct again.
1476
+ */
1477
+ setProxy: (id: string, proxy?: ProxyConfigInit) => Effect.Effect<void, ExecutorError, never>; /** Stops the session and removes its profile and files. Snapshots taken of it stay. */
1478
+ delete: (id: string) => Effect.Effect<void, ExecutorError, never>;
1479
+ /**
1480
+ * The node's sessions as they change: each as it is now, then each again when what
1481
+ * `get` tells of it becomes another, and the id of each that is gone. It goes on
1482
+ * until whoever runs the stream stops.
1483
+ */
1484
+ watch: Stream.Stream<WatchSessionsResponse, ExecutorError, never>;
1485
+ /**
1486
+ * Drops the node's copy of a session that is at rest where nodes share sessions: the
1487
+ * session stays there, for whichever node resumes it.
1488
+ */
1489
+ evict: (id: string) => Effect.Effect<void, ExecutorError, never>; /** The sessions where nodes share them, whichever node has them or none. */
1490
+ stored: Effect.Effect<StoredSession[], ExecutorError, never>;
1491
+ };
1492
+ snapshots: {
1493
+ /** Keeps the session's profile as it is now. */create: (request: CreateSnapshot) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Snapshot"> & {
1494
+ id: string;
1495
+ name?: string | undefined;
1496
+ sessionId: string;
1497
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1498
+ }, ExecutorError, never>;
1499
+ get: (id: string) => Effect.Effect<import("@bufbuild/protobuf").Message<"aperture.executor.v1.Snapshot"> & {
1500
+ id: string;
1501
+ name?: string | undefined;
1502
+ sessionId: string;
1503
+ createdAt?: import("@bufbuild/protobuf/wkt").Timestamp | undefined;
1504
+ }, ExecutorError, never>;
1505
+ list: Effect.Effect<Snapshot[], ExecutorError, never>; /** Sessions created from the snapshot keep working. */
1506
+ delete: (id: string) => Effect.Effect<void, ExecutorError, never>;
1507
+ };
1508
+ }>;
1509
+ /** One executor's client, for programs that pass it along as a service. */
1510
+ declare class Executor extends Executor_base {}
1511
+ declare const layer: (address: Address) => Layer.Layer<Executor, never, never>;
1512
+ //#endregion
1513
+ export { type Address, type CreateSession, type CreateSnapshot, Executor, type ExecutorClient, ExecutorError, ExecutorErrorCode, type ProxyConfigInit, layer, make, executor_pb_d_exports as proto };
1514
+ //# sourceMappingURL=index.d.ts.map