admin: updated dist files

This commit is contained in:
Richard Moore 2024-04-09 21:13:01 -04:00
parent 531ab95b3e
commit 501de23450
110 changed files with 1690 additions and 262 deletions

@ -3,6 +3,15 @@ Change Log
This change log is maintained by `src.ts/_admin/update-changelog.ts` but may also be manually updated. This change log is maintained by `src.ts/_admin/update-changelog.ts` but may also be manually updated.
ethers/v6.12.0 (2024-04-09 21:12)
---------------------------------
- Added Polygon Amoy testnet ([#4645](https://github.com/ethers-io/ethers.js/issues/4645); [1717abb](https://github.com/ethers-io/ethers.js/commit/1717abbf29a14a6f6b106e479fe9a5b1f8768dc4)).
- Added Chainstack provider ([#2741](https://github.com/ethers-io/ethers.js/issues/2741); [014004d](https://github.com/ethers-io/ethers.js/commit/014004d9402d7fd8c15553792cfb7a8a84ed327a)).
- Added deep convertion to Result for toObject and toArray ([#4681](https://github.com/ethers-io/ethers.js/issues/4681); [03bfe2a](https://github.com/ethers-io/ethers.js/commit/03bfe2a4f7b29b15cd90127974b7fc1d8b03edf9)).
- Added EIP-4844 broadcast support ([92bad88](https://github.com/ethers-io/ethers.js/commit/92bad88261a5d8a538535a7d5528162fe5010527)).
- Fix ignored throttle parameters ([#4663](https://github.com/ethers-io/ethers.js/issues/4663); [12772e9](https://github.com/ethers-io/ethers.js/commit/12772e9498b70f8538838f30e16f3792ea90e173)).
ethers/v6.11.1 (2024-02-14 13:13) ethers/v6.11.1 (2024-02-14 13:13)
--------------------------------- ---------------------------------

366
dist/ethers.js vendored

@ -3,7 +3,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
/** /**
* The current version of Ethers. * The current version of Ethers.
*/ */
const version = "6.11.1"; const version = "6.12.0";
/** /**
* Property helper functions. * Property helper functions.
@ -1608,6 +1608,7 @@ class FetchRequest {
clone.#preflight = this.#preflight; clone.#preflight = this.#preflight;
clone.#process = this.#process; clone.#process = this.#process;
clone.#retry = this.#retry; clone.#retry = this.#retry;
clone.#throttle = Object.assign({}, this.#throttle);
clone.#getUrlFunc = this.#getUrlFunc; clone.#getUrlFunc = this.#getUrlFunc;
return clone; return clone;
} }
@ -2737,35 +2738,45 @@ class Result extends Array {
}); });
} }
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray() { toArray(deep) {
const result = []; const result = [];
this.forEach((item, index) => { this.forEach((item, index) => {
if (item instanceof Error) { if (item instanceof Error) {
throwError(`index ${index}`, item); throwError(`index ${index}`, item);
} }
if (deep && item instanceof Result) {
item = item.toArray(deep);
}
result.push(item); result.push(item);
}); });
return result; return result;
} }
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject() { toObject(deep) {
return this.#names.reduce((accum, name, index) => { return this.#names.reduce((accum, name, index) => {
assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", { assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", {
operation: "toObject()" operation: "toObject()"
}); });
// Add values for names that don't conflict // Add values for names that don't conflict
if (!(name in accum)) { if (!(name in accum)) {
accum[name] = this.getValue(name); let child = this.getValue(name);
if (deep && child instanceof Result) {
child = child.toObject(deep);
}
accum[name] = child;
} }
return accum; return accum;
}, {}); }, {});
@ -9623,6 +9634,15 @@ const BN_27 = BigInt(27);
const BN_28 = BigInt(28); const BN_28 = BigInt(28);
const BN_35 = BigInt(35); const BN_35 = BigInt(35);
const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");
const BLOB_SIZE = 4096 * 32;
function getVersionedHash(version, hash) {
let versioned = version.toString(16);
while (versioned.length < 2) {
versioned = "0" + versioned;
}
versioned += sha256(hash).substring(4);
return "0x" + versioned;
}
function handleAddress(value) { function handleAddress(value) {
if (value === "0x") { if (value === "0x") {
return null; return null;
@ -9705,7 +9725,7 @@ function _parseLegacy(data) {
s: zeroPadValue(fields[8], 32), s: zeroPadValue(fields[8], 32),
v v
}); });
tx.hash = keccak256(data); //tx.hash = keccak256(data);
} }
return tx; return tx;
} }
@ -9796,7 +9816,7 @@ function _parseEip1559(data) {
if (fields.length === 9) { if (fields.length === 9) {
return tx; return tx;
} }
tx.hash = keccak256(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(9)); _parseEipSignature(tx, fields.slice(9));
return tx; return tx;
} }
@ -9837,7 +9857,7 @@ function _parseEip2930(data) {
if (fields.length === 8) { if (fields.length === 8) {
return tx; return tx;
} }
tx.hash = keccak256(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(8)); _parseEipSignature(tx, fields.slice(8));
return tx; return tx;
} }
@ -9860,8 +9880,29 @@ function _serializeEip2930(tx, sig) {
return concat(["0x01", encodeRlp(fields)]); return concat(["0x01", encodeRlp(fields)]);
} }
function _parseEip4844(data) { function _parseEip4844(data) {
const fields = decodeRlp(getBytes(data).slice(1)); let fields = decodeRlp(getBytes(data).slice(1));
assertArgument(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), "invalid field count for transaction type: 3", "data", hexlify(data)); let typeName = "3";
let blobs = null;
// Parse the network format
if (fields.length === 4 && Array.isArray(fields[0])) {
typeName = "3 (network format)";
const fBlobs = fields[1], fCommits = fields[2], fProofs = fields[3];
assertArgument(Array.isArray(fBlobs), "invalid network format: blobs not an array", "fields[1]", fBlobs);
assertArgument(Array.isArray(fCommits), "invalid network format: commitments not an array", "fields[2]", fCommits);
assertArgument(Array.isArray(fProofs), "invalid network format: proofs not an array", "fields[3]", fProofs);
assertArgument(fBlobs.length === fCommits.length, "invalid network format: blobs/commitments length mismatch", "fields", fields);
assertArgument(fBlobs.length === fProofs.length, "invalid network format: blobs/proofs length mismatch", "fields", fields);
blobs = [];
for (let i = 0; i < fields[1].length; i++) {
blobs.push({
data: fBlobs[i],
commitment: fCommits[i],
proof: fProofs[i],
});
}
fields = fields[0];
}
assertArgument(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), `invalid field count for transaction type: ${typeName}`, "data", hexlify(data));
const tx = { const tx = {
type: 3, type: 3,
chainId: handleUint(fields[0], "chainId"), chainId: handleUint(fields[0], "chainId"),
@ -9877,7 +9918,10 @@ function _parseEip4844(data) {
maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"), maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"),
blobVersionedHashes: fields[10] blobVersionedHashes: fields[10]
}; };
assertArgument(tx.to != null, "invalid address for transaction type: 3", "data", data); if (blobs) {
tx.blobs = blobs;
}
assertArgument(tx.to != null, `invalid address for transaction type: ${typeName}`, "data", data);
assertArgument(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data); assertArgument(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data);
for (let i = 0; i < tx.blobVersionedHashes.length; i++) { for (let i = 0; i < tx.blobVersionedHashes.length; i++) {
assertArgument(isHexString(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data); assertArgument(isHexString(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data);
@ -9886,11 +9930,13 @@ function _parseEip4844(data) {
if (fields.length === 11) { if (fields.length === 11) {
return tx; return tx;
} }
tx.hash = keccak256(data); // @TODO: Do we need to do this? This is only called internally
// and used to verify hashes; it might save time to not do this
//tx.hash = keccak256(concat([ "0x03", encodeRlp(fields) ]));
_parseEipSignature(tx, fields.slice(11)); _parseEipSignature(tx, fields.slice(11));
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig, blobs) {
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
@ -9908,6 +9954,18 @@ function _serializeEip4844(tx, sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
fields.push(toBeArray(sig.r)); fields.push(toBeArray(sig.r));
fields.push(toBeArray(sig.s)); fields.push(toBeArray(sig.s));
// We have blobs; return the network wrapped format
if (blobs) {
return concat([
"0x03",
encodeRlp([
fields,
blobs.map((b) => b.data),
blobs.map((b) => b.commitment),
blobs.map((b) => b.proof),
])
]);
}
} }
return concat(["0x03", encodeRlp(fields)]); return concat(["0x03", encodeRlp(fields)]);
} }
@ -9939,6 +9997,8 @@ class Transaction {
#accessList; #accessList;
#maxFeePerBlobGas; #maxFeePerBlobGas;
#blobVersionedHashes; #blobVersionedHashes;
#kzg;
#blobs;
/** /**
* The transaction type. * The transaction type.
* *
@ -10120,7 +10180,7 @@ class Transaction {
this.#maxFeePerBlobGas = (value == null) ? null : getBigInt(value, "maxFeePerBlobGas"); this.#maxFeePerBlobGas = (value == null) ? null : getBigInt(value, "maxFeePerBlobGas");
} }
/** /**
* The BLOB versioned hashes for Cancun transactions. * The BLOb versioned hashes for Cancun transactions.
*/ */
get blobVersionedHashes() { get blobVersionedHashes() {
// @TODO: Mutation is inconsistent; if unset, the returned value // @TODO: Mutation is inconsistent; if unset, the returned value
@ -10141,6 +10201,87 @@ class Transaction {
} }
this.#blobVersionedHashes = value; this.#blobVersionedHashes = value;
} }
/**
* The BLObs for the Transaction, if any.
*
* If ``blobs`` is non-``null``, then the [[seriailized]]
* will return the network formatted sidecar, otherwise it
* will return the standard [[link-eip-2718]] payload. The
* [[unsignedSerialized]] is unaffected regardless.
*
* When setting ``blobs``, either fully valid [[Blob]] objects
* may be specified (i.e. correctly padded, with correct
* committments and proofs) or a raw [[BytesLike]] may
* be provided.
*
* If raw [[BytesLike]] are provided, the [[kzg]] property **must**
* be already set. The blob will be correctly padded and the
* [[KzgLibrary]] will be used to compute the committment and
* proof for the blob.
*
* A BLOb is a sequence of field elements, each of which must
* be within the BLS field modulo, so some additional processing
* may be required to encode arbitrary data to ensure each 32 byte
* field is within the valid range.
*
* Setting this automatically populates [[blobVersionedHashes]],
* overwriting any existing values. Setting this to ``null``
* does **not** remove the [[blobVersionedHashes]], leaving them
* present.
*/
get blobs() {
if (this.#blobs == null) {
return null;
}
return this.#blobs.map((b) => Object.assign({}, b));
}
set blobs(_blobs) {
if (_blobs == null) {
this.#blobs = null;
return;
}
const blobs = [];
const versionedHashes = [];
for (let i = 0; i < _blobs.length; i++) {
const blob = _blobs[i];
if (isBytesLike(blob)) {
assert(this.#kzg, "adding a raw blob requires a KZG library", "UNSUPPORTED_OPERATION", {
operation: "set blobs()"
});
let data = getBytes(blob);
assertArgument(data.length <= BLOB_SIZE, "blob is too large", `blobs[${i}]`, blob);
// Pad blob if necessary
if (data.length !== BLOB_SIZE) {
const padded = new Uint8Array(BLOB_SIZE);
padded.set(data);
data = padded;
}
const commit = this.#kzg.blobToKzgCommitment(data);
const proof = hexlify(this.#kzg.computeBlobKzgProof(data, commit));
blobs.push({
data: hexlify(data),
commitment: hexlify(commit),
proof
});
versionedHashes.push(getVersionedHash(1, commit));
}
else {
const commit = hexlify(blob.commitment);
blobs.push({
data: hexlify(blob.data),
commitment: commit,
proof: hexlify(blob.proof)
});
versionedHashes.push(getVersionedHash(1, commit));
}
}
this.#blobs = blobs;
this.#blobVersionedHashes = versionedHashes;
}
get kzg() { return this.#kzg; }
set kzg(kzg) {
this.#kzg = kzg;
}
/** /**
* Creates a new Transaction with default values. * Creates a new Transaction with default values.
*/ */
@ -10159,6 +10300,8 @@ class Transaction {
this.#accessList = null; this.#accessList = null;
this.#maxFeePerBlobGas = null; this.#maxFeePerBlobGas = null;
this.#blobVersionedHashes = null; this.#blobVersionedHashes = null;
this.#blobs = null;
this.#kzg = null;
} }
/** /**
* The transaction hash, if signed. Otherwise, ``null``. * The transaction hash, if signed. Otherwise, ``null``.
@ -10167,7 +10310,7 @@ class Transaction {
if (this.signature == null) { if (this.signature == null) {
return null; return null;
} }
return keccak256(this.serialized); return keccak256(this.#getSerialized(true, false));
} }
/** /**
* The pre-image hash of this transaction. * The pre-image hash of this transaction.
@ -10205,6 +10348,21 @@ class Transaction {
isSigned() { isSigned() {
return this.signature != null; return this.signature != null;
} }
#getSerialized(signed, sidecar) {
assert(!signed || this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
const sig = signed ? this.signature : null;
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, sig);
case 1:
return _serializeEip2930(this, sig);
case 2:
return _serializeEip1559(this, sig);
case 3:
return _serializeEip4844(this, sig, sidecar ? this.blobs : null);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
}
/** /**
* The serialized transaction. * The serialized transaction.
* *
@ -10212,18 +10370,7 @@ class Transaction {
* use [[unsignedSerialized]]. * use [[unsignedSerialized]].
*/ */
get serialized() { get serialized() {
assert(this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" }); return this.#getSerialized(true, true);
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, this.signature);
case 1:
return _serializeEip2930(this, this.signature);
case 2:
return _serializeEip1559(this, this.signature);
case 3:
return _serializeEip4844(this, this.signature);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
} }
/** /**
* The transaction pre-image. * The transaction pre-image.
@ -10232,17 +10379,7 @@ class Transaction {
* authorize this transaction. * authorize this transaction.
*/ */
get unsignedSerialized() { get unsignedSerialized() {
switch (this.inferType()) { return this.#getSerialized(false, false);
case 0:
return _serializeLegacy(this);
case 1:
return _serializeEip2930(this);
case 2:
return _serializeEip1559(this);
case 3:
return _serializeEip4844(this);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".unsignedSerialized" });
} }
/** /**
* Return the most "likely" type; currently the highest * Return the most "likely" type; currently the highest
@ -10442,9 +10579,18 @@ class Transaction {
if (tx.accessList != null) { if (tx.accessList != null) {
result.accessList = tx.accessList; result.accessList = tx.accessList;
} }
// This will get overwritten by blobs, if present
if (tx.blobVersionedHashes != null) { if (tx.blobVersionedHashes != null) {
result.blobVersionedHashes = tx.blobVersionedHashes; result.blobVersionedHashes = tx.blobVersionedHashes;
} }
// Make sure we assign the kzg before assigning blobs, which
// require the library in the event raw blob data is provided.
if (tx.kzg != null) {
result.kzg = tx.kzg;
}
if (tx.blobs != null) {
result.blobs = tx.blobs;
}
if (tx.hash != null) { if (tx.hash != null) {
assertArgument(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx); assertArgument(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx);
assertArgument(result.hash === tx.hash, "hash mismatch", "tx", tx); assertArgument(result.hash === tx.hash, "hash mismatch", "tx", tx);
@ -13840,7 +13986,7 @@ function copyRequest(req) {
if (req.data) { if (req.data) {
result.data = hexlify(req.data); result.data = hexlify(req.data);
} }
const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/); const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerBlobGas,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);
for (const key of bigIntKeys) { for (const key of bigIntKeys) {
if (!(key in req) || req[key] == null) { if (!(key in req) || req[key] == null) {
continue; continue;
@ -13866,6 +14012,20 @@ function copyRequest(req) {
if ("customData" in req) { if ("customData" in req) {
result.customData = req.customData; result.customData = req.customData;
} }
if ("blobVersionedHashes" in req && req.blobVersionedHashes) {
result.blobVersionedHashes = req.blobVersionedHashes.slice();
}
if ("kzg" in req) {
result.kzg = req.kzg;
}
if ("blobs" in req && req.blobs) {
result.blobs = req.blobs.map((b) => {
if (isBytesLike(b)) {
return hexlify(b);
}
return Object.assign({}, b);
});
}
return result; return result;
} }
/** /**
@ -17548,6 +17708,7 @@ function injectCommonNetworks() {
getGasStationPlugin("https:/\/gasstation.polygon.technology/v2") getGasStationPlugin("https:/\/gasstation.polygon.technology/v2")
] ]
}); });
registerEth("matic-amoy", 80002, {});
registerEth("matic-mumbai", 80001, { registerEth("matic-mumbai", 80001, {
altNames: ["maticMumbai", "maticmum"], altNames: ["maticMumbai", "maticmum"],
plugins: [ plugins: [
@ -19366,8 +19527,8 @@ class AbstractSigner {
}); });
} }
} }
else if (pop.type === 2) { else if (pop.type === 2 || pop.type === 3) {
// Explicitly using EIP-1559 // Explicitly using EIP-1559 or EIP-4844
// Populate missing fee data // Populate missing fee data
if (pop.maxFeePerGas == null) { if (pop.maxFeePerGas == null) {
pop.maxFeePerGas = feeData.maxFeePerGas; pop.maxFeePerGas = feeData.maxFeePerGas;
@ -20599,7 +20760,7 @@ function spelunkMessage(value) {
* @_subsection: api/providers/thirdparty:Ankr [providers-ankr] * @_subsection: api/providers/thirdparty:Ankr [providers-ankr]
*/ */
const defaultApiKey$1 = "9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972"; const defaultApiKey$1 = "9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";
function getHost$4(name) { function getHost$5(name) {
switch (name) { switch (name) {
case "mainnet": case "mainnet":
return "rpc.ankr.com/eth"; return "rpc.ankr.com/eth";
@ -20681,7 +20842,7 @@ class AnkrProvider extends JsonRpcProvider {
if (apiKey == null) { if (apiKey == null) {
apiKey = defaultApiKey$1; apiKey = defaultApiKey$1;
} }
const request = new FetchRequest(`https:/\/${getHost$4(network.name)}/${apiKey}`); const request = new FetchRequest(`https:/\/${getHost$5(network.name)}/${apiKey}`);
request.allowGzip = true; request.allowGzip = true;
if (apiKey === defaultApiKey$1) { if (apiKey === defaultApiKey$1) {
request.retryFunc = async (request, response, attempt) => { request.retryFunc = async (request, response, attempt) => {
@ -20723,12 +20884,13 @@ class AnkrProvider extends JsonRpcProvider {
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]
*/ */
const defaultApiKey = "_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC"; const defaultApiKey = "_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";
function getHost$3(name) { function getHost$4(name) {
switch (name) { switch (name) {
case "mainnet": case "mainnet":
return "eth-mainnet.alchemyapi.io"; return "eth-mainnet.alchemyapi.io";
@ -20750,6 +20912,8 @@ function getHost$3(name) {
return "base-sepolia.g.alchemy.com"; return "base-sepolia.g.alchemy.com";
case "matic": case "matic":
return "polygon-mainnet.g.alchemy.com"; return "polygon-mainnet.g.alchemy.com";
case "matic-amoy":
return "polygon-amoy.g.alchemy.com";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.g.alchemy.com"; return "polygon-mumbai.g.alchemy.com";
case "optimism": case "optimism":
@ -20832,7 +20996,7 @@ class AlchemyProvider extends JsonRpcProvider {
if (apiKey == null) { if (apiKey == null) {
apiKey = defaultApiKey; apiKey = defaultApiKey;
} }
const request = new FetchRequest(`https:/\/${getHost$3(network.name)}/v2/${apiKey}`); const request = new FetchRequest(`https:/\/${getHost$4(network.name)}/v2/${apiKey}`);
request.allowGzip = true; request.allowGzip = true;
if (apiKey === defaultApiKey) { if (apiKey === defaultApiKey) {
request.retryFunc = async (request, response, attempt) => { request.retryFunc = async (request, response, attempt) => {
@ -20844,6 +21008,100 @@ class AlchemyProvider extends JsonRpcProvider {
} }
} }
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
function getApiKey(name) {
switch (name) {
case "mainnet": return "39f1d67cedf8b7831010a665328c9197";
case "arbitrum": return "0550c209db33c3abf4cc927e1e18cea1";
case "bnb": return "98b5a77e531614387366f6fc5da097f8";
case "matic": return "cd9d4d70377471aa7c142ec4a4205249";
}
assertArgument(false, "unsupported network", "network", name);
}
function getHost$3(name) {
switch (name) {
case "mainnet":
return "ethereum-mainnet.core.chainstack.com";
case "arbitrum":
return "arbitrum-mainnet.core.chainstack.com";
case "bnb":
return "bsc-mainnet.core.chainstack.com";
case "matic":
return "polygon-mainnet.core.chainstack.com";
}
assertArgument(false, "unsupported network", "network", name);
}
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
class ChainstackProvider extends JsonRpcProvider {
/**
* The API key for the Chainstack connection.
*/
apiKey;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network, apiKey) {
if (_network == null) {
_network = "mainnet";
}
const network = Network.from(_network);
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = ChainstackProvider.getRequest(network, apiKey);
super(request, network, { staticNetwork: network });
defineProperties(this, { apiKey });
}
_getProvider(chainId) {
try {
return new ChainstackProvider(chainId, this.apiKey);
}
catch (error) { }
return super._getProvider(chainId);
}
isCommunityResource() {
return (this.apiKey === getApiKey(this._network.name));
}
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network, apiKey) {
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = new FetchRequest(`https:/\/${getHost$3(network.name)}/${apiKey}`);
request.allowGzip = true;
if (apiKey === getApiKey(network.name)) {
request.retryFunc = async (request, response, attempt) => {
showThrottleMessage("ChainstackProvider");
return true;
};
}
return request;
}
}
/** /**
* About Cloudflare * About Cloudflare
* *
@ -21767,6 +22025,7 @@ class WebSocketProvider extends SocketProvider {
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]
@ -21802,6 +22061,8 @@ function getHost$2(name) {
return "linea-goerli.infura.io"; return "linea-goerli.infura.io";
case "matic": case "matic":
return "polygon-mainnet.infura.io"; return "polygon-mainnet.infura.io";
case "matic-amoy":
return "polygon-amoy.infura.io";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.infura.io"; return "polygon-mumbai.infura.io";
case "optimism": case "optimism":
@ -22723,6 +22984,7 @@ const Testnets = "goerli kovan sepolia classicKotti optimism-goerli arbitrum-goe
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``
@ -22776,6 +23038,9 @@ function getDefaultProvider(network, options) {
if (staticNetwork.name === "matic") { if (staticNetwork.name === "matic") {
providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork })); providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork }));
} }
else if (staticNetwork.name === "matic-amoy") {
providers.push(new JsonRpcProvider("https:/\/rpc-amoy.polygon.technology/", staticNetwork, { staticNetwork }));
}
} }
if (allowService("alchemy")) { if (allowService("alchemy")) {
try { try {
@ -22789,6 +23054,12 @@ function getDefaultProvider(network, options) {
} }
catch (error) { } catch (error) { }
} }
if (allowService("chainstack")) {
try {
providers.push(new ChainstackProvider(network, options.chainstack));
}
catch (error) { }
}
if (allowService("cloudflare")) { if (allowService("cloudflare")) {
try { try {
providers.push(new CloudflareProvider(network)); providers.push(new CloudflareProvider(network));
@ -25152,6 +25423,7 @@ var ethers = /*#__PURE__*/Object.freeze({
BaseWallet: BaseWallet, BaseWallet: BaseWallet,
Block: Block, Block: Block,
BrowserProvider: BrowserProvider, BrowserProvider: BrowserProvider,
ChainstackProvider: ChainstackProvider,
CloudflareProvider: CloudflareProvider, CloudflareProvider: CloudflareProvider,
ConstructorFragment: ConstructorFragment, ConstructorFragment: ConstructorFragment,
Contract: Contract, Contract: Contract,
@ -25333,5 +25605,5 @@ var ethers = /*#__PURE__*/Object.freeze({
zeroPadValue: zeroPadValue zeroPadValue: zeroPadValue
}); });
export { AbiCoder, AbstractProvider, AbstractSigner, AlchemyProvider, AnkrProvider, BaseContract, BaseWallet, Block, BrowserProvider, CloudflareProvider, ConstructorFragment, Contract, ContractEventPayload, ContractFactory, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EnsPlugin, EnsResolver, ErrorDescription, ErrorFragment, EtherSymbol, EtherscanPlugin, EtherscanProvider, EventFragment, EventLog, EventPayload, FallbackFragment, FallbackProvider, FeeData, FeeDataNetworkPlugin, FetchCancelSignal, FetchRequest, FetchResponse, FetchUrlFeeDataNetworkPlugin, FixedNumber, Fragment, FunctionFragment, GasCostPlugin, HDNodeVoidWallet, HDNodeWallet, Indexed, InfuraProvider, InfuraWebSocketProvider, Interface, IpcSocketProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, LangEn, Log, LogDescription, MaxInt256, MaxUint256, MessagePrefix, MinInt256, Mnemonic, MulticoinProviderPlugin, N$1 as N, NamedFragment, Network, NetworkPlugin, NonceManager, ParamType, PocketProvider, QuickNodeProvider, Result, Signature, SigningKey, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketProvider, SocketSubscriber, StructFragment, Transaction, TransactionDescription, TransactionReceipt, TransactionResponse, Typed, TypedDataEncoder, UndecodedEventLog, UnmanagedSubscriber, Utf8ErrorFuncs, VoidSigner, Wallet, WebSocketProvider, WeiPerEther, Wordlist, WordlistOwl, WordlistOwlA, ZeroAddress, ZeroHash, accessListify, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, checkResultErrors, computeAddress, computeHmac, concat, copyRequest, dataLength, dataSlice, decodeBase58, decodeBase64, decodeBytes32String, decodeRlp, decryptCrowdsaleJson, decryptKeystoreJson, decryptKeystoreJsonSync, defaultPath, defineProperties, dnsEncode, encodeBase58, encodeBase64, encodeBytes32String, encodeRlp, encryptKeystoreJson, encryptKeystoreJsonSync, ensNormalize, ethers, formatEther, formatUnits, fromTwos, getAccountPath, getAddress, getBigInt, getBytes, getBytesCopy, getCreate2Address, getCreateAddress, getDefaultProvider, getIcapAddress, getIndexedAccountPath, getNumber, getUint, hashMessage, hexlify, id, isAddress, isAddressable, isBytesLike, isCallException, isCrowdsaleJson, isError, isHexString, isKeystoreJson, isValidName, keccak256, lock, makeError, mask, namehash, parseEther, parseUnits$1 as parseUnits, pbkdf2, randomBytes, recoverAddress, resolveAddress, resolveProperties, ripemd160, scrypt, scryptSync, sha256, sha512, showThrottleMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, stripZerosLeft, toBeArray, toBeHex, toBigInt, toNumber, toQuantity, toTwos, toUtf8Bytes, toUtf8CodePoints, toUtf8String, uuidV4, verifyMessage, verifyTypedData, version, wordlists, zeroPadBytes, zeroPadValue }; export { AbiCoder, AbstractProvider, AbstractSigner, AlchemyProvider, AnkrProvider, BaseContract, BaseWallet, Block, BrowserProvider, ChainstackProvider, CloudflareProvider, ConstructorFragment, Contract, ContractEventPayload, ContractFactory, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EnsPlugin, EnsResolver, ErrorDescription, ErrorFragment, EtherSymbol, EtherscanPlugin, EtherscanProvider, EventFragment, EventLog, EventPayload, FallbackFragment, FallbackProvider, FeeData, FeeDataNetworkPlugin, FetchCancelSignal, FetchRequest, FetchResponse, FetchUrlFeeDataNetworkPlugin, FixedNumber, Fragment, FunctionFragment, GasCostPlugin, HDNodeVoidWallet, HDNodeWallet, Indexed, InfuraProvider, InfuraWebSocketProvider, Interface, IpcSocketProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, LangEn, Log, LogDescription, MaxInt256, MaxUint256, MessagePrefix, MinInt256, Mnemonic, MulticoinProviderPlugin, N$1 as N, NamedFragment, Network, NetworkPlugin, NonceManager, ParamType, PocketProvider, QuickNodeProvider, Result, Signature, SigningKey, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketProvider, SocketSubscriber, StructFragment, Transaction, TransactionDescription, TransactionReceipt, TransactionResponse, Typed, TypedDataEncoder, UndecodedEventLog, UnmanagedSubscriber, Utf8ErrorFuncs, VoidSigner, Wallet, WebSocketProvider, WeiPerEther, Wordlist, WordlistOwl, WordlistOwlA, ZeroAddress, ZeroHash, accessListify, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, checkResultErrors, computeAddress, computeHmac, concat, copyRequest, dataLength, dataSlice, decodeBase58, decodeBase64, decodeBytes32String, decodeRlp, decryptCrowdsaleJson, decryptKeystoreJson, decryptKeystoreJsonSync, defaultPath, defineProperties, dnsEncode, encodeBase58, encodeBase64, encodeBytes32String, encodeRlp, encryptKeystoreJson, encryptKeystoreJsonSync, ensNormalize, ethers, formatEther, formatUnits, fromTwos, getAccountPath, getAddress, getBigInt, getBytes, getBytesCopy, getCreate2Address, getCreateAddress, getDefaultProvider, getIcapAddress, getIndexedAccountPath, getNumber, getUint, hashMessage, hexlify, id, isAddress, isAddressable, isBytesLike, isCallException, isCrowdsaleJson, isError, isHexString, isKeystoreJson, isValidName, keccak256, lock, makeError, mask, namehash, parseEther, parseUnits$1 as parseUnits, pbkdf2, randomBytes, recoverAddress, resolveAddress, resolveProperties, ripemd160, scrypt, scryptSync, sha256, sha512, showThrottleMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, stripZerosLeft, toBeArray, toBeHex, toBigInt, toNumber, toQuantity, toTwos, toUtf8Bytes, toUtf8CodePoints, toUtf8String, uuidV4, verifyMessage, verifyTypedData, version, wordlists, zeroPadBytes, zeroPadValue };
//# sourceMappingURL=ethers.js.map //# sourceMappingURL=ethers.js.map

2
dist/ethers.js.map vendored

File diff suppressed because one or more lines are too long

2
dist/ethers.min.js vendored

File diff suppressed because one or more lines are too long

365
dist/ethers.umd.js vendored

@ -9,7 +9,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
/** /**
* The current version of Ethers. * The current version of Ethers.
*/ */
const version = "6.11.1"; const version = "6.12.0";
/** /**
* Property helper functions. * Property helper functions.
@ -1614,6 +1614,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
clone.#preflight = this.#preflight; clone.#preflight = this.#preflight;
clone.#process = this.#process; clone.#process = this.#process;
clone.#retry = this.#retry; clone.#retry = this.#retry;
clone.#throttle = Object.assign({}, this.#throttle);
clone.#getUrlFunc = this.#getUrlFunc; clone.#getUrlFunc = this.#getUrlFunc;
return clone; return clone;
} }
@ -2743,35 +2744,45 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
}); });
} }
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray() { toArray(deep) {
const result = []; const result = [];
this.forEach((item, index) => { this.forEach((item, index) => {
if (item instanceof Error) { if (item instanceof Error) {
throwError(`index ${index}`, item); throwError(`index ${index}`, item);
} }
if (deep && item instanceof Result) {
item = item.toArray(deep);
}
result.push(item); result.push(item);
}); });
return result; return result;
} }
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject() { toObject(deep) {
return this.#names.reduce((accum, name, index) => { return this.#names.reduce((accum, name, index) => {
assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", { assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", {
operation: "toObject()" operation: "toObject()"
}); });
// Add values for names that don't conflict // Add values for names that don't conflict
if (!(name in accum)) { if (!(name in accum)) {
accum[name] = this.getValue(name); let child = this.getValue(name);
if (deep && child instanceof Result) {
child = child.toObject(deep);
}
accum[name] = child;
} }
return accum; return accum;
}, {}); }, {});
@ -9629,6 +9640,15 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
const BN_28 = BigInt(28); const BN_28 = BigInt(28);
const BN_35 = BigInt(35); const BN_35 = BigInt(35);
const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");
const BLOB_SIZE = 4096 * 32;
function getVersionedHash(version, hash) {
let versioned = version.toString(16);
while (versioned.length < 2) {
versioned = "0" + versioned;
}
versioned += sha256(hash).substring(4);
return "0x" + versioned;
}
function handleAddress(value) { function handleAddress(value) {
if (value === "0x") { if (value === "0x") {
return null; return null;
@ -9711,7 +9731,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
s: zeroPadValue(fields[8], 32), s: zeroPadValue(fields[8], 32),
v v
}); });
tx.hash = keccak256(data); //tx.hash = keccak256(data);
} }
return tx; return tx;
} }
@ -9802,7 +9822,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (fields.length === 9) { if (fields.length === 9) {
return tx; return tx;
} }
tx.hash = keccak256(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(9)); _parseEipSignature(tx, fields.slice(9));
return tx; return tx;
} }
@ -9843,7 +9863,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (fields.length === 8) { if (fields.length === 8) {
return tx; return tx;
} }
tx.hash = keccak256(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(8)); _parseEipSignature(tx, fields.slice(8));
return tx; return tx;
} }
@ -9866,8 +9886,29 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return concat(["0x01", encodeRlp(fields)]); return concat(["0x01", encodeRlp(fields)]);
} }
function _parseEip4844(data) { function _parseEip4844(data) {
const fields = decodeRlp(getBytes(data).slice(1)); let fields = decodeRlp(getBytes(data).slice(1));
assertArgument(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), "invalid field count for transaction type: 3", "data", hexlify(data)); let typeName = "3";
let blobs = null;
// Parse the network format
if (fields.length === 4 && Array.isArray(fields[0])) {
typeName = "3 (network format)";
const fBlobs = fields[1], fCommits = fields[2], fProofs = fields[3];
assertArgument(Array.isArray(fBlobs), "invalid network format: blobs not an array", "fields[1]", fBlobs);
assertArgument(Array.isArray(fCommits), "invalid network format: commitments not an array", "fields[2]", fCommits);
assertArgument(Array.isArray(fProofs), "invalid network format: proofs not an array", "fields[3]", fProofs);
assertArgument(fBlobs.length === fCommits.length, "invalid network format: blobs/commitments length mismatch", "fields", fields);
assertArgument(fBlobs.length === fProofs.length, "invalid network format: blobs/proofs length mismatch", "fields", fields);
blobs = [];
for (let i = 0; i < fields[1].length; i++) {
blobs.push({
data: fBlobs[i],
commitment: fCommits[i],
proof: fProofs[i],
});
}
fields = fields[0];
}
assertArgument(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), `invalid field count for transaction type: ${typeName}`, "data", hexlify(data));
const tx = { const tx = {
type: 3, type: 3,
chainId: handleUint(fields[0], "chainId"), chainId: handleUint(fields[0], "chainId"),
@ -9883,7 +9924,10 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"), maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"),
blobVersionedHashes: fields[10] blobVersionedHashes: fields[10]
}; };
assertArgument(tx.to != null, "invalid address for transaction type: 3", "data", data); if (blobs) {
tx.blobs = blobs;
}
assertArgument(tx.to != null, `invalid address for transaction type: ${typeName}`, "data", data);
assertArgument(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data); assertArgument(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data);
for (let i = 0; i < tx.blobVersionedHashes.length; i++) { for (let i = 0; i < tx.blobVersionedHashes.length; i++) {
assertArgument(isHexString(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data); assertArgument(isHexString(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data);
@ -9892,11 +9936,13 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (fields.length === 11) { if (fields.length === 11) {
return tx; return tx;
} }
tx.hash = keccak256(data); // @TODO: Do we need to do this? This is only called internally
// and used to verify hashes; it might save time to not do this
//tx.hash = keccak256(concat([ "0x03", encodeRlp(fields) ]));
_parseEipSignature(tx, fields.slice(11)); _parseEipSignature(tx, fields.slice(11));
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig, blobs) {
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
@ -9914,6 +9960,18 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
fields.push(toBeArray(sig.r)); fields.push(toBeArray(sig.r));
fields.push(toBeArray(sig.s)); fields.push(toBeArray(sig.s));
// We have blobs; return the network wrapped format
if (blobs) {
return concat([
"0x03",
encodeRlp([
fields,
blobs.map((b) => b.data),
blobs.map((b) => b.commitment),
blobs.map((b) => b.proof),
])
]);
}
} }
return concat(["0x03", encodeRlp(fields)]); return concat(["0x03", encodeRlp(fields)]);
} }
@ -9945,6 +10003,8 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
#accessList; #accessList;
#maxFeePerBlobGas; #maxFeePerBlobGas;
#blobVersionedHashes; #blobVersionedHashes;
#kzg;
#blobs;
/** /**
* The transaction type. * The transaction type.
* *
@ -10126,7 +10186,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
this.#maxFeePerBlobGas = (value == null) ? null : getBigInt(value, "maxFeePerBlobGas"); this.#maxFeePerBlobGas = (value == null) ? null : getBigInt(value, "maxFeePerBlobGas");
} }
/** /**
* The BLOB versioned hashes for Cancun transactions. * The BLOb versioned hashes for Cancun transactions.
*/ */
get blobVersionedHashes() { get blobVersionedHashes() {
// @TODO: Mutation is inconsistent; if unset, the returned value // @TODO: Mutation is inconsistent; if unset, the returned value
@ -10147,6 +10207,87 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
} }
this.#blobVersionedHashes = value; this.#blobVersionedHashes = value;
} }
/**
* The BLObs for the Transaction, if any.
*
* If ``blobs`` is non-``null``, then the [[seriailized]]
* will return the network formatted sidecar, otherwise it
* will return the standard [[link-eip-2718]] payload. The
* [[unsignedSerialized]] is unaffected regardless.
*
* When setting ``blobs``, either fully valid [[Blob]] objects
* may be specified (i.e. correctly padded, with correct
* committments and proofs) or a raw [[BytesLike]] may
* be provided.
*
* If raw [[BytesLike]] are provided, the [[kzg]] property **must**
* be already set. The blob will be correctly padded and the
* [[KzgLibrary]] will be used to compute the committment and
* proof for the blob.
*
* A BLOb is a sequence of field elements, each of which must
* be within the BLS field modulo, so some additional processing
* may be required to encode arbitrary data to ensure each 32 byte
* field is within the valid range.
*
* Setting this automatically populates [[blobVersionedHashes]],
* overwriting any existing values. Setting this to ``null``
* does **not** remove the [[blobVersionedHashes]], leaving them
* present.
*/
get blobs() {
if (this.#blobs == null) {
return null;
}
return this.#blobs.map((b) => Object.assign({}, b));
}
set blobs(_blobs) {
if (_blobs == null) {
this.#blobs = null;
return;
}
const blobs = [];
const versionedHashes = [];
for (let i = 0; i < _blobs.length; i++) {
const blob = _blobs[i];
if (isBytesLike(blob)) {
assert(this.#kzg, "adding a raw blob requires a KZG library", "UNSUPPORTED_OPERATION", {
operation: "set blobs()"
});
let data = getBytes(blob);
assertArgument(data.length <= BLOB_SIZE, "blob is too large", `blobs[${i}]`, blob);
// Pad blob if necessary
if (data.length !== BLOB_SIZE) {
const padded = new Uint8Array(BLOB_SIZE);
padded.set(data);
data = padded;
}
const commit = this.#kzg.blobToKzgCommitment(data);
const proof = hexlify(this.#kzg.computeBlobKzgProof(data, commit));
blobs.push({
data: hexlify(data),
commitment: hexlify(commit),
proof
});
versionedHashes.push(getVersionedHash(1, commit));
}
else {
const commit = hexlify(blob.commitment);
blobs.push({
data: hexlify(blob.data),
commitment: commit,
proof: hexlify(blob.proof)
});
versionedHashes.push(getVersionedHash(1, commit));
}
}
this.#blobs = blobs;
this.#blobVersionedHashes = versionedHashes;
}
get kzg() { return this.#kzg; }
set kzg(kzg) {
this.#kzg = kzg;
}
/** /**
* Creates a new Transaction with default values. * Creates a new Transaction with default values.
*/ */
@ -10165,6 +10306,8 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
this.#accessList = null; this.#accessList = null;
this.#maxFeePerBlobGas = null; this.#maxFeePerBlobGas = null;
this.#blobVersionedHashes = null; this.#blobVersionedHashes = null;
this.#blobs = null;
this.#kzg = null;
} }
/** /**
* The transaction hash, if signed. Otherwise, ``null``. * The transaction hash, if signed. Otherwise, ``null``.
@ -10173,7 +10316,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (this.signature == null) { if (this.signature == null) {
return null; return null;
} }
return keccak256(this.serialized); return keccak256(this.#getSerialized(true, false));
} }
/** /**
* The pre-image hash of this transaction. * The pre-image hash of this transaction.
@ -10211,6 +10354,21 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
isSigned() { isSigned() {
return this.signature != null; return this.signature != null;
} }
#getSerialized(signed, sidecar) {
assert(!signed || this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
const sig = signed ? this.signature : null;
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, sig);
case 1:
return _serializeEip2930(this, sig);
case 2:
return _serializeEip1559(this, sig);
case 3:
return _serializeEip4844(this, sig, sidecar ? this.blobs : null);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
}
/** /**
* The serialized transaction. * The serialized transaction.
* *
@ -10218,18 +10376,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* use [[unsignedSerialized]]. * use [[unsignedSerialized]].
*/ */
get serialized() { get serialized() {
assert(this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" }); return this.#getSerialized(true, true);
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, this.signature);
case 1:
return _serializeEip2930(this, this.signature);
case 2:
return _serializeEip1559(this, this.signature);
case 3:
return _serializeEip4844(this, this.signature);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
} }
/** /**
* The transaction pre-image. * The transaction pre-image.
@ -10238,17 +10385,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* authorize this transaction. * authorize this transaction.
*/ */
get unsignedSerialized() { get unsignedSerialized() {
switch (this.inferType()) { return this.#getSerialized(false, false);
case 0:
return _serializeLegacy(this);
case 1:
return _serializeEip2930(this);
case 2:
return _serializeEip1559(this);
case 3:
return _serializeEip4844(this);
}
assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".unsignedSerialized" });
} }
/** /**
* Return the most "likely" type; currently the highest * Return the most "likely" type; currently the highest
@ -10448,9 +10585,18 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (tx.accessList != null) { if (tx.accessList != null) {
result.accessList = tx.accessList; result.accessList = tx.accessList;
} }
// This will get overwritten by blobs, if present
if (tx.blobVersionedHashes != null) { if (tx.blobVersionedHashes != null) {
result.blobVersionedHashes = tx.blobVersionedHashes; result.blobVersionedHashes = tx.blobVersionedHashes;
} }
// Make sure we assign the kzg before assigning blobs, which
// require the library in the event raw blob data is provided.
if (tx.kzg != null) {
result.kzg = tx.kzg;
}
if (tx.blobs != null) {
result.blobs = tx.blobs;
}
if (tx.hash != null) { if (tx.hash != null) {
assertArgument(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx); assertArgument(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx);
assertArgument(result.hash === tx.hash, "hash mismatch", "tx", tx); assertArgument(result.hash === tx.hash, "hash mismatch", "tx", tx);
@ -13846,7 +13992,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (req.data) { if (req.data) {
result.data = hexlify(req.data); result.data = hexlify(req.data);
} }
const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/); const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerBlobGas,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);
for (const key of bigIntKeys) { for (const key of bigIntKeys) {
if (!(key in req) || req[key] == null) { if (!(key in req) || req[key] == null) {
continue; continue;
@ -13872,6 +14018,20 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if ("customData" in req) { if ("customData" in req) {
result.customData = req.customData; result.customData = req.customData;
} }
if ("blobVersionedHashes" in req && req.blobVersionedHashes) {
result.blobVersionedHashes = req.blobVersionedHashes.slice();
}
if ("kzg" in req) {
result.kzg = req.kzg;
}
if ("blobs" in req && req.blobs) {
result.blobs = req.blobs.map((b) => {
if (isBytesLike(b)) {
return hexlify(b);
}
return Object.assign({}, b);
});
}
return result; return result;
} }
/** /**
@ -17554,6 +17714,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
getGasStationPlugin("https:/\/gasstation.polygon.technology/v2") getGasStationPlugin("https:/\/gasstation.polygon.technology/v2")
] ]
}); });
registerEth("matic-amoy", 80002, {});
registerEth("matic-mumbai", 80001, { registerEth("matic-mumbai", 80001, {
altNames: ["maticMumbai", "maticmum"], altNames: ["maticMumbai", "maticmum"],
plugins: [ plugins: [
@ -19372,8 +19533,8 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
}); });
} }
} }
else if (pop.type === 2) { else if (pop.type === 2 || pop.type === 3) {
// Explicitly using EIP-1559 // Explicitly using EIP-1559 or EIP-4844
// Populate missing fee data // Populate missing fee data
if (pop.maxFeePerGas == null) { if (pop.maxFeePerGas == null) {
pop.maxFeePerGas = feeData.maxFeePerGas; pop.maxFeePerGas = feeData.maxFeePerGas;
@ -20605,7 +20766,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* @_subsection: api/providers/thirdparty:Ankr [providers-ankr] * @_subsection: api/providers/thirdparty:Ankr [providers-ankr]
*/ */
const defaultApiKey$1 = "9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972"; const defaultApiKey$1 = "9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";
function getHost$4(name) { function getHost$5(name) {
switch (name) { switch (name) {
case "mainnet": case "mainnet":
return "rpc.ankr.com/eth"; return "rpc.ankr.com/eth";
@ -20687,7 +20848,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (apiKey == null) { if (apiKey == null) {
apiKey = defaultApiKey$1; apiKey = defaultApiKey$1;
} }
const request = new FetchRequest(`https:/\/${getHost$4(network.name)}/${apiKey}`); const request = new FetchRequest(`https:/\/${getHost$5(network.name)}/${apiKey}`);
request.allowGzip = true; request.allowGzip = true;
if (apiKey === defaultApiKey$1) { if (apiKey === defaultApiKey$1) {
request.retryFunc = async (request, response, attempt) => { request.retryFunc = async (request, response, attempt) => {
@ -20729,12 +20890,13 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]
*/ */
const defaultApiKey = "_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC"; const defaultApiKey = "_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";
function getHost$3(name) { function getHost$4(name) {
switch (name) { switch (name) {
case "mainnet": case "mainnet":
return "eth-mainnet.alchemyapi.io"; return "eth-mainnet.alchemyapi.io";
@ -20756,6 +20918,8 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return "base-sepolia.g.alchemy.com"; return "base-sepolia.g.alchemy.com";
case "matic": case "matic":
return "polygon-mainnet.g.alchemy.com"; return "polygon-mainnet.g.alchemy.com";
case "matic-amoy":
return "polygon-amoy.g.alchemy.com";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.g.alchemy.com"; return "polygon-mumbai.g.alchemy.com";
case "optimism": case "optimism":
@ -20838,7 +21002,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (apiKey == null) { if (apiKey == null) {
apiKey = defaultApiKey; apiKey = defaultApiKey;
} }
const request = new FetchRequest(`https:/\/${getHost$3(network.name)}/v2/${apiKey}`); const request = new FetchRequest(`https:/\/${getHost$4(network.name)}/v2/${apiKey}`);
request.allowGzip = true; request.allowGzip = true;
if (apiKey === defaultApiKey) { if (apiKey === defaultApiKey) {
request.retryFunc = async (request, response, attempt) => { request.retryFunc = async (request, response, attempt) => {
@ -20850,6 +21014,100 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
} }
} }
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
function getApiKey(name) {
switch (name) {
case "mainnet": return "39f1d67cedf8b7831010a665328c9197";
case "arbitrum": return "0550c209db33c3abf4cc927e1e18cea1";
case "bnb": return "98b5a77e531614387366f6fc5da097f8";
case "matic": return "cd9d4d70377471aa7c142ec4a4205249";
}
assertArgument(false, "unsupported network", "network", name);
}
function getHost$3(name) {
switch (name) {
case "mainnet":
return "ethereum-mainnet.core.chainstack.com";
case "arbitrum":
return "arbitrum-mainnet.core.chainstack.com";
case "bnb":
return "bsc-mainnet.core.chainstack.com";
case "matic":
return "polygon-mainnet.core.chainstack.com";
}
assertArgument(false, "unsupported network", "network", name);
}
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
class ChainstackProvider extends JsonRpcProvider {
/**
* The API key for the Chainstack connection.
*/
apiKey;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network, apiKey) {
if (_network == null) {
_network = "mainnet";
}
const network = Network.from(_network);
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = ChainstackProvider.getRequest(network, apiKey);
super(request, network, { staticNetwork: network });
defineProperties(this, { apiKey });
}
_getProvider(chainId) {
try {
return new ChainstackProvider(chainId, this.apiKey);
}
catch (error) { }
return super._getProvider(chainId);
}
isCommunityResource() {
return (this.apiKey === getApiKey(this._network.name));
}
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network, apiKey) {
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = new FetchRequest(`https:/\/${getHost$3(network.name)}/${apiKey}`);
request.allowGzip = true;
if (apiKey === getApiKey(network.name)) {
request.retryFunc = async (request, response, attempt) => {
showThrottleMessage("ChainstackProvider");
return true;
};
}
return request;
}
}
/** /**
* About Cloudflare * About Cloudflare
* *
@ -21773,6 +22031,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]
@ -21808,6 +22067,8 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return "linea-goerli.infura.io"; return "linea-goerli.infura.io";
case "matic": case "matic":
return "polygon-mainnet.infura.io"; return "polygon-mainnet.infura.io";
case "matic-amoy":
return "polygon-amoy.infura.io";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.infura.io"; return "polygon-mumbai.infura.io";
case "optimism": case "optimism":
@ -22729,6 +22990,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``
@ -22782,6 +23044,9 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
if (staticNetwork.name === "matic") { if (staticNetwork.name === "matic") {
providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork })); providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork }));
} }
else if (staticNetwork.name === "matic-amoy") {
providers.push(new JsonRpcProvider("https:/\/rpc-amoy.polygon.technology/", staticNetwork, { staticNetwork }));
}
} }
if (allowService("alchemy")) { if (allowService("alchemy")) {
try { try {
@ -22795,6 +23060,12 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
} }
catch (error) { } catch (error) { }
} }
if (allowService("chainstack")) {
try {
providers.push(new ChainstackProvider(network, options.chainstack));
}
catch (error) { }
}
if (allowService("cloudflare")) { if (allowService("cloudflare")) {
try { try {
providers.push(new CloudflareProvider(network)); providers.push(new CloudflareProvider(network));
@ -25158,6 +25429,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
BaseWallet: BaseWallet, BaseWallet: BaseWallet,
Block: Block, Block: Block,
BrowserProvider: BrowserProvider, BrowserProvider: BrowserProvider,
ChainstackProvider: ChainstackProvider,
CloudflareProvider: CloudflareProvider, CloudflareProvider: CloudflareProvider,
ConstructorFragment: ConstructorFragment, ConstructorFragment: ConstructorFragment,
Contract: Contract, Contract: Contract,
@ -25348,6 +25620,7 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
exports.BaseWallet = BaseWallet; exports.BaseWallet = BaseWallet;
exports.Block = Block; exports.Block = Block;
exports.BrowserProvider = BrowserProvider; exports.BrowserProvider = BrowserProvider;
exports.ChainstackProvider = ChainstackProvider;
exports.CloudflareProvider = CloudflareProvider; exports.CloudflareProvider = CloudflareProvider;
exports.ConstructorFragment = ConstructorFragment; exports.ConstructorFragment = ConstructorFragment;
exports.Contract = Contract; exports.Contract = Contract;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -100,7 +100,7 @@ const rotlBL = (h, l, s) => (h << (s - 32)) | (l >>> (64 - s));
/** /**
* The current version of Ethers. * The current version of Ethers.
*/ */
const version = "6.11.1"; const version = "6.12.0";
/** /**
* Property helper functions. * Property helper functions.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"version":3,"file":"create-provider.d.ts","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AA2FpD,wBAAgB,cAAc,IAAI,IAAI,CAKrC;AAED,eAAO,MAAM,aAAa,mBAAuD,CAAC;AAQlF,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAInE;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,gBAAgB,CAgBtF;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAGxE;AAED,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,CAIzD"} {"version":3,"file":"create-provider.d.ts","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAkGpD,wBAAgB,cAAc,IAAI,IAAI,CAKrC;AAED,eAAO,MAAM,aAAa,mBAAuD,CAAC;AAQlF,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAInE;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,gBAAgB,CAgBtF;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAGxE;AAED,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,CAIzD"}

@ -31,6 +31,13 @@ const ProviderCreators = [
} }
}, },
*/ */
{
name: "ChainstackProvider",
networks: ["default", "mainnet", "arbitrum", "bnb", "matic"],
create: function (network) {
return new index_js_1.ChainstackProvider(network);
}
},
{ {
name: "EtherscanProvider", name: "EtherscanProvider",
networks: ethNetworks, networks: ethNetworks,
@ -137,7 +144,7 @@ function getProvider(provider, network) {
exports.getProvider = getProvider; exports.getProvider = getProvider;
function checkProvider(provider, network) { function checkProvider(provider, network) {
const creator = getCreator(provider); const creator = getCreator(provider);
return (creator != null); return (creator != null && creator.networks.indexOf(network) >= 0);
} }
exports.checkProvider = checkProvider; exports.checkProvider = checkProvider;
function connect(network) { function connect(network) {

@ -1 +1 @@
{"version":3,"file":"create-provider.js","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":";;;AAAA,0CAWqB;AAQpB,CAAC;AAEF,MAAM,WAAW,GAAG,CAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,CAAE,CAAC;AACvD,gDAAgD;AAEhD,MAAM,gBAAgB,GAA2B;IAC7C;QACI,IAAI,EAAE,iBAAiB;QACvB,QAAQ,EAAE,WAAW;QACrB,MAAM,EAAE,UAAS,OAAe;YAC5B,OAAO,IAAI,0BAAe,CAAC,OAAO,EAAE,kCAAkC,CAAC,CAAC;QAC5E,CAAC;KACJ;IACD;;;;;;;;MAQE;IACF;;;;;;;;MAQE;IACF;QACI,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AAK,EAAE;QAAE,MAAM,IAAI,KAAK,CAAC,0CAA0C,CAAC,CAAC;KAAE;IAEpF,MAAM,OAAO,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAC;IACrC,IAAI;QACA,IAAI,OAAO,EAAE;YACT,MAAM,QAAQ,GAAG,OAAO,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YACzC,IAAI,QAAQ,EAAE;gBACV,OAAO,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,QAAQ,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;aAC/C;YACD,OAAO,QAAQ,CAAC;SACnB;KACJ;IAAC,OAAO,KAAK,EAAE;QACZ,IAAI,CAAC,IAAA,kBAAO,EAAC,KAAK,EAAE,kBAAkB,CAAC,EAAE;YAAE,MAAM,KAAK,CAAC;SAAE;KAC5D;IACD,OAAO,IAAI,CAAC;AAChB,CAAC;AAhBD,kCAgBC;AAED,SAAgB,aAAa,CAAC,QAAgB,EAAE,OAAe;IAC3D,MAAM,OAAO,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAC;IACrC,OAAO,CAAC,OAAO,IAAI,IAAI,IAAI,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;AACvE,CAAC;AAHD,sCAGC;AAED,SAAgB,OAAO,CAAC,OAAe;IACnC,MAAM,QAAQ,GAAG,WAAW,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACxD,IAAI,QAAQ,IAAI,IAAI,EAAE;QAAE,MAAM,IAAI,KAAK,CAAC,wBAAyB,OAAQ,EAAE,CAAC,CAAC;KAAE;IAC/E,OAAO,QAAQ,CAAC;AACpB,CAAC;AAJD,0BAIC"}

@ -5,5 +5,5 @@ exports.version = void 0;
/** /**
* The current version of Ethers. * The current version of Ethers.
*/ */
exports.version = "6.11.1"; exports.version = "6.12.0";
//# sourceMappingURL=_version.js.map //# sourceMappingURL=_version.js.map

@ -18,19 +18,22 @@ export declare class Result extends Array<any> {
*/ */
constructor(...args: Array<any>); constructor(...args: Array<any>);
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray(): Array<any>; toArray(deep?: boolean): Array<any>;
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject(): Record<string, any>; toObject(deep?: boolean): Record<string, any>;
/** /**
* @_ignore * @_ignore
*/ */

@ -1 +1 @@
{"version":3,"file":"abstract-coder.d.ts","sourceRoot":"","sources":["../../../src.ts/abi/coders/abstract-coder.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEpE;;GAEG;AACH,eAAO,MAAM,QAAQ,EAAE,MAAW,CAAC;AAenC;;;;;;GAMG;AACH,qBAAa,MAAO,SAAQ,KAAK,CAAC,GAAG,CAAC;;IAGlC,CAAE,CAAC,EAAE,MAAM,GAAG,MAAM,GAAI,GAAG,CAAA;IAE3B;;OAEG;gBACS,GAAG,IAAI,EAAE,KAAK,CAAC,GAAG,CAAC;IAyF/B;;;;;OAKG;IACH,OAAO,IAAI,KAAK,CAAC,GAAG,CAAC;IASrB;;;;;OAKG;IACH,QAAQ,IAAI,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;IAe/B;;OAEG;IACH,KAAK,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM;IAuBnE;;OAEG;IACH,MAAM,CAAC,QAAQ,EAAE,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE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MAAM;IAOjC,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,OAAO,GAAG,UAAU;IAStD,SAAS,IAAI,MAAM;IAInB,SAAS,IAAI,MAAM;CAGtB"}

@ -106,35 +106,45 @@ class Result extends Array {
}); });
} }
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray() { toArray(deep) {
const result = []; const result = [];
this.forEach((item, index) => { this.forEach((item, index) => {
if (item instanceof Error) { if (item instanceof Error) {
throwError(`index ${index}`, item); throwError(`index ${index}`, item);
} }
if (deep && item instanceof Result) {
item = item.toArray(deep);
}
result.push(item); result.push(item);
}); });
return result; return result;
} }
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject() { toObject(deep) {
return this.#names.reduce((accum, name, index) => { return this.#names.reduce((accum, name, index) => {
(0, index_js_1.assert)(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", { (0, index_js_1.assert)(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", {
operation: "toObject()" operation: "toObject()"
}); });
// Add values for names that don't conflict // Add values for names that don't conflict
if (!(name in accum)) { if (!(name in accum)) {
accum[name] = this.getValue(name); let child = this.getValue(name);
if (deep && child instanceof Result) {
child = child.toObject(deep);
}
accum[name] = child;
} }
return accum; return accum;
}, {}); }, {});

File diff suppressed because one or more lines are too long

@ -5,7 +5,7 @@ export { ZeroAddress, WeiPerEther, MaxUint256, MinInt256, MaxInt256, N, ZeroHash
export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js"; export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js";
export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js"; export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js";
export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js"; export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js";
export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js"; export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, ChainstackProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js";
export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js"; export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js";
export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js"; export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js";
export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js"; export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js";
@ -16,7 +16,7 @@ export type { ConstantContractMethod, ContractEvent, ContractEventArgs, Contract
export type { ProgressCallback, SignatureLike } from "./crypto/index.js"; export type { ProgressCallback, SignatureLike } from "./crypto/index.js";
export type { TypedDataDomain, TypedDataField } from "./hash/index.js"; export type { TypedDataDomain, TypedDataField } from "./hash/index.js";
export type { Provider, Signer, AbstractProviderOptions, FallbackProviderOptions, AbstractProviderPlugin, BlockParams, BlockTag, ContractRunner, DebugEventBrowserProvider, Eip1193Provider, EventFilter, Filter, FilterByBlockHash, GasCostParameters, JsonRpcApiProviderOptions, JsonRpcError, JsonRpcPayload, JsonRpcResult, JsonRpcTransactionRequest, LogParams, MinedBlock, MinedTransactionResponse, Networkish, OrphanFilter, PerformActionFilter, PerformActionRequest, PerformActionTransaction, PreparedTransactionRequest, ProviderEvent, Subscriber, Subscription, TopicFilter, TransactionReceiptParams, TransactionRequest, TransactionResponseParams, WebSocketCreator, WebSocketLike } from "./providers/index.js"; export type { Provider, Signer, AbstractProviderOptions, FallbackProviderOptions, AbstractProviderPlugin, BlockParams, BlockTag, ContractRunner, DebugEventBrowserProvider, Eip1193Provider, EventFilter, Filter, FilterByBlockHash, GasCostParameters, JsonRpcApiProviderOptions, JsonRpcError, JsonRpcPayload, JsonRpcResult, JsonRpcTransactionRequest, LogParams, MinedBlock, MinedTransactionResponse, Networkish, OrphanFilter, PerformActionFilter, PerformActionRequest, PerformActionTransaction, PreparedTransactionRequest, ProviderEvent, Subscriber, Subscription, TopicFilter, TransactionReceiptParams, TransactionRequest, TransactionResponseParams, WebSocketCreator, WebSocketLike } from "./providers/index.js";
export type { AccessList, AccessListish, AccessListEntry, TransactionLike } from "./transaction/index.js"; export type { AccessList, AccessListish, AccessListEntry, Blob, BlobLike, KzgLibrary, TransactionLike } from "./transaction/index.js";
export type { BytesLike, BigNumberish, Numeric, ErrorCode, FixedFormat, Utf8ErrorFunc, UnicodeNormalizationForm, Utf8ErrorReason, RlpStructuredData, RlpStructuredDataish, GetUrlResponse, FetchPreflightFunc, FetchProcessFunc, FetchRetryFunc, FetchGatewayFunc, FetchGetUrlFunc, EthersError, UnknownError, NotImplementedError, UnsupportedOperationError, NetworkError, ServerError, TimeoutError, BadDataError, CancelledError, BufferOverrunError, NumericFaultError, InvalidArgumentError, MissingArgumentError, UnexpectedArgumentError, CallExceptionError, InsufficientFundsError, NonceExpiredError, OffchainFaultError, ReplacementUnderpricedError, TransactionReplacedError, UnconfiguredNameError, ActionRejectedError, CodedEthersError, CallExceptionAction, CallExceptionTransaction, EventEmitterable, Listener } from "./utils/index.js"; export type { BytesLike, BigNumberish, Numeric, ErrorCode, FixedFormat, Utf8ErrorFunc, UnicodeNormalizationForm, Utf8ErrorReason, RlpStructuredData, RlpStructuredDataish, GetUrlResponse, FetchPreflightFunc, FetchProcessFunc, FetchRetryFunc, FetchGatewayFunc, FetchGetUrlFunc, EthersError, UnknownError, NotImplementedError, UnsupportedOperationError, NetworkError, ServerError, TimeoutError, BadDataError, CancelledError, BufferOverrunError, NumericFaultError, InvalidArgumentError, MissingArgumentError, UnexpectedArgumentError, CallExceptionError, InsufficientFundsError, NonceExpiredError, OffchainFaultError, ReplacementUnderpricedError, TransactionReplacedError, UnconfiguredNameError, ActionRejectedError, CodedEthersError, CallExceptionAction, CallExceptionTransaction, EventEmitterable, Listener } from "./utils/index.js";
export type { CrowdsaleAccount, KeystoreAccount, EncryptOptions } from "./wallet/index.js"; export type { CrowdsaleAccount, KeystoreAccount, EncryptOptions } from "./wallet/index.js";
//# sourceMappingURL=ethers.d.ts.map //# sourceMappingURL=ethers.d.ts.map

@ -1 +1 @@
{"version":3,"file":"ethers.d.ts","sourceRoot":"","sources":["../src.ts/ethers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,OAAO,EACH,mBAAmB,EAAE,mBAAmB,EAExC,QAAQ,EACR,mBAAmB,EAAE,aAAa,EAAE,aAAa,EAAE,QAAQ,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,EAAE,SAAS,EAAE,cAAc,EAEzI,iBAAiB,EAAE,gBAAgB,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,EAAE,sBAAsB,EACvG,KAAK,GACR,MAAM,gBAAgB,CAAC;AAExB,OAAO,EACH,UAAU,EAAE,cAAc,EAC1B,gBAAgB,EAAE,iBAAiB,EACnC,aAAa,EAAE,SAAS,EAAE,cAAc,EAC3C,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACH,WAAW,EACX,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC,EAChD,QAAQ,EACR,WAAW,EAAE,aAAa,EAC7B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACH,YAAY,EAAE,QAAQ,EACtB,eAAe,EACf,oBAAoB,EAAE,0BAA0B,EAAE,2BAA2B,EAAE,2BAA2B,EAAE,QAAQ,EAAE,iBAAiB,EAC1I,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EACH,WAAW,EACX,WAAW,EACX,SAAS,EACT,SAAS,EACT,MAAM,EAAE,MAAM,EACd,MAAM,EACN,MAAM,EAAE,UAAU,EAClB,IAAI,EACJ,SAAS,EAAE,UAAU,EACxB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACH,EAAE,EACF,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,SAAS,EAC9C,WAAW,EAAE,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.defineProperty(exports, "__esModule", { value: true });
exports.ripemd160 = exports.keccak256 = exports.randomBytes = exports.computeHmac = exports.UndecodedEventLog = exports.EventLog = exports.ContractUnknownEventPayload = exports.ContractTransactionResponse = exports.ContractTransactionReceipt = exports.ContractEventPayload = exports.ContractFactory = exports.Contract = exports.BaseContract = exports.MessagePrefix = exports.EtherSymbol = exports.ZeroHash = exports.N = exports.MaxInt256 = exports.MinInt256 = exports.MaxUint256 = exports.WeiPerEther = exports.ZeroAddress = exports.resolveAddress = exports.isAddress = exports.isAddressable = exports.getCreate2Address = exports.getCreateAddress = exports.getIcapAddress = exports.getAddress = exports.Typed = exports.TransactionDescription = exports.Result = exports.LogDescription = exports.Interface = exports.Indexed = exports.ErrorDescription = exports.checkResultErrors = exports.StructFragment = exports.ParamType = exports.NamedFragment = exports.FunctionFragment = exports.FallbackFragment = exports.Fragment = exports.EventFragment = exports.ErrorFragment = exports.ConstructorFragment = exports.AbiCoder = exports.encodeBytes32String = exports.decodeBytes32String = exports.version = void 0; exports.ripemd160 = exports.keccak256 = exports.randomBytes = exports.computeHmac = exports.UndecodedEventLog = exports.EventLog = exports.ContractUnknownEventPayload = exports.ContractTransactionResponse = exports.ContractTransactionReceipt = exports.ContractEventPayload = exports.ContractFactory = exports.Contract = exports.BaseContract = exports.MessagePrefix = exports.EtherSymbol = exports.ZeroHash = exports.N = exports.MaxInt256 = exports.MinInt256 = exports.MaxUint256 = exports.WeiPerEther = exports.ZeroAddress = exports.resolveAddress = exports.isAddress = exports.isAddressable = exports.getCreate2Address = exports.getCreateAddress = exports.getIcapAddress = exports.getAddress = exports.Typed = exports.TransactionDescription = exports.Result = exports.LogDescription = exports.Interface = exports.Indexed = exports.ErrorDescription = exports.checkResultErrors = exports.StructFragment = exports.ParamType = exports.NamedFragment = exports.FunctionFragment = exports.FallbackFragment = exports.Fragment = exports.EventFragment = exports.ErrorFragment = exports.ConstructorFragment = exports.AbiCoder = exports.encodeBytes32String = exports.decodeBytes32String = exports.version = void 0;
exports.EtherscanPlugin = exports.EnsPlugin = exports.Network = exports.EnsResolver = exports.WebSocketProvider = exports.SocketProvider = exports.IpcSocketProvider = exports.QuickNodeProvider = exports.PocketProvider = exports.InfuraWebSocketProvider = exports.InfuraProvider = exports.EtherscanProvider = exports.CloudflareProvider = exports.AnkrProvider = exports.AlchemyProvider = exports.BrowserProvider = exports.JsonRpcSigner = exports.JsonRpcProvider = exports.JsonRpcApiProvider = exports.FallbackProvider = exports.AbstractProvider = exports.VoidSigner = exports.NonceManager = exports.AbstractSigner = exports.TransactionResponse = exports.TransactionReceipt = exports.Log = exports.FeeData = exports.Block = exports.getDefaultProvider = exports.verifyTypedData = exports.TypedDataEncoder = exports.solidityPackedSha256 = exports.solidityPackedKeccak256 = exports.solidityPacked = exports.verifyMessage = exports.hashMessage = exports.dnsEncode = exports.namehash = exports.isValidName = exports.ensNormalize = exports.id = exports.SigningKey = exports.Signature = exports.lock = exports.scryptSync = exports.scrypt = exports.pbkdf2 = exports.sha512 = exports.sha256 = void 0; exports.EnsPlugin = exports.Network = exports.EnsResolver = exports.WebSocketProvider = exports.SocketProvider = exports.IpcSocketProvider = exports.QuickNodeProvider = exports.PocketProvider = exports.InfuraWebSocketProvider = exports.InfuraProvider = exports.EtherscanProvider = exports.CloudflareProvider = exports.ChainstackProvider = exports.AnkrProvider = exports.AlchemyProvider = exports.BrowserProvider = exports.JsonRpcSigner = exports.JsonRpcProvider = exports.JsonRpcApiProvider = exports.FallbackProvider = exports.AbstractProvider = exports.VoidSigner = exports.NonceManager = exports.AbstractSigner = exports.TransactionResponse = exports.TransactionReceipt = exports.Log = exports.FeeData = exports.Block = exports.getDefaultProvider = exports.verifyTypedData = exports.TypedDataEncoder = exports.solidityPackedSha256 = exports.solidityPackedKeccak256 = exports.solidityPacked = exports.verifyMessage = exports.hashMessage = exports.dnsEncode = exports.namehash = exports.isValidName = exports.ensNormalize = exports.id = exports.SigningKey = exports.Signature = exports.lock = exports.scryptSync = exports.scrypt = exports.pbkdf2 = exports.sha512 = exports.sha256 = void 0;
exports.toBeArray = exports.getUint = exports.getNumber = exports.getBigInt = exports.FixedNumber = exports.FetchCancelSignal = exports.FetchResponse = exports.FetchRequest = exports.EventPayload = exports.isError = exports.isCallException = exports.makeError = exports.assertPrivate = exports.assertNormalize = exports.assertArgumentCount = exports.assertArgument = exports.assert = exports.resolveProperties = exports.defineProperties = exports.zeroPadValue = exports.zeroPadBytes = exports.stripZerosLeft = exports.isBytesLike = exports.isHexString = exports.hexlify = exports.getBytesCopy = exports.getBytes = exports.dataSlice = exports.dataLength = exports.concat = exports.encodeBase64 = exports.decodeBase64 = exports.encodeBase58 = exports.decodeBase58 = exports.Transaction = exports.recoverAddress = exports.computeAddress = exports.accessListify = exports.showThrottleMessage = exports.copyRequest = exports.UnmanagedSubscriber = exports.SocketSubscriber = exports.SocketPendingSubscriber = exports.SocketEventSubscriber = exports.SocketBlockSubscriber = exports.MulticoinProviderPlugin = exports.NetworkPlugin = exports.GasCostPlugin = exports.FetchUrlFeeDataNetworkPlugin = exports.FeeDataNetworkPlugin = void 0; exports.getUint = exports.getNumber = exports.getBigInt = exports.FixedNumber = exports.FetchCancelSignal = exports.FetchResponse = exports.FetchRequest = exports.EventPayload = exports.isError = exports.isCallException = exports.makeError = exports.assertPrivate = exports.assertNormalize = exports.assertArgumentCount = exports.assertArgument = exports.assert = exports.resolveProperties = exports.defineProperties = exports.zeroPadValue = exports.zeroPadBytes = exports.stripZerosLeft = exports.isBytesLike = exports.isHexString = exports.hexlify = exports.getBytesCopy = exports.getBytes = exports.dataSlice = exports.dataLength = exports.concat = exports.encodeBase64 = exports.decodeBase64 = exports.encodeBase58 = exports.decodeBase58 = exports.Transaction = exports.recoverAddress = exports.computeAddress = exports.accessListify = exports.showThrottleMessage = exports.copyRequest = exports.UnmanagedSubscriber = exports.SocketSubscriber = exports.SocketPendingSubscriber = exports.SocketEventSubscriber = exports.SocketBlockSubscriber = exports.MulticoinProviderPlugin = exports.NetworkPlugin = exports.GasCostPlugin = exports.FetchUrlFeeDataNetworkPlugin = exports.FeeDataNetworkPlugin = exports.EtherscanPlugin = void 0;
exports.wordlists = exports.WordlistOwlA = exports.WordlistOwl = exports.LangEn = exports.Wordlist = exports.encryptKeystoreJsonSync = exports.encryptKeystoreJson = exports.decryptKeystoreJson = exports.decryptKeystoreJsonSync = exports.decryptCrowdsaleJson = exports.isKeystoreJson = exports.isCrowdsaleJson = exports.getIndexedAccountPath = exports.getAccountPath = exports.defaultPath = exports.Wallet = exports.HDNodeVoidWallet = exports.HDNodeWallet = exports.BaseWallet = exports.Mnemonic = exports.uuidV4 = exports.encodeRlp = exports.decodeRlp = exports.Utf8ErrorFuncs = exports.toUtf8String = exports.toUtf8CodePoints = exports.toUtf8Bytes = exports.parseUnits = exports.formatUnits = exports.parseEther = exports.formatEther = exports.mask = exports.toTwos = exports.fromTwos = exports.toQuantity = exports.toNumber = exports.toBeHex = exports.toBigInt = void 0; exports.wordlists = exports.WordlistOwlA = exports.WordlistOwl = exports.LangEn = exports.Wordlist = exports.encryptKeystoreJsonSync = exports.encryptKeystoreJson = exports.decryptKeystoreJson = exports.decryptKeystoreJsonSync = exports.decryptCrowdsaleJson = exports.isKeystoreJson = exports.isCrowdsaleJson = exports.getIndexedAccountPath = exports.getAccountPath = exports.defaultPath = exports.Wallet = exports.HDNodeVoidWallet = exports.HDNodeWallet = exports.BaseWallet = exports.Mnemonic = exports.uuidV4 = exports.encodeRlp = exports.decodeRlp = exports.Utf8ErrorFuncs = exports.toUtf8String = exports.toUtf8CodePoints = exports.toUtf8Bytes = exports.parseUnits = exports.formatUnits = exports.parseEther = exports.formatEther = exports.mask = exports.toTwos = exports.fromTwos = exports.toQuantity = exports.toNumber = exports.toBeHex = exports.toBigInt = exports.toBeArray = void 0;
var _version_js_1 = require("./_version.js"); var _version_js_1 = require("./_version.js");
Object.defineProperty(exports, "version", { enumerable: true, get: function () { return _version_js_1.version; } }); Object.defineProperty(exports, "version", { enumerable: true, get: function () { return _version_js_1.version; } });
var index_js_1 = require("./abi/index.js"); var index_js_1 = require("./abi/index.js");
@ -101,6 +101,7 @@ Object.defineProperty(exports, "JsonRpcSigner", { enumerable: true, get: functio
Object.defineProperty(exports, "BrowserProvider", { enumerable: true, get: function () { return index_js_7.BrowserProvider; } }); Object.defineProperty(exports, "BrowserProvider", { enumerable: true, get: function () { return index_js_7.BrowserProvider; } });
Object.defineProperty(exports, "AlchemyProvider", { enumerable: true, get: function () { return index_js_7.AlchemyProvider; } }); Object.defineProperty(exports, "AlchemyProvider", { enumerable: true, get: function () { return index_js_7.AlchemyProvider; } });
Object.defineProperty(exports, "AnkrProvider", { enumerable: true, get: function () { return index_js_7.AnkrProvider; } }); Object.defineProperty(exports, "AnkrProvider", { enumerable: true, get: function () { return index_js_7.AnkrProvider; } });
Object.defineProperty(exports, "ChainstackProvider", { enumerable: true, get: function () { return index_js_7.ChainstackProvider; } });
Object.defineProperty(exports, "CloudflareProvider", { enumerable: true, get: function () { return index_js_7.CloudflareProvider; } }); Object.defineProperty(exports, "CloudflareProvider", { enumerable: true, get: function () { return index_js_7.CloudflareProvider; } });
Object.defineProperty(exports, "EtherscanProvider", { enumerable: true, get: function () { return index_js_7.EtherscanProvider; } }); Object.defineProperty(exports, "EtherscanProvider", { enumerable: true, get: function () { return index_js_7.EtherscanProvider; } });
Object.defineProperty(exports, "InfuraProvider", { enumerable: true, get: function () { return index_js_7.InfuraProvider; } }); Object.defineProperty(exports, "InfuraProvider", { enumerable: true, get: function () { return index_js_7.InfuraProvider; } });

@ -1 +1 @@
{"version":3,"file":"ethers.js","sourceRoot":"","sources":["../src.ts/ethers.ts"],"names":[],"mappings":";AAEA,6BAA6B;AAC7B,EAAE;;;;;;AAEF,6CAAwC;AAA/B,sGAAA,OAAO,OAAA;AAEhB,2CAQwB;AAPpB,+GAAA,mBAAmB,OAAA;AAAE,+GAAA,mBAAmB,OAAA;AAExC,oGAAA,QAAQ,OAAA;AACR,+GAAA,mBAAmB,OAAA;AAAE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AE/B,iHAAA,oBAAoB,OAAA;AAAE,oHAAA,uBAAuB,OAAA;AAAE,gHAAA,mBAAmB,OAAA;AAClE,gHAAA,mBAAmB,OAAA;AAAE,oHAAA,uBAAuB,OAAA;AAGhD,kDAE8B;AAD1B,qGAAA,QAAQ,OAAA;AAAE,mGAAA,MAAM,OAAA;AAAE,wGAAA,WAAW,OAAA;AAAE,yGAAA,YAAY,OAAA;AAAE,sGAAA,SAAS,OAAA"}

@ -152,8 +152,8 @@ class AbstractSigner {
}); });
} }
} }
else if (pop.type === 2) { else if (pop.type === 2 || pop.type === 3) {
// Explicitly using EIP-1559 // Explicitly using EIP-1559 or EIP-4844
// Populate missing fee data // Populate missing fee data
if (pop.maxFeePerGas == null) { if (pop.maxFeePerGas == null) {
pop.maxFeePerGas = feeData.maxFeePerGas; pop.maxFeePerGas = feeData.maxFeePerGas;

File diff suppressed because one or more lines are too long

@ -24,6 +24,7 @@ import { WebSocketLike } from "./provider-websocket.js";
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``

@ -1 +1 @@
{"version":3,"file":"default-provider.d.ts","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AASxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,UAAU,GAAG,aAAa,EAAE,OAAO,CAAC,EAAE,GAAG,GAAG,gBAAgB,CAkHjH"} {"version":3,"file":"default-provider.d.ts","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AASxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,UAAU,GAAG,aAAa,EAAE,OAAO,CAAC,EAAE,GAAG,GAAG,gBAAgB,CA0HjH"}

@ -4,6 +4,7 @@ exports.getDefaultProvider = void 0;
const index_js_1 = require("../utils/index.js"); const index_js_1 = require("../utils/index.js");
const provider_ankr_js_1 = require("./provider-ankr.js"); const provider_ankr_js_1 = require("./provider-ankr.js");
const provider_alchemy_js_1 = require("./provider-alchemy.js"); const provider_alchemy_js_1 = require("./provider-alchemy.js");
const provider_chainstack_js_1 = require("./provider-chainstack.js");
const provider_cloudflare_js_1 = require("./provider-cloudflare.js"); const provider_cloudflare_js_1 = require("./provider-cloudflare.js");
const provider_etherscan_js_1 = require("./provider-etherscan.js"); const provider_etherscan_js_1 = require("./provider-etherscan.js");
const provider_infura_js_1 = require("./provider-infura.js"); const provider_infura_js_1 = require("./provider-infura.js");
@ -41,6 +42,7 @@ const Testnets = "goerli kovan sepolia classicKotti optimism-goerli arbitrum-goe
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``
@ -94,6 +96,9 @@ function getDefaultProvider(network, options) {
if (staticNetwork.name === "matic") { if (staticNetwork.name === "matic") {
providers.push(new provider_jsonrpc_js_1.JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork })); providers.push(new provider_jsonrpc_js_1.JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork }));
} }
else if (staticNetwork.name === "matic-amoy") {
providers.push(new provider_jsonrpc_js_1.JsonRpcProvider("https:/\/rpc-amoy.polygon.technology/", staticNetwork, { staticNetwork }));
}
} }
if (allowService("alchemy")) { if (allowService("alchemy")) {
try { try {
@ -107,6 +112,12 @@ function getDefaultProvider(network, options) {
} }
catch (error) { } catch (error) { }
} }
if (allowService("chainstack")) {
try {
providers.push(new provider_chainstack_js_1.ChainstackProvider(network, options.chainstack));
}
catch (error) { }
}
if (allowService("cloudflare")) { if (allowService("cloudflare")) {
try { try {
providers.push(new provider_cloudflare_js_1.CloudflareProvider(network)); providers.push(new provider_cloudflare_js_1.CloudflareProvider(network));

@ -1 +1 @@
{"version":3,"file":"default-provider.js","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":";;;AACA,gDAA2C;AAE3C,yDAAkD;AAClD,+DAAwD;AACxD,qEAA8D;AAC9D,mEAA4D;AAC5D,6DAAsD;AACtD,wDAAwD;AACxD,mEAA4D;AAE5D,iEAA0D;AAC1D,+DAAwD;AACxD,6CAAuC;AACvC,mEAA4D;AAM5D,SAAS,eAAe,CAAC,KAAU;IAC/B,OAAO,CAAC,KAAK,IAAI,OAAM,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,UAAU;QAC9C,OAAM,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,UAAU,CAAC,CAAC;AAC5C,CAAC;AAED,MAAM,QAAQ,GAAG,qFAAqF,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;AAElH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,SAAgB,kBAAkB,CAAC,OAA6C,EAAE,OAAa;IAC3F,IAAI,OAAO,IAAI,IAAI,EAAE;QAAE,OA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EAAE,uBAAuB,EAAE;QAC7E,SAAS,EAAE,oBAAoB;KAClC,CAAC,CAAC;IAEH,iCAAiC;IACjC,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC,EAAE;QAAE,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC;KAAE;IAEpD,2EAA2E;IAC3E,uEAAuE;IACvE,IAAI,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;IAC9C,IAAI,MAAM,GAAG,CAAC,EAAE;QAAE,MAAM,GAAG,CAAC,CAAC;KAAE;IAE/B,kEAAkE;IAClE,6BAA6B;IAC7B,IAAI,aAAa,IAAI,QAAQ,CAAC,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE;QAAE,MAAM,GAAG,CAAC,CAAC;KAAE;IAEjF,yCAAyC;IACzC,IAAI,OAAO,IAAI,OAAO,CAAC,MAAM,EAAE;QAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;KAAE;IAE3D,OAAO,IAAI,uCAAgB,CAAC,SAAS,EAAE,SAAS,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;AAClE,CAAC;AA1HD,gDA0HC"}

@ -24,6 +24,7 @@ export { BrowserProvider } from "./provider-browser.js";
export { AlchemyProvider } from "./provider-alchemy.js"; export { AlchemyProvider } from "./provider-alchemy.js";
export { AnkrProvider } from "./provider-ankr.js"; export { AnkrProvider } from "./provider-ankr.js";
export { CloudflareProvider } from "./provider-cloudflare.js"; export { CloudflareProvider } from "./provider-cloudflare.js";
export { ChainstackProvider } from "./provider-chainstack.js";
export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js"; export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js";
export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js"; export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js";
export { PocketProvider } from "./provider-pocket.js"; export { PocketProvider } from "./provider-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AE/B,YAAY,EACR,gBAAgB,EAAE,aAAa,EAClC,MAAM,yBAAyB,CAAC;AAEjC,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC"}

@ -11,7 +11,7 @@
* @_section: api/providers:Providers [about-providers] * @_section: api/providers:Providers [about-providers]
*/ */
Object.defineProperty(exports, "__esModule", { value: true }); Object.defineProperty(exports, "__esModule", { value: true });
exports.SocketEventSubscriber = exports.SocketPendingSubscriber = exports.SocketBlockSubscriber = exports.SocketSubscriber = exports.WebSocketProvider = exports.SocketProvider = exports.IpcSocketProvider = exports.QuickNodeProvider = exports.PocketProvider = exports.InfuraWebSocketProvider = exports.InfuraProvider = exports.EtherscanPlugin = exports.EtherscanProvider = exports.CloudflareProvider = exports.AnkrProvider = exports.AlchemyProvider = exports.BrowserProvider = exports.JsonRpcSigner = exports.JsonRpcProvider = exports.JsonRpcApiProvider = exports.FallbackProvider = exports.copyRequest = exports.TransactionResponse = exports.TransactionReceipt = exports.Log = exports.FeeData = exports.Block = exports.FetchUrlFeeDataNetworkPlugin = exports.FeeDataNetworkPlugin = exports.EnsPlugin = exports.GasCostPlugin = exports.NetworkPlugin = exports.NonceManager = exports.Network = exports.MulticoinProviderPlugin = exports.EnsResolver = exports.getDefaultProvider = exports.showThrottleMessage = exports.VoidSigner = exports.AbstractSigner = exports.UnmanagedSubscriber = exports.AbstractProvider = void 0; exports.SocketEventSubscriber = exports.SocketPendingSubscriber = exports.SocketBlockSubscriber = exports.SocketSubscriber = exports.WebSocketProvider = exports.SocketProvider = exports.IpcSocketProvider = exports.QuickNodeProvider = exports.PocketProvider = exports.InfuraWebSocketProvider = exports.InfuraProvider = exports.EtherscanPlugin = exports.EtherscanProvider = exports.ChainstackProvider = exports.CloudflareProvider = exports.AnkrProvider = exports.AlchemyProvider = exports.BrowserProvider = exports.JsonRpcSigner = exports.JsonRpcProvider = exports.JsonRpcApiProvider = exports.FallbackProvider = exports.copyRequest = exports.TransactionResponse = exports.TransactionReceipt = exports.Log = exports.FeeData = exports.Block = exports.FetchUrlFeeDataNetworkPlugin = exports.FeeDataNetworkPlugin = exports.EnsPlugin = exports.GasCostPlugin = exports.NetworkPlugin = exports.NonceManager = exports.Network = exports.MulticoinProviderPlugin = exports.EnsResolver = exports.getDefaultProvider = exports.showThrottleMessage = exports.VoidSigner = exports.AbstractSigner = exports.UnmanagedSubscriber = exports.AbstractProvider = void 0;
var abstract_provider_js_1 = require("./abstract-provider.js"); var abstract_provider_js_1 = require("./abstract-provider.js");
Object.defineProperty(exports, "AbstractProvider", { enumerable: true, get: function () { return abstract_provider_js_1.AbstractProvider; } }); Object.defineProperty(exports, "AbstractProvider", { enumerable: true, get: function () { return abstract_provider_js_1.AbstractProvider; } });
Object.defineProperty(exports, "UnmanagedSubscriber", { enumerable: true, get: function () { return abstract_provider_js_1.UnmanagedSubscriber; } }); Object.defineProperty(exports, "UnmanagedSubscriber", { enumerable: true, get: function () { return abstract_provider_js_1.UnmanagedSubscriber; } });
@ -56,6 +56,8 @@ var provider_ankr_js_1 = require("./provider-ankr.js");
Object.defineProperty(exports, "AnkrProvider", { enumerable: true, get: function () { return provider_ankr_js_1.AnkrProvider; } }); Object.defineProperty(exports, "AnkrProvider", { enumerable: true, get: function () { return provider_ankr_js_1.AnkrProvider; } });
var provider_cloudflare_js_1 = require("./provider-cloudflare.js"); var provider_cloudflare_js_1 = require("./provider-cloudflare.js");
Object.defineProperty(exports, "CloudflareProvider", { enumerable: true, get: function () { return provider_cloudflare_js_1.CloudflareProvider; } }); Object.defineProperty(exports, "CloudflareProvider", { enumerable: true, get: function () { return provider_cloudflare_js_1.CloudflareProvider; } });
var provider_chainstack_js_1 = require("./provider-chainstack.js");
Object.defineProperty(exports, "ChainstackProvider", { enumerable: true, get: function () { return provider_chainstack_js_1.ChainstackProvider; } });
var provider_etherscan_js_1 = require("./provider-etherscan.js"); var provider_etherscan_js_1 = require("./provider-etherscan.js");
Object.defineProperty(exports, "EtherscanProvider", { enumerable: true, get: function () { return provider_etherscan_js_1.EtherscanProvider; } }); Object.defineProperty(exports, "EtherscanProvider", { enumerable: true, get: function () { return provider_etherscan_js_1.EtherscanProvider; } });
Object.defineProperty(exports, "EtherscanPlugin", { enumerable: true, get: function () { return provider_etherscan_js_1.EtherscanPlugin; } }); Object.defineProperty(exports, "EtherscanPlugin", { enumerable: true, get: function () { return provider_etherscan_js_1.EtherscanPlugin; } });

@ -1 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src.ts/providers/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;GAUG;;;AAGH,+DAEgC;AAD5B,wHAAA,gBAAgB,OAAA;AAAE,2HAAA,mBAAmB,OAAA;AAGzC,2DAG8B;AAF1B,oHAAA,cAAc,OAAA;AACd,gHAAA,UAAU,OAAA;AAGd,+CAEwB;AADpB,mHAAA,mBAAmB,OAAA;AAGvB,6DAA2D;AAAlD,yHAAA,kBAAkB,OAAA;AAE3B,qDAG2B;AAFvB,8GAAA,WAAW,OAAA;AACX,0HAAA,uBAAuB,OAAA;AAG3B,2CAAuC;AAA9B,qGAAA,OAAO,OAAA;AAEhB,mEAAwD;AAA/C,sHAAA,YAAY,OAAA;AAErB,2DAM8B;AAL1B,mHAAA,aAAa,OAAA;AACb,mHAAA,aAAa,OAAA;AACb,+GAAA,SAAS,OAAA;AACT,0HAAA,oBAAoB,OAAA;AACpB,kIAAA,4BAA4B,OAAA;AAGhC,6CASuB;AARnB,oGAAA,KAAK,OAAA;AACL,sGAAA,OAAO,OAAA;AACP,kGAAA,GAAG,OAAA;AACH,iHAAA,kBAAkB,OAAA;AAClB,kHAAA,mBAAmB,OAAA;AAEnB,0GAAA,WAAW,OAAA;AAIf,+DAA0D;AAAjD,wHAAA,gBAAgB,OAAA;AACzB,6DAA0F;AAAjF,yHAAA,kBAAkB,OAAA;AAAE,sHAAA,eAAe,OAAA;AAAE,oHAAA,aAAa,OAAA;AAE3D,6DAAwD;AAA/C,sHAAA,eAAe,OAAA;AAExB,6DAAwD;AA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A,KAAK,OAAA;AACL,sGAAA,OAAO,OAAA;AACP,kGAAA,GAAG,OAAA;AACH,iHAAA,kBAAkB,OAAA;AAClB,kHAAA,mBAAmB,OAAA;AAEnB,0GAAA,WAAW,OAAA;AAIf,+DAA0D;AAAjD,wHAAA,gBAAgB,OAAA;AACzB,6DAA0F;AAAjF,yHAAA,kBAAkB,OAAA;AAAE,sHAAA,eAAe,OAAA;AAAE,oHAAA,aAAa,OAAA;AAE3D,6DAAwD;AAA/C,sHAAA,eAAe,OAAA;AAExB,6DAAwD;AAA/C,sHAAA,eAAe,OAAA;AACxB,uDAAkD;AAAzC,gHAAA,YAAY,OAAA;AACrB,mEAA8D;AAArD,4HAAA,kBAAkB,OAAA;AAC3B,mEAA8D;AAArD,4HAAA,kBAAkB,OAAA;AAC3B,iEAA6E;AAApE,0HAAA,iBAAiB,OAAA;AAAE,wHAAA,eAAe,OAAA;AAC3C,2DAA+E;AAAtE,oHAAA,cAAc,OAAA;AAAE,6HAAA,uBAAuB,OAAA;AAChD,2DAAsD;AAA7C,oHAAA,cAAc,OAAA;AACvB,iEAA4D;AAAnD,0HAAA,iBAAiB,OAAA;AAE1B,mEAA4D,CAAC,YAAY;AAChE,kGADA,yCAAiB,OACA;AAC1B,2DAAsD;AAA7C,oHAAA,cAAc,OAAA;AACvB,iEAA4D;AAAnD,0HAAA,iBAAiB,OAAA;AAE1B,2DAG8B;AAF1B,sHAAA,gBAAgB,OAAA;AAAE,2HAAA,qBAAqB,OAAA;AAAE,6HAAA,uBAAuB,OAAA;AAChE,2HAAA,qBAAqB,OAAA"}

@ -348,6 +348,7 @@ function injectCommonNetworks() {
getGasStationPlugin("https:/\/gasstation.polygon.technology/v2") getGasStationPlugin("https:/\/gasstation.polygon.technology/v2")
] ]
}); });
registerEth("matic-amoy", 80002, {});
registerEth("matic-mumbai", 80001, { registerEth("matic-mumbai", 80001, {
altNames: ["maticMumbai", "maticmum"], altNames: ["maticMumbai", "maticmum"],
plugins: [ plugins: [

File diff suppressed because one or more lines are too long

@ -17,6 +17,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]

@ -1 +1 @@
{"version":3,"file":"provider-alchemy.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAEH,YAAY,EACf,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAyC/C;;;;;;;;;;GAUG;AACH,qBAAa,eAAgB,SAAQ,eAAgB,YAAW,oBAAoB;IAChF,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;gBAEb,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAWzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAOzC,QAAQ,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,GAAG,CAAC;IAmCvD,mBAAmB,IAAI,OAAO;IAI9B,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,YAAY;CAerE"} {"version":3,"file":"provider-alchemy.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,EAEH,YAAY,EACf,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AA2C/C;;;;;;;;;;GAUG;AACH,qBAAa,eAAgB,SAAQ,eAAgB,YAAW,oBAAoB;IAChF,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;gBAEb,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAWzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAOzC,QAAQ,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,GAAG,CAAC;IAmCvD,mBAAmB,IAAI,OAAO;IAI9B,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,YAAY;CAerE"}

@ -18,6 +18,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]
@ -51,6 +52,8 @@ function getHost(name) {
return "base-sepolia.g.alchemy.com"; return "base-sepolia.g.alchemy.com";
case "matic": case "matic":
return "polygon-mainnet.g.alchemy.com"; return "polygon-mainnet.g.alchemy.com";
case "matic-amoy":
return "polygon-amoy.g.alchemy.com";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.g.alchemy.com"; return "polygon-mumbai.g.alchemy.com";
case "optimism": case "optimism":

@ -1 +1 @@
{"version":3,"file":"provider-alchemy.js","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;;;AAEH,gDAG2B;AAE3B,iDAAqD;AACrD,6CAAuC;AACvC,+DAAwD;AAOxD,MAAM,aAAa,GAAG,kCAAkC,CAAA;AAExD,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QACvC,KAAK,QAAQ;YACT,OAAO,0BAA0B,CAAC;QACtC,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QAEvC,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB,OAAO,0BAA0B,CAAC;QACtC,KAAK,kBAAkB;YACnB,OAAO,2BAA2B,CAAC;QACvC,KAAK,MAAM;YACP,OAAO,4BAA4B,CAAC;QACxC,KAAK,aAAa;YACd,OAAO,2BAA2B,CAAC;QACvC,KAAK,cAAc;YACf,OAAO,4BAA4B,CAAC;QACxC,KAAK,OAAO;YACR,OAAO,+BAA+B,CAAC;QAC3C,KAAK,cAAc;YACf,OAAO,8BAA8B,CAAC;QAC1C,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB,OAAO,0BAA0B,CAAC;QACtC,KAAK,kBAAkB;YACnB,OAAO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C;QAEzB,IAAI,MAAM,KAAK,aAAa,EAAE;YAC1B,OAAO,CAAC,SAAS,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE;gBACrD,IAAA,kCAAmB,EAAC,SAAS,CAAC,CAAC;gBAC/B,OAAO,IAAI,CAAC;YAChB,CAAC,CAAA;SACJ;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ;AA3ED,0CA2EC"} {"version":3,"file":"provider-alchemy.js","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;;;AAEH,gDAG2B;AAE3B,iDAAqD;AACrD,6CAAuC;AACvC,+DAAwD;AAOxD,MAAM,aAAa,GAAG,kCAAkC,CAAA;AAExD,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QACvC,KAAK,QAAQ;YACT,OAAO,0BAA0B,CAAC;QACtC,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QAEvC,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB,OAAO,0BAA0B,CAAC;QACtC,KAAK,kBAAkB;YACnB,OAAO,2BAA2B,CAAC;QACvC,KAAK,MAAM;YACP,OAAO,4BAA4B,CAAC;QACxC,KAAK,aAAa;YACd,OAAO,2BAA2B,CAAC;QACvC,KAAK,cAAc;YACf,OAAO,4BAA4B,CAAC;QACxC,KAAK,OAAO;YACR,OAAO,+BAA+B,CAAC;QAC3C,KAAK,YAAY;YACb,OAAO,4BAA4B,CAAC;QACxC,KAAK,cAAc;YACf,OAAO,8BAA8B,CAAC;QAC1C,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB,OAAO,0BAA0B,CAAC;QACtC,KAAK,kBAAkB;YACnB,OAAO,2BAA2B,CAAC;KAC1C;IA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K,aAAa,EAAE;YAC1B,OAAO,CAAC,SAAS,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE;gBACrD,IAAA,kCAAmB,EAAC,SAAS,CAAC,CAAC;gBAC/B,OAAO,IAAI,CAAC;YAChB,CAAC,CAAA;SACJ;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ;AA3ED,0CA2EC"}

@ -0,0 +1,46 @@
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
import { FetchRequest } from "../utils/index.js";
import { Network } from "./network.js";
import { JsonRpcProvider } from "./provider-jsonrpc.js";
import type { AbstractProvider } from "./abstract-provider.js";
import type { CommunityResourcable } from "./community.js";
import type { Networkish } from "./network.js";
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
export declare class ChainstackProvider extends JsonRpcProvider implements CommunityResourcable {
/**
* The API key for the Chainstack connection.
*/
readonly apiKey: string;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network?: Networkish, apiKey?: null | string);
_getProvider(chainId: number): AbstractProvider;
isCommunityResource(): boolean;
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network: Network, apiKey?: null | string): FetchRequest;
}
//# sourceMappingURL=provider-chainstack.d.ts.map

@ -0,0 +1 @@
{"version":3,"file":"provider-chainstack.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-chainstack.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,EACe,YAAY,EACjC,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AA6B/C;;;;;;;;GAQG;AACH,qBAAa,kBAAmB,SAAQ,eAAgB,YAAW,oBAAoB;IACnF;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;IAEzB;;OAEG;gBACS,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAYzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAO/C,mBAAmB,IAAI,OAAO;IAI9B;;;OAGG;IACH,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,YAAY;CAe5E"}

@ -0,0 +1,102 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ChainstackProvider = void 0;
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
const index_js_1 = require("../utils/index.js");
const community_js_1 = require("./community.js");
const network_js_1 = require("./network.js");
const provider_jsonrpc_js_1 = require("./provider-jsonrpc.js");
function getApiKey(name) {
switch (name) {
case "mainnet": return "39f1d67cedf8b7831010a665328c9197";
case "arbitrum": return "0550c209db33c3abf4cc927e1e18cea1";
case "bnb": return "98b5a77e531614387366f6fc5da097f8";
case "matic": return "cd9d4d70377471aa7c142ec4a4205249";
}
(0, index_js_1.assertArgument)(false, "unsupported network", "network", name);
}
function getHost(name) {
switch (name) {
case "mainnet":
return "ethereum-mainnet.core.chainstack.com";
case "arbitrum":
return "arbitrum-mainnet.core.chainstack.com";
case "bnb":
return "bsc-mainnet.core.chainstack.com";
case "matic":
return "polygon-mainnet.core.chainstack.com";
}
(0, index_js_1.assertArgument)(false, "unsupported network", "network", name);
}
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
class ChainstackProvider extends provider_jsonrpc_js_1.JsonRpcProvider {
/**
* The API key for the Chainstack connection.
*/
apiKey;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network, apiKey) {
if (_network == null) {
_network = "mainnet";
}
const network = network_js_1.Network.from(_network);
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = ChainstackProvider.getRequest(network, apiKey);
super(request, network, { staticNetwork: network });
(0, index_js_1.defineProperties)(this, { apiKey });
}
_getProvider(chainId) {
try {
return new ChainstackProvider(chainId, this.apiKey);
}
catch (error) { }
return super._getProvider(chainId);
}
isCommunityResource() {
return (this.apiKey === getApiKey(this._network.name));
}
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network, apiKey) {
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = new index_js_1.FetchRequest(`https:/\/${getHost(network.name)}/${apiKey}`);
request.allowGzip = true;
if (apiKey === getApiKey(network.name)) {
request.retryFunc = async (request, response, attempt) => {
(0, community_js_1.showThrottleMessage)("ChainstackProvider");
return true;
};
}
return request;
}
}
exports.ChainstackProvider = ChainstackProvider;
//# sourceMappingURL=provider-chainstack.js.map

@ -0,0 +1 @@
{"version":3,"file":"provider-chainstack.js","sourceRoot":"","sources":["../../src.ts/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testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]

@ -1 +1 @@
{"version":3,"file":"provider-infura.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-infura.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EACe,YAAY,EACjC,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAiD/C;;;;;;;;GAQG;AACH,qBAAa,uBAAwB,SAAQ,iBAAkB,YAAW,oBAAoB;IAE1F;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM;IAgBpD,mBAAmB,IAAI,OAAO;CAGjC;AAED;;;;;;;;GAQG;AACH,qBAAa,cAAe,SAAQ,eAAgB,YAAW,oBAAoB;IAC/E;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IA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,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM;IAgBpD,mBAAmB,IAAI,OAAO;CAGjC;AAED;;;;;;;;GAQG;AACH,qBAAa,cAAe,SAAQ,eAAgB,YAAW,oBAAoB;IAC/E;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,QAAQ,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,EAAE,aAAa,CAAC,EAAE,IAAI,GAAG,MAAM;IAY3F,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAO/C,mBAAmB,IAAI,OAAO;IAI9B;;OAEG;IACH,MAAM,CAAC,oBAAoB,CAAC,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,uBAAuB;IAI9F;;;OAGG;IACH,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,EAAE,aAAa,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,YAAY;CAiB9G"}

@ -24,6 +24,7 @@ exports.InfuraProvider = exports.InfuraWebSocketProvider = void 0;
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]
@ -64,6 +65,8 @@ function getHost(name) {
return "linea-goerli.infura.io"; return "linea-goerli.infura.io";
case "matic": case "matic":
return "polygon-mainnet.infura.io"; return "polygon-mainnet.infura.io";
case "matic-amoy":
return "polygon-amoy.infura.io";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.infura.io"; return "polygon-mumbai.infura.io";
case "optimism": case "optimism":

@ -1 +1 @@
{"version":3,"file":"provider-infura.js","sourceRoot":"","sources":["../../src.ts/providers/provider-infura.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,gDAE2B;AAE3B,iDAAqD;AACrD,6CAAuC;AACvC,+DAAwD;AACxD,mEAA4D;AAO5D,MAAM,gBAAgB,GAAG,kCAAkC,CAAC;AAE5D,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAC/B,KAAK,QAAQ;YACT,OAAO,kBAAkB,CAAC;QAC9B,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAE/B,KAAK,UAAU;YACX,OAAO,4BAA4B,CAAC;QACxC,KAAK,iBAAiB;YAClB,OAAO,2BAA2B,CAAC;QACvC,KAAK,kBAAkB;YACnB,OAAO,4BAA4B,CAAC;QACxC,KAAK,MAAM;YACP,OAAO,wBAAwB,CAAC;QACpC,KAAK,cAAc;YACf,OAAO,uBAAuB,CAAC;QACnC,KAAK,cAAc;YACf,OAAO,wBAAwB,CAAC;QACpC,KAAK,KAAK;YACN,OAAO,iCAAiC,CAAC;QAC7C,KAAK,MAAM;YACP,OAAO,iCAAiC,CAAC;QAC7C,KAAK,OAAO;YACR,OAAO,yBAAyB,CAAC;QACrC,KAAK,cAAc;YACf,OAAO,wBAAwB,CAAC;QACpC,KAAK,OAAO;YACR,OAAO,2BAA2B,CAAC;QACvC,KAAK,cAAc;YACf,OAAO,0BAA0B,CAAC;QACtC,KAAK,UAAU;YACX,OAAO,4BAA4B,CAAC;QACxC,KAA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E;QAEpD,MAAM,OAAO,GAAG,IAAI,uBAAY,CAAC,YAAa,OAAO,CAAC,OAAO,CAAC,IAAI,CAAE,OAAQ,SAAU,EAAE,CAAC,CAAC;QAC1F,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC;QACzB,IAAI,aAAa,EAAE;YAAE,OAAO,CAAC,cAAc,CAAC,EAAE,EAAE,aAAa,CAAC,CAAC;SAAE;QAEjE,IAAI,SAAS,KAAK,gBAAgB,EAAE;YAChC,OAAO,CAAC,SAAS,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE;gBACrD,IAAA,kCAAmB,EAAC,gBAAgB,CAAC,CAAC;gBACtC,OAAO,IAAI,CAAC;YAChB,CAAC,CAAC;SACL;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ;AApED,wCAoEC"} {"version":3,"file":"provider-infura.js","sourceRoot":"","sources":["../../src.ts/providers/provider-infura.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,gDAE2B;AAE3B,iDAAqD;AACrD,6CAAuC;AACvC,+DAAwD;AACxD,mEAA4D;AAO5D,MAAM,gBAAgB,GAAG,kCAAkC,CAAC;AAE5D,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAC/B,KAAK,QAAQ;YACT,OAAO,kBAAkB,CAAC;QAC9B,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAE/B,KAAK,UAAU;YACX,OAAO,4BAA4B,CAAC;QACxC,KAAK,iBAAiB;YAClB,OAAO,2BAA2B,CAAC;QACvC,KAAK,kBAAkB;YACnB,OAAO,4BAA4B,CAAC;QACxC,KAAK,MAAM;YACP,OAAO,wBAAwB,CAAC;QACpC,KAAK,cAAc;YACf,OAAO,uBAAuB,CAAC;QACnC,KAAK,cAAc;YACf,OAAO,wBAAwB,CAAC;QACpC,KAA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;IACH,MAAM,CAAC,oBAAoB,CAAC,OAAoB,EAAE,SAAkB;QAChE,OAAO,IAAI,uBAAuB,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;IAC3D,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,UAAU,CAAC,OAAgB,EAAE,SAAyB,EAAE,aAA6B;QACxF,IAAI,SAAS,IAAI,IAAI,EAAE;YAAE,SAAS,GAAG,gBAAgB,CAAC;SAAE;QACxD,IAAI,aAAa,IAAI,IAAI,EAAE;YAAE,aAAa,GAAG,IAAI,CAAC;SAAE;QAEpD,MAAM,OAAO,GAAG,IAAI,uBAAY,CAAC,YAAa,OAAO,CAAC,OAAO,CAAC,IAAI,CAAE,OAAQ,SAAU,EAAE,CAAC,CAAC;QAC1F,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC;QACzB,IAAI,aAAa,EAAE;YAAE,OAAO,CAAC,cAAc,CAAC,EAAE,EAAE,aAAa,CAAC,CAAC;SAAE;QAEjE,IAAI,SAAS,KAAK,gBAAgB,EAAE;YAChC,OAAO,CAAC,SAAS,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE;gBACrD,IAAA,kCAAmB,EAAC,gBAAgB,CAAC,CAAC;gBACtC,OAAO,IAAI,CAAC;YAChB,CAAC,CAAC;SACL;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ;AApED,wCAoEC"}

@ -1,7 +1,7 @@
import type { AddressLike, NameResolver } from "../address/index.js"; import type { AddressLike, NameResolver } from "../address/index.js";
import type { BigNumberish, EventEmitterable } from "../utils/index.js"; import type { BigNumberish, EventEmitterable } from "../utils/index.js";
import type { Signature } from "../crypto/index.js"; import type { Signature } from "../crypto/index.js";
import type { AccessList, AccessListish, TransactionLike } from "../transaction/index.js"; import type { AccessList, AccessListish, BlobLike, KzgLibrary, TransactionLike } from "../transaction/index.js";
import type { ContractRunner } from "./contracts.js"; import type { ContractRunner } from "./contracts.js";
import type { Network } from "./network.js"; import type { Network } from "./network.js";
/** /**
@ -144,6 +144,26 @@ export interface TransactionRequest {
* the fetch to unexpected parties. * the fetch to unexpected parties.
*/ */
enableCcipRead?: boolean; enableCcipRead?: boolean;
/**
* The blob versioned hashes (see [[link-eip-4844]]).
*/
blobVersionedHashes?: null | Array<string>;
/**
* The maximum fee per blob gas (see [[link-eip-4844]]).
*/
maxFeePerBlobGas?: null | BigNumberish;
/**
* Any blobs to include in the transaction (see [[link-eip-4844]]).
*/
blobs?: null | Array<BlobLike>;
/**
* An external library for computing the KZG commitments and
* proofs necessary for EIP-4844 transactions (see [[link-eip-4844]]).
*
* This is generally ``null``, unless you are creating BLOb
* transactions.
*/
kzg?: null | KzgLibrary;
} }
/** /**
* A **PreparedTransactionRequest** is identical to a [[TransactionRequest]] * A **PreparedTransactionRequest** is identical to a [[TransactionRequest]]

File diff suppressed because one or more lines are too long

@ -93,7 +93,7 @@ function copyRequest(req) {
if (req.data) { if (req.data) {
result.data = (0, index_js_1.hexlify)(req.data); result.data = (0, index_js_1.hexlify)(req.data);
} }
const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/); const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerBlobGas,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);
for (const key of bigIntKeys) { for (const key of bigIntKeys) {
if (!(key in req) || req[key] == null) { if (!(key in req) || req[key] == null) {
continue; continue;
@ -119,6 +119,20 @@ function copyRequest(req) {
if ("customData" in req) { if ("customData" in req) {
result.customData = req.customData; result.customData = req.customData;
} }
if ("blobVersionedHashes" in req && req.blobVersionedHashes) {
result.blobVersionedHashes = req.blobVersionedHashes.slice();
}
if ("kzg" in req) {
result.kzg = req.kzg;
}
if ("blobs" in req && req.blobs) {
result.blobs = req.blobs.map((b) => {
if ((0, index_js_1.isBytesLike)(b)) {
return (0, index_js_1.hexlify)(b);
}
return Object.assign({}, b);
});
}
return result; return result;
} }
exports.copyRequest = copyRequest; exports.copyRequest = copyRequest;

File diff suppressed because one or more lines are too long

@ -21,5 +21,5 @@ export type AccessListish = AccessList | Array<[string, Array<string>]> | Record
export { accessListify } from "./accesslist.js"; export { accessListify } from "./accesslist.js";
export { computeAddress, recoverAddress } from "./address.js"; export { computeAddress, recoverAddress } from "./address.js";
export { Transaction } from "./transaction.js"; export { Transaction } from "./transaction.js";
export type { TransactionLike } from "./transaction.js"; export type { Blob, BlobLike, KzgLibrary, TransactionLike } from "./transaction.js";
//# sourceMappingURL=index.d.ts.map //# sourceMappingURL=index.d.ts.map

@ -1 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src.ts/transaction/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;CAAE,CAAC;AAE9E;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,eAAe,CAAC,CAAC;AAEhD;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,UAAU,GACV,KAAK,CAAC,CAAE,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAE,CAAC,GAChC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;AAG1D,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,YAAY,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC"} {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src.ts/transaction/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;CAAE,CAAC;AAE9E;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,eAAe,CAAC,CAAC;AAEhD;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,UAAU,GACV,KAAK,CAAC,CAAE,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAE,CAAC,GAChC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;AAG1D,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,YAAY,EACR,IAAI,EAAE,QAAQ,EAAE,UAAU,EAAE,eAAe,EAC9C,MAAM,kBAAkB,CAAC"}

@ -72,6 +72,49 @@ export interface TransactionLike<A = string> {
* The versioned hashes (see [[link-eip-4844]]). * The versioned hashes (see [[link-eip-4844]]).
*/ */
blobVersionedHashes?: null | Array<string>; blobVersionedHashes?: null | Array<string>;
/**
* The blobs (if any) attached to this transaction (see [[link-eip-4844]]).
*/
blobs?: null | Array<BlobLike>;
/**
* An external library for computing the KZG commitments and
* proofs necessary for EIP-4844 transactions (see [[link-eip-4844]]).
*
* This is generally ``null``, unless you are creating BLOb
* transactions.
*/
kzg?: null | KzgLibrary;
}
/**
* A full-valid BLOb object for [[link-eip-4844]] transactions.
*
* The commitment and proof should have been computed using a
* KZG library.
*/
export interface Blob {
data: string;
proof: string;
commitment: string;
}
/**
* A BLOb object that can be passed for [[link-eip-4844]]
* transactions.
*
* It may have had its commitment and proof already provided
* or rely on an attached [[KzgLibrary]] to compute them.
*/
export type BlobLike = BytesLike | {
data: BytesLike;
proof: BytesLike;
commitment: BytesLike;
};
/**
* A KZG Library with the necessary functions to compute
* BLOb commitments and proofs.
*/
export interface KzgLibrary {
blobToKzgCommitment: (blob: Uint8Array) => Uint8Array;
computeBlobKzgProof: (blob: Uint8Array, commitment: Uint8Array) => Uint8Array;
} }
/** /**
* A **Transaction** describes an operation to be executed on * A **Transaction** describes an operation to be executed on
@ -171,10 +214,42 @@ export declare class Transaction implements TransactionLike<string> {
get maxFeePerBlobGas(): null | bigint; get maxFeePerBlobGas(): null | bigint;
set maxFeePerBlobGas(value: null | BigNumberish); set maxFeePerBlobGas(value: null | BigNumberish);
/** /**
* The BLOB versioned hashes for Cancun transactions. * The BLOb versioned hashes for Cancun transactions.
*/ */
get blobVersionedHashes(): null | Array<string>; get blobVersionedHashes(): null | Array<string>;
set blobVersionedHashes(value: null | Array<string>); set blobVersionedHashes(value: null | Array<string>);
/**
* The BLObs for the Transaction, if any.
*
* If ``blobs`` is non-``null``, then the [[seriailized]]
* will return the network formatted sidecar, otherwise it
* will return the standard [[link-eip-2718]] payload. The
* [[unsignedSerialized]] is unaffected regardless.
*
* When setting ``blobs``, either fully valid [[Blob]] objects
* may be specified (i.e. correctly padded, with correct
* committments and proofs) or a raw [[BytesLike]] may
* be provided.
*
* If raw [[BytesLike]] are provided, the [[kzg]] property **must**
* be already set. The blob will be correctly padded and the
* [[KzgLibrary]] will be used to compute the committment and
* proof for the blob.
*
* A BLOb is a sequence of field elements, each of which must
* be within the BLS field modulo, so some additional processing
* may be required to encode arbitrary data to ensure each 32 byte
* field is within the valid range.
*
* Setting this automatically populates [[blobVersionedHashes]],
* overwriting any existing values. Setting this to ``null``
* does **not** remove the [[blobVersionedHashes]], leaving them
* present.
*/
get blobs(): null | Array<Blob>;
set blobs(_blobs: null | Array<BlobLike>);
get kzg(): null | KzgLibrary;
set kzg(kzg: null | KzgLibrary);
/** /**
* Creates a new Transaction with default values. * Creates a new Transaction with default values.
*/ */

@ -1 +1 @@
{"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../../src.ts/transaction/transaction.ts"],"names":[],"mappings":"AAGA,OAAO,EAAa,SAAS,EAAc,MAAM,oBAAoB,CAAC;AAStE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,IAAI,IAAI,IAAI,CAAC,WAAW,GAAG;QAAE,IAAI,EAAE,CAAC,CAAC;QAAC,UAAU,EAAE,UAAU,CAAC;QAAC,YAAY,EAAE,MAAM,CAAC;QAAC,oBAAoB,EAAE,MAAM,CAAA;KAAE,CAAC;IAI3H;;;;;;OAMG;IACH,QAAQ,IAAI,IAAI,IAAI,CAAC,WAAW,GAAG;QAAE,IAAI,EAAE,CAAC,CAAC;QAAC,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,UAAU,CAAC;QAAC,YAAY,EAAE,MAAM,CAAC;QAAC,oBAAoB,EAAE,MAAM,CAAC;QAAC,gBAAgB,EAAE,MAAM,CAAC;QAAC,mBAAmB,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;KAAE,CAAC;IAIrM;;OAEG;IACH,KAAK,IAAI,WAAW;IAIpB;;OAEG;IACH,MAAM,IAAI,GAAG;IAuBb;;;OAGG;IACH,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC,GAAG,WAAW;CAqDlE"}

@ -13,6 +13,15 @@ const BN_27 = BigInt(27);
const BN_28 = BigInt(28); const BN_28 = BigInt(28);
const BN_35 = BigInt(35); const BN_35 = BigInt(35);
const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); const BN_MAX_UINT = BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");
const BLOB_SIZE = 4096 * 32;
function getVersionedHash(version, hash) {
let versioned = version.toString(16);
while (versioned.length < 2) {
versioned = "0" + versioned;
}
versioned += (0, index_js_2.sha256)(hash).substring(4);
return "0x" + versioned;
}
function handleAddress(value) { function handleAddress(value) {
if (value === "0x") { if (value === "0x") {
return null; return null;
@ -95,7 +104,7 @@ function _parseLegacy(data) {
s: (0, index_js_3.zeroPadValue)(fields[8], 32), s: (0, index_js_3.zeroPadValue)(fields[8], 32),
v v
}); });
tx.hash = (0, index_js_2.keccak256)(data); //tx.hash = keccak256(data);
} }
return tx; return tx;
} }
@ -186,7 +195,7 @@ function _parseEip1559(data) {
if (fields.length === 9) { if (fields.length === 9) {
return tx; return tx;
} }
tx.hash = (0, index_js_2.keccak256)(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(9)); _parseEipSignature(tx, fields.slice(9));
return tx; return tx;
} }
@ -227,7 +236,7 @@ function _parseEip2930(data) {
if (fields.length === 8) { if (fields.length === 8) {
return tx; return tx;
} }
tx.hash = (0, index_js_2.keccak256)(data); //tx.hash = keccak256(data);
_parseEipSignature(tx, fields.slice(8)); _parseEipSignature(tx, fields.slice(8));
return tx; return tx;
} }
@ -250,8 +259,29 @@ function _serializeEip2930(tx, sig) {
return (0, index_js_3.concat)(["0x01", (0, index_js_3.encodeRlp)(fields)]); return (0, index_js_3.concat)(["0x01", (0, index_js_3.encodeRlp)(fields)]);
} }
function _parseEip4844(data) { function _parseEip4844(data) {
const fields = (0, index_js_3.decodeRlp)((0, index_js_3.getBytes)(data).slice(1)); let fields = (0, index_js_3.decodeRlp)((0, index_js_3.getBytes)(data).slice(1));
(0, index_js_3.assertArgument)(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), "invalid field count for transaction type: 3", "data", (0, index_js_3.hexlify)(data)); let typeName = "3";
let blobs = null;
// Parse the network format
if (fields.length === 4 && Array.isArray(fields[0])) {
typeName = "3 (network format)";
const fBlobs = fields[1], fCommits = fields[2], fProofs = fields[3];
(0, index_js_3.assertArgument)(Array.isArray(fBlobs), "invalid network format: blobs not an array", "fields[1]", fBlobs);
(0, index_js_3.assertArgument)(Array.isArray(fCommits), "invalid network format: commitments not an array", "fields[2]", fCommits);
(0, index_js_3.assertArgument)(Array.isArray(fProofs), "invalid network format: proofs not an array", "fields[3]", fProofs);
(0, index_js_3.assertArgument)(fBlobs.length === fCommits.length, "invalid network format: blobs/commitments length mismatch", "fields", fields);
(0, index_js_3.assertArgument)(fBlobs.length === fProofs.length, "invalid network format: blobs/proofs length mismatch", "fields", fields);
blobs = [];
for (let i = 0; i < fields[1].length; i++) {
blobs.push({
data: fBlobs[i],
commitment: fCommits[i],
proof: fProofs[i],
});
}
fields = fields[0];
}
(0, index_js_3.assertArgument)(Array.isArray(fields) && (fields.length === 11 || fields.length === 14), `invalid field count for transaction type: ${typeName}`, "data", (0, index_js_3.hexlify)(data));
const tx = { const tx = {
type: 3, type: 3,
chainId: handleUint(fields[0], "chainId"), chainId: handleUint(fields[0], "chainId"),
@ -267,7 +297,10 @@ function _parseEip4844(data) {
maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"), maxFeePerBlobGas: handleUint(fields[9], "maxFeePerBlobGas"),
blobVersionedHashes: fields[10] blobVersionedHashes: fields[10]
}; };
(0, index_js_3.assertArgument)(tx.to != null, "invalid address for transaction type: 3", "data", data); if (blobs) {
tx.blobs = blobs;
}
(0, index_js_3.assertArgument)(tx.to != null, `invalid address for transaction type: ${typeName}`, "data", data);
(0, index_js_3.assertArgument)(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data); (0, index_js_3.assertArgument)(Array.isArray(tx.blobVersionedHashes), "invalid blobVersionedHashes: must be an array", "data", data);
for (let i = 0; i < tx.blobVersionedHashes.length; i++) { for (let i = 0; i < tx.blobVersionedHashes.length; i++) {
(0, index_js_3.assertArgument)((0, index_js_3.isHexString)(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data); (0, index_js_3.assertArgument)((0, index_js_3.isHexString)(tx.blobVersionedHashes[i], 32), `invalid blobVersionedHash at index ${i}: must be length 32`, "data", data);
@ -276,11 +309,13 @@ function _parseEip4844(data) {
if (fields.length === 11) { if (fields.length === 11) {
return tx; return tx;
} }
tx.hash = (0, index_js_2.keccak256)(data); // @TODO: Do we need to do this? This is only called internally
// and used to verify hashes; it might save time to not do this
//tx.hash = keccak256(concat([ "0x03", encodeRlp(fields) ]));
_parseEipSignature(tx, fields.slice(11)); _parseEipSignature(tx, fields.slice(11));
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig, blobs) {
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
@ -298,6 +333,18 @@ function _serializeEip4844(tx, sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
fields.push((0, index_js_3.toBeArray)(sig.r)); fields.push((0, index_js_3.toBeArray)(sig.r));
fields.push((0, index_js_3.toBeArray)(sig.s)); fields.push((0, index_js_3.toBeArray)(sig.s));
// We have blobs; return the network wrapped format
if (blobs) {
return (0, index_js_3.concat)([
"0x03",
(0, index_js_3.encodeRlp)([
fields,
blobs.map((b) => b.data),
blobs.map((b) => b.commitment),
blobs.map((b) => b.proof),
])
]);
}
} }
return (0, index_js_3.concat)(["0x03", (0, index_js_3.encodeRlp)(fields)]); return (0, index_js_3.concat)(["0x03", (0, index_js_3.encodeRlp)(fields)]);
} }
@ -329,6 +376,8 @@ class Transaction {
#accessList; #accessList;
#maxFeePerBlobGas; #maxFeePerBlobGas;
#blobVersionedHashes; #blobVersionedHashes;
#kzg;
#blobs;
/** /**
* The transaction type. * The transaction type.
* *
@ -510,7 +559,7 @@ class Transaction {
this.#maxFeePerBlobGas = (value == null) ? null : (0, index_js_3.getBigInt)(value, "maxFeePerBlobGas"); this.#maxFeePerBlobGas = (value == null) ? null : (0, index_js_3.getBigInt)(value, "maxFeePerBlobGas");
} }
/** /**
* The BLOB versioned hashes for Cancun transactions. * The BLOb versioned hashes for Cancun transactions.
*/ */
get blobVersionedHashes() { get blobVersionedHashes() {
// @TODO: Mutation is inconsistent; if unset, the returned value // @TODO: Mutation is inconsistent; if unset, the returned value
@ -531,6 +580,87 @@ class Transaction {
} }
this.#blobVersionedHashes = value; this.#blobVersionedHashes = value;
} }
/**
* The BLObs for the Transaction, if any.
*
* If ``blobs`` is non-``null``, then the [[seriailized]]
* will return the network formatted sidecar, otherwise it
* will return the standard [[link-eip-2718]] payload. The
* [[unsignedSerialized]] is unaffected regardless.
*
* When setting ``blobs``, either fully valid [[Blob]] objects
* may be specified (i.e. correctly padded, with correct
* committments and proofs) or a raw [[BytesLike]] may
* be provided.
*
* If raw [[BytesLike]] are provided, the [[kzg]] property **must**
* be already set. The blob will be correctly padded and the
* [[KzgLibrary]] will be used to compute the committment and
* proof for the blob.
*
* A BLOb is a sequence of field elements, each of which must
* be within the BLS field modulo, so some additional processing
* may be required to encode arbitrary data to ensure each 32 byte
* field is within the valid range.
*
* Setting this automatically populates [[blobVersionedHashes]],
* overwriting any existing values. Setting this to ``null``
* does **not** remove the [[blobVersionedHashes]], leaving them
* present.
*/
get blobs() {
if (this.#blobs == null) {
return null;
}
return this.#blobs.map((b) => Object.assign({}, b));
}
set blobs(_blobs) {
if (_blobs == null) {
this.#blobs = null;
return;
}
const blobs = [];
const versionedHashes = [];
for (let i = 0; i < _blobs.length; i++) {
const blob = _blobs[i];
if ((0, index_js_3.isBytesLike)(blob)) {
(0, index_js_3.assert)(this.#kzg, "adding a raw blob requires a KZG library", "UNSUPPORTED_OPERATION", {
operation: "set blobs()"
});
let data = (0, index_js_3.getBytes)(blob);
(0, index_js_3.assertArgument)(data.length <= BLOB_SIZE, "blob is too large", `blobs[${i}]`, blob);
// Pad blob if necessary
if (data.length !== BLOB_SIZE) {
const padded = new Uint8Array(BLOB_SIZE);
padded.set(data);
data = padded;
}
const commit = this.#kzg.blobToKzgCommitment(data);
const proof = (0, index_js_3.hexlify)(this.#kzg.computeBlobKzgProof(data, commit));
blobs.push({
data: (0, index_js_3.hexlify)(data),
commitment: (0, index_js_3.hexlify)(commit),
proof
});
versionedHashes.push(getVersionedHash(1, commit));
}
else {
const commit = (0, index_js_3.hexlify)(blob.commitment);
blobs.push({
data: (0, index_js_3.hexlify)(blob.data),
commitment: commit,
proof: (0, index_js_3.hexlify)(blob.proof)
});
versionedHashes.push(getVersionedHash(1, commit));
}
}
this.#blobs = blobs;
this.#blobVersionedHashes = versionedHashes;
}
get kzg() { return this.#kzg; }
set kzg(kzg) {
this.#kzg = kzg;
}
/** /**
* Creates a new Transaction with default values. * Creates a new Transaction with default values.
*/ */
@ -549,6 +679,8 @@ class Transaction {
this.#accessList = null; this.#accessList = null;
this.#maxFeePerBlobGas = null; this.#maxFeePerBlobGas = null;
this.#blobVersionedHashes = null; this.#blobVersionedHashes = null;
this.#blobs = null;
this.#kzg = null;
} }
/** /**
* The transaction hash, if signed. Otherwise, ``null``. * The transaction hash, if signed. Otherwise, ``null``.
@ -557,7 +689,7 @@ class Transaction {
if (this.signature == null) { if (this.signature == null) {
return null; return null;
} }
return (0, index_js_2.keccak256)(this.serialized); return (0, index_js_2.keccak256)(this.#getSerialized(true, false));
} }
/** /**
* The pre-image hash of this transaction. * The pre-image hash of this transaction.
@ -595,6 +727,21 @@ class Transaction {
isSigned() { isSigned() {
return this.signature != null; return this.signature != null;
} }
#getSerialized(signed, sidecar) {
(0, index_js_3.assert)(!signed || this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
const sig = signed ? this.signature : null;
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, sig);
case 1:
return _serializeEip2930(this, sig);
case 2:
return _serializeEip1559(this, sig);
case 3:
return _serializeEip4844(this, sig, sidecar ? this.blobs : null);
}
(0, index_js_3.assert)(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
}
/** /**
* The serialized transaction. * The serialized transaction.
* *
@ -602,18 +749,7 @@ class Transaction {
* use [[unsignedSerialized]]. * use [[unsignedSerialized]].
*/ */
get serialized() { get serialized() {
(0, index_js_3.assert)(this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" }); return this.#getSerialized(true, true);
switch (this.inferType()) {
case 0:
return _serializeLegacy(this, this.signature);
case 1:
return _serializeEip2930(this, this.signature);
case 2:
return _serializeEip1559(this, this.signature);
case 3:
return _serializeEip4844(this, this.signature);
}
(0, index_js_3.assert)(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
} }
/** /**
* The transaction pre-image. * The transaction pre-image.
@ -622,17 +758,7 @@ class Transaction {
* authorize this transaction. * authorize this transaction.
*/ */
get unsignedSerialized() { get unsignedSerialized() {
switch (this.inferType()) { return this.#getSerialized(false, false);
case 0:
return _serializeLegacy(this);
case 1:
return _serializeEip2930(this);
case 2:
return _serializeEip1559(this);
case 3:
return _serializeEip4844(this);
}
(0, index_js_3.assert)(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".unsignedSerialized" });
} }
/** /**
* Return the most "likely" type; currently the highest * Return the most "likely" type; currently the highest
@ -832,9 +958,18 @@ class Transaction {
if (tx.accessList != null) { if (tx.accessList != null) {
result.accessList = tx.accessList; result.accessList = tx.accessList;
} }
// This will get overwritten by blobs, if present
if (tx.blobVersionedHashes != null) { if (tx.blobVersionedHashes != null) {
result.blobVersionedHashes = tx.blobVersionedHashes; result.blobVersionedHashes = tx.blobVersionedHashes;
} }
// Make sure we assign the kzg before assigning blobs, which
// require the library in the event raw blob data is provided.
if (tx.kzg != null) {
result.kzg = tx.kzg;
}
if (tx.blobs != null) {
result.blobs = tx.blobs;
}
if (tx.hash != null) { if (tx.hash != null) {
(0, index_js_3.assertArgument)(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx); (0, index_js_3.assertArgument)(result.isSigned(), "unsigned transaction cannot define hash", "tx", tx);
(0, index_js_3.assertArgument)(result.hash === tx.hash, "hash mismatch", "tx", tx); (0, index_js_3.assertArgument)(result.hash === tx.hash, "hash mismatch", "tx", tx);

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../src.ts/utils/fetch.ts"],"names":[],"mappings":"AA2BA;;GAEG;AAC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AEG;IACH,IAAI,aAAa,IAAI,MAAM,CAAgC;IAE3D;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAA8C;IAEnF;;OAEG;IACH,IAAI,IAAI,IAAI,IAAI,GAAG,QAAQ,CAAC,UAAU,CAAC,CAEtC;IAED;;;;;OAKG;IACH,IAAI,QAAQ,IAAI,MAAM,CAQrB;IAED;;;;;OAKG;IACH,IAAI,QAAQ,IAAI,GAAG,CAQlB;IAED,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,CAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,CAAE,CAAC;gBAiBjD,UAAU,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,GAAG,UAAU,EAAE,OAAO,CAAC,EAAE,YAAY;IAajJ;;;;OAIG;IACH,eAAe,CAAC,OAAO,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK,GAAG,aAAa;IAc/D;;;;OAIG;IACH,kBAAkB,CAAC,OAAO,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,KAAK;IAc3D;;OAEG;IACH,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM;IAI9B;;OAEG;IACH,OAAO,IAAI,IAAI,IAAI,CAAC,aAAa,GAAG;QAAE,IAAI,EAAE,UAAU,CAAA;KAAE,CAAC;IAIzD;;OAEG;IACH,IAAI,OAAO,IAAI,IAAI,GAAG,YAAY,CAA0B;IAE5D;;OAEG;IACH,EAAE,IAAI,OAAO;IAIb;;OAEG;IACH,QAAQ,IAAI,IAAI;CAsBnB"}

@ -580,6 +580,7 @@ class FetchRequest {
clone.#preflight = this.#preflight; clone.#preflight = this.#preflight;
clone.#process = this.#process; clone.#process = this.#process;
clone.#retry = this.#retry; clone.#retry = this.#retry;
clone.#throttle = Object.assign({}, this.#throttle);
clone.#getUrlFunc = this.#getUrlFunc; clone.#getUrlFunc = this.#getUrlFunc;
return clone; return clone;
} }

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"version":3,"file":"create-provider.d.ts","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AA2FpD,wBAAgB,cAAc,IAAI,IAAI,CAKrC;AAED,eAAO,MAAM,aAAa,mBAAuD,CAAC;AAQlF,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAInE;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,gBAAgB,CAgBtF;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAGxE;AAED,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,CAIzD"} {"version":3,"file":"create-provider.d.ts","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAkGpD,wBAAgB,cAAc,IAAI,IAAI,CAKrC;AAED,eAAO,MAAM,aAAa,mBAAuD,CAAC;AAQlF,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAInE;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,gBAAgB,CAgBtF;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAGxE;AAED,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,CAIzD"}

@ -1,7 +1,7 @@
import { AlchemyProvider, import { AlchemyProvider,
// AnkrProvider, // AnkrProvider,
// CloudflareProvider, // CloudflareProvider,
EtherscanProvider, InfuraProvider, ChainstackProvider, EtherscanProvider, InfuraProvider,
// PocketProvider, // PocketProvider,
QuickNodeProvider, FallbackProvider, isError, } from "../index.js"; QuickNodeProvider, FallbackProvider, isError, } from "../index.js";
; ;
@ -33,6 +33,13 @@ const ProviderCreators = [
} }
}, },
*/ */
{
name: "ChainstackProvider",
networks: ["default", "mainnet", "arbitrum", "bnb", "matic"],
create: function (network) {
return new ChainstackProvider(network);
}
},
{ {
name: "EtherscanProvider", name: "EtherscanProvider",
networks: ethNetworks, networks: ethNetworks,
@ -136,7 +143,7 @@ export function getProvider(provider, network) {
} }
export function checkProvider(provider, network) { export function checkProvider(provider, network) {
const creator = getCreator(provider); const creator = getCreator(provider);
return (creator != null); return (creator != null && creator.networks.indexOf(network) >= 0);
} }
export function connect(network) { export function connect(network) {
const provider = getProvider("InfuraProvider", network); const provider = getProvider("InfuraProvider", network);

@ -1 +1 @@
{"version":3,"file":"create-provider.js","sourceRoot":"","sources":["../../src.ts/_tests/create-provider.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,eAAe;AACnB,mBAAmB;AACnB,yBAAyB;AACrB,iBAAiB,EACjB,cAAc;AAClB,qBAAqB;AACjB,iBAAiB,EAEjB,gBAAgB,EAChB,OAAO,GACV,MAAM,aAAa,CAAC;AAQpB,CAAC;AAEF,MAAM,WAAW,GAAG,CAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,CAAE,CAAC;AACvD,gDAAgD;AAEhD,MAAM,gBAAgB,GAA2B;IAC7C;QACI,IAAI,EAAE,iBAAiB;QACvB,QAAQ,EAAE,WAAW;QACrB,MAAM,EAAE,UAAS,OAAe;YAC5B,OAAO,IAAI,eAAe,CAAC,OAAO,EAAE,kCAAkC,CAAC,CAAC;QAC5E,CAAC;KAC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Ethers. * The current version of Ethers.
*/ */
export const version = "6.11.1"; export const version = "6.12.0";
//# sourceMappingURL=_version.js.map //# sourceMappingURL=_version.js.map

@ -18,19 +18,22 @@ export declare class Result extends Array<any> {
*/ */
constructor(...args: Array<any>); constructor(...args: Array<any>);
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray(): Array<any>; toArray(deep?: boolean): Array<any>;
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject(): Record<string, any>; toObject(deep?: boolean): Record<string, any>;
/** /**
* @_ignore * @_ignore
*/ */

@ -1 +1 @@
{"version":3,"file":"abstract-coder.d.ts","sourceRoot":"","sources":["../../../src.ts/abi/coders/abstract-coder.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEpE;;GAEG;AACH,eAAO,MAAM,QAAQ,EAAE,MAAW,CAAC;AAenC;;;;;;GAMG;AACH,qBAAa,MAAO,SAAQ,KAAK,CAAC,GAAG,CAAC;;IAGlC,CAAE,CAAC,EAAE,MAAM,GAAG,MAAM,GAAI,GAAG,CAAA;IAE3B;;OAEG;gBACS,GAAG,IAAI,EAAE,KAAK,CAAC,GAAG,CAAC;IAyF/B;;;;;OAKG;IACH,OAAO,IAAI,KAAK,CAAC,GAAG,CAAC;IASrB;;;;;OAKG;IACH,QAAQ,IAAI,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;IAe/B;;OAEG;IACH,KAAK,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,GAAG,CAAC,EAAE,MAAM,GAA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AQ,IAAI,MAAM,CAAyB;IAC/C,IAAI,KAAK,IAAI,UAAU,CAAuC;IAkC9D,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM;IAOjC,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,OAAO,GAAG,UAAU;IAStD,SAAS,IAAI,MAAM;IAInB,SAAS,IAAI,MAAM;CAGtB"}

@ -103,35 +103,45 @@ export class Result extends Array {
}); });
} }
/** /**
* Returns the Result as a normal Array. * Returns the Result as a normal Array. If %%deep%%, any children
* which are Result objects are also converted to a normal Array.
* *
* This will throw if there are any outstanding deferred * This will throw if there are any outstanding deferred
* errors. * errors.
*/ */
toArray() { toArray(deep) {
const result = []; const result = [];
this.forEach((item, index) => { this.forEach((item, index) => {
if (item instanceof Error) { if (item instanceof Error) {
throwError(`index ${index}`, item); throwError(`index ${index}`, item);
} }
if (deep && item instanceof Result) {
item = item.toArray(deep);
}
result.push(item); result.push(item);
}); });
return result; return result;
} }
/** /**
* Returns the Result as an Object with each name-value pair. * Returns the Result as an Object with each name-value pair. If
* %%deep%%, any children which are Result objects are also
* converted to an Object.
* *
* This will throw if any value is unnamed, or if there are * This will throw if any value is unnamed, or if there are
* any outstanding deferred errors. * any outstanding deferred errors.
*/ */
toObject() { toObject(deep) {
return this.#names.reduce((accum, name, index) => { return this.#names.reduce((accum, name, index) => {
assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", { assert(name != null, "value at index ${ index } unnamed", "UNSUPPORTED_OPERATION", {
operation: "toObject()" operation: "toObject()"
}); });
// Add values for names that don't conflict // Add values for names that don't conflict
if (!(name in accum)) { if (!(name in accum)) {
accum[name] = this.getValue(name); let child = this.getValue(name);
if (deep && child instanceof Result) {
child = child.toObject(deep);
}
accum[name] = child;
} }
return accum; return accum;
}, {}); }, {});

File diff suppressed because one or more lines are too long

4
lib.esm/ethers.d.ts vendored

@ -5,7 +5,7 @@ export { ZeroAddress, WeiPerEther, MaxUint256, MinInt256, MaxInt256, N, ZeroHash
export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js"; export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js";
export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js"; export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js";
export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js"; export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js";
export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js"; export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, ChainstackProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js";
export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js"; export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js";
export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js"; export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js";
export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js"; export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js";
@ -16,7 +16,7 @@ export type { ConstantContractMethod, ContractEvent, ContractEventArgs, Contract
export type { ProgressCallback, SignatureLike } from "./crypto/index.js"; export type { ProgressCallback, SignatureLike } from "./crypto/index.js";
export type { TypedDataDomain, TypedDataField } from "./hash/index.js"; export type { TypedDataDomain, TypedDataField } from "./hash/index.js";
export type { Provider, Signer, AbstractProviderOptions, FallbackProviderOptions, AbstractProviderPlugin, BlockParams, BlockTag, ContractRunner, DebugEventBrowserProvider, Eip1193Provider, EventFilter, Filter, FilterByBlockHash, GasCostParameters, JsonRpcApiProviderOptions, JsonRpcError, JsonRpcPayload, JsonRpcResult, JsonRpcTransactionRequest, LogParams, MinedBlock, MinedTransactionResponse, Networkish, OrphanFilter, PerformActionFilter, PerformActionRequest, PerformActionTransaction, PreparedTransactionRequest, ProviderEvent, Subscriber, Subscription, TopicFilter, TransactionReceiptParams, TransactionRequest, TransactionResponseParams, WebSocketCreator, WebSocketLike } from "./providers/index.js"; export type { Provider, Signer, AbstractProviderOptions, FallbackProviderOptions, AbstractProviderPlugin, BlockParams, BlockTag, ContractRunner, DebugEventBrowserProvider, Eip1193Provider, EventFilter, Filter, FilterByBlockHash, GasCostParameters, JsonRpcApiProviderOptions, JsonRpcError, JsonRpcPayload, JsonRpcResult, JsonRpcTransactionRequest, LogParams, MinedBlock, MinedTransactionResponse, Networkish, OrphanFilter, PerformActionFilter, PerformActionRequest, PerformActionTransaction, PreparedTransactionRequest, ProviderEvent, Subscriber, Subscription, TopicFilter, TransactionReceiptParams, TransactionRequest, TransactionResponseParams, WebSocketCreator, WebSocketLike } from "./providers/index.js";
export type { AccessList, AccessListish, AccessListEntry, TransactionLike } from "./transaction/index.js"; export type { AccessList, AccessListish, AccessListEntry, Blob, BlobLike, KzgLibrary, TransactionLike } from "./transaction/index.js";
export type { BytesLike, BigNumberish, Numeric, ErrorCode, FixedFormat, Utf8ErrorFunc, UnicodeNormalizationForm, Utf8ErrorReason, RlpStructuredData, RlpStructuredDataish, GetUrlResponse, FetchPreflightFunc, FetchProcessFunc, FetchRetryFunc, FetchGatewayFunc, FetchGetUrlFunc, EthersError, UnknownError, NotImplementedError, UnsupportedOperationError, NetworkError, ServerError, TimeoutError, BadDataError, CancelledError, BufferOverrunError, NumericFaultError, InvalidArgumentError, MissingArgumentError, UnexpectedArgumentError, CallExceptionError, InsufficientFundsError, NonceExpiredError, OffchainFaultError, ReplacementUnderpricedError, TransactionReplacedError, UnconfiguredNameError, ActionRejectedError, CodedEthersError, CallExceptionAction, CallExceptionTransaction, EventEmitterable, Listener } from "./utils/index.js"; export type { BytesLike, BigNumberish, Numeric, ErrorCode, FixedFormat, Utf8ErrorFunc, UnicodeNormalizationForm, Utf8ErrorReason, RlpStructuredData, RlpStructuredDataish, GetUrlResponse, FetchPreflightFunc, FetchProcessFunc, FetchRetryFunc, FetchGatewayFunc, FetchGetUrlFunc, EthersError, UnknownError, NotImplementedError, UnsupportedOperationError, NetworkError, ServerError, TimeoutError, BadDataError, CancelledError, BufferOverrunError, NumericFaultError, InvalidArgumentError, MissingArgumentError, UnexpectedArgumentError, CallExceptionError, InsufficientFundsError, NonceExpiredError, OffchainFaultError, ReplacementUnderpricedError, TransactionReplacedError, UnconfiguredNameError, ActionRejectedError, CodedEthersError, CallExceptionAction, CallExceptionTransaction, EventEmitterable, Listener } from "./utils/index.js";
export type { CrowdsaleAccount, KeystoreAccount, EncryptOptions } from "./wallet/index.js"; export type { CrowdsaleAccount, KeystoreAccount, EncryptOptions } from "./wallet/index.js";
//# sourceMappingURL=ethers.d.ts.map //# sourceMappingURL=ethers.d.ts.map

@ -1 +1 @@
{"version":3,"file":"ethers.d.ts","sourceRoot":"","sources":["../src.ts/ethers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,OAAO,EACH,mBAAmB,EAAE,mBAAmB,EAExC,QAAQ,EACR,mBAAmB,EAAE,aAAa,EAAE,aAAa,EAAE,QAAQ,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,EAAE,SAAS,EAAE,cAAc,EAEzI,iBAAiB,EAAE,gBAAgB,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,EAAE,sBAAsB,EACvG,KAAK,GACR,MAAM,gBAAgB,CAAC;AAExB,OAAO,EACH,UAAU,EAAE,cAAc,EAC1B,gBAAgB,EAAE,iBAAiB,EACnC,aAAa,EAAE,SAAS,EAAE,cAAc,EAC3C,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACH,WAAW,EACX,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC,EAChD,QAAQ,EACR,WAAW,EAAE,aAAa,EAC7B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACH,YAAY,EAAE,QAAQ,EACtB,eAAe,EACf,oBAAoB,EAAE,0BAA0B,EAAE,2BAA2B,EAAE,2BAA2B,EAAE,QAAQ,EAAE,iBAAiB,EAC1I,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EACH,WAAW,EACX,WAAW,EACX,SAAS,EACT,SAAS,EACT,MAAM,EAAE,MAAM,EACd,MAAM,EACN,MAAM,EAAE,UAAU,EAClB,IAAI,EACJ,SAAS,EAAE,UAAU,EACxB,MAA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B,EAAE,eAAe,EAAE,cAAc,EACpD,MAAM,mBAAmB,CAAC"}

@ -7,7 +7,7 @@ export { ZeroAddress, WeiPerEther, MaxUint256, MinInt256, MaxInt256, N, ZeroHash
export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js"; export { BaseContract, Contract, ContractFactory, ContractEventPayload, ContractTransactionReceipt, ContractTransactionResponse, ContractUnknownEventPayload, EventLog, UndecodedEventLog } from "./contract/index.js";
export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js"; export { computeHmac, randomBytes, keccak256, ripemd160, sha256, sha512, pbkdf2, scrypt, scryptSync, lock, Signature, SigningKey } from "./crypto/index.js";
export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js"; export { id, ensNormalize, isValidName, namehash, dnsEncode, hashMessage, verifyMessage, solidityPacked, solidityPackedKeccak256, solidityPackedSha256, TypedDataEncoder, verifyTypedData } from "./hash/index.js";
export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js"; export { getDefaultProvider, Block, FeeData, Log, TransactionReceipt, TransactionResponse, AbstractSigner, NonceManager, VoidSigner, AbstractProvider, FallbackProvider, JsonRpcApiProvider, JsonRpcProvider, JsonRpcSigner, BrowserProvider, AlchemyProvider, AnkrProvider, ChainstackProvider, CloudflareProvider, EtherscanProvider, InfuraProvider, InfuraWebSocketProvider, PocketProvider, QuickNodeProvider, IpcSocketProvider, SocketProvider, WebSocketProvider, EnsResolver, Network, EnsPlugin, EtherscanPlugin, FeeDataNetworkPlugin, FetchUrlFeeDataNetworkPlugin, GasCostPlugin, NetworkPlugin, MulticoinProviderPlugin, SocketBlockSubscriber, SocketEventSubscriber, SocketPendingSubscriber, SocketSubscriber, UnmanagedSubscriber, copyRequest, showThrottleMessage } from "./providers/index.js";
export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js"; export { accessListify, computeAddress, recoverAddress, Transaction } from "./transaction/index.js";
export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js"; export { decodeBase58, encodeBase58, decodeBase64, encodeBase64, concat, dataLength, dataSlice, getBytes, getBytesCopy, hexlify, isHexString, isBytesLike, stripZerosLeft, zeroPadBytes, zeroPadValue, defineProperties, resolveProperties, assert, assertArgument, assertArgumentCount, assertNormalize, assertPrivate, makeError, isCallException, isError, EventPayload, FetchRequest, FetchResponse, FetchCancelSignal, FixedNumber, getBigInt, getNumber, getUint, toBeArray, toBigInt, toBeHex, toNumber, toQuantity, fromTwos, toTwos, mask, formatEther, parseEther, formatUnits, parseUnits, toUtf8Bytes, toUtf8CodePoints, toUtf8String, Utf8ErrorFuncs, decodeRlp, encodeRlp, uuidV4, } from "./utils/index.js";
export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js"; export { Mnemonic, BaseWallet, HDNodeWallet, HDNodeVoidWallet, Wallet, defaultPath, getAccountPath, getIndexedAccountPath, isCrowdsaleJson, isKeystoreJson, decryptCrowdsaleJson, decryptKeystoreJsonSync, decryptKeystoreJson, encryptKeystoreJson, encryptKeystoreJsonSync, } from "./wallet/index.js";

@ -1 +1 @@
{"version":3,"file":"ethers.js","sourceRoot":"","sources":["../src.ts/ethers.ts"],"names":[],"mappings":"AAEA,6BAA6B;AAC7B,EAAE;AAEF,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,OAAO,EACH,mBAAmB,EAAE,mBAAmB,EAExC,QAAQ,EACR,mBAAmB,EAAE,aAAa,EAAE,aAAa,EAAE,QAAQ,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,EAAE,SAAS,EAAE,cAAc,EAEzI,iBAAiB,EAAE,gBAAgB,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,EAAE,sBAAsB,EACvG,KAAK,GACR,MAAM,gBAAgB,CAAC;AAExB,OAAO,EACH,UAAU,EAAE,cAAc,EAC1B,gBAAgB,EAAE,iBAAiB,EACnC,aAAa,EAAE,SAAS,EAAE,cAAc,EAC3C,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACH,WAAW,EACX,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC,EACh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AAE1B,OAAO,EACH,QAAQ,EACR,UAAU,EAAE,YAAY,EAAE,gBAAgB,EAC1C,MAAM,EAEN,WAAW,EAEX,cAAc,EAAE,qBAAqB,EACrC,eAAe,EAAE,cAAc,EAE/B,oBAAoB,EAAE,uBAAuB,EAAE,mBAAmB,EAClE,mBAAmB,EAAE,uBAAuB,GAC/C,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACH,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,YAAY,EAAE,SAAS,EACzD,MAAM,sBAAsB,CAAC"}

@ -149,8 +149,8 @@ export class AbstractSigner {
}); });
} }
} }
else if (pop.type === 2) { else if (pop.type === 2 || pop.type === 3) {
// Explicitly using EIP-1559 // Explicitly using EIP-1559 or EIP-4844
// Populate missing fee data // Populate missing fee data
if (pop.maxFeePerGas == null) { if (pop.maxFeePerGas == null) {
pop.maxFeePerGas = feeData.maxFeePerGas; pop.maxFeePerGas = feeData.maxFeePerGas;

File diff suppressed because one or more lines are too long

@ -24,6 +24,7 @@ import { WebSocketLike } from "./provider-websocket.js";
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``

@ -1 +1 @@
{"version":3,"file":"default-provider.d.ts","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AASxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,UAAU,GAAG,aAAa,EAAE,OAAO,CAAC,EAAE,GAAG,GAAG,gBAAgB,CAkHjH"} {"version":3,"file":"default-provider.d.ts","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AASxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,UAAU,GAAG,aAAa,EAAE,OAAO,CAAC,EAAE,GAAG,GAAG,gBAAgB,CA0HjH"}

@ -1,6 +1,7 @@
import { assert } from "../utils/index.js"; import { assert } from "../utils/index.js";
import { AnkrProvider } from "./provider-ankr.js"; import { AnkrProvider } from "./provider-ankr.js";
import { AlchemyProvider } from "./provider-alchemy.js"; import { AlchemyProvider } from "./provider-alchemy.js";
import { ChainstackProvider } from "./provider-chainstack.js";
import { CloudflareProvider } from "./provider-cloudflare.js"; import { CloudflareProvider } from "./provider-cloudflare.js";
import { EtherscanProvider } from "./provider-etherscan.js"; import { EtherscanProvider } from "./provider-etherscan.js";
import { InfuraProvider } from "./provider-infura.js"; import { InfuraProvider } from "./provider-infura.js";
@ -38,6 +39,7 @@ const Testnets = "goerli kovan sepolia classicKotti optimism-goerli arbitrum-goe
* - ``"alchemy"`` * - ``"alchemy"``
* - ``"ankr"`` * - ``"ankr"``
* - ``"cloudflare"`` * - ``"cloudflare"``
* - ``"chainstack"``
* - ``"etherscan"`` * - ``"etherscan"``
* - ``"infura"`` * - ``"infura"``
* - ``"publicPolygon"`` * - ``"publicPolygon"``
@ -91,6 +93,9 @@ export function getDefaultProvider(network, options) {
if (staticNetwork.name === "matic") { if (staticNetwork.name === "matic") {
providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork })); providers.push(new JsonRpcProvider("https:/\/polygon-rpc.com/", staticNetwork, { staticNetwork }));
} }
else if (staticNetwork.name === "matic-amoy") {
providers.push(new JsonRpcProvider("https:/\/rpc-amoy.polygon.technology/", staticNetwork, { staticNetwork }));
}
} }
if (allowService("alchemy")) { if (allowService("alchemy")) {
try { try {
@ -104,6 +109,12 @@ export function getDefaultProvider(network, options) {
} }
catch (error) { } catch (error) { }
} }
if (allowService("chainstack")) {
try {
providers.push(new ChainstackProvider(network, options.chainstack));
}
catch (error) { }
}
if (allowService("cloudflare")) { if (allowService("cloudflare")) {
try { try {
providers.push(new CloudflareProvider(network)); providers.push(new CloudflareProvider(network));

@ -1 +1 @@
{"version":3,"file":"default-provider.js","sourceRoot":"","sources":["../../src.ts/providers/default-provider.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAE3C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,wDAAwD;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAM5D,SAAS,eAAe,CAAC,KAAU;IAC/B,OAAO,CAAC,KAAK,IAAI,OAAM,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,UAAU;QA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CAAC;KAAE;IAEjF,yCAAyC;IACzC,IAAI,OAAO,IAAI,OAAO,CAAC,MAAM,EAAE;QAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;KAAE;IAE3D,OAAO,IAAI,gBAAgB,CAAC,SAAS,EAAE,SAAS,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;AAClE,CAAC"}

@ -24,6 +24,7 @@ export { BrowserProvider } from "./provider-browser.js";
export { AlchemyProvider } from "./provider-alchemy.js"; export { AlchemyProvider } from "./provider-alchemy.js";
export { AnkrProvider } from "./provider-ankr.js"; export { AnkrProvider } from "./provider-ankr.js";
export { CloudflareProvider } from "./provider-cloudflare.js"; export { CloudflareProvider } from "./provider-cloudflare.js";
export { ChainstackProvider } from "./provider-chainstack.js";
export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js"; export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js";
export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js"; export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js";
export { PocketProvider } from "./provider-pocket.js"; export { PocketProvider } from "./provider-pocket.js";

@ -1 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src.ts/providers/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,EACH,gBAAgB,EAAE,mBAAmB,EACxC,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACH,cAAc,EACd,UAAU,GACb,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACH,mBAAmB,EACtB,MAAM,gBAAgB,CAAC;AAExB,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAE3D,OAAO,EACH,WAAW,EACX,uBAAuB,EAC1B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAExD,OAAO,EACH,aAAa,EACb,a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,GACtE,MAAM,wBAAwB,CAAA;AAE/B,YAAY,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAErD,YAAY,EACR,WAAW,EAAE,SAAS,EAAE,wBAAwB,EAChD,yBAAyB,GAC5B,MAAM,iBAAiB,CAAC;AAWzB,YAAY,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE/C,YAAY,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D,YAAY,EACR,QAAQ,EACR,kBAAkB,EAAE,0BAA0B,EAC9C,WAAW,EAAE,MAAM,EAAE,iBAAiB,EAAE,YAAY,EAAE,aAAa,EACnE,WAAW,EACX,QAAQ,EACR,UAAU,EAAE,wBAAwB,EACvC,MAAM,eAAe,CAAC;AAEvB,YAAY,EACR,yBAAyB,EAAE,eAAe,EAC7C,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AAEtE,YAAY,EACR,cAAc,EAAE,aAAa,EAAE,YAAY,EAC3C,yBAAyB,EACzB,yBAAyB,GAC5B,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EACR,gBAAgB,EAAE,aAAa,EAClC,MAAM,yBAAyB,CAAC;AAEjC,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC"}

@ -26,6 +26,7 @@ export { BrowserProvider } from "./provider-browser.js";
export { AlchemyProvider } from "./provider-alchemy.js"; export { AlchemyProvider } from "./provider-alchemy.js";
export { AnkrProvider } from "./provider-ankr.js"; export { AnkrProvider } from "./provider-ankr.js";
export { CloudflareProvider } from "./provider-cloudflare.js"; export { CloudflareProvider } from "./provider-cloudflare.js";
export { ChainstackProvider } from "./provider-chainstack.js";
export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js"; export { EtherscanProvider, EtherscanPlugin } from "./provider-etherscan.js";
export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js"; export { InfuraProvider, InfuraWebSocketProvider } from "./provider-infura.js";
export { PocketProvider } from "./provider-pocket.js"; export { PocketProvider } from "./provider-pocket.js";

@ -1 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src.ts/providers/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,EACH,gBAAgB,EAAE,mBAAmB,EACxC,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACH,cAAc,EACd,UAAU,GACb,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACH,mBAAmB,EACtB,MAAM,gBAAgB,CAAC;AAExB,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAE3D,OAAO,EACH,WAAW,EACX,uBAAuB,EAC1B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAExD,OAAO,EACH,aAAa,EACb,aAAa,EACb,SAAS,EACT,oBAAoB,EACpB,4BAA4B,GAC/B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACH,KAAK,EACL,OAAO,EACP,GAAG,EACH,kBAAkB,EAClB,mBAAmB,EAEnB,WAAW;AACX,4BAA4B;EAC/B,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAE1F,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC7E,OAAO,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,sB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E,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAE1F,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC7E,OAAO,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC/E,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC,CAAC,YAAY;AACzE,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,OAAO,EACH,gBAAgB,EAAE,qBAAqB,EAAE,uBAAuB,EAChE,qBAAqB,EACxB,MAAM,sBAAsB,CAAC"}

@ -344,6 +344,7 @@ function injectCommonNetworks() {
getGasStationPlugin("https:/\/gasstation.polygon.technology/v2") getGasStationPlugin("https:/\/gasstation.polygon.technology/v2")
] ]
}); });
registerEth("matic-amoy", 80002, {});
registerEth("matic-mumbai", 80001, { registerEth("matic-mumbai", 80001, {
altNames: ["maticMumbai", "maticmum"], altNames: ["maticMumbai", "maticmum"],
plugins: [ plugins: [

File diff suppressed because one or more lines are too long

@ -17,6 +17,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]

@ -1 +1 @@
{"version":3,"file":"provider-alchemy.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAEH,YAAY,EACf,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAyC/C;;;;;;;;;;GAUG;AACH,qBAAa,eAAgB,SAAQ,eAAgB,YAAW,oBAAoB;IAChF,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;gBAEb,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAWzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAOzC,QAAQ,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,GAAG,CAAC;IAmCvD,mBAAmB,IAAI,OAAO;IAI9B,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,YAAY;CAerE"} {"version":3,"file":"provider-alchemy.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,EAEH,YAAY,EACf,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AA2C/C;;;;;;;;;;GAUG;AACH,qBAAa,eAAgB,SAAQ,eAAgB,YAAW,oBAAoB;IAChF,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;gBAEb,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAWzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAOzC,QAAQ,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,GAAG,CAAC;IAmCvD,mBAAmB,IAAI,OAAO;IAI9B,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,YAAY;CAerE"}

@ -17,6 +17,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy] * @_subsection: api/providers/thirdparty:Alchemy [providers-alchemy]
@ -48,6 +49,8 @@ function getHost(name) {
return "base-sepolia.g.alchemy.com"; return "base-sepolia.g.alchemy.com";
case "matic": case "matic":
return "polygon-mainnet.g.alchemy.com"; return "polygon-mainnet.g.alchemy.com";
case "matic-amoy":
return "polygon-amoy.g.alchemy.com";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.g.alchemy.com"; return "polygon-mumbai.g.alchemy.com";
case "optimism": case "optimism":

@ -1 +1 @@
{"version":3,"file":"provider-alchemy.js","sourceRoot":"","sources":["../../src.ts/providers/provider-alchemy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EACH,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,EAAE,cAAc,EAC3D,YAAY,EACf,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAOxD,MAAM,aAAa,GAAG,kCAAkC,CAAA;AAExD,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QACvC,KAAK,QAAQ;YACT,OAAO,0BAA0B,CAAC;QACtC,KAAK,SAAS;YACV,OAAO,2BAA2B,CAAC;QAEvC,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB,OAAO,0BAA0B,CAAC;QACtC,KAAK,kBAAkB;YACnB,OAAO,2BAA2B,CAAC;QACvC,KAAK,MAAM;YACP,OAAO,4BAA4B,CAAC;QACxC,KAAK,aAAa;YACd,OAAO,2BAA2B,CAAC;QACvC,KAAK,cAAc;YACf,OAAO,4BAA4B,CAAC;QACxC,KAAK,OAAO;YACR,OAAO,+BAA+B,CAAC;QAC3C,KAAK,cAAc;YACf,OAAO,8BAA8B,CAAC;QAC1C,KAAK,UAAU;YACX,OAAO,2BAA2B,CAAC;QACvC,KAAK,iBAAiB;YAClB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GAAG,IAAI,YAAY,CAAC,YAAa,OAAO,CAAC,OAAO,CAAC,IAAI,CAAE,OAAQ,MAAO,EAAE,CAAC,CAAC;QACvF,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC;QAEzB,IAAI,MAAM,KAAK,aAAa,EAAE;YAC1B,OAAO,CAAC,SAAS,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE;gBACrD,mBAAmB,CAAC,SAAS,CAAC,CAAC;gBAC/B,OAAO,IAAI,CAAC;YAChB,CAAC,CAAA;SACJ;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ"}

@ -0,0 +1,46 @@
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
import { FetchRequest } from "../utils/index.js";
import { Network } from "./network.js";
import { JsonRpcProvider } from "./provider-jsonrpc.js";
import type { AbstractProvider } from "./abstract-provider.js";
import type { CommunityResourcable } from "./community.js";
import type { Networkish } from "./network.js";
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
export declare class ChainstackProvider extends JsonRpcProvider implements CommunityResourcable {
/**
* The API key for the Chainstack connection.
*/
readonly apiKey: string;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network?: Networkish, apiKey?: null | string);
_getProvider(chainId: number): AbstractProvider;
isCommunityResource(): boolean;
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network: Network, apiKey?: null | string): FetchRequest;
}
//# sourceMappingURL=provider-chainstack.d.ts.map

@ -0,0 +1 @@
{"version":3,"file":"provider-chainstack.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-chainstack.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,EACe,YAAY,EACjC,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AA6B/C;;;;;;;;GAQG;AACH,qBAAa,kBAAmB,SAAQ,eAAgB,YAAW,oBAAoB;IACnF;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAG,MAAM,CAAC;IAEzB;;OAEG;gBACS,QAAQ,CAAC,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM;IAYzD,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAO/C,mBAAmB,IAAI,OAAO;IAI9B;;;OAGG;IACH,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,YAAY;CAe5E"}

@ -0,0 +1,98 @@
/**
* [[link-chainstack]] provides a third-party service for connecting to
* various blockchains over JSON-RPC.
*
* **Supported Networks**
*
* - Ethereum Mainnet (``mainnet``)
* - Arbitrum (``arbitrum``)
* - BNB Smart Chain Mainnet (``bnb``)
* - Polygon (``matic``)
*
* @_subsection: api/providers/thirdparty:Chainstack [providers-chainstack]
*/
import { defineProperties, FetchRequest, assertArgument } from "../utils/index.js";
import { showThrottleMessage } from "./community.js";
import { Network } from "./network.js";
import { JsonRpcProvider } from "./provider-jsonrpc.js";
function getApiKey(name) {
switch (name) {
case "mainnet": return "39f1d67cedf8b7831010a665328c9197";
case "arbitrum": return "0550c209db33c3abf4cc927e1e18cea1";
case "bnb": return "98b5a77e531614387366f6fc5da097f8";
case "matic": return "cd9d4d70377471aa7c142ec4a4205249";
}
assertArgument(false, "unsupported network", "network", name);
}
function getHost(name) {
switch (name) {
case "mainnet":
return "ethereum-mainnet.core.chainstack.com";
case "arbitrum":
return "arbitrum-mainnet.core.chainstack.com";
case "bnb":
return "bsc-mainnet.core.chainstack.com";
case "matic":
return "polygon-mainnet.core.chainstack.com";
}
assertArgument(false, "unsupported network", "network", name);
}
/**
* The **ChainstackProvider** connects to the [[link-chainstack]]
* JSON-RPC end-points.
*
* By default, a highly-throttled API key is used, which is
* appropriate for quick prototypes and simple scripts. To
* gain access to an increased rate-limit, it is highly
* recommended to [sign up here](link-chainstack).
*/
export class ChainstackProvider extends JsonRpcProvider {
/**
* The API key for the Chainstack connection.
*/
apiKey;
/**
* Creates a new **ChainstackProvider**.
*/
constructor(_network, apiKey) {
if (_network == null) {
_network = "mainnet";
}
const network = Network.from(_network);
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = ChainstackProvider.getRequest(network, apiKey);
super(request, network, { staticNetwork: network });
defineProperties(this, { apiKey });
}
_getProvider(chainId) {
try {
return new ChainstackProvider(chainId, this.apiKey);
}
catch (error) { }
return super._getProvider(chainId);
}
isCommunityResource() {
return (this.apiKey === getApiKey(this._network.name));
}
/**
* Returns a prepared request for connecting to %%network%%
* with %%apiKey%% and %%projectSecret%%.
*/
static getRequest(network, apiKey) {
if (apiKey == null) {
apiKey = getApiKey(network.name);
}
const request = new FetchRequest(`https:/\/${getHost(network.name)}/${apiKey}`);
request.allowGzip = true;
if (apiKey === getApiKey(network.name)) {
request.retryFunc = async (request, response, attempt) => {
showThrottleMessage("ChainstackProvider");
return true;
};
}
return request;
}
}
//# sourceMappingURL=provider-chainstack.js.map

@ -0,0 +1 @@
{"version":3,"file":"provider-chainstack.js","sourceRoot":"","sources":["../../src.ts/providers/provider-chain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C,CAAC;SACL;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ"}

@ -21,6 +21,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]

@ -1 +1 @@
{"version":3,"file":"provider-infura.d.ts","sourceRoot":"","sources":["../../src.ts/providers/provider-infura.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EACe,YAAY,EACjC,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAiD/C;;;;;;;;GAQG;AACH,qBAAa,uBAAwB,SAAQ,iBAAkB,YAAW,oBAAoB;IAE1F;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM;IAgBpD,mBAAmB,IAAI,OAAO;CAGjC;AAED;;;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AAkB,YAAW,oBAAoB;IAE1F;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM;IAgBpD,mBAAmB,IAAI,OAAO;CAGjC;AAED;;;;;;;;GAQG;AACH,qBAAa,cAAe,SAAQ,eAAgB,YAAW,oBAAoB;IAC/E;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAG,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAG,IAAI,GAAG,MAAM,CAAC;IAEvC;;OAEG;gBACS,QAAQ,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,EAAE,aAAa,CAAC,EAAE,IAAI,GAAG,MAAM;IAY3F,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB;IAO/C,mBAAmB,IAAI,OAAO;IAI9B;;OAEG;IACH,MAAM,CAAC,oBAAoB,CAAC,OAAO,CAAC,EAAE,UAAU,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,uBAAuB;IAI9F;;;OAGG;IACH,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,EAAE,aAAa,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,YAAY;CAiB9G"}

@ -21,6 +21,7 @@
* - Optimism Goerli Testnet (``optimism-goerli``) * - Optimism Goerli Testnet (``optimism-goerli``)
* - Optimism Sepolia Testnet (``optimism-sepolia``) * - Optimism Sepolia Testnet (``optimism-sepolia``)
* - Polygon (``matic``) * - Polygon (``matic``)
* - Polygon Amoy Testnet (``matic-amoy``)
* - Polygon Mumbai Testnet (``matic-mumbai``) * - Polygon Mumbai Testnet (``matic-mumbai``)
* *
* @_subsection: api/providers/thirdparty:INFURA [providers-infura] * @_subsection: api/providers/thirdparty:INFURA [providers-infura]
@ -61,6 +62,8 @@ function getHost(name) {
return "linea-goerli.infura.io"; return "linea-goerli.infura.io";
case "matic": case "matic":
return "polygon-mainnet.infura.io"; return "polygon-mainnet.infura.io";
case "matic-amoy":
return "polygon-amoy.infura.io";
case "matic-mumbai": case "matic-mumbai":
return "polygon-mumbai.infura.io"; return "polygon-mumbai.infura.io";
case "optimism": case "optimism":

@ -1 +1 @@
{"version":3,"file":"provider-infura.js","sourceRoot":"","sources":["../../src.ts/providers/provider-infura.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EACH,gBAAgB,EAAE,YAAY,EAAE,MAAM,EAAE,cAAc,EACzD,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAO5D,MAAM,gBAAgB,GAAG,kCAAkC,CAAC;AAE5D,SAAS,OAAO,CAAC,IAAY;IACzB,QAAO,IAAI,EAAE;QACT,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAC/B,KAAK,QAAQ;YACT,OAAO,kBAAkB,CAAC;QAC9B,KAAK,SAAS;YACV,OAAO,mBAAmB,CAAC;QAE/B,KAAK,UAAU;YACX,OAAO,4BAA4B,CAAC;QACxC,KAAK,iBAAiB;YAClB,OAAO,2BAA2B,CAAC;QACvC,KAAK,kBAAkB;YACnB,OAAO,4BAA4B,CAAC;QACxC,KAAK,MAAM;YACP,OAAO,wBAAwB,CAAC;QACpC,KAAK,cAAc;YACf,OAAO,uBAAuB,CAAC;QACnC,KAAK,cAAc;YACf,OAAO,wBAAwB,CAAC;QACpC,KAAK,KAAK;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CAAC,CAAC;SACL;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ"}

@ -1,7 +1,7 @@
import type { AddressLike, NameResolver } from "../address/index.js"; import type { AddressLike, NameResolver } from "../address/index.js";
import type { BigNumberish, EventEmitterable } from "../utils/index.js"; import type { BigNumberish, EventEmitterable } from "../utils/index.js";
import type { Signature } from "../crypto/index.js"; import type { Signature } from "../crypto/index.js";
import type { AccessList, AccessListish, TransactionLike } from "../transaction/index.js"; import type { AccessList, AccessListish, BlobLike, KzgLibrary, TransactionLike } from "../transaction/index.js";
import type { ContractRunner } from "./contracts.js"; import type { ContractRunner } from "./contracts.js";
import type { Network } from "./network.js"; import type { Network } from "./network.js";
/** /**
@ -144,6 +144,26 @@ export interface TransactionRequest {
* the fetch to unexpected parties. * the fetch to unexpected parties.
*/ */
enableCcipRead?: boolean; enableCcipRead?: boolean;
/**
* The blob versioned hashes (see [[link-eip-4844]]).
*/
blobVersionedHashes?: null | Array<string>;
/**
* The maximum fee per blob gas (see [[link-eip-4844]]).
*/
maxFeePerBlobGas?: null | BigNumberish;
/**
* Any blobs to include in the transaction (see [[link-eip-4844]]).
*/
blobs?: null | Array<BlobLike>;
/**
* An external library for computing the KZG commitments and
* proofs necessary for EIP-4844 transactions (see [[link-eip-4844]]).
*
* This is generally ``null``, unless you are creating BLOb
* transactions.
*/
kzg?: null | KzgLibrary;
} }
/** /**
* A **PreparedTransactionRequest** is identical to a [[TransactionRequest]] * A **PreparedTransactionRequest** is identical to a [[TransactionRequest]]

File diff suppressed because one or more lines are too long

@ -1,5 +1,5 @@
//import { resolveAddress } from "@ethersproject/address"; //import { resolveAddress } from "@ethersproject/address";
import { defineProperties, getBigInt, getNumber, hexlify, resolveProperties, assert, assertArgument, isError, makeError } from "../utils/index.js"; import { defineProperties, getBigInt, getNumber, hexlify, isBytesLike, resolveProperties, assert, assertArgument, isError, makeError } from "../utils/index.js";
import { accessListify } from "../transaction/index.js"; import { accessListify } from "../transaction/index.js";
const BN_0 = BigInt(0); const BN_0 = BigInt(0);
// ----------------------- // -----------------------
@ -89,7 +89,7 @@ export function copyRequest(req) {
if (req.data) { if (req.data) {
result.data = hexlify(req.data); result.data = hexlify(req.data);
} }
const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/); const bigIntKeys = "chainId,gasLimit,gasPrice,maxFeePerBlobGas,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);
for (const key of bigIntKeys) { for (const key of bigIntKeys) {
if (!(key in req) || req[key] == null) { if (!(key in req) || req[key] == null) {
continue; continue;
@ -115,6 +115,20 @@ export function copyRequest(req) {
if ("customData" in req) { if ("customData" in req) {
result.customData = req.customData; result.customData = req.customData;
} }
if ("blobVersionedHashes" in req && req.blobVersionedHashes) {
result.blobVersionedHashes = req.blobVersionedHashes.slice();
}
if ("kzg" in req) {
result.kzg = req.kzg;
}
if ("blobs" in req && req.blobs) {
result.blobs = req.blobs.map((b) => {
if (isBytesLike(b)) {
return hexlify(b);
}
return Object.assign({}, b);
});
}
return result; return result;
} }
/** /**

File diff suppressed because one or more lines are too long

@ -21,5 +21,5 @@ export type AccessListish = AccessList | Array<[string, Array<string>]> | Record
export { accessListify } from "./accesslist.js"; export { accessListify } from "./accesslist.js";
export { computeAddress, recoverAddress } from "./address.js"; export { computeAddress, recoverAddress } from "./address.js";
export { Transaction } from "./transaction.js"; export { Transaction } from "./transaction.js";
export type { TransactionLike } from "./transaction.js"; export type { Blob, BlobLike, KzgLibrary, TransactionLike } from "./transaction.js";
//# sourceMappingURL=index.d.ts.map //# sourceMappingURL=index.d.ts.map

Some files were not shown because too many files have changed in this diff Show More