Skip to content

Repository files navigation

Partnr-Chainlink-Task

This project implements a get price action using Solidity. Users can get ethusd prices from chainlink oracle.

🚀 Features

  • getPrice get price
  • Interact using Ethers.js.

Setup

Clone the Repository

git clone https://github.com/chang96/chainlinkdata
cd chainlinkdata

Install Dependencies

npm install

Set Up Environment Variables

Create a .env file in the root directory and add:

SEPOLIA_RPC_URL=""
PRIVATE_KEY=""
CONTRACT_ADDRESS=""

Deployment

To deploy the contract to a testnet (e.g., Sepolia):

npx hardhat run scripts/deploy.ts --network sepolia

Interaction with the Smart Contract

Use Ethers.js to interact with the contract. The functions are located in etherjs-sample.ts.

Available Functions (in etherjs-sample.ts):

  • getPrice: getPrice()

Testing

License

MIT

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages