Skip to main content

Function: curateOptionDetails()

function curateOptionDetails(details, registry): object;

Defined in: packages/overcast-core/src/assets/index.ts:285

Resolve every asset field of OptionDetails against the registry. Defaults to an unknownAsset if not available

Parameters

ParameterType
detailsOptionDetails
registryAssetRegistry

Returns

object

borrowAllowed

borrowAllowed: boolean;

collateralAmount

collateralAmount: string;

collateralAsset

collateralAsset: object = assetSchema;

collateralAsset.address

address: string;

The on-chain address (mint) that uniquely identifies the asset.

collateralAsset.cashLike?

optional cashLike?: boolean;

Whether or not the asset can be treated similar to cash

collateralAsset.chain?

optional chain?: string;

The chain the asset lives on.

collateralAsset.coinGeckoId?

optional coinGeckoId?: string;

CoinGecko id for price lookups, e.g. usd-coin.

collateralAsset.decimals?

optional decimals?: number;

Number of decimal places in the asset's native units.

collateralAsset.lastKnownPriceUsd?

optional lastKnownPriceUsd?: number;

Last known USD price, sourced best-effort from an external feed (CoinGecko). Untrusted — do not use for settlement, signing, valuation, or any value transfer. It is informational only (e.g. showing an approximate notional in a picker), may be stale, missing, or wrong, and is never part of the canonical, content-addressed asset identity. Present only once a price has actually been fetched for the asset.

collateralAsset.logoUrl?

optional logoUrl?: string;

Logo of the coin

collateralAsset.name?

optional name?: string;

Human name of the asset.

collateralAsset.rwa?

optional rwa?: boolean;

Whether the asset is a real-world asset (RWA) — e.g. tokenized private equity — rather than a native crypto asset.

collateralAsset.symbol?

optional symbol?: string;

Human ticker, e.g. USDC.

collateralAsset.volatility?

optional volatility?: number;

Volatility of the asset

domain

domain: number;

endTimestamp

endTimestamp: number;

premiumAmount

premiumAmount: string;

premiumAsset

premiumAsset: object = assetSchema;

premiumAsset.address

address: string;

The on-chain address (mint) that uniquely identifies the asset.

premiumAsset.cashLike?

optional cashLike?: boolean;

Whether or not the asset can be treated similar to cash

premiumAsset.chain?

optional chain?: string;

The chain the asset lives on.

premiumAsset.coinGeckoId?

optional coinGeckoId?: string;

CoinGecko id for price lookups, e.g. usd-coin.

premiumAsset.decimals?

optional decimals?: number;

Number of decimal places in the asset's native units.

premiumAsset.lastKnownPriceUsd?

optional lastKnownPriceUsd?: number;

Last known USD price, sourced best-effort from an external feed (CoinGecko). Untrusted — do not use for settlement, signing, valuation, or any value transfer. It is informational only (e.g. showing an approximate notional in a picker), may be stale, missing, or wrong, and is never part of the canonical, content-addressed asset identity. Present only once a price has actually been fetched for the asset.

premiumAsset.logoUrl?

optional logoUrl?: string;

Logo of the coin

premiumAsset.name?

optional name?: string;

Human name of the asset.

premiumAsset.rwa?

optional rwa?: boolean;

Whether the asset is a real-world asset (RWA) — e.g. tokenized private equity — rather than a native crypto asset.

premiumAsset.symbol?

optional symbol?: string;

Human ticker, e.g. USDC.

premiumAsset.volatility?

optional volatility?: number;

Volatility of the asset

settlementAmount

settlementAmount: string;

settlementAsset

settlementAsset: object = assetSchema;

settlementAsset.address

address: string;

The on-chain address (mint) that uniquely identifies the asset.

settlementAsset.cashLike?

optional cashLike?: boolean;

Whether or not the asset can be treated similar to cash

settlementAsset.chain?

optional chain?: string;

The chain the asset lives on.

settlementAsset.coinGeckoId?

optional coinGeckoId?: string;

CoinGecko id for price lookups, e.g. usd-coin.

settlementAsset.decimals?

optional decimals?: number;

Number of decimal places in the asset's native units.

settlementAsset.lastKnownPriceUsd?

optional lastKnownPriceUsd?: number;

Last known USD price, sourced best-effort from an external feed (CoinGecko). Untrusted — do not use for settlement, signing, valuation, or any value transfer. It is informational only (e.g. showing an approximate notional in a picker), may be stale, missing, or wrong, and is never part of the canonical, content-addressed asset identity. Present only once a price has actually been fetched for the asset.

settlementAsset.logoUrl?

optional logoUrl?: string;

Logo of the coin

settlementAsset.name?

optional name?: string;

Human name of the asset.

settlementAsset.rwa?

optional rwa?: boolean;

Whether the asset is a real-world asset (RWA) — e.g. tokenized private equity — rather than a native crypto asset.

settlementAsset.symbol?

optional symbol?: string;

Human ticker, e.g. USDC.

settlementAsset.volatility?

optional volatility?: number;

Volatility of the asset

settlementLayer

settlementLayer: string;

startTimestamp

startTimestamp: number;