Infura project url

Hi,

I have made a project in infura. its end point is rinkeby url rinkeby.infura.io/v3/dce50af7b3a347ada43267d2bb80b5b2 but whenever i am using this in my ethereum code, it is giving me error.
error: UnhandledPromiseRejectionWarning: ReferenceError: account is not defined
and when i m using https://rinkeby.infura.io/v3/dce50af7b3a347ada43267d2bb80b5b2
error:Couldn’t connect to node
and if i m entering this url in google- then 404 error.

what i am doing wrong?
please suggest.

Hi, Welcome to the Infura community!

Could you provide the code you are using to generate the requests?

const HDWalletProvider = require(“truffle-hdwallet-provider”);
const Web3 = require(“web3”);
const { interface, bytecode } = require("./compile");

const provider = new HDWalletProvider(
“mnemonic”,
https://rinkeby.infura.io/v3/dce50af7b3a347ada43267d2bb80b5b2
);
const web3 = new Web3(provider);
console.log(“shruti…”);
//try {
const deploy = async () => {
const accounts = await web3.eth.getAccounts();
// console.log(“attempting to deploy from accounts”, account[0]);
const result = await new web3.eth.Contract(JSON.parse(interface))
.deploy({ data: bytecode, arguments: [“Hi there!”] })
.send({ gas: “1000000”, from: accounts[0] });

console.log(“tandon”);
// console.log(“attempting to deploy from account”, getAccounts[0]);
//const result = await new web3.eth.Contract(JSON.parse(interface))
// .deploy({ data: “0x” + bytecode })
// .send({ from: accounts[0] });

console.log(interface);
console.log(“contract deploed to”, result.options.address);
};

deploy();

I tested your provided API key and it is functioning as expected, this could be an issue with how you are executing Web3.js. Does the deploying account have sufficient Rinkeby ether to deploy the contract?

Hello!
I have a same problem nut I 'm using infura, It give me just one account[0] and I want to use 4 accounts . What should I do ?

Hi @Sirine_Hml - welcome to the Infura community! Just to clarify - the account[0] you’re referencing is an ETH address?