@bitgo/public-types 5.64.0 → 5.65.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/schema/transactionRequest/intents/intent.d.ts +61 -0
- package/dist/src/schema/transactionRequest/intents/intent.js +2 -0
- package/dist/src/schema/transactionRequest/intents/intent.js.map +1 -1
- package/dist/src/schema/transactionRequest/intents/xdcStakingIntent.d.ts +63 -0
- package/dist/src/schema/transactionRequest/intents/xdcStakingIntent.js +11 -1
- package/dist/src/schema/transactionRequest/intents/xdcStakingIntent.js.map +1 -1
- package/dist/src/schema/transactionRequest/transactionRequest.d.ts +122 -0
- package/package.json +1 -1
- package/src/schema/transactionRequest/intents/intent.ts +2 -0
- package/src/schema/transactionRequest/intents/xdcStakingIntent.ts +26 -0
|
@@ -7418,6 +7418,67 @@ export declare const TransactionIntent: t.UnionC<[t.IntersectionC<[t.Intersectio
|
|
|
7418
7418
|
intentType: t.LiteralC<"contractCall">;
|
|
7419
7419
|
ipfsHash: import("io-ts-types").NonEmptyStringC;
|
|
7420
7420
|
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
7421
|
+
}>]>, t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.TypeC<{
|
|
7422
|
+
intentType: t.KeyofC<{
|
|
7423
|
+
payment: t.LiteralC<"payment">;
|
|
7424
|
+
transferToken: t.LiteralC<"transferToken">;
|
|
7425
|
+
consolidate: t.LiteralC<"consolidate">;
|
|
7426
|
+
consolidateToken: t.LiteralC<"consolidateToken">;
|
|
7427
|
+
fanout: t.LiteralC<"fanout">;
|
|
7428
|
+
stake: t.LiteralC<"stake">;
|
|
7429
|
+
unstake: t.LiteralC<"unstake">;
|
|
7430
|
+
delegate: t.LiteralC<"delegate">;
|
|
7431
|
+
undelegate: t.LiteralC<"undelegate">;
|
|
7432
|
+
switchValidator: t.LiteralC<"switchValidator">;
|
|
7433
|
+
claim: t.LiteralC<"claim">;
|
|
7434
|
+
stakeClaimRewards: t.LiteralC<"stakeClaimRewards">;
|
|
7435
|
+
pledge: t.LiteralC<"pledge">;
|
|
7436
|
+
voteDelegation: t.LiteralC<"voteDelegation">;
|
|
7437
|
+
vote: t.LiteralC<"vote">;
|
|
7438
|
+
createAccount: t.LiteralC<"createAccount">;
|
|
7439
|
+
updateAccount: t.LiteralC<"updateAccount">;
|
|
7440
|
+
addTrustLine: t.LiteralC<"addTrustLine">;
|
|
7441
|
+
removeTrustLine: t.LiteralC<"removeTrustLine">;
|
|
7442
|
+
signMessage: t.LiteralC<"signMessage">;
|
|
7443
|
+
signTypedStructuredData: t.LiteralC<"signTypedStructuredData">;
|
|
7444
|
+
enableToken: t.LiteralC<"enableToken">;
|
|
7445
|
+
authorize: t.LiteralC<"authorize">;
|
|
7446
|
+
acceleration: t.LiteralC<"acceleration">;
|
|
7447
|
+
fillNonce: t.LiteralC<"fillNonce">;
|
|
7448
|
+
walletRecovery: t.LiteralC<"walletRecovery">;
|
|
7449
|
+
contractCall: t.LiteralC<"contractCall">;
|
|
7450
|
+
deactivate: t.LiteralC<"deactivate">;
|
|
7451
|
+
customTx: t.LiteralC<"customTx">;
|
|
7452
|
+
closeAssociatedTokenAccount: t.LiteralC<"closeAssociatedTokenAccount">;
|
|
7453
|
+
stakeWithCallData: t.LiteralC<"stakeWithCallData">;
|
|
7454
|
+
unstakeWithCallData: t.LiteralC<"unstakeWithCallData">;
|
|
7455
|
+
switchValidatorWithCallData: t.LiteralC<"switchValidatorWithCallData">;
|
|
7456
|
+
feeAddressTransfer: t.LiteralC<"feeAddressTransfer">;
|
|
7457
|
+
tokenApproval: t.LiteralC<"tokenApproval">;
|
|
7458
|
+
transferStake: t.LiteralC<"transferStake">;
|
|
7459
|
+
validatorRegistration: t.LiteralC<"validatorRegistration">;
|
|
7460
|
+
goUnstake: t.LiteralC<"goUnstake">;
|
|
7461
|
+
createBtcDelegation: t.LiteralC<"createBtcDelegation">;
|
|
7462
|
+
transferAccept: t.LiteralC<"transferAccept">;
|
|
7463
|
+
transferReject: t.LiteralC<"transferReject">;
|
|
7464
|
+
transferAcknowledge: t.LiteralC<"transferAcknowledge">;
|
|
7465
|
+
}>;
|
|
7466
|
+
}>, t.PartialC<{
|
|
7467
|
+
sequenceId: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
7468
|
+
comment: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
7469
|
+
nonce: t.UnionC<[t.Type<string | number, string | number, unknown>, t.UndefinedC]>;
|
|
7470
|
+
}>]>, t.TypeC<{
|
|
7471
|
+
stakingRequestId: t.StringC;
|
|
7472
|
+
}>]>, t.TypeC<{
|
|
7473
|
+
intentType: t.LiteralC<"validatorRegistration">;
|
|
7474
|
+
}>]>, t.TypeC<{
|
|
7475
|
+
amount: t.TypeC<{
|
|
7476
|
+
value: t.StringC;
|
|
7477
|
+
symbol: t.StringC;
|
|
7478
|
+
}>;
|
|
7479
|
+
}>, t.TypeC<{
|
|
7480
|
+
candidateAddress: import("io-ts-types").NonEmptyStringC;
|
|
7481
|
+
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
7421
7482
|
}>]>, t.IntersectionC<[t.TypeC<{
|
|
7422
7483
|
intentType: t.KeyofC<{
|
|
7423
7484
|
payment: t.LiteralC<"payment">;
|
|
@@ -124,6 +124,7 @@ const cantonTransferAcknowledgeIntent_1 = require("./cantonTransferAcknowledgeIn
|
|
|
124
124
|
const tonWhalesDelegateIntent_1 = require("./tonWhalesDelegateIntent");
|
|
125
125
|
const tonWhalesUndelegateIntent_1 = require("./tonWhalesUndelegateIntent");
|
|
126
126
|
const xdcStakingIntent_1 = require("./xdcStakingIntent");
|
|
127
|
+
const xdcStakingIntent_2 = require("./xdcStakingIntent");
|
|
127
128
|
exports.TransactionIntent = t.union([
|
|
128
129
|
adaConsolidateIntent_1.AdaConsolidateIntent,
|
|
129
130
|
adaPaymentIntent_1.AdaPaymentIntent,
|
|
@@ -224,6 +225,7 @@ exports.TransactionIntent = t.union([
|
|
|
224
225
|
walrusUndelegateIntent_1.WalrusUndelegateIntent,
|
|
225
226
|
walrusWithdrawIntent_1.WalrusWithdrawIntent,
|
|
226
227
|
xdcStakingIntent_1.XdcUploadKycIntent,
|
|
228
|
+
xdcStakingIntent_2.XdcProposeIntent,
|
|
227
229
|
baseIntent_1.BaseIntent,
|
|
228
230
|
]);
|
|
229
231
|
//# sourceMappingURL=intent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../../../../src/schema/transactionRequest/intents/intent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,iEAA8D;AAC9D,yDAAsD;AACtD,qDAAkD;AAClD,uEAAoE;AACpE,2DAAwD;AACxD,2DAAwD;AACxD,uDAAoD;AACpD,2DAAwD;AACxD,6DAA0D;AAC1D,mFAAgF;AAChF,yEAAsE;AACtE,2DAAwD;AACxD,+DAA4D;AAC5D,+EAA4E;AAC5E,6DAG8B;AAC9B,+DAA4D;AAC5D,2DAAwD;AACxD,+EAA4E;AAC5E,+DAA4D;AAC5D,iEAA8D;AAC9D,qEAAkE;AAClE,yDAAsD;AACtD,yDAAsD;AACtD,6DAA0D;AAC1D,qEAAkE;AAClE,mEAAgE;AAChE,6DAA0D;AAC1D,yDAAsD;AACtD,yDAAsD;AACtD,yEAAsE;AACtE,yDAAsD;AACtD,qEAAkE;AAClE,iEAA8D;AAC9D,uDAAoD;AACpD,2DAAwD;AACxD,6DAA0D;AAC1D,yEAAsE;AACtE,6EAA0E;AAC1E,yDAAsD;AACtD,6DAA0D;AAC1D,+DAA4D;AAC5D,6DAA0D;AAC1D,qDAAkD;AAClD,mGAAgG;AAChG,2DAAwD;AACxD,+DAA4D;AAC5D,2DAAwD;AACxD,yDAAsD;AACtD,qDAAkD;AAClD,yDAAsD;AACtD,6EAA0E;AAC1E,2DAAwD;AACxD,yDAAsD;AACtD,6DAA0D;AAC1D,6EAA0E;AAC1E,qEAAkE;AAClE,qDAAkD;AAClD,yEAAsE;AACtE,qEAAkE;AAClE,yDAAsD;AACtD,+DAA4D;AAC5D,2DAAwD;AACxD,yDAAsD;AACtD,+DAA4D;AAC5D,iEAA8D;AAC9D,iEAA8D;AAC9D,iEAA8D;AAC9D,6EAA0E;AAC1E,yDAAsD;AACtD,yDAAsD;AACtD,iEAA8D;AAC9D,yEAAsE;AACtE,iEAA8D;AAC9D,2EAAwE;AACxE,qEAAkE;AAClE,6CAA0C;AAC1C,iEAA8D;AAC9D,iGAA8F;AAC9F,+EAA4E;AAC5E,mEAAgE;AAChE,uEAAoE;AACpE,6DAA0D;AAC1D,6DAA0D;AAC1D,6DAA0D;AAC1D,+DAA4D;AAC5D,qEAAkE;AAClE,iEAA8D;AAC9D,6DAA0D;AAC1D,6DAA0D;AAC1D,yDAAsD;AACtD,2DAAwD;AACxD,6EAA0E;AAC1E,qFAAkF;AAClF,6EAA0E;AAC1E,6EAA0E;AAC1E,uFAAoF;AACpF,uEAAoE;AACpE,2EAAwE;AACxE,yDAAwD;
|
|
1
|
+
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../../../../src/schema/transactionRequest/intents/intent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,iEAA8D;AAC9D,yDAAsD;AACtD,qDAAkD;AAClD,uEAAoE;AACpE,2DAAwD;AACxD,2DAAwD;AACxD,uDAAoD;AACpD,2DAAwD;AACxD,6DAA0D;AAC1D,mFAAgF;AAChF,yEAAsE;AACtE,2DAAwD;AACxD,+DAA4D;AAC5D,+EAA4E;AAC5E,6DAG8B;AAC9B,+DAA4D;AAC5D,2DAAwD;AACxD,+EAA4E;AAC5E,+DAA4D;AAC5D,iEAA8D;AAC9D,qEAAkE;AAClE,yDAAsD;AACtD,yDAAsD;AACtD,6DAA0D;AAC1D,qEAAkE;AAClE,mEAAgE;AAChE,6DA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;IACrB,iDAAuB;IACvB,uCAAkB;IAClB,uCAAkB;IAClB,uCAAkB;IAClB,yCAAmB;IACnB,+CAAsB;IACtB,2CAAoB;IACpB,qCAAkB;IAClB,mCAAgB;IAKhB,uBAAU;CACX,CAAC,CAAC"}
|
|
@@ -56,3 +56,66 @@ export declare const XdcUploadKycIntent: t.IntersectionC<[t.IntersectionC<[t.Int
|
|
|
56
56
|
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
57
57
|
}>]>;
|
|
58
58
|
export type XdcUploadKycIntent = t.TypeOf<typeof XdcUploadKycIntent>;
|
|
59
|
+
export declare const XdcProposeIntent: t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.TypeC<{
|
|
60
|
+
intentType: t.KeyofC<{
|
|
61
|
+
payment: t.LiteralC<"payment">;
|
|
62
|
+
transferToken: t.LiteralC<"transferToken">;
|
|
63
|
+
consolidate: t.LiteralC<"consolidate">;
|
|
64
|
+
consolidateToken: t.LiteralC<"consolidateToken">;
|
|
65
|
+
fanout: t.LiteralC<"fanout">;
|
|
66
|
+
stake: t.LiteralC<"stake">;
|
|
67
|
+
unstake: t.LiteralC<"unstake">;
|
|
68
|
+
delegate: t.LiteralC<"delegate">;
|
|
69
|
+
undelegate: t.LiteralC<"undelegate">;
|
|
70
|
+
switchValidator: t.LiteralC<"switchValidator">;
|
|
71
|
+
claim: t.LiteralC<"claim">;
|
|
72
|
+
stakeClaimRewards: t.LiteralC<"stakeClaimRewards">;
|
|
73
|
+
pledge: t.LiteralC<"pledge">;
|
|
74
|
+
voteDelegation: t.LiteralC<"voteDelegation">;
|
|
75
|
+
vote: t.LiteralC<"vote">;
|
|
76
|
+
createAccount: t.LiteralC<"createAccount">;
|
|
77
|
+
updateAccount: t.LiteralC<"updateAccount">;
|
|
78
|
+
addTrustLine: t.LiteralC<"addTrustLine">;
|
|
79
|
+
removeTrustLine: t.LiteralC<"removeTrustLine">;
|
|
80
|
+
signMessage: t.LiteralC<"signMessage">;
|
|
81
|
+
signTypedStructuredData: t.LiteralC<"signTypedStructuredData">;
|
|
82
|
+
enableToken: t.LiteralC<"enableToken">;
|
|
83
|
+
authorize: t.LiteralC<"authorize">;
|
|
84
|
+
acceleration: t.LiteralC<"acceleration">;
|
|
85
|
+
fillNonce: t.LiteralC<"fillNonce">;
|
|
86
|
+
walletRecovery: t.LiteralC<"walletRecovery">;
|
|
87
|
+
contractCall: t.LiteralC<"contractCall">;
|
|
88
|
+
deactivate: t.LiteralC<"deactivate">;
|
|
89
|
+
customTx: t.LiteralC<"customTx">;
|
|
90
|
+
closeAssociatedTokenAccount: t.LiteralC<"closeAssociatedTokenAccount">;
|
|
91
|
+
stakeWithCallData: t.LiteralC<"stakeWithCallData">;
|
|
92
|
+
unstakeWithCallData: t.LiteralC<"unstakeWithCallData">;
|
|
93
|
+
switchValidatorWithCallData: t.LiteralC<"switchValidatorWithCallData">;
|
|
94
|
+
feeAddressTransfer: t.LiteralC<"feeAddressTransfer">;
|
|
95
|
+
tokenApproval: t.LiteralC<"tokenApproval">;
|
|
96
|
+
transferStake: t.LiteralC<"transferStake">;
|
|
97
|
+
validatorRegistration: t.LiteralC<"validatorRegistration">;
|
|
98
|
+
goUnstake: t.LiteralC<"goUnstake">;
|
|
99
|
+
createBtcDelegation: t.LiteralC<"createBtcDelegation">;
|
|
100
|
+
transferAccept: t.LiteralC<"transferAccept">;
|
|
101
|
+
transferReject: t.LiteralC<"transferReject">;
|
|
102
|
+
transferAcknowledge: t.LiteralC<"transferAcknowledge">;
|
|
103
|
+
}>;
|
|
104
|
+
}>, t.PartialC<{
|
|
105
|
+
sequenceId: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
106
|
+
comment: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
107
|
+
nonce: t.UnionC<[t.Type<string | number, string | number, unknown>, t.UndefinedC]>;
|
|
108
|
+
}>]>, t.TypeC<{
|
|
109
|
+
stakingRequestId: t.StringC;
|
|
110
|
+
}>]>, t.TypeC<{
|
|
111
|
+
intentType: t.LiteralC<"validatorRegistration">;
|
|
112
|
+
}>]>, t.TypeC<{
|
|
113
|
+
amount: t.TypeC<{
|
|
114
|
+
value: t.StringC;
|
|
115
|
+
symbol: t.StringC;
|
|
116
|
+
}>;
|
|
117
|
+
}>, t.TypeC<{
|
|
118
|
+
candidateAddress: import("io-ts-types").NonEmptyStringC;
|
|
119
|
+
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
120
|
+
}>]>;
|
|
121
|
+
export type XdcProposeIntent = t.TypeOf<typeof XdcProposeIntent>;
|
|
@@ -23,11 +23,13 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.XdcUploadKycIntent = void 0;
|
|
26
|
+
exports.XdcProposeIntent = exports.XdcUploadKycIntent = void 0;
|
|
27
27
|
const t = __importStar(require("io-ts"));
|
|
28
28
|
const baseStakeIntent_1 = require("./baseStakeIntent");
|
|
29
29
|
const intentType_1 = require("./intentType");
|
|
30
30
|
const io_ts_types_1 = require("io-ts-types");
|
|
31
|
+
const validatorRegistrationIntent_1 = require("./validatorRegistrationIntent");
|
|
32
|
+
const baseIntent_1 = require("./baseIntent");
|
|
31
33
|
exports.XdcUploadKycIntent = t.intersection([
|
|
32
34
|
baseStakeIntent_1.BaseStakeIntent,
|
|
33
35
|
t.type({
|
|
@@ -36,4 +38,12 @@ exports.XdcUploadKycIntent = t.intersection([
|
|
|
36
38
|
validatorContractAddress: io_ts_types_1.NonEmptyString,
|
|
37
39
|
}),
|
|
38
40
|
]);
|
|
41
|
+
exports.XdcProposeIntent = t.intersection([
|
|
42
|
+
validatorRegistrationIntent_1.ValidatorRegistrationIntent,
|
|
43
|
+
baseIntent_1.BaseIntentWithAmount,
|
|
44
|
+
t.type({
|
|
45
|
+
candidateAddress: io_ts_types_1.NonEmptyString,
|
|
46
|
+
validatorContractAddress: io_ts_types_1.NonEmptyString,
|
|
47
|
+
}),
|
|
48
|
+
]);
|
|
39
49
|
//# sourceMappingURL=xdcStakingIntent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"xdcStakingIntent.js","sourceRoot":"","sources":["../../../../../src/schema/transactionRequest/intents/xdcStakingIntent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,uDAAoD;AACpD,6CAA2C;AAC3C,6CAA6C;
|
|
1
|
+
{"version":3,"file":"xdcStakingIntent.js","sourceRoot":"","sources":["../../../../../src/schema/transactionRequest/intents/xdcStakingIntent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,uDAAoD;AACpD,6CAA2C;AAC3C,6CAA6C;AAC7C,+EAA4E;AAC5E,6CAAoD;AAavC,QAAA,kBAAkB,GAAG,CAAC,CAAC,YAAY,CAAC;IAC/C,iCAAe;IACf,CAAC,CAAC,IAAI,CAAC;QACL,UAAU,EAAE,wBAAW,CAAC,YAAY;QACpC,QAAQ,EAAE,4BAAc;QACxB,wBAAwB,EAAE,4BAAc;KACzC,CAAC;CACH,CAAC,CAAC;AAiBU,QAAA,gBAAgB,GAAG,CAAC,CAAC,YAAY,CAAC;IAC7C,yDAA2B;IAC3B,iCAAoB;IACpB,CAAC,CAAC,IAAI,CAAC;QACL,gBAAgB,EAAE,4BAAc;QAChC,wBAAwB,EAAE,4BAAc;KACzC,CAAC;CACH,CAAC,CAAC"}
|
|
@@ -7516,6 +7516,67 @@ export declare const TransactionRequestLite: t.IntersectionC<[t.IntersectionC<[t
|
|
|
7516
7516
|
intentType: t.LiteralC<"contractCall">;
|
|
7517
7517
|
ipfsHash: import("io-ts-types").NonEmptyStringC;
|
|
7518
7518
|
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
7519
|
+
}>]>, t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.TypeC<{
|
|
7520
|
+
intentType: t.KeyofC<{
|
|
7521
|
+
payment: t.LiteralC<"payment">;
|
|
7522
|
+
transferToken: t.LiteralC<"transferToken">;
|
|
7523
|
+
consolidate: t.LiteralC<"consolidate">;
|
|
7524
|
+
consolidateToken: t.LiteralC<"consolidateToken">;
|
|
7525
|
+
fanout: t.LiteralC<"fanout">;
|
|
7526
|
+
stake: t.LiteralC<"stake">;
|
|
7527
|
+
unstake: t.LiteralC<"unstake">;
|
|
7528
|
+
delegate: t.LiteralC<"delegate">;
|
|
7529
|
+
undelegate: t.LiteralC<"undelegate">;
|
|
7530
|
+
switchValidator: t.LiteralC<"switchValidator">;
|
|
7531
|
+
claim: t.LiteralC<"claim">;
|
|
7532
|
+
stakeClaimRewards: t.LiteralC<"stakeClaimRewards">;
|
|
7533
|
+
pledge: t.LiteralC<"pledge">;
|
|
7534
|
+
voteDelegation: t.LiteralC<"voteDelegation">;
|
|
7535
|
+
vote: t.LiteralC<"vote">;
|
|
7536
|
+
createAccount: t.LiteralC<"createAccount">;
|
|
7537
|
+
updateAccount: t.LiteralC<"updateAccount">;
|
|
7538
|
+
addTrustLine: t.LiteralC<"addTrustLine">;
|
|
7539
|
+
removeTrustLine: t.LiteralC<"removeTrustLine">;
|
|
7540
|
+
signMessage: t.LiteralC<"signMessage">;
|
|
7541
|
+
signTypedStructuredData: t.LiteralC<"signTypedStructuredData">;
|
|
7542
|
+
enableToken: t.LiteralC<"enableToken">;
|
|
7543
|
+
authorize: t.LiteralC<"authorize">;
|
|
7544
|
+
acceleration: t.LiteralC<"acceleration">;
|
|
7545
|
+
fillNonce: t.LiteralC<"fillNonce">;
|
|
7546
|
+
walletRecovery: t.LiteralC<"walletRecovery">;
|
|
7547
|
+
contractCall: t.LiteralC<"contractCall">;
|
|
7548
|
+
deactivate: t.LiteralC<"deactivate">;
|
|
7549
|
+
customTx: t.LiteralC<"customTx">;
|
|
7550
|
+
closeAssociatedTokenAccount: t.LiteralC<"closeAssociatedTokenAccount">;
|
|
7551
|
+
stakeWithCallData: t.LiteralC<"stakeWithCallData">;
|
|
7552
|
+
unstakeWithCallData: t.LiteralC<"unstakeWithCallData">;
|
|
7553
|
+
switchValidatorWithCallData: t.LiteralC<"switchValidatorWithCallData">;
|
|
7554
|
+
feeAddressTransfer: t.LiteralC<"feeAddressTransfer">;
|
|
7555
|
+
tokenApproval: t.LiteralC<"tokenApproval">;
|
|
7556
|
+
transferStake: t.LiteralC<"transferStake">;
|
|
7557
|
+
validatorRegistration: t.LiteralC<"validatorRegistration">;
|
|
7558
|
+
goUnstake: t.LiteralC<"goUnstake">;
|
|
7559
|
+
createBtcDelegation: t.LiteralC<"createBtcDelegation">;
|
|
7560
|
+
transferAccept: t.LiteralC<"transferAccept">;
|
|
7561
|
+
transferReject: t.LiteralC<"transferReject">;
|
|
7562
|
+
transferAcknowledge: t.LiteralC<"transferAcknowledge">;
|
|
7563
|
+
}>;
|
|
7564
|
+
}>, t.PartialC<{
|
|
7565
|
+
sequenceId: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
7566
|
+
comment: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
7567
|
+
nonce: t.UnionC<[t.Type<string | number, string | number, unknown>, t.UndefinedC]>;
|
|
7568
|
+
}>]>, t.TypeC<{
|
|
7569
|
+
stakingRequestId: t.StringC;
|
|
7570
|
+
}>]>, t.TypeC<{
|
|
7571
|
+
intentType: t.LiteralC<"validatorRegistration">;
|
|
7572
|
+
}>]>, t.TypeC<{
|
|
7573
|
+
amount: t.TypeC<{
|
|
7574
|
+
value: t.StringC;
|
|
7575
|
+
symbol: t.StringC;
|
|
7576
|
+
}>;
|
|
7577
|
+
}>, t.TypeC<{
|
|
7578
|
+
candidateAddress: import("io-ts-types").NonEmptyStringC;
|
|
7579
|
+
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
7519
7580
|
}>]>, t.IntersectionC<[t.TypeC<{
|
|
7520
7581
|
intentType: t.KeyofC<{
|
|
7521
7582
|
payment: t.LiteralC<"payment">;
|
|
@@ -15366,6 +15427,67 @@ export declare const TransactionRequest: t.UnionC<[t.IntersectionC<[t.Intersecti
|
|
|
15366
15427
|
intentType: t.LiteralC<"contractCall">;
|
|
15367
15428
|
ipfsHash: import("io-ts-types").NonEmptyStringC;
|
|
15368
15429
|
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
15430
|
+
}>]>, t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.IntersectionC<[t.TypeC<{
|
|
15431
|
+
intentType: t.KeyofC<{
|
|
15432
|
+
payment: t.LiteralC<"payment">;
|
|
15433
|
+
transferToken: t.LiteralC<"transferToken">;
|
|
15434
|
+
consolidate: t.LiteralC<"consolidate">;
|
|
15435
|
+
consolidateToken: t.LiteralC<"consolidateToken">;
|
|
15436
|
+
fanout: t.LiteralC<"fanout">;
|
|
15437
|
+
stake: t.LiteralC<"stake">;
|
|
15438
|
+
unstake: t.LiteralC<"unstake">;
|
|
15439
|
+
delegate: t.LiteralC<"delegate">;
|
|
15440
|
+
undelegate: t.LiteralC<"undelegate">;
|
|
15441
|
+
switchValidator: t.LiteralC<"switchValidator">;
|
|
15442
|
+
claim: t.LiteralC<"claim">;
|
|
15443
|
+
stakeClaimRewards: t.LiteralC<"stakeClaimRewards">;
|
|
15444
|
+
pledge: t.LiteralC<"pledge">;
|
|
15445
|
+
voteDelegation: t.LiteralC<"voteDelegation">;
|
|
15446
|
+
vote: t.LiteralC<"vote">;
|
|
15447
|
+
createAccount: t.LiteralC<"createAccount">;
|
|
15448
|
+
updateAccount: t.LiteralC<"updateAccount">;
|
|
15449
|
+
addTrustLine: t.LiteralC<"addTrustLine">;
|
|
15450
|
+
removeTrustLine: t.LiteralC<"removeTrustLine">;
|
|
15451
|
+
signMessage: t.LiteralC<"signMessage">;
|
|
15452
|
+
signTypedStructuredData: t.LiteralC<"signTypedStructuredData">;
|
|
15453
|
+
enableToken: t.LiteralC<"enableToken">;
|
|
15454
|
+
authorize: t.LiteralC<"authorize">;
|
|
15455
|
+
acceleration: t.LiteralC<"acceleration">;
|
|
15456
|
+
fillNonce: t.LiteralC<"fillNonce">;
|
|
15457
|
+
walletRecovery: t.LiteralC<"walletRecovery">;
|
|
15458
|
+
contractCall: t.LiteralC<"contractCall">;
|
|
15459
|
+
deactivate: t.LiteralC<"deactivate">;
|
|
15460
|
+
customTx: t.LiteralC<"customTx">;
|
|
15461
|
+
closeAssociatedTokenAccount: t.LiteralC<"closeAssociatedTokenAccount">;
|
|
15462
|
+
stakeWithCallData: t.LiteralC<"stakeWithCallData">;
|
|
15463
|
+
unstakeWithCallData: t.LiteralC<"unstakeWithCallData">;
|
|
15464
|
+
switchValidatorWithCallData: t.LiteralC<"switchValidatorWithCallData">;
|
|
15465
|
+
feeAddressTransfer: t.LiteralC<"feeAddressTransfer">;
|
|
15466
|
+
tokenApproval: t.LiteralC<"tokenApproval">;
|
|
15467
|
+
transferStake: t.LiteralC<"transferStake">;
|
|
15468
|
+
validatorRegistration: t.LiteralC<"validatorRegistration">;
|
|
15469
|
+
goUnstake: t.LiteralC<"goUnstake">;
|
|
15470
|
+
createBtcDelegation: t.LiteralC<"createBtcDelegation">;
|
|
15471
|
+
transferAccept: t.LiteralC<"transferAccept">;
|
|
15472
|
+
transferReject: t.LiteralC<"transferReject">;
|
|
15473
|
+
transferAcknowledge: t.LiteralC<"transferAcknowledge">;
|
|
15474
|
+
}>;
|
|
15475
|
+
}>, t.PartialC<{
|
|
15476
|
+
sequenceId: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
15477
|
+
comment: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
|
|
15478
|
+
nonce: t.UnionC<[t.Type<string | number, string | number, unknown>, t.UndefinedC]>;
|
|
15479
|
+
}>]>, t.TypeC<{
|
|
15480
|
+
stakingRequestId: t.StringC;
|
|
15481
|
+
}>]>, t.TypeC<{
|
|
15482
|
+
intentType: t.LiteralC<"validatorRegistration">;
|
|
15483
|
+
}>]>, t.TypeC<{
|
|
15484
|
+
amount: t.TypeC<{
|
|
15485
|
+
value: t.StringC;
|
|
15486
|
+
symbol: t.StringC;
|
|
15487
|
+
}>;
|
|
15488
|
+
}>, t.TypeC<{
|
|
15489
|
+
candidateAddress: import("io-ts-types").NonEmptyStringC;
|
|
15490
|
+
validatorContractAddress: import("io-ts-types").NonEmptyStringC;
|
|
15369
15491
|
}>]>, t.IntersectionC<[t.TypeC<{
|
|
15370
15492
|
intentType: t.KeyofC<{
|
|
15371
15493
|
payment: t.LiteralC<"payment">;
|
package/package.json
CHANGED
|
@@ -101,6 +101,7 @@ import { CantonTransferAcknowledgeIntent } from "./cantonTransferAcknowledgeInte
|
|
|
101
101
|
import { TonWhalesDelegateIntent } from "./tonWhalesDelegateIntent";
|
|
102
102
|
import { TonWhalesUndelegateIntent } from "./tonWhalesUndelegateIntent";
|
|
103
103
|
import { XdcUploadKycIntent } from "./xdcStakingIntent";
|
|
104
|
+
import { XdcProposeIntent } from "./xdcStakingIntent";
|
|
104
105
|
|
|
105
106
|
export const TransactionIntent = t.union([
|
|
106
107
|
AdaConsolidateIntent,
|
|
@@ -202,6 +203,7 @@ export const TransactionIntent = t.union([
|
|
|
202
203
|
WalrusUndelegateIntent,
|
|
203
204
|
WalrusWithdrawIntent,
|
|
204
205
|
XdcUploadKycIntent,
|
|
206
|
+
XdcProposeIntent,
|
|
205
207
|
|
|
206
208
|
/**
|
|
207
209
|
* Catch all for past intents that have not been converted to codecs
|
|
@@ -2,6 +2,8 @@ import * as t from "io-ts";
|
|
|
2
2
|
import { BaseStakeIntent } from "./baseStakeIntent";
|
|
3
3
|
import { intentTypes } from "./intentType";
|
|
4
4
|
import { NonEmptyString } from "io-ts-types";
|
|
5
|
+
import { ValidatorRegistrationIntent } from "./validatorRegistrationIntent";
|
|
6
|
+
import { BaseIntentWithAmount } from "./baseIntent";
|
|
5
7
|
|
|
6
8
|
/**
|
|
7
9
|
* @title XDC Upload KYC Intent
|
|
@@ -24,3 +26,27 @@ export const XdcUploadKycIntent = t.intersection([
|
|
|
24
26
|
]);
|
|
25
27
|
|
|
26
28
|
export type XdcUploadKycIntent = t.TypeOf<typeof XdcUploadKycIntent>;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* @title XDC Propose Intent
|
|
32
|
+
*
|
|
33
|
+
* Intent for proposing a validator candidate on XDC network.
|
|
34
|
+
* This registers the validator and stakes XDC.
|
|
35
|
+
* Must be done AFTER uploading KYC.
|
|
36
|
+
*
|
|
37
|
+
* @param {string} intentType - The type of intent (validatorRegistration)
|
|
38
|
+
* @param {string} stakingRequestId - The staking request identifier
|
|
39
|
+
* @param {Amount} amount - The amount of XDC to stake (must be >= minCandidateCap)
|
|
40
|
+
* @param {string} candidateAddress - The address of the validator candidate
|
|
41
|
+
* @param {string} validatorContractAddress - The address of the XDC Validator contract
|
|
42
|
+
*/
|
|
43
|
+
export const XdcProposeIntent = t.intersection([
|
|
44
|
+
ValidatorRegistrationIntent,
|
|
45
|
+
BaseIntentWithAmount,
|
|
46
|
+
t.type({
|
|
47
|
+
candidateAddress: NonEmptyString,
|
|
48
|
+
validatorContractAddress: NonEmptyString,
|
|
49
|
+
}),
|
|
50
|
+
]);
|
|
51
|
+
|
|
52
|
+
export type XdcProposeIntent = t.TypeOf<typeof XdcProposeIntent>;
|