modal 0.10.2-dev.2 → 0.10.2-dev.3

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.d.cts CHANGED
@@ -233,6 +233,20 @@ declare enum FileDescriptor {
233
233
  FILE_DESCRIPTOR_INFO = 3,
234
234
  UNRECOGNIZED = -1
235
235
  }
236
+ declare enum FunctionCallInputStatus {
237
+ FUNCTION_CALL_INPUT_STATUS_UNSPECIFIED = 0,
238
+ FUNCTION_CALL_INPUT_STATUS_PENDING = 1,
239
+ FUNCTION_CALL_INPUT_STATUS_RUNNING = 2,
240
+ FUNCTION_CALL_INPUT_STATUS_SUCCESS = 3,
241
+ FUNCTION_CALL_INPUT_STATUS_FAILURE = 4,
242
+ FUNCTION_CALL_INPUT_STATUS_TIMEOUT = 5,
243
+ FUNCTION_CALL_INPUT_STATUS_TERMINATED = 6,
244
+ FUNCTION_CALL_INPUT_STATUS_INIT_FAILURE = 7,
245
+ FUNCTION_CALL_INPUT_STATUS_INTERNAL_FAILURE = 8,
246
+ FUNCTION_CALL_INPUT_STATUS_IDLE_TIMEOUT = 9,
247
+ FUNCTION_CALL_INPUT_STATUS_MEMORY_MANAGER_EVICTION = 10,
248
+ UNRECOGNIZED = -1
249
+ }
236
250
  declare enum FunctionCallInvocationType {
237
251
  FUNCTION_CALL_INVOCATION_TYPE_UNSPECIFIED = 0,
238
252
  FUNCTION_CALL_INVOCATION_TYPE_SYNC_LEGACY = 1,
@@ -530,6 +544,11 @@ declare enum SandboxGetExitSnapshotResponse_ErrorCode {
530
544
  ERROR_CODE_UNSPECIFIED = 0,
531
545
  ERROR_CODE_TIMEOUT = 1,
532
546
  ERROR_CODE_INTERNAL = 2,
547
+ /**
548
+ * ERROR_CODE_FILESYSTEM_INCONSISTENT - The sandbox exited without leaving a consistent filesystem (e.g. killed
549
+ * before it could flush) and recovery failed, so no exit snapshot exists.
550
+ */
551
+ ERROR_CODE_FILESYSTEM_INCONSISTENT = 3,
533
552
  UNRECOGNIZED = -1
534
553
  }
535
554
  declare enum SandboxRestoreRequest_SandboxNameOverrideType {
@@ -2129,6 +2148,23 @@ interface FunctionCallCancelRequest {
2129
2148
  functionId?: string | undefined;
2130
2149
  }
2131
2150
  declare const FunctionCallCancelRequest: MessageFns$1<FunctionCallCancelRequest>;
2151
+ interface FunctionCallFetchRequest {
2152
+ functionId: string;
2153
+ tail?: FunctionCallFetchRequest_Tail | undefined;
2154
+ /** Include the root Function and its eligible variants. */
2155
+ allVariants: boolean;
2156
+ }
2157
+ declare const FunctionCallFetchRequest: MessageFns$1<FunctionCallFetchRequest>;
2158
+ interface FunctionCallFetchRequest_Tail {
2159
+ /** Number of most recent inputs to return. Must be between 1 and 1000. */
2160
+ count: number;
2161
+ }
2162
+ declare const FunctionCallFetchRequest_Tail: MessageFns$1<FunctionCallFetchRequest_Tail>;
2163
+ interface FunctionCallFetchResponse {
2164
+ /** The requested number of most recent inputs from the last seven days, ordered from newest to oldest. */
2165
+ functionCallInputs: FunctionCallInputInfo[];
2166
+ }
2167
+ declare const FunctionCallFetchResponse: MessageFns$1<FunctionCallFetchResponse>;
2132
2168
  interface FunctionCallFromIdRequest {
2133
2169
  functionCallId: string;
2134
2170
  }
@@ -2175,6 +2211,17 @@ interface FunctionCallInfo {
2175
2211
  totalInputs: number;
2176
2212
  }
2177
2213
  declare const FunctionCallInfo: MessageFns$1<FunctionCallInfo>;
2214
+ interface FunctionCallInputInfo {
2215
+ enqueuedAt: Date | undefined;
2216
+ startedAt?: Date | undefined;
2217
+ containerId?: string | undefined;
2218
+ startupTimeSeconds?: number | undefined;
2219
+ executionTimeSeconds?: number | undefined;
2220
+ status: FunctionCallInputStatus;
2221
+ functionCallId: string;
2222
+ serviceMethodName?: string | undefined;
2223
+ }
2224
+ declare const FunctionCallInputInfo: MessageFns$1<FunctionCallInputInfo>;
2178
2225
  interface FunctionCallListRequest {
2179
2226
  functionId: string;
2180
2227
  }
@@ -2548,6 +2595,20 @@ interface FunctionInput {
2548
2595
  methodName?: string | undefined;
2549
2596
  }
2550
2597
  declare const FunctionInput: MessageFns$1<FunctionInput>;
2598
+ interface FunctionListVariantsRequest {
2599
+ functionId: string;
2600
+ cursor: FunctionVariantCursor | undefined;
2601
+ limit: number;
2602
+ }
2603
+ declare const FunctionListVariantsRequest: MessageFns$1<FunctionListVariantsRequest>;
2604
+ interface FunctionListVariantsResponse {
2605
+ infos: FunctionVariantInfo[];
2606
+ /** Pass back as cursor to fetch the next page. Unset once the listing is complete. */
2607
+ nextCursor: FunctionVariantCursor | undefined;
2608
+ /** Set by the server when it ordered the variants by how many tasks each is running, busiest first. */
2609
+ orderedByTaskCount: boolean;
2610
+ }
2611
+ declare const FunctionListVariantsResponse: MessageFns$1<FunctionListVariantsResponse>;
2551
2612
  interface FunctionMapRequest {
2552
2613
  functionId: string;
2553
2614
  parentInputId: string;
@@ -2707,6 +2768,17 @@ interface FunctionUpdateSchedulingParamsResponse {
2707
2768
  currentSettings: AutoscalerSettings | undefined;
2708
2769
  }
2709
2770
  declare const FunctionUpdateSchedulingParamsResponse: MessageFns$1<FunctionUpdateSchedulingParamsResponse>;
2771
+ interface FunctionVariantCursor {
2772
+ createdBefore: number;
2773
+ functionId: string;
2774
+ }
2775
+ declare const FunctionVariantCursor: MessageFns$1<FunctionVariantCursor>;
2776
+ interface FunctionVariantInfo {
2777
+ functionId: string;
2778
+ serializedParams: Uint8Array;
2779
+ functionOptions: FunctionOptions$1 | undefined;
2780
+ }
2781
+ declare const FunctionVariantInfo: MessageFns$1<FunctionVariantInfo>;
2710
2782
  interface GPUConfig {
2711
2783
  /** Deprecated, at some point */
2712
2784
  type: GPUType;
@@ -4067,6 +4139,7 @@ declare const SecretListResponse: MessageFns$1<SecretListResponse>;
4067
4139
  interface SecretMetadata {
4068
4140
  name: string;
4069
4141
  creationInfo: CreationInfo | undefined;
4142
+ keys: string[];
4070
4143
  }
4071
4144
  declare const SecretMetadata: MessageFns$1<SecretMetadata>;
4072
4145
  interface SecretUpdateRequest {
@@ -4145,6 +4218,29 @@ interface ServerGetTimeRangeStatsResponse_ServerStatusCodeCount {
4145
4218
  count: number;
4146
4219
  }
4147
4220
  declare const ServerGetTimeRangeStatsResponse_ServerStatusCodeCount: MessageFns$1<ServerGetTimeRangeStatsResponse_ServerStatusCodeCount>;
4221
+ interface ServerRequestFetchRequest {
4222
+ functionId: string;
4223
+ tail?: ServerRequestFetchRequest_Tail | undefined;
4224
+ }
4225
+ declare const ServerRequestFetchRequest: MessageFns$1<ServerRequestFetchRequest>;
4226
+ interface ServerRequestFetchRequest_Tail {
4227
+ /** Number of most recent requests to return. Must be between 1 and 1000. */
4228
+ count: number;
4229
+ }
4230
+ declare const ServerRequestFetchRequest_Tail: MessageFns$1<ServerRequestFetchRequest_Tail>;
4231
+ interface ServerRequestFetchResponse {
4232
+ /** The requested number of most recent requests from the last seven days, ordered from newest to oldest. */
4233
+ requests: ServerRequestInfo[];
4234
+ }
4235
+ declare const ServerRequestFetchResponse: MessageFns$1<ServerRequestFetchResponse>;
4236
+ interface ServerRequestInfo {
4237
+ route: string;
4238
+ timestamp: Date | undefined;
4239
+ containerId: string;
4240
+ durationSeconds: number;
4241
+ status: number;
4242
+ }
4243
+ declare const ServerRequestInfo: MessageFns$1<ServerRequestInfo>;
4148
4244
  interface ServiceUser {
4149
4245
  name: string;
4150
4246
  tokenId: string;
@@ -4427,6 +4523,7 @@ interface TokenFlowCreateRequest {
4427
4523
  utmSource: string;
4428
4524
  localhostPort: number;
4429
4525
  nextUrl: string;
4526
+ expiresInSeconds: number;
4430
4527
  }
4431
4528
  declare const TokenFlowCreateRequest: MessageFns$1<TokenFlowCreateRequest>;
4432
4529
  interface TokenFlowCreateResponse {
@@ -5717,6 +5814,14 @@ declare const ModalClientDefinition: {
5717
5814
  readonly responseStream: false;
5718
5815
  readonly options: {};
5719
5816
  };
5817
+ readonly functionCallFetch: {
5818
+ readonly name: "FunctionCallFetch";
5819
+ readonly requestType: MessageFns$1<FunctionCallFetchRequest>;
5820
+ readonly requestStream: false;
5821
+ readonly responseType: MessageFns$1<FunctionCallFetchResponse>;
5822
+ readonly responseStream: false;
5823
+ readonly options: {};
5824
+ };
5720
5825
  readonly functionCallFromId: {
5721
5826
  readonly name: "FunctionCallFromId";
5722
5827
  readonly requestType: MessageFns$1<FunctionCallFromIdRequest>;
@@ -5872,6 +5977,14 @@ declare const ModalClientDefinition: {
5872
5977
  readonly responseStream: false;
5873
5978
  readonly options: {};
5874
5979
  };
5980
+ readonly functionListVariants: {
5981
+ readonly name: "FunctionListVariants";
5982
+ readonly requestType: MessageFns$1<FunctionListVariantsRequest>;
5983
+ readonly requestStream: false;
5984
+ readonly responseType: MessageFns$1<FunctionListVariantsResponse>;
5985
+ readonly responseStream: false;
5986
+ readonly options: {};
5987
+ };
5875
5988
  readonly functionMap: {
5876
5989
  readonly name: "FunctionMap";
5877
5990
  readonly requestType: MessageFns$1<FunctionMapRequest>;
@@ -6539,6 +6652,14 @@ declare const ModalClientDefinition: {
6539
6652
  readonly responseStream: false;
6540
6653
  readonly options: {};
6541
6654
  };
6655
+ readonly serverRequestFetch: {
6656
+ readonly name: "ServerRequestFetch";
6657
+ readonly requestType: MessageFns$1<ServerRequestFetchRequest>;
6658
+ readonly requestStream: false;
6659
+ readonly responseType: MessageFns$1<ServerRequestFetchResponse>;
6660
+ readonly responseStream: false;
6661
+ readonly options: {};
6662
+ };
6542
6663
  /** Service users */
6543
6664
  readonly serviceUserList: {
6544
6665
  readonly name: "ServiceUserList";
package/dist/index.d.ts CHANGED
@@ -233,6 +233,20 @@ declare enum FileDescriptor {
233
233
  FILE_DESCRIPTOR_INFO = 3,
234
234
  UNRECOGNIZED = -1
235
235
  }
236
+ declare enum FunctionCallInputStatus {
237
+ FUNCTION_CALL_INPUT_STATUS_UNSPECIFIED = 0,
238
+ FUNCTION_CALL_INPUT_STATUS_PENDING = 1,
239
+ FUNCTION_CALL_INPUT_STATUS_RUNNING = 2,
240
+ FUNCTION_CALL_INPUT_STATUS_SUCCESS = 3,
241
+ FUNCTION_CALL_INPUT_STATUS_FAILURE = 4,
242
+ FUNCTION_CALL_INPUT_STATUS_TIMEOUT = 5,
243
+ FUNCTION_CALL_INPUT_STATUS_TERMINATED = 6,
244
+ FUNCTION_CALL_INPUT_STATUS_INIT_FAILURE = 7,
245
+ FUNCTION_CALL_INPUT_STATUS_INTERNAL_FAILURE = 8,
246
+ FUNCTION_CALL_INPUT_STATUS_IDLE_TIMEOUT = 9,
247
+ FUNCTION_CALL_INPUT_STATUS_MEMORY_MANAGER_EVICTION = 10,
248
+ UNRECOGNIZED = -1
249
+ }
236
250
  declare enum FunctionCallInvocationType {
237
251
  FUNCTION_CALL_INVOCATION_TYPE_UNSPECIFIED = 0,
238
252
  FUNCTION_CALL_INVOCATION_TYPE_SYNC_LEGACY = 1,
@@ -530,6 +544,11 @@ declare enum SandboxGetExitSnapshotResponse_ErrorCode {
530
544
  ERROR_CODE_UNSPECIFIED = 0,
531
545
  ERROR_CODE_TIMEOUT = 1,
532
546
  ERROR_CODE_INTERNAL = 2,
547
+ /**
548
+ * ERROR_CODE_FILESYSTEM_INCONSISTENT - The sandbox exited without leaving a consistent filesystem (e.g. killed
549
+ * before it could flush) and recovery failed, so no exit snapshot exists.
550
+ */
551
+ ERROR_CODE_FILESYSTEM_INCONSISTENT = 3,
533
552
  UNRECOGNIZED = -1
534
553
  }
535
554
  declare enum SandboxRestoreRequest_SandboxNameOverrideType {
@@ -2129,6 +2148,23 @@ interface FunctionCallCancelRequest {
2129
2148
  functionId?: string | undefined;
2130
2149
  }
2131
2150
  declare const FunctionCallCancelRequest: MessageFns$1<FunctionCallCancelRequest>;
2151
+ interface FunctionCallFetchRequest {
2152
+ functionId: string;
2153
+ tail?: FunctionCallFetchRequest_Tail | undefined;
2154
+ /** Include the root Function and its eligible variants. */
2155
+ allVariants: boolean;
2156
+ }
2157
+ declare const FunctionCallFetchRequest: MessageFns$1<FunctionCallFetchRequest>;
2158
+ interface FunctionCallFetchRequest_Tail {
2159
+ /** Number of most recent inputs to return. Must be between 1 and 1000. */
2160
+ count: number;
2161
+ }
2162
+ declare const FunctionCallFetchRequest_Tail: MessageFns$1<FunctionCallFetchRequest_Tail>;
2163
+ interface FunctionCallFetchResponse {
2164
+ /** The requested number of most recent inputs from the last seven days, ordered from newest to oldest. */
2165
+ functionCallInputs: FunctionCallInputInfo[];
2166
+ }
2167
+ declare const FunctionCallFetchResponse: MessageFns$1<FunctionCallFetchResponse>;
2132
2168
  interface FunctionCallFromIdRequest {
2133
2169
  functionCallId: string;
2134
2170
  }
@@ -2175,6 +2211,17 @@ interface FunctionCallInfo {
2175
2211
  totalInputs: number;
2176
2212
  }
2177
2213
  declare const FunctionCallInfo: MessageFns$1<FunctionCallInfo>;
2214
+ interface FunctionCallInputInfo {
2215
+ enqueuedAt: Date | undefined;
2216
+ startedAt?: Date | undefined;
2217
+ containerId?: string | undefined;
2218
+ startupTimeSeconds?: number | undefined;
2219
+ executionTimeSeconds?: number | undefined;
2220
+ status: FunctionCallInputStatus;
2221
+ functionCallId: string;
2222
+ serviceMethodName?: string | undefined;
2223
+ }
2224
+ declare const FunctionCallInputInfo: MessageFns$1<FunctionCallInputInfo>;
2178
2225
  interface FunctionCallListRequest {
2179
2226
  functionId: string;
2180
2227
  }
@@ -2548,6 +2595,20 @@ interface FunctionInput {
2548
2595
  methodName?: string | undefined;
2549
2596
  }
2550
2597
  declare const FunctionInput: MessageFns$1<FunctionInput>;
2598
+ interface FunctionListVariantsRequest {
2599
+ functionId: string;
2600
+ cursor: FunctionVariantCursor | undefined;
2601
+ limit: number;
2602
+ }
2603
+ declare const FunctionListVariantsRequest: MessageFns$1<FunctionListVariantsRequest>;
2604
+ interface FunctionListVariantsResponse {
2605
+ infos: FunctionVariantInfo[];
2606
+ /** Pass back as cursor to fetch the next page. Unset once the listing is complete. */
2607
+ nextCursor: FunctionVariantCursor | undefined;
2608
+ /** Set by the server when it ordered the variants by how many tasks each is running, busiest first. */
2609
+ orderedByTaskCount: boolean;
2610
+ }
2611
+ declare const FunctionListVariantsResponse: MessageFns$1<FunctionListVariantsResponse>;
2551
2612
  interface FunctionMapRequest {
2552
2613
  functionId: string;
2553
2614
  parentInputId: string;
@@ -2707,6 +2768,17 @@ interface FunctionUpdateSchedulingParamsResponse {
2707
2768
  currentSettings: AutoscalerSettings | undefined;
2708
2769
  }
2709
2770
  declare const FunctionUpdateSchedulingParamsResponse: MessageFns$1<FunctionUpdateSchedulingParamsResponse>;
2771
+ interface FunctionVariantCursor {
2772
+ createdBefore: number;
2773
+ functionId: string;
2774
+ }
2775
+ declare const FunctionVariantCursor: MessageFns$1<FunctionVariantCursor>;
2776
+ interface FunctionVariantInfo {
2777
+ functionId: string;
2778
+ serializedParams: Uint8Array;
2779
+ functionOptions: FunctionOptions$1 | undefined;
2780
+ }
2781
+ declare const FunctionVariantInfo: MessageFns$1<FunctionVariantInfo>;
2710
2782
  interface GPUConfig {
2711
2783
  /** Deprecated, at some point */
2712
2784
  type: GPUType;
@@ -4067,6 +4139,7 @@ declare const SecretListResponse: MessageFns$1<SecretListResponse>;
4067
4139
  interface SecretMetadata {
4068
4140
  name: string;
4069
4141
  creationInfo: CreationInfo | undefined;
4142
+ keys: string[];
4070
4143
  }
4071
4144
  declare const SecretMetadata: MessageFns$1<SecretMetadata>;
4072
4145
  interface SecretUpdateRequest {
@@ -4145,6 +4218,29 @@ interface ServerGetTimeRangeStatsResponse_ServerStatusCodeCount {
4145
4218
  count: number;
4146
4219
  }
4147
4220
  declare const ServerGetTimeRangeStatsResponse_ServerStatusCodeCount: MessageFns$1<ServerGetTimeRangeStatsResponse_ServerStatusCodeCount>;
4221
+ interface ServerRequestFetchRequest {
4222
+ functionId: string;
4223
+ tail?: ServerRequestFetchRequest_Tail | undefined;
4224
+ }
4225
+ declare const ServerRequestFetchRequest: MessageFns$1<ServerRequestFetchRequest>;
4226
+ interface ServerRequestFetchRequest_Tail {
4227
+ /** Number of most recent requests to return. Must be between 1 and 1000. */
4228
+ count: number;
4229
+ }
4230
+ declare const ServerRequestFetchRequest_Tail: MessageFns$1<ServerRequestFetchRequest_Tail>;
4231
+ interface ServerRequestFetchResponse {
4232
+ /** The requested number of most recent requests from the last seven days, ordered from newest to oldest. */
4233
+ requests: ServerRequestInfo[];
4234
+ }
4235
+ declare const ServerRequestFetchResponse: MessageFns$1<ServerRequestFetchResponse>;
4236
+ interface ServerRequestInfo {
4237
+ route: string;
4238
+ timestamp: Date | undefined;
4239
+ containerId: string;
4240
+ durationSeconds: number;
4241
+ status: number;
4242
+ }
4243
+ declare const ServerRequestInfo: MessageFns$1<ServerRequestInfo>;
4148
4244
  interface ServiceUser {
4149
4245
  name: string;
4150
4246
  tokenId: string;
@@ -4427,6 +4523,7 @@ interface TokenFlowCreateRequest {
4427
4523
  utmSource: string;
4428
4524
  localhostPort: number;
4429
4525
  nextUrl: string;
4526
+ expiresInSeconds: number;
4430
4527
  }
4431
4528
  declare const TokenFlowCreateRequest: MessageFns$1<TokenFlowCreateRequest>;
4432
4529
  interface TokenFlowCreateResponse {
@@ -5717,6 +5814,14 @@ declare const ModalClientDefinition: {
5717
5814
  readonly responseStream: false;
5718
5815
  readonly options: {};
5719
5816
  };
5817
+ readonly functionCallFetch: {
5818
+ readonly name: "FunctionCallFetch";
5819
+ readonly requestType: MessageFns$1<FunctionCallFetchRequest>;
5820
+ readonly requestStream: false;
5821
+ readonly responseType: MessageFns$1<FunctionCallFetchResponse>;
5822
+ readonly responseStream: false;
5823
+ readonly options: {};
5824
+ };
5720
5825
  readonly functionCallFromId: {
5721
5826
  readonly name: "FunctionCallFromId";
5722
5827
  readonly requestType: MessageFns$1<FunctionCallFromIdRequest>;
@@ -5872,6 +5977,14 @@ declare const ModalClientDefinition: {
5872
5977
  readonly responseStream: false;
5873
5978
  readonly options: {};
5874
5979
  };
5980
+ readonly functionListVariants: {
5981
+ readonly name: "FunctionListVariants";
5982
+ readonly requestType: MessageFns$1<FunctionListVariantsRequest>;
5983
+ readonly requestStream: false;
5984
+ readonly responseType: MessageFns$1<FunctionListVariantsResponse>;
5985
+ readonly responseStream: false;
5986
+ readonly options: {};
5987
+ };
5875
5988
  readonly functionMap: {
5876
5989
  readonly name: "FunctionMap";
5877
5990
  readonly requestType: MessageFns$1<FunctionMapRequest>;
@@ -6539,6 +6652,14 @@ declare const ModalClientDefinition: {
6539
6652
  readonly responseStream: false;
6540
6653
  readonly options: {};
6541
6654
  };
6655
+ readonly serverRequestFetch: {
6656
+ readonly name: "ServerRequestFetch";
6657
+ readonly requestType: MessageFns$1<ServerRequestFetchRequest>;
6658
+ readonly requestStream: false;
6659
+ readonly responseType: MessageFns$1<ServerRequestFetchResponse>;
6660
+ readonly responseStream: false;
6661
+ readonly options: {};
6662
+ };
6542
6663
  /** Service users */
6543
6664
  readonly serviceUserList: {
6544
6665
  readonly name: "ServiceUserList";