From a30a98429a24e647e93e6367b212a463c8db5d15 Mon Sep 17 00:00:00 2001 From: Turupawn Date: Sat, 6 Dec 2025 10:56:20 -0600 Subject: [PATCH 1/5] updated yarn lock --- yarn.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yarn.lock b/yarn.lock index e539e92a4b2..0a519a5bf61 100644 --- a/yarn.lock +++ b/yarn.lock @@ -13823,7 +13823,7 @@ polished@^3.3.2: polyfill-object.fromentries@^1.0.1: version "1.0.1" - resolved "https://registry.nlark.com/polyfill-object.fromentries/download/polyfill-object.fromentries-1.0.1.tgz#1a5d89e3777684a852c9b6a6a1d2c3f9c262fc86" + resolved "https://registry.yarnpkg.com/polyfill-object.fromentries/-/polyfill-object.fromentries-1.0.1.tgz#1a5d89e3777684a852c9b6a6a1d2c3f9c262fc86" integrity sha1-Gl2J43d2hKhSybamodLD+cJi/IY= popper-max-size-modifier@^0.2.0: From d3d38af0e6cb7281d34de33975485221683ccdfb Mon Sep 17 00:00:00 2001 From: Turupawn Date: Sat, 6 Dec 2025 11:13:14 -0600 Subject: [PATCH 2/5] made graphql optional --- package.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index d9f5325c1fd..86bc7ccdd2f 100644 --- a/package.json +++ b/package.json @@ -9,14 +9,14 @@ "contracts:compile:v3": "typechain --target ethers-v5 --out-dir src/types/v3 \"./node_modules/@uniswap/**/artifacts/contracts/**/*[!dbg].json\"", "contracts:compile": "yarn contracts:compile:abi && yarn contracts:compile:v3", "relay": "relay-compiler relay.config.js", - "relay-thegraph": "relay-compiler relay_thegraph.config.js", - "graphql:fetch": "node fetch-schema.js", - "graphql:generate": "yarn relay && yarn relay-thegraph", + "relay-thegraph": "relay-compiler relay_thegraph.config.js || true", + "graphql:fetch": "node fetch-schema.js || true", + "graphql:generate": "yarn relay || true", "prei18n:extract": "node prei18n-extract.js", "i18n:extract": "lingui extract --locale en-US", "i18n:compile": "yarn i18n:extract && lingui compile", "i18n:pseudo": "lingui extract --locale pseudo && lingui compile", - "prepare": "yarn contracts:compile && yarn graphql:fetch && yarn graphql:generate && yarn i18n:compile", + "prepare": "yarn contracts:compile && yarn i18n:compile", "start": "craco start", "build": "craco build", "serve": "serve build -l 3000", From c60740dd281a66ba55c290ae365d7b86a58cf1a4 Mon Sep 17 00:00:00 2001 From: Turupawn Date: Sat, 6 Dec 2025 11:23:22 -0600 Subject: [PATCH 3/5] fix start command and browser list --- package.json | 8 ++++---- yarn.lock | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/package.json b/package.json index 86bc7ccdd2f..750228128f5 100644 --- a/package.json +++ b/package.json @@ -17,12 +17,12 @@ "i18n:compile": "yarn i18n:extract && lingui compile", "i18n:pseudo": "lingui extract --locale pseudo && lingui compile", "prepare": "yarn contracts:compile && yarn i18n:compile", - "start": "craco start", - "build": "craco build", + "start": "NODE_OPTIONS=--openssl-legacy-provider craco start", + "build": "NODE_OPTIONS=--openssl-legacy-provider craco build", "serve": "serve build -l 3000", "deduplicate": "yarn-deduplicate --strategy=highest", "lint": "yarn eslint .", - "test": "craco test --coverage", + "test": "NODE_OPTIONS=--openssl-legacy-provider craco test --coverage", "cypress:open": "cypress open --browser chrome --e2e", "cypress:run": "cypress run --browser chrome --e2e", "postinstall": "patch-package" @@ -248,4 +248,4 @@ "node": "22.x", "yarn": ">=1.22" } -} \ No newline at end of file +} diff --git a/yarn.lock b/yarn.lock index 0a519a5bf61..50f1a689bb0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6609,9 +6609,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30001109, caniuse-lite@^1.0.30001125, caniuse-lite@^1.0.30001370: - version "1.0.30001488" - resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001488.tgz" - integrity sha512-NORIQuuL4xGpIy6iCCQGN4iFjlBXtfKWIenlUuyZJumLRIindLb7wXM+GO8erEhb7vXfcnf4BAg2PrSDN5TNLQ== + version "1.0.30001759" + resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001759.tgz" + integrity sha512-Pzfx9fOKoKvevQf8oCXoyNRQ5QyxJj+3O0Rqx2V5oxT61KGx8+n6hV/IUyJeifUci2clnmmKVpvtiqRzgiWjSw== capture-exit@^2.0.0: version "2.0.0" From 307fb17a7927b7e8aa6a3a5fb9c5c289e18d7ed2 Mon Sep 17 00:00:00 2001 From: Ahmed Castro Date: Tue, 9 Dec 2025 13:16:18 -0600 Subject: [PATCH 4/5] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index fedf193e302..11b36fc8d88 100644 --- a/README.md +++ b/README.md @@ -48,4 +48,4 @@ The Uniswap Interface supports swapping, adding liquidity, removing liquidity an ## Accessing Uniswap V1 The Uniswap V1 interface for mainnet and testnets is accessible via IPFS gateways -linked from the [v1.0.0 release](https://github.com/Uniswap/uniswap-interface/releases/tag/v1.0.0). +linked from the [v1.0.0 release](https://github.com/Uniswap/uniswap-interface/releases/tag/v1.0.0).. From f6f150edfd5aa88498b85b3835ef8f9ca68e9976 Mon Sep 17 00:00:00 2001 From: Turupawn Date: Tue, 9 Dec 2025 19:15:18 -0600 Subject: [PATCH 5/5] yarn run build passing now --- .gitignore | 2 - craco.config.cjs | 3 + package.json | 4 +- .../__generated__/TokenPriceQuery.graphql.ts | 251 +++ .../data/__generated__/TokenQuery.graphql.ts | 494 +++++ .../TopTokens100Query.graphql.ts | 381 ++++ .../TopTokensSparklineQuery.graphql.ts | 227 +++ .../AssetPaginationQuery.graphql.ts | 635 +++++++ .../nft/__generated__/AssetQuery.graphql.ts | 651 +++++++ .../AssetQuery_nftAssets.graphql.ts | 643 +++++++ .../__generated__/CollectionQuery.graphql.ts | 808 +++++++++ .../nft/__generated__/DetailsQuery.graphql.ts | 874 +++++++++ .../NftBalancePaginationQuery.graphql.ts | 602 +++++++ .../__generated__/NftBalanceQuery.graphql.ts | 614 +++++++ .../NftBalanceQuery_nftBalances.graphql.ts | 619 +++++++ src/graphql/data/schema.graphql | 1582 +++++++++++++++++ .../__generated__/AllV3TicksQuery.graphql.ts | 212 +++ .../FeeTierDistributionQuery.graphql.ts | 378 ++++ src/graphql/thegraph/schema.graphql | 10 + src/graphql/thegraph/schema.graphql.temp | 0 src/hooks/useFeeTierDistribution.ts | 11 +- src/hooks/usePoolTickData.ts | 36 +- src/utils/computeSurroundingTicks.ts | 11 +- 23 files changed, 9023 insertions(+), 25 deletions(-) create mode 100644 src/graphql/data/__generated__/TokenPriceQuery.graphql.ts create mode 100644 src/graphql/data/__generated__/TokenQuery.graphql.ts create mode 100644 src/graphql/data/__generated__/TopTokens100Query.graphql.ts create mode 100644 src/graphql/data/__generated__/TopTokensSparklineQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/AssetPaginationQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/AssetQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/AssetQuery_nftAssets.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/CollectionQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/DetailsQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/NftBalancePaginationQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/NftBalanceQuery.graphql.ts create mode 100644 src/graphql/data/nft/__generated__/NftBalanceQuery_nftBalances.graphql.ts create mode 100644 src/graphql/data/schema.graphql create mode 100644 src/graphql/thegraph/__generated__/AllV3TicksQuery.graphql.ts create mode 100644 src/graphql/thegraph/__generated__/FeeTierDistributionQuery.graphql.ts create mode 100644 src/graphql/thegraph/schema.graphql create mode 100644 src/graphql/thegraph/schema.graphql.temp diff --git a/.gitignore b/.gitignore index 9b8eb61c20f..fcf961b20de 100644 --- a/.gitignore +++ b/.gitignore @@ -9,8 +9,6 @@ /src/locales/**/pseudo.po # generated graphql types -__generated__/ -schema.graphql # dependencies /node_modules diff --git a/craco.config.cjs b/craco.config.cjs index 3189e7afc6f..b7b79bf5a3f 100644 --- a/craco.config.cjs +++ b/craco.config.cjs @@ -31,6 +31,9 @@ module.exports = { // This is required because conedison uses * to redirect all imports to its dist. webpackConfig.resolve.alias['@uniswap/conedison'] = '@uniswap/conedison/dist' + // Disable source maps to avoid SourceMapConsumer WASM initialization issues + webpackConfig.devtool = false + return webpackConfig }, }, diff --git a/package.json b/package.json index 750228128f5..3e6cefe49a7 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "relay": "relay-compiler relay.config.js", "relay-thegraph": "relay-compiler relay_thegraph.config.js || true", "graphql:fetch": "node fetch-schema.js || true", - "graphql:generate": "yarn relay || true", + "graphql:generate": "yarn relay && yarn relay-thegraph", "prei18n:extract": "node prei18n-extract.js", "i18n:extract": "lingui extract --locale en-US", "i18n:compile": "yarn i18n:extract && lingui compile", @@ -248,4 +248,4 @@ "node": "22.x", "yarn": ">=1.22" } -} +} \ No newline at end of file diff --git a/src/graphql/data/__generated__/TokenPriceQuery.graphql.ts b/src/graphql/data/__generated__/TokenPriceQuery.graphql.ts new file mode 100644 index 00000000000..157f82608ff --- /dev/null +++ b/src/graphql/data/__generated__/TokenPriceQuery.graphql.ts @@ -0,0 +1,251 @@ +/** + * @generated SignedSource<<926be9e5a248470f9b74af80d4331e58>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type HistoryDuration = "DAY" | "FIVE_MINUTE" | "HOUR" | "MAX" | "MONTH" | "WEEK" | "YEAR" | "%future added value"; +export type ContractInput = { + address?: string | null; + chain: Chain; +}; +export type TokenPriceQuery$variables = { + contract: ContractInput; + duration: HistoryDuration; +}; +export type TokenPriceQuery$data = { + readonly tokens: ReadonlyArray<{ + readonly market: { + readonly price: { + readonly value: number; + } | null; + readonly priceHistory: ReadonlyArray<{ + readonly timestamp: number; + readonly value: number; + } | null> | null; + }; + } | null> | null; +}; +export type TokenPriceQuery = { + response: TokenPriceQuery$data; + variables: TokenPriceQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "contract" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "duration" + } +], +v1 = [ + { + "items": [ + { + "kind": "Variable", + "name": "contracts.0", + "variableName": "contract" + } + ], + "kind": "ListValue", + "name": "contracts" + } +], +v2 = [ + { + "kind": "Literal", + "name": "currency", + "value": "USD" + } +], +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v4 = [ + { + "kind": "Variable", + "name": "duration", + "variableName": "duration" + } +], +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "timestamp", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "TokenPriceQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + { + "kind": "RequiredField", + "field": (v3/*: any*/), + "action": "LOG", + "path": "tokens.market.price.value" + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v4/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "priceHistory", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": (v5/*: any*/), + "action": "LOG", + "path": "tokens.market.priceHistory.timestamp" + }, + { + "kind": "RequiredField", + "field": (v3/*: any*/), + "action": "LOG", + "path": "tokens.market.priceHistory.value" + } + ], + "storageKey": null + } + ], + "storageKey": "market(currency:\"USD\")" + }, + "action": "LOG", + "path": "tokens.market" + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "TokenPriceQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v3/*: any*/), + (v6/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v4/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "priceHistory", + "plural": true, + "selections": [ + (v5/*: any*/), + (v3/*: any*/), + (v6/*: any*/) + ], + "storageKey": null + }, + (v6/*: any*/) + ], + "storageKey": "market(currency:\"USD\")" + }, + (v6/*: any*/) + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "57d6ad1f08cbca6e18ae3b0c24927301", + "id": null, + "metadata": {}, + "name": "TokenPriceQuery", + "operationKind": "query", + "text": "query TokenPriceQuery(\n $contract: ContractInput!\n $duration: HistoryDuration!\n) {\n tokens(contracts: [$contract]) {\n market(currency: USD) {\n price {\n value\n id\n }\n priceHistory(duration: $duration) {\n timestamp\n value\n id\n }\n id\n }\n id\n }\n}\n" + } +}; +})(); + +(node as any).hash = "47f1f49f7d0ace05e64ff5bec4cf4d35"; + +export default node; diff --git a/src/graphql/data/__generated__/TokenQuery.graphql.ts b/src/graphql/data/__generated__/TokenQuery.graphql.ts new file mode 100644 index 00000000000..f682c3f14dd --- /dev/null +++ b/src/graphql/data/__generated__/TokenQuery.graphql.ts @@ -0,0 +1,494 @@ +/** + * @generated SignedSource<<87e41a34ec2bda8ceb97763f23275f93>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type ContractInput = { + address?: string | null; + chain: Chain; +}; +export type TokenQuery$variables = { + contract: ContractInput; +}; +export type TokenQuery$data = { + readonly tokens: ReadonlyArray<{ + readonly address: string; + readonly chain: Chain; + readonly decimals: number | null; + readonly id: string; + readonly market: { + readonly price: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly priceHigh52W: { + readonly value: number; + } | null; + readonly priceLow52W: { + readonly value: number; + } | null; + readonly totalValueLocked: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly volume24H: { + readonly currency: Currency | null; + readonly value: number; + } | null; + } | null; + readonly name: string | null; + readonly project: { + readonly description: string | null; + readonly homepageUrl: string | null; + readonly logoUrl: string | null; + readonly tokens: ReadonlyArray<{ + readonly address: string; + readonly chain: Chain; + } | null>; + readonly twitterName: string | null; + } | null; + readonly symbol: string | null; + } | null> | null; +}; +export type TokenQuery = { + response: TokenQuery$data; + variables: TokenQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "contract" + } +], +v1 = [ + { + "items": [ + { + "kind": "Variable", + "name": "contracts.0", + "variableName": "contract" + } + ], + "kind": "ListValue", + "name": "contracts" + } +], +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "decimals", + "storageKey": null +}, +v4 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null +}, +v8 = [ + { + "kind": "Literal", + "name": "currency", + "value": "USD" + } +], +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}, +v11 = [ + (v9/*: any*/), + (v10/*: any*/) +], +v12 = [ + { + "kind": "Literal", + "name": "duration", + "value": "DAY" + } +], +v13 = { + "kind": "Literal", + "name": "duration", + "value": "YEAR" +}, +v14 = [ + (v13/*: any*/), + { + "kind": "Literal", + "name": "highLow", + "value": "HIGH" + } +], +v15 = [ + (v9/*: any*/) +], +v16 = [ + (v13/*: any*/), + { + "kind": "Literal", + "name": "highLow", + "value": "LOW" + } +], +v17 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null +}, +v18 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "homepageUrl", + "storageKey": null +}, +v19 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "twitterName", + "storageKey": null +}, +v20 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "logoUrl", + "storageKey": null +}, +v21 = [ + (v9/*: any*/), + (v10/*: any*/), + (v2/*: any*/) +], +v22 = [ + (v9/*: any*/), + (v2/*: any*/) +]; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "TokenQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": (v2/*: any*/), + "action": "LOG", + "path": "tokens.id" + }, + (v3/*: any*/), + (v4/*: any*/), + { + "kind": "RequiredField", + "field": (v5/*: any*/), + "action": "LOG", + "path": "tokens.chain" + }, + { + "kind": "RequiredField", + "field": (v6/*: any*/), + "action": "LOG", + "path": "tokens.address" + }, + (v7/*: any*/), + { + "alias": null, + "args": (v8/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "totalValueLocked", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + { + "alias": "volume24H", + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": "volume(duration:\"DAY\")" + }, + { + "alias": "priceHigh52W", + "args": (v14/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "priceHighLow", + "plural": false, + "selections": (v15/*: any*/), + "storageKey": "priceHighLow(duration:\"YEAR\",highLow:\"HIGH\")" + }, + { + "alias": "priceLow52W", + "args": (v16/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "priceHighLow", + "plural": false, + "selections": (v15/*: any*/), + "storageKey": "priceHighLow(duration:\"YEAR\",highLow:\"LOW\")" + } + ], + "storageKey": "market(currency:\"USD\")" + }, + { + "alias": null, + "args": null, + "concreteType": "TokenProject", + "kind": "LinkedField", + "name": "project", + "plural": false, + "selections": [ + (v17/*: any*/), + (v18/*: any*/), + (v19/*: any*/), + (v20/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": (v5/*: any*/), + "action": "LOG", + "path": "tokens.project.tokens.chain" + }, + { + "kind": "RequiredField", + "field": (v6/*: any*/), + "action": "LOG", + "path": "tokens.project.tokens.address" + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "TokenQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + (v2/*: any*/), + (v3/*: any*/), + (v4/*: any*/), + (v5/*: any*/), + (v6/*: any*/), + (v7/*: any*/), + { + "alias": null, + "args": (v8/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "totalValueLocked", + "plural": false, + "selections": (v21/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": (v21/*: any*/), + "storageKey": null + }, + { + "alias": "volume24H", + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v21/*: any*/), + "storageKey": "volume(duration:\"DAY\")" + }, + { + "alias": "priceHigh52W", + "args": (v14/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "priceHighLow", + "plural": false, + "selections": (v22/*: any*/), + "storageKey": "priceHighLow(duration:\"YEAR\",highLow:\"HIGH\")" + }, + { + "alias": "priceLow52W", + "args": (v16/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "priceHighLow", + "plural": false, + "selections": (v22/*: any*/), + "storageKey": "priceHighLow(duration:\"YEAR\",highLow:\"LOW\")" + }, + (v2/*: any*/) + ], + "storageKey": "market(currency:\"USD\")" + }, + { + "alias": null, + "args": null, + "concreteType": "TokenProject", + "kind": "LinkedField", + "name": "project", + "plural": false, + "selections": [ + (v17/*: any*/), + (v18/*: any*/), + (v19/*: any*/), + (v20/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Token", + "kind": "LinkedField", + "name": "tokens", + "plural": true, + "selections": [ + (v5/*: any*/), + (v6/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "650ce9b09cdc85375ec02dac7ab527f7", + "id": null, + "metadata": {}, + "name": "TokenQuery", + "operationKind": "query", + "text": "query TokenQuery(\n $contract: ContractInput!\n) {\n tokens(contracts: [$contract]) {\n id\n decimals\n name\n chain\n address\n symbol\n market(currency: USD) {\n totalValueLocked {\n value\n currency\n id\n }\n price {\n value\n currency\n id\n }\n volume24H: volume(duration: DAY) {\n value\n currency\n id\n }\n priceHigh52W: priceHighLow(duration: YEAR, highLow: HIGH) {\n value\n id\n }\n priceLow52W: priceHighLow(duration: YEAR, highLow: LOW) {\n value\n id\n }\n id\n }\n project {\n description\n homepageUrl\n twitterName\n logoUrl\n tokens {\n chain\n address\n id\n }\n id\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "0ed708e6183ea3af274040a8c3e71694"; + +export default node; diff --git a/src/graphql/data/__generated__/TopTokens100Query.graphql.ts b/src/graphql/data/__generated__/TopTokens100Query.graphql.ts new file mode 100644 index 00000000000..2e1ade62fcb --- /dev/null +++ b/src/graphql/data/__generated__/TopTokens100Query.graphql.ts @@ -0,0 +1,381 @@ +/** + * @generated SignedSource<<7449f20ea07b56974ddb724d87959b06>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type HistoryDuration = "DAY" | "FIVE_MINUTE" | "HOUR" | "MAX" | "MONTH" | "WEEK" | "YEAR" | "%future added value"; +export type TopTokens100Query$variables = { + chain: Chain; + duration: HistoryDuration; +}; +export type TopTokens100Query$data = { + readonly topTokens: ReadonlyArray<{ + readonly address: string; + readonly chain: Chain; + readonly id: string; + readonly market: { + readonly price: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly pricePercentChange: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly totalValueLocked: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly volume: { + readonly currency: Currency | null; + readonly value: number; + } | null; + } | null; + readonly name: string | null; + readonly project: { + readonly logoUrl: string | null; + } | null; + readonly symbol: string | null; + } | null> | null; +}; +export type TopTokens100Query = { + response: TopTokens100Query$data; + variables: TopTokens100Query$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "chain" +}, +v1 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "duration" +}, +v2 = [ + { + "kind": "Variable", + "name": "chain", + "variableName": "chain" + }, + { + "kind": "Literal", + "name": "page", + "value": 1 + }, + { + "kind": "Literal", + "name": "pageSize", + "value": 100 + } +], +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v4 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null +}, +v8 = [ + { + "kind": "Literal", + "name": "currency", + "value": "USD" + } +], +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}, +v11 = [ + (v9/*: any*/), + (v10/*: any*/) +], +v12 = [ + { + "kind": "Variable", + "name": "duration", + "variableName": "duration" + } +], +v13 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "logoUrl", + "storageKey": null +}, +v14 = [ + (v9/*: any*/), + (v10/*: any*/), + (v3/*: any*/) +]; +return { + "fragment": { + "argumentDefinitions": [ + (v0/*: any*/), + (v1/*: any*/) + ], + "kind": "Fragment", + "metadata": null, + "name": "TopTokens100Query", + "selections": [ + { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "topTokens", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": (v3/*: any*/), + "action": "LOG", + "path": "topTokens.id" + }, + (v4/*: any*/), + { + "kind": "RequiredField", + "field": (v5/*: any*/), + "action": "LOG", + "path": "topTokens.chain" + }, + { + "kind": "RequiredField", + "field": (v6/*: any*/), + "action": "LOG", + "path": "topTokens.address" + }, + (v7/*: any*/), + { + "alias": null, + "args": (v8/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "totalValueLocked", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "pricePercentChange", + "plural": false, + "selections": [ + (v10/*: any*/), + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + } + ], + "storageKey": "market(currency:\"USD\")" + }, + { + "alias": null, + "args": null, + "concreteType": "TokenProject", + "kind": "LinkedField", + "name": "project", + "plural": false, + "selections": [ + (v13/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + (v1/*: any*/), + (v0/*: any*/) + ], + "kind": "Operation", + "name": "TopTokens100Query", + "selections": [ + { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "topTokens", + "plural": true, + "selections": [ + (v3/*: any*/), + (v4/*: any*/), + (v5/*: any*/), + (v6/*: any*/), + (v7/*: any*/), + { + "alias": null, + "args": (v8/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "totalValueLocked", + "plural": false, + "selections": (v14/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": (v14/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "pricePercentChange", + "plural": false, + "selections": [ + (v10/*: any*/), + (v9/*: any*/), + (v3/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v12/*: any*/), + "concreteType": "Amount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v14/*: any*/), + "storageKey": null + }, + (v3/*: any*/) + ], + "storageKey": "market(currency:\"USD\")" + }, + { + "alias": null, + "args": null, + "concreteType": "TokenProject", + "kind": "LinkedField", + "name": "project", + "plural": false, + "selections": [ + (v13/*: any*/), + (v3/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "7eca410bcfbc06385de3498ded3a9f34", + "id": null, + "metadata": {}, + "name": "TopTokens100Query", + "operationKind": "query", + "text": "query TopTokens100Query(\n $duration: HistoryDuration!\n $chain: Chain!\n) {\n topTokens(pageSize: 100, page: 1, chain: $chain) {\n id\n name\n chain\n address\n symbol\n market(currency: USD) {\n totalValueLocked {\n value\n currency\n id\n }\n price {\n value\n currency\n id\n }\n pricePercentChange(duration: $duration) {\n currency\n value\n id\n }\n volume(duration: $duration) {\n value\n currency\n id\n }\n id\n }\n project {\n logoUrl\n id\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "2a5802d51b430b2b9812ad0971b5b59b"; + +export default node; diff --git a/src/graphql/data/__generated__/TopTokensSparklineQuery.graphql.ts b/src/graphql/data/__generated__/TopTokensSparklineQuery.graphql.ts new file mode 100644 index 00000000000..c0953b8fa1a --- /dev/null +++ b/src/graphql/data/__generated__/TopTokensSparklineQuery.graphql.ts @@ -0,0 +1,227 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type HistoryDuration = "DAY" | "FIVE_MINUTE" | "HOUR" | "MAX" | "MONTH" | "WEEK" | "YEAR" | "%future added value"; +export type TopTokensSparklineQuery$variables = { + chain: Chain; + duration: HistoryDuration; +}; +export type TopTokensSparklineQuery$data = { + readonly topTokens: ReadonlyArray<{ + readonly address: string | null; + readonly market: { + readonly priceHistory: ReadonlyArray<{ + readonly timestamp: number; + readonly value: number; + } | null> | null; + } | null; + } | null> | null; +}; +export type TopTokensSparklineQuery = { + response: TopTokensSparklineQuery$data; + variables: TopTokensSparklineQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "chain" +}, +v1 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "duration" +}, +v2 = [ + { + "kind": "Variable", + "name": "chain", + "variableName": "chain" + }, + { + "kind": "Literal", + "name": "page", + "value": 1 + }, + { + "kind": "Literal", + "name": "pageSize", + "value": 100 + } +], +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v4 = [ + { + "kind": "Literal", + "name": "currency", + "value": "USD" + } +], +v5 = [ + { + "kind": "Variable", + "name": "duration", + "variableName": "duration" + } +], +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "timestamp", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v8 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": [ + (v0/*: any*/), + (v1/*: any*/) + ], + "kind": "Fragment", + "metadata": null, + "name": "TopTokensSparklineQuery", + "selections": [ + { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "topTokens", + "plural": true, + "selections": [ + (v3/*: any*/), + { + "alias": null, + "args": (v4/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": (v5/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "priceHistory", + "plural": true, + "selections": [ + { + "kind": "RequiredField", + "field": (v6/*: any*/), + "action": "LOG", + "path": "topTokens.market.priceHistory.timestamp" + }, + { + "kind": "RequiredField", + "field": (v7/*: any*/), + "action": "LOG", + "path": "topTokens.market.priceHistory.value" + } + ], + "storageKey": null + } + ], + "storageKey": "market(currency:\"USD\")" + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + (v1/*: any*/), + (v0/*: any*/) + ], + "kind": "Operation", + "name": "TopTokensSparklineQuery", + "selections": [ + { + "alias": null, + "args": (v2/*: any*/), + "concreteType": "Token", + "kind": "LinkedField", + "name": "topTokens", + "plural": true, + "selections": [ + (v3/*: any*/), + { + "alias": null, + "args": (v4/*: any*/), + "concreteType": "TokenMarket", + "kind": "LinkedField", + "name": "market", + "plural": false, + "selections": [ + { + "alias": null, + "args": (v5/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "priceHistory", + "plural": true, + "selections": [ + (v6/*: any*/), + (v7/*: any*/), + (v8/*: any*/) + ], + "storageKey": null + }, + (v8/*: any*/) + ], + "storageKey": "market(currency:\"USD\")" + }, + (v8/*: any*/) + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "4f33118105f6043bc4c5b887a68d03e3", + "id": null, + "metadata": {}, + "name": "TopTokensSparklineQuery", + "operationKind": "query", + "text": "query TopTokensSparklineQuery(\n $duration: HistoryDuration!\n $chain: Chain!\n) {\n topTokens(pageSize: 100, page: 1, chain: $chain) {\n address\n market(currency: USD) {\n priceHistory(duration: $duration) {\n timestamp\n value\n id\n }\n id\n }\n id\n }\n}\n" + } +}; +})(); + +(node as any).hash = "b120413d433f3c8044906a5bac370590"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/AssetPaginationQuery.graphql.ts b/src/graphql/data/nft/__generated__/AssetPaginationQuery.graphql.ts new file mode 100644 index 00000000000..3054b869bca --- /dev/null +++ b/src/graphql/data/nft/__generated__/AssetPaginationQuery.graphql.ts @@ -0,0 +1,635 @@ +/** + * @generated SignedSource<<4d62f2ab641df956582bab1ec8bf9980>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +import { FragmentRefs } from "relay-runtime"; +export type NftAssetSortableField = "PRICE" | "RARITY" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftAssetsFilterInput = { + listed?: boolean | null; + marketplaces?: ReadonlyArray | null; + maxPrice?: string | null; + minPrice?: string | null; + tokenIds?: ReadonlyArray | null; + tokenSearchQuery?: string | null; + traits?: ReadonlyArray | null; +}; +export type NftAssetTraitInput = { + name: string; + values: ReadonlyArray; +}; +export type AssetPaginationQuery$variables = { + address: string; + after?: string | null; + asc?: boolean | null; + before?: string | null; + filter?: NftAssetsFilterInput | null; + first?: number | null; + last?: number | null; + orderBy?: NftAssetSortableField | null; +}; +export type AssetPaginationQuery$data = { + readonly " $fragmentSpreads": FragmentRefs<"AssetQuery_nftAssets">; +}; +export type AssetPaginationQuery = { + response: AssetPaginationQuery$data; + variables: AssetPaginationQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "address" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "after" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "asc" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "before" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "filter" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "first" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "last" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "orderBy" + } +], +v1 = [ + { + "kind": "Variable", + "name": "address", + "variableName": "address" + }, + { + "kind": "Variable", + "name": "after", + "variableName": "after" + }, + { + "kind": "Variable", + "name": "asc", + "variableName": "asc" + }, + { + "kind": "Variable", + "name": "before", + "variableName": "before" + }, + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "first", + "variableName": "first" + }, + { + "kind": "Variable", + "name": "last", + "variableName": "last" + }, + { + "kind": "Variable", + "name": "orderBy", + "variableName": "orderBy" + } +], +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v4 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + }, + (v2/*: any*/) +], +v5 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null +}, +v8 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "AssetPaginationQuery", + "selections": [ + { + "args": null, + "kind": "FragmentSpread", + "name": "AssetQuery_nftAssets" + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "AssetPaginationQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftAssetConnection", + "kind": "LinkedField", + "name": "nftAssets", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAssetEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v2/*: any*/), + (v3/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + (v5/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null + }, + (v6/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + (v3/*: any*/), + (v7/*: any*/), + (v5/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftProfile", + "kind": "LinkedField", + "name": "creator", + "plural": false, + "selections": [ + (v8/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "profileImage", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null + }, + (v7/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v8/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v8/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + }, + (v2/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "maker", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplaceUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "orderHash", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "quantity", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "status", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "taker", + "storageKey": null + }, + (v6/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "type", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "protocolParameters", + "storageKey": null + } + ], + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + }, + { + "alias": null, + "args": null, + "concreteType": "NftAssetRarity", + "kind": "LinkedField", + "name": "rarities", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "provider", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "rank", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "score", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "metadataUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalCount", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v1/*: any*/), + "filters": [ + "address", + "orderBy", + "asc", + "filter" + ], + "handle": "connection", + "key": "AssetQuery_nftAssets", + "kind": "LinkedHandle", + "name": "nftAssets" + } + ] + }, + "params": { + "cacheID": "ad839d55a2fcccb92dc0c13d1d308a99", + "id": null, + "metadata": {}, + "name": "AssetPaginationQuery", + "operationKind": "query", + "text": "query AssetPaginationQuery(\n $address: String!\n $after: String\n $asc: Boolean\n $before: String\n $filter: NftAssetsFilterInput\n $first: Int\n $last: Int\n $orderBy: NftAssetSortableField\n) {\n ...AssetQuery_nftAssets\n}\n\nfragment AssetQuery_nftAssets on Query {\n nftAssets(address: $address, orderBy: $orderBy, asc: $asc, filter: $filter, first: $first, after: $after, last: $last, before: $before) {\n edges {\n node {\n id\n name\n ownerAddress\n image {\n url\n id\n }\n smallImage {\n url\n id\n }\n originalImage {\n url\n id\n }\n tokenId\n description\n animationUrl\n suspiciousFlag\n collection {\n name\n isVerified\n image {\n url\n id\n }\n creator {\n address\n profileImage {\n url\n id\n }\n isVerified\n id\n }\n nftContracts {\n address\n standard\n id\n }\n id\n }\n listings(first: 1) {\n edges {\n node {\n address\n createdAt\n endAt\n id\n maker\n marketplace\n marketplaceUrl\n orderHash\n price {\n currency\n value\n id\n }\n quantity\n startAt\n status\n taker\n tokenId\n type\n protocolParameters\n }\n cursor\n }\n }\n rarities {\n provider\n rank\n score\n id\n }\n metadataUrl\n __typename\n }\n cursor\n }\n totalCount\n pageInfo {\n endCursor\n hasNextPage\n hasPreviousPage\n startCursor\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "f6406d94b8b7549bb491fc4490cbc136"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/AssetQuery.graphql.ts b/src/graphql/data/nft/__generated__/AssetQuery.graphql.ts new file mode 100644 index 00000000000..49d4c8af59e --- /dev/null +++ b/src/graphql/data/nft/__generated__/AssetQuery.graphql.ts @@ -0,0 +1,651 @@ +/** + * @generated SignedSource<<60585ea3d2381886b33facb1f93e3f59>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +import { FragmentRefs } from "relay-runtime"; +export type NftAssetSortableField = "PRICE" | "RARITY" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftAssetsFilterInput = { + listed?: boolean | null; + marketplaces?: ReadonlyArray | null; + maxPrice?: string | null; + minPrice?: string | null; + tokenIds?: ReadonlyArray | null; + tokenSearchQuery?: string | null; + traits?: ReadonlyArray | null; +}; +export type NftAssetTraitInput = { + name: string; + values: ReadonlyArray; +}; +export type AssetQuery$variables = { + address: string; + after?: string | null; + asc?: boolean | null; + before?: string | null; + filter?: NftAssetsFilterInput | null; + first?: number | null; + last?: number | null; + orderBy?: NftAssetSortableField | null; +}; +export type AssetQuery$data = { + readonly " $fragmentSpreads": FragmentRefs<"AssetQuery_nftAssets">; +}; +export type AssetQuery = { + response: AssetQuery$data; + variables: AssetQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "address" +}, +v1 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "after" +}, +v2 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "asc" +}, +v3 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "before" +}, +v4 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "filter" +}, +v5 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "first" +}, +v6 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "last" +}, +v7 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "orderBy" +}, +v8 = [ + { + "kind": "Variable", + "name": "address", + "variableName": "address" + }, + { + "kind": "Variable", + "name": "after", + "variableName": "after" + }, + { + "kind": "Variable", + "name": "asc", + "variableName": "asc" + }, + { + "kind": "Variable", + "name": "before", + "variableName": "before" + }, + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "first", + "variableName": "first" + }, + { + "kind": "Variable", + "name": "last", + "variableName": "last" + }, + { + "kind": "Variable", + "name": "orderBy", + "variableName": "orderBy" + } +], +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v11 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + }, + (v9/*: any*/) +], +v12 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null +}, +v13 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null +}, +v14 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null +}, +v15 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v16 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": [ + (v0/*: any*/), + (v1/*: any*/), + (v2/*: any*/), + (v3/*: any*/), + (v4/*: any*/), + (v5/*: any*/), + (v6/*: any*/), + (v7/*: any*/) + ], + "kind": "Fragment", + "metadata": null, + "name": "AssetQuery", + "selections": [ + { + "args": null, + "kind": "FragmentSpread", + "name": "AssetQuery_nftAssets" + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + (v0/*: any*/), + (v7/*: any*/), + (v2/*: any*/), + (v4/*: any*/), + (v5/*: any*/), + (v1/*: any*/), + (v6/*: any*/), + (v3/*: any*/) + ], + "kind": "Operation", + "name": "AssetQuery", + "selections": [ + { + "alias": null, + "args": (v8/*: any*/), + "concreteType": "NftAssetConnection", + "kind": "LinkedField", + "name": "nftAssets", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAssetEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v9/*: any*/), + (v10/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + (v12/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + (v13/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + (v10/*: any*/), + (v14/*: any*/), + (v12/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftProfile", + "kind": "LinkedField", + "name": "creator", + "plural": false, + "selections": [ + (v15/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "profileImage", + "plural": false, + "selections": (v11/*: any*/), + "storageKey": null + }, + (v14/*: any*/), + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v15/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v15/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + }, + (v9/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "maker", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplaceUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "orderHash", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "quantity", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "status", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "taker", + "storageKey": null + }, + (v13/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "type", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "protocolParameters", + "storageKey": null + } + ], + "storageKey": null + }, + (v16/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + }, + { + "alias": null, + "args": null, + "concreteType": "NftAssetRarity", + "kind": "LinkedField", + "name": "rarities", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "provider", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "rank", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "score", + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "metadataUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + (v16/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalCount", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v8/*: any*/), + "filters": [ + "address", + "orderBy", + "asc", + "filter" + ], + "handle": "connection", + "key": "AssetQuery_nftAssets", + "kind": "LinkedHandle", + "name": "nftAssets" + } + ] + }, + "params": { + "cacheID": "8e5edc9cf886fdfa82b8ad8ea0117f2c", + "id": null, + "metadata": {}, + "name": "AssetQuery", + "operationKind": "query", + "text": "query AssetQuery(\n $address: String!\n $orderBy: NftAssetSortableField\n $asc: Boolean\n $filter: NftAssetsFilterInput\n $first: Int\n $after: String\n $last: Int\n $before: String\n) {\n ...AssetQuery_nftAssets\n}\n\nfragment AssetQuery_nftAssets on Query {\n nftAssets(address: $address, orderBy: $orderBy, asc: $asc, filter: $filter, first: $first, after: $after, last: $last, before: $before) {\n edges {\n node {\n id\n name\n ownerAddress\n image {\n url\n id\n }\n smallImage {\n url\n id\n }\n originalImage {\n url\n id\n }\n tokenId\n description\n animationUrl\n suspiciousFlag\n collection {\n name\n isVerified\n image {\n url\n id\n }\n creator {\n address\n profileImage {\n url\n id\n }\n isVerified\n id\n }\n nftContracts {\n address\n standard\n id\n }\n id\n }\n listings(first: 1) {\n edges {\n node {\n address\n createdAt\n endAt\n id\n maker\n marketplace\n marketplaceUrl\n orderHash\n price {\n currency\n value\n id\n }\n quantity\n startAt\n status\n taker\n tokenId\n type\n protocolParameters\n }\n cursor\n }\n }\n rarities {\n provider\n rank\n score\n id\n }\n metadataUrl\n __typename\n }\n cursor\n }\n totalCount\n pageInfo {\n endCursor\n hasNextPage\n hasPreviousPage\n startCursor\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "0fc1ce2d80317f61262116984e6aeb1a"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/AssetQuery_nftAssets.graphql.ts b/src/graphql/data/nft/__generated__/AssetQuery_nftAssets.graphql.ts new file mode 100644 index 00000000000..97a33582b54 --- /dev/null +++ b/src/graphql/data/nft/__generated__/AssetQuery_nftAssets.graphql.ts @@ -0,0 +1,643 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ReaderFragment, RefetchableFragment } from 'relay-runtime'; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftRarityProvider = "RARITY_SNIPER" | "%future added value"; +export type NftStandard = "ERC1155" | "ERC721" | "NONCOMPLIANT" | "%future added value"; +export type OrderStatus = "CANCELLED" | "EXECUTED" | "EXPIRED" | "VALID" | "%future added value"; +export type OrderType = "LISTING" | "OFFER" | "%future added value"; +import { FragmentRefs } from "relay-runtime"; +export type AssetQuery_nftAssets$data = { + readonly nftAssets: { + readonly edges: ReadonlyArray<{ + readonly node: { + readonly animationUrl: string | null; + readonly collection: { + readonly creator: { + readonly address: string; + readonly isVerified: boolean | null; + readonly profileImage: { + readonly url: string; + } | null; + } | null; + readonly image: { + readonly url: string; + } | null; + readonly isVerified: boolean | null; + readonly name: string | null; + readonly nftContracts: ReadonlyArray<{ + readonly address: string; + readonly standard: NftStandard | null; + }> | null; + } | null; + readonly description: string | null; + readonly id: string; + readonly image: { + readonly url: string; + } | null; + readonly listings: { + readonly edges: ReadonlyArray<{ + readonly cursor: string; + readonly node: { + readonly address: string; + readonly createdAt: number; + readonly endAt: number | null; + readonly id: string; + readonly maker: string; + readonly marketplace: NftMarketplace; + readonly marketplaceUrl: string; + readonly orderHash: string | null; + readonly price: { + readonly currency: Currency | null; + readonly value: number; + }; + readonly protocolParameters: any | null; + readonly quantity: number; + readonly startAt: number; + readonly status: OrderStatus; + readonly taker: string | null; + readonly tokenId: string | null; + readonly type: OrderType; + }; + }>; + } | null; + readonly metadataUrl: string | null; + readonly name: string | null; + readonly originalImage: { + readonly url: string; + } | null; + readonly ownerAddress: string | null; + readonly rarities: ReadonlyArray<{ + readonly provider: NftRarityProvider | null; + readonly rank: number | null; + readonly score: number | null; + }> | null; + readonly smallImage: { + readonly url: string; + } | null; + readonly suspiciousFlag: boolean | null; + readonly tokenId: string; + }; + }>; + readonly totalCount: number | null; + } | null; + readonly " $fragmentType": "AssetQuery_nftAssets"; +}; +export type AssetQuery_nftAssets$key = { + readonly " $data"?: AssetQuery_nftAssets$data; + readonly " $fragmentSpreads": FragmentRefs<"AssetQuery_nftAssets">; +}; + +const node: ReaderFragment = (function(){ +var v0 = [ + "nftAssets" +], +v1 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v3 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + } +], +v4 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v8 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null +}; +return { + "argumentDefinitions": [ + { + "kind": "RootArgument", + "name": "address" + }, + { + "kind": "RootArgument", + "name": "after" + }, + { + "kind": "RootArgument", + "name": "asc" + }, + { + "kind": "RootArgument", + "name": "before" + }, + { + "kind": "RootArgument", + "name": "filter" + }, + { + "kind": "RootArgument", + "name": "first" + }, + { + "kind": "RootArgument", + "name": "last" + }, + { + "kind": "RootArgument", + "name": "orderBy" + } + ], + "kind": "Fragment", + "metadata": { + "connection": [ + { + "count": null, + "cursor": null, + "direction": "bidirectional", + "path": (v0/*: any*/) + } + ], + "refetch": { + "connection": { + "forward": { + "count": "first", + "cursor": "after" + }, + "backward": { + "count": "last", + "cursor": "before" + }, + "path": (v0/*: any*/) + }, + "fragmentPathInResult": [], + "operation": require('./AssetPaginationQuery.graphql') + } + }, + "name": "AssetQuery_nftAssets", + "selections": [ + { + "alias": "nftAssets", + "args": [ + { + "kind": "Variable", + "name": "address", + "variableName": "address" + }, + { + "kind": "Variable", + "name": "asc", + "variableName": "asc" + }, + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "orderBy", + "variableName": "orderBy" + } + ], + "concreteType": "NftAssetConnection", + "kind": "LinkedField", + "name": "__AssetQuery_nftAssets_connection", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAssetEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v1/*: any*/), + (v2/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + (v4/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + (v5/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + (v2/*: any*/), + (v6/*: any*/), + (v4/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftProfile", + "kind": "LinkedField", + "name": "creator", + "plural": false, + "selections": [ + (v7/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "profileImage", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + (v6/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v7/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v7/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + }, + (v1/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "maker", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplaceUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "orderHash", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "quantity", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "status", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "taker", + "storageKey": null + }, + (v5/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "type", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "protocolParameters", + "storageKey": null + } + ], + "storageKey": null + }, + (v8/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + }, + { + "alias": null, + "args": null, + "concreteType": "NftAssetRarity", + "kind": "LinkedField", + "name": "rarities", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "provider", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "rank", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "score", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "metadataUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + (v8/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalCount", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null +}; +})(); + +(node as any).hash = "f6406d94b8b7549bb491fc4490cbc136"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/CollectionQuery.graphql.ts b/src/graphql/data/nft/__generated__/CollectionQuery.graphql.ts new file mode 100644 index 00000000000..258a3304acc --- /dev/null +++ b/src/graphql/data/nft/__generated__/CollectionQuery.graphql.ts @@ -0,0 +1,808 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftStandard = "ERC1155" | "ERC721" | "NONCOMPLIANT" | "%future added value"; +export type CollectionQuery$variables = { + addresses: ReadonlyArray; +}; +export type CollectionQuery$data = { + readonly nftCollections: { + readonly edges: ReadonlyArray<{ + readonly cursor: string; + readonly node: { + readonly bannerImage: { + readonly url: string; + } | null; + readonly collectionId: string; + readonly description: string | null; + readonly discordUrl: string | null; + readonly homepageUrl: string | null; + readonly image: { + readonly url: string; + } | null; + readonly instagramName: string | null; + readonly isVerified: boolean | null; + readonly markets: ReadonlyArray<{ + readonly floorPrice: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly floorPricePercentChange: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly listings: { + readonly value: number; + } | null; + readonly marketplaces: ReadonlyArray<{ + readonly floorPrice: number | null; + readonly listings: number | null; + readonly marketplace: NftMarketplace | null; + }> | null; + readonly owners: number | null; + readonly totalVolume: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly volume: { + readonly currency: Currency | null; + readonly value: number; + } | null; + readonly volumePercentChange: { + readonly currency: Currency | null; + readonly value: number; + } | null; + }> | null; + readonly name: string | null; + readonly nftContracts: ReadonlyArray<{ + readonly address: string; + readonly chain: Chain; + readonly name: string | null; + readonly standard: NftStandard | null; + readonly symbol: string | null; + readonly totalSupply: number | null; + }> | null; + readonly numAssets: number | null; + readonly traits: ReadonlyArray<{ + readonly name: string | null; + readonly stats: ReadonlyArray<{ + readonly assets: number | null; + readonly listings: number | null; + readonly name: string | null; + readonly value: string | null; + }> | null; + readonly values: ReadonlyArray | null; + }> | null; + readonly twitterName: string | null; + }; + }>; + readonly pageInfo: { + readonly endCursor: string | null; + readonly hasNextPage: boolean | null; + readonly hasPreviousPage: boolean | null; + readonly startCursor: string | null; + }; + } | null; +}; +export type CollectionQuery = { + response: CollectionQuery$data; + variables: CollectionQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "addresses" + } +], +v1 = [ + { + "fields": [ + { + "kind": "Variable", + "name": "addresses", + "variableName": "addresses" + } + ], + "kind": "ObjectValue", + "name": "filter" + } +], +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null +}, +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null +}, +v4 = [ + (v3/*: any*/) +], +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "collectionId", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "discordUrl", + "storageKey": null +}, +v8 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "homepageUrl", + "storageKey": null +}, +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "instagramName", + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null +}, +v11 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v12 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "numAssets", + "storageKey": null +}, +v13 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "twitterName", + "storageKey": null +}, +v14 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v15 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null +}, +v16 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null +}, +v17 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null +}, +v18 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalSupply", + "storageKey": null +}, +v19 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "values", + "storageKey": null +}, +v20 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v21 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "assets", + "storageKey": null +}, +v22 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "listings", + "storageKey": null +}, +v23 = [ + { + "kind": "Literal", + "name": "currencies", + "value": "ETH" + } +], +v24 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}, +v25 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "owners", + "storageKey": null +}, +v26 = [ + (v20/*: any*/), + (v24/*: any*/) +], +v27 = [ + { + "kind": "Literal", + "name": "duration", + "value": "DAY" + } +], +v28 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null +}, +v29 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "floorPrice", + "storageKey": null +}, +v30 = { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null +}, +v31 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v32 = [ + (v3/*: any*/), + (v31/*: any*/) +], +v33 = [ + (v20/*: any*/), + (v24/*: any*/), + (v31/*: any*/) +]; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "CollectionQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftCollectionConnection", + "kind": "LinkedField", + "name": "nftCollections", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftCollectionEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + (v2/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "bannerImage", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null + }, + (v5/*: any*/), + (v6/*: any*/), + (v7/*: any*/), + (v8/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v4/*: any*/), + "storageKey": null + }, + (v9/*: any*/), + (v10/*: any*/), + (v11/*: any*/), + (v12/*: any*/), + (v13/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v14/*: any*/), + (v15/*: any*/), + (v11/*: any*/), + (v16/*: any*/), + (v17/*: any*/), + (v18/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollectionTrait", + "kind": "LinkedField", + "name": "traits", + "plural": true, + "selections": [ + (v11/*: any*/), + (v19/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftCollectionTraitStats", + "kind": "LinkedField", + "name": "stats", + "plural": true, + "selections": [ + (v11/*: any*/), + (v20/*: any*/), + (v21/*: any*/), + (v22/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v23/*: any*/), + "concreteType": "NftCollectionMarket", + "kind": "LinkedField", + "name": "markets", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPrice", + "plural": false, + "selections": [ + (v24/*: any*/), + (v20/*: any*/) + ], + "storageKey": null + }, + (v25/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "totalVolume", + "plural": false, + "selections": (v26/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + (v20/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v26/*: any*/), + "storageKey": "volume(duration:\"DAY\")" + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "volumePercentChange", + "plural": false, + "selections": (v26/*: any*/), + "storageKey": "volumePercentChange(duration:\"DAY\")" + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPricePercentChange", + "plural": false, + "selections": (v26/*: any*/), + "storageKey": "floorPricePercentChange(duration:\"DAY\")" + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollectionMarketplace", + "kind": "LinkedField", + "name": "marketplaces", + "plural": true, + "selections": [ + (v28/*: any*/), + (v22/*: any*/), + (v29/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "markets(currencies:\"ETH\")" + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + (v30/*: any*/) + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "CollectionQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftCollectionConnection", + "kind": "LinkedField", + "name": "nftCollections", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftCollectionEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + (v2/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "bannerImage", + "plural": false, + "selections": (v32/*: any*/), + "storageKey": null + }, + (v5/*: any*/), + (v6/*: any*/), + (v7/*: any*/), + (v8/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v32/*: any*/), + "storageKey": null + }, + (v9/*: any*/), + (v10/*: any*/), + (v11/*: any*/), + (v12/*: any*/), + (v13/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v14/*: any*/), + (v15/*: any*/), + (v11/*: any*/), + (v16/*: any*/), + (v17/*: any*/), + (v18/*: any*/), + (v31/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollectionTrait", + "kind": "LinkedField", + "name": "traits", + "plural": true, + "selections": [ + (v11/*: any*/), + (v19/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftCollectionTraitStats", + "kind": "LinkedField", + "name": "stats", + "plural": true, + "selections": [ + (v11/*: any*/), + (v20/*: any*/), + (v21/*: any*/), + (v22/*: any*/), + (v31/*: any*/) + ], + "storageKey": null + }, + (v31/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v23/*: any*/), + "concreteType": "NftCollectionMarket", + "kind": "LinkedField", + "name": "markets", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPrice", + "plural": false, + "selections": [ + (v24/*: any*/), + (v20/*: any*/), + (v31/*: any*/) + ], + "storageKey": null + }, + (v25/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "totalVolume", + "plural": false, + "selections": (v33/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + (v20/*: any*/), + (v31/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "volume", + "plural": false, + "selections": (v33/*: any*/), + "storageKey": "volume(duration:\"DAY\")" + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "volumePercentChange", + "plural": false, + "selections": (v33/*: any*/), + "storageKey": "volumePercentChange(duration:\"DAY\")" + }, + { + "alias": null, + "args": (v27/*: any*/), + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPricePercentChange", + "plural": false, + "selections": (v33/*: any*/), + "storageKey": "floorPricePercentChange(duration:\"DAY\")" + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollectionMarketplace", + "kind": "LinkedField", + "name": "marketplaces", + "plural": true, + "selections": [ + (v28/*: any*/), + (v22/*: any*/), + (v29/*: any*/), + (v31/*: any*/) + ], + "storageKey": null + }, + (v31/*: any*/) + ], + "storageKey": "markets(currencies:\"ETH\")" + }, + (v31/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + }, + (v30/*: any*/) + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "c86c5cc75669b51469ee70eb1759b687", + "id": null, + "metadata": {}, + "name": "CollectionQuery", + "operationKind": "query", + "text": "query CollectionQuery(\n $addresses: [String!]!\n) {\n nftCollections(filter: {addresses: $addresses}) {\n edges {\n cursor\n node {\n bannerImage {\n url\n id\n }\n collectionId\n description\n discordUrl\n homepageUrl\n image {\n url\n id\n }\n instagramName\n isVerified\n name\n numAssets\n twitterName\n nftContracts {\n address\n chain\n name\n standard\n symbol\n totalSupply\n id\n }\n traits {\n name\n values\n stats {\n name\n value\n assets\n listings\n id\n }\n id\n }\n markets(currencies: ETH) {\n floorPrice {\n currency\n value\n id\n }\n owners\n totalVolume {\n value\n currency\n id\n }\n listings {\n value\n id\n }\n volume(duration: DAY) {\n value\n currency\n id\n }\n volumePercentChange(duration: DAY) {\n value\n currency\n id\n }\n floorPricePercentChange(duration: DAY) {\n value\n currency\n id\n }\n marketplaces {\n marketplace\n listings\n floorPrice\n id\n }\n id\n }\n id\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n hasPreviousPage\n startCursor\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "4c0e5aa05e2013b0902d0b7f22c18f0b"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/DetailsQuery.graphql.ts b/src/graphql/data/nft/__generated__/DetailsQuery.graphql.ts new file mode 100644 index 00000000000..0cc9f5d340a --- /dev/null +++ b/src/graphql/data/nft/__generated__/DetailsQuery.graphql.ts @@ -0,0 +1,874 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftRarityProvider = "RARITY_SNIPER" | "%future added value"; +export type NftStandard = "ERC1155" | "ERC721" | "NONCOMPLIANT" | "%future added value"; +export type OrderStatus = "CANCELLED" | "EXECUTED" | "EXPIRED" | "VALID" | "%future added value"; +export type OrderType = "LISTING" | "OFFER" | "%future added value"; +export type DetailsQuery$variables = { + address: string; + tokenId: string; +}; +export type DetailsQuery$data = { + readonly nftAssets: { + readonly edges: ReadonlyArray<{ + readonly node: { + readonly animationUrl: string | null; + readonly collection: { + readonly description: string | null; + readonly discordUrl: string | null; + readonly homepageUrl: string | null; + readonly image: { + readonly url: string; + } | null; + readonly isVerified: boolean | null; + readonly name: string | null; + readonly nftContracts: ReadonlyArray<{ + readonly address: string; + readonly standard: NftStandard | null; + }> | null; + readonly numAssets: number | null; + readonly twitterName: string | null; + } | null; + readonly creator: { + readonly address: string; + readonly isVerified: boolean | null; + readonly profileImage: { + readonly url: string; + } | null; + } | null; + readonly description: string | null; + readonly id: string; + readonly image: { + readonly url: string; + } | null; + readonly listings: { + readonly edges: ReadonlyArray<{ + readonly cursor: string; + readonly node: { + readonly address: string; + readonly createdAt: number; + readonly endAt: number | null; + readonly id: string; + readonly maker: string; + readonly marketplace: NftMarketplace; + readonly marketplaceUrl: string; + readonly orderHash: string | null; + readonly price: { + readonly currency: Currency | null; + readonly value: number; + }; + readonly protocolParameters: any | null; + readonly quantity: number; + readonly startAt: number; + readonly status: OrderStatus; + readonly taker: string | null; + readonly tokenId: string | null; + readonly type: OrderType; + }; + }>; + } | null; + readonly metadataUrl: string | null; + readonly name: string | null; + readonly originalImage: { + readonly url: string; + } | null; + readonly ownerAddress: string | null; + readonly rarities: ReadonlyArray<{ + readonly provider: NftRarityProvider | null; + readonly rank: number | null; + readonly score: number | null; + }> | null; + readonly smallImage: { + readonly url: string; + } | null; + readonly suspiciousFlag: boolean | null; + readonly tokenId: string; + readonly traits: ReadonlyArray<{ + readonly name: string | null; + readonly value: string | null; + }> | null; + }; + }>; + } | null; +}; +export type DetailsQuery = { + response: DetailsQuery$data; + variables: DetailsQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "address" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "tokenId" + } +], +v1 = [ + { + "kind": "Variable", + "name": "address", + "variableName": "address" + }, + { + "fields": [ + { + "kind": "Literal", + "name": "listed", + "value": false + }, + { + "items": [ + { + "kind": "Variable", + "name": "tokenIds.0", + "variableName": "tokenId" + } + ], + "kind": "ListValue", + "name": "tokenIds" + } + ], + "kind": "ObjectValue", + "name": "filter" + } +], +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v4 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null +}, +v6 = [ + (v5/*: any*/) +], +v7 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v6/*: any*/), + "storageKey": null +}, +v8 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null +}, +v9 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null +}, +v11 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null +}, +v12 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null +}, +v13 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null +}, +v14 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "numAssets", + "storageKey": null +}, +v15 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "twitterName", + "storageKey": null +}, +v16 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "discordUrl", + "storageKey": null +}, +v17 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "homepageUrl", + "storageKey": null +}, +v18 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null +}, +v19 = [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } +], +v20 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null +}, +v21 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null +}, +v22 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "maker", + "storageKey": null +}, +v23 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null +}, +v24 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplaceUrl", + "storageKey": null +}, +v25 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "orderHash", + "storageKey": null +}, +v26 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}, +v27 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v28 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "quantity", + "storageKey": null +}, +v29 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startAt", + "storageKey": null +}, +v30 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "status", + "storageKey": null +}, +v31 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "taker", + "storageKey": null +}, +v32 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "type", + "storageKey": null +}, +v33 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "protocolParameters", + "storageKey": null +}, +v34 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null +}, +v35 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "provider", + "storageKey": null +}, +v36 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "rank", + "storageKey": null +}, +v37 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "score", + "storageKey": null +}, +v38 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "metadataUrl", + "storageKey": null +}, +v39 = [ + (v5/*: any*/), + (v2/*: any*/) +], +v40 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v39/*: any*/), + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "DetailsQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftAssetConnection", + "kind": "LinkedField", + "name": "nftAssets", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAssetEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v2/*: any*/), + (v3/*: any*/), + (v4/*: any*/), + (v7/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v6/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v6/*: any*/), + "storageKey": null + }, + (v8/*: any*/), + (v9/*: any*/), + (v10/*: any*/), + (v11/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftProfile", + "kind": "LinkedField", + "name": "creator", + "plural": false, + "selections": [ + (v12/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "profileImage", + "plural": false, + "selections": (v6/*: any*/), + "storageKey": null + }, + (v13/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + (v3/*: any*/), + (v13/*: any*/), + (v14/*: any*/), + (v15/*: any*/), + (v16/*: any*/), + (v17/*: any*/), + (v7/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v12/*: any*/), + (v18/*: any*/) + ], + "storageKey": null + }, + (v9/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v19/*: any*/), + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v12/*: any*/), + (v20/*: any*/), + (v21/*: any*/), + (v2/*: any*/), + (v22/*: any*/), + (v23/*: any*/), + (v24/*: any*/), + (v25/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v26/*: any*/), + (v27/*: any*/) + ], + "storageKey": null + }, + (v28/*: any*/), + (v29/*: any*/), + (v30/*: any*/), + (v31/*: any*/), + (v8/*: any*/), + (v32/*: any*/), + (v33/*: any*/) + ], + "storageKey": null + }, + (v34/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + }, + { + "alias": null, + "args": null, + "concreteType": "NftAssetRarity", + "kind": "LinkedField", + "name": "rarities", + "plural": true, + "selections": [ + (v35/*: any*/), + (v36/*: any*/), + (v37/*: any*/) + ], + "storageKey": null + }, + (v38/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftAssetTrait", + "kind": "LinkedField", + "name": "traits", + "plural": true, + "selections": [ + (v3/*: any*/), + (v27/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "DetailsQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftAssetConnection", + "kind": "LinkedField", + "name": "nftAssets", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAssetEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v2/*: any*/), + (v3/*: any*/), + (v4/*: any*/), + (v40/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v39/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v39/*: any*/), + "storageKey": null + }, + (v8/*: any*/), + (v9/*: any*/), + (v10/*: any*/), + (v11/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftProfile", + "kind": "LinkedField", + "name": "creator", + "plural": false, + "selections": [ + (v12/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "profileImage", + "plural": false, + "selections": (v39/*: any*/), + "storageKey": null + }, + (v13/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + (v3/*: any*/), + (v13/*: any*/), + (v14/*: any*/), + (v15/*: any*/), + (v16/*: any*/), + (v17/*: any*/), + (v40/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + (v12/*: any*/), + (v18/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v9/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": (v19/*: any*/), + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + (v12/*: any*/), + (v20/*: any*/), + (v21/*: any*/), + (v2/*: any*/), + (v22/*: any*/), + (v23/*: any*/), + (v24/*: any*/), + (v25/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v26/*: any*/), + (v27/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v28/*: any*/), + (v29/*: any*/), + (v30/*: any*/), + (v31/*: any*/), + (v8/*: any*/), + (v32/*: any*/), + (v33/*: any*/) + ], + "storageKey": null + }, + (v34/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + }, + { + "alias": null, + "args": null, + "concreteType": "NftAssetRarity", + "kind": "LinkedField", + "name": "rarities", + "plural": true, + "selections": [ + (v35/*: any*/), + (v36/*: any*/), + (v37/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v38/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftAssetTrait", + "kind": "LinkedField", + "name": "traits", + "plural": true, + "selections": [ + (v3/*: any*/), + (v27/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "614aec51be138a694322837c39c2b19a", + "id": null, + "metadata": {}, + "name": "DetailsQuery", + "operationKind": "query", + "text": "query DetailsQuery(\n $address: String!\n $tokenId: String!\n) {\n nftAssets(address: $address, filter: {listed: false, tokenIds: [$tokenId]}) {\n edges {\n node {\n id\n name\n ownerAddress\n image {\n url\n id\n }\n smallImage {\n url\n id\n }\n originalImage {\n url\n id\n }\n tokenId\n description\n animationUrl\n suspiciousFlag\n creator {\n address\n profileImage {\n url\n id\n }\n isVerified\n id\n }\n collection {\n name\n isVerified\n numAssets\n twitterName\n discordUrl\n homepageUrl\n image {\n url\n id\n }\n nftContracts {\n address\n standard\n id\n }\n description\n id\n }\n listings(first: 1) {\n edges {\n node {\n address\n createdAt\n endAt\n id\n maker\n marketplace\n marketplaceUrl\n orderHash\n price {\n currency\n value\n id\n }\n quantity\n startAt\n status\n taker\n tokenId\n type\n protocolParameters\n }\n cursor\n }\n }\n rarities {\n provider\n rank\n score\n id\n }\n metadataUrl\n traits {\n name\n value\n id\n }\n }\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "71907572f7abd6bed7fde358e2b81be0"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/NftBalancePaginationQuery.graphql.ts b/src/graphql/data/nft/__generated__/NftBalancePaginationQuery.graphql.ts new file mode 100644 index 00000000000..e8ee4c90a9f --- /dev/null +++ b/src/graphql/data/nft/__generated__/NftBalancePaginationQuery.graphql.ts @@ -0,0 +1,602 @@ +/** + * @generated SignedSource<<8eeec161dc19c266088160637611448d>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +import { FragmentRefs } from "relay-runtime"; +export type NftBalancesFilterInput = { + addresses?: ReadonlyArray | null; + assets?: ReadonlyArray | null; + filterSpam?: boolean | null; +}; +export type NftBalanceAssetInput = { + address: string; + tokenId: string; +}; +export type NftBalancePaginationQuery$variables = { + after?: string | null; + before?: string | null; + filter?: NftBalancesFilterInput | null; + first?: number | null; + last?: number | null; + ownerAddress: string; +}; +export type NftBalancePaginationQuery$data = { + readonly " $fragmentSpreads": FragmentRefs<"NftBalanceQuery_nftBalances">; +}; +export type NftBalancePaginationQuery = { + response: NftBalancePaginationQuery$data; + variables: NftBalancePaginationQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = [ + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "after" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "before" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "filter" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "first" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "last" + }, + { + "defaultValue": null, + "kind": "LocalArgument", + "name": "ownerAddress" + } +], +v1 = [ + { + "kind": "Variable", + "name": "after", + "variableName": "after" + }, + { + "kind": "Variable", + "name": "before", + "variableName": "before" + }, + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "first", + "variableName": "first" + }, + { + "kind": "Variable", + "name": "last", + "variableName": "last" + }, + { + "kind": "Variable", + "name": "ownerAddress", + "variableName": "ownerAddress" + } +], +v2 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v3 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + }, + (v2/*: any*/) +], +v4 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v6 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Fragment", + "metadata": null, + "name": "NftBalancePaginationQuery", + "selections": [ + { + "args": null, + "kind": "FragmentSpread", + "name": "NftBalanceQuery_nftBalances" + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": (v0/*: any*/), + "kind": "Operation", + "name": "NftBalancePaginationQuery", + "selections": [ + { + "alias": null, + "args": (v1/*: any*/), + "concreteType": "NftBalanceConnection", + "kind": "LinkedField", + "name": "nftBalances", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalanceEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalance", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "ownedAsset", + "plural": false, + "selections": [ + (v2/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null + }, + (v4/*: any*/), + (v5/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null + }, + (v5/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalSupply", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "currencies", + "value": "ETH" + } + ], + "concreteType": "NftCollectionMarket", + "kind": "LinkedField", + "name": "markets", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPrice", + "plural": false, + "selections": [ + (v6/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": "markets(currencies:\"ETH\")" + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "flaggedBy", + "storageKey": null + }, + (v4/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + (v5/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "thumbnail", + "plural": false, + "selections": (v3/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v6/*: any*/), + (v7/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "listedMarketplaces", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftFee", + "kind": "LinkedField", + "name": "listingFees", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "payoutAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "basisPoints", + "storageKey": null + }, + (v2/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "lastPrice", + "plural": false, + "selections": [ + (v7/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "timestamp", + "storageKey": null + }, + (v6/*: any*/), + (v2/*: any*/) + ], + "storageKey": null + }, + (v2/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v1/*: any*/), + "filters": [ + "ownerAddress", + "filter" + ], + "handle": "connection", + "key": "NftBalanceQuery_nftBalances", + "kind": "LinkedHandle", + "name": "nftBalances" + } + ] + }, + "params": { + "cacheID": "58f8cb210f4be23460e77ddb3a9b8be7", + "id": null, + "metadata": {}, + "name": "NftBalancePaginationQuery", + "operationKind": "query", + "text": "query NftBalancePaginationQuery(\n $after: String\n $before: String\n $filter: NftBalancesFilterInput\n $first: Int\n $last: Int\n $ownerAddress: String!\n) {\n ...NftBalanceQuery_nftBalances\n}\n\nfragment NftBalanceQuery_nftBalances on Query {\n nftBalances(ownerAddress: $ownerAddress, filter: $filter, first: $first, after: $after, last: $last, before: $before) {\n edges {\n node {\n ownedAsset {\n id\n animationUrl\n collection {\n isVerified\n image {\n url\n id\n }\n name\n nftContracts {\n address\n chain\n name\n standard\n symbol\n totalSupply\n id\n }\n markets(currencies: ETH) {\n floorPrice {\n value\n id\n }\n id\n }\n id\n }\n description\n flaggedBy\n image {\n url\n id\n }\n originalImage {\n url\n id\n }\n name\n ownerAddress\n smallImage {\n url\n id\n }\n suspiciousFlag\n tokenId\n thumbnail {\n url\n id\n }\n listings(first: 1) {\n edges {\n node {\n price {\n value\n currency\n id\n }\n createdAt\n marketplace\n endAt\n id\n }\n }\n }\n }\n listedMarketplaces\n listingFees {\n payoutAddress\n basisPoints\n id\n }\n lastPrice {\n currency\n timestamp\n value\n id\n }\n id\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n hasPreviousPage\n startCursor\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "51ba85a72e5973ac0faad0e8d2c4b681"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/NftBalanceQuery.graphql.ts b/src/graphql/data/nft/__generated__/NftBalanceQuery.graphql.ts new file mode 100644 index 00000000000..5b5945f6604 --- /dev/null +++ b/src/graphql/data/nft/__generated__/NftBalanceQuery.graphql.ts @@ -0,0 +1,614 @@ +/** + * @generated SignedSource<<13d45bc7fe372e1ab62ce295bf3da309>> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +import { FragmentRefs } from "relay-runtime"; +export type NftBalancesFilterInput = { + addresses?: ReadonlyArray | null; + assets?: ReadonlyArray | null; + filterSpam?: boolean | null; +}; +export type NftBalanceAssetInput = { + address: string; + tokenId: string; +}; +export type NftBalanceQuery$variables = { + after?: string | null; + before?: string | null; + filter?: NftBalancesFilterInput | null; + first?: number | null; + last?: number | null; + ownerAddress: string; +}; +export type NftBalanceQuery$data = { + readonly " $fragmentSpreads": FragmentRefs<"NftBalanceQuery_nftBalances">; +}; +export type NftBalanceQuery = { + response: NftBalanceQuery$data; + variables: NftBalanceQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +var v0 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "after" +}, +v1 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "before" +}, +v2 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "filter" +}, +v3 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "first" +}, +v4 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "last" +}, +v5 = { + "defaultValue": null, + "kind": "LocalArgument", + "name": "ownerAddress" +}, +v6 = [ + { + "kind": "Variable", + "name": "after", + "variableName": "after" + }, + { + "kind": "Variable", + "name": "before", + "variableName": "before" + }, + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "first", + "variableName": "first" + }, + { + "kind": "Variable", + "name": "last", + "variableName": "last" + }, + { + "kind": "Variable", + "name": "ownerAddress", + "variableName": "ownerAddress" + } +], +v7 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null +}, +v8 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + }, + (v7/*: any*/) +], +v9 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v8/*: any*/), + "storageKey": null +}, +v10 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v11 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v12 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}; +return { + "fragment": { + "argumentDefinitions": [ + (v0/*: any*/), + (v1/*: any*/), + (v2/*: any*/), + (v3/*: any*/), + (v4/*: any*/), + (v5/*: any*/) + ], + "kind": "Fragment", + "metadata": null, + "name": "NftBalanceQuery", + "selections": [ + { + "args": null, + "kind": "FragmentSpread", + "name": "NftBalanceQuery_nftBalances" + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + (v5/*: any*/), + (v2/*: any*/), + (v3/*: any*/), + (v0/*: any*/), + (v4/*: any*/), + (v1/*: any*/) + ], + "kind": "Operation", + "name": "NftBalanceQuery", + "selections": [ + { + "alias": null, + "args": (v6/*: any*/), + "concreteType": "NftBalanceConnection", + "kind": "LinkedField", + "name": "nftBalances", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalanceEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalance", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "ownedAsset", + "plural": false, + "selections": [ + (v7/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null + }, + (v9/*: any*/), + (v10/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null + }, + (v10/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalSupply", + "storageKey": null + }, + (v7/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "currencies", + "value": "ETH" + } + ], + "concreteType": "NftCollectionMarket", + "kind": "LinkedField", + "name": "markets", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPrice", + "plural": false, + "selections": [ + (v11/*: any*/), + (v7/*: any*/) + ], + "storageKey": null + }, + (v7/*: any*/) + ], + "storageKey": "markets(currencies:\"ETH\")" + }, + (v7/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "flaggedBy", + "storageKey": null + }, + (v9/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v8/*: any*/), + "storageKey": null + }, + (v10/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v8/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "thumbnail", + "plural": false, + "selections": (v8/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v11/*: any*/), + (v12/*: any*/), + (v7/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + }, + (v7/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "listedMarketplaces", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftFee", + "kind": "LinkedField", + "name": "listingFees", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "payoutAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "basisPoints", + "storageKey": null + }, + (v7/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "lastPrice", + "plural": false, + "selections": [ + (v12/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "timestamp", + "storageKey": null + }, + (v11/*: any*/), + (v7/*: any*/) + ], + "storageKey": null + }, + (v7/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": (v6/*: any*/), + "filters": [ + "ownerAddress", + "filter" + ], + "handle": "connection", + "key": "NftBalanceQuery_nftBalances", + "kind": "LinkedHandle", + "name": "nftBalances" + } + ] + }, + "params": { + "cacheID": "9877ad50562691fac3d95c81955708f4", + "id": null, + "metadata": {}, + "name": "NftBalanceQuery", + "operationKind": "query", + "text": "query NftBalanceQuery(\n $ownerAddress: String!\n $filter: NftBalancesFilterInput\n $first: Int\n $after: String\n $last: Int\n $before: String\n) {\n ...NftBalanceQuery_nftBalances\n}\n\nfragment NftBalanceQuery_nftBalances on Query {\n nftBalances(ownerAddress: $ownerAddress, filter: $filter, first: $first, after: $after, last: $last, before: $before) {\n edges {\n node {\n ownedAsset {\n id\n animationUrl\n collection {\n isVerified\n image {\n url\n id\n }\n name\n nftContracts {\n address\n chain\n name\n standard\n symbol\n totalSupply\n id\n }\n markets(currencies: ETH) {\n floorPrice {\n value\n id\n }\n id\n }\n id\n }\n description\n flaggedBy\n image {\n url\n id\n }\n originalImage {\n url\n id\n }\n name\n ownerAddress\n smallImage {\n url\n id\n }\n suspiciousFlag\n tokenId\n thumbnail {\n url\n id\n }\n listings(first: 1) {\n edges {\n node {\n price {\n value\n currency\n id\n }\n createdAt\n marketplace\n endAt\n id\n }\n }\n }\n }\n listedMarketplaces\n listingFees {\n payoutAddress\n basisPoints\n id\n }\n lastPrice {\n currency\n timestamp\n value\n id\n }\n id\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n hasPreviousPage\n startCursor\n }\n }\n}\n" + } +}; +})(); + +(node as any).hash = "2e8e89ede5c7d0bdfa02b2d773b206c6"; + +export default node; diff --git a/src/graphql/data/nft/__generated__/NftBalanceQuery_nftBalances.graphql.ts b/src/graphql/data/nft/__generated__/NftBalanceQuery_nftBalances.graphql.ts new file mode 100644 index 00000000000..bacd98f5c10 --- /dev/null +++ b/src/graphql/data/nft/__generated__/NftBalanceQuery_nftBalances.graphql.ts @@ -0,0 +1,619 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ReaderFragment, RefetchableFragment } from 'relay-runtime'; +export type Chain = "ARBITRUM" | "ARBITRUM_SEPOLIA" | "ASTROCHAIN_SEPOLIA" | "AVALANCHE" | "BASE" | "BASE_SEPOLIA" | "BLAST" | "BNB" | "CELO" | "ETHEREUM" | "ETHEREUM_GOERLI" | "ETHEREUM_SEPOLIA" | "MONAD" | "MONAD_TESTNET" | "OPTIMISM" | "POLYGON" | "SOLANA" | "SONEIUM" | "UNICHAIN" | "UNKNOWN_CHAIN" | "WORLDCHAIN" | "XLAYER" | "ZKSYNC" | "ZORA" | "%future added value"; +export type Currency = "ARS" | "AUD" | "BRL" | "CAD" | "CNY" | "COP" | "ETH" | "EUR" | "GBP" | "HKD" | "IDR" | "INR" | "JPY" | "KRW" | "MATIC" | "MXN" | "NGN" | "NZD" | "PKR" | "RUB" | "SGD" | "THB" | "TRY" | "UAH" | "USD" | "VND" | "%future added value"; +export type NftMarketplace = "CRYPTOPUNKS" | "FOUNDATION" | "LOOKSRARE" | "NFT20" | "NFTX" | "OPENSEA" | "SUDOSWAP" | "X2Y2" | "%future added value"; +export type NftStandard = "ERC1155" | "ERC721" | "NONCOMPLIANT" | "%future added value"; +import { FragmentRefs } from "relay-runtime"; +export type NftBalanceQuery_nftBalances$data = { + readonly nftBalances: { + readonly edges: ReadonlyArray<{ + readonly node: { + readonly lastPrice: { + readonly currency: Currency | null; + readonly timestamp: number; + readonly value: number; + } | null; + readonly listedMarketplaces: ReadonlyArray | null; + readonly listingFees: ReadonlyArray<{ + readonly basisPoints: number; + readonly payoutAddress: string; + } | null> | null; + readonly ownedAsset: { + readonly animationUrl: string | null; + readonly collection: { + readonly image: { + readonly url: string; + } | null; + readonly isVerified: boolean | null; + readonly markets: ReadonlyArray<{ + readonly floorPrice: { + readonly value: number; + } | null; + }> | null; + readonly name: string | null; + readonly nftContracts: ReadonlyArray<{ + readonly address: string; + readonly chain: Chain; + readonly name: string | null; + readonly standard: NftStandard | null; + readonly symbol: string | null; + readonly totalSupply: number | null; + }> | null; + } | null; + readonly description: string | null; + readonly flaggedBy: string | null; + readonly id: string; + readonly image: { + readonly url: string; + } | null; + readonly listings: { + readonly edges: ReadonlyArray<{ + readonly node: { + readonly createdAt: number; + readonly endAt: number | null; + readonly marketplace: NftMarketplace; + readonly price: { + readonly currency: Currency | null; + readonly value: number; + }; + }; + }>; + } | null; + readonly name: string | null; + readonly originalImage: { + readonly url: string; + } | null; + readonly ownerAddress: string | null; + readonly smallImage: { + readonly url: string; + } | null; + readonly suspiciousFlag: boolean | null; + readonly thumbnail: { + readonly url: string; + } | null; + readonly tokenId: string; + } | null; + }; + }>; + readonly pageInfo: { + readonly endCursor: string | null; + readonly hasNextPage: boolean | null; + readonly hasPreviousPage: boolean | null; + readonly startCursor: string | null; + }; + } | null; + readonly " $fragmentType": "NftBalanceQuery_nftBalances"; +}; +export type NftBalanceQuery_nftBalances$key = { + readonly " $data"?: NftBalanceQuery_nftBalances$data; + readonly " $fragmentSpreads": FragmentRefs<"NftBalanceQuery_nftBalances">; +}; + +const node: ReaderFragment = (function(){ +var v0 = [ + "nftBalances" +], +v1 = [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "url", + "storageKey": null + } +], +v2 = { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "image", + "plural": false, + "selections": (v1/*: any*/), + "storageKey": null +}, +v3 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "name", + "storageKey": null +}, +v4 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "value", + "storageKey": null +}, +v5 = { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "currency", + "storageKey": null +}; +return { + "argumentDefinitions": [ + { + "kind": "RootArgument", + "name": "after" + }, + { + "kind": "RootArgument", + "name": "before" + }, + { + "kind": "RootArgument", + "name": "filter" + }, + { + "kind": "RootArgument", + "name": "first" + }, + { + "kind": "RootArgument", + "name": "last" + }, + { + "kind": "RootArgument", + "name": "ownerAddress" + } + ], + "kind": "Fragment", + "metadata": { + "connection": [ + { + "count": null, + "cursor": null, + "direction": "bidirectional", + "path": (v0/*: any*/) + } + ], + "refetch": { + "connection": { + "forward": { + "count": "first", + "cursor": "after" + }, + "backward": { + "count": "last", + "cursor": "before" + }, + "path": (v0/*: any*/) + }, + "fragmentPathInResult": [], + "operation": require('./NftBalancePaginationQuery.graphql') + } + }, + "name": "NftBalanceQuery_nftBalances", + "selections": [ + { + "alias": "nftBalances", + "args": [ + { + "kind": "Variable", + "name": "filter", + "variableName": "filter" + }, + { + "kind": "Variable", + "name": "ownerAddress", + "variableName": "ownerAddress" + } + ], + "concreteType": "NftBalanceConnection", + "kind": "LinkedField", + "name": "__NftBalanceQuery_nftBalances_connection", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalanceEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftBalance", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftAsset", + "kind": "LinkedField", + "name": "ownedAsset", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "id", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "animationUrl", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftCollection", + "kind": "LinkedField", + "name": "collection", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "isVerified", + "storageKey": null + }, + (v2/*: any*/), + (v3/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "NftContract", + "kind": "LinkedField", + "name": "nftContracts", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "address", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "chain", + "storageKey": null + }, + (v3/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "standard", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "symbol", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalSupply", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "currencies", + "value": "ETH" + } + ], + "concreteType": "NftCollectionMarket", + "kind": "LinkedField", + "name": "markets", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "floorPrice", + "plural": false, + "selections": [ + (v4/*: any*/) + ], + "storageKey": null + } + ], + "storageKey": "markets(currencies:\"ETH\")" + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "description", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "flaggedBy", + "storageKey": null + }, + (v2/*: any*/), + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "originalImage", + "plural": false, + "selections": (v1/*: any*/), + "storageKey": null + }, + (v3/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "ownerAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "smallImage", + "plural": false, + "selections": (v1/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "suspiciousFlag", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "tokenId", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "Image", + "kind": "LinkedField", + "name": "thumbnail", + "plural": false, + "selections": (v1/*: any*/), + "storageKey": null + }, + { + "alias": null, + "args": [ + { + "kind": "Literal", + "name": "first", + "value": 1 + } + ], + "concreteType": "NftOrderConnection", + "kind": "LinkedField", + "name": "listings", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrderEdge", + "kind": "LinkedField", + "name": "edges", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "NftOrder", + "kind": "LinkedField", + "name": "node", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "Amount", + "kind": "LinkedField", + "name": "price", + "plural": false, + "selections": [ + (v4/*: any*/), + (v5/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "createdAt", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "marketplace", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endAt", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": "listings(first:1)" + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "listedMarketplaces", + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "NftFee", + "kind": "LinkedField", + "name": "listingFees", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "payoutAddress", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "basisPoints", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "TimestampedAmount", + "kind": "LinkedField", + "name": "lastPrice", + "plural": false, + "selections": [ + (v5/*: any*/), + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "timestamp", + "storageKey": null + }, + (v4/*: any*/) + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "cursor", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": null, + "args": null, + "concreteType": "PageInfo", + "kind": "LinkedField", + "name": "pageInfo", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "endCursor", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasNextPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "hasPreviousPage", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "startCursor", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null +}; +})(); + +(node as any).hash = "51ba85a72e5973ac0faad0e8d2c4b681"; + +export default node; diff --git a/src/graphql/data/schema.graphql b/src/graphql/data/schema.graphql new file mode 100644 index 00000000000..9ef3512fbeb --- /dev/null +++ b/src/graphql/data/schema.graphql @@ -0,0 +1,1582 @@ +"""This directive allows results to be deferred during execution""" +directive @defer on FIELD + +"""Directs the schema to enforce authorization on a field""" +directive @aws_auth( + """List of cognito user pool groups which have access on this field""" + cognito_groups: [String] +) on FIELD_DEFINITION + +"""Tells the service which mutation triggers this subscription.""" +directive @aws_subscribe( + """ + List of mutations which will trigger this subscription when they are called. + """ + mutations: [String] +) on FIELD_DEFINITION + +""" +Tells the service this field/object has access authorized by a Lambda Authorizer. +""" +directive @aws_lambda on OBJECT | FIELD_DEFINITION + +""" +Tells the service this field/object has access authorized by an OIDC token. +""" +directive @aws_oidc on OBJECT | FIELD_DEFINITION + +""" +Tells the service which subscriptions will be published to when this mutation is +called. This directive is deprecated use @aws_susbscribe directive instead. +""" +directive @aws_publish( + """ + List of subscriptions which will be published to when this mutation is called. + """ + subscriptions: [String] +) on FIELD_DEFINITION + +""" +Tells the service this field/object has access authorized by sigv4 signing. +""" +directive @aws_iam on OBJECT | FIELD_DEFINITION + +""" +Tells the service this field/object has access authorized by an API key. +""" +directive @aws_api_key on OBJECT | FIELD_DEFINITION + +""" +Tells the service this field/object has access authorized by a Cognito User Pools token. +""" +directive @aws_cognito_user_pools( + """List of cognito user pool groups which have access on this field""" + cognito_groups: [String] +) on OBJECT | FIELD_DEFINITION + +""" + Types, unions, and inputs (alphabetized): + These are colocated to highlight the relationship between some types and their inputs. +""" +union ActivityDetails = TransactionDetails | SwapOrderDetails | OnRampTransactionDetails | OffRampTransactionDetails + +input ActivityDetailsInput { + transactionDetails: TransactionDetailsInput + swapOrderDetails: SwapOrderDetailsInput + onRampTransactionDetails: OnRampTransactionDetailsInput + offRampTransactionDetails: OffRampTransactionDetailsInput +} + +""" + Enums (alphabetized): + deprecated and replaced with TransactionType, please do not use this +""" +enum ActivityType { + APPROVE + CANCEL + CLAIM + SEND + RECEIVE + SWAP + DEPLOYMENT + UNKNOWN + money + market + LEND + BORROW + REPAY + WITHDRAW + NFT + MINT + BURN + Staking + STAKE + UNSTAKE + SWAP_ORDER + ON_RAMP + OFF_RAMP +} + +type Amount implements IAmount { + id: ID! + currency: Currency + value: Float! +} + +type AmountChange { + id: ID! + percentage: Amount + absolute: Amount +} + +input AmountInput { + currency: Currency + value: Float! +} + +type ApplicationContract implements IContract { + id: ID! + chain: Chain! + address: String! + name: String + icon: Image +} + +input ApplicationContractInput { + chain: Chain! + address: String! + name: String + icon: ImageInput +} + +type AssetActivity { + id: ID! + timestamp: Int! + type: ActivityType! @deprecated(reason: "use type field in details") + chain: Chain! + gasUsed: Float @deprecated(reason: "not required, remove usage") + transaction: Transaction! @deprecated(reason: "use fields from details") + assetChanges: [AssetChange]! @deprecated(reason: "use assetChanges field in details") + details: ActivityDetails! + addresses: [String!] +} + +input AssetActivityInput { + timestamp: Int! + chain: Chain! + details: ActivityDetailsInput! +} + +enum AssetActivitySwitch { + ALTERNATE + LEGACY +} + +union AssetChange = TokenTransfer | NftTransfer | OnRampTransfer | TokenApproval | NftApproval | NftApproveForAll | OffRampTransfer + +input AssetChangeInput { + tokenTransfer: TokenTransferInput + tokenApproval: TokenApprovalInput + nftTransfer: NftTransferInput + nftApproval: NftApprovalInput + nftApproveForAll: NftApproveForAllInput + onRampTransfer: OnRampTransferInput + offRampTransfer: OffRampTransferInput +} + +""" +The `AWSJSON` scalar type provided by AWS AppSync, represents a JSON string that +complies with [RFC 8259](https://tools.ietf.org/html/rfc8259). Maps like +"**{\\"upvotes\\": 10}**", lists like "**[1,2,3]**", and scalar values like +"**\\"AWSJSON example string\\"**", "**1**", and "**true**" are accepted as +valid JSON and will automatically be parsed and loaded in the resolver mapping +templates as Maps, Lists, or Scalar values rather than as the literal input +strings. Invalid JSON strings like "**{a: 1}**", "**{'a': 1}**" and "**Unquoted +string**" will throw GraphQL validation errors. +""" +scalar AWSJSON + +type BlockaidFees { + transfer: Float + buy: Float + sell: Float +} + +type BridgedWithdrawalInfo { + chain: String! + provider: String! + url: String! +} + +enum Chain { + ARBITRUM + AVALANCHE + ETHEREUM + ETHEREUM_GOERLI + ETHEREUM_SEPOLIA + OPTIMISM + POLYGON + CELO + BNB + BASE + BLAST + ZORA + ZKSYNC + UNICHAIN + SONEIUM + ASTROCHAIN_SEPOLIA + WORLDCHAIN + MONAD_TESTNET + MONAD + ARBITRUM_SEPOLIA + BASE_SEPOLIA + SOLANA + XLAYER + UNKNOWN_CHAIN +} + +enum CollectionSortableField { + VOLUME +} + +input ContractInput { + chain: Chain! + address: String +} + +enum Currency { + ARS + AUD + BRL + CAD + CNY + COP + ETH + EUR + GBP + HKD + IDR + INR + JPY + KRW + MATIC + MXN + NGN + NZD + PKR + RUB + SGD + THB + TRY + UAH + USD + VND +} + +input CurrencyAmountInput { + currency: Currency! + value: Float! +} + +type DescriptionTranslations { + id: ID! + descriptionZhHans: String + descriptionZhHant: String + descriptionNlNl: String + descriptionEnUs: String + descriptionFrFr: String + descriptionHiIn: String + descriptionIdId: String + descriptionJaJp: String + descriptionMsMy: String + descriptionPtPt: String + descriptionRuRu: String + descriptionEsEs: String + descriptionEs419: String + descriptionEsUs: String + descriptionThTh: String + descriptionTrTr: String + descriptionUkUa: String + descriptionUrPk: String + descriptionViVn: String +} + +type Dimensions { + id: ID! + height: Float + width: Float +} + +input DimensionsInput { + height: Float + width: Float +} + +type FeeData { + sellFeeBps: String + buyFeeBps: String + feeTakenOnTransfer: Boolean + externalTransferFailed: Boolean + sellReverted: Boolean +} + +enum HighLow { + HIGH + LOW +} + +""" FIVE_MINUTE is only supported for TokenMarket.pricePercentChange""" +enum HistoryDuration { + FIVE_MINUTE + HOUR + DAY + WEEK + MONTH + YEAR + MAX +} + +""" Interfaces (alphabetized):""" +interface IAmount { + currency: Currency + value: Float! +} + +interface IContract { + chain: Chain! + address: String +} + +type Image { + id: ID! + url: String! + dimensions: Dimensions +} + +input ImageInput { + url: String! + dimensions: DimensionsInput +} + +interface IPool { + id: ID! + protocolVersion: ProtocolVersion! + chain: Chain! + address: String! + createdAtTimestamp: Int + totalLiquidity: Amount + token0: Token + token0Supply: Float + token1: Token + token1Supply: Float + txCount: Int + totalLiquidityPercentChange24h: Amount + cumulativeVolume(duration: HistoryDuration!): Amount + historicalVolume(duration: HistoryDuration!): [TimestampedAmount] + priceHistory(duration: HistoryDuration!): [TimestampedPoolPrice] + transactions(first: Int!, timestampCursor: Int): [PoolTransaction] +} + +enum MediaType { + VIDEO + IMAGE + RAW + AUDIO +} + +type Mutation { + assetActivity(input: AssetActivityInput!): AssetActivity! + heartbeat(subscriptionId: ID!, type: SubscriptionType!): Status! + unsubscribe(subscriptionId: ID!, type: SubscriptionType!): Status! +} + +type NetworkFee { + quantity: String + tokenSymbol: String + tokenAddress: String + tokenChain: String +} + +type NftActivity { + id: ID! + address: String! + tokenId: String + asset: NftAsset + type: NftActivityType! + marketplace: String + fromAddress: String! + toAddress: String + transactionHash: String + price: Amount + quantity: Int + orderStatus: OrderStatus + url: String + timestamp: Int! +} + +type NftActivityConnection { + pageInfo: PageInfo! + edges: [NftActivityEdge!]! +} + +type NftActivityEdge { + cursor: String! + node: NftActivity! +} + +input NftActivityFilterInput { + address: String + tokenId: String + activityTypes: [NftActivityType!] +} + +enum NftActivityType { + LISTING + SALE + CANCEL_LISTING + TRANSFER +} + +type NftApproval { + id: ID! + nftStandard: NftStandard! + + """ can be erc721, erc1155, noncompliant""" + asset: NftAsset! + approvedAddress: String! +} + +input NftApprovalInput { + nftStandard: NftStandard! + asset: NftAssetInput! + approvedAddress: String! +} + +type NftApproveForAll { + id: ID! + nftStandard: NftStandard! + + """ can be erc721, erc1155, noncompliant""" + asset: NftAsset! + operatorAddress: String! + approved: Boolean! +} + +input NftApproveForAllInput { + nftStandard: NftStandard! + asset: NftAssetInput! + operatorAddress: String! + approved: Boolean! +} + +type NftAsset { + id: ID! + collection: NftCollection + description: String + imageUrl: String @deprecated + thumbnailUrl: String @deprecated + animationUrl: String + smallImageUrl: String @deprecated + image: Image + thumbnail: Image + smallImage: Image + originalImage: Image + name: String + nftContract: NftContract + + """ TODO: may need to be array to support erc1155 cases. not needed at the moment so will revisit. + """ + ownerAddress: String + tokenId: String! + traits: [NftAssetTrait!] + rarities: [NftAssetRarity!] + listings(chain: Chain, asc: Boolean, first: Int, last: Int, after: String, before: String): NftOrderConnection + suspiciousFlag: Boolean + flaggedBy: String + metadataUrl: String + creator: NftProfile + mediaType: MediaType + isSpam: Boolean + protectionInfo: ProtectionInfo + chain: Chain +} + +type NftAssetConnection { + pageInfo: PageInfo! + edges: [NftAssetEdge!]! + totalCount: Int +} + +type NftAssetEdge { + cursor: String! + node: NftAsset! +} + +input NftAssetInput { + collection: NftCollectionInput + description: String + animationUrl: String + image: ImageInput + thumbnail: ImageInput + smallImage: ImageInput + name: String + nftContract: NftContractInput + tokenId: String! + mediaType: MediaType + isSpam: Boolean +} + +type NftAssetRarity { + id: ID! + score: Float + rank: Int + provider: NftRarityProvider +} + +input NftAssetsFilterInput { + tokenSearchQuery: String + tokenIds: [String!] + traits: [NftAssetTraitInput!] + listed: Boolean + minPrice: String + maxPrice: String + marketplaces: [NftMarketplace!] +} + +enum NftAssetSortableField { + PRICE + RARITY +} + +type NftAssetTrait { + id: ID! + name: String + rarity: Float + value: String +} + +input NftAssetTraitInput { + name: String! + values: [String!]! +} + +type NftBalance { + id: ID! + ownedAsset: NftAsset + listedMarketplaces: [NftMarketplace!] + lastPrice: TimestampedAmount + listingFees: [NftFee] + quantity: Int +} + +input NftBalanceAssetInput { + address: String! + tokenId: String! +} + +type NftBalanceConnection { + pageInfo: PageInfo! + edges: [NftBalanceEdge!]! +} + +type NftBalanceEdge { + cursor: String! + node: NftBalance! +} + +input NftBalancesFilterInput { + addresses: [String!] + assets: [NftBalanceAssetInput!] + filterSpam: Boolean +} + +type NftCollection { + id: ID! + collectionId: String! + + """ + TODO: support querying for collection assets here + assets(page: Int, pageSize: Int, orderBy: NftAssetSortableField): [NftAsset] + """ + bannerImageUrl: String @deprecated + bannerImage: Image + description: String + discordUrl: String + homepageUrl: String + imageUrl: String @deprecated + image: Image + instagramName: String + markets(currencies: [Currency!]!): [NftCollectionMarket!] + name: String + nftContracts: [NftContract!] + openseaUrl: String @deprecated + traits: [NftCollectionTrait!] + twitterName: String + isVerified: Boolean + numAssets: Int + creator: NftProfile +} + +type NftCollectionBalance { + id: ID! + address: String! + name: String! + logoImage: Image + balance: Float! +} + +type NftCollectionBalanceConnection { + pageInfo: PageInfo! + edges: [NftCollectionBalanceEdge!]! +} + +type NftCollectionBalanceEdge { + cursor: String! + node: NftCollectionBalance! +} + +type NftCollectionConnection { + pageInfo: PageInfo! + edges: [NftCollectionEdge!]! +} + +type NftCollectionEdge { + cursor: String! + node: NftCollection! +} + +input NftCollectionInput { + collectionId: String! + name: String + nftContracts: [NftContractInput!] +} + +type NftCollectionMarket { + id: ID! + nftContracts: [NftContract!] + floorPrice: TimestampedAmount + owners: Int + volume24h: Amount @deprecated + totalVolume: TimestampedAmount + volume(duration: HistoryDuration): TimestampedAmount + volumePercentChange(duration: HistoryDuration): TimestampedAmount + floorPricePercentChange(duration: HistoryDuration): TimestampedAmount + sales(duration: HistoryDuration): TimestampedAmount + listings: TimestampedAmount + marketplaces(marketplaces: [NftMarketplace!]): [NftCollectionMarketplace!] + percentUniqueOwners: TimestampedAmount + percentListed: TimestampedAmount +} + +type NftCollectionMarketplace { + id: ID! + marketplace: NftMarketplace + listings: Int + floorPrice: Float +} + +input NftCollectionsFilterInput { + addresses: [String!] + nameQuery: String +} + +type NftCollectionTrait { + id: ID! + name: String + values: [String!] + stats: [NftCollectionTraitStats!] +} + +type NftCollectionTraitStats { + id: ID! + name: String + value: String + assets: Int + listings: Int +} + +type NftContract implements IContract { + id: ID! + address: String! + chain: Chain! + name: String + standard: NftStandard + symbol: String + totalSupply: Int +} + +input NftContractInput { + address: String! + chain: Chain! + name: String + standard: NftStandard + symbol: String + totalSupply: Int +} + +type NftFee { + id: ID! + payoutAddress: String! + basisPoints: Int! +} + +enum NftMarketplace { + OPENSEA + LOOKSRARE + X2Y2 + SUDOSWAP + NFTX + NFT20 + FOUNDATION + CRYPTOPUNKS +} + +type NftOrder { + id: ID! + address: String! + tokenId: String + type: OrderType! + marketplace: NftMarketplace! + marketplaceUrl: String! + price: Amount! + quantity: Int! + orderHash: String + status: OrderStatus! + createdAt: Float! + startAt: Float! + endAt: Float + maker: String! + taker: String + auctionType: String + protocolParameters: AWSJSON + poolPrices: [String!] +} + +type NftOrderConnection { + pageInfo: PageInfo! + edges: [NftOrderEdge!]! +} + +type NftOrderEdge { + cursor: String! + node: NftOrder! +} + +type NftProfile { + id: ID! + address: String! + isVerified: Boolean + profileImage: Image + username: String +} + +enum NftRarityProvider { + RARITY_SNIPER +} + +type NftRouteResponse { + id: ID! + calldata: String! + toAddress: String! + sendAmount: TokenAmount! + route: [NftTrade!] +} + +enum NftStandard { + ERC721 + ERC1155 + NONCOMPLIANT +} + +type NftTrade { + id: ID! + contractAddress: String! + tokenId: String! + tokenType: NftStandard + marketplace: NftMarketplace! + amount: Int! + + """ quotePrice represents the last quoted price of the NFT""" + quotePrice: TokenAmount + + """ price represents the current price of the NFT, which can be different from quotePrice + """ + price: TokenAmount! +} + +input NftTradeInput { + id: ID! + contractAddress: String! + tokenId: String! + tokenType: NftStandard + marketplace: NftMarketplace! + amount: Int! + quotePrice: TokenAmountInput +} + +type NftTransfer { + id: ID! + nftStandard: NftStandard! + asset: NftAsset! + sender: String! + recipient: String! + direction: TransactionDirection! +} + +input NftTransferInput { + nftStandard: NftStandard! + asset: NftAssetInput! + sender: String! + recipient: String! + direction: TransactionDirection! +} + +type OffRampServiceProvider { + id: ID! + serviceProvider: String! + name: String! + url: String! + logoLightUrl: String! + logoDarkUrl: String! + supportUrl: String +} + +input OffRampServiceProviderInput { + serviceProvider: String! + name: String! + url: String! + logoLightUrl: String! + logoDarkUrl: String! + supportUrl: String +} + +type OffRampTransactionDetails { + id: ID! + status: TransactionStatus! + senderAddress: String! + offRampTransfer: OffRampTransfer! +} + +input OffRampTransactionDetailsInput { + status: TransactionStatus! + senderAddress: String! + offRampTransfer: OffRampTransferInput! +} + +type OffRampTransfer { + id: ID! + token: Token! + tokenStandard: TokenStandard! + amount: Float! + destinationCurrency: String + destinationAmount: Float! + serviceProvider: OffRampServiceProvider! + transactionReferenceId: String! + externalSessionId: String! + networkFee: Float + transactionFee: Float + totalFee: Float +} + +input OffRampTransferInput { + token: TokenAssetInput! + tokenStandard: TokenStandard! + amount: Float! + destinationCurrency: String + destinationAmount: Float! + serviceProvider: OffRampServiceProviderInput! + transactionReferenceId: String! + networkFee: Float + transactionFee: Float + totalFee: Float +} + +type OnRampServiceProvider { + id: ID! + serviceProvider: String! + name: String! + url: String! + logoLightUrl: String! + logoDarkUrl: String! + supportUrl: String +} + +input OnRampServiceProviderInput { + serviceProvider: String! + name: String! + url: String! + logoLightUrl: String! + logoDarkUrl: String! + supportUrl: String +} + +type OnRampTransactionDetails { + id: ID! + status: TransactionStatus! + receiverAddress: String! + onRampTransfer: OnRampTransfer! +} + +input OnRampTransactionDetailsInput { + status: TransactionStatus! + receiverAddress: String! + onRampTransfer: OnRampTransferInput! +} + +input OnRampTransactionsAuth { + queryParams: String! + signature: String! +} + +type OnRampTransfer { + id: ID! + token: Token! + tokenStandard: TokenStandard! + amount: Float! + sourceCurrency: String + sourceAmount: Float! + serviceProvider: OnRampServiceProvider! + transactionReferenceId: String! + externalSessionId: String! + networkFee: Float + transactionFee: Float + totalFee: Float +} + +input OnRampTransferInput { + token: TokenAssetInput! + tokenStandard: TokenStandard! + amount: Float! + sourceCurrency: String + sourceAmount: Float! + serviceProvider: OnRampServiceProviderInput! + transactionReferenceId: String! + networkFee: Float + transactionFee: Float + totalFee: Float +} + +enum OrderStatus { + VALID + EXECUTED + CANCELLED + EXPIRED +} + +enum OrderType { + LISTING + OFFER +} + +type PageInfo { + hasPreviousPage: Boolean + hasNextPage: Boolean + startCursor: String + endCursor: String +} + +""" v2 pool parameters as defined by https://github.com/Uniswap/v2-sdk/blob/main/src/entities/pair.ts +""" +input PairInput { + tokenAmountA: TokenAmountInput! + tokenAmountB: TokenAmountInput! +} + +input PermitDetailsInput { + token: String! + amount: String! + expiration: String! + nonce: String! +} + +input PermitInput { + signature: String! + details: PermitDetailsInput! + spender: String! + sigDeadline: String! +} + +""" v3 pool parameters as defined by https://github.com/Uniswap/v3-sdk/blob/main/src/entities/pool.ts +""" +input PoolInput { + tokenA: TokenInput! + tokenB: TokenInput! + fee: Int! + sqrtRatioX96: String! + liquidity: String! + tickCurrent: String! +} + +type PoolTransaction { + id: ID! + chain: Chain! + protocolVersion: ProtocolVersion! + type: PoolTransactionType! + hash: String! + timestamp: Int! + usdValue: Amount! + account: String! + token0: Token! + token0Quantity: String! + token1: Token! + token1Quantity: String! +} + +enum PoolTransactionType { + SWAP + ADD + REMOVE +} + +type Portfolio { + id: ID! + ownerAddress: String! + tokensTotalDenominatedValue: Amount + tokensTotalDenominatedValueChange(duration: HistoryDuration): AmountChange + tokenBalances: [TokenBalance] + + """ TODO: (michael.zhang) replace with paginated query""" + nftBalances: [NftBalance] + assetActivities(page: Int, pageSize: Int, includeOffChain: Boolean, onRampTransactionsAuth: OnRampTransactionsAuth, onRampTransactionIDs: [String!], chains: [Chain!], includeBridging: Boolean, _fs: AssetActivitySwitch): [AssetActivity] +} + +""" Specify how the portfolio value should be calculated for each `ownerAddress`. +""" +input PortfolioValueModifier { + ownerAddress: String! + tokenIncludeOverrides: [ContractInput!] + tokenExcludeOverrides: [ContractInput!] + includeSmallBalances: Boolean + includeSpamTokens: Boolean + tokenBalancesLimit: Int +} + +enum PriceSource { + SUBGRAPH_V2 + SUBGRAPH_V3 + SUBGRAPH_V4 + EXTERNAL +} + +enum ProtectionAttackType { + UNKNOWN + METADATA + INORGANIC_VOLUME + AIRDROP_PATTERN + DYNAMIC_ANALYSIS + STATIC_CODE_SIGNATURE + KNOWN_MALICIOUS + IMPERSONATOR + UNSTABLE_TOKEN_PRICE + RUGPULL + HIGH_FEES + HONEYPOT +} + +type ProtectionInfo { + result: ProtectionResult + attackTypes: [ProtectionAttackType] + blockaidFees: BlockaidFees +} + +enum ProtectionResult { + UNKNOWN + MALICIOUS + BENIGN + SPAM + WARNING +} + +enum ProtocolVersion { + V2 + V3 + V4 +} + +type PushNotification { + id: ID! + contents: AWSJSON! + notifyAddress: String! + viewerHeader: AWSJSON! + signerHeader: AWSJSON! +} + +type Query { + isV3SubgraphStale(chain: Chain!): Boolean + historicalProtocolVolume(chain: Chain!, version: ProtocolVersion!, duration: HistoryDuration!): [TimestampedAmount!] + dailyProtocolTvl(chain: Chain!, version: ProtocolVersion!): [TimestampedAmount!] + + """ returns top v3 pools sorted by total value locked in desc order""" + topV3Pools(chain: Chain!, first: Int!, tvlCursor: Float, tokenFilter: String, debugMode: Boolean): [V3Pool!] + topV4Pools(chain: Chain!, first: Int!, tvlCursor: Float, tokenFilter: String, debugMode: Boolean): [V4Pool!] + v3Pool(chain: Chain!, address: String!): V3Pool + v4Pool(chain: Chain!, poolId: String!): V4Pool + v3PoolsForTokenPair(chain: Chain!, token0: String!, token1: String!): [V3Pool!] + v4PoolsForTokenPair(chain: Chain!, token0: String!, token1: String!): [V4Pool!] + v3Transactions(chain: Chain!, first: Int!, timestampCursor: Int): [PoolTransaction!] + v4Transactions(chain: Chain!, first: Int!, timestampCursor: Int): [PoolTransaction!] + + """ returns top v2 pairs sorted by total value locked in desc order""" + topV2Pairs(chain: Chain!, first: Int!, tvlCursor: Float, tokenFilter: String, debugMode: Boolean): [V2Pair!] + v2Pair(chain: Chain!, address: String!): V2Pair + v2Transactions(chain: Chain!, first: Int!, timestampCursor: Int): [PoolTransaction] + convert(fromAmount: CurrencyAmountInput!, toCurrency: Currency!): Amount + tokens(contracts: [ContractInput!]!): [Token] + + """ + token consumes chain and address instead of contract because the apollo client request cache can only use + keys from the response, and the token response does not contain a contract, but does contain an unwrapped + contract: chain and address. + """ + token(chain: Chain!, address: String): Token + tokenProjects(contracts: [ContractInput!]!): [TokenProject] + searchTokens(searchQuery: String!, chains: [Chain!], tokenSearchV2Enabled: Boolean): [Token] + portfolios(ownerAddresses: [String!]!, chains: [Chain!], lookupTokens: [ContractInput!], fungibleIds: [String!], valueModifiers: [PortfolioValueModifier!]): [Portfolio] + topTokens(chain: Chain, page: Int, pageSize: Int, orderBy: TokenSortableField): [Token] + topCollections(chains: [Chain!], orderBy: CollectionSortableField, duration: HistoryDuration, after: String, first: Int, cursor: String, limit: Int): NftCollectionConnection + nftAssets(chain: Chain, address: String!, orderBy: NftAssetSortableField, asc: Boolean, filter: NftAssetsFilterInput, after: String, first: Int, before: String, last: Int): NftAssetConnection + nftCollections(chain: Chain, filter: NftCollectionsFilterInput, after: String, first: Int): NftCollectionConnection + nftBalances(chain: Chain, ownerAddress: String!, filter: NftBalancesFilterInput, after: String, first: Int, before: String, last: Int, chains: [Chain!]): NftBalanceConnection + nftRoute(chain: Chain, senderAddress: String!, nftTrades: [NftTradeInput!]!, tokenTrades: [TokenTradeInput!]): NftRouteResponse + nftActivity(chain: Chain, filter: NftActivityFilterInput, after: String, first: Int): NftActivityConnection + nftCollectionBalances(chain: Chain, ownerAddress: String!, after: String, first: Int, before: String, last: Int): NftCollectionBalanceConnection + transactionNotification(chain: Chain!, address: String!, transactionHash: String!, isBridging: Boolean): TransactionNotification +} + +type RewardsCampaign { + id: ID! + boostedApr: Float! + startTimestamp: Int + endTimestamp: Int + totalRewardAllocation: String + distributedRewards: String +} + +enum SafetyLevel { + VERIFIED + MEDIUM_WARNING + STRONG_WARNING + BLOCKED +} + +type Status { + success: Boolean! +} + +type Subscription { + onAssetActivity(subscriptionId: ID!, addresses: [String!]!): AssetActivity +} + +enum SubscriptionType { + ASSET_ACTIVITY +} + +type SwapOrderDetails { + id: ID! + offerer: String! + hash: String! + status: SwapOrderStatus! @deprecated(reason: "use swapOrderStatus to disambiguate from transactionStatus") + swapOrderStatus: SwapOrderStatus! + inputToken: Token! + inputTokenQuantity: String! + outputToken: Token! + outputTokenQuantity: String! + expiry: Int! + encodedOrder: String! + swapOrderType: SwapOrderType! +} + +input SwapOrderDetailsInput { + offerer: String! + hash: String! + status: SwapOrderStatus + swapOrderStatus: SwapOrderStatus! + inputToken: TokenAssetInput! + inputAmount: String! + outputToken: TokenAssetInput! + outputAmount: String! + expiry: Int! + encodedOrder: String! + swapOrderType: SwapOrderType! +} + +enum SwapOrderStatus { + OPEN + EXPIRED + ERROR + INSUFFICIENT_FUNDS + FILLED + CANCELLED +} + +enum SwapOrderType { + DUTCH + LIMIT + DUTCH_V2 + PRIORITY +} + +type TimestampedAmount implements IAmount { + id: ID! + currency: Currency + value: Float! + timestamp: Int! +} + +type TimestampedOhlc { + id: ID! + timestamp: Int! + open: Amount! + high: Amount! + low: Amount! + close: Amount! +} + +type TimestampedPoolPrice { + id: ID! + timestamp: Int! + token0Price: Float! + token1Price: Float! +} + +type Token implements IContract { + id: ID! + chain: Chain! + address: String + standard: TokenStandard + decimals: Int + name: String + symbol: String + project: TokenProject + market(currency: Currency): TokenMarket + feeData: FeeData + protectionInfo: ProtectionInfo + v4Transactions(first: Int!, timestampCursor: Int): [PoolTransaction] + v3Transactions(first: Int!, timestampCursor: Int): [PoolTransaction] + v2Transactions(first: Int!, timestampCursor: Int): [PoolTransaction] + source: TokenSource + isBridged: Boolean + bridgedWithdrawalInfo: BridgedWithdrawalInfo +} + +type TokenAmount { + id: ID! + value: String! + currency: Currency! +} + +input TokenAmountInput { + token: TokenInput! + amount: String! +} + +type TokenApproval { + id: ID! + tokenStandard: TokenStandard! + + """ can be erc20 or native""" + asset: Token! + approvedAddress: String! + quantity: String! +} + +input TokenApprovalInput { + tokenStandard: TokenStandard! + asset: TokenAssetInput! + approvedAddress: String! + quantity: String! +} + +input TokenAssetInput { + chain: Chain! + address: String + standard: TokenStandard! + decimals: Int + name: String + symbol: String +} + +type TokenBalance { + id: ID! + blockNumber: Int + blockTimestamp: Int + quantity: Float + denominatedValue: Amount + ownerAddress: String! + token: Token + tokenProjectMarket: TokenProjectMarket + isHidden: Boolean +} + +input TokenInput { + chainId: Int! + address: String! + decimals: Int! + isNative: Boolean! +} + +type TokenMarket { + id: ID! + token: Token! + price: Amount + priceSource: PriceSource! + totalValueLocked: Amount + fullyDilutedValuation: Amount + historicalVolume(duration: HistoryDuration!): [TimestampedAmount] + historicalTvl(duration: HistoryDuration!): [TimestampedAmount] + priceHistory(duration: HistoryDuration!, maxLength: Int): [TimestampedAmount] + ohlc(duration: HistoryDuration!): [TimestampedOhlc] + + """ this volume is cumulative volume over the specified duration""" + volume(duration: HistoryDuration!): Amount + pricePercentChange(duration: HistoryDuration!): Amount + priceHighLow(duration: HistoryDuration!, highLow: HighLow!): Amount +} + +type TokenProject { + id: ID! + name: String + tokens: [Token!]! + description: String + descriptionTranslations: DescriptionTranslations + twitterName: String + homepageUrl: String + logoUrl: String @deprecated(reason: "use logo") + logo: Image + smallLogo: Image @deprecated(reason: "use logo") + isSpam: Boolean + spamCode: Int + safetyLevel: SafetyLevel + markets(currencies: [Currency!]!): [TokenProjectMarket] +} + +type TokenProjectMarket { + id: ID! + tokenProject: TokenProject! + currency: Currency! + price: Amount + marketCap: Amount + fullyDilutedValuation: Amount + pricePercentChange24h: Amount + priceHigh52w: Amount + priceLow52w: Amount + priceHistory(duration: HistoryDuration!, maxLength: Int): [TimestampedAmount] + pricePercentChange(duration: HistoryDuration!): Amount + priceHighLow(duration: HistoryDuration!, highLow: HighLow!): Amount +} + +enum TokenSortableField { + TOTAL_VALUE_LOCKED + MARKET_CAP + VOLUME + POPULARITY +} + +enum TokenSource { + TOKEN_FACTORY +} + +enum TokenStandard { + NATIVE + ERC20 + SPL +} + +input TokenTradeInput { + tokenAmount: TokenAmountInput! + routes: TokenTradeRoutesInput + slippageToleranceBasisPoints: Int + permit: PermitInput +} + +input TokenTradeRouteInput { + pools: [TradePoolInput!]! + inputAmount: TokenAmountInput! + outputAmount: TokenAmountInput! +} + +input TokenTradeRoutesInput { + v2Routes: [TokenTradeRouteInput!] + v3Routes: [TokenTradeRouteInput!] + mixedRoutes: [TokenTradeRouteInput!] + tradeType: TokenTradeType! +} + +enum TokenTradeType { + EXACT_INPUT + EXACT_OUTPUT +} + +type TokenTransfer { + id: ID! + tokenStandard: TokenStandard! + asset: Token! + sender: String! + recipient: String! + quantity: String! + direction: TransactionDirection! + transactedValue: Amount +} + +input TokenTransferInput { + tokenStandard: TokenStandard! + asset: TokenAssetInput! + sender: String! + recipient: String! + quantity: String! + direction: TransactionDirection! + transactedValue: AmountInput +} + +input TradePoolInput { + pair: PairInput + pool: PoolInput +} + +type Transaction { + id: ID! + blockNumber: Int! + from: String! + to: String! + hash: String! + nonce: Int! + gasLimit: Float + maxFeePerGas: Float + status: TransactionStatus! +} + +type TransactionDetails { + id: ID! + type: TransactionType! + assetChanges: [AssetChange]! + from: String! + to: String! + hash: String! + status: TransactionStatus! @deprecated(reason: "use transactionStatus to disambiguate from swapOrderStatus") + transactionStatus: TransactionStatus! + nonce: Int! + application: ApplicationContract + networkFee: NetworkFee +} + +input TransactionDetailsInput { + type: TransactionType! + assetChanges: [AssetChangeInput]! + from: String! + to: String! + hash: String! + status: TransactionStatus + transactionStatus: TransactionStatus! + nonce: Int! + application: ApplicationContractInput +} + +enum TransactionDirection { + IN + OUT + SELF +} + +type TransactionNotification { + id: ID! + hash: String! + push: [PushNotification!]! +} + +enum TransactionStatus { + FAILED + CONFIRMED + PENDING +} + +enum TransactionType { + APPROVE + BORROW + BRIDGING + CANCEL + CLAIM + DEPLOYMENT + EXECUTE + LEND + MINT + RECEIVE + REPAY + SEND + STAKE + SWAP + SWAP_ORDER + UNKNOWN + UNSTAKE + WITHDRAW + ON_RAMP + OFF_RAMP +} + +type V2Pair implements IPool { + id: ID! + protocolVersion: ProtocolVersion! + chain: Chain! + address: String! + createdAtTimestamp: Int + totalLiquidity: Amount + token0: Token + token0Supply: Float + token1: Token + token1Supply: Float + txCount: Int + totalLiquidityPercentChange24h: Amount + cumulativeVolume(duration: HistoryDuration!): Amount + historicalVolume(duration: HistoryDuration!): [TimestampedAmount] + priceHistory(duration: HistoryDuration!): [TimestampedPoolPrice] + transactions(first: Int!, timestampCursor: Int): [PoolTransaction] +} + +type V3Pool implements IPool { + id: ID! + protocolVersion: ProtocolVersion! + chain: Chain! + address: String! + createdAtTimestamp: Int + totalLiquidity: Amount + token0: Token + token0Supply: Float + token1: Token + token1Supply: Float + txCount: Int + feeTier: Float + totalLiquidityPercentChange24h: Amount + cumulativeVolume(duration: HistoryDuration!): Amount + historicalVolume(duration: HistoryDuration!): [TimestampedAmount] + priceHistory(duration: HistoryDuration!): [TimestampedPoolPrice] + transactions(first: Int!, timestampCursor: Int): [PoolTransaction] + ticks(skip: Int, first: Int): [V3PoolTick] +} + +type V3PoolTick { + id: ID! + tickIdx: Int + liquidityGross: String + liquidityNet: String + price0: String + price1: String +} + +type V4Pool { + id: ID! + protocolVersion: ProtocolVersion! + chain: Chain! + poolId: String! + createdAtTimestamp: Int + totalLiquidity: Amount + token0: Token + token0Supply: Float + token1: Token + token1Supply: Float + txCount: Int + feeTier: Float + isDynamicFee: Boolean + hook: V4PoolHook + tickSpacing: Int + totalLiquidityPercentChange24h: Amount + cumulativeVolume(duration: HistoryDuration!): Amount + historicalVolume(duration: HistoryDuration!): [TimestampedAmount] + priceHistory(duration: HistoryDuration!): [TimestampedPoolPrice] + transactions(first: Int!, timestampCursor: Int): [PoolTransaction] + ticks(skip: Int, first: Int): [V4PoolTick] + rewardsCampaign: RewardsCampaign +} + +type V4PoolHook { + id: ID! + address: String! +} + +type V4PoolTick { + id: ID! + tickIdx: Int + liquidityGross: String + liquidityNet: String + price0: String + price1: String +} + diff --git a/src/graphql/thegraph/__generated__/AllV3TicksQuery.graphql.ts b/src/graphql/thegraph/__generated__/AllV3TicksQuery.graphql.ts new file mode 100644 index 00000000000..c39a2d3efa7 --- /dev/null +++ b/src/graphql/thegraph/__generated__/AllV3TicksQuery.graphql.ts @@ -0,0 +1,212 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type AllV3TicksQuery$variables = { + poolAddress: string; + skip: number; +}; +export type AllV3TicksQuery$data = { + readonly ticks: ReadonlyArray<{ + readonly tick: string | null; + readonly liquidityNet: string | null; + readonly price0: string | null; + readonly price1: string | null; + } | null>; +}; +export type AllV3TicksQuery = { + response: AllV3TicksQuery$data; + variables: AllV3TicksQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +return { + "fragment": { + "argumentDefinitions": [ + { + "kind": "LocalArgument", + "name": "poolAddress", + "type": "String!" + }, + { + "kind": "LocalArgument", + "name": "skip", + "type": "Int!" + } + ], + "kind": "Fragment", + "metadata": null, + "name": "AllV3TicksQuery", + "selections": [ + { + "alias": null, + "args": [ + { + "kind": "Variable", + "name": "where", + "variableName": "poolAddress" + }, + { + "kind": "Variable", + "name": "skip", + "variableName": "skip" + }, + { + "kind": "Literal", + "name": "first", + "value": 1000 + }, + { + "kind": "Literal", + "name": "orderBy", + "value": "tickIdx" + } + ], + "concreteType": "Tick", + "kind": "LinkedField", + "name": "ticks", + "plural": true, + "selections": [ + { + "alias": "tick", + "args": null, + "kind": "ScalarField", + "name": "tickIdx", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "liquidityNet", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "price0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "price1", + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + { + "kind": "LocalArgument", + "name": "poolAddress", + "type": "String!" + }, + { + "kind": "LocalArgument", + "name": "skip", + "type": "Int!" + } + ], + "kind": "Operation", + "name": "AllV3TicksQuery", + "selections": [ + { + "alias": null, + "args": [ + { + "kind": "Variable", + "name": "where", + "variableName": "poolAddress" + }, + { + "kind": "Variable", + "name": "skip", + "variableName": "skip" + }, + { + "kind": "Literal", + "name": "first", + "value": 1000 + }, + { + "kind": "Literal", + "name": "orderBy", + "value": "tickIdx" + } + ], + "concreteType": "Tick", + "kind": "LinkedField", + "name": "ticks", + "plural": true, + "selections": [ + { + "alias": "tick", + "args": null, + "kind": "ScalarField", + "name": "tickIdx", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "liquidityNet", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "price0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "price1", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "placeholder", + "id": null, + "metadata": {}, + "name": "AllV3TicksQuery", + "operationKind": "query", + "text": "query AllV3TicksQuery($poolAddress: String!, $skip: Int!) { ticks(first: 1000, skip: $skip, where: { poolAddress: $poolAddress }, orderBy: tickIdx) { tick: tickIdx liquidityNet price0 price1 } }" + } +}; +})(); + +(node as any).hash = "placeholder"; + +export default node; + diff --git a/src/graphql/thegraph/__generated__/FeeTierDistributionQuery.graphql.ts b/src/graphql/thegraph/__generated__/FeeTierDistributionQuery.graphql.ts new file mode 100644 index 00000000000..686a7da7b8d --- /dev/null +++ b/src/graphql/thegraph/__generated__/FeeTierDistributionQuery.graphql.ts @@ -0,0 +1,378 @@ +/** + * @generated SignedSource<> + * @lightSyntaxTransform + * @nogrep + */ + +/* tslint:disable */ +/* eslint-disable */ +// @ts-nocheck + +import { ConcreteRequest, Query } from 'relay-runtime'; +export type FeeTierDistributionQuery$variables = { + token0: string; + token1: string; +}; +export type FeeTierDistributionQuery$data = { + readonly _meta: { + readonly block: { + readonly number: number | null; + } | null; + } | null; + readonly asToken0: ReadonlyArray<{ + readonly feeTier: string | null; + readonly totalValueLockedToken0: string | null; + readonly totalValueLockedToken1: string | null; + } | null> | null; + readonly asToken1: ReadonlyArray<{ + readonly feeTier: string | null; + readonly totalValueLockedToken0: string | null; + readonly totalValueLockedToken1: string | null; + } | null> | null; +}; +export type FeeTierDistributionQuery = { + response: FeeTierDistributionQuery$data; + variables: FeeTierDistributionQuery$variables; +}; + +const node: ConcreteRequest = (function(){ +return { + "fragment": { + "argumentDefinitions": [ + { + "kind": "LocalArgument", + "name": "token0", + "type": "String!" + }, + { + "kind": "LocalArgument", + "name": "token1", + "type": "String!" + } + ], + "kind": "Fragment", + "metadata": null, + "name": "FeeTierDistributionQuery", + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "_Meta_", + "kind": "LinkedField", + "name": "_meta", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "_Block_", + "kind": "LinkedField", + "name": "block", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "number", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": "asToken0", + "args": [ + { + "kind": "Literal", + "name": "orderBy", + "value": "totalValueLockedToken0" + }, + { + "kind": "Literal", + "name": "orderDirection", + "value": "desc" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token0" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token1" + } + ], + "concreteType": "Pool", + "kind": "LinkedField", + "name": "pools", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "feeTier", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken1", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": "asToken1", + "args": [ + { + "kind": "Literal", + "name": "orderBy", + "value": "totalValueLockedToken0" + }, + { + "kind": "Literal", + "name": "orderDirection", + "value": "desc" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token1" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token0" + } + ], + "concreteType": "Pool", + "kind": "LinkedField", + "name": "pools", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "feeTier", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken1", + "storageKey": null + } + ], + "storageKey": null + } + ], + "type": "Query", + "abstractKey": null + }, + "kind": "Request", + "operation": { + "argumentDefinitions": [ + { + "kind": "LocalArgument", + "name": "token0", + "type": "String!" + }, + { + "kind": "LocalArgument", + "name": "token1", + "type": "String!" + } + ], + "kind": "Operation", + "name": "FeeTierDistributionQuery", + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "_Meta_", + "kind": "LinkedField", + "name": "_meta", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "concreteType": "_Block_", + "kind": "LinkedField", + "name": "block", + "plural": false, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "number", + "storageKey": null + } + ], + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": "asToken0", + "args": [ + { + "kind": "Literal", + "name": "orderBy", + "value": "totalValueLockedToken0" + }, + { + "kind": "Literal", + "name": "orderDirection", + "value": "desc" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token0" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token1" + } + ], + "concreteType": "Pool", + "kind": "LinkedField", + "name": "pools", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "feeTier", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken1", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + }, + { + "alias": "asToken1", + "args": [ + { + "kind": "Literal", + "name": "orderBy", + "value": "totalValueLockedToken0" + }, + { + "kind": "Literal", + "name": "orderDirection", + "value": "desc" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token1" + }, + { + "kind": "Variable", + "name": "where", + "variableName": "token0" + } + ], + "concreteType": "Pool", + "kind": "LinkedField", + "name": "pools", + "plural": true, + "selections": [ + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "feeTier", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken0", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "totalValueLockedToken1", + "storageKey": null + }, + { + "alias": null, + "args": null, + "kind": "ScalarField", + "name": "__typename", + "storageKey": null + } + ], + "storageKey": null + } + ] + }, + "params": { + "cacheID": "placeholder", + "id": null, + "metadata": {}, + "name": "FeeTierDistributionQuery", + "operationKind": "query", + "text": "query FeeTierDistributionQuery($token0: String!, $token1: String!) { _meta { block { number } } asToken0: pools(orderBy: totalValueLockedToken0, orderDirection: desc, where: { token0: $token0, token1: $token1 }) { feeTier totalValueLockedToken0 totalValueLockedToken1 } asToken1: pools(orderBy: totalValueLockedToken0, orderDirection: desc, where: { token0: $token1, token1: $token0 }) { feeTier totalValueLockedToken0 totalValueLockedToken1 } }" + } +}; +})(); + +(node as any).hash = "placeholder"; + +export default node; + diff --git a/src/graphql/thegraph/schema.graphql b/src/graphql/thegraph/schema.graphql new file mode 100644 index 00000000000..aa0b51403ba --- /dev/null +++ b/src/graphql/thegraph/schema.graphql @@ -0,0 +1,10 @@ +Error: [ + { + "message": "This endpoint has been removed. If you have any questions, reach out to support@thegraph.zendesk.com" + } +] + at /home/irenee/Projects/uniswap-v3-interface/vercel-fix/node_modules/get-graphql-schema/dist/index.js:84:31 + at step (/home/irenee/Projects/uniswap-v3-interface/vercel-fix/node_modules/get-graphql-schema/dist/index.js:33:23) + at Object.next (/home/irenee/Projects/uniswap-v3-interface/vercel-fix/node_modules/get-graphql-schema/dist/index.js:14:53) + at fulfilled (/home/irenee/Projects/uniswap-v3-interface/vercel-fix/node_modules/get-graphql-schema/dist/index.js:5:58) + at process.processTicksAndRejections (node:internal/process/task_queues:105:5) diff --git a/src/graphql/thegraph/schema.graphql.temp b/src/graphql/thegraph/schema.graphql.temp new file mode 100644 index 00000000000..e69de29bb2d diff --git a/src/hooks/useFeeTierDistribution.ts b/src/hooks/useFeeTierDistribution.ts index 377e14e002a..ef8d13c75a3 100644 --- a/src/hooks/useFeeTierDistribution.ts +++ b/src/hooks/useFeeTierDistribution.ts @@ -97,13 +97,18 @@ function usePoolTVL(token0: Token | undefined, token1: Token | undefined) { } } - const all = asToken0.concat(asToken1) + const all = asToken0.concat(asToken1).filter((value): value is NonNullable => value !== null) // sum tvl for token0 and token1 by fee tier const tvlByFeeTier = all.reduce<{ [feeAmount: number]: [number | undefined, number | undefined] }>( (acc, value) => { - acc[value.feeTier][0] = (acc[value.feeTier][0] ?? 0) + Number(value.totalValueLockedToken0) - acc[value.feeTier][1] = (acc[value.feeTier][1] ?? 0) + Number(value.totalValueLockedToken1) + if (value.feeTier === null) return acc + const feeTier = Number(value.feeTier) + if (!acc[feeTier]) { + acc[feeTier] = [undefined, undefined] + } + acc[feeTier][0] = (acc[feeTier][0] ?? 0) + Number(value.totalValueLockedToken0 ?? 0) + acc[feeTier][1] = (acc[feeTier][1] ?? 0) + Number(value.totalValueLockedToken1 ?? 0) return acc }, { diff --git a/src/hooks/usePoolTickData.ts b/src/hooks/usePoolTickData.ts index 385b4603b3b..c2d4370e512 100644 --- a/src/hooks/usePoolTickData.ts +++ b/src/hooks/usePoolTickData.ts @@ -109,16 +109,20 @@ function useTicksFromTickLens( callStates .map(({ result }) => result?.populatedTicks) .reduce( - (accumulator, current) => [ - ...accumulator, - ...(current?.map((tickData: TickData) => { - return { - tick: tickData.tick, - liquidityNet: JSBI.BigInt(tickData.liquidityNet), - } - }) ?? []), - ], - [] + (accumulator, current) => { + if (!current) return accumulator + const validTicks = current + .filter((tickData: TickData): tickData is NonNullable => tickData !== null) + .filter((tickData: NonNullable): tickData is NonNullable & { tick: string } => tickData.tick !== null) + .map((tickData: NonNullable & { tick: string }) => { + return { + tick: tickData.tick, + liquidityNet: JSBI.BigInt(tickData.liquidityNet ?? '0'), + } + }) + return [...accumulator, ...validTicks] + }, + [] as TickData[] ), [callStates] ) @@ -131,7 +135,7 @@ function useTicksFromTickLens( // return the latest synced tickData even if we are still loading the newest data useEffect(() => { if (!IsSyncing && !isLoading && !isError && isValid) { - setTickDataLatestSynced(tickData.sort((a, b) => a.tick - b.tick)) + setTickDataLatestSynced(tickData.filter((t): t is NonNullable & { tick: string } => t !== null && t.tick !== null).sort((a, b) => Number(a.tick) - Number(b.tick))) } }, [isError, isLoading, IsSyncing, tickData, isValid]) @@ -224,7 +228,8 @@ export function usePoolActiveLiquidity( // find where the active tick would be to partition the array // if the active tick is initialized, the pivot will be an element // if not, take the previous tick as pivot - const pivot = ticks.findIndex(({ tick }) => tick > activeTick) - 1 + const validTicks = ticks.filter((t): t is NonNullable & { tick: string } => t !== null && t.tick !== null) + const pivot = validTicks.findIndex(({ tick }) => Number(tick) > activeTick) - 1 if (pivot < 0) { // consider setting a local error @@ -237,16 +242,17 @@ export function usePoolActiveLiquidity( } } + const pivotTick = validTicks[pivot] const activeTickProcessed: TickProcessed = { liquidityActive: JSBI.BigInt(pool[1]?.liquidity ?? 0), tick: activeTick, - liquidityNet: Number(ticks[pivot].tick) === activeTick ? JSBI.BigInt(ticks[pivot].liquidityNet) : JSBI.BigInt(0), + liquidityNet: Number(pivotTick.tick) === activeTick ? JSBI.BigInt(pivotTick.liquidityNet ?? '0') : JSBI.BigInt(0), price0: tickToPrice(token0, token1, activeTick).toFixed(PRICE_FIXED_DIGITS), } - const subsequentTicks = computeSurroundingTicks(token0, token1, activeTickProcessed, ticks, pivot, true) + const subsequentTicks = computeSurroundingTicks(token0, token1, activeTickProcessed, validTicks, pivot, true) - const previousTicks = computeSurroundingTicks(token0, token1, activeTickProcessed, ticks, pivot, false) + const previousTicks = computeSurroundingTicks(token0, token1, activeTickProcessed, validTicks, pivot, false) const ticksProcessed = previousTicks.concat(activeTickProcessed).concat(subsequentTicks) diff --git a/src/utils/computeSurroundingTicks.ts b/src/utils/computeSurroundingTicks.ts index f2185e93b07..b79ec2b0baf 100644 --- a/src/utils/computeSurroundingTicks.ts +++ b/src/utils/computeSurroundingTicks.ts @@ -23,11 +23,16 @@ export default function computeSurroundingTicks( // building active liquidity for every tick. let processedTicks: TickProcessed[] = [] for (let i = pivot + (ascending ? 1 : -1); ascending ? i < sortedTickData.length : i >= 0; ascending ? i++ : i--) { - const tick = Number(sortedTickData[i].tick) + const tickData = sortedTickData[i] + if (!tickData || tickData.tick === null || tickData.liquidityNet === null) { + continue + } + const tick = Number(tickData.tick) + const liquidityNet = JSBI.BigInt(tickData.liquidityNet) const currentTickProcessed: TickProcessed = { liquidityActive: previousTickProcessed.liquidityActive, tick, - liquidityNet: JSBI.BigInt(sortedTickData[i].liquidityNet), + liquidityNet, price0: tickToPrice(token0, token1, tick).toFixed(PRICE_FIXED_DIGITS), } @@ -38,7 +43,7 @@ export default function computeSurroundingTicks( if (ascending) { currentTickProcessed.liquidityActive = JSBI.add( previousTickProcessed.liquidityActive, - JSBI.BigInt(sortedTickData[i].liquidityNet) + liquidityNet ) } else if (!ascending && JSBI.notEqual(previousTickProcessed.liquidityNet, JSBI.BigInt(0))) { // We are iterating descending, so look at the previous tick and apply any net liquidity.