phantasma-sdk-ts 0.11.0 → 0.13.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.
Files changed (33) hide show
  1. package/dist/cjs/rpc/interfaces/estimate-transaction.js +28 -0
  2. package/dist/cjs/rpc/interfaces/gas-config.js +64 -0
  3. package/dist/cjs/rpc/interfaces/index.js +2 -0
  4. package/dist/cjs/rpc/phantasma.js +22 -0
  5. package/dist/cjs/types/carbon/blockchain/gas-config.js +137 -0
  6. package/dist/cjs/types/carbon/blockchain/index.js +1 -0
  7. package/dist/cjs/types/carbon/blockchain/tx-helpers/index.js +1 -0
  8. package/dist/cjs/types/carbon/blockchain/tx-helpers/native-fee-estimator.js +268 -0
  9. package/dist/esm/rpc/interfaces/estimate-transaction.js +25 -0
  10. package/dist/esm/rpc/interfaces/gas-config.js +61 -0
  11. package/dist/esm/rpc/interfaces/index.js +2 -0
  12. package/dist/esm/rpc/phantasma.js +22 -0
  13. package/dist/esm/types/carbon/blockchain/gas-config.js +133 -0
  14. package/dist/esm/types/carbon/blockchain/index.js +1 -0
  15. package/dist/esm/types/carbon/blockchain/tx-helpers/index.js +1 -0
  16. package/dist/esm/types/carbon/blockchain/tx-helpers/native-fee-estimator.js +263 -0
  17. package/dist/types/rpc/interfaces/estimate-transaction.d.ts +36 -0
  18. package/dist/types/rpc/interfaces/estimate-transaction.d.ts.map +1 -0
  19. package/dist/types/rpc/interfaces/gas-config.d.ts +61 -0
  20. package/dist/types/rpc/interfaces/gas-config.d.ts.map +1 -0
  21. package/dist/types/rpc/interfaces/index.d.ts +2 -0
  22. package/dist/types/rpc/interfaces/index.d.ts.map +1 -1
  23. package/dist/types/rpc/phantasma.d.ts +18 -0
  24. package/dist/types/rpc/phantasma.d.ts.map +1 -1
  25. package/dist/types/types/carbon/blockchain/gas-config.d.ts +63 -0
  26. package/dist/types/types/carbon/blockchain/gas-config.d.ts.map +1 -0
  27. package/dist/types/types/carbon/blockchain/index.d.ts +1 -0
  28. package/dist/types/types/carbon/blockchain/index.d.ts.map +1 -1
  29. package/dist/types/types/carbon/blockchain/tx-helpers/index.d.ts +1 -0
  30. package/dist/types/types/carbon/blockchain/tx-helpers/index.d.ts.map +1 -1
  31. package/dist/types/types/carbon/blockchain/tx-helpers/native-fee-estimator.d.ts +105 -0
  32. package/dist/types/types/carbon/blockchain/tx-helpers/native-fee-estimator.d.ts.map +1 -0
  33. package/package.json +1 -1
@@ -410,6 +410,28 @@ export class PhantasmaAPI {
410
410
  const params = [name, extended];
411
411
  return (await this.JSONRPC('getChain', params));
412
412
  }
413
+ /**
414
+ * Returns the current on-chain gas configuration plus the chain parameters fee estimation
415
+ * needs (block rate target, expiry window). Changes only via governance resolutions, so the
416
+ * result is safe to cache. Feed gasConfigFromRpc() into estimateNativeFee() for Tier-1 fee
417
+ * estimates.
418
+ */
419
+ async getGasConfig() {
420
+ const params = [];
421
+ return (await this.JSONRPC('getGasConfig', params));
422
+ }
423
+ /**
424
+ * Dry-runs a serialized transaction envelope against current chain state and returns its exact
425
+ * fee bill with recommended maxGas/maxData ceilings (gas-model-v2 Tier-2 estimate). Signatures
426
+ * inside the envelope may be zero-filled dummies of the correct length - the simulation skips
427
+ * signature checks, and dummies preserve the exact envelope byte length the bill depends on.
428
+ * Until the estimate service is launched this method returns a standard RPC error; use the
429
+ * Tier-1 estimateNativeFee() with getGasConfig() as the fallback.
430
+ */
431
+ async estimateTransaction(txData) {
432
+ const params = [txData];
433
+ return (await this.JSONRPC('estimateTransaction', params));
434
+ }
413
435
  //Returns info about the nexus.
414
436
  // Warning: current Carbon RPC endpoint is stubbed and returns a default nexus object.
415
437
  async getNexus(extended = true) {
@@ -0,0 +1,133 @@
1
+ /**
2
+ * On-chain gas configuration (governance module). The gas-model-v2 extension fields serialize
3
+ * only for version >= 1, mirroring the node's data_blockchain.h wire format exactly: the
4
+ * version-0 byte image is frozen forever for historical replay, and a version>=1 image truncated
5
+ * to the v0 length fails to parse (the tail read throws on end of stream).
6
+ */
7
+ export class GasConfig {
8
+ constructor(init) {
9
+ this.version = 0;
10
+ this.maxNameLength = 0;
11
+ this.maxTokenSymbolLength = 0;
12
+ this.feeShift = 0;
13
+ this.maxStructureSize = 0;
14
+ this.feeMultiplier = 0n;
15
+ this.gasTokenId = 0n;
16
+ this.dataTokenId = 0n;
17
+ this.minimumGasOffer = 0n;
18
+ this.dataEscrowPerRow = 0n;
19
+ this.gasFeeTransfer = 0n;
20
+ this.gasFeeQuery = 0n;
21
+ this.gasFeeCreateTokenBase = 0n;
22
+ this.gasFeeCreateTokenSymbol = 0n;
23
+ this.gasFeeCreateTokenSeries = 0n;
24
+ this.gasFeePerByte = 0n;
25
+ this.gasFeeRegisterName = 0n;
26
+ this.gasBurnRatioMul = 0n;
27
+ this.gasBurnRatioShift = 0;
28
+ this.minimumGasBill = 0n;
29
+ this.gasProducerRatioMul = 0n;
30
+ this.gasProducerRatioShift = 0;
31
+ this.gasDappRatioMul = 0n;
32
+ this.gasDappRatioShift = 0;
33
+ this.policyFeeCreateTokenBase = 0n;
34
+ this.policyFeeCreateTokenSymbol = 0n;
35
+ this.policyFeeCreateTokenSeries = 0n;
36
+ this.policyFeeRegisterName = 0n;
37
+ this.legacyDataEscrowPerRow = 0n;
38
+ Object.assign(this, init);
39
+ }
40
+ /**
41
+ * True when this config activates the gas-model-v2 billing rules (config version >= 1). The
42
+ * gas model is gated by the config version, not by a chain feature level.
43
+ */
44
+ get hasGasModelV2() {
45
+ return this.version >= 1;
46
+ }
47
+ write(w) {
48
+ w.write1(this.version);
49
+ w.write1(this.maxNameLength);
50
+ w.write1(this.maxTokenSymbolLength);
51
+ w.write1(this.feeShift);
52
+ w.write4u(this.maxStructureSize);
53
+ w.write8u(this.feeMultiplier);
54
+ w.write8u(this.gasTokenId);
55
+ w.write8u(this.dataTokenId);
56
+ w.write8u(this.minimumGasOffer);
57
+ w.write8u(this.dataEscrowPerRow);
58
+ w.write8u(this.gasFeeTransfer);
59
+ w.write8u(this.gasFeeQuery);
60
+ w.write8u(this.gasFeeCreateTokenBase);
61
+ w.write8u(this.gasFeeCreateTokenSymbol);
62
+ w.write8u(this.gasFeeCreateTokenSeries);
63
+ w.write8u(this.gasFeePerByte);
64
+ w.write8u(this.gasFeeRegisterName);
65
+ w.write8u(this.gasBurnRatioMul);
66
+ w.write1(this.gasBurnRatioShift);
67
+ if (this.version === 0) {
68
+ // Version-0 wire image must stay byte-identical to the pre-v2 layout.
69
+ return;
70
+ }
71
+ w.write8u(this.minimumGasBill);
72
+ w.write8u(this.gasProducerRatioMul);
73
+ w.write1(this.gasProducerRatioShift);
74
+ w.write8u(this.gasDappRatioMul);
75
+ w.write1(this.gasDappRatioShift);
76
+ w.write8u(this.policyFeeCreateTokenBase);
77
+ w.write8u(this.policyFeeCreateTokenSymbol);
78
+ w.write8u(this.policyFeeCreateTokenSeries);
79
+ w.write8u(this.policyFeeRegisterName);
80
+ w.write8u(this.legacyDataEscrowPerRow);
81
+ }
82
+ read(r) {
83
+ this.version = r.read1();
84
+ this.maxNameLength = r.read1();
85
+ this.maxTokenSymbolLength = r.read1();
86
+ this.feeShift = r.read1();
87
+ this.maxStructureSize = r.read4u();
88
+ this.feeMultiplier = r.read8u();
89
+ this.gasTokenId = r.read8u();
90
+ this.dataTokenId = r.read8u();
91
+ this.minimumGasOffer = r.read8u();
92
+ this.dataEscrowPerRow = r.read8u();
93
+ this.gasFeeTransfer = r.read8u();
94
+ this.gasFeeQuery = r.read8u();
95
+ this.gasFeeCreateTokenBase = r.read8u();
96
+ this.gasFeeCreateTokenSymbol = r.read8u();
97
+ this.gasFeeCreateTokenSeries = r.read8u();
98
+ this.gasFeePerByte = r.read8u();
99
+ this.gasFeeRegisterName = r.read8u();
100
+ this.gasBurnRatioMul = r.read8u();
101
+ this.gasBurnRatioShift = r.read1();
102
+ if (this.version === 0) {
103
+ // Version-0 rows carry no v2 tail; zero it so a reused instance never leaks stale values.
104
+ this.minimumGasBill = 0n;
105
+ this.gasProducerRatioMul = 0n;
106
+ this.gasProducerRatioShift = 0;
107
+ this.gasDappRatioMul = 0n;
108
+ this.gasDappRatioShift = 0;
109
+ this.policyFeeCreateTokenBase = 0n;
110
+ this.policyFeeCreateTokenSymbol = 0n;
111
+ this.policyFeeCreateTokenSeries = 0n;
112
+ this.policyFeeRegisterName = 0n;
113
+ this.legacyDataEscrowPerRow = 0n;
114
+ return;
115
+ }
116
+ // version >= 1: the tail is mandatory; a truncated image throws (end of stream).
117
+ this.minimumGasBill = r.read8u();
118
+ this.gasProducerRatioMul = r.read8u();
119
+ this.gasProducerRatioShift = r.read1();
120
+ this.gasDappRatioMul = r.read8u();
121
+ this.gasDappRatioShift = r.read1();
122
+ this.policyFeeCreateTokenBase = r.read8u();
123
+ this.policyFeeCreateTokenSymbol = r.read8u();
124
+ this.policyFeeCreateTokenSeries = r.read8u();
125
+ this.policyFeeRegisterName = r.read8u();
126
+ this.legacyDataEscrowPerRow = r.read8u();
127
+ }
128
+ static read(r) {
129
+ const v = new GasConfig();
130
+ v.read(r);
131
+ return v;
132
+ }
133
+ }
@@ -3,6 +3,7 @@ export * from './modules/index.js';
3
3
  export * from './tx-helpers/index.js';
4
4
  export * from './vm/index.js';
5
5
  export * from './carbon-token-flags.js';
6
+ export * from './gas-config.js';
6
7
  export * from './module-id.js';
7
8
  export * from './signed-tx-msg.js';
8
9
  export * from './tx-msg.js';
@@ -3,3 +3,4 @@ export * from './create-token-tx-helper.js';
3
3
  export * from './fee-options.js';
4
4
  export * from './mint-phantasma-non-fungible-tx-helper.js';
5
5
  export * from './mint-non-fungible-tx-helper.js';
6
+ export * from './native-fee-estimator.js';
@@ -0,0 +1,263 @@
1
+ /** Native operation kinds supported by the Tier-1 fee estimator. */
2
+ export var NativeFeeKind;
3
+ (function (NativeFeeKind) {
4
+ /** Fungible token transfer (native TxTypes.TransferFungible / _GasPayer). */
5
+ NativeFeeKind["TransferFungible"] = "TransferFungible";
6
+ /** NFT transfer of `count` instances (TxTypes.TransferNonFungible_*). */
7
+ NativeFeeKind["TransferNonFungible"] = "TransferNonFungible";
8
+ /** Fungible mint (TxTypes.MintFungible or TokenContract.MintFungible call). */
9
+ NativeFeeKind["MintFungible"] = "MintFungible";
10
+ /** NFT mint of `count` instances (TxTypes.MintNonFungible or contract call). */
11
+ NativeFeeKind["MintNonFungible"] = "MintNonFungible";
12
+ /** Fungible burn (TxTypes.BurnFungible / _GasPayer). */
13
+ NativeFeeKind["BurnFungible"] = "BurnFungible";
14
+ /** NFT burn of `count` instances (TxTypes.BurnNonFungible / _GasPayer). */
15
+ NativeFeeKind["BurnNonFungible"] = "BurnNonFungible";
16
+ /** TokenContract.CreateToken call. Requires `symbolLength` when a symbol is set. */
17
+ NativeFeeKind["CreateToken"] = "CreateToken";
18
+ /** TokenContract.CreateTokenSeries call. */
19
+ NativeFeeKind["CreateTokenSeries"] = "CreateTokenSeries";
20
+ /** GovernanceContract.RegisterName call. Requires `nameLength`. */
21
+ NativeFeeKind["RegisterName"] = "RegisterName";
22
+ /**
23
+ * Generic Phantasma VM script transaction (AllowGas/SpendGas pattern: stake, marketplace,
24
+ * custom contract calls). Script opcode costs are not closed-form in Tier-1; the estimate
25
+ * budgets `scriptUnitsAllowance` VM work units on top of the byte fee. For an exact script
26
+ * bill use the node-side Tier-2 estimator once available.
27
+ */
28
+ NativeFeeKind["Script"] = "Script";
29
+ })(NativeFeeKind || (NativeFeeKind = {}));
30
+ /**
31
+ * Gas model v2 price of block-carried bytes, in gas units per byte. A versioned consensus
32
+ * constant of the v2 gas model (node data_blockchain.h kGasModelV2UnitsPerBlockDataByte),
33
+ * deliberately not part of the on-chain config.
34
+ */
35
+ export const GAS_MODEL_V2_UNITS_PER_BLOCK_DATA_BYTE = 25n;
36
+ /** Serialized size of one witness-array entry (32-byte address + 64-byte signature). */
37
+ export const WITNESS_ARRAY_ENTRY_BYTES = 96;
38
+ /** Serialized size of one bare signature (native TxTypes carry no witness array). */
39
+ export const NATIVE_SIGNATURE_BYTES = 64;
40
+ const U64_MAX = 0xffffffffffffffffn;
41
+ /**
42
+ * Tier-1 static fee calculator: closed-form gas/data offers for native operations, exact under
43
+ * both gas models (selected by GasConfig.version). Mirrors the validator billing formula
44
+ * (node blockchain.cpp settlement + token/governance contract gas sites); any change to those
45
+ * formulas ships as a new gas-model version, never silently.
46
+ *
47
+ * @param kind - Operation kind.
48
+ * @param config - Current chain gas config (see the getGasConfig RPC method).
49
+ * @param params - Optional inputs; omit for safe single-signer defaults.
50
+ */
51
+ export function estimateNativeFee(kind, config, params = {}) {
52
+ const count = params.count ?? 1;
53
+ if (!Number.isSafeInteger(count) || count < 1) {
54
+ throw new RangeError('count must be a positive integer');
55
+ }
56
+ const countU = BigInt(count);
57
+ const v2 = config.hasGasModelV2;
58
+ // Work units consumed by the operation itself (the ConsumeGas amounts in the token /
59
+ // governance contracts) and, under v2, the direct kcal-base policy fee that replaces the v1
60
+ // unit-priced product prices.
61
+ let workUnits;
62
+ let policyFee = 0n;
63
+ switch (kind) {
64
+ case NativeFeeKind.TransferFungible:
65
+ case NativeFeeKind.MintFungible:
66
+ case NativeFeeKind.BurnFungible:
67
+ workUnits = config.gasFeeTransfer;
68
+ break;
69
+ case NativeFeeKind.TransferNonFungible:
70
+ case NativeFeeKind.MintNonFungible:
71
+ case NativeFeeKind.BurnNonFungible:
72
+ workUnits = clampU64(config.gasFeeTransfer * countU);
73
+ break;
74
+ case NativeFeeKind.CreateToken: {
75
+ // Symbol price halves per character after the first; shift is validated by the chain
76
+ // against maxTokenSymbolLength, mirror that bound here.
77
+ const shift = symbolShift(params.symbolLength ?? 0, config.maxTokenSymbolLength, 'symbolLength');
78
+ const hasSymbol = (params.symbolLength ?? 0) > 0;
79
+ if (v2) {
80
+ workUnits = 0n;
81
+ policyFee = clampU64(config.policyFeeCreateTokenBase +
82
+ (hasSymbol ? config.policyFeeCreateTokenSymbol >> shift : 0n));
83
+ }
84
+ else {
85
+ workUnits = clampU64(config.gasFeeCreateTokenBase + (hasSymbol ? config.gasFeeCreateTokenSymbol >> shift : 0n));
86
+ }
87
+ break;
88
+ }
89
+ case NativeFeeKind.CreateTokenSeries:
90
+ workUnits = v2 ? 0n : config.gasFeeCreateTokenSeries;
91
+ policyFee = v2 ? config.policyFeeCreateTokenSeries : 0n;
92
+ break;
93
+ case NativeFeeKind.RegisterName: {
94
+ const nameLength = params.nameLength ?? 0;
95
+ if (nameLength <= 0) {
96
+ throw new RangeError('nameLength is required for RegisterName');
97
+ }
98
+ const shift = symbolShift(nameLength, config.maxNameLength, 'nameLength');
99
+ workUnits = v2 ? 0n : config.gasFeeRegisterName >> shift;
100
+ policyFee = v2 ? config.policyFeeRegisterName >> shift : 0n;
101
+ break;
102
+ }
103
+ case NativeFeeKind.Script:
104
+ workUnits = params.scriptUnitsAllowance ?? 5000n;
105
+ break;
106
+ default:
107
+ throw new RangeError(`unknown fee kind: ${kind}`);
108
+ }
109
+ const rows = BigInt(params.freshRows ?? defaultFreshRows(kind, count, params.romRamBytes ?? 0));
110
+ if (rows < 0n) {
111
+ throw new RangeError('freshRows must not be negative');
112
+ }
113
+ const envelope = BigInt(params.envelopeBytes ?? defaultEnvelopeBytes(kind, count, params.romRamBytes ?? 0));
114
+ // Native TxTypes store no events in the block; script txs do (Notify), so budget some.
115
+ const eventBytes = kind === NativeFeeKind.Script ? 512n : 0n;
116
+ let expected;
117
+ let maxGas;
118
+ if (v2) {
119
+ // v2 formula: bill = mulShiftSat(workUnits + blockData*25, mult, shift) + policyFee,
120
+ // floored at minimumGasBill. blockData = envelope + events + net storage quanta (quanta are
121
+ // added to the byte count by the chain formula).
122
+ expected = billV2(workUnits, envelope, eventBytes, rows, policyFee, config);
123
+ // Offer headroom: +25% over the padded bill covers witness-size wiggle and event variance;
124
+ // deterministic and always refunded down to the actual bill.
125
+ const padded = billV2(workUnits, roundUp(envelope, 128n), eventBytes, rows, policyFee, config);
126
+ maxGas = clampU64(padded + padded / 4n);
127
+ if (maxGas < config.minimumGasBill)
128
+ maxGas = config.minimumGasBill;
129
+ if (maxGas < config.minimumGasOffer)
130
+ maxGas = config.minimumGasOffer;
131
+ }
132
+ else {
133
+ // v1 formula: bill = (workUnits * mult >> shift) + blockData * gasFeePerByte where
134
+ // blockData = payload + events + net storage quanta (no envelope term, no floor).
135
+ const work = mulShift(workUnits, config.feeMultiplier, config.feeShift);
136
+ const blockData = BigInt(params.payloadBytes ?? 0) + eventBytes + rows;
137
+ expected = clampU64(work + clampU64(blockData * config.gasFeePerByte));
138
+ // Offer shape mirrors the validator's own test-agent stdFee: a 2x minimum-offer pad plus a
139
+ // flat 1 KiB block-data allowance on top of the work term.
140
+ const byteAllowance = blockData > 1024n ? blockData : 1024n;
141
+ maxGas = clampU64(config.minimumGasOffer * 2n + work + clampU64(byteAllowance * config.gasFeePerByte));
142
+ }
143
+ const maxData = clampU64(rows * config.dataEscrowPerRow);
144
+ return { maxGas, maxData, expectedGasBill: expected };
145
+ }
146
+ /**
147
+ * Envelope size (signed tx bytes as carried in the block) from a serialized unsigned message
148
+ * length and the number of signers. Use with {@link NativeFeeParams.envelopeBytes} for exact v2
149
+ * estimates. Witness layout mirrors SignedTxMsg: native TxTypes append bare 64-byte signatures
150
+ * (one, or two for the _GasPayer variants); Call/Trade/Phantasma txs append a length-prefixed
151
+ * witness array (32-byte address + 64-byte signature per entry).
152
+ */
153
+ export function envelopeBytesFor(kind, serializedMessageLength, witnessCount = 1) {
154
+ if (!Number.isSafeInteger(serializedMessageLength) || serializedMessageLength < 0) {
155
+ throw new RangeError('serializedMessageLength must be a non-negative integer');
156
+ }
157
+ if (!Number.isSafeInteger(witnessCount) || witnessCount < 0) {
158
+ throw new RangeError('witnessCount must be a non-negative integer');
159
+ }
160
+ switch (kind) {
161
+ case NativeFeeKind.TransferFungible:
162
+ case NativeFeeKind.TransferNonFungible:
163
+ case NativeFeeKind.MintFungible:
164
+ case NativeFeeKind.MintNonFungible:
165
+ case NativeFeeKind.BurnFungible:
166
+ case NativeFeeKind.BurnNonFungible:
167
+ return serializedMessageLength + NATIVE_SIGNATURE_BYTES * witnessCount;
168
+ default:
169
+ // CreateToken/CreateTokenSeries/RegisterName ride TxTypes.Call; Script rides
170
+ // TxTypes.Phantasma - both carry the witness array form.
171
+ return serializedMessageLength + 4 + WITNESS_ARRAY_ENTRY_BYTES * witnessCount;
172
+ }
173
+ }
174
+ function billV2(workUnits, envelope, eventBytes, rows, policyFee, config) {
175
+ const blockData = envelope + eventBytes + rows;
176
+ const byteUnits = clampU64(blockData * GAS_MODEL_V2_UNITS_PER_BLOCK_DATA_BYTE);
177
+ let bill = mulShift(clampU64(workUnits + byteUnits), config.feeMultiplier, config.feeShift);
178
+ bill = clampU64(bill + policyFee);
179
+ return bill < config.minimumGasBill ? config.minimumGasBill : bill;
180
+ }
181
+ // Chain fee scaling: (value * feeMultiplier) >> feeShift, saturating to u64. Matches the
182
+ // validator's v2 MulShiftSaturateU64; for sane v1 configs (live values never overflow 64 bits)
183
+ // it is also bit-identical to the v1 math.
184
+ function mulShift(value, multiplier, shift) {
185
+ if (shift >= 64)
186
+ return 0n; // the chain clamps oversized shifts to a zero delta
187
+ return clampU64((value * multiplier) >> BigInt(shift));
188
+ }
189
+ function symbolShift(length, maxLength, paramName) {
190
+ if (!Number.isSafeInteger(length) || length < 0) {
191
+ throw new RangeError(`${paramName} must be a non-negative integer`);
192
+ }
193
+ if (length === 0)
194
+ return 0n;
195
+ const shift = length - 1;
196
+ // The chain asserts shift < maxNameLength / maxTokenSymbolLength; a longer input could never
197
+ // be admitted, so reject it here instead of quoting a fee for an impossible tx.
198
+ if (maxLength !== 0 && shift >= maxLength) {
199
+ throw new RangeError(`${paramName} ${length} exceeds the chain maximum ${maxLength}`);
200
+ }
201
+ return BigInt(shift);
202
+ }
203
+ // Worst-case paid rows the operation can create (drives maxData). Refund-only operations
204
+ // (burns) need no escrow allowance: refunds never require maxData budget.
205
+ function defaultFreshRows(kind, count, romRamBytes) {
206
+ switch (kind) {
207
+ case NativeFeeKind.TransferFungible:
208
+ case NativeFeeKind.MintFungible:
209
+ return 1; // recipient balance row may be fresh (SOUL/KCAL rows would be free)
210
+ case NativeFeeKind.TransferNonFungible:
211
+ // Per instance the chain deletes the sender's NFT-lookup row and creates the recipient's
212
+ // (creation escrows at the current price, the deletion refunds the old row's own deposit)
213
+ // + possibly a fresh recipient balance row.
214
+ return count + 1;
215
+ case NativeFeeKind.MintNonFungible:
216
+ // Per instance: owner row + lookup row + the instance state rows holding ROM/RAM (1 KiB
217
+ // quanta), plus possibly a fresh recipient balance row.
218
+ return count * (2 + Math.ceil(romRamBytes / 1024)) + 1;
219
+ case NativeFeeKind.BurnFungible:
220
+ case NativeFeeKind.BurnNonFungible:
221
+ return 0;
222
+ case NativeFeeKind.CreateToken:
223
+ return 8; // token info + symbol lookup + supply/config rows, metadata-dependent
224
+ case NativeFeeKind.CreateTokenSeries:
225
+ return 4;
226
+ case NativeFeeKind.RegisterName:
227
+ return 2; // name->address and address->name rows
228
+ case NativeFeeKind.Script:
229
+ default:
230
+ return 4;
231
+ }
232
+ }
233
+ // Conservative single-witness envelope defaults per kind; used only when the caller did not
234
+ // measure the real signed size. Generous by design: under v2 an oversized estimate only raises
235
+ // the refunded offer, never the settled bill.
236
+ function defaultEnvelopeBytes(kind, count, romRamBytes) {
237
+ switch (kind) {
238
+ case NativeFeeKind.TransferFungible:
239
+ case NativeFeeKind.MintFungible:
240
+ case NativeFeeKind.BurnFungible:
241
+ case NativeFeeKind.RegisterName:
242
+ return 512;
243
+ case NativeFeeKind.TransferNonFungible:
244
+ case NativeFeeKind.BurnNonFungible:
245
+ return 512 + 8 * count; // 8 bytes per carried instance id
246
+ case NativeFeeKind.MintNonFungible:
247
+ return 512 + count * (64 + romRamBytes); // ROM/RAM ride the envelope
248
+ case NativeFeeKind.CreateToken:
249
+ return 4096; // token metadata (icons, descriptions) dominates
250
+ case NativeFeeKind.CreateTokenSeries:
251
+ return 2048;
252
+ case NativeFeeKind.Script:
253
+ default:
254
+ return 1024;
255
+ }
256
+ }
257
+ function roundUp(value, step) {
258
+ const rem = value % step;
259
+ return rem === 0n ? value : value + (step - rem);
260
+ }
261
+ function clampU64(value) {
262
+ return value > U64_MAX ? U64_MAX : value;
263
+ }
@@ -0,0 +1,36 @@
1
+ import { NativeFeeEstimate } from '../../types/carbon/blockchain/tx-helpers/native-fee-estimator.js';
2
+ /**
3
+ * Response of the estimateTransaction RPC method: the exact fee bill of one serialized
4
+ * transaction envelope, computed by dry-running it against current chain state (gas-model-v2
5
+ * Tier-2). 64-bit amounts arrive as decimal strings (they can exceed the 2^53 precision of JSON
6
+ * numbers). Amounts are kcal-base atoms of the gas token; escrow amounts are data-token atoms.
7
+ * Service availability (routing, gas model, node budget) surfaces as a standard RPC error, never
8
+ * through this shape. Feed {@link feeEstimateFromRpc} into the same NativeFeeEstimate wallets use
9
+ * for Tier-1 estimates.
10
+ */
11
+ export interface EstimateTransactionResult {
12
+ /** True when the transaction would not complete on-chain as submitted; see abortReason. */
13
+ wouldAbort: boolean;
14
+ /** Rejection or abort reason when wouldAbort is true; empty otherwise. */
15
+ abortReason?: string;
16
+ /** Settled gas bill in kcal-base, including the minimum-bill floor and the maxGas clamp (aborted transactions still pay). */
17
+ gasBillKcalBase: string;
18
+ /** Newly paid storage quanta the transaction creates (dataRows * dataEscrowPerRow == dataEscrowAtoms). */
19
+ dataRows: string;
20
+ /** Gross storage escrow paid for grown rows, in data-token atoms. */
21
+ dataEscrowAtoms: string;
22
+ /** Gross storage refunds for shrunk rows, in data-token atoms. */
23
+ dataRefundAtoms: string;
24
+ /** Recommended TxMsg.maxGas: the bill plus a 15% state-drift margin, floored at the chain minimums; "0" when wouldAbort. */
25
+ recommendedMaxGas: string;
26
+ /** Recommended TxMsg.maxData: the net escrow plus a 15% margin, aligned up to whole rows; "0" when wouldAbort or nothing is escrowed. */
27
+ recommendedMaxData: string;
28
+ }
29
+ /**
30
+ * Converts a completed estimate into the same NativeFeeEstimate struct Tier-1 estimates produce,
31
+ * so wallet code consumes both tiers identically: maxGas/maxData are the recommended ceilings and
32
+ * expectedGasBill is the exact settled bill. Throws when wouldAbort is set - an aborted simulation
33
+ * has no recommendations (retry with a higher offer or fall back to the Tier-1 estimator).
34
+ */
35
+ export declare function feeEstimateFromRpc(result: EstimateTransactionResult): NativeFeeEstimate;
36
+ //# sourceMappingURL=estimate-transaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"estimate-transaction.d.ts","sourceRoot":"","sources":["../../../../src/rpc/interfaces/estimate-transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,kEAAkE,CAAC;AAErG;;;;;;;;GAQG;AACH,MAAM,WAAW,yBAAyB;IACxC,2FAA2F;IAC3F,UAAU,EAAE,OAAO,CAAC;IACpB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,6HAA6H;IAC7H,eAAe,EAAE,MAAM,CAAC;IACxB,0GAA0G;IAC1G,QAAQ,EAAE,MAAM,CAAC;IACjB,qEAAqE;IACrE,eAAe,EAAE,MAAM,CAAC;IACxB,kEAAkE;IAClE,eAAe,EAAE,MAAM,CAAC;IACxB,4HAA4H;IAC5H,iBAAiB,EAAE,MAAM,CAAC;IAC1B,yIAAyI;IACzI,kBAAkB,EAAE,MAAM,CAAC;CAC5B;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,yBAAyB,GAAG,iBAAiB,CAWvF"}
@@ -0,0 +1,61 @@
1
+ import { GasConfig } from '../../types/carbon/blockchain/gas-config.js';
2
+ /**
3
+ * Response of the getGasConfig RPC method: the current on-chain gas configuration plus the
4
+ * chain parameters fee estimation needs. 64-bit config values arrive as decimal strings (they
5
+ * can exceed the 2^53 precision of JSON numbers). Feed {@link gasConfigFromRpc} into
6
+ * estimateNativeFee for Tier-1 fee estimates.
7
+ */
8
+ export interface GasConfigResult {
9
+ /** Gas model version: 1 = original fee model, 2 = gas-model-v2 (config version >= 1). */
10
+ gasModelVersion: number;
11
+ /** Current on-chain GasConfig. */
12
+ gasConfig?: GasConfigData;
13
+ /** Chain block rate target in milliseconds. */
14
+ blockRateTarget: number;
15
+ /** Transaction expiry window in milliseconds. */
16
+ expiryWindow: number;
17
+ /** Gas-model-v2 price of block-carried bytes in gas units per byte; absent under gas model v1. */
18
+ unitsPerBlockDataByte?: number;
19
+ }
20
+ /**
21
+ * JSON shape of the on-chain GasConfig. Fields after gasBurnRatioShift exist only when the
22
+ * config version is >= 1 (gas-model-v2) and are omitted from v1 responses.
23
+ */
24
+ export interface GasConfigData {
25
+ version: number;
26
+ maxNameLength: number;
27
+ maxTokenSymbolLength: number;
28
+ feeShift: number;
29
+ maxStructureSize: number;
30
+ feeMultiplier: string;
31
+ gasTokenId: string;
32
+ dataTokenId: string;
33
+ minimumGasOffer: string;
34
+ dataEscrowPerRow: string;
35
+ gasFeeTransfer: string;
36
+ gasFeeQuery: string;
37
+ gasFeeCreateTokenBase: string;
38
+ gasFeeCreateTokenSymbol: string;
39
+ gasFeeCreateTokenSeries: string;
40
+ gasFeePerByte: string;
41
+ gasFeeRegisterName: string;
42
+ gasBurnRatioMul: string;
43
+ gasBurnRatioShift: number;
44
+ minimumGasBill?: string;
45
+ gasProducerRatioMul?: string;
46
+ gasProducerRatioShift?: number;
47
+ gasDappRatioMul?: string;
48
+ gasDappRatioShift?: number;
49
+ policyFeeCreateTokenBase?: string;
50
+ policyFeeCreateTokenSymbol?: string;
51
+ policyFeeCreateTokenSeries?: string;
52
+ policyFeeRegisterName?: string;
53
+ legacyDataEscrowPerRow?: string;
54
+ }
55
+ /**
56
+ * Converts the getGasConfig JSON response to the wire-format GasConfig consumed by the Tier-1
57
+ * fee estimator. Throws on malformed numeric strings and on a v2 response missing tail fields:
58
+ * estimating fees from silently zeroed v2 prices would produce rejected transactions.
59
+ */
60
+ export declare function gasConfigFromRpc(result: GasConfigResult): GasConfig;
61
+ //# sourceMappingURL=gas-config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gas-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B,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,0BAA0B,CAAC,EAAE,MAAM,CAAC;IACpC,0BAA0B,CAAC,EAAE,MAAM,CAAC;IACpC,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,sBAAsB,CAAC,EAAE,MAAM,CAAC;CACjC;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,eAAe,GAAG,SAAS,CAgDnE"}
@@ -12,8 +12,10 @@ export * from './chain.js';
12
12
  export * from './channel.js';
13
13
  export * from './contract.js';
14
14
  export * from './dapp.js';
15
+ export * from './estimate-transaction.js';
15
16
  export * from './event.js';
16
17
  export * from './event-extended.js';
18
+ export * from './gas-config.js';
17
19
  export * from './governance.js';
18
20
  export * from './interop.js';
19
21
  export * from './key-value.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/rpc/interfaces/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AACnC,cAAc,cAAc,CAAC;AAC7B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAm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AiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AACtC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,uBAAuB,CAAC;AACtC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC"}
@@ -4,6 +4,8 @@ import { Nexus } from './interfaces/nexus.js';
4
4
  import { Account } from './interfaces/account.js';
5
5
  import { Leaderboard } from './interfaces/leaderboard.js';
6
6
  import { Chain } from './interfaces/chain.js';
7
+ import { GasConfigResult } from './interfaces/gas-config.js';
8
+ import { EstimateTransactionResult } from './interfaces/estimate-transaction.js';
7
9
  import { Contract } from './interfaces/contract.js';
8
10
  import { TransactionData } from './interfaces/transaction-data.js';
9
11
  import { AccountTransactions } from './interfaces/account-transactions.js';
@@ -67,6 +69,22 @@ export declare class PhantasmaAPI {
67
69
  getTransaction(hashText: string): Promise<TransactionData>;
68
70
  getChains(extended?: boolean): Promise<Chain[]>;
69
71
  getChain(name: string, extended?: boolean): Promise<Chain>;
72
+ /**
73
+ * Returns the current on-chain gas configuration plus the chain parameters fee estimation
74
+ * needs (block rate target, expiry window). Changes only via governance resolutions, so the
75
+ * result is safe to cache. Feed gasConfigFromRpc() into estimateNativeFee() for Tier-1 fee
76
+ * estimates.
77
+ */
78
+ getGasConfig(): Promise<GasConfigResult>;
79
+ /**
80
+ * Dry-runs a serialized transaction envelope against current chain state and returns its exact
81
+ * fee bill with recommended maxGas/maxData ceilings (gas-model-v2 Tier-2 estimate). Signatures
82
+ * inside the envelope may be zero-filled dummies of the correct length - the simulation skips
83
+ * signature checks, and dummies preserve the exact envelope byte length the bill depends on.
84
+ * Until the estimate service is launched this method returns a standard RPC error; use the
85
+ * Tier-1 estimateNativeFee() with getGasConfig() as the fallback.
86
+ */
87
+ estimateTransaction(txData: string): Promise<EstimateTransactionResult>;
70
88
  getNexus(extended?: boolean): Promise<Nexus>;
71
89
  getContracts(chainAddressOrName?: string, extended?: boolean): Promise<Contract[]>;
72
90
  getContract(chainAddressOrName: string | undefined, contractName: string): Promise<Contract>;
@@ -1 +1 @@
1
- {"version":3,"file":"phantasma.d.ts","sourceRoot":"","sources":["../../../src/rpc/phantasma.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAChG,OAAO,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAC1D,OAAO,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACpD,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