rivetkit 2.3.20 → 2.3.21
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/browser/client.d.ts +43 -5
- package/dist/browser/client.js +302 -60
- package/dist/browser/client.js.map +1 -1
- package/dist/browser/inspector/client.js +2 -1
- package/dist/browser/inspector/client.js.map +1 -1
- package/dist/tsup/actor/errors.cjs.map +1 -1
- package/dist/tsup/agent-os/index.cjs +2 -1
- package/dist/tsup/agent-os/index.cjs.map +1 -1
- package/dist/tsup/agent-os/index.d.cts +32 -4
- package/dist/tsup/agent-os/index.d.ts +32 -4
- package/dist/tsup/agent-os/index.js +2 -1
- package/dist/tsup/agent-os/index.js.map +1 -1
- package/dist/tsup/{chunk-553CIQJY.js → chunk-2CI2IEVN.js} +2 -2
- package/dist/tsup/{chunk-W2PXGWMR.js → chunk-5EGLHQJJ.js} +2 -2
- package/dist/tsup/{chunk-DMQUERRN.js → chunk-5IBUZFLP.js} +2 -2
- package/dist/tsup/{chunk-76YTS32R.cjs → chunk-6LRPYB4Q.cjs} +4 -4
- package/dist/tsup/chunk-6LRPYB4Q.cjs.map +1 -0
- package/dist/tsup/{chunk-WAISW7KR.cjs → chunk-APOANSDG.cjs} +10 -10
- package/dist/tsup/chunk-APOANSDG.cjs.map +1 -0
- package/dist/tsup/{chunk-IHKDFKM4.cjs → chunk-ARGNQGYG.cjs} +3 -3
- package/dist/tsup/chunk-ARGNQGYG.cjs.map +1 -0
- package/dist/tsup/{chunk-A36FMKOV.cjs → chunk-B5SNXPSS.cjs} +448 -199
- package/dist/tsup/chunk-B5SNXPSS.cjs.map +1 -0
- package/dist/tsup/{chunk-SNNVRHLX.js → chunk-CJXBGTVT.js} +2 -2
- package/dist/tsup/{chunk-CVLNRT7O.cjs → chunk-GHKQC4PD.cjs} +3 -3
- package/dist/tsup/chunk-GHKQC4PD.cjs.map +1 -0
- package/dist/tsup/chunk-JX2ITWAV.cjs.map +1 -1
- package/dist/tsup/chunk-KVFIONKQ.cjs.map +1 -1
- package/dist/tsup/{chunk-2CE5UNWK.cjs → chunk-KWGN2ZBJ.cjs} +3 -2
- package/dist/tsup/chunk-KWGN2ZBJ.cjs.map +1 -0
- package/dist/tsup/{chunk-3WS7Z64U.cjs → chunk-LWSLKKZ5.cjs} +3 -3
- package/dist/tsup/chunk-LWSLKKZ5.cjs.map +1 -0
- package/dist/tsup/chunk-MYWZCDML.cjs.map +1 -1
- package/dist/tsup/{chunk-RSIOGT2U.cjs → chunk-NL2EIKK6.cjs} +7 -7
- package/dist/tsup/chunk-NL2EIKK6.cjs.map +1 -0
- package/dist/tsup/chunk-NWCAIWHL.cjs.map +1 -1
- package/dist/tsup/{chunk-5G2J26VM.js → chunk-PYRI75DL.js} +314 -65
- package/dist/tsup/chunk-PYRI75DL.js.map +1 -0
- package/dist/tsup/{chunk-2NXLTFWI.js → chunk-RFN3BG6D.js} +3 -3
- package/dist/tsup/chunk-RFN3BG6D.js.map +1 -0
- package/dist/tsup/{chunk-DHWZTUKA.js → chunk-RGIZNZYO.js} +3 -2
- package/dist/tsup/chunk-RGIZNZYO.js.map +1 -0
- package/dist/tsup/{chunk-TZVAVPGJ.js → chunk-VMMXXVDO.js} +4 -4
- package/dist/tsup/client/mod.cjs +5 -5
- package/dist/tsup/client/mod.cjs.map +1 -1
- package/dist/tsup/client/mod.d.cts +12 -3
- package/dist/tsup/client/mod.d.ts +12 -3
- package/dist/tsup/client/mod.js +4 -4
- package/dist/tsup/common/log.cjs +2 -2
- package/dist/tsup/common/log.cjs.map +1 -1
- package/dist/tsup/common/log.js +1 -1
- package/dist/tsup/common/websocket.cjs +3 -3
- package/dist/tsup/common/websocket.cjs.map +1 -1
- package/dist/tsup/common/websocket.js +2 -2
- package/dist/tsup/{config-Be-VOHaX.d.ts → config-Bc1nnvUl.d.ts} +35 -5
- package/dist/tsup/{config-Ct5uXxXk.d.cts → config-Do_0guSS.d.cts} +35 -5
- package/dist/tsup/{context-Cw-11Q-B.d.cts → context-CgNkhjdY.d.cts} +1 -1
- package/dist/tsup/{context-CXLa0BIM.d.ts → context-oGQxZDPz.d.ts} +1 -1
- package/dist/tsup/db/drizzle.cjs +2 -2
- package/dist/tsup/db/drizzle.cjs.map +1 -1
- package/dist/tsup/db/drizzle.js +1 -1
- package/dist/tsup/db/mod.cjs +3 -3
- package/dist/tsup/db/mod.cjs.map +1 -1
- package/dist/tsup/db/mod.js +2 -2
- package/dist/tsup/dynamic/mod.cjs.map +1 -1
- package/dist/tsup/dynamic/mod.d.cts +2 -1
- package/dist/tsup/dynamic/mod.d.ts +2 -1
- package/dist/tsup/inspector/mod.cjs +5 -5
- package/dist/tsup/inspector/mod.cjs.map +1 -1
- package/dist/tsup/inspector/mod.js +4 -4
- package/dist/tsup/inspector/workflow.cjs +4 -4
- package/dist/tsup/inspector/workflow.cjs.map +1 -1
- package/dist/tsup/inspector/workflow.js +3 -3
- package/dist/tsup/inspector-tab/mod.cjs.map +1 -1
- package/dist/tsup/inspector-tab/mod.d.cts +3 -2
- package/dist/tsup/inspector-tab/mod.d.ts +3 -2
- package/dist/tsup/mod.cjs +105 -115
- package/dist/tsup/mod.cjs.map +1 -1
- package/dist/tsup/mod.d.cts +4 -3
- package/dist/tsup/mod.d.ts +4 -3
- package/dist/tsup/mod.js +29 -39
- package/dist/tsup/mod.js.map +1 -1
- package/dist/tsup/test/mod.cjs +6 -6
- package/dist/tsup/test/mod.cjs.map +1 -1
- package/dist/tsup/test/mod.d.cts +2 -1
- package/dist/tsup/test/mod.d.ts +2 -1
- package/dist/tsup/test/mod.js +4 -4
- package/dist/tsup/unstable/migrations.cjs.map +1 -1
- package/dist/tsup/utils.cjs +2 -2
- package/dist/tsup/utils.cjs.map +1 -1
- package/dist/tsup/utils.js +1 -1
- package/dist/tsup/workflow/mod.cjs +7 -7
- package/dist/tsup/workflow/mod.cjs.map +1 -1
- package/dist/tsup/workflow/mod.d.cts +4 -3
- package/dist/tsup/workflow/mod.d.ts +4 -3
- package/dist/tsup/workflow/mod.js +4 -4
- package/package.json +10 -9
- package/src/client/actor-conn.ts +34 -1
- package/src/client/actor-handle.ts +29 -1
- package/src/client/auth.ts +37 -0
- package/src/client/client.ts +10 -2
- package/src/client/config.ts +12 -1
- package/src/client/mod.ts +9 -0
- package/src/client/token-provider.test.ts +86 -0
- package/src/client/token-provider.ts +93 -0
- package/src/client/utils.ts +1 -0
- package/src/engine-client/actor-websocket-client.ts +2 -1
- package/src/engine-client/api-endpoints.ts +28 -0
- package/src/engine-client/driver.ts +4 -0
- package/src/engine-client/mod.ts +201 -64
- package/src/registry/config/envoy.ts +1 -17
- package/src/registry/config/index.test.ts +2 -2
- package/src/registry/config/index.ts +7 -2
- package/src/registry/index.ts +28 -0
- package/dist/tsup/chunk-2CE5UNWK.cjs.map +0 -1
- package/dist/tsup/chunk-2NXLTFWI.js.map +0 -1
- package/dist/tsup/chunk-3WS7Z64U.cjs.map +0 -1
- package/dist/tsup/chunk-5G2J26VM.js.map +0 -1
- package/dist/tsup/chunk-76YTS32R.cjs.map +0 -1
- package/dist/tsup/chunk-A36FMKOV.cjs.map +0 -1
- package/dist/tsup/chunk-CVLNRT7O.cjs.map +0 -1
- package/dist/tsup/chunk-DHWZTUKA.js.map +0 -1
- package/dist/tsup/chunk-IHKDFKM4.cjs.map +0 -1
- package/dist/tsup/chunk-RSIOGT2U.cjs.map +0 -1
- package/dist/tsup/chunk-WAISW7KR.cjs.map +0 -1
- /package/dist/tsup/{chunk-553CIQJY.js.map → chunk-2CI2IEVN.js.map} +0 -0
- /package/dist/tsup/{chunk-W2PXGWMR.js.map → chunk-5EGLHQJJ.js.map} +0 -0
- /package/dist/tsup/{chunk-DMQUERRN.js.map → chunk-5IBUZFLP.js.map} +0 -0
- /package/dist/tsup/{chunk-SNNVRHLX.js.map → chunk-CJXBGTVT.js.map} +0 -0
- /package/dist/tsup/{chunk-TZVAVPGJ.js.map → chunk-VMMXXVDO.js.map} +0 -0
|
@@ -2,6 +2,7 @@ import * as _rivet_dev_agent_os_core from '@rivet-dev/agent-os-core';
|
|
|
2
2
|
import { AgentOs, JsonRpcNotification, PermissionRequest, CronEvent, AgentCapabilities, AgentInfo, JsonRpcResponse, AgentOsOptions, BatchReadResult, BatchWriteEntry, BatchWriteResult, ReaddirRecursiveOptions, DirEntry, AgentRegistryEntry, SpawnedProcessInfo, ProcessInfo, ProcessTreeNode, SessionModeState, SessionConfigOption, GetEventsOptions, SequencedEvent, PermissionReply, AgentType, CreateSessionOptions, SessionInfo, OpenShellOptions } from '@rivet-dev/agent-os-core';
|
|
3
3
|
import { z as z$1 } from 'zod/v4';
|
|
4
4
|
import { StandardSchemaV1 } from '@standard-schema/spec';
|
|
5
|
+
import { Rivet } from '@rivetkit/engine-api-full';
|
|
5
6
|
import { Context, Handler, Hono } from 'hono';
|
|
6
7
|
import { UniversalWebSocket } from '@rivetkit/virtual-websocket';
|
|
7
8
|
import * as _rivetkit_rivetkit_wasm from '@rivetkit/rivetkit-wasm';
|
|
@@ -272,7 +273,7 @@ declare const RegistryConfigSchema: z.ZodPipe<z.ZodObject<{
|
|
|
272
273
|
endpoint: string | undefined;
|
|
273
274
|
startServices: boolean;
|
|
274
275
|
namespace: string;
|
|
275
|
-
token: string;
|
|
276
|
+
token: string | undefined;
|
|
276
277
|
publicEndpoint: string | undefined;
|
|
277
278
|
publicNamespace: string | undefined;
|
|
278
279
|
publicToken: string | undefined;
|
|
@@ -445,6 +446,24 @@ declare class ActorDefinition<S, CP, CS, V, I, DB extends AnyDatabaseProvider, E
|
|
|
445
446
|
get config(): ActorConfig<S, CP, CS, V, I, DB, E, Q, R>;
|
|
446
447
|
}
|
|
447
448
|
|
|
449
|
+
/** Options for `client.auth.issueToken()`. `expiresIn` is in seconds. */
|
|
450
|
+
type IssueTokenOptions = Pick<Rivet.AuthTokenCreateRequest, "subject" | "grants"> & {
|
|
451
|
+
expiresIn?: Rivet.AuthTokenCreateRequest["duration"];
|
|
452
|
+
};
|
|
453
|
+
/** Token timestamps are Unix milliseconds. */
|
|
454
|
+
interface IssuedToken {
|
|
455
|
+
token: Rivet.AuthTokenCreateResponse["token"];
|
|
456
|
+
issuedAt: Rivet.AuthTokenCreateResponse["issuedTs"];
|
|
457
|
+
expiresAt: Rivet.AuthTokenCreateResponse["expiresTs"];
|
|
458
|
+
}
|
|
459
|
+
/** Resources that can be scoped to a single actor ID. */
|
|
460
|
+
type ActorTokenResource = Extract<Rivet.AuthTokenGrant["resource"], "actor_gateway" | "actor" | "actor_kv">;
|
|
461
|
+
type ActorTokenPermissions = Partial<Record<ActorTokenResource, Rivet.AuthTokenGrant["operations"]>>;
|
|
462
|
+
/** Options for `actor.issueToken()`. Omit permissions for gateway read access only. */
|
|
463
|
+
type ActorIssueTokenOptions = Pick<IssueTokenOptions, "subject" | "expiresIn"> & {
|
|
464
|
+
permissions?: ActorTokenPermissions;
|
|
465
|
+
};
|
|
466
|
+
|
|
448
467
|
declare const EncodingSchema: z$1.ZodEnum<{
|
|
449
468
|
json: "json";
|
|
450
469
|
cbor: "cbor";
|
|
@@ -576,6 +595,7 @@ interface GatewayRequestOptions {
|
|
|
576
595
|
skipReadyWait?: boolean;
|
|
577
596
|
}
|
|
578
597
|
interface EngineControlClient {
|
|
598
|
+
issueToken(options: IssueTokenOptions): Promise<IssuedToken>;
|
|
579
599
|
getForId(input: GetForIdInput): Promise<ActorOutput | undefined>;
|
|
580
600
|
getWithKey(input: GetWithKeyInput): Promise<ActorOutput | undefined>;
|
|
581
601
|
getOrCreateWithKey(input: GetOrCreateWithKeyInput): Promise<ActorOutput>;
|
|
@@ -583,6 +603,8 @@ interface EngineControlClient {
|
|
|
583
603
|
listActors(input: ListActorsInput): Promise<ActorOutput[]>;
|
|
584
604
|
sendRequest(target: GatewayTarget, actorRequest: Request, options?: GatewayRequestOptions): Promise<Response>;
|
|
585
605
|
openWebSocket(path: string, target: GatewayTarget, encoding: Encoding, params: unknown, options?: GatewayRequestOptions): Promise<UniversalWebSocket>;
|
|
606
|
+
/** Refresh a credential rejected during this WebSocket handshake, if supported. */
|
|
607
|
+
refreshAuthToken?(ws: UniversalWebSocket): Promise<boolean>;
|
|
586
608
|
proxyRequest(c: Context, actorRequest: Request, actorId: string): Promise<Response>;
|
|
587
609
|
proxyWebSocket(c: Context, path: string, actorId: string, encoding: Encoding, params: unknown): Promise<Response>;
|
|
588
610
|
buildGatewayUrl(target: GatewayTarget, options?: GatewayRequestOptions): Promise<string>;
|
|
@@ -1572,6 +1594,8 @@ declare class ActorHandleRaw {
|
|
|
1572
1594
|
* Resolves the actor to get its unique actor ID.
|
|
1573
1595
|
*/
|
|
1574
1596
|
resolve(): Promise<string>;
|
|
1597
|
+
/** Issue a token scoped to this actor. Defaults to actor gateway read access. */
|
|
1598
|
+
issueToken(options?: ActorIssueTokenOptions): Promise<IssuedToken>;
|
|
1575
1599
|
/**
|
|
1576
1600
|
* Returns the raw URL for routing traffic to the actor.
|
|
1577
1601
|
*/
|
|
@@ -1597,7 +1621,7 @@ declare class ActorHandleRaw {
|
|
|
1597
1621
|
type ActorHandle<AD extends AnyActorDefinition> = Omit<ActorHandleRaw, "connect" | "send"> & {
|
|
1598
1622
|
connect(params?: unknown, options?: ActorConnectOptions): ActorConn<AD>;
|
|
1599
1623
|
resolve(): Promise<string>;
|
|
1600
|
-
} & ActorDefinitionQueueSend<AD> & ActorDefinitionActions<AD>;
|
|
1624
|
+
} & ActorDefinitionQueueSend<AD> & Omit<ActorDefinitionActions<AD>, keyof ActorHandleRaw>;
|
|
1601
1625
|
|
|
1602
1626
|
/** Extract the actor registry from the registry definition. */
|
|
1603
1627
|
type ExtractActorsFromRegistry<A extends Registry<any>> = A extends Registry<infer Actors> ? Actors : never;
|
|
@@ -1733,6 +1757,10 @@ interface ActorClientRuntimeOptions {
|
|
|
1733
1757
|
*/
|
|
1734
1758
|
declare class ClientRaw {
|
|
1735
1759
|
#private;
|
|
1760
|
+
/** Issue namespace-scoped tokens with an explicit grant list. */
|
|
1761
|
+
readonly auth: {
|
|
1762
|
+
issueToken(options: IssueTokenOptions): Promise<IssuedToken>;
|
|
1763
|
+
};
|
|
1736
1764
|
[ACTOR_CONNS_SYMBOL]: Set<ActorConnRaw>;
|
|
1737
1765
|
/**
|
|
1738
1766
|
* Creates an instance of Client.
|
|
@@ -1793,9 +1821,9 @@ declare class ClientRaw {
|
|
|
1793
1821
|
*
|
|
1794
1822
|
* @template A The actor registry type.
|
|
1795
1823
|
*/
|
|
1796
|
-
type Client<A extends Registry<any>> = ClientRaw & {
|
|
1824
|
+
type Client<A extends Registry<any>> = ClientRaw & Omit<{
|
|
1797
1825
|
[K in keyof ExtractActorsFromRegistry<A>]: ActorAccessor<ExtractActorsFromRegistry<A>[K]>;
|
|
1798
|
-
}
|
|
1826
|
+
}, keyof ClientRaw>;
|
|
1799
1827
|
|
|
1800
1828
|
/** @experimental State exposed by a durable workflow run handler to the Inspector. */
|
|
1801
1829
|
type WorkflowState = "pending" | "running" | "sleeping" | "failed" | "completed" | "cancelled" | "rolling_back";
|
|
@@ -2,6 +2,7 @@ import * as _rivet_dev_agent_os_core from '@rivet-dev/agent-os-core';
|
|
|
2
2
|
import { AgentOs, JsonRpcNotification, PermissionRequest, CronEvent, AgentCapabilities, AgentInfo, JsonRpcResponse, AgentOsOptions, BatchReadResult, BatchWriteEntry, BatchWriteResult, ReaddirRecursiveOptions, DirEntry, AgentRegistryEntry, SpawnedProcessInfo, ProcessInfo, ProcessTreeNode, SessionModeState, SessionConfigOption, GetEventsOptions, SequencedEvent, PermissionReply, AgentType, CreateSessionOptions, SessionInfo, OpenShellOptions } from '@rivet-dev/agent-os-core';
|
|
3
3
|
import { z as z$1 } from 'zod/v4';
|
|
4
4
|
import { StandardSchemaV1 } from '@standard-schema/spec';
|
|
5
|
+
import { Rivet } from '@rivetkit/engine-api-full';
|
|
5
6
|
import { Context, Handler, Hono } from 'hono';
|
|
6
7
|
import { UniversalWebSocket } from '@rivetkit/virtual-websocket';
|
|
7
8
|
import * as _rivetkit_rivetkit_wasm from '@rivetkit/rivetkit-wasm';
|
|
@@ -272,7 +273,7 @@ declare const RegistryConfigSchema: z.ZodPipe<z.ZodObject<{
|
|
|
272
273
|
endpoint: string | undefined;
|
|
273
274
|
startServices: boolean;
|
|
274
275
|
namespace: string;
|
|
275
|
-
token: string;
|
|
276
|
+
token: string | undefined;
|
|
276
277
|
publicEndpoint: string | undefined;
|
|
277
278
|
publicNamespace: string | undefined;
|
|
278
279
|
publicToken: string | undefined;
|
|
@@ -445,6 +446,24 @@ declare class ActorDefinition<S, CP, CS, V, I, DB extends AnyDatabaseProvider, E
|
|
|
445
446
|
get config(): ActorConfig<S, CP, CS, V, I, DB, E, Q, R>;
|
|
446
447
|
}
|
|
447
448
|
|
|
449
|
+
/** Options for `client.auth.issueToken()`. `expiresIn` is in seconds. */
|
|
450
|
+
type IssueTokenOptions = Pick<Rivet.AuthTokenCreateRequest, "subject" | "grants"> & {
|
|
451
|
+
expiresIn?: Rivet.AuthTokenCreateRequest["duration"];
|
|
452
|
+
};
|
|
453
|
+
/** Token timestamps are Unix milliseconds. */
|
|
454
|
+
interface IssuedToken {
|
|
455
|
+
token: Rivet.AuthTokenCreateResponse["token"];
|
|
456
|
+
issuedAt: Rivet.AuthTokenCreateResponse["issuedTs"];
|
|
457
|
+
expiresAt: Rivet.AuthTokenCreateResponse["expiresTs"];
|
|
458
|
+
}
|
|
459
|
+
/** Resources that can be scoped to a single actor ID. */
|
|
460
|
+
type ActorTokenResource = Extract<Rivet.AuthTokenGrant["resource"], "actor_gateway" | "actor" | "actor_kv">;
|
|
461
|
+
type ActorTokenPermissions = Partial<Record<ActorTokenResource, Rivet.AuthTokenGrant["operations"]>>;
|
|
462
|
+
/** Options for `actor.issueToken()`. Omit permissions for gateway read access only. */
|
|
463
|
+
type ActorIssueTokenOptions = Pick<IssueTokenOptions, "subject" | "expiresIn"> & {
|
|
464
|
+
permissions?: ActorTokenPermissions;
|
|
465
|
+
};
|
|
466
|
+
|
|
448
467
|
declare const EncodingSchema: z$1.ZodEnum<{
|
|
449
468
|
json: "json";
|
|
450
469
|
cbor: "cbor";
|
|
@@ -576,6 +595,7 @@ interface GatewayRequestOptions {
|
|
|
576
595
|
skipReadyWait?: boolean;
|
|
577
596
|
}
|
|
578
597
|
interface EngineControlClient {
|
|
598
|
+
issueToken(options: IssueTokenOptions): Promise<IssuedToken>;
|
|
579
599
|
getForId(input: GetForIdInput): Promise<ActorOutput | undefined>;
|
|
580
600
|
getWithKey(input: GetWithKeyInput): Promise<ActorOutput | undefined>;
|
|
581
601
|
getOrCreateWithKey(input: GetOrCreateWithKeyInput): Promise<ActorOutput>;
|
|
@@ -583,6 +603,8 @@ interface EngineControlClient {
|
|
|
583
603
|
listActors(input: ListActorsInput): Promise<ActorOutput[]>;
|
|
584
604
|
sendRequest(target: GatewayTarget, actorRequest: Request, options?: GatewayRequestOptions): Promise<Response>;
|
|
585
605
|
openWebSocket(path: string, target: GatewayTarget, encoding: Encoding, params: unknown, options?: GatewayRequestOptions): Promise<UniversalWebSocket>;
|
|
606
|
+
/** Refresh a credential rejected during this WebSocket handshake, if supported. */
|
|
607
|
+
refreshAuthToken?(ws: UniversalWebSocket): Promise<boolean>;
|
|
586
608
|
proxyRequest(c: Context, actorRequest: Request, actorId: string): Promise<Response>;
|
|
587
609
|
proxyWebSocket(c: Context, path: string, actorId: string, encoding: Encoding, params: unknown): Promise<Response>;
|
|
588
610
|
buildGatewayUrl(target: GatewayTarget, options?: GatewayRequestOptions): Promise<string>;
|
|
@@ -1572,6 +1594,8 @@ declare class ActorHandleRaw {
|
|
|
1572
1594
|
* Resolves the actor to get its unique actor ID.
|
|
1573
1595
|
*/
|
|
1574
1596
|
resolve(): Promise<string>;
|
|
1597
|
+
/** Issue a token scoped to this actor. Defaults to actor gateway read access. */
|
|
1598
|
+
issueToken(options?: ActorIssueTokenOptions): Promise<IssuedToken>;
|
|
1575
1599
|
/**
|
|
1576
1600
|
* Returns the raw URL for routing traffic to the actor.
|
|
1577
1601
|
*/
|
|
@@ -1597,7 +1621,7 @@ declare class ActorHandleRaw {
|
|
|
1597
1621
|
type ActorHandle<AD extends AnyActorDefinition> = Omit<ActorHandleRaw, "connect" | "send"> & {
|
|
1598
1622
|
connect(params?: unknown, options?: ActorConnectOptions): ActorConn<AD>;
|
|
1599
1623
|
resolve(): Promise<string>;
|
|
1600
|
-
} & ActorDefinitionQueueSend<AD> & ActorDefinitionActions<AD>;
|
|
1624
|
+
} & ActorDefinitionQueueSend<AD> & Omit<ActorDefinitionActions<AD>, keyof ActorHandleRaw>;
|
|
1601
1625
|
|
|
1602
1626
|
/** Extract the actor registry from the registry definition. */
|
|
1603
1627
|
type ExtractActorsFromRegistry<A extends Registry<any>> = A extends Registry<infer Actors> ? Actors : never;
|
|
@@ -1733,6 +1757,10 @@ interface ActorClientRuntimeOptions {
|
|
|
1733
1757
|
*/
|
|
1734
1758
|
declare class ClientRaw {
|
|
1735
1759
|
#private;
|
|
1760
|
+
/** Issue namespace-scoped tokens with an explicit grant list. */
|
|
1761
|
+
readonly auth: {
|
|
1762
|
+
issueToken(options: IssueTokenOptions): Promise<IssuedToken>;
|
|
1763
|
+
};
|
|
1736
1764
|
[ACTOR_CONNS_SYMBOL]: Set<ActorConnRaw>;
|
|
1737
1765
|
/**
|
|
1738
1766
|
* Creates an instance of Client.
|
|
@@ -1793,9 +1821,9 @@ declare class ClientRaw {
|
|
|
1793
1821
|
*
|
|
1794
1822
|
* @template A The actor registry type.
|
|
1795
1823
|
*/
|
|
1796
|
-
type Client<A extends Registry<any>> = ClientRaw & {
|
|
1824
|
+
type Client<A extends Registry<any>> = ClientRaw & Omit<{
|
|
1797
1825
|
[K in keyof ExtractActorsFromRegistry<A>]: ActorAccessor<ExtractActorsFromRegistry<A>[K]>;
|
|
1798
|
-
}
|
|
1826
|
+
}, keyof ClientRaw>;
|
|
1799
1827
|
|
|
1800
1828
|
/** @experimental State exposed by a durable workflow run handler to the Inspector. */
|
|
1801
1829
|
type WorkflowState = "pending" | "running" | "sleeping" | "failed" | "completed" | "cancelled" | "rolling_back";
|
|
@@ -451,7 +451,7 @@ function isRivetErrorCode(error, group, code) {
|
|
|
451
451
|
// package.json
|
|
452
452
|
var package_default = {
|
|
453
453
|
name: "rivetkit",
|
|
454
|
-
version: "2.3.
|
|
454
|
+
version: "2.3.21",
|
|
455
455
|
description: "Lightweight libraries for building stateful actors on edge platforms",
|
|
456
456
|
license: "Apache-2.0",
|
|
457
457
|
keywords: [
|
|
@@ -664,6 +664,7 @@ var package_default = {
|
|
|
664
664
|
"@rivet-dev/agent-os-core": "^0.1.1",
|
|
665
665
|
"@rivet-dev/services": "^0.1.5",
|
|
666
666
|
"@rivetkit/bare-ts": "^0.6.2",
|
|
667
|
+
"@rivetkit/engine-api-full": "workspace:*",
|
|
667
668
|
"@rivetkit/engine-cli": "workspace:*",
|
|
668
669
|
"@rivetkit/engine-envoy-protocol": "workspace:*",
|
|
669
670
|
"@rivetkit/on-change": "6.0.1",
|