bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 26쪽 중 24쪽
TC for response timestamps; Unix seconds for many query parameters |
### Querying Off-Chain Prices
When building analytics tools, dashboards, or performing off-chain calculations (such as collateral market value), you often need up-to-date asset prices.
:::warning[Endpoint removed]
The previously documented `https://app.euler.finance/api/v1/price` endpoint no longer exists. Use the endpoints below instead.
:::
### Fetching Prices from the Euler V3 API
Euler Data API V3 serves current and historical USD prices for assets used across Euler deployments:
```bash
# Current prices for one or more assets (comma-separated)
curl "https://v3.euler.finance/v3/prices?chainId=1&addresses=0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0,0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"
# Current price for a single token
curl "https://v3.euler.finance/v3/tokens/1/0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0/price"
# Historical prices over a time range (Unix seconds)
curl "https://v3.euler.finance/v3/prices/history?chainId=1&addresses=0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0&from=1750000000&to=1752000000"
```
Prices are returned as USD numbers (not fixed-point integers), together with a provider-redacted source category and timestamp. The `source` value is one of `onchain`, `offchain`, or `hardcoded`; the response does not include a confidence field:
```json
{
"data": [
{
"chainId": 1,
"address": "0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0",
"symbol": "wstETH",
"decimals": 18,
"priceUsd": 2323.31,
"source": "offchain",
"timestamp": "2026-07-14T16:11:24.895Z"
}
]
}
```
Use the [interactive API reference](https://v3.euler.finance/v3/docs) for exact parameters and schemas.
### Context: Why Use Off-Chain Prices?
In some cases, curators configure oracles that do not directly reflect the current market price. For example, they may use hardcoded values for certain assets, or rely on oracles (such as Chainlink) that are naturally lagging behind the market due to heartbeat intervals or update thresholds. This means the on-chain price used for risk management and liquidations may differ from the real-time market price.
For analytics, risk assessment, or user interfaces, you may want to use a more up-to-date or market-reflective price. Off-chain prices can help you calculate the real-time market value of a collateral position and provide users with more accurate portfolio valuations.
Data API price values are for display and analytics. They are not necessarily the configured oracle values a vault uses for solvency or liquidation. For execution-sensitive checks, read the vault's deployed oracle path or the relevant lens at the intended block. Verify chain, token, quote unit, timestamp, and units before consuming any value.
### Read next
* [Data querying overview](/build/data-querying)
* [Build](/build)
* [Lens contracts](/build/data-querying/lens-contracts)
## Data querying
Euler data integrations usually combine indexed data, metadata, and direct contract reads. Choose the source based on whether you need display data, historical data, or onchain state for execution.
### Choose a data source
* **[Euler Data API V3](/build/data-querying/euler-v3-api):** indexed and enriched data for applications and analytics, including chains, vaults, accounts, prices, APYs, rewards, liquidations, governance actions, and event timelines.
* **[Lens contracts](/build/data-querying/lens-contracts):** current onchain vault, account, oracle, IRM, and Earn state aggregated for offchain reads.
* **[Known vault endpoints](/build/data-querying/perspectives):** public HTTP endpoints for checking which vaults are known (listed by the Euler app: labelled by their curator, published by Euler, and passing Euler's checks) and fetching their metadata (name, curator, deprecation status).
* **[Using lens contracts](/build/data-querying/using-lens-contracts):** practical account, vault, health, LTV, and APY queries.
* **[Subgraphs](/build/data-querying/subgraphs):** lightweight GraphQL indexes hosted on Goldsky for discovering active deposit and borrow positions across all sub-accounts.
* **Direct calls, logs, and custom indexers:** query vaults, EVC, and periphery contracts directly or maintain an index when the hosted interfaces do not cover your use case.
Euler state is distributed across vaults, EVC, and periphery contracts. Indexed data can lag chain state. For transaction validity, solvency, liquidation, or other execution-sensitive decisions, read or simulate against current onchain state on the target chain.
## Label file format (forks)
Euler curators do not use these files. Labels are set in the [Toolbox](/curate/toolbox) and published through the Euler Data API ([Labels and metadata](/curate/vaults/labeling)). A fork of the [Euler app](/build/euler-lite) can instead read labels from static files in this format, with no label service.
### Files
One directory per chain, named by chain ID:
| File | Holds |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------------- |
| `entities.json` | Organisations: name, description, links, logo, on-chain addresses |
| `products.json` | EVK products, their vaults, per-vault overrides under `vaultOverrides` (no standalone `vaults.json`) |
| `points.json` | Points programmes |
| `earn-vaults.json` (optional) | Earn vault discovery and entry metadata. Separate from products. |
| `assets.json` (optional) | Chain-specific asset rules by address. Cross-chain rules go in `all/assets.json`, matched by `symbols` and `names`. |
### Tags
On a product, a vault, or in `vaultOverrides`:
```json
{ "tags": ["governance limited"] }
```
Also in use: `"keyring"`, `"suppress high utilisation warning"`.
### Asset rules
`block`, `restricted`, labels and group aliases are applied by the app at display time. Each fork decides how.
### Descriptions
Keep descriptions factual, with no endorsement: `An EVK lending product for selected assets, configured by Example DAO.` Labels describe what an interface shows. Verify roles and configuration on chain.
## Lens contracts
Lens contracts are specialized, read-only smart contracts designed to make it easy for developers and analysts to access and aggregate protocol data from Euler V2. They provide a convenient way to query on-chain state, combining information from multiple contracts into a single, structured response. Typically, lens contracts are meant for off-chain use only as they are not gas optimized.
### What are lens contracts?
In the context of Euler V2, lens contracts are part of the periphery codebase. They are not involved in protocol state changes or user funds, but instead serve as data aggregators and helpers for off-chain applications, dashboards, bots, and research tools. By using lens contracts, you can:
* Retrieve comprehensive account and vault information in a single call
* Access risk metrics, interest rates, caps, and configuration details
* Query on-chain rewards data
* Aggregate data across multiple vaults or accounts
Euler provides several lens contracts, each focused on a specific aspect of the protocol:
#### [`AccountLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/AccountLens.sol)
* **Purpose:** Aggregate all relevant information about a user account and its positions across vaults.
* **What you can query:**
* Account balances and shares in vaults
* Borrowed amounts and debt positions
* Collateral and controller status
* On-chain reward and incentive data
* Liquidity and risk metrics (e.g., time to liquidation)
#### [`VaultLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/VaultLens.sol)
* **Purpose:** Provide detailed information about a specific vault.
* **What you can query:**
* Vault configuration and parameters (caps, fees, IRM, etc.)
* Total assets, borrows, and shares
* Collateral and their LTVs
* Oracle and price data
* Interest rate model details
#### [`OracleLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/OracleLens.sol)
* **Purpose:** Expose information about price oracles and their configuration.
* **What you can query:**
* Oracle types and parameters
#### [`IRMLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/IRMLens.sol)
* **Purpose:** Provide metadata and parameters for interest rate models (IRMs).
* **What you can query:**
* IRM type (e.g., Kink, Adaptive Curve)
* Model parameters (base rate, slopes, kink point, etc.)
#### [`UtilsLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/UtilsLens.sol)
* **Purpose:** Offer utility queries and helpers for vaults and tokens.
* **What you can query:**
* ERC-4626 vault info
* APYs
* Token balances and allowances
* Indicative on-chain price lookups
* Time to liquidation
#### [`EulerEarnVaultLens`](https://github.com/euler-xyz/evk-periphery/blob/master/src/Lens/EulerEarnVaultLens.sol)
* **Purpose:** Specialized lens for EulerEarn vaults.
* **What you can query:**
* Strategy allocations and performance
* Fee configuration
* Reward and access control data
### Where to find lens contracts
Lens contracts are part of the [EVK Periphery](https://github.com/euler-xyz/evk-periphery/tree/development/src/Lens) repository. You can find their source code and deployment details there.
For contract addresses, check out the [**Contract Addresses** page](../contract-addresses)
For more technical details, see the Solidity interfaces and structs in the periphery codebase, or explore the guides in this section for practical examples.
## Getting Lists of Known Vaults
Euler vaults are permissionless: anyone can deploy one. Integrators, dashboards, and analytics tools therefore need a way to distinguish **known** vaults from unknown or experimental ones. Euler provides public HTTP endpoints for this — the same vault lists and metadata used by the Euler app.
:::warning[Known does not mean safe]
A vault being "known" means the Euler app lists it: its curator labelled it, Euler published the label, and the vault passes Euler's checks on its configuration and on its labels. Escrow vaults, which no curator claims, are known as well. Known is not an endorsement, a safety guarantee, or a promise of ongoing monitoring; the checks and their results are shown in the Toolbox. Governed EVK vaults may remain under active governor or curator control; finalized and canonical escrow vaults may have no active governor. Always inspect live roles and configuration before depositing into or integrating a vault.
:::
### Public Endpoints for Known Vaults
The endpoints are hosted at `https://app.euler.finance/api/public` and require no API key. Requests are rate limited per IP, and responses are cacheable for short periods (about 30 seconds). Addresses must be valid EIP-55 checksummed or all-lowercase hex; response keys are always checksummed.
#### Check or List Known Vaults
`GET /api/public/is-known` returns whether addresses are known vaults on a given chain:
```bash
curl "https://app.euler.finance/api/public/is-known?chainId=1&addresses=0x797DD80692c3b2dAdabCe8e30C07fDE5307D48a9"
```
```json
{
"0x797DD80692c3b2dAdabCe8e30C07fDE5307D48a9": true
}
```
* `chainId` (required): the chain to check against
* `addresses` (optional): comma-separated list of up to 100 addresses
Omit `addresses` to get the full known set for the chain, returned as an object with `true` values:
```bash
curl "https://app.euler.finance/api/public/is-known?chainId=1"
```
Responses from these public endpoints can also include the top-level request-context fields `countryCode`, `isProxyOrVpn`, and `is_vpn`. These keys are not vault addresses or vault metadata entries, so integrations that iterate over the response object should handle or remove them separately. The proxy/VPN flags are currently returned as strings such as `"false"`.
#### Fetch Vault Metadata
`GET /api/public/metadata` returns display metadata for known vaults — name, description, vault type, deprecation status, product, underlying asset, and the entities (curators) behind it:
```bash
curl "https://app.euler.finance/api/public/metadata?chainId=1&addresses=0x797DD80692c3b2dAdabCe8e30C07fDE5307D48a9"
```
```json
{
"0x797DD80692c3b2dAdabCe8e30C07fDE5307D48a9": {
"chainId": 1,
"address": "0x797DD80692c3b2dAdabCe8e30C07fDE5307D48a9",
"type": "evk",
"name": "K3 Capital Prime Market",
"description": "A lending and borrowing market for stablecoin-denominated assets and selected collateral, configured by K3 Capital",
"portfolioNotice": null,
"deprecationReason": null,
"deprecated": false,
"governanceLimited": false,
"productId": "k3-prime",
"asset": {
"address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
"symbol": "USDC",
"name": "USD Coin",
"decimals": 6,
"url": "https://v3.euler.finance/v3/images/tokens/1/0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"
},
"entities": [
{
"name": "K3 Capital",
"logo": "https://v3.euler.finance/v3/images/labels/k3",
"description": "K3 Capital is a third-party curator using Euler infrastructure...",
"url": "https://k3.capital/"
}
]
}
}
```
* `chainId` (required): the chain to query
* `addresses` (optional): comma-separated list of up to 100 addresses; unknown addresses return `null`
* `productId` (optional): only return vaults belonging to a given product slug (e.g. `k3-prime`)
Omit `addresses` to list metadata for every known vault on the chain. `type` is one of `evk` (borrowable vault), `earn` (EulerEarn vault), or `securitize` (Securitize collateral vault).
#### Typical Integration Flow
1. Discover vault and account addresses from the [subgraph](./subgraphs), [lens contracts](./using-lens-contracts), or the [Euler V3 API](./euler-v3-api).
2. Filter the vault list through `/api/public/is-known` to keep only known vaults.
3. Enrich the results with names, curator entities, and deprecation status from `/api/public/metadata` — in particular, check `deprecated` before presenting a vault as active.
### Underlying data: published labels
These endpoints serve the labels Euler publishes through the Euler Data API, and list only the vaults that pass Euler's checks. Curators set labels in the [Toolbox](/curate/toolbox); Euler publishes numbered versions. See [Labels and metadata](/curate/vaults/labeling) and [Publishing and versions](/curate/toolbox/publishing).
The `euler-labels` GitHub repository is deprecated. A fork of the Euler app that brings its own labels reads static files in the [Label file format](/build/data-querying/label-file-format).
### Legacy: On-Chain Perspectives
:::warning[Deprecated as a vault-list source]
The `governedPerspective` — the on-chain curated vault list queried via `verifiedArray()` and `isVerified(vaultAddress)` — has been **retired and replaced by the public endpoints above**. It is no longer maintained and should not be used as a source of known vaults.
:::
Not every perspective contract is retired. The factory perspectives (`evkFactoryPerspective`, `eulerEarnFactoryPerspective`) and the `escrowedCollateralPerspective` remain in use for on-chain **provenance and configuration checks** — verifying that a vault was deployed by the canonical factory, or that it is a correctly configured escrow vault. These perform mechanical checks only; they are not a curated list and do not imply review or endorsement.
## Subgraphs
Subgraphs index on-chain data from Euler V2 smart contracts and expose it through GraphQL. Euler's production subgraphs use a deliberately lightweight schema (`euler-simple`) designed to answer one question efficiently: **which accounts have deposits or borrows in which vaults**. This is the same source the Euler apps and the Euler SDK use for account position discovery.
The simple schema does not expose vault configuration, interest rates, APYs, prices, or health scores. For that data, take the vault and account addresses returned by the subgraph and query [lens contracts](./using-lens-contracts) or the [Euler V3 API](./euler-v3-api).
:::warning[Schema change]
The previous `euler-v2-*` subgraphs and their schema (`eulerVaults`, `trackingActiveAccount` keyed by `mainAddress`, `eulerEarnVaults`, `eulerSwapPools`, etc.) have been decommissioned and their endpoints no longer exist. The `euler-simple-*` subgraphs documented below serve **different entities** and are queried by **address prefix** rather than by account address.
:::
### Source Code
The source code for the Euler simple subgraphs is open source and includes the GraphQL schema, entity definitions, and event handlers:
* [Euler Subgraphs GitHub Repository](https://github.com/euler-xyz/euler-subgraph) (`simple-subgraph` branch)
### Available Networks and Endpoints
Each production network has its own subgraph instance hosted by Goldsky — the same networks listed on the [Contract Addresses](/build/contract-addresses) page:
| Network | Chain ID | GraphQL Endpoint |
| --------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Ethereum | 1 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-mainnet/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-mainnet/latest/gn) |
| BSC | 56 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-bsc/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-bsc/latest/gn) |
| Unichain | 130 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-unichain/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-unichain/latest/gn) |
| Polygon | 137 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-polygon/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-polygon/latest/gn) |
| Monad | 143 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-monad/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-monad/latest/gn) |
| Sonic | 146 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-sonic/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-sonic/latest/gn) |
| TAC | 239 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-tac/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-tac/latest/gn) |
| HyperEVM | 999 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-hyperevm/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-hyperevm/latest/gn) |
| Base | 8453 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-base/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-base/latest/gn) |
| Plasma | 9745 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-plasma/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-plasma/latest/gn) |
| Arbitrum | 42161 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-arbitrum/latest/gn](https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/euler-simple-arbitrum/latest/gn) |
| Avalanche | 43114 | [https://api.goldsky.com/api/public/project_cm4iagnemt1wp01xn4gh1agft/subgraphs/e프로젝트로 돌아가기