@polyester/sdk 0.36.0-devnet-20261118141710 → 0.36.0-devnet-20261118184607
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/CHANGELOG.md +5 -1
- package/dist/realtime/ready-gated-subscription.js +1 -1
- package/dist/realtime/snapshot-then-stream.js +2 -0
- package/dist/realtime/snapshot-then-stream.js.map +1 -1
- package/dist/services/account-activity/account-activity.schemas.d.ts +2 -2
- package/dist/services/assistant/assistant-events.schemas.d.ts +27 -27
- package/dist/services/assistant/assistant.schemas.d.ts +1 -1
- package/dist/services/auto-withdraw/auto-withdraw.schemas.d.ts +3 -3
- package/dist/services/candles/candles.schemas.d.ts +10 -10
- package/dist/services/changelog/changelog.schemas.d.ts +38 -38
- package/dist/services/checkpoints/checkpoints.schemas.d.ts +1 -1
- package/dist/services/claims/claims.schemas.d.ts +2 -2
- package/dist/services/dust-conversion/dust-conversion.schemas.d.ts +2 -2
- package/dist/services/heatmap/heatmap.schemas.d.ts +4 -4
- package/dist/services/internal-transfers/internal-transfers.schemas.d.ts +6 -6
- package/dist/services/lifecycle/lifecycle.js +1 -1
- package/dist/services/lifecycle/lifecycle.js.map +1 -1
- package/dist/services/lifecycle/lifecycle.schemas.d.ts +39 -39
- package/dist/services/orderbook/orderbook.js +1 -1
- package/dist/services/orders/order-errors.schemas.d.ts +9 -9
- package/dist/services/orders/orders-batch.schemas.d.ts +102 -102
- package/dist/services/orders/orders-input.schemas.d.ts +15 -15
- package/dist/services/orders/orders-output.schemas.d.ts +14 -14
- package/dist/services/orders/orders.d.ts.map +1 -1
- package/dist/services/orders/orders.js +47 -43
- package/dist/services/orders/orders.js.map +1 -1
- package/dist/services/rewards/rewards.schemas.d.ts +4 -4
- package/dist/services/statement-exports/statement-exports.schemas.d.ts +6 -6
- package/dist/services/subaccounts/subaccounts.schemas.d.ts +4 -4
- package/dist/services/system/system.schemas.d.ts +13 -13
- package/dist/services/trades/trades.d.ts.map +1 -1
- package/dist/services/trades/trades.js +12 -4
- package/dist/services/trades/trades.js.map +1 -1
- package/dist/services/trades/trades.schemas.d.ts +1 -1
- package/dist/services/triggers/trigger-input.schemas.d.ts +1 -1
- package/dist/services/triggers/triggers-output.schemas.d.ts +50 -50
- package/dist/services/triggers/triggers.d.ts.map +1 -1
- package/dist/services/triggers/triggers.js +14 -10
- package/dist/services/triggers/triggers.js.map +1 -1
- package/dist/shared/connect-error-mapping.d.ts.map +1 -1
- package/dist/shared/connect-error-mapping.js +4 -1
- package/dist/shared/connect-error-mapping.js.map +1 -1
- package/dist/shared/decimal-surface.d.ts +6 -0
- package/dist/shared/decimal-surface.d.ts.map +1 -1
- package/dist/shared/decimal-surface.js +65 -1
- package/dist/shared/decimal-surface.js.map +1 -1
- package/dist/shared/rate-limit.schemas.d.ts +1 -1
- package/package.json +1 -1
|
@@ -31,7 +31,7 @@ declare const ListChangelogChangesInputSchema: v.SchemaWithPipe<readonly [v.Stri
|
|
|
31
31
|
}, undefined>, v.CheckAction<{
|
|
32
32
|
categories: ("breaking_change" | "new_feature" | "improvement" | "bug_fix")[];
|
|
33
33
|
actionRequired?: boolean | undefined;
|
|
34
|
-
surfaces: ("assistant" | "
|
|
34
|
+
surfaces: ("assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
35
35
|
audiences: ("all_users" | "traders" | "market_makers" | "developers")[];
|
|
36
36
|
startTime?: number | undefined;
|
|
37
37
|
endTime?: number | undefined;
|
|
@@ -42,7 +42,7 @@ declare const ListChangelogChangesInputSchema: v.SchemaWithPipe<readonly [v.Stri
|
|
|
42
42
|
}, "endTime: must be after startTime">, v.TransformAction<{
|
|
43
43
|
categories: ("breaking_change" | "new_feature" | "improvement" | "bug_fix")[];
|
|
44
44
|
actionRequired?: boolean | undefined;
|
|
45
|
-
surfaces: ("assistant" | "
|
|
45
|
+
surfaces: ("assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
46
46
|
audiences: ("all_users" | "traders" | "market_makers" | "developers")[];
|
|
47
47
|
startTime?: number | undefined;
|
|
48
48
|
endTime?: number | undefined;
|
|
@@ -77,10 +77,10 @@ declare const ChangelogChangeSchema: v.ObjectSchema<{
|
|
|
77
77
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
78
78
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
79
79
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
80
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
80
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
81
81
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
82
82
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
83
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
83
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
84
84
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
85
85
|
readonly seconds: v.BigintSchema<undefined>;
|
|
86
86
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -95,7 +95,7 @@ type ChangelogChange = v.InferOutput<typeof ChangelogChangeSchema>;
|
|
|
95
95
|
declare const ChangelogSectionSchema: v.ObjectSchema<{
|
|
96
96
|
readonly heading: v.StringSchema<undefined>;
|
|
97
97
|
readonly summary: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
98
|
-
readonly surface: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
98
|
+
readonly surface: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>;
|
|
99
99
|
readonly changes: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
100
100
|
readonly id: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
|
|
101
101
|
readonly title: v.StringSchema<undefined>;
|
|
@@ -105,10 +105,10 @@ declare const ChangelogSectionSchema: v.ObjectSchema<{
|
|
|
105
105
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
106
106
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
107
107
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
108
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
108
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
109
109
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
110
110
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
111
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
111
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
112
112
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
113
113
|
readonly seconds: v.BigintSchema<undefined>;
|
|
114
114
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -278,7 +278,7 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
278
278
|
readonly sections: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
279
279
|
readonly heading: v.StringSchema<undefined>;
|
|
280
280
|
readonly summary: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
281
|
-
readonly surface: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
281
|
+
readonly surface: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>;
|
|
282
282
|
readonly changes: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
283
283
|
readonly id: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
|
|
284
284
|
readonly title: v.StringSchema<undefined>;
|
|
@@ -288,10 +288,10 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
288
288
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
289
289
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
290
290
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
291
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
291
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
292
292
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
293
293
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
294
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
294
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
295
295
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
296
296
|
readonly seconds: v.BigintSchema<undefined>;
|
|
297
297
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -327,7 +327,7 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
327
327
|
sections: {
|
|
328
328
|
heading: string;
|
|
329
329
|
summary?: string | undefined;
|
|
330
|
-
surface: "unspecified" | "assistant" | "
|
|
330
|
+
surface: "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards";
|
|
331
331
|
changes: {
|
|
332
332
|
id: string;
|
|
333
333
|
title: string;
|
|
@@ -337,10 +337,10 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
337
337
|
actionRequired: boolean;
|
|
338
338
|
migrationGuidance?: string | undefined;
|
|
339
339
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
340
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
340
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
341
341
|
environmentExceptions: {
|
|
342
342
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
343
|
-
availability: "unspecified" | "
|
|
343
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
344
344
|
liveAt?: number | undefined;
|
|
345
345
|
}[];
|
|
346
346
|
}[];
|
|
@@ -349,7 +349,7 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
349
349
|
sections: {
|
|
350
350
|
heading: string;
|
|
351
351
|
summary?: string | undefined;
|
|
352
|
-
surface: "unspecified" | "assistant" | "
|
|
352
|
+
surface: "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards";
|
|
353
353
|
changes: {
|
|
354
354
|
id: string;
|
|
355
355
|
title: string;
|
|
@@ -359,10 +359,10 @@ declare const ChangelogPostSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
359
359
|
actionRequired: boolean;
|
|
360
360
|
migrationGuidance?: string | undefined;
|
|
361
361
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
362
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
362
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
363
363
|
environmentExceptions: {
|
|
364
364
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
365
|
-
availability: "unspecified" | "
|
|
365
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
366
366
|
liveAt?: number | undefined;
|
|
367
367
|
}[];
|
|
368
368
|
}[];
|
|
@@ -398,10 +398,10 @@ declare const ChangelogChangeEntrySchema: v.SchemaWithPipe<readonly [v.ObjectSch
|
|
|
398
398
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
399
399
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
400
400
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
401
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
401
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
402
402
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
403
403
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
404
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
404
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
405
405
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
406
406
|
readonly seconds: v.BigintSchema<undefined>;
|
|
407
407
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -430,10 +430,10 @@ declare const ChangelogChangeEntrySchema: v.SchemaWithPipe<readonly [v.ObjectSch
|
|
|
430
430
|
actionRequired: boolean;
|
|
431
431
|
migrationGuidance?: string | undefined;
|
|
432
432
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
433
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
433
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
434
434
|
environmentExceptions: {
|
|
435
435
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
436
|
-
availability: "unspecified" | "
|
|
436
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
437
437
|
liveAt?: number | undefined;
|
|
438
438
|
}[];
|
|
439
439
|
};
|
|
@@ -452,10 +452,10 @@ declare const ChangelogChangeEntrySchema: v.SchemaWithPipe<readonly [v.ObjectSch
|
|
|
452
452
|
actionRequired: boolean;
|
|
453
453
|
migrationGuidance?: string | undefined;
|
|
454
454
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
455
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
455
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
456
456
|
environmentExceptions: {
|
|
457
457
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
458
|
-
availability: "unspecified" | "
|
|
458
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
459
459
|
liveAt?: number | undefined;
|
|
460
460
|
}[];
|
|
461
461
|
}>]>;
|
|
@@ -472,10 +472,10 @@ declare const ListChangelogChangesResultSchema: v.ObjectSchema<{
|
|
|
472
472
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
473
473
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
474
474
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
475
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
475
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
476
476
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
477
477
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
478
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
478
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
479
479
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
480
480
|
readonly seconds: v.BigintSchema<undefined>;
|
|
481
481
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -504,10 +504,10 @@ declare const ListChangelogChangesResultSchema: v.ObjectSchema<{
|
|
|
504
504
|
actionRequired: boolean;
|
|
505
505
|
migrationGuidance?: string | undefined;
|
|
506
506
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
507
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
507
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
508
508
|
environmentExceptions: {
|
|
509
509
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
510
|
-
availability: "unspecified" | "
|
|
510
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
511
511
|
liveAt?: number | undefined;
|
|
512
512
|
}[];
|
|
513
513
|
};
|
|
@@ -526,10 +526,10 @@ declare const ListChangelogChangesResultSchema: v.ObjectSchema<{
|
|
|
526
526
|
actionRequired: boolean;
|
|
527
527
|
migrationGuidance?: string | undefined;
|
|
528
528
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
529
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
529
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
530
530
|
environmentExceptions: {
|
|
531
531
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
532
|
-
availability: "unspecified" | "
|
|
532
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
533
533
|
liveAt?: number | undefined;
|
|
534
534
|
}[];
|
|
535
535
|
}>]>, undefined>, readonly []>;
|
|
@@ -678,10 +678,10 @@ declare const ChangelogDeploymentGroupSchema: v.SchemaWithPipe<readonly [v.Objec
|
|
|
678
678
|
readonly actionRequired: v.BooleanSchema<undefined>;
|
|
679
679
|
readonly migrationGuidance: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
680
680
|
readonly audiences: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "all_users" | "traders" | "market_makers" | "developers">]>, undefined>, readonly []>;
|
|
681
|
-
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "
|
|
681
|
+
readonly surfaces: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards">]>, undefined>, readonly []>;
|
|
682
682
|
readonly environmentExceptions: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
|
|
683
683
|
readonly environment: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "devnet" | "testnet" | "mainnet">]>;
|
|
684
|
-
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
684
|
+
readonly availability: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "ahead" | "pending" | "unavailable">]>;
|
|
685
685
|
readonly liveAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
686
686
|
readonly seconds: v.BigintSchema<undefined>;
|
|
687
687
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -703,10 +703,10 @@ declare const ChangelogDeploymentGroupSchema: v.SchemaWithPipe<readonly [v.Objec
|
|
|
703
703
|
actionRequired: boolean;
|
|
704
704
|
migrationGuidance?: string | undefined;
|
|
705
705
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
706
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
706
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
707
707
|
environmentExceptions: {
|
|
708
708
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
709
|
-
availability: "unspecified" | "
|
|
709
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
710
710
|
liveAt?: number | undefined;
|
|
711
711
|
}[];
|
|
712
712
|
};
|
|
@@ -723,10 +723,10 @@ declare const ChangelogDeploymentGroupSchema: v.SchemaWithPipe<readonly [v.Objec
|
|
|
723
723
|
actionRequired: boolean;
|
|
724
724
|
migrationGuidance?: string | undefined;
|
|
725
725
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
726
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
726
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
727
727
|
environmentExceptions: {
|
|
728
728
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
729
|
-
availability: "unspecified" | "
|
|
729
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
730
730
|
liveAt?: number | undefined;
|
|
731
731
|
}[];
|
|
732
732
|
}>]>, undefined>, readonly []>;
|
|
@@ -765,10 +765,10 @@ declare const ChangelogDeploymentGroupSchema: v.SchemaWithPipe<readonly [v.Objec
|
|
|
765
765
|
actionRequired: boolean;
|
|
766
766
|
migrationGuidance?: string | undefined;
|
|
767
767
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
768
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
768
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
769
769
|
environmentExceptions: {
|
|
770
770
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
771
|
-
availability: "unspecified" | "
|
|
771
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
772
772
|
liveAt?: number | undefined;
|
|
773
773
|
}[];
|
|
774
774
|
}[];
|
|
@@ -789,10 +789,10 @@ declare const ChangelogDeploymentGroupSchema: v.SchemaWithPipe<readonly [v.Objec
|
|
|
789
789
|
actionRequired: boolean;
|
|
790
790
|
migrationGuidance?: string | undefined;
|
|
791
791
|
audiences: ("unspecified" | "all_users" | "traders" | "market_makers" | "developers")[];
|
|
792
|
-
surfaces: ("unspecified" | "assistant" | "
|
|
792
|
+
surfaces: ("unspecified" | "assistant" | "api" | "trading" | "funding" | "accounts" | "explorer" | "documentation" | "platform" | "market_data" | "quickswap" | "rewards")[];
|
|
793
793
|
environmentExceptions: {
|
|
794
794
|
environment: "unspecified" | "devnet" | "testnet" | "mainnet";
|
|
795
|
-
availability: "unspecified" | "
|
|
795
|
+
availability: "unspecified" | "ahead" | "pending" | "unavailable";
|
|
796
796
|
liveAt?: number | undefined;
|
|
797
797
|
}[];
|
|
798
798
|
}[];
|
|
@@ -427,7 +427,7 @@ declare const CheckpointSchema: v.ObjectSchema<{
|
|
|
427
427
|
readonly seasonResultUsd: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
|
|
428
428
|
readonly subaccounts: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.MaxValueAction<bigint, bigint, undefined>, v.TransformAction<any, number>]>;
|
|
429
429
|
/** Values computed from partial evidence; show them with an approximation marker. */
|
|
430
|
-
readonly incomplete: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
430
|
+
readonly incomplete: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "tools" | "deposits" | "withdrawals" | "volume" | "top_pairs" | "order_types" | "time_in_force" | "order_status" | "median_limit_rest" | "internal_transfers" | "daily_claim_amounts" | "portfolio_value" | "trading_balances" | "funding_balances" | "transfers" | "season_result">]>, undefined>, readonly []>;
|
|
431
431
|
}, undefined>;
|
|
432
432
|
/**
|
|
433
433
|
* One frozen season recap of a root account and all of its subaccounts. An absent USD value
|
|
@@ -36,7 +36,7 @@ declare const DailyClaimTransferSchema: v.ObjectSchema<{
|
|
|
36
36
|
}, undefined>;
|
|
37
37
|
type DailyClaimTransfer = v.InferOutput<typeof DailyClaimTransferSchema>;
|
|
38
38
|
declare const DailyClaimStatusSchema: v.ObjectSchema<{
|
|
39
|
-
readonly state: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
39
|
+
readonly state: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "unavailable" | "processing" | "available" | "claimed" | "payout_delayed">]>;
|
|
40
40
|
readonly resetAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
41
41
|
readonly seconds: v.BigintSchema<undefined>;
|
|
42
42
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -76,7 +76,7 @@ declare const DailyClaimStatusSchema: v.ObjectSchema<{
|
|
|
76
76
|
type DailyClaimStatus = v.InferOutput<typeof DailyClaimStatusSchema>;
|
|
77
77
|
declare const ClaimDailyRewardResultSchema: v.ObjectSchema<{
|
|
78
78
|
readonly claimId: v.StringSchema<undefined>;
|
|
79
|
-
readonly state: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "
|
|
79
|
+
readonly state: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "unavailable" | "processing" | "available" | "claimed" | "payout_delayed">]>;
|
|
80
80
|
readonly claimedAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
|
|
81
81
|
readonly seconds: v.BigintSchema<undefined>;
|
|
82
82
|
readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
|
|
@@ -218,7 +218,7 @@ declare const DustConversionSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
|
218
218
|
quoteId: string;
|
|
219
219
|
state: "unspecified" | "processing" | "completed" | "refused";
|
|
220
220
|
/** Why a `refused` conversion was refused; null otherwise. */
|
|
221
|
-
refusalCode: "UNSPECIFIED" | "
|
|
221
|
+
refusalCode: "UNSPECIFIED" | "INSUFFICIENT_FUNDS" | "INVALID_REQUEST" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "RATE_LIMIT_EXCEEDED" | "SERVICE_UNAVAILABLE" | "INTERNAL_ERROR" | "INVALID_SUBACCOUNT_ID" | "SUBACCOUNT_NOT_FOUND" | "SOURCE_ACCOUNT_INACTIVE" | "UNSUPPORTED_ASSET" | "INVALID_AMOUNT" | "INVALID_DESTINATION" | "DESTINATION_NOT_FOUND" | "DESTINATION_INACTIVE" | "SAME_SOURCE_DESTINATION" | "DESTINATION_NOT_WHITELISTED" | "SMART_ACCOUNT_UNAVAILABLE" | "STEP_UP_UNAVAILABLE" | "IDEMPOTENCY_CONFLICT" | "FUNDS_LOCK_CONFLICT" | "CAPITAL_VIEW_UNAVAILABLE" | "ACCOUNT_SHARD_UNAVAILABLE" | "POLICY_DENIED" | "FAILED_PRECONDITION" | "NOT_FOUND" | "CONFLICT" | "DUST_QUOTE_EXPIRED" | "DUST_PRICE_MOVED" | "DUST_NOT_ELIGIBLE" | "DUST_WINDOW_ACTIVE" | "DUST_DAILY_LIMIT" | "DUST_BUSY" | "DUST_TARGET_UNAVAILABLE" | "DUST_BALANCE_CHANGED" | "DUST_CONVERSION_FAILED" | "BATCH_TOO_MANY_SOURCES" | null;
|
|
222
222
|
targetAssetId: number;
|
|
223
223
|
/** Whole quoted balances moved, in asset id order. */
|
|
224
224
|
sources: {
|
|
@@ -534,7 +534,7 @@ declare const ListDustConversionsResultSchema: v.ObjectSchema<{
|
|
|
534
534
|
quoteId: string;
|
|
535
535
|
state: "unspecified" | "processing" | "completed" | "refused";
|
|
536
536
|
/** Why a `refused` conversion was refused; null otherwise. */
|
|
537
|
-
refusalCode: "UNSPECIFIED" | "
|
|
537
|
+
refusalCode: "UNSPECIFIED" | "INSUFFICIENT_FUNDS" | "INVALID_REQUEST" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "RATE_LIMIT_EXCEEDED" | "SERVICE_UNAVAILABLE" | "INTERNAL_ERROR" | "INVALID_SUBACCOUNT_ID" | "SUBACCOUNT_NOT_FOUND" | "SOURCE_ACCOUNT_INACTIVE" | "UNSUPPORTED_ASSET" | "INVALID_AMOUNT" | "INVALID_DESTINATION" | "DESTINATION_NOT_FOUND" | "DESTINATION_INACTIVE" | "SAME_SOURCE_DESTINATION" | "DESTINATION_NOT_WHITELISTED" | "SMART_ACCOUNT_UNAVAILABLE" | "STEP_UP_UNAVAILABLE" | "IDEMPOTENCY_CONFLICT" | "FUNDS_LOCK_CONFLICT" | "CAPITAL_VIEW_UNAVAILABLE" | "ACCOUNT_SHARD_UNAVAILABLE" | "POLICY_DENIED" | "FAILED_PRECONDITION" | "NOT_FOUND" | "CONFLICT" | "DUST_QUOTE_EXPIRED" | "DUST_PRICE_MOVED" | "DUST_NOT_ELIGIBLE" | "DUST_WINDOW_ACTIVE" | "DUST_DAILY_LIMIT" | "DUST_BUSY" | "DUST_TARGET_UNAVAILABLE" | "DUST_BALANCE_CHANGED" | "DUST_CONVERSION_FAILED" | "BATCH_TOO_MANY_SOURCES" | null;
|
|
538
538
|
targetAssetId: number;
|
|
539
539
|
/** Whole quoted balances moved, in asset id order. */
|
|
540
540
|
sources: {
|
|
@@ -14,7 +14,7 @@ type TimestampInit = {
|
|
|
14
14
|
declare const GetOrderbookHeatmapInputSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
15
15
|
readonly symbolId: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.GtValueAction<number, 0, undefined>, v.MaxValueAction<number, 4294967295, undefined>]>;
|
|
16
16
|
readonly interval: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["1s", "1m", "5m", "1h"], undefined>, "1s">, v.TransformAction<"1s" | "1m" | "5m" | "1h", HeatmapInterval>]>;
|
|
17
|
-
readonly depth: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly [1, 5, 10, 20, 50, 100, 200, 500, 1000], undefined>, 50>, v.TransformAction<1 |
|
|
17
|
+
readonly depth: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly [1, 5, 10, 20, 50, 100, 200, 500, 1000], undefined>, 50>, v.TransformAction<1 | 5 | 10 | 20 | 200 | 100 | 500 | 1000 | 50, HeatmapDepth>]>;
|
|
18
18
|
readonly quantityMode: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["close", "peak"], undefined>, "close">, v.TransformAction<"close" | "peak", HeatmapQuantityMode>]>;
|
|
19
19
|
readonly limit: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.GtValueAction<number, 0, undefined>, v.MaxValueAction<number, 20000, undefined>]>;
|
|
20
20
|
readonly startTsSec: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>, v.MaxValueAction<number, number, undefined>, v.TransformAction<number, bigint>]>, undefined>;
|
|
@@ -227,7 +227,7 @@ type OrderbookHeatmapDeltaChain = ReturnType<typeof convertHeatmapDeltaChain>;
|
|
|
227
227
|
declare function createOrderbookHeatmapResponseSchema(scales: SdkScales): v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
228
228
|
readonly symbolId: v.NumberSchema<undefined>;
|
|
229
229
|
readonly interval: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, DecodedEnum<"1s" | "1m" | "5m" | "1h">>]>;
|
|
230
|
-
readonly depth: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, 1 |
|
|
230
|
+
readonly depth: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, 1 | 5 | 10 | 20 | "unspecified" | 200 | 100 | 500 | 1000 | 50>]>;
|
|
231
231
|
readonly chain: v.OptionalSchema<v.ObjectSchema<{
|
|
232
232
|
readonly baseKeyframe: v.OptionalSchema<v.ObjectSchema<{
|
|
233
233
|
readonly tsSec: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, number>]>;
|
|
@@ -287,7 +287,7 @@ declare function createOrderbookHeatmapResponseSchema(scales: SdkScales): v.Sche
|
|
|
287
287
|
}, undefined>, v.TransformAction<{
|
|
288
288
|
symbolId: number;
|
|
289
289
|
interval: DecodedEnum<"1s" | "1m" | "5m" | "1h">;
|
|
290
|
-
depth: 1 |
|
|
290
|
+
depth: 1 | 5 | 10 | 20 | "unspecified" | 200 | 100 | 500 | 1000 | 50;
|
|
291
291
|
chain?: {
|
|
292
292
|
baseKeyframe?: {
|
|
293
293
|
tsSec: number;
|
|
@@ -347,7 +347,7 @@ declare function createOrderbookHeatmapResponseSchema(scales: SdkScales): v.Sche
|
|
|
347
347
|
}, {
|
|
348
348
|
symbolId: number;
|
|
349
349
|
interval: DecodedEnum<"1s" | "1m" | "5m" | "1h">;
|
|
350
|
-
depth: 1 |
|
|
350
|
+
depth: 1 | 5 | 10 | 20 | "unspecified" | 200 | 100 | 500 | 1000 | 50;
|
|
351
351
|
chain: {
|
|
352
352
|
baseKeyframe: {
|
|
353
353
|
tsSec: number;
|
|
@@ -138,7 +138,7 @@ declare function createCreateInternalTransferResultSchema(): v.SchemaWithPipe<re
|
|
|
138
138
|
subaccountId: string | undefined;
|
|
139
139
|
smartAccountAddress: string | undefined;
|
|
140
140
|
}>]>, undefined>;
|
|
141
|
-
readonly status: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "failed" | "
|
|
141
|
+
readonly status: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "failed" | "accepted" | "rejected">]>;
|
|
142
142
|
/** Lifecycle flow ID for `lifecycle.getAccountFlow`; empty when the server did not return one. */
|
|
143
143
|
readonly flowId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, "">;
|
|
144
144
|
}, undefined>, v.TransformAction<{
|
|
@@ -157,7 +157,7 @@ declare function createCreateInternalTransferResultSchema(): v.SchemaWithPipe<re
|
|
|
157
157
|
subaccountId: string | undefined;
|
|
158
158
|
smartAccountAddress: string | undefined;
|
|
159
159
|
} | undefined;
|
|
160
|
-
status: "unspecified" | "failed" | "
|
|
160
|
+
status: "unspecified" | "failed" | "accepted" | "rejected";
|
|
161
161
|
flowId: string;
|
|
162
162
|
}, {
|
|
163
163
|
acceptedAtUnixMs: number;
|
|
@@ -174,7 +174,7 @@ declare function createCreateInternalTransferResultSchema(): v.SchemaWithPipe<re
|
|
|
174
174
|
subaccountId: string | undefined;
|
|
175
175
|
smartAccountAddress: string | undefined;
|
|
176
176
|
} | undefined;
|
|
177
|
-
status: "unspecified" | "failed" | "
|
|
177
|
+
status: "unspecified" | "failed" | "accepted" | "rejected";
|
|
178
178
|
flowId: string;
|
|
179
179
|
}>]>;
|
|
180
180
|
type CreateInternalTransferResult = v.InferOutput<ReturnType<typeof createCreateInternalTransferResultSchema>>;
|
|
@@ -349,7 +349,7 @@ declare const InternalTransferBatchLegResultSchema: v.SchemaWithPipe<readonly [v
|
|
|
349
349
|
creditedAtNs: string | undefined;
|
|
350
350
|
quantity: string | undefined;
|
|
351
351
|
/** Why the leg caused its batch's refusal; unset for every other leg. */
|
|
352
|
-
errorCode: "UNSPECIFIED" | "
|
|
352
|
+
errorCode: "UNSPECIFIED" | "INSUFFICIENT_FUNDS" | "INVALID_REQUEST" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "RATE_LIMIT_EXCEEDED" | "SERVICE_UNAVAILABLE" | "INTERNAL_ERROR" | "INVALID_SUBACCOUNT_ID" | "SUBACCOUNT_NOT_FOUND" | "SOURCE_ACCOUNT_INACTIVE" | "UNSUPPORTED_ASSET" | "INVALID_AMOUNT" | "INVALID_DESTINATION" | "DESTINATION_NOT_FOUND" | "DESTINATION_INACTIVE" | "SAME_SOURCE_DESTINATION" | "DESTINATION_NOT_WHITELISTED" | "SMART_ACCOUNT_UNAVAILABLE" | "STEP_UP_UNAVAILABLE" | "IDEMPOTENCY_CONFLICT" | "FUNDS_LOCK_CONFLICT" | "CAPITAL_VIEW_UNAVAILABLE" | "ACCOUNT_SHARD_UNAVAILABLE" | "POLICY_DENIED" | "FAILED_PRECONDITION" | "NOT_FOUND" | "CONFLICT" | "DUST_QUOTE_EXPIRED" | "DUST_PRICE_MOVED" | "DUST_NOT_ELIGIBLE" | "DUST_WINDOW_ACTIVE" | "DUST_DAILY_LIMIT" | "DUST_BUSY" | "DUST_TARGET_UNAVAILABLE" | "DUST_BALANCE_CHANGED" | "DUST_CONVERSION_FAILED" | "BATCH_TOO_MANY_SOURCES" | undefined;
|
|
353
353
|
legIndex: number;
|
|
354
354
|
status: "unspecified" | "processing" | "credited" | "not_moved";
|
|
355
355
|
transferId?: string | undefined;
|
|
@@ -370,7 +370,7 @@ declare const BatchCreateInternalTransfersResultSchema: v.ObjectSchema<{
|
|
|
370
370
|
* it was accepted for processing.
|
|
371
371
|
*/
|
|
372
372
|
readonly requestId: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>, v.TransformAction<string | undefined, string | undefined>]>;
|
|
373
|
-
readonly status: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "processing" | "
|
|
373
|
+
readonly status: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "processing" | "refused" | "accepted">]>;
|
|
374
374
|
/** One result per leg, in request order. */
|
|
375
375
|
readonly legs: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
376
376
|
readonly legIndex: v.NumberSchema<undefined>;
|
|
@@ -427,7 +427,7 @@ declare const BatchCreateInternalTransfersResultSchema: v.ObjectSchema<{
|
|
|
427
427
|
creditedAtNs: string | undefined;
|
|
428
428
|
quantity: string | undefined;
|
|
429
429
|
/** Why the leg caused its batch's refusal; unset for every other leg. */
|
|
430
|
-
errorCode: "UNSPECIFIED" | "
|
|
430
|
+
errorCode: "UNSPECIFIED" | "INSUFFICIENT_FUNDS" | "INVALID_REQUEST" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "RATE_LIMIT_EXCEEDED" | "SERVICE_UNAVAILABLE" | "INTERNAL_ERROR" | "INVALID_SUBACCOUNT_ID" | "SUBACCOUNT_NOT_FOUND" | "SOURCE_ACCOUNT_INACTIVE" | "UNSUPPORTED_ASSET" | "INVALID_AMOUNT" | "INVALID_DESTINATION" | "DESTINATION_NOT_FOUND" | "DESTINATION_INACTIVE" | "SAME_SOURCE_DESTINATION" | "DESTINATION_NOT_WHITELISTED" | "SMART_ACCOUNT_UNAVAILABLE" | "STEP_UP_UNAVAILABLE" | "IDEMPOTENCY_CONFLICT" | "FUNDS_LOCK_CONFLICT" | "CAPITAL_VIEW_UNAVAILABLE" | "ACCOUNT_SHARD_UNAVAILABLE" | "POLICY_DENIED" | "FAILED_PRECONDITION" | "NOT_FOUND" | "CONFLICT" | "DUST_QUOTE_EXPIRED" | "DUST_PRICE_MOVED" | "DUST_NOT_ELIGIBLE" | "DUST_WINDOW_ACTIVE" | "DUST_DAILY_LIMIT" | "DUST_BUSY" | "DUST_TARGET_UNAVAILABLE" | "DUST_BALANCE_CHANGED" | "DUST_CONVERSION_FAILED" | "BATCH_TOO_MANY_SOURCES" | undefined;
|
|
431
431
|
legIndex: number;
|
|
432
432
|
status: "unspecified" | "processing" | "credited" | "not_moved";
|
|
433
433
|
transferId?: string | undefined;
|
|
@@ -82,7 +82,7 @@ var LifecycleService = class {
|
|
|
82
82
|
* Subscribes to open lifecycle flow summary updates, using private:chain:lifecycle:flows:{accountId}:proto when `accountId` is set and the public all-accounts flow channel only when it is omitted.
|
|
83
83
|
*/
|
|
84
84
|
subscribeOpenFlows(input) {
|
|
85
|
-
const channel = input.accountId === void 0 ? "public:chain:lifecycle:flows:proto" : `private:chain:lifecycle:flows:${input.accountId}:proto`;
|
|
85
|
+
const channel = input.accountId === void 0 ? "public:chain:lifecycle:flows:proto" : `private:chain:lifecycle:flows:${input.accountId.trim()}:proto`;
|
|
86
86
|
return this.#realtime.connectProtoChannel({
|
|
87
87
|
channel,
|
|
88
88
|
schema: FlowSummaryViewSchema,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lifecycle.js","names":["#client","#authClient","#realtime","#resolver"],"sources":["../../../src/services/lifecycle/lifecycle.ts"],"sourcesContent":["import { createClient, type Client } from \"@connectrpc/connect\";\nimport { create } from \"@bufbuild/protobuf\";\nimport {\n FlowDetailViewSchema,\n FlowSummaryViewSchema,\n GetFlowByIdRequestSchema,\n LifecycleReadService,\n} from \"../../gen/chain/lifecycle/v1/lifecycle_read_pb.js\";\nimport type { PolyesterRealtime } from \"../../realtime/types.js\";\nimport type { AuthAndPublicApiTransports } from \"../../shared/transports.js\";\nimport { resolveAccountScopedInput, type SubaccountResolver } from \"../subaccount-resolver.js\";\nimport type { BaseSubscribeInput } from \"../../shared/types.js\";\nimport {\n toConnectCallOptions,\n type PolyesterRequestOptions,\n} from \"../../shared/request-options.js\";\nimport { isDev } from \"../../utils/is-dev.js\";\nimport * as v from \"valibot\";\nimport { parse } from \"../../shared/validation.js\";\nimport {\n GetLifecycleAccountFlowInputSchema,\n GetLifecycleFlowInputSchema,\n GetLifecycleFlowOutputSchema,\n LifecycleFlowDetailSchema,\n LifecycleFlowSummarySchema,\n ListLifecycleFlowsByTxOutputSchema,\n ListLifecycleFlowsByTxInputSchema,\n ListLifecycleFlowsOutputSchema,\n ListLifecycleFlowsInputSchema,\n ListLifecycleAccountFlowsInputSchema,\n type GetLifecycleAccountFlowInput,\n type GetLifecycleFlowInput,\n type GetLifecycleFlowOutput,\n type LifecycleFlowDetail,\n type LifecycleFlowSummary,\n type ListLifecycleFlowsByTxInput,\n type ListLifecycleFlowsByTxOutput,\n type ListLifecycleFlowsInput,\n type ListLifecycleAccountFlowsInput,\n type ListLifecycleFlowsOutput,\n} from \"./lifecycle.schemas.js\";\n\ninterface SubscribeOpenLifecycleFlowsInput extends BaseSubscribeInput<LifecycleFlowSummary> {\n accountId?: string;\n}\n\ninterface SubscribeLifecycleFlowDetailInput extends BaseSubscribeInput<LifecycleFlowDetail> {\n flowId: string;\n}\n\n/**\n * Reads and streams chain lifecycle flow state, history, progress, and transaction matches.\n */\nexport class LifecycleService {\n #client: Client<typeof LifecycleReadService>;\n #authClient: Client<typeof LifecycleReadService>;\n #realtime: PolyesterRealtime;\n #resolver?: SubaccountResolver;\n\n constructor(\n transports: AuthAndPublicApiTransports,\n realtime: PolyesterRealtime,\n resolver?: SubaccountResolver,\n ) {\n this.#client = createClient(LifecycleReadService, transports.publicApi);\n this.#authClient = createClient(LifecycleReadService, transports.authApi);\n this.#realtime = realtime;\n this.#resolver = resolver;\n }\n\n /**\n * Returns paginated lifecycle flow summaries filtered by kind, state, scope, account selector, transaction reference, chain ids, and asset ids. The response is ordered by the selected timestamp and includes an opaque next page token.\n *\n * Lists only flows a chain transaction started. With an `accountSelector` (a smart\n * account address), the list holds the flows the account owns and the transfers it\n * receives from other accounts; each row's `participation` says which. Pass\n * `participation: \"owner\"` for the owned flows only. A `pageToken` only resumes the\n * request it came from: change nothing but `limit` between pages. Use `listAccountFlows`\n * for every flow of the signed-in account.\n */\n async listFlows(\n input: ListLifecycleFlowsInput,\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsOutput> {\n const parsedInput = parse(ListLifecycleFlowsInputSchema, input);\n const response = await this.#client.listFlows(parsedInput, toConnectCallOptions(options));\n const res = parse(ListLifecycleFlowsOutputSchema, response);\n return res;\n }\n\n /**\n * Lists the signed-in account's flows: the ones it owns and the transfers it receives,\n * including flows no chain transaction started, such as transfers between Trading accounts.\n * Each row's `participation` says which. Takes the same filters as `listFlows`; a\n * `pageToken` only resumes the request it came from. API keys need `read-funding-flows`.\n */\n async listAccountFlows(\n input: ListLifecycleAccountFlowsInput = {},\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsOutput> {\n const resolved = resolveAccountScopedInput(input, this.#resolver);\n const request = parse(ListLifecycleAccountFlowsInputSchema, resolved);\n const response = await this.#authClient.listAccountFlows(\n request,\n toConnectCallOptions(options),\n );\n return parse(ListLifecycleFlowsOutputSchema, response);\n }\n\n /**\n * Fetches one flow the signed-in account owns or receives, including one no chain\n * transaction started. A flow the account takes no part in throws `ResourceNotFoundError`. API keys\n * need `read-funding-flows`.\n */\n async getAccountFlow(\n input: GetLifecycleAccountFlowInput,\n options?: PolyesterRequestOptions,\n ): Promise<GetLifecycleFlowOutput> {\n const resolved = resolveAccountScopedInput(input, this.#resolver);\n const request = parse(GetLifecycleAccountFlowInputSchema, resolved);\n const response = await this.#authClient.getAccountFlow(\n request,\n toConnectCallOptions(options),\n );\n return parse(GetLifecycleFlowOutputSchema, response);\n }\n\n /**\n * Fetches one lifecycle flow by its public flow id and returns summary, factual steps,\n * timeline, and live-state detail when available. Finds only flows a chain transaction\n * started; the account reads its other flows with `getAccountFlow`.\n */\n async getFlow(\n input: GetLifecycleFlowInput,\n options?: PolyesterRequestOptions,\n ): Promise<GetLifecycleFlowOutput> {\n const parsedInput = parse(GetLifecycleFlowInputSchema, input);\n const response = await this.#client.getFlowById(\n create(GetFlowByIdRequestSchema, parsedInput),\n toConnectCallOptions(options),\n );\n return parse(GetLifecycleFlowOutputSchema, response);\n }\n\n /**\n * Searches lifecycle flows that reference a 0x-prefixed transaction hash, using source-only or any-reference lookup mode. A single transaction may match zero, one, or many flows.\n */\n async listFlowsByTx(\n input: ListLifecycleFlowsByTxInput,\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsByTxOutput> {\n const parsedInput = parse(ListLifecycleFlowsByTxInputSchema, input);\n const response = await this.#client.listFlowsByTx(\n parsedInput,\n toConnectCallOptions(options),\n );\n return parse(ListLifecycleFlowsByTxOutputSchema, response);\n }\n\n /**\n * Subscribes to open lifecycle flow summary updates, using private:chain:lifecycle:flows:{accountId}:proto when `accountId` is set and the public all-accounts flow channel only when it is omitted.\n */\n subscribeOpenFlows(input: SubscribeOpenLifecycleFlowsInput): () => void {\n const channel =\n input.accountId === undefined\n ? \"public:chain:lifecycle:flows:proto\"\n : `private:chain:lifecycle:flows:${input.accountId}:proto`;\n return this.#realtime.connectProtoChannel({\n channel,\n schema: FlowSummaryViewSchema,\n onPublication: (data) => {\n const flow = parse(LifecycleFlowSummarySchema, data);\n input.onEvent(flow);\n },\n onConnected: input.onOpen,\n onDisconnected: input.onClose,\n onError: input.onError,\n });\n }\n\n /**\n * Subscribes to detail updates for one lifecycle flow on public:chain:lifecycle:flow:{flowId}:proto. Invalid flow ids are rejected locally with a no-op unsubscribe function.\n */\n subscribeFlowDetail(input: SubscribeLifecycleFlowDetailInput): () => void {\n const parsedFlowId = v.safeParse(GetLifecycleFlowInputSchema, { flowId: input.flowId });\n if (!parsedFlowId.success) {\n if (isDev()) {\n console.error(\n \"[LifecycleService] flowId is required for flow detail subscription.\",\n );\n }\n return () => {};\n }\n\n const channel = `public:chain:lifecycle:flow:${parsedFlowId.output.flowId}:proto`;\n return this.#realtime.connectProtoChannel({\n channel,\n schema: FlowDetailViewSchema,\n onPublication: (data) => {\n const flow = parse(LifecycleFlowDetailSchema, data);\n input.onEvent(flow);\n },\n onConnected: input.onOpen,\n onDisconnected: input.onClose,\n onError: input.onError,\n });\n }\n}\n"],"mappings":";;;;;;;;;;;;;AAqDA,IAAa,mBAAb,MAA8B;CAC1B;CACA;CACA;CACA;CAEA,YACI,YACA,UACA,UACF;EACE,KAAKA,UAAU,aAAa,sBAAsB,WAAW,SAAS;EACtE,KAAKC,cAAc,aAAa,sBAAsB,WAAW,OAAO;EACxE,KAAKC,YAAY;EACjB,KAAKC,YAAY;CACrB;;;;;;;;;;;CAYA,MAAM,UACF,OACA,SACiC;EACjC,MAAM,cAAc,MAAM,+BAA+B,KAAK;EAC9D,MAAM,WAAW,MAAM,KAAKH,QAAQ,UAAU,aAAa,qBAAqB,OAAO,CAAC;EAExF,OADY,MAAM,gCAAgC,QACzC;CACb;;;;;;;CAQA,MAAM,iBACF,QAAwC,CAAC,GACzC,SACiC;EACjC,MAAM,WAAW,0BAA0B,OAAO,KAAKG,SAAS;EAChE,MAAM,UAAU,MAAM,sCAAsC,QAAQ;EACpE,MAAM,WAAW,MAAM,KAAKF,YAAY,iBACpC,SACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,gCAAgC,QAAQ;CACzD;;;;;;CAOA,MAAM,eACF,OACA,SAC+B;EAC/B,MAAM,WAAW,0BAA0B,OAAO,KAAKE,SAAS;EAChE,MAAM,UAAU,MAAM,oCAAoC,QAAQ;EAClE,MAAM,WAAW,MAAM,KAAKF,YAAY,eACpC,SACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,8BAA8B,QAAQ;CACvD;;;;;;CAOA,MAAM,QACF,OACA,SAC+B;EAC/B,MAAM,cAAc,MAAM,6BAA6B,KAAK;EAC5D,MAAM,WAAW,MAAM,KAAKD,QAAQ,YAChC,OAAO,0BAA0B,WAAW,GAC5C,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,8BAA8B,QAAQ;CACvD;;;;CAKA,MAAM,cACF,OACA,SACqC;EACrC,MAAM,cAAc,MAAM,mCAAmC,KAAK;EAClE,MAAM,WAAW,MAAM,KAAKA,QAAQ,cAChC,aACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,oCAAoC,QAAQ;CAC7D;;;;CAKA,mBAAmB,OAAqD;EACpE,MAAM,UACF,MAAM,cAAc,KAAA,IACd,uCACA,iCAAiC,MAAM,UAAU;EAC3D,OAAO,KAAKE,UAAU,oBAAoB;GACtC;GACA,QAAQ;GACR,gBAAgB,SAAS;IACrB,MAAM,OAAO,MAAM,4BAA4B,IAAI;IACnD,MAAM,QAAQ,IAAI;GACtB;GACA,aAAa,MAAM;GACnB,gBAAgB,MAAM;GACtB,SAAS,MAAM;EACnB,CAAC;CACL;;;;CAKA,oBAAoB,OAAsD;EACtE,MAAM,eAAe,EAAE,UAAU,6BAA6B,EAAE,QAAQ,MAAM,OAAO,CAAC;EACtF,IAAI,CAAC,aAAa,SAAS;GACvB,IAAI,MAAM,GACN,QAAQ,MACJ,qEACJ;GAEJ,aAAa,CAAC;EAClB;EAEA,MAAM,UAAU,+BAA+B,aAAa,OAAO,OAAO;EAC1E,OAAO,KAAKA,UAAU,oBAAoB;GACtC;GACA,QAAQ;GACR,gBAAgB,SAAS;IACrB,MAAM,OAAO,MAAM,2BAA2B,IAAI;IAClD,MAAM,QAAQ,IAAI;GACtB;GACA,aAAa,MAAM;GACnB,gBAAgB,MAAM;GACtB,SAAS,MAAM;EACnB,CAAC;CACL;AACJ"}
|
|
1
|
+
{"version":3,"file":"lifecycle.js","names":["#client","#authClient","#realtime","#resolver"],"sources":["../../../src/services/lifecycle/lifecycle.ts"],"sourcesContent":["import { createClient, type Client } from \"@connectrpc/connect\";\nimport { create } from \"@bufbuild/protobuf\";\nimport {\n FlowDetailViewSchema,\n FlowSummaryViewSchema,\n GetFlowByIdRequestSchema,\n LifecycleReadService,\n} from \"../../gen/chain/lifecycle/v1/lifecycle_read_pb.js\";\nimport type { PolyesterRealtime } from \"../../realtime/types.js\";\nimport type { AuthAndPublicApiTransports } from \"../../shared/transports.js\";\nimport { resolveAccountScopedInput, type SubaccountResolver } from \"../subaccount-resolver.js\";\nimport type { BaseSubscribeInput } from \"../../shared/types.js\";\nimport {\n toConnectCallOptions,\n type PolyesterRequestOptions,\n} from \"../../shared/request-options.js\";\nimport { isDev } from \"../../utils/is-dev.js\";\nimport * as v from \"valibot\";\nimport { parse } from \"../../shared/validation.js\";\nimport {\n GetLifecycleAccountFlowInputSchema,\n GetLifecycleFlowInputSchema,\n GetLifecycleFlowOutputSchema,\n LifecycleFlowDetailSchema,\n LifecycleFlowSummarySchema,\n ListLifecycleFlowsByTxOutputSchema,\n ListLifecycleFlowsByTxInputSchema,\n ListLifecycleFlowsOutputSchema,\n ListLifecycleFlowsInputSchema,\n ListLifecycleAccountFlowsInputSchema,\n type GetLifecycleAccountFlowInput,\n type GetLifecycleFlowInput,\n type GetLifecycleFlowOutput,\n type LifecycleFlowDetail,\n type LifecycleFlowSummary,\n type ListLifecycleFlowsByTxInput,\n type ListLifecycleFlowsByTxOutput,\n type ListLifecycleFlowsInput,\n type ListLifecycleAccountFlowsInput,\n type ListLifecycleFlowsOutput,\n} from \"./lifecycle.schemas.js\";\n\ninterface SubscribeOpenLifecycleFlowsInput extends BaseSubscribeInput<LifecycleFlowSummary> {\n accountId?: string;\n}\n\ninterface SubscribeLifecycleFlowDetailInput extends BaseSubscribeInput<LifecycleFlowDetail> {\n flowId: string;\n}\n\n/**\n * Reads and streams chain lifecycle flow state, history, progress, and transaction matches.\n */\nexport class LifecycleService {\n #client: Client<typeof LifecycleReadService>;\n #authClient: Client<typeof LifecycleReadService>;\n #realtime: PolyesterRealtime;\n #resolver?: SubaccountResolver;\n\n constructor(\n transports: AuthAndPublicApiTransports,\n realtime: PolyesterRealtime,\n resolver?: SubaccountResolver,\n ) {\n this.#client = createClient(LifecycleReadService, transports.publicApi);\n this.#authClient = createClient(LifecycleReadService, transports.authApi);\n this.#realtime = realtime;\n this.#resolver = resolver;\n }\n\n /**\n * Returns paginated lifecycle flow summaries filtered by kind, state, scope, account selector, transaction reference, chain ids, and asset ids. The response is ordered by the selected timestamp and includes an opaque next page token.\n *\n * Lists only flows a chain transaction started. With an `accountSelector` (a smart\n * account address), the list holds the flows the account owns and the transfers it\n * receives from other accounts; each row's `participation` says which. Pass\n * `participation: \"owner\"` for the owned flows only. A `pageToken` only resumes the\n * request it came from: change nothing but `limit` between pages. Use `listAccountFlows`\n * for every flow of the signed-in account.\n */\n async listFlows(\n input: ListLifecycleFlowsInput,\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsOutput> {\n const parsedInput = parse(ListLifecycleFlowsInputSchema, input);\n const response = await this.#client.listFlows(parsedInput, toConnectCallOptions(options));\n const res = parse(ListLifecycleFlowsOutputSchema, response);\n return res;\n }\n\n /**\n * Lists the signed-in account's flows: the ones it owns and the transfers it receives,\n * including flows no chain transaction started, such as transfers between Trading accounts.\n * Each row's `participation` says which. Takes the same filters as `listFlows`; a\n * `pageToken` only resumes the request it came from. API keys need `read-funding-flows`.\n */\n async listAccountFlows(\n input: ListLifecycleAccountFlowsInput = {},\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsOutput> {\n const resolved = resolveAccountScopedInput(input, this.#resolver);\n const request = parse(ListLifecycleAccountFlowsInputSchema, resolved);\n const response = await this.#authClient.listAccountFlows(\n request,\n toConnectCallOptions(options),\n );\n return parse(ListLifecycleFlowsOutputSchema, response);\n }\n\n /**\n * Fetches one flow the signed-in account owns or receives, including one no chain\n * transaction started. A flow the account takes no part in throws `ResourceNotFoundError`. API keys\n * need `read-funding-flows`.\n */\n async getAccountFlow(\n input: GetLifecycleAccountFlowInput,\n options?: PolyesterRequestOptions,\n ): Promise<GetLifecycleFlowOutput> {\n const resolved = resolveAccountScopedInput(input, this.#resolver);\n const request = parse(GetLifecycleAccountFlowInputSchema, resolved);\n const response = await this.#authClient.getAccountFlow(\n request,\n toConnectCallOptions(options),\n );\n return parse(GetLifecycleFlowOutputSchema, response);\n }\n\n /**\n * Fetches one lifecycle flow by its public flow id and returns summary, factual steps,\n * timeline, and live-state detail when available. Finds only flows a chain transaction\n * started; the account reads its other flows with `getAccountFlow`.\n */\n async getFlow(\n input: GetLifecycleFlowInput,\n options?: PolyesterRequestOptions,\n ): Promise<GetLifecycleFlowOutput> {\n const parsedInput = parse(GetLifecycleFlowInputSchema, input);\n const response = await this.#client.getFlowById(\n create(GetFlowByIdRequestSchema, parsedInput),\n toConnectCallOptions(options),\n );\n return parse(GetLifecycleFlowOutputSchema, response);\n }\n\n /**\n * Searches lifecycle flows that reference a 0x-prefixed transaction hash, using source-only or any-reference lookup mode. A single transaction may match zero, one, or many flows.\n */\n async listFlowsByTx(\n input: ListLifecycleFlowsByTxInput,\n options?: PolyesterRequestOptions,\n ): Promise<ListLifecycleFlowsByTxOutput> {\n const parsedInput = parse(ListLifecycleFlowsByTxInputSchema, input);\n const response = await this.#client.listFlowsByTx(\n parsedInput,\n toConnectCallOptions(options),\n );\n return parse(ListLifecycleFlowsByTxOutputSchema, response);\n }\n\n /**\n * Subscribes to open lifecycle flow summary updates, using private:chain:lifecycle:flows:{accountId}:proto when `accountId` is set and the public all-accounts flow channel only when it is omitted.\n */\n subscribeOpenFlows(input: SubscribeOpenLifecycleFlowsInput): () => void {\n const channel =\n input.accountId === undefined\n ? \"public:chain:lifecycle:flows:proto\"\n : `private:chain:lifecycle:flows:${input.accountId.trim()}:proto`;\n return this.#realtime.connectProtoChannel({\n channel,\n schema: FlowSummaryViewSchema,\n onPublication: (data) => {\n const flow = parse(LifecycleFlowSummarySchema, data);\n input.onEvent(flow);\n },\n onConnected: input.onOpen,\n onDisconnected: input.onClose,\n onError: input.onError,\n });\n }\n\n /**\n * Subscribes to detail updates for one lifecycle flow on public:chain:lifecycle:flow:{flowId}:proto. Invalid flow ids are rejected locally with a no-op unsubscribe function.\n */\n subscribeFlowDetail(input: SubscribeLifecycleFlowDetailInput): () => void {\n const parsedFlowId = v.safeParse(GetLifecycleFlowInputSchema, { flowId: input.flowId });\n if (!parsedFlowId.success) {\n if (isDev()) {\n console.error(\n \"[LifecycleService] flowId is required for flow detail subscription.\",\n );\n }\n return () => {};\n }\n\n const channel = `public:chain:lifecycle:flow:${parsedFlowId.output.flowId}:proto`;\n return this.#realtime.connectProtoChannel({\n channel,\n schema: FlowDetailViewSchema,\n onPublication: (data) => {\n const flow = parse(LifecycleFlowDetailSchema, data);\n input.onEvent(flow);\n },\n onConnected: input.onOpen,\n onDisconnected: input.onClose,\n onError: input.onError,\n });\n }\n}\n"],"mappings":";;;;;;;;;;;;;AAqDA,IAAa,mBAAb,MAA8B;CAC1B;CACA;CACA;CACA;CAEA,YACI,YACA,UACA,UACF;EACE,KAAKA,UAAU,aAAa,sBAAsB,WAAW,SAAS;EACtE,KAAKC,cAAc,aAAa,sBAAsB,WAAW,OAAO;EACxE,KAAKC,YAAY;EACjB,KAAKC,YAAY;CACrB;;;;;;;;;;;CAYA,MAAM,UACF,OACA,SACiC;EACjC,MAAM,cAAc,MAAM,+BAA+B,KAAK;EAC9D,MAAM,WAAW,MAAM,KAAKH,QAAQ,UAAU,aAAa,qBAAqB,OAAO,CAAC;EAExF,OADY,MAAM,gCAAgC,QACzC;CACb;;;;;;;CAQA,MAAM,iBACF,QAAwC,CAAC,GACzC,SACiC;EACjC,MAAM,WAAW,0BAA0B,OAAO,KAAKG,SAAS;EAChE,MAAM,UAAU,MAAM,sCAAsC,QAAQ;EACpE,MAAM,WAAW,MAAM,KAAKF,YAAY,iBACpC,SACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,gCAAgC,QAAQ;CACzD;;;;;;CAOA,MAAM,eACF,OACA,SAC+B;EAC/B,MAAM,WAAW,0BAA0B,OAAO,KAAKE,SAAS;EAChE,MAAM,UAAU,MAAM,oCAAoC,QAAQ;EAClE,MAAM,WAAW,MAAM,KAAKF,YAAY,eACpC,SACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,8BAA8B,QAAQ;CACvD;;;;;;CAOA,MAAM,QACF,OACA,SAC+B;EAC/B,MAAM,cAAc,MAAM,6BAA6B,KAAK;EAC5D,MAAM,WAAW,MAAM,KAAKD,QAAQ,YAChC,OAAO,0BAA0B,WAAW,GAC5C,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,8BAA8B,QAAQ;CACvD;;;;CAKA,MAAM,cACF,OACA,SACqC;EACrC,MAAM,cAAc,MAAM,mCAAmC,KAAK;EAClE,MAAM,WAAW,MAAM,KAAKA,QAAQ,cAChC,aACA,qBAAqB,OAAO,CAChC;EACA,OAAO,MAAM,oCAAoC,QAAQ;CAC7D;;;;CAKA,mBAAmB,OAAqD;EACpE,MAAM,UACF,MAAM,cAAc,KAAA,IACd,uCACA,iCAAiC,MAAM,UAAU,KAAK,EAAE;EAClE,OAAO,KAAKE,UAAU,oBAAoB;GACtC;GACA,QAAQ;GACR,gBAAgB,SAAS;IACrB,MAAM,OAAO,MAAM,4BAA4B,IAAI;IACnD,MAAM,QAAQ,IAAI;GACtB;GACA,aAAa,MAAM;GACnB,gBAAgB,MAAM;GACtB,SAAS,MAAM;EACnB,CAAC;CACL;;;;CAKA,oBAAoB,OAAsD;EACtE,MAAM,eAAe,EAAE,UAAU,6BAA6B,EAAE,QAAQ,MAAM,OAAO,CAAC;EACtF,IAAI,CAAC,aAAa,SAAS;GACvB,IAAI,MAAM,GACN,QAAQ,MACJ,qEACJ;GAEJ,aAAa,CAAC;EAClB;EAEA,MAAM,UAAU,+BAA+B,aAAa,OAAO,OAAO;EAC1E,OAAO,KAAKA,UAAU,oBAAoB;GACtC;GACA,QAAQ;GACR,gBAAgB,SAAS;IACrB,MAAM,OAAO,MAAM,2BAA2B,IAAI;IAClD,MAAM,QAAQ,IAAI;GACtB;GACA,aAAa,MAAM;GACnB,gBAAgB,MAAM;GACtB,SAAS,MAAM;EACnB,CAAC;CACL;AACJ"}
|