Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@nftx/types

Package Overview
Dependencies
Maintainers
2
Versions
52
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nftx/types - npm Package Compare versions

Comparing version 0.1.3 to 0.1.4

8

CHANGELOG.md

@@ -6,2 +6,10 @@ # Change Log

## [0.1.4](https://github.com/NFTX-project/nftxjs/compare/v0.1.3...v0.1.4) (2022-12-20)
**Note:** Version bump only for package @nftx/types
## 0.1.3 (2022-12-19)

@@ -8,0 +16,0 @@

6

package.json
{
"name": "@nftx/types",
"version": "0.1.3",
"version": "0.1.4",
"description": "",
"homepage": "https://github.com/NFTX-project/nftxjs#readme",
"license": "MIT",
"main": "main.js",
"types": "dist/ts/index.d.ts",
"typedoc": {
"entryPoint": "src/index.ts"
},
"publishConfig": {

@@ -10,0 +12,0 @@ "access": "public"

import type { BigNumber } from 'ethers';
/**
* An ERC721 or ERC1155 asset
*/
export type Asset = {

@@ -7,2 +10,6 @@ id: string;

assetAddress: string;
/**
* URL path to fetch the asset's metadata
* {@link AssetMetadata}
*/
metaUrl: string;

@@ -13,2 +20,5 @@ vaultId: string;

/**
* Metadata about an ERC asset pulled from covalent or opensea
*/
export type AssetMetadata = Asset & {

@@ -28,2 +38,3 @@ name: string;

/** Metadata bouat an ERC collection */
export type Collection = {

@@ -30,0 +41,0 @@ address: string;

import type { BigNumber } from '@ethersproject/bignumber';
import type { TokenReserve } from './tokens';
/**
* An NFTX pool
* This interface contains details on both inventory staking and liquidity staking
*/
export type Pool = {

@@ -5,0 +9,0 @@ vaultId: string;

import type { BigNumber } from '@ethersproject/bignumber';
import type { Pool } from './pools';
/**
* A given user's NFTX position in a given a pool
*/
export type Position = Pool & {

@@ -5,0 +8,0 @@ userAddress: string;

import type { BigNumber } from '@ethersproject/bignumber';
/** A price object returned by all pricing methods (@nftx/trade) */
export type Price = {

@@ -7,4 +8,8 @@ price: BigNumber;

gasPrice?: BigNumber;
/**
* A list of sources providing liquidity for the given price
* This will only be provided if 0x pricing is enabled
*/
sources?: Array<{ name: string; proportion: string }>;
priceImpact?: number;
};
import type { BigNumber } from '@ethersproject/bignumber';
/**
* Common token metadata
*/
export type Token = {

@@ -9,2 +12,5 @@ id: string;

/**
* A token reserve
*/
export type TokenReserve = {

@@ -11,0 +17,0 @@ tokenId: string;

import type { BigNumber } from '@ethersproject/bignumber';
export type NftxTokenType = 'xTokenWETH' | 'xToken' | 'vToken' | 'vTokenWETH';
// export type NftxTokenType = 'xTokenWETH' | 'xToken' | 'vToken' | 'vTokenWETH';
export enum NftxTokenType {
/** vToken paired with WETH and staked in NFTX */
xTokenWETH = 'xTokenWETH',
/** vToken staked in NFTX */
xToken = 'xToken',
vToken = 'vToken',
/** vToken paired with WETH on Sushi */
vTokenWETH = 'vTokenWETH',
}
/**
* An NFTX balance held by a user
* This could be
*/
export type UserVaultBalance = {

@@ -6,0 +19,0 @@ balance: BigNumber;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc