LogoLogo
PivotalChain.ioStaking AppPivotalChain ContractsPivotal Bridge
  • Introduction: Pivotal & plusBTC
    • Pivotal
    • Bitcoin's Revolution
    • Pivotal's Mission and Vision
  • PIVOTAL PARTNERS
    • Babylon: Bitcoin Staking
    • Ceffu: Institutional Custody
    • B² Network: Finality Provider
  • LINKS
    • Pivotal Website
    • Pivotal X (Twitter)
    • Pivotal Discord Server
    • Staking BTC
Powered by GitBook
LogoLogo

Notices

  • Terms of Service
  • Privacy Policy
  • Legal Notice
  • UK Residents

(c) Copyright Pivotal Research Ltd

On this page
  • Hardhat
  • Using Hardhat with Pivotal
Export as PDF
  1. PIVOTALCHAIN TOOLS
  2. Toolchains

Hardhat

Last updated 11 months ago

Hardhat

Hardhat is an Ethereum development environment for flexible, extensible, and fast smart contract development.

You can use Hardhat to edit, compile, debug, and deploy your smart contracts to Pivotal.


Using Hardhat with Pivotal

To configure to deploy smart contracts to Pivotal, update your project’s hardhat.config.ts file by adding Pivotal as a network:

networks: {
   // for mainnet
   "pivotal-mainnet": {
     url: 'https://mainnet.thepivotal.xyz',
     accounts: [process.env.PRIVATE_KEY as string],
     gasPrice: 1000000000,
   },
   // for Sepolia testnet
   "pivotal-sepolia": {
     url: "https://sepolia.thepivotal.xyz",
     accounts: [process.env.PRIVATE_KEY as string],
     gasPrice: 1000000000,
   },
   // for local dev environment
   "pivotal-local": {
     url: "http://localhost:8545",
     accounts: [process.env.PRIVATE_KEY as string],
     gasPrice: 1000000000,
   },
 },
 defaultNetwork: "pivotal-local",

For a complete guide on using Hardhat to deploy contracts on Pivotal, see

Hardhat
Deploying a Smart Contract.