@effect-agent/storage-cloudflare 0.1.0-beta.90 → 0.1.0-beta.91

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.
@@ -421,10 +421,80 @@ declare const encodePortRequest: (input: LedgerAdmitCall | LedgerLookupCall | Le
421
421
  readonly createdAt: string;
422
422
  readonly deploymentId: string;
423
423
  readonly payload: {
424
- readonly _tag: "AbortRequested";
424
+ readonly _tag: "SubmissionSettled";
425
425
  readonly submissionId: string;
426
- readonly author: string;
427
- readonly reason: string;
426
+ readonly settlementId: string;
427
+ readonly receiptId: string;
428
+ readonly outcome: "aborted" | "completed" | "failed";
429
+ readonly runId?: string | undefined;
430
+ readonly result?: Schema.Json | undefined;
431
+ readonly runDisposition?: Schema.Json | undefined;
432
+ readonly finishReason?: "budget-exhausted" | undefined;
433
+ readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
434
+ readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
435
+ readonly usageSummary?: {
436
+ readonly modelCalls: number;
437
+ readonly inputTokens: {
438
+ readonly total: number;
439
+ readonly uncached: number;
440
+ readonly cacheRead: number;
441
+ readonly cacheWrite: number;
442
+ };
443
+ readonly outputTokens: {
444
+ readonly total: number;
445
+ readonly text: number;
446
+ readonly reasoning: number;
447
+ };
448
+ readonly costMicrousd: number;
449
+ readonly byModel: readonly {
450
+ readonly provider: string;
451
+ readonly model: string;
452
+ readonly responseModel?: string | undefined;
453
+ readonly serviceTier?: string | undefined;
454
+ readonly pricingVersion?: string | undefined;
455
+ readonly modelCalls: number;
456
+ readonly inputTokens: {
457
+ readonly total: number;
458
+ readonly uncached: number;
459
+ readonly cacheRead: number;
460
+ readonly cacheWrite: number;
461
+ };
462
+ readonly outputTokens: {
463
+ readonly total: number;
464
+ readonly text: number;
465
+ readonly reasoning: number;
466
+ };
467
+ readonly costMicrousd: number;
468
+ }[];
469
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
470
+ readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
471
+ readonly unobservedModelCalls?: number | undefined;
472
+ } | undefined;
473
+ readonly uncommittedModelUsage?: readonly {
474
+ readonly provider: string;
475
+ readonly model: string;
476
+ readonly serviceTier?: string | undefined;
477
+ readonly pricingVersion?: string | undefined;
478
+ readonly response?: {
479
+ readonly id?: string | undefined;
480
+ readonly model?: string | undefined;
481
+ } | undefined;
482
+ readonly purpose?: "summary" | "turn" | undefined;
483
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
484
+ readonly pricingStatus?: "estimated" | "unknown" | undefined;
485
+ readonly inputTokens: {
486
+ readonly total: number;
487
+ readonly uncached: number;
488
+ readonly cacheRead: number;
489
+ readonly cacheWrite: number;
490
+ };
491
+ readonly outputTokens: {
492
+ readonly total: number;
493
+ readonly text: number;
494
+ readonly reasoning: number;
495
+ };
496
+ readonly costMicrousd: number;
497
+ }[] | undefined;
428
498
  } | {
429
499
  readonly _tag: "ThreadCreated";
430
500
  readonly agentId: string;
@@ -670,80 +740,10 @@ declare const encodePortRequest: (input: LedgerAdmitCall | LedgerLookupCall | Le
670
740
  readonly finishReason?: "budget-exhausted" | undefined;
671
741
  readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
672
742
  } | {
673
- readonly _tag: "SubmissionSettled";
743
+ readonly _tag: "AbortRequested";
674
744
  readonly submissionId: string;
675
- readonly settlementId: string;
676
- readonly receiptId: string;
677
- readonly outcome: "aborted" | "completed" | "failed";
678
- readonly runId?: string | undefined;
679
- readonly result?: Schema.Json | undefined;
680
- readonly runDisposition?: Schema.Json | undefined;
681
- readonly finishReason?: "budget-exhausted" | undefined;
682
- readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
683
- readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
684
- readonly usageSummary?: {
685
- readonly modelCalls: number;
686
- readonly inputTokens: {
687
- readonly total: number;
688
- readonly uncached: number;
689
- readonly cacheRead: number;
690
- readonly cacheWrite: number;
691
- };
692
- readonly outputTokens: {
693
- readonly total: number;
694
- readonly text: number;
695
- readonly reasoning: number;
696
- };
697
- readonly costMicrousd: number;
698
- readonly byModel: readonly {
699
- readonly provider: string;
700
- readonly model: string;
701
- readonly responseModel?: string | undefined;
702
- readonly serviceTier?: string | undefined;
703
- readonly pricingVersion?: string | undefined;
704
- readonly modelCalls: number;
705
- readonly inputTokens: {
706
- readonly total: number;
707
- readonly uncached: number;
708
- readonly cacheRead: number;
709
- readonly cacheWrite: number;
710
- };
711
- readonly outputTokens: {
712
- readonly total: number;
713
- readonly text: number;
714
- readonly reasoning: number;
715
- };
716
- readonly costMicrousd: number;
717
- }[];
718
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
719
- readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
720
- readonly unobservedModelCalls?: number | undefined;
721
- } | undefined;
722
- readonly uncommittedModelUsage?: readonly {
723
- readonly provider: string;
724
- readonly model: string;
725
- readonly serviceTier?: string | undefined;
726
- readonly pricingVersion?: string | undefined;
727
- readonly response?: {
728
- readonly id?: string | undefined;
729
- readonly model?: string | undefined;
730
- } | undefined;
731
- readonly purpose?: "summary" | "turn" | undefined;
732
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
733
- readonly pricingStatus?: "estimated" | "unknown" | undefined;
734
- readonly inputTokens: {
735
- readonly total: number;
736
- readonly uncached: number;
737
- readonly cacheRead: number;
738
- readonly cacheWrite: number;
739
- };
740
- readonly outputTokens: {
741
- readonly total: number;
742
- readonly text: number;
743
- readonly reasoning: number;
744
- };
745
- readonly costMicrousd: number;
746
- }[] | undefined;
745
+ readonly author: string;
746
+ readonly reason: string;
747
747
  } | {
748
748
  readonly _tag: "SubagentRequested";
749
749
  readonly runId: string;
@@ -1130,10 +1130,80 @@ declare const encodePortRequest: (input: LedgerAdmitCall | LedgerLookupCall | Le
1130
1130
  readonly createdAt: string;
1131
1131
  readonly deploymentId: string;
1132
1132
  readonly payload: {
1133
- readonly _tag: "AbortRequested";
1133
+ readonly _tag: "SubmissionSettled";
1134
1134
  readonly submissionId: string;
1135
- readonly author: string;
1136
- readonly reason: string;
1135
+ readonly settlementId: string;
1136
+ readonly receiptId: string;
1137
+ readonly outcome: "aborted" | "completed" | "failed";
1138
+ readonly runId?: string | undefined;
1139
+ readonly result?: Schema.Json | undefined;
1140
+ readonly runDisposition?: Schema.Json | undefined;
1141
+ readonly finishReason?: "budget-exhausted" | undefined;
1142
+ readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
1143
+ readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
1144
+ readonly usageSummary?: {
1145
+ readonly modelCalls: number;
1146
+ readonly inputTokens: {
1147
+ readonly total: number;
1148
+ readonly uncached: number;
1149
+ readonly cacheRead: number;
1150
+ readonly cacheWrite: number;
1151
+ };
1152
+ readonly outputTokens: {
1153
+ readonly total: number;
1154
+ readonly text: number;
1155
+ readonly reasoning: number;
1156
+ };
1157
+ readonly costMicrousd: number;
1158
+ readonly byModel: readonly {
1159
+ readonly provider: string;
1160
+ readonly model: string;
1161
+ readonly responseModel?: string | undefined;
1162
+ readonly serviceTier?: string | undefined;
1163
+ readonly pricingVersion?: string | undefined;
1164
+ readonly modelCalls: number;
1165
+ readonly inputTokens: {
1166
+ readonly total: number;
1167
+ readonly uncached: number;
1168
+ readonly cacheRead: number;
1169
+ readonly cacheWrite: number;
1170
+ };
1171
+ readonly outputTokens: {
1172
+ readonly total: number;
1173
+ readonly text: number;
1174
+ readonly reasoning: number;
1175
+ };
1176
+ readonly costMicrousd: number;
1177
+ }[];
1178
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
1179
+ readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
1180
+ readonly unobservedModelCalls?: number | undefined;
1181
+ } | undefined;
1182
+ readonly uncommittedModelUsage?: readonly {
1183
+ readonly provider: string;
1184
+ readonly model: string;
1185
+ readonly serviceTier?: string | undefined;
1186
+ readonly pricingVersion?: string | undefined;
1187
+ readonly response?: {
1188
+ readonly id?: string | undefined;
1189
+ readonly model?: string | undefined;
1190
+ } | undefined;
1191
+ readonly purpose?: "summary" | "turn" | undefined;
1192
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
1193
+ readonly pricingStatus?: "estimated" | "unknown" | undefined;
1194
+ readonly inputTokens: {
1195
+ readonly total: number;
1196
+ readonly uncached: number;
1197
+ readonly cacheRead: number;
1198
+ readonly cacheWrite: number;
1199
+ };
1200
+ readonly outputTokens: {
1201
+ readonly total: number;
1202
+ readonly text: number;
1203
+ readonly reasoning: number;
1204
+ };
1205
+ readonly costMicrousd: number;
1206
+ }[] | undefined;
1137
1207
  } | {
1138
1208
  readonly _tag: "ThreadCreated";
1139
1209
  readonly agentId: string;
@@ -1379,80 +1449,10 @@ declare const encodePortRequest: (input: LedgerAdmitCall | LedgerLookupCall | Le
1379
1449
  readonly finishReason?: "budget-exhausted" | undefined;
1380
1450
  readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
1381
1451
  } | {
1382
- readonly _tag: "SubmissionSettled";
1452
+ readonly _tag: "AbortRequested";
1383
1453
  readonly submissionId: string;
1384
- readonly settlementId: string;
1385
- readonly receiptId: string;
1386
- readonly outcome: "aborted" | "completed" | "failed";
1387
- readonly runId?: string | undefined;
1388
- readonly result?: Schema.Json | undefined;
1389
- readonly runDisposition?: Schema.Json | undefined;
1390
- readonly finishReason?: "budget-exhausted" | undefined;
1391
- readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
1392
- readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
1393
- readonly usageSummary?: {
1394
- readonly modelCalls: number;
1395
- readonly inputTokens: {
1396
- readonly total: number;
1397
- readonly uncached: number;
1398
- readonly cacheRead: number;
1399
- readonly cacheWrite: number;
1400
- };
1401
- readonly outputTokens: {
1402
- readonly total: number;
1403
- readonly text: number;
1404
- readonly reasoning: number;
1405
- };
1406
- readonly costMicrousd: number;
1407
- readonly byModel: readonly {
1408
- readonly provider: string;
1409
- readonly model: string;
1410
- readonly responseModel?: string | undefined;
1411
- readonly serviceTier?: string | undefined;
1412
- readonly pricingVersion?: string | undefined;
1413
- readonly modelCalls: number;
1414
- readonly inputTokens: {
1415
- readonly total: number;
1416
- readonly uncached: number;
1417
- readonly cacheRead: number;
1418
- readonly cacheWrite: number;
1419
- };
1420
- readonly outputTokens: {
1421
- readonly total: number;
1422
- readonly text: number;
1423
- readonly reasoning: number;
1424
- };
1425
- readonly costMicrousd: number;
1426
- }[];
1427
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
1428
- readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
1429
- readonly unobservedModelCalls?: number | undefined;
1430
- } | undefined;
1431
- readonly uncommittedModelUsage?: readonly {
1432
- readonly provider: string;
1433
- readonly model: string;
1434
- readonly serviceTier?: string | undefined;
1435
- readonly pricingVersion?: string | undefined;
1436
- readonly response?: {
1437
- readonly id?: string | undefined;
1438
- readonly model?: string | undefined;
1439
- } | undefined;
1440
- readonly purpose?: "summary" | "turn" | undefined;
1441
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
1442
- readonly pricingStatus?: "estimated" | "unknown" | undefined;
1443
- readonly inputTokens: {
1444
- readonly total: number;
1445
- readonly uncached: number;
1446
- readonly cacheRead: number;
1447
- readonly cacheWrite: number;
1448
- };
1449
- readonly outputTokens: {
1450
- readonly total: number;
1451
- readonly text: number;
1452
- readonly reasoning: number;
1453
- };
1454
- readonly costMicrousd: number;
1455
- }[] | undefined;
1454
+ readonly author: string;
1455
+ readonly reason: string;
1456
1456
  } | {
1457
1457
  readonly _tag: "SubagentRequested";
1458
1458
  readonly runId: string;
@@ -2310,10 +2310,80 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
2310
2310
  readonly createdAt: string;
2311
2311
  readonly deploymentId: string;
2312
2312
  readonly payload: {
2313
- readonly _tag: "AbortRequested";
2313
+ readonly _tag: "SubmissionSettled";
2314
2314
  readonly submissionId: string;
2315
- readonly author: string;
2316
- readonly reason: string;
2315
+ readonly settlementId: string;
2316
+ readonly receiptId: string;
2317
+ readonly outcome: "aborted" | "completed" | "failed";
2318
+ readonly runId?: string | undefined;
2319
+ readonly result?: Schema.Json | undefined;
2320
+ readonly runDisposition?: Schema.Json | undefined;
2321
+ readonly finishReason?: "budget-exhausted" | undefined;
2322
+ readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
2323
+ readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
2324
+ readonly usageSummary?: {
2325
+ readonly modelCalls: number;
2326
+ readonly inputTokens: {
2327
+ readonly total: number;
2328
+ readonly uncached: number;
2329
+ readonly cacheRead: number;
2330
+ readonly cacheWrite: number;
2331
+ };
2332
+ readonly outputTokens: {
2333
+ readonly total: number;
2334
+ readonly text: number;
2335
+ readonly reasoning: number;
2336
+ };
2337
+ readonly costMicrousd: number;
2338
+ readonly byModel: readonly {
2339
+ readonly provider: string;
2340
+ readonly model: string;
2341
+ readonly responseModel?: string | undefined;
2342
+ readonly serviceTier?: string | undefined;
2343
+ readonly pricingVersion?: string | undefined;
2344
+ readonly modelCalls: number;
2345
+ readonly inputTokens: {
2346
+ readonly total: number;
2347
+ readonly uncached: number;
2348
+ readonly cacheRead: number;
2349
+ readonly cacheWrite: number;
2350
+ };
2351
+ readonly outputTokens: {
2352
+ readonly total: number;
2353
+ readonly text: number;
2354
+ readonly reasoning: number;
2355
+ };
2356
+ readonly costMicrousd: number;
2357
+ }[];
2358
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
2359
+ readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
2360
+ readonly unobservedModelCalls?: number | undefined;
2361
+ } | undefined;
2362
+ readonly uncommittedModelUsage?: readonly {
2363
+ readonly provider: string;
2364
+ readonly model: string;
2365
+ readonly serviceTier?: string | undefined;
2366
+ readonly pricingVersion?: string | undefined;
2367
+ readonly response?: {
2368
+ readonly id?: string | undefined;
2369
+ readonly model?: string | undefined;
2370
+ } | undefined;
2371
+ readonly purpose?: "summary" | "turn" | undefined;
2372
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
2373
+ readonly pricingStatus?: "estimated" | "unknown" | undefined;
2374
+ readonly inputTokens: {
2375
+ readonly total: number;
2376
+ readonly uncached: number;
2377
+ readonly cacheRead: number;
2378
+ readonly cacheWrite: number;
2379
+ };
2380
+ readonly outputTokens: {
2381
+ readonly total: number;
2382
+ readonly text: number;
2383
+ readonly reasoning: number;
2384
+ };
2385
+ readonly costMicrousd: number;
2386
+ }[] | undefined;
2317
2387
  } | {
2318
2388
  readonly _tag: "ThreadCreated";
2319
2389
  readonly agentId: string;
@@ -2550,89 +2620,19 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
2550
2620
  } | {
2551
2621
  readonly _tag: "RunFailed";
2552
2622
  readonly runId: string;
2553
- readonly failure: Schema.Json;
2554
- } | {
2555
- readonly _tag: "RunCompleted";
2556
- readonly runId: string;
2557
- readonly output: Schema.Json;
2558
- readonly runDisposition?: Schema.Json | undefined;
2559
- readonly finishReason?: "budget-exhausted" | undefined;
2560
- readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
2561
- } | {
2562
- readonly _tag: "SubmissionSettled";
2563
- readonly submissionId: string;
2564
- readonly settlementId: string;
2565
- readonly receiptId: string;
2566
- readonly outcome: "aborted" | "completed" | "failed";
2567
- readonly runId?: string | undefined;
2568
- readonly result?: Schema.Json | undefined;
2623
+ readonly failure: Schema.Json;
2624
+ } | {
2625
+ readonly _tag: "RunCompleted";
2626
+ readonly runId: string;
2627
+ readonly output: Schema.Json;
2569
2628
  readonly runDisposition?: Schema.Json | undefined;
2570
2629
  readonly finishReason?: "budget-exhausted" | undefined;
2571
2630
  readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
2572
- readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
2573
- readonly usageSummary?: {
2574
- readonly modelCalls: number;
2575
- readonly inputTokens: {
2576
- readonly total: number;
2577
- readonly uncached: number;
2578
- readonly cacheRead: number;
2579
- readonly cacheWrite: number;
2580
- };
2581
- readonly outputTokens: {
2582
- readonly total: number;
2583
- readonly text: number;
2584
- readonly reasoning: number;
2585
- };
2586
- readonly costMicrousd: number;
2587
- readonly byModel: readonly {
2588
- readonly provider: string;
2589
- readonly model: string;
2590
- readonly responseModel?: string | undefined;
2591
- readonly serviceTier?: string | undefined;
2592
- readonly pricingVersion?: string | undefined;
2593
- readonly modelCalls: number;
2594
- readonly inputTokens: {
2595
- readonly total: number;
2596
- readonly uncached: number;
2597
- readonly cacheRead: number;
2598
- readonly cacheWrite: number;
2599
- };
2600
- readonly outputTokens: {
2601
- readonly total: number;
2602
- readonly text: number;
2603
- readonly reasoning: number;
2604
- };
2605
- readonly costMicrousd: number;
2606
- }[];
2607
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
2608
- readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
2609
- readonly unobservedModelCalls?: number | undefined;
2610
- } | undefined;
2611
- readonly uncommittedModelUsage?: readonly {
2612
- readonly provider: string;
2613
- readonly model: string;
2614
- readonly serviceTier?: string | undefined;
2615
- readonly pricingVersion?: string | undefined;
2616
- readonly response?: {
2617
- readonly id?: string | undefined;
2618
- readonly model?: string | undefined;
2619
- } | undefined;
2620
- readonly purpose?: "summary" | "turn" | undefined;
2621
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
2622
- readonly pricingStatus?: "estimated" | "unknown" | undefined;
2623
- readonly inputTokens: {
2624
- readonly total: number;
2625
- readonly uncached: number;
2626
- readonly cacheRead: number;
2627
- readonly cacheWrite: number;
2628
- };
2629
- readonly outputTokens: {
2630
- readonly total: number;
2631
- readonly text: number;
2632
- readonly reasoning: number;
2633
- };
2634
- readonly costMicrousd: number;
2635
- }[] | undefined;
2631
+ } | {
2632
+ readonly _tag: "AbortRequested";
2633
+ readonly submissionId: string;
2634
+ readonly author: string;
2635
+ readonly reason: string;
2636
2636
  } | {
2637
2637
  readonly _tag: "SubagentRequested";
2638
2638
  readonly runId: string;
@@ -3041,10 +3041,80 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
3041
3041
  readonly createdAt: string;
3042
3042
  readonly deploymentId: string;
3043
3043
  readonly payload: {
3044
- readonly _tag: "AbortRequested";
3044
+ readonly _tag: "SubmissionSettled";
3045
3045
  readonly submissionId: string;
3046
- readonly author: string;
3047
- readonly reason: string;
3046
+ readonly settlementId: string;
3047
+ readonly receiptId: string;
3048
+ readonly outcome: "aborted" | "completed" | "failed";
3049
+ readonly runId?: string | undefined;
3050
+ readonly result?: Schema.Json | undefined;
3051
+ readonly runDisposition?: Schema.Json | undefined;
3052
+ readonly finishReason?: "budget-exhausted" | undefined;
3053
+ readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
3054
+ readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
3055
+ readonly usageSummary?: {
3056
+ readonly modelCalls: number;
3057
+ readonly inputTokens: {
3058
+ readonly total: number;
3059
+ readonly uncached: number;
3060
+ readonly cacheRead: number;
3061
+ readonly cacheWrite: number;
3062
+ };
3063
+ readonly outputTokens: {
3064
+ readonly total: number;
3065
+ readonly text: number;
3066
+ readonly reasoning: number;
3067
+ };
3068
+ readonly costMicrousd: number;
3069
+ readonly byModel: readonly {
3070
+ readonly provider: string;
3071
+ readonly model: string;
3072
+ readonly responseModel?: string | undefined;
3073
+ readonly serviceTier?: string | undefined;
3074
+ readonly pricingVersion?: string | undefined;
3075
+ readonly modelCalls: number;
3076
+ readonly inputTokens: {
3077
+ readonly total: number;
3078
+ readonly uncached: number;
3079
+ readonly cacheRead: number;
3080
+ readonly cacheWrite: number;
3081
+ };
3082
+ readonly outputTokens: {
3083
+ readonly total: number;
3084
+ readonly text: number;
3085
+ readonly reasoning: number;
3086
+ };
3087
+ readonly costMicrousd: number;
3088
+ }[];
3089
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
3090
+ readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
3091
+ readonly unobservedModelCalls?: number | undefined;
3092
+ } | undefined;
3093
+ readonly uncommittedModelUsage?: readonly {
3094
+ readonly provider: string;
3095
+ readonly model: string;
3096
+ readonly serviceTier?: string | undefined;
3097
+ readonly pricingVersion?: string | undefined;
3098
+ readonly response?: {
3099
+ readonly id?: string | undefined;
3100
+ readonly model?: string | undefined;
3101
+ } | undefined;
3102
+ readonly purpose?: "summary" | "turn" | undefined;
3103
+ readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
3104
+ readonly pricingStatus?: "estimated" | "unknown" | undefined;
3105
+ readonly inputTokens: {
3106
+ readonly total: number;
3107
+ readonly uncached: number;
3108
+ readonly cacheRead: number;
3109
+ readonly cacheWrite: number;
3110
+ };
3111
+ readonly outputTokens: {
3112
+ readonly total: number;
3113
+ readonly text: number;
3114
+ readonly reasoning: number;
3115
+ };
3116
+ readonly costMicrousd: number;
3117
+ }[] | undefined;
3048
3118
  } | {
3049
3119
  readonly _tag: "ThreadCreated";
3050
3120
  readonly agentId: string;
@@ -3290,80 +3360,10 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
3290
3360
  readonly finishReason?: "budget-exhausted" | undefined;
3291
3361
  readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
3292
3362
  } | {
3293
- readonly _tag: "SubmissionSettled";
3363
+ readonly _tag: "AbortRequested";
3294
3364
  readonly submissionId: string;
3295
- readonly settlementId: string;
3296
- readonly receiptId: string;
3297
- readonly outcome: "aborted" | "completed" | "failed";
3298
- readonly runId?: string | undefined;
3299
- readonly result?: Schema.Json | undefined;
3300
- readonly runDisposition?: Schema.Json | undefined;
3301
- readonly finishReason?: "budget-exhausted" | undefined;
3302
- readonly exhausted?: "tokens" | "tool-calls" | "turns" | undefined;
3303
- readonly policyLimit?: "cost" | "duration" | "repeated-failures" | "tokens" | "tool-calls" | "turns" | "usage" | undefined;
3304
- readonly usageSummary?: {
3305
- readonly modelCalls: number;
3306
- readonly inputTokens: {
3307
- readonly total: number;
3308
- readonly uncached: number;
3309
- readonly cacheRead: number;
3310
- readonly cacheWrite: number;
3311
- };
3312
- readonly outputTokens: {
3313
- readonly total: number;
3314
- readonly text: number;
3315
- readonly reasoning: number;
3316
- };
3317
- readonly costMicrousd: number;
3318
- readonly byModel: readonly {
3319
- readonly provider: string;
3320
- readonly model: string;
3321
- readonly responseModel?: string | undefined;
3322
- readonly serviceTier?: string | undefined;
3323
- readonly pricingVersion?: string | undefined;
3324
- readonly modelCalls: number;
3325
- readonly inputTokens: {
3326
- readonly total: number;
3327
- readonly uncached: number;
3328
- readonly cacheRead: number;
3329
- readonly cacheWrite: number;
3330
- };
3331
- readonly outputTokens: {
3332
- readonly total: number;
3333
- readonly text: number;
3334
- readonly reasoning: number;
3335
- };
3336
- readonly costMicrousd: number;
3337
- }[];
3338
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
3339
- readonly pricingStatus?: "complete" | "partial" | "unknown" | undefined;
3340
- readonly unobservedModelCalls?: number | undefined;
3341
- } | undefined;
3342
- readonly uncommittedModelUsage?: readonly {
3343
- readonly provider: string;
3344
- readonly model: string;
3345
- readonly serviceTier?: string | undefined;
3346
- readonly pricingVersion?: string | undefined;
3347
- readonly response?: {
3348
- readonly id?: string | undefined;
3349
- readonly model?: string | undefined;
3350
- } | undefined;
3351
- readonly purpose?: "summary" | "turn" | undefined;
3352
- readonly usageStatus?: "complete" | "partial" | "unknown" | undefined;
3353
- readonly pricingStatus?: "estimated" | "unknown" | undefined;
3354
- readonly inputTokens: {
3355
- readonly total: number;
3356
- readonly uncached: number;
3357
- readonly cacheRead: number;
3358
- readonly cacheWrite: number;
3359
- };
3360
- readonly outputTokens: {
3361
- readonly total: number;
3362
- readonly text: number;
3363
- readonly reasoning: number;
3364
- };
3365
- readonly costMicrousd: number;
3366
- }[] | undefined;
3365
+ readonly author: string;
3366
+ readonly reason: string;
3367
3367
  } | {
3368
3368
  readonly _tag: "SubagentRequested";
3369
3369
  readonly runId: string;
@@ -3752,26 +3752,14 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
3752
3752
  readonly failure: {
3753
3753
  readonly _tag: "PortProtocolError";
3754
3754
  readonly message: string;
3755
- } | {
3756
- readonly _tag: "FenceRejected";
3757
- readonly threadId: string;
3758
- readonly actualEpoch: number;
3759
- readonly attemptedEpoch: number;
3760
- } | {
3761
- readonly _tag: "ThreadStoreError";
3762
- readonly operation: string;
3763
- readonly message: string;
3764
- readonly cause?: Schema.Json | undefined;
3765
3755
  } | {
3766
3756
  readonly _tag: "ThreadNotMaterialized";
3767
3757
  readonly threadId: string;
3768
3758
  } | {
3769
- readonly _tag: "AppendConflict";
3759
+ readonly _tag: "FenceRejected";
3770
3760
  readonly threadId: string;
3771
- readonly batchId: string;
3772
- readonly reason: "batch-digest" | "record-identity" | "tail";
3773
- readonly actualTailSequence?: number | undefined;
3774
- readonly actualTailDigest?: string | undefined;
3761
+ readonly actualEpoch: number;
3762
+ readonly attemptedEpoch: number;
3775
3763
  } | {
3776
3764
  readonly _tag: "AdmissionConflict";
3777
3765
  readonly threadId: string;
@@ -3792,6 +3780,18 @@ declare const encodePortResponse: (input: PortFailed | PortSucceeded, options?:
3792
3780
  readonly _tag: "SettlementConflict";
3793
3781
  readonly submissionId: string;
3794
3782
  readonly existingOutcome: "aborted" | "completed" | "failed";
3783
+ } | {
3784
+ readonly _tag: "ThreadStoreError";
3785
+ readonly operation: string;
3786
+ readonly message: string;
3787
+ readonly cause?: Schema.Json | undefined;
3788
+ } | {
3789
+ readonly _tag: "AppendConflict";
3790
+ readonly threadId: string;
3791
+ readonly batchId: string;
3792
+ readonly reason: "batch-digest" | "record-identity" | "tail";
3793
+ readonly actualTailSequence?: number | undefined;
3794
+ readonly actualTailDigest?: string | undefined;
3795
3795
  } | {
3796
3796
  readonly _tag: "JoinedToHost";
3797
3797
  readonly submissionId: string;
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"@effect-agent/storage-cloudflare","version":"0.1.0-beta.90","dependencies":{"@effect/platform-browser":"4.0.0-rc.112","@effect/sql-sqlite-do":"4.0.0-rc.112","effect-agent":"0.1.0-beta.90"},"devDependencies":{"@cloudflare/vitest-pool-workers":"0.21.3","@cloudflare/workers-types":"5.20260825.1","@effect-agent/testing":"0.1.0-beta.90","@effect/vitest":"4.0.0-rc.112","effect":"4.0.0-rc.112","typescript":"7.0.2","vite-plus":"0.3.0","vitest":"4.1.11"},"peerDependencies":{"effect":"^4.0.0-rc.112"},"exports":{".":{"types":"./dist/index.d.mts","default":"./dist/index.mjs"},"./do-memory-store":{"types":"./dist/DoMemoryStore.d.mts","default":"./dist/DoMemoryStore.mjs"},"./do-schedule-store":{"types":"./dist/DoScheduleStore.d.mts","default":"./dist/DoScheduleStore.mjs"},"./do-storage-config":{"types":"./dist/DoStorageConfig.d.mts","default":"./dist/DoStorageConfig.mjs"},"./do-storage-error":{"types":"./dist/DoStorageError.d.mts","default":"./dist/DoStorageError.mjs"},"./do-storage-failpoint":{"types":"./dist/DoStorageFailpoint.d.mts","default":"./dist/DoStorageFailpoint.mjs"},"./do-storage-version":{"types":"./dist/DoStorageVersion.d.mts","default":"./dist/DoStorageVersion.mjs"},"./do-submission-ledger":{"types":"./dist/DoSubmissionLedger.d.mts","default":"./dist/DoSubmissionLedger.mjs"},"./do-subscription-store":{"types":"./dist/DoSubscriptionStore.d.mts","default":"./dist/DoSubscriptionStore.mjs"},"./do-thread-store":{"types":"./dist/DoThreadStore.d.mts","default":"./dist/DoThreadStore.mjs"},"./memory-protocol":{"types":"./dist/MemoryProtocol.d.mts","default":"./dist/MemoryProtocol.mjs"},"./port-protocol":{"types":"./dist/PortProtocol.d.mts","default":"./dist/PortProtocol.mjs"},"./port-routing":{"types":"./dist/PortRouting.d.mts","default":"./dist/PortRouting.mjs"},"./testing/do-storage-failpoint-testing":{"types":"./dist/DoStorageFailpointTesting.d.mts","default":"./dist/DoStorageFailpointTesting.mjs"},"./do-message-delivery-store":{"types":"./dist/DoMessageDeliveryStore.d.mts","default":"./dist/DoMessageDeliveryStore.mjs"}},"description":"Durable Object SQLite storage adapters and the routed port protocol for Effect Agent on Cloudflare.","license":"MIT","repository":{"type":"git","url":"git+https://github.com/danieljvdm/effect-agent.git","directory":"packages/storage-cloudflare"},"files":["dist","src"],"type":"module","sideEffects":[],"publishConfig":{"access":"public"},"scripts":{"build":"vp pack","check":"tsc --noEmit -p tsconfig.json"}}
1
+ {"name":"@effect-agent/storage-cloudflare","version":"0.1.0-beta.91","dependencies":{"@effect/platform-browser":"4.0.0-rc.112","@effect/sql-sqlite-do":"4.0.0-rc.112","effect-agent":"0.1.0-beta.91"},"devDependencies":{"@cloudflare/vitest-pool-workers":"0.21.3","@cloudflare/workers-types":"5.20260825.1","@effect-agent/testing":"0.1.0-beta.91","@effect/vitest":"4.0.0-rc.112","effect":"4.0.0-rc.112","typescript":"7.0.2","vite-plus":"0.3.0","vitest":"4.1.11"},"peerDependencies":{"effect":"^4.0.0-rc.112"},"exports":{".":{"types":"./dist/index.d.mts","default":"./dist/index.mjs"},"./do-memory-store":{"types":"./dist/DoMemoryStore.d.mts","default":"./dist/DoMemoryStore.mjs"},"./do-schedule-store":{"types":"./dist/DoScheduleStore.d.mts","default":"./dist/DoScheduleStore.mjs"},"./do-storage-config":{"types":"./dist/DoStorageConfig.d.mts","default":"./dist/DoStorageConfig.mjs"},"./do-storage-error":{"types":"./dist/DoStorageError.d.mts","default":"./dist/DoStorageError.mjs"},"./do-storage-failpoint":{"types":"./dist/DoStorageFailpoint.d.mts","default":"./dist/DoStorageFailpoint.mjs"},"./do-storage-version":{"types":"./dist/DoStorageVersion.d.mts","default":"./dist/DoStorageVersion.mjs"},"./do-submission-ledger":{"types":"./dist/DoSubmissionLedger.d.mts","default":"./dist/DoSubmissionLedger.mjs"},"./do-subscription-store":{"types":"./dist/DoSubscriptionStore.d.mts","default":"./dist/DoSubscriptionStore.mjs"},"./do-thread-store":{"types":"./dist/DoThreadStore.d.mts","default":"./dist/DoThreadStore.mjs"},"./memory-protocol":{"types":"./dist/MemoryProtocol.d.mts","default":"./dist/MemoryProtocol.mjs"},"./port-protocol":{"types":"./dist/PortProtocol.d.mts","default":"./dist/PortProtocol.mjs"},"./port-routing":{"types":"./dist/PortRouting.d.mts","default":"./dist/PortRouting.mjs"},"./testing/do-storage-failpoint-testing":{"types":"./dist/DoStorageFailpointTesting.d.mts","default":"./dist/DoStorageFailpointTesting.mjs"},"./do-message-delivery-store":{"types":"./dist/DoMessageDeliveryStore.d.mts","default":"./dist/DoMessageDeliveryStore.mjs"}},"description":"Durable Object SQLite storage adapters and the routed port protocol for Effect Agent on Cloudflare.","license":"MIT","repository":{"type":"git","url":"git+https://github.com/danieljvdm/effect-agent.git","directory":"packages/storage-cloudflare"},"files":["dist","src"],"type":"module","sideEffects":[],"publishConfig":{"access":"public"},"scripts":{"build":"vp pack","check":"tsc --noEmit -p tsconfig.json"}}