diff --git a/src/client.ts b/src/client.ts index 8885719..a46d9d9 100644 --- a/src/client.ts +++ b/src/client.ts @@ -20,10 +20,10 @@ const main = async () => { const kzg = await loadKZG() let batcherAddress = '0xb79c84166a348b38894bafa95b4f8e286e325e1e'; - const txType: number = 3; + const txType: number = 2; const url = 'http://127.0.0.1:8000'; // Change the URL accordingly - const rpc = "https://eth-sepolia.public.blastapi.io" + const rpc = "https://1rpc.io/sepolia" const web3 = new Web3(rpc); const provider = new ethers.JsonRpcProvider(rpc); diff --git a/src/server.ts b/src/server.ts index 9da5568..a0ec949 100644 --- a/src/server.ts +++ b/src/server.ts @@ -10,7 +10,12 @@ const app = fastify({ logger: true, }); -const kmsProvider = new KMSProviderGCP({}); +const gcpConfig = { + keyFilename: "/Users/inkvi/dev/signer-service/keyfile.json" +}; +const kmsProvider = new KMSProviderGCP(gcpConfig); + +// const kmsProvider = new KMSProviderGCP({}); const wallets = new KMSWallets(kmsProvider); let PROJECT_ID = process.env.PROJECT_ID! @@ -66,7 +71,7 @@ async function handleEthSignTransaction(transactionArgs: TransactionArgs) { transactionArgs.type = '0x0'; } - if (transactionArgs.accessList) { + if (transactionArgs.accessList && transactionArgs.accessList.length > 0) { transactionArgs.type = '0x1'; } else if (transactionArgs.blobVersionedHashes && transactionArgs.blobVersionedHashes.length > 0) { transactionArgs.type = '0x3';