Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the link of the GitHub AggregatorV3Interface file #1751

Merged
merged 4 commits into from
Feb 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ To learn how to create a consumer contract that uses an existing data feed, read

### Consumer

A Consumer contract is any contract that uses Chainlink Data Feeds to consume aggregated data. Consumer contracts must reference the correct [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) contract and call one of the exposed functions.
A Consumer contract is any contract that uses Chainlink Data Feeds to consume aggregated data. Consumer contracts must reference the correct [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) contract and call one of the exposed functions.

{/* prettier-ignore */}
```solidity
Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/api-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ constructor() {

To see examples for how to use this interface, read the [Using Data Feeds](/data-feeds/price-feeds) guide.

You can see the code for the [`AggregatorV3Interface` contract](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) on GitHub.
You can see the code for the [`AggregatorV3Interface` contract](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) on GitHub.

### Functions in AggregatorV3Interface

Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/feed-registry/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ For a complete list of functions and parameters for the `FeedRegistryInterface`

## Base and Quote

The Feed Registry fully supports the [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/develop/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) API for multiple feeds. It maps feeds from `base` and `quote` address pairs. To get the latest LINK / USD round data from the registry, call:
The Feed Registry fully supports the [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) API for multiple feeds. It maps feeds from `base` and `quote` address pairs. To get the latest LINK / USD round data from the registry, call:

{/* prettier-ignore */}
```solidity
Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/getting-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ This example contract obtains the latest price answer from the [BTC / USD feed](

The contract has the following components:

- The `import` line imports an interface named `AggregatorV3Interface`. Interfaces define functions without their implementation, which leaves inheriting contracts to define the actual implementation themselves. In this case, `AggregatorV3Interface` defines that all v3 Aggregators have the function `latestRoundData`. You can [see the complete code](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) for the `AggregatorV3Interface` on GitHub.
- The `import` line imports an interface named `AggregatorV3Interface`. Interfaces define functions without their implementation, which leaves inheriting contracts to define the actual implementation themselves. In this case, `AggregatorV3Interface` defines that all v3 Aggregators have the function `latestRoundData`. You can [see the complete code](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) for the `AggregatorV3Interface` on GitHub.

- The `constructor() {}` initializes an interface object named `dataFeed` that uses `AggregatorV3Interface` and connects specifically to a proxy aggregator contract that is already deployed at `0x1b44F3514812d835EB1BDB0acB33d3fA3351Ee43`. The interface allows your contract to run functions on that deployed aggregator contract.

Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/historical-data.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { HistoricalPrice } from "@features/feeds"
import { Aside, ClickToZoom, CodeSample, Icon } from "@components"
import button from "@chainlink/design-system/button.module.css"

The most common use case for Data Feeds is to [Get the Latest Data](/data-feeds/using-data-feeds) from a feed. However, the [AggregatorV3Interface.sol](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) also has functions to retrieve data of a previous round IDs.
The most common use case for Data Feeds is to [Get the Latest Data](/data-feeds/using-data-feeds) from a feed. However, the [AggregatorV3Interface.sol](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) also has functions to retrieve data of a previous round IDs.

There are two parameters that can cause Chainlink nodes to update:

Expand Down
4 changes: 2 additions & 2 deletions src/content/data-feeds/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ See the [Proof of Reserve Contract Addresses](/data-feeds/proof-of-reserve/addre

### NFT Floor Price Feeds

NFT Floor Price Feeds provide the price of the lowest priced NFT available in a collection. These feeds operate similarly to [Price Feeds](/data-feeds/price-feeds) so you can use the [AggregatorV3Interface.sol](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) contract to retrieve price answers.
NFT Floor Price Feeds provide the price of the lowest priced NFT available in a collection. These feeds operate similarly to [Price Feeds](/data-feeds/price-feeds) so you can use the [AggregatorV3Interface.sol](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) contract to retrieve price answers.

To learn more, see the [NFT Floor Price Feeds](/data-feeds/nft-floor-price) documentation.

Expand All @@ -86,7 +86,7 @@ To learn how to use L2 sequencer uptime feeds feeds, see the [L2 Sequencer Uptim

Data Feeds are an example of a decentralized oracle network and include the following components:

- **Consumer**: A consumer is an onchain or offchain application that uses Data Feeds. Consumer contracts use the [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol) to call functions on the proxy contract and retrieve information from the aggregator contract. For a complete list of functions available in the `AggregatorV3Interface`, see the [Data Feeds API Reference](/data-feeds/api-reference/#aggregatorv3interface).
- **Consumer**: A consumer is an onchain or offchain application that uses Data Feeds. Consumer contracts use the [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol) to call functions on the proxy contract and retrieve information from the aggregator contract. For a complete list of functions available in the `AggregatorV3Interface`, see the [Data Feeds API Reference](/data-feeds/api-reference/#aggregatorv3interface).
- **Proxy contract**: Proxy contracts are onchain proxies that point to the aggregator for a particular data feed. Using proxies enables the underlying aggregator to be upgraded without any service interruption to consuming contracts. Proxy contracts can vary from one data feed to another, but the [`AggregatorProxy.sol` contract](https://github.com/smartcontractkit/chainlink/blob/develop/contracts/src/v0.7/dev/AggregatorProxy.sol) on Github is a common example.
- **Aggregator contract**: An aggregator is a contract that receives periodic data updates from the oracle network. Aggregators store aggregated data onchain so that consumers can retrieve it and act upon it within the same transaction. For a complete list of functions and variables available on most aggregator contracts, see the [Data Feeds API Reference](/data-feeds/api-reference/#accesscontrolledoffchainaggregator).

Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/nft-floor-price/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ Find the list of testnet feeds on the [Contract Addresses](/data-feeds/nft-floor

Read answers from NFT Floor Price Feeds the same way that you read other Data Feeds. Specify the [NFT Floor Price Feed Address](/data-feeds/nft-floor-price/addresses) that you want to read instead of specifying a Price Feed address. See the [Using Data Feeds](/data-feeds/using-data-feeds) page to learn more.

Using Solidity, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.
Using Solidity, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.

<CodeSample src="samples/DataFeeds/NFTFloorPriceConsumerV3.sol" />
2 changes: 1 addition & 1 deletion src/content/data-feeds/proof-of-reserve/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Cross-chain reserves provide their data using the following methods:

Read answers from Proof of Reserve Feeds the same way that you read other Data Feeds. Specify the [Proof of Reserve Feed Address](/data-feeds/proof-of-reserve/addresses) that you want to read instead of specifying a Price Feed address. See the [Using Data Feeds](/data-feeds/using-data-feeds) page to learn more.

Using Solidity, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.
Using Solidity, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.

<CodeSample src="samples/DataFeeds/ReserveConsumerV3.sol" />

Expand Down
2 changes: 1 addition & 1 deletion src/content/data-feeds/using-data-feeds.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ These code examples demonstrate how to deploy a consumer contract onchain that r

### Solidity

To consume price data, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.
To consume price data, your smart contract should reference [`AggregatorV3Interface`](https://github.com/smartcontractkit/chainlink/blob/master/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol), which defines the external functions implemented by Data Feeds.

<CodeSample src="samples/DataFeeds/DataConsumerV3.sol" />

Expand Down
Loading