From ad740447270d7d7b28098e9c25b62a05cb276b9b Mon Sep 17 00:00:00 2001 From: maayan Date: Wed, 23 Aug 2023 17:52:10 -0700 Subject: [PATCH] add support for fungible asset queries --- .../sdk/src/indexer/generated/operations.ts | 12 +- .../sdk/src/indexer/generated/queries.ts | 52 +- .../sdk/src/indexer/generated/types.ts | 1841 +++++++++++------ .../queries/getAccountCoinDataCount.graphql | 7 + .../queries/getAccountCoinsData.graphql | 38 +- .../typescript/sdk/src/providers/indexer.ts | 41 +- .../sdk/src/tests/e2e/indexer.test.ts | 11 +- 7 files changed, 1356 insertions(+), 646 deletions(-) create mode 100644 ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinDataCount.graphql diff --git a/ecosystem/typescript/sdk/src/indexer/generated/operations.ts b/ecosystem/typescript/sdk/src/indexer/generated/operations.ts index 1f260abbc41b97..161891ed2e2a9f 100644 --- a/ecosystem/typescript/sdk/src/indexer/generated/operations.ts +++ b/ecosystem/typescript/sdk/src/indexer/generated/operations.ts @@ -2,14 +2,22 @@ import * as Types from './types'; export type CurrentTokenOwnershipFieldsFragment = { __typename?: 'current_token_ownerships_v2', token_standard: string, token_properties_mutated_v1?: any | null, token_data_id: string, table_type_v1?: string | null, storage_id: string, property_version_v1: any, owner_address: string, last_transaction_version: any, last_transaction_timestamp: any, is_soulbound_v2?: boolean | null, is_fungible_v2?: boolean | null, amount: any, current_token_data?: { __typename?: 'current_token_datas_v2', collection_id: string, description: string, is_fungible_v2?: boolean | null, largest_property_version_v1?: any | null, last_transaction_timestamp: any, last_transaction_version: any, maximum?: any | null, supply: any, token_data_id: string, token_name: string, token_properties: any, token_standard: string, token_uri: string, current_collection?: { __typename?: 'current_collections_v2', collection_id: string, collection_name: string, creator_address: string, current_supply: any, description: string, last_transaction_timestamp: any, last_transaction_version: any, max_supply?: any | null, mutable_description?: boolean | null, mutable_uri?: boolean | null, table_handle_v1?: string | null, token_standard: string, total_minted_v2?: any | null, uri: string } | null } | null }; +export type GetAccountCoinsDataCountQueryVariables = Types.Exact<{ + address?: Types.InputMaybe; +}>; + + +export type GetAccountCoinsDataCountQuery = { __typename?: 'query_root', current_fungible_asset_balances_aggregate: { __typename?: 'current_fungible_asset_balances_aggregate', aggregate?: { __typename?: 'current_fungible_asset_balances_aggregate_fields', count: number } | null } }; + export type GetAccountCoinsDataQueryVariables = Types.Exact<{ - owner_address?: Types.InputMaybe; + where_condition: Types.Current_Fungible_Asset_Balances_Bool_Exp; offset?: Types.InputMaybe; limit?: Types.InputMaybe; + order_by?: Types.InputMaybe | Types.Current_Fungible_Asset_Balances_Order_By>; }>; -export type GetAccountCoinsDataQuery = { __typename?: 'query_root', current_coin_balances: Array<{ __typename?: 'current_coin_balances', amount: any, coin_type: string, coin_type_hash: string, last_transaction_timestamp: any, last_transaction_version: any, owner_address: string, coin_info?: { __typename?: 'coin_infos', coin_type: string, coin_type_hash: string, creator_address: string, decimals: number, name: string, supply_aggregator_table_handle?: string | null, supply_aggregator_table_key?: string | null, symbol: string, transaction_created_timestamp: any, transaction_version_created: any } | null }> }; +export type GetAccountCoinsDataQuery = { __typename?: 'query_root', current_fungible_asset_balances: Array<{ __typename?: 'current_fungible_asset_balances', amount: any, asset_type: string, is_frozen: boolean, is_primary: boolean, last_transaction_timestamp: any, last_transaction_version: any, owner_address: string, storage_id: string, token_standard: string, metadata?: { __typename?: 'fungible_asset_metadata', token_standard: string, symbol: string, supply_aggregator_table_key_v1?: string | null, supply_aggregator_table_handle_v1?: string | null, project_uri?: string | null, name: string, last_transaction_version: any, last_transaction_timestamp: any, icon_uri?: string | null, decimals: number, creator_address: string, asset_type: string } | null }> }; export type GetAccountCurrentTokensQueryVariables = Types.Exact<{ address: Types.Scalars['String']; diff --git a/ecosystem/typescript/sdk/src/indexer/generated/queries.ts b/ecosystem/typescript/sdk/src/indexer/generated/queries.ts index 77002cdb76ba68..b60c927468001c 100644 --- a/ecosystem/typescript/sdk/src/indexer/generated/queries.ts +++ b/ecosystem/typescript/sdk/src/indexer/generated/queries.ts @@ -90,30 +90,47 @@ export const TokenActivitiesFieldsFragmentDoc = ` type } `; +export const GetAccountCoinsDataCount = ` + query getAccountCoinsDataCount($address: String) { + current_fungible_asset_balances_aggregate( + where: {owner_address: {_eq: $address}} + ) { + aggregate { + count + } + } +} + `; export const GetAccountCoinsData = ` - query getAccountCoinsData($owner_address: String, $offset: Int, $limit: Int) { - current_coin_balances( - where: {owner_address: {_eq: $owner_address}} + query getAccountCoinsData($where_condition: current_fungible_asset_balances_bool_exp!, $offset: Int, $limit: Int, $order_by: [current_fungible_asset_balances_order_by!]) { + current_fungible_asset_balances( + where: $where_condition offset: $offset limit: $limit + order_by: $order_by ) { amount - coin_type - coin_type_hash + asset_type + is_frozen + is_primary last_transaction_timestamp last_transaction_version owner_address - coin_info { - coin_type - coin_type_hash - creator_address - decimals - name - supply_aggregator_table_handle - supply_aggregator_table_key + storage_id + token_standard + metadata { + token_standard symbol - transaction_created_timestamp - transaction_version_created + supply_aggregator_table_key_v1 + supply_aggregator_table_handle_v1 + project_uri + name + last_transaction_version + last_transaction_timestamp + icon_uri + decimals + creator_address + asset_type } } } @@ -417,7 +434,10 @@ const defaultWrapper: SdkFunctionWrapper = (action, _operationName, _operationTy export function getSdk(client: GraphQLClient, withWrapper: SdkFunctionWrapper = defaultWrapper) { return { - getAccountCoinsData(variables?: Types.GetAccountCoinsDataQueryVariables, requestHeaders?: Dom.RequestInit["headers"]): Promise { + getAccountCoinsDataCount(variables?: Types.GetAccountCoinsDataCountQueryVariables, requestHeaders?: Dom.RequestInit["headers"]): Promise { + return withWrapper((wrappedRequestHeaders) => client.request(GetAccountCoinsDataCount, variables, {...requestHeaders, ...wrappedRequestHeaders}), 'getAccountCoinsDataCount', 'query'); + }, + getAccountCoinsData(variables: Types.GetAccountCoinsDataQueryVariables, requestHeaders?: Dom.RequestInit["headers"]): Promise { return withWrapper((wrappedRequestHeaders) => client.request(GetAccountCoinsData, variables, {...requestHeaders, ...wrappedRequestHeaders}), 'getAccountCoinsData', 'query'); }, getAccountCurrentTokens(variables: Types.GetAccountCurrentTokensQueryVariables, requestHeaders?: Dom.RequestInit["headers"]): Promise { diff --git a/ecosystem/typescript/sdk/src/indexer/generated/types.ts b/ecosystem/typescript/sdk/src/indexer/generated/types.ts index 8e9b6b57d86c13..be08b54c9cad27 100644 --- a/ecosystem/typescript/sdk/src/indexer/generated/types.ts +++ b/ecosystem/typescript/sdk/src/indexer/generated/types.ts @@ -80,10 +80,17 @@ export type String_Comparison_Exp = { export type Account_Transactions = { __typename?: 'account_transactions'; account_address: Scalars['String']; + /** An array relationship */ coin_activities: Array; + /** An aggregate relationship */ coin_activities_aggregate: Coin_Activities_Aggregate; + /** An array relationship */ delegated_staking_activities: Array; + /** An array relationship */ + fungible_asset_activities: Array; + /** An array relationship */ token_activities: Array; + /** An aggregate relationship */ token_activities_aggregate: Token_Activities_Aggregate; /** An array relationship */ token_activities_v2: Array; @@ -123,6 +130,16 @@ export type Account_TransactionsDelegated_Staking_ActivitiesArgs = { }; +/** columns and relationships of "account_transactions" */ +export type Account_TransactionsFungible_Asset_ActivitiesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + /** columns and relationships of "account_transactions" */ export type Account_TransactionsToken_ActivitiesArgs = { distinct_on?: InputMaybe>; @@ -206,6 +223,7 @@ export type Account_Transactions_Bool_Exp = { account_address?: InputMaybe; coin_activities?: InputMaybe; delegated_staking_activities?: InputMaybe; + fungible_asset_activities?: InputMaybe; token_activities?: InputMaybe; token_activities_v2?: InputMaybe; transaction_version?: InputMaybe; @@ -230,6 +248,7 @@ export type Account_Transactions_Order_By = { account_address?: InputMaybe; coin_activities_aggregate?: InputMaybe; delegated_staking_activities_aggregate?: InputMaybe; + fungible_asset_activities_aggregate?: InputMaybe; token_activities_aggregate?: InputMaybe; token_activities_v2_aggregate?: InputMaybe; transaction_version?: InputMaybe; @@ -357,11 +376,20 @@ export type Address_Events_Summary_Stream_Cursor_Value_Input = { export type Address_Version_From_Events = { __typename?: 'address_version_from_events'; account_address?: Maybe; + /** An array relationship */ coin_activities: Array; + /** An aggregate relationship */ coin_activities_aggregate: Coin_Activities_Aggregate; + /** An array relationship */ delegated_staking_activities: Array; + /** An array relationship */ token_activities: Array; + /** An aggregate relationship */ token_activities_aggregate: Token_Activities_Aggregate; + /** An array relationship */ + token_activities_v2: Array; + /** An aggregate relationship */ + token_activities_v2_aggregate: Token_Activities_V2_Aggregate; transaction_version?: Maybe; }; @@ -415,6 +443,26 @@ export type Address_Version_From_EventsToken_Activities_AggregateArgs = { where?: InputMaybe; }; + +/** columns and relationships of "address_version_from_events" */ +export type Address_Version_From_EventsToken_Activities_V2Args = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +/** columns and relationships of "address_version_from_events" */ +export type Address_Version_From_EventsToken_Activities_V2_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + /** aggregated selection of "address_version_from_events" */ export type Address_Version_From_Events_Aggregate = { __typename?: 'address_version_from_events_aggregate'; @@ -457,6 +505,10 @@ export type Address_Version_From_Events_Bool_Exp = { _not?: InputMaybe; _or?: InputMaybe>; account_address?: InputMaybe; + coin_activities?: InputMaybe; + delegated_staking_activities?: InputMaybe; + token_activities?: InputMaybe; + token_activities_v2?: InputMaybe; transaction_version?: InputMaybe; }; @@ -477,6 +529,10 @@ export type Address_Version_From_Events_Min_Fields = { /** Ordering options when selecting data from "address_version_from_events". */ export type Address_Version_From_Events_Order_By = { account_address?: InputMaybe; + coin_activities_aggregate?: InputMaybe; + delegated_staking_activities_aggregate?: InputMaybe; + token_activities_aggregate?: InputMaybe; + token_activities_v2_aggregate?: InputMaybe; transaction_version?: InputMaybe; }; @@ -548,11 +604,20 @@ export type Address_Version_From_Events_Variance_Fields = { export type Address_Version_From_Move_Resources = { __typename?: 'address_version_from_move_resources'; address?: Maybe; + /** An array relationship */ coin_activities: Array; + /** An aggregate relationship */ coin_activities_aggregate: Coin_Activities_Aggregate; + /** An array relationship */ delegated_staking_activities: Array; + /** An array relationship */ token_activities: Array; + /** An aggregate relationship */ token_activities_aggregate: Token_Activities_Aggregate; + /** An array relationship */ + token_activities_v2: Array; + /** An aggregate relationship */ + token_activities_v2_aggregate: Token_Activities_V2_Aggregate; transaction_version?: Maybe; }; @@ -606,18 +671,96 @@ export type Address_Version_From_Move_ResourcesToken_Activities_AggregateArgs = where?: InputMaybe; }; + +/** columns and relationships of "address_version_from_move_resources" */ +export type Address_Version_From_Move_ResourcesToken_Activities_V2Args = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +/** columns and relationships of "address_version_from_move_resources" */ +export type Address_Version_From_Move_ResourcesToken_Activities_V2_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + +/** aggregated selection of "address_version_from_move_resources" */ +export type Address_Version_From_Move_Resources_Aggregate = { + __typename?: 'address_version_from_move_resources_aggregate'; + aggregate?: Maybe; + nodes: Array; +}; + +/** aggregate fields of "address_version_from_move_resources" */ +export type Address_Version_From_Move_Resources_Aggregate_Fields = { + __typename?: 'address_version_from_move_resources_aggregate_fields'; + avg?: Maybe; + count: Scalars['Int']; + max?: Maybe; + min?: Maybe; + stddev?: Maybe; + stddev_pop?: Maybe; + stddev_samp?: Maybe; + sum?: Maybe; + var_pop?: Maybe; + var_samp?: Maybe; + variance?: Maybe; +}; + + +/** aggregate fields of "address_version_from_move_resources" */ +export type Address_Version_From_Move_Resources_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; + distinct?: InputMaybe; +}; + +/** aggregate avg on columns */ +export type Address_Version_From_Move_Resources_Avg_Fields = { + __typename?: 'address_version_from_move_resources_avg_fields'; + transaction_version?: Maybe; +}; + /** Boolean expression to filter rows from the table "address_version_from_move_resources". All fields are combined with a logical 'AND'. */ export type Address_Version_From_Move_Resources_Bool_Exp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; address?: InputMaybe; + coin_activities?: InputMaybe; + delegated_staking_activities?: InputMaybe; + token_activities?: InputMaybe; + token_activities_v2?: InputMaybe; transaction_version?: InputMaybe; }; +/** aggregate max on columns */ +export type Address_Version_From_Move_Resources_Max_Fields = { + __typename?: 'address_version_from_move_resources_max_fields'; + address?: Maybe; + transaction_version?: Maybe; +}; + +/** aggregate min on columns */ +export type Address_Version_From_Move_Resources_Min_Fields = { + __typename?: 'address_version_from_move_resources_min_fields'; + address?: Maybe; + transaction_version?: Maybe; +}; + /** Ordering options when selecting data from "address_version_from_move_resources". */ export type Address_Version_From_Move_Resources_Order_By = { address?: InputMaybe; + coin_activities_aggregate?: InputMaybe; + delegated_staking_activities_aggregate?: InputMaybe; + token_activities_aggregate?: InputMaybe; + token_activities_v2_aggregate?: InputMaybe; transaction_version?: InputMaybe; }; @@ -629,6 +772,24 @@ export enum Address_Version_From_Move_Resources_Select_Column { TransactionVersion = 'transaction_version' } +/** aggregate stddev on columns */ +export type Address_Version_From_Move_Resources_Stddev_Fields = { + __typename?: 'address_version_from_move_resources_stddev_fields'; + transaction_version?: Maybe; +}; + +/** aggregate stddev_pop on columns */ +export type Address_Version_From_Move_Resources_Stddev_Pop_Fields = { + __typename?: 'address_version_from_move_resources_stddev_pop_fields'; + transaction_version?: Maybe; +}; + +/** aggregate stddev_samp on columns */ +export type Address_Version_From_Move_Resources_Stddev_Samp_Fields = { + __typename?: 'address_version_from_move_resources_stddev_samp_fields'; + transaction_version?: Maybe; +}; + /** Streaming cursor of the table "address_version_from_move_resources" */ export type Address_Version_From_Move_Resources_Stream_Cursor_Input = { /** Stream column input with initial value */ @@ -643,6 +804,30 @@ export type Address_Version_From_Move_Resources_Stream_Cursor_Value_Input = { transaction_version?: InputMaybe; }; +/** aggregate sum on columns */ +export type Address_Version_From_Move_Resources_Sum_Fields = { + __typename?: 'address_version_from_move_resources_sum_fields'; + transaction_version?: Maybe; +}; + +/** aggregate var_pop on columns */ +export type Address_Version_From_Move_Resources_Var_Pop_Fields = { + __typename?: 'address_version_from_move_resources_var_pop_fields'; + transaction_version?: Maybe; +}; + +/** aggregate var_samp on columns */ +export type Address_Version_From_Move_Resources_Var_Samp_Fields = { + __typename?: 'address_version_from_move_resources_var_samp_fields'; + transaction_version?: Maybe; +}; + +/** aggregate variance on columns */ +export type Address_Version_From_Move_Resources_Variance_Fields = { + __typename?: 'address_version_from_move_resources_variance_fields'; + transaction_version?: Maybe; +}; + /** Boolean expression to compare columns of type "bigint". All fields are combined with logical 'AND'. */ export type Bigint_Comparison_Exp = { _eq?: InputMaybe; @@ -2237,12 +2422,16 @@ export type Current_Delegated_Staking_Pool_Balances_Stream_Cursor_Value_Input = /** columns and relationships of "current_delegator_balances" */ export type Current_Delegator_Balances = { __typename?: 'current_delegator_balances'; + /** An object relationship */ + current_pool_balance?: Maybe; delegator_address: Scalars['String']; last_transaction_version: Scalars['bigint']; parent_table_handle: Scalars['String']; pool_address: Scalars['String']; pool_type: Scalars['String']; shares: Scalars['numeric']; + /** An object relationship */ + staking_pool_metadata?: Maybe; table_handle: Scalars['String']; }; @@ -2251,23 +2440,27 @@ export type Current_Delegator_Balances_Bool_Exp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; + current_pool_balance?: InputMaybe; delegator_address?: InputMaybe; last_transaction_version?: InputMaybe; parent_table_handle?: InputMaybe; pool_address?: InputMaybe; pool_type?: InputMaybe; shares?: InputMaybe; + staking_pool_metadata?: InputMaybe; table_handle?: InputMaybe; }; /** Ordering options when selecting data from "current_delegator_balances". */ export type Current_Delegator_Balances_Order_By = { + current_pool_balance?: InputMaybe; delegator_address?: InputMaybe; last_transaction_version?: InputMaybe; parent_table_handle?: InputMaybe; pool_address?: InputMaybe; pool_type?: InputMaybe; shares?: InputMaybe; + staking_pool_metadata?: InputMaybe; table_handle?: InputMaybe; }; @@ -2308,72 +2501,346 @@ export type Current_Delegator_Balances_Stream_Cursor_Value_Input = { table_handle?: InputMaybe; }; -/** columns and relationships of "current_staking_pool_voter" */ -export type Current_Staking_Pool_Voter = { - __typename?: 'current_staking_pool_voter'; +/** columns and relationships of "current_fungible_asset_balances" */ +export type Current_Fungible_Asset_Balances = { + __typename?: 'current_fungible_asset_balances'; + amount: Scalars['numeric']; + asset_type: Scalars['String']; + is_frozen: Scalars['Boolean']; + is_primary: Scalars['Boolean']; + last_transaction_timestamp: Scalars['timestamp']; last_transaction_version: Scalars['bigint']; - operator_address: Scalars['String']; - /** An array relationship */ - operator_aptos_name: Array; - staking_pool_address: Scalars['String']; - voter_address: Scalars['String']; + /** An object relationship */ + metadata?: Maybe; + owner_address: Scalars['String']; + storage_id: Scalars['String']; + token_standard: Scalars['String']; }; +/** aggregated selection of "current_fungible_asset_balances" */ +export type Current_Fungible_Asset_Balances_Aggregate = { + __typename?: 'current_fungible_asset_balances_aggregate'; + aggregate?: Maybe; + nodes: Array; +}; -/** columns and relationships of "current_staking_pool_voter" */ -export type Current_Staking_Pool_VoterOperator_Aptos_NameArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; +/** aggregate fields of "current_fungible_asset_balances" */ +export type Current_Fungible_Asset_Balances_Aggregate_Fields = { + __typename?: 'current_fungible_asset_balances_aggregate_fields'; + avg?: Maybe; + count: Scalars['Int']; + max?: Maybe; + min?: Maybe; + stddev?: Maybe; + stddev_pop?: Maybe; + stddev_samp?: Maybe; + sum?: Maybe; + var_pop?: Maybe; + var_samp?: Maybe; + variance?: Maybe; }; -/** Boolean expression to filter rows from the table "current_staking_pool_voter". All fields are combined with a logical 'AND'. */ -export type Current_Staking_Pool_Voter_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; + +/** aggregate fields of "current_fungible_asset_balances" */ +export type Current_Fungible_Asset_Balances_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; + distinct?: InputMaybe; +}; + +/** aggregate avg on columns */ +export type Current_Fungible_Asset_Balances_Avg_Fields = { + __typename?: 'current_fungible_asset_balances_avg_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** Boolean expression to filter rows from the table "current_fungible_asset_balances". All fields are combined with a logical 'AND'. */ +export type Current_Fungible_Asset_Balances_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + amount?: InputMaybe; + asset_type?: InputMaybe; + is_frozen?: InputMaybe; + is_primary?: InputMaybe; + last_transaction_timestamp?: InputMaybe; last_transaction_version?: InputMaybe; - operator_address?: InputMaybe; - operator_aptos_name?: InputMaybe; - staking_pool_address?: InputMaybe; - voter_address?: InputMaybe; + metadata?: InputMaybe; + owner_address?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; }; -/** Ordering options when selecting data from "current_staking_pool_voter". */ -export type Current_Staking_Pool_Voter_Order_By = { +/** aggregate max on columns */ +export type Current_Fungible_Asset_Balances_Max_Fields = { + __typename?: 'current_fungible_asset_balances_max_fields'; + amount?: Maybe; + asset_type?: Maybe; + last_transaction_timestamp?: Maybe; + last_transaction_version?: Maybe; + owner_address?: Maybe; + storage_id?: Maybe; + token_standard?: Maybe; +}; + +/** aggregate min on columns */ +export type Current_Fungible_Asset_Balances_Min_Fields = { + __typename?: 'current_fungible_asset_balances_min_fields'; + amount?: Maybe; + asset_type?: Maybe; + last_transaction_timestamp?: Maybe; + last_transaction_version?: Maybe; + owner_address?: Maybe; + storage_id?: Maybe; + token_standard?: Maybe; +}; + +/** Ordering options when selecting data from "current_fungible_asset_balances". */ +export type Current_Fungible_Asset_Balances_Order_By = { + amount?: InputMaybe; + asset_type?: InputMaybe; + is_frozen?: InputMaybe; + is_primary?: InputMaybe; + last_transaction_timestamp?: InputMaybe; last_transaction_version?: InputMaybe; - operator_address?: InputMaybe; - operator_aptos_name_aggregate?: InputMaybe; - staking_pool_address?: InputMaybe; - voter_address?: InputMaybe; + metadata?: InputMaybe; + owner_address?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; }; -/** select columns of table "current_staking_pool_voter" */ -export enum Current_Staking_Pool_Voter_Select_Column { +/** select columns of table "current_fungible_asset_balances" */ +export enum Current_Fungible_Asset_Balances_Select_Column { + /** column name */ + Amount = 'amount', + /** column name */ + AssetType = 'asset_type', + /** column name */ + IsFrozen = 'is_frozen', + /** column name */ + IsPrimary = 'is_primary', + /** column name */ + LastTransactionTimestamp = 'last_transaction_timestamp', /** column name */ LastTransactionVersion = 'last_transaction_version', /** column name */ - OperatorAddress = 'operator_address', + OwnerAddress = 'owner_address', /** column name */ - StakingPoolAddress = 'staking_pool_address', + StorageId = 'storage_id', /** column name */ - VoterAddress = 'voter_address' + TokenStandard = 'token_standard' } -/** Streaming cursor of the table "current_staking_pool_voter" */ -export type Current_Staking_Pool_Voter_Stream_Cursor_Input = { +/** aggregate stddev on columns */ +export type Current_Fungible_Asset_Balances_Stddev_Fields = { + __typename?: 'current_fungible_asset_balances_stddev_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** aggregate stddev_pop on columns */ +export type Current_Fungible_Asset_Balances_Stddev_Pop_Fields = { + __typename?: 'current_fungible_asset_balances_stddev_pop_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** aggregate stddev_samp on columns */ +export type Current_Fungible_Asset_Balances_Stddev_Samp_Fields = { + __typename?: 'current_fungible_asset_balances_stddev_samp_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** Streaming cursor of the table "current_fungible_asset_balances" */ +export type Current_Fungible_Asset_Balances_Stream_Cursor_Input = { /** Stream column input with initial value */ - initial_value: Current_Staking_Pool_Voter_Stream_Cursor_Value_Input; + initial_value: Current_Fungible_Asset_Balances_Stream_Cursor_Value_Input; /** cursor ordering */ ordering?: InputMaybe; }; /** Initial value of the column from where the streaming should start */ -export type Current_Staking_Pool_Voter_Stream_Cursor_Value_Input = { +export type Current_Fungible_Asset_Balances_Stream_Cursor_Value_Input = { + amount?: InputMaybe; + asset_type?: InputMaybe; + is_frozen?: InputMaybe; + is_primary?: InputMaybe; + last_transaction_timestamp?: InputMaybe; last_transaction_version?: InputMaybe; - operator_address?: InputMaybe; + owner_address?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; +}; + +/** aggregate sum on columns */ +export type Current_Fungible_Asset_Balances_Sum_Fields = { + __typename?: 'current_fungible_asset_balances_sum_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** aggregate var_pop on columns */ +export type Current_Fungible_Asset_Balances_Var_Pop_Fields = { + __typename?: 'current_fungible_asset_balances_var_pop_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** aggregate var_samp on columns */ +export type Current_Fungible_Asset_Balances_Var_Samp_Fields = { + __typename?: 'current_fungible_asset_balances_var_samp_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** aggregate variance on columns */ +export type Current_Fungible_Asset_Balances_Variance_Fields = { + __typename?: 'current_fungible_asset_balances_variance_fields'; + amount?: Maybe; + last_transaction_version?: Maybe; +}; + +/** columns and relationships of "current_objects" */ +export type Current_Objects = { + __typename?: 'current_objects'; + allow_ungated_transfer: Scalars['Boolean']; + is_deleted: Scalars['Boolean']; + last_guid_creation_num: Scalars['numeric']; + last_transaction_version: Scalars['bigint']; + object_address: Scalars['String']; + owner_address: Scalars['String']; + state_key_hash: Scalars['String']; +}; + +/** Boolean expression to filter rows from the table "current_objects". All fields are combined with a logical 'AND'. */ +export type Current_Objects_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + allow_ungated_transfer?: InputMaybe; + is_deleted?: InputMaybe; + last_guid_creation_num?: InputMaybe; + last_transaction_version?: InputMaybe; + object_address?: InputMaybe; + owner_address?: InputMaybe; + state_key_hash?: InputMaybe; +}; + +/** Ordering options when selecting data from "current_objects". */ +export type Current_Objects_Order_By = { + allow_ungated_transfer?: InputMaybe; + is_deleted?: InputMaybe; + last_guid_creation_num?: InputMaybe; + last_transaction_version?: InputMaybe; + object_address?: InputMaybe; + owner_address?: InputMaybe; + state_key_hash?: InputMaybe; +}; + +/** select columns of table "current_objects" */ +export enum Current_Objects_Select_Column { + /** column name */ + AllowUngatedTransfer = 'allow_ungated_transfer', + /** column name */ + IsDeleted = 'is_deleted', + /** column name */ + LastGuidCreationNum = 'last_guid_creation_num', + /** column name */ + LastTransactionVersion = 'last_transaction_version', + /** column name */ + ObjectAddress = 'object_address', + /** column name */ + OwnerAddress = 'owner_address', + /** column name */ + StateKeyHash = 'state_key_hash' +} + +/** Streaming cursor of the table "current_objects" */ +export type Current_Objects_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Current_Objects_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Current_Objects_Stream_Cursor_Value_Input = { + allow_ungated_transfer?: InputMaybe; + is_deleted?: InputMaybe; + last_guid_creation_num?: InputMaybe; + last_transaction_version?: InputMaybe; + object_address?: InputMaybe; + owner_address?: InputMaybe; + state_key_hash?: InputMaybe; +}; + +/** columns and relationships of "current_staking_pool_voter" */ +export type Current_Staking_Pool_Voter = { + __typename?: 'current_staking_pool_voter'; + last_transaction_version: Scalars['bigint']; + operator_address: Scalars['String']; + /** An array relationship */ + operator_aptos_name: Array; + staking_pool_address: Scalars['String']; + voter_address: Scalars['String']; +}; + + +/** columns and relationships of "current_staking_pool_voter" */ +export type Current_Staking_Pool_VoterOperator_Aptos_NameArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + +/** Boolean expression to filter rows from the table "current_staking_pool_voter". All fields are combined with a logical 'AND'. */ +export type Current_Staking_Pool_Voter_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + last_transaction_version?: InputMaybe; + operator_address?: InputMaybe; + operator_aptos_name?: InputMaybe; + staking_pool_address?: InputMaybe; + voter_address?: InputMaybe; +}; + +/** Ordering options when selecting data from "current_staking_pool_voter". */ +export type Current_Staking_Pool_Voter_Order_By = { + last_transaction_version?: InputMaybe; + operator_address?: InputMaybe; + operator_aptos_name_aggregate?: InputMaybe; + staking_pool_address?: InputMaybe; + voter_address?: InputMaybe; +}; + +/** select columns of table "current_staking_pool_voter" */ +export enum Current_Staking_Pool_Voter_Select_Column { + /** column name */ + LastTransactionVersion = 'last_transaction_version', + /** column name */ + OperatorAddress = 'operator_address', + /** column name */ + StakingPoolAddress = 'staking_pool_address', + /** column name */ + VoterAddress = 'voter_address' +} + +/** Streaming cursor of the table "current_staking_pool_voter" */ +export type Current_Staking_Pool_Voter_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Current_Staking_Pool_Voter_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Current_Staking_Pool_Voter_Stream_Cursor_Value_Input = { + last_transaction_version?: InputMaybe; + operator_address?: InputMaybe; staking_pool_address?: InputMaybe; voter_address?: InputMaybe; }; @@ -3060,6 +3527,10 @@ export type Current_Token_Ownerships_Sum_Order_By = { export type Current_Token_Ownerships_V2 = { __typename?: 'current_token_ownerships_v2'; amount: Scalars['numeric']; + /** An array relationship */ + composed_nfts: Array; + /** An aggregate relationship */ + composed_nfts_aggregate: Current_Token_Ownerships_V2_Aggregate; /** An object relationship */ current_token_data?: Maybe; is_fungible_v2?: Maybe; @@ -3076,6 +3547,26 @@ export type Current_Token_Ownerships_V2 = { }; +/** columns and relationships of "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2Composed_NftsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +/** columns and relationships of "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2Composed_Nfts_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + /** columns and relationships of "current_token_ownerships_v2" */ export type Current_Token_Ownerships_V2Token_Properties_Mutated_V1Args = { path?: InputMaybe; @@ -3111,6 +3602,21 @@ export type Current_Token_Ownerships_V2_Aggregate_FieldsCountArgs = { distinct?: InputMaybe; }; +/** order by aggregate values of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Aggregate_Order_By = { + avg?: InputMaybe; + count?: InputMaybe; + max?: InputMaybe; + min?: InputMaybe; + stddev?: InputMaybe; + stddev_pop?: InputMaybe; + stddev_samp?: InputMaybe; + sum?: InputMaybe; + var_pop?: InputMaybe; + var_samp?: InputMaybe; + variance?: InputMaybe; +}; + /** aggregate avg on columns */ export type Current_Token_Ownerships_V2_Avg_Fields = { __typename?: 'current_token_ownerships_v2_avg_fields'; @@ -3119,12 +3625,20 @@ export type Current_Token_Ownerships_V2_Avg_Fields = { property_version_v1?: Maybe; }; +/** order by avg() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Avg_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** Boolean expression to filter rows from the table "current_token_ownerships_v2". All fields are combined with a logical 'AND'. */ export type Current_Token_Ownerships_V2_Bool_Exp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; amount?: InputMaybe; + composed_nfts?: InputMaybe; current_token_data?: InputMaybe; is_fungible_v2?: InputMaybe; is_soulbound_v2?: InputMaybe; @@ -3153,6 +3667,19 @@ export type Current_Token_Ownerships_V2_Max_Fields = { token_standard?: Maybe; }; +/** order by max() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Max_Order_By = { + amount?: InputMaybe; + last_transaction_timestamp?: InputMaybe; + last_transaction_version?: InputMaybe; + owner_address?: InputMaybe; + property_version_v1?: InputMaybe; + storage_id?: InputMaybe; + table_type_v1?: InputMaybe; + token_data_id?: InputMaybe; + token_standard?: InputMaybe; +}; + /** aggregate min on columns */ export type Current_Token_Ownerships_V2_Min_Fields = { __typename?: 'current_token_ownerships_v2_min_fields'; @@ -3167,9 +3694,23 @@ export type Current_Token_Ownerships_V2_Min_Fields = { token_standard?: Maybe; }; +/** order by min() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Min_Order_By = { + amount?: InputMaybe; + last_transaction_timestamp?: InputMaybe; + last_transaction_version?: InputMaybe; + owner_address?: InputMaybe; + property_version_v1?: InputMaybe; + storage_id?: InputMaybe; + table_type_v1?: InputMaybe; + token_data_id?: InputMaybe; + token_standard?: InputMaybe; +}; + /** Ordering options when selecting data from "current_token_ownerships_v2". */ export type Current_Token_Ownerships_V2_Order_By = { amount?: InputMaybe; + composed_nfts_aggregate?: InputMaybe; current_token_data?: InputMaybe; is_fungible_v2?: InputMaybe; is_soulbound_v2?: InputMaybe; @@ -3220,6 +3761,13 @@ export type Current_Token_Ownerships_V2_Stddev_Fields = { property_version_v1?: Maybe; }; +/** order by stddev() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Stddev_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate stddev_pop on columns */ export type Current_Token_Ownerships_V2_Stddev_Pop_Fields = { __typename?: 'current_token_ownerships_v2_stddev_pop_fields'; @@ -3228,6 +3776,13 @@ export type Current_Token_Ownerships_V2_Stddev_Pop_Fields = { property_version_v1?: Maybe; }; +/** order by stddev_pop() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Stddev_Pop_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate stddev_samp on columns */ export type Current_Token_Ownerships_V2_Stddev_Samp_Fields = { __typename?: 'current_token_ownerships_v2_stddev_samp_fields'; @@ -3236,6 +3791,13 @@ export type Current_Token_Ownerships_V2_Stddev_Samp_Fields = { property_version_v1?: Maybe; }; +/** order by stddev_samp() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Stddev_Samp_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** Streaming cursor of the table "current_token_ownerships_v2" */ export type Current_Token_Ownerships_V2_Stream_Cursor_Input = { /** Stream column input with initial value */ @@ -3268,6 +3830,13 @@ export type Current_Token_Ownerships_V2_Sum_Fields = { property_version_v1?: Maybe; }; +/** order by sum() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Sum_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate var_pop on columns */ export type Current_Token_Ownerships_V2_Var_Pop_Fields = { __typename?: 'current_token_ownerships_v2_var_pop_fields'; @@ -3276,6 +3845,13 @@ export type Current_Token_Ownerships_V2_Var_Pop_Fields = { property_version_v1?: Maybe; }; +/** order by var_pop() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Var_Pop_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate var_samp on columns */ export type Current_Token_Ownerships_V2_Var_Samp_Fields = { __typename?: 'current_token_ownerships_v2_var_samp_fields'; @@ -3284,6 +3860,13 @@ export type Current_Token_Ownerships_V2_Var_Samp_Fields = { property_version_v1?: Maybe; }; +/** order by var_samp() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Var_Samp_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate variance on columns */ export type Current_Token_Ownerships_V2_Variance_Fields = { __typename?: 'current_token_ownerships_v2_variance_fields'; @@ -3292,6 +3875,13 @@ export type Current_Token_Ownerships_V2_Variance_Fields = { property_version_v1?: Maybe; }; +/** order by variance() on columns of table "current_token_ownerships_v2" */ +export type Current_Token_Ownerships_V2_Variance_Order_By = { + amount?: InputMaybe; + last_transaction_version?: InputMaybe; + property_version_v1?: InputMaybe; +}; + /** aggregate var_pop on columns */ export type Current_Token_Ownerships_Var_Pop_Fields = { __typename?: 'current_token_ownerships_var_pop_fields'; @@ -3699,6 +4289,28 @@ export type Delegator_Distinct_Pool = { staking_pool_metadata?: Maybe; }; +/** aggregated selection of "delegator_distinct_pool" */ +export type Delegator_Distinct_Pool_Aggregate = { + __typename?: 'delegator_distinct_pool_aggregate'; + aggregate?: Maybe; + nodes: Array; +}; + +/** aggregate fields of "delegator_distinct_pool" */ +export type Delegator_Distinct_Pool_Aggregate_Fields = { + __typename?: 'delegator_distinct_pool_aggregate_fields'; + count: Scalars['Int']; + max?: Maybe; + min?: Maybe; +}; + + +/** aggregate fields of "delegator_distinct_pool" */ +export type Delegator_Distinct_Pool_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; + distinct?: InputMaybe; +}; + /** Boolean expression to filter rows from the table "delegator_distinct_pool". All fields are combined with a logical 'AND'. */ export type Delegator_Distinct_Pool_Bool_Exp = { _and?: InputMaybe>; @@ -3710,6 +4322,20 @@ export type Delegator_Distinct_Pool_Bool_Exp = { staking_pool_metadata?: InputMaybe; }; +/** aggregate max on columns */ +export type Delegator_Distinct_Pool_Max_Fields = { + __typename?: 'delegator_distinct_pool_max_fields'; + delegator_address?: Maybe; + pool_address?: Maybe; +}; + +/** aggregate min on columns */ +export type Delegator_Distinct_Pool_Min_Fields = { + __typename?: 'delegator_distinct_pool_min_fields'; + delegator_address?: Maybe; + pool_address?: Maybe; +}; + /** Ordering options when selecting data from "delegator_distinct_pool". */ export type Delegator_Distinct_Pool_Order_By = { current_pool_balance?: InputMaybe; @@ -3826,17 +4452,261 @@ export type Events_Stream_Cursor_Value_Input = { type?: InputMaybe; }; -/** columns and relationships of "indexer_status" */ -export type Indexer_Status = { - __typename?: 'indexer_status'; - db: Scalars['String']; - is_indexer_up: Scalars['Boolean']; +/** columns and relationships of "fungible_asset_activities" */ +export type Fungible_Asset_Activities = { + __typename?: 'fungible_asset_activities'; + amount?: Maybe; + asset_type: Scalars['String']; + block_height: Scalars['bigint']; + entry_function_id_str?: Maybe; + event_index: Scalars['bigint']; + gas_fee_payer_address?: Maybe; + is_frozen?: Maybe; + is_gas_fee: Scalars['Boolean']; + is_transaction_success: Scalars['Boolean']; + /** An object relationship */ + metadata?: Maybe; + owner_address: Scalars['String']; + /** An array relationship */ + owner_aptos_names: Array; + storage_id: Scalars['String']; + token_standard: Scalars['String']; + transaction_timestamp: Scalars['timestamp']; + transaction_version: Scalars['bigint']; + type: Scalars['String']; }; -/** Boolean expression to filter rows from the table "indexer_status". All fields are combined with a logical 'AND'. */ -export type Indexer_Status_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; + +/** columns and relationships of "fungible_asset_activities" */ +export type Fungible_Asset_ActivitiesOwner_Aptos_NamesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + +/** Boolean expression to filter rows from the table "fungible_asset_activities". All fields are combined with a logical 'AND'. */ +export type Fungible_Asset_Activities_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + amount?: InputMaybe; + asset_type?: InputMaybe; + block_height?: InputMaybe; + entry_function_id_str?: InputMaybe; + event_index?: InputMaybe; + gas_fee_payer_address?: InputMaybe; + is_frozen?: InputMaybe; + is_gas_fee?: InputMaybe; + is_transaction_success?: InputMaybe; + metadata?: InputMaybe; + owner_address?: InputMaybe; + owner_aptos_names?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; + transaction_timestamp?: InputMaybe; + transaction_version?: InputMaybe; + type?: InputMaybe; +}; + +/** Ordering options when selecting data from "fungible_asset_activities". */ +export type Fungible_Asset_Activities_Order_By = { + amount?: InputMaybe; + asset_type?: InputMaybe; + block_height?: InputMaybe; + entry_function_id_str?: InputMaybe; + event_index?: InputMaybe; + gas_fee_payer_address?: InputMaybe; + is_frozen?: InputMaybe; + is_gas_fee?: InputMaybe; + is_transaction_success?: InputMaybe; + metadata?: InputMaybe; + owner_address?: InputMaybe; + owner_aptos_names_aggregate?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; + transaction_timestamp?: InputMaybe; + transaction_version?: InputMaybe; + type?: InputMaybe; +}; + +/** select columns of table "fungible_asset_activities" */ +export enum Fungible_Asset_Activities_Select_Column { + /** column name */ + Amount = 'amount', + /** column name */ + AssetType = 'asset_type', + /** column name */ + BlockHeight = 'block_height', + /** column name */ + EntryFunctionIdStr = 'entry_function_id_str', + /** column name */ + EventIndex = 'event_index', + /** column name */ + GasFeePayerAddress = 'gas_fee_payer_address', + /** column name */ + IsFrozen = 'is_frozen', + /** column name */ + IsGasFee = 'is_gas_fee', + /** column name */ + IsTransactionSuccess = 'is_transaction_success', + /** column name */ + OwnerAddress = 'owner_address', + /** column name */ + StorageId = 'storage_id', + /** column name */ + TokenStandard = 'token_standard', + /** column name */ + TransactionTimestamp = 'transaction_timestamp', + /** column name */ + TransactionVersion = 'transaction_version', + /** column name */ + Type = 'type' +} + +/** Streaming cursor of the table "fungible_asset_activities" */ +export type Fungible_Asset_Activities_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Fungible_Asset_Activities_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Fungible_Asset_Activities_Stream_Cursor_Value_Input = { + amount?: InputMaybe; + asset_type?: InputMaybe; + block_height?: InputMaybe; + entry_function_id_str?: InputMaybe; + event_index?: InputMaybe; + gas_fee_payer_address?: InputMaybe; + is_frozen?: InputMaybe; + is_gas_fee?: InputMaybe; + is_transaction_success?: InputMaybe; + owner_address?: InputMaybe; + storage_id?: InputMaybe; + token_standard?: InputMaybe; + transaction_timestamp?: InputMaybe; + transaction_version?: InputMaybe; + type?: InputMaybe; +}; + +/** columns and relationships of "fungible_asset_metadata" */ +export type Fungible_Asset_Metadata = { + __typename?: 'fungible_asset_metadata'; + asset_type: Scalars['String']; + creator_address: Scalars['String']; + decimals: Scalars['Int']; + icon_uri?: Maybe; + last_transaction_timestamp: Scalars['timestamp']; + last_transaction_version: Scalars['bigint']; + name: Scalars['String']; + project_uri?: Maybe; + supply_aggregator_table_handle_v1?: Maybe; + supply_aggregator_table_key_v1?: Maybe; + symbol: Scalars['String']; + token_standard: Scalars['String']; +}; + +/** Boolean expression to filter rows from the table "fungible_asset_metadata". All fields are combined with a logical 'AND'. */ +export type Fungible_Asset_Metadata_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + asset_type?: InputMaybe; + creator_address?: InputMaybe; + decimals?: InputMaybe; + icon_uri?: InputMaybe; + last_transaction_timestamp?: InputMaybe; + last_transaction_version?: InputMaybe; + name?: InputMaybe; + project_uri?: InputMaybe; + supply_aggregator_table_handle_v1?: InputMaybe; + supply_aggregator_table_key_v1?: InputMaybe; + symbol?: InputMaybe; + token_standard?: InputMaybe; +}; + +/** Ordering options when selecting data from "fungible_asset_metadata". */ +export type Fungible_Asset_Metadata_Order_By = { + asset_type?: InputMaybe; + creator_address?: InputMaybe; + decimals?: InputMaybe; + icon_uri?: InputMaybe; + last_transaction_timestamp?: InputMaybe; + last_transaction_version?: InputMaybe; + name?: InputMaybe; + project_uri?: InputMaybe; + supply_aggregator_table_handle_v1?: InputMaybe; + supply_aggregator_table_key_v1?: InputMaybe; + symbol?: InputMaybe; + token_standard?: InputMaybe; +}; + +/** select columns of table "fungible_asset_metadata" */ +export enum Fungible_Asset_Metadata_Select_Column { + /** column name */ + AssetType = 'asset_type', + /** column name */ + CreatorAddress = 'creator_address', + /** column name */ + Decimals = 'decimals', + /** column name */ + IconUri = 'icon_uri', + /** column name */ + LastTransactionTimestamp = 'last_transaction_timestamp', + /** column name */ + LastTransactionVersion = 'last_transaction_version', + /** column name */ + Name = 'name', + /** column name */ + ProjectUri = 'project_uri', + /** column name */ + SupplyAggregatorTableHandleV1 = 'supply_aggregator_table_handle_v1', + /** column name */ + SupplyAggregatorTableKeyV1 = 'supply_aggregator_table_key_v1', + /** column name */ + Symbol = 'symbol', + /** column name */ + TokenStandard = 'token_standard' +} + +/** Streaming cursor of the table "fungible_asset_metadata" */ +export type Fungible_Asset_Metadata_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Fungible_Asset_Metadata_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Fungible_Asset_Metadata_Stream_Cursor_Value_Input = { + asset_type?: InputMaybe; + creator_address?: InputMaybe; + decimals?: InputMaybe; + icon_uri?: InputMaybe; + last_transaction_timestamp?: InputMaybe; + last_transaction_version?: InputMaybe; + name?: InputMaybe; + project_uri?: InputMaybe; + supply_aggregator_table_handle_v1?: InputMaybe; + supply_aggregator_table_key_v1?: InputMaybe; + symbol?: InputMaybe; + token_standard?: InputMaybe; +}; + +/** columns and relationships of "indexer_status" */ +export type Indexer_Status = { + __typename?: 'indexer_status'; + db: Scalars['String']; + is_indexer_up: Scalars['Boolean']; +}; + +/** Boolean expression to filter rows from the table "indexer_status". All fields are combined with a logical 'AND'. */ +export type Indexer_Status_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; _or?: InputMaybe>; db?: InputMaybe; is_indexer_up?: InputMaybe; @@ -4081,6 +4951,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Auctions = { contract_address: Scalars['String']; current_bid_price?: Maybe; current_bidder?: Maybe; + /** An object relationship */ current_token_data?: Maybe; entry_function_id_str: Scalars['String']; expiration_time: Scalars['numeric']; @@ -4108,6 +4979,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Auctions_Bool_Exp = { contract_address?: InputMaybe; current_bid_price?: InputMaybe; current_bidder?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4131,6 +5003,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Auctions_Order_By = { contract_address?: InputMaybe; current_bid_price?: InputMaybe; current_bidder?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4227,7 +5100,8 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Collection_Offers = { collection_id: Scalars['String']; collection_offer_id: Scalars['String']; contract_address: Scalars['String']; - current_collection?: Maybe; + /** An object relationship */ + current_collection_v2?: Maybe; entry_function_id_str: Scalars['String']; expiration_time: Scalars['numeric']; fee_schedule_id: Scalars['String']; @@ -4250,6 +5124,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Collection_Offers_Bool_Ex collection_id?: InputMaybe; collection_offer_id?: InputMaybe; contract_address?: InputMaybe; + current_collection_v2?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4269,6 +5144,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Collection_Offers_Order_B collection_id?: InputMaybe; collection_offer_id?: InputMaybe; contract_address?: InputMaybe; + current_collection_v2?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4348,6 +5224,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Listings = { coin_type?: Maybe; collection_id: Scalars['String']; contract_address: Scalars['String']; + /** An object relationship */ current_token_data?: Maybe; entry_function_id_str: Scalars['String']; fee_schedule_id: Scalars['String']; @@ -4371,6 +5248,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Listings_Bool_Exp = { coin_type?: InputMaybe; collection_id?: InputMaybe; contract_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; fee_schedule_id?: InputMaybe; is_deleted?: InputMaybe; @@ -4390,6 +5268,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Listings_Order_By = { coin_type?: InputMaybe; collection_id?: InputMaybe; contract_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; fee_schedule_id?: InputMaybe; is_deleted?: InputMaybe; @@ -4472,6 +5351,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Token_Offers = { coin_type?: Maybe; collection_id: Scalars['String']; contract_address: Scalars['String']; + /** An object relationship */ current_token_data?: Maybe; entry_function_id_str: Scalars['String']; expiration_time: Scalars['numeric']; @@ -4496,6 +5376,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Token_Offers_Bool_Exp = { coin_type?: InputMaybe; collection_id?: InputMaybe; contract_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4516,6 +5397,7 @@ export type Nft_Marketplace_V2_Current_Nft_Marketplace_Token_Offers_Order_By = { coin_type?: InputMaybe; collection_id?: InputMaybe; contract_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; expiration_time?: InputMaybe; fee_schedule_id?: InputMaybe; @@ -4603,6 +5485,7 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities = { collection_name: Scalars['String']; contract_address: Scalars['String']; creator_address: Scalars['String']; + /** An object relationship */ current_token_data?: Maybe; entry_function_id_str: Scalars['String']; event_index: Scalars['bigint']; @@ -4621,45 +5504,6 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities = { transaction_version: Scalars['bigint']; }; -/** aggregated selection of "nft_marketplace_v2.nft_marketplace_activities" */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Aggregate = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_aggregate'; - aggregate?: Maybe; - nodes: Array; -}; - -/** aggregate fields of "nft_marketplace_v2.nft_marketplace_activities" */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Aggregate_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_aggregate_fields'; - avg?: Maybe; - count: Scalars['Int']; - max?: Maybe; - min?: Maybe; - stddev?: Maybe; - stddev_pop?: Maybe; - stddev_samp?: Maybe; - sum?: Maybe; - var_pop?: Maybe; - var_samp?: Maybe; - variance?: Maybe; -}; - - -/** aggregate fields of "nft_marketplace_v2.nft_marketplace_activities" */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Aggregate_FieldsCountArgs = { - columns?: InputMaybe>; - distinct?: InputMaybe; -}; - -/** aggregate avg on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Avg_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_avg_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - /** Boolean expression to filter rows from the table "nft_marketplace_v2.nft_marketplace_activities". All fields are combined with a logical 'AND'. */ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Bool_Exp = { _and?: InputMaybe>; @@ -4671,6 +5515,7 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Bool_Exp = { collection_name?: InputMaybe; contract_address?: InputMaybe; creator_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; event_index?: InputMaybe; event_type?: InputMaybe; @@ -4688,58 +5533,6 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Bool_Exp = { transaction_version?: InputMaybe; }; -/** aggregate max on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Max_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_max_fields'; - buyer?: Maybe; - coin_type?: Maybe; - collection_id?: Maybe; - collection_name?: Maybe; - contract_address?: Maybe; - creator_address?: Maybe; - entry_function_id_str?: Maybe; - event_index?: Maybe; - event_type?: Maybe; - fee_schedule_id?: Maybe; - marketplace?: Maybe; - offer_or_listing_id?: Maybe; - price?: Maybe; - property_version?: Maybe; - seller?: Maybe; - token_amount?: Maybe; - token_data_id?: Maybe; - token_name?: Maybe; - token_standard?: Maybe; - transaction_timestamp?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate min on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Min_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_min_fields'; - buyer?: Maybe; - coin_type?: Maybe; - collection_id?: Maybe; - collection_name?: Maybe; - contract_address?: Maybe; - creator_address?: Maybe; - entry_function_id_str?: Maybe; - event_index?: Maybe; - event_type?: Maybe; - fee_schedule_id?: Maybe; - marketplace?: Maybe; - offer_or_listing_id?: Maybe; - price?: Maybe; - property_version?: Maybe; - seller?: Maybe; - token_amount?: Maybe; - token_data_id?: Maybe; - token_name?: Maybe; - token_standard?: Maybe; - transaction_timestamp?: Maybe; - transaction_version?: Maybe; -}; - /** Ordering options when selecting data from "nft_marketplace_v2.nft_marketplace_activities". */ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Order_By = { buyer?: InputMaybe; @@ -4748,6 +5541,7 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Order_By = { collection_name?: InputMaybe; contract_address?: InputMaybe; creator_address?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; event_index?: InputMaybe; event_type?: InputMaybe; @@ -4811,33 +5605,6 @@ export enum Nft_Marketplace_V2_Nft_Marketplace_Activities_Select_Column { TransactionVersion = 'transaction_version' } -/** aggregate stddev on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Stddev_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_stddev_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate stddev_pop on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Stddev_Pop_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_stddev_pop_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate stddev_samp on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Stddev_Samp_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_stddev_samp_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - /** Streaming cursor of the table "nft_marketplace_v2_nft_marketplace_activities" */ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Stream_Cursor_Input = { /** Stream column input with initial value */ @@ -4864,272 +5631,11 @@ export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Stream_Cursor_Value_In property_version?: InputMaybe; seller?: InputMaybe; token_amount?: InputMaybe; - token_data_id?: InputMaybe; - token_name?: InputMaybe; - token_standard?: InputMaybe; - transaction_timestamp?: InputMaybe; - transaction_version?: InputMaybe; -}; - -/** aggregate sum on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Sum_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_sum_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate var_pop on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Var_Pop_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_var_pop_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate var_samp on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Var_Samp_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_var_samp_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** aggregate variance on columns */ -export type Nft_Marketplace_V2_Nft_Marketplace_Activities_Variance_Fields = { - __typename?: 'nft_marketplace_v2_nft_marketplace_activities_variance_fields'; - event_index?: Maybe; - price?: Maybe; - token_amount?: Maybe; - transaction_version?: Maybe; -}; - -/** columns and relationships of "nft_marketplace_v2_top_collections" */ -export type Nft_Marketplace_V2_Top_Collections = { - __typename?: 'nft_marketplace_v2_top_collections'; - collection_id?: Maybe; - current_collection?: Maybe; - price?: Maybe; -}; - -/** Boolean expression to filter rows from the table "nft_marketplace_v2_top_collections". All fields are combined with a logical 'AND'. */ -export type Nft_Marketplace_V2_Top_Collections_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** Ordering options when selecting data from "nft_marketplace_v2_top_collections". */ -export type Nft_Marketplace_V2_Top_Collections_Order_By = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** select columns of table "nft_marketplace_v2_top_collections" */ -export enum Nft_Marketplace_V2_Top_Collections_Select_Column { - /** column name */ - CollectionId = 'collection_id', - /** column name */ - Price = 'price' -} - -/** Streaming cursor of the table "nft_marketplace_v2_top_collections" */ -export type Nft_Marketplace_V2_Top_Collections_Stream_Cursor_Input = { - /** Stream column input with initial value */ - initial_value: Nft_Marketplace_V2_Top_Collections_Stream_Cursor_Value_Input; - /** cursor ordering */ - ordering?: InputMaybe; -}; - -/** Initial value of the column from where the streaming should start */ -export type Nft_Marketplace_V2_Top_Collections_Stream_Cursor_Value_Input = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** columns and relationships of "nft_marketplace_v2_top_collections_token_v1_24h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_24h = { - __typename?: 'nft_marketplace_v2_top_collections_token_v1_24h'; - collection_id?: Maybe; - current_collection?: Maybe; - price?: Maybe; -}; - -/** Boolean expression to filter rows from the table "nft_marketplace_v2_top_collections_token_v1_24h". All fields are combined with a logical 'AND'. */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** Ordering options when selecting data from "nft_marketplace_v2_top_collections_token_v1_24h". */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Order_By = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** select columns of table "nft_marketplace_v2_top_collections_token_v1_24h" */ -export enum Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Select_Column { - /** column name */ - CollectionId = 'collection_id', - /** column name */ - Price = 'price' -} - -/** Streaming cursor of the table "nft_marketplace_v2_top_collections_token_v1_24h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Stream_Cursor_Input = { - /** Stream column input with initial value */ - initial_value: Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Stream_Cursor_Value_Input; - /** cursor ordering */ - ordering?: InputMaybe; -}; - -/** Initial value of the column from where the streaming should start */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_24h_Stream_Cursor_Value_Input = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** columns and relationships of "nft_marketplace_v2_top_collections_token_v1_48h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_48h = { - __typename?: 'nft_marketplace_v2_top_collections_token_v1_48h'; - collection_id?: Maybe; - current_collection?: Maybe; - price?: Maybe; -}; - -/** Boolean expression to filter rows from the table "nft_marketplace_v2_top_collections_token_v1_48h". All fields are combined with a logical 'AND'. */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** Ordering options when selecting data from "nft_marketplace_v2_top_collections_token_v1_48h". */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Order_By = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** select columns of table "nft_marketplace_v2_top_collections_token_v1_48h" */ -export enum Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Select_Column { - /** column name */ - CollectionId = 'collection_id', - /** column name */ - Price = 'price' -} - -/** Streaming cursor of the table "nft_marketplace_v2_top_collections_token_v1_48h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Stream_Cursor_Input = { - /** Stream column input with initial value */ - initial_value: Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Stream_Cursor_Value_Input; - /** cursor ordering */ - ordering?: InputMaybe; -}; - -/** Initial value of the column from where the streaming should start */ -export type Nft_Marketplace_V2_Top_Collections_Token_V1_48h_Stream_Cursor_Value_Input = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** columns and relationships of "nft_marketplace_v2_top_collections_token_v2_24h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_24h = { - __typename?: 'nft_marketplace_v2_top_collections_token_v2_24h'; - collection_id?: Maybe; - current_collection?: Maybe; - price?: Maybe; -}; - -/** Boolean expression to filter rows from the table "nft_marketplace_v2_top_collections_token_v2_24h". All fields are combined with a logical 'AND'. */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** Ordering options when selecting data from "nft_marketplace_v2_top_collections_token_v2_24h". */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Order_By = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** select columns of table "nft_marketplace_v2_top_collections_token_v2_24h" */ -export enum Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Select_Column { - /** column name */ - CollectionId = 'collection_id', - /** column name */ - Price = 'price' -} - -/** Streaming cursor of the table "nft_marketplace_v2_top_collections_token_v2_24h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Stream_Cursor_Input = { - /** Stream column input with initial value */ - initial_value: Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Stream_Cursor_Value_Input; - /** cursor ordering */ - ordering?: InputMaybe; -}; - -/** Initial value of the column from where the streaming should start */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_24h_Stream_Cursor_Value_Input = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** columns and relationships of "nft_marketplace_v2_top_collections_token_v2_48h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_48h = { - __typename?: 'nft_marketplace_v2_top_collections_token_v2_48h'; - collection_id?: Maybe; - current_collection?: Maybe; - price?: Maybe; -}; - -/** Boolean expression to filter rows from the table "nft_marketplace_v2_top_collections_token_v2_48h". All fields are combined with a logical 'AND'. */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** Ordering options when selecting data from "nft_marketplace_v2_top_collections_token_v2_48h". */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Order_By = { - collection_id?: InputMaybe; - price?: InputMaybe; -}; - -/** select columns of table "nft_marketplace_v2_top_collections_token_v2_48h" */ -export enum Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Select_Column { - /** column name */ - CollectionId = 'collection_id', - /** column name */ - Price = 'price' -} - -/** Streaming cursor of the table "nft_marketplace_v2_top_collections_token_v2_48h" */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Stream_Cursor_Input = { - /** Stream column input with initial value */ - initial_value: Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Stream_Cursor_Value_Input; - /** cursor ordering */ - ordering?: InputMaybe; -}; - -/** Initial value of the column from where the streaming should start */ -export type Nft_Marketplace_V2_Top_Collections_Token_V2_48h_Stream_Cursor_Value_Input = { - collection_id?: InputMaybe; - price?: InputMaybe; + token_data_id?: InputMaybe; + token_name?: InputMaybe; + token_standard?: InputMaybe; + transaction_timestamp?: InputMaybe; + transaction_version?: InputMaybe; }; /** columns and relationships of "num_active_delegator_per_pool" */ @@ -5461,11 +5967,15 @@ export type Query_Root = { address_version_from_events_aggregate: Address_Version_From_Events_Aggregate; /** fetch data from the table: "address_version_from_move_resources" */ address_version_from_move_resources: Array; + /** fetch aggregated fields from the table: "address_version_from_move_resources" */ + address_version_from_move_resources_aggregate: Address_Version_From_Move_Resources_Aggregate; /** fetch data from the table: "block_metadata_transactions" */ block_metadata_transactions: Array; /** fetch data from the table: "block_metadata_transactions" using primary key columns */ block_metadata_transactions_by_pk?: Maybe; + /** An array relationship */ coin_activities: Array; + /** An aggregate relationship */ coin_activities_aggregate: Coin_Activities_Aggregate; /** fetch data from the table: "coin_activities" using primary key columns */ coin_activities_by_pk?: Maybe; @@ -5513,6 +6023,16 @@ export type Query_Root = { current_delegator_balances: Array; /** fetch data from the table: "current_delegator_balances" using primary key columns */ current_delegator_balances_by_pk?: Maybe; + /** fetch data from the table: "current_fungible_asset_balances" */ + current_fungible_asset_balances: Array; + /** fetch aggregated fields from the table: "current_fungible_asset_balances" */ + current_fungible_asset_balances_aggregate: Current_Fungible_Asset_Balances_Aggregate; + /** fetch data from the table: "current_fungible_asset_balances" using primary key columns */ + current_fungible_asset_balances_by_pk?: Maybe; + /** fetch data from the table: "current_objects" */ + current_objects: Array; + /** fetch data from the table: "current_objects" using primary key columns */ + current_objects_by_pk?: Maybe; /** fetch data from the table: "current_staking_pool_voter" */ current_staking_pool_voter: Array; /** fetch data from the table: "current_staking_pool_voter" using primary key columns */ @@ -5545,6 +6065,7 @@ export type Query_Root = { current_token_pending_claims: Array; /** fetch data from the table: "current_token_pending_claims" using primary key columns */ current_token_pending_claims_by_pk?: Maybe; + /** An array relationship */ delegated_staking_activities: Array; /** fetch data from the table: "delegated_staking_activities" using primary key columns */ delegated_staking_activities_by_pk?: Maybe; @@ -5554,10 +6075,20 @@ export type Query_Root = { delegated_staking_pools_by_pk?: Maybe; /** fetch data from the table: "delegator_distinct_pool" */ delegator_distinct_pool: Array; + /** fetch aggregated fields from the table: "delegator_distinct_pool" */ + delegator_distinct_pool_aggregate: Delegator_Distinct_Pool_Aggregate; /** fetch data from the table: "events" */ events: Array; /** fetch data from the table: "events" using primary key columns */ events_by_pk?: Maybe; + /** fetch data from the table: "fungible_asset_activities" */ + fungible_asset_activities: Array; + /** fetch data from the table: "fungible_asset_activities" using primary key columns */ + fungible_asset_activities_by_pk?: Maybe; + /** fetch data from the table: "fungible_asset_metadata" */ + fungible_asset_metadata: Array; + /** fetch data from the table: "fungible_asset_metadata" using primary key columns */ + fungible_asset_metadata_by_pk?: Maybe; /** fetch data from the table: "indexer_status" */ indexer_status: Array; /** fetch data from the table: "indexer_status" using primary key columns */ @@ -5588,20 +6119,8 @@ export type Query_Root = { nft_marketplace_v2_current_nft_marketplace_token_offers_by_pk?: Maybe; /** fetch data from the table: "nft_marketplace_v2.nft_marketplace_activities" */ nft_marketplace_v2_nft_marketplace_activities: Array; - /** fetch aggregated fields from the table: "nft_marketplace_v2.nft_marketplace_activities" */ - nft_marketplace_v2_nft_marketplace_activities_aggregate: Nft_Marketplace_V2_Nft_Marketplace_Activities_Aggregate; /** fetch data from the table: "nft_marketplace_v2.nft_marketplace_activities" using primary key columns */ nft_marketplace_v2_nft_marketplace_activities_by_pk?: Maybe; - /** fetch data from the table: "nft_marketplace_v2_top_collections" */ - nft_marketplace_v2_top_collections: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v1_24h" */ - nft_marketplace_v2_top_collections_token_v1_24h: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v1_48h" */ - nft_marketplace_v2_top_collections_token_v1_48h: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v2_24h" */ - nft_marketplace_v2_top_collections_token_v2_24h: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v2_48h" */ - nft_marketplace_v2_top_collections_token_v2_48h: Array; /** fetch data from the table: "num_active_delegator_per_pool" */ num_active_delegator_per_pool: Array; /** fetch data from the table: "processor_status" */ @@ -5622,7 +6141,9 @@ export type Query_Root = { table_metadatas: Array; /** fetch data from the table: "table_metadatas" using primary key columns */ table_metadatas_by_pk?: Maybe; + /** An array relationship */ token_activities: Array; + /** An aggregate relationship */ token_activities_aggregate: Token_Activities_Aggregate; /** fetch data from the table: "token_activities" using primary key columns */ token_activities_by_pk?: Maybe; @@ -5711,6 +6232,15 @@ export type Query_RootAddress_Version_From_Move_ResourcesArgs = { }; +export type Query_RootAddress_Version_From_Move_Resources_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + export type Query_RootBlock_Metadata_TransactionsArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -5918,6 +6448,43 @@ export type Query_RootCurrent_Delegator_Balances_By_PkArgs = { }; +export type Query_RootCurrent_Fungible_Asset_BalancesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootCurrent_Fungible_Asset_Balances_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootCurrent_Fungible_Asset_Balances_By_PkArgs = { + storage_id: Scalars['String']; +}; + + +export type Query_RootCurrent_ObjectsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootCurrent_Objects_By_PkArgs = { + object_address: Scalars['String']; +}; + + export type Query_RootCurrent_Staking_Pool_VoterArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6081,6 +6648,15 @@ export type Query_RootDelegator_Distinct_PoolArgs = { }; +export type Query_RootDelegator_Distinct_Pool_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + export type Query_RootEventsArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6097,6 +6673,35 @@ export type Query_RootEvents_By_PkArgs = { }; +export type Query_RootFungible_Asset_ActivitiesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootFungible_Asset_Activities_By_PkArgs = { + event_index: Scalars['bigint']; + transaction_version: Scalars['bigint']; +}; + + +export type Query_RootFungible_Asset_MetadataArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootFungible_Asset_Metadata_By_PkArgs = { + asset_type: Scalars['String']; +}; + + export type Query_RootIndexer_StatusArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6212,66 +6817,12 @@ export type Query_RootNft_Marketplace_V2_Nft_Marketplace_ActivitiesArgs = { }; -export type Query_RootNft_Marketplace_V2_Nft_Marketplace_Activities_AggregateArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - export type Query_RootNft_Marketplace_V2_Nft_Marketplace_Activities_By_PkArgs = { event_index: Scalars['bigint']; transaction_version: Scalars['bigint']; }; -export type Query_RootNft_Marketplace_V2_Top_CollectionsArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootNft_Marketplace_V2_Top_Collections_Token_V1_24hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootNft_Marketplace_V2_Top_Collections_Token_V1_48hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootNft_Marketplace_V2_Top_Collections_Token_V2_24hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootNft_Marketplace_V2_Top_Collections_Token_V2_48hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - export type Query_RootNum_Active_Delegator_Per_PoolArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6482,6 +7033,8 @@ export type Subscription_Root = { address_version_from_events_stream: Array; /** fetch data from the table: "address_version_from_move_resources" */ address_version_from_move_resources: Array; + /** fetch aggregated fields from the table: "address_version_from_move_resources" */ + address_version_from_move_resources_aggregate: Address_Version_From_Move_Resources_Aggregate; /** fetch data from the table in a streaming manner : "address_version_from_move_resources" */ address_version_from_move_resources_stream: Array; /** fetch data from the table: "block_metadata_transactions" */ @@ -6490,7 +7043,9 @@ export type Subscription_Root = { block_metadata_transactions_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "block_metadata_transactions" */ block_metadata_transactions_stream: Array; + /** An array relationship */ coin_activities: Array; + /** An aggregate relationship */ coin_activities_aggregate: Coin_Activities_Aggregate; /** fetch data from the table: "coin_activities" using primary key columns */ coin_activities_by_pk?: Maybe; @@ -6562,6 +7117,20 @@ export type Subscription_Root = { current_delegator_balances_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "current_delegator_balances" */ current_delegator_balances_stream: Array; + /** fetch data from the table: "current_fungible_asset_balances" */ + current_fungible_asset_balances: Array; + /** fetch aggregated fields from the table: "current_fungible_asset_balances" */ + current_fungible_asset_balances_aggregate: Current_Fungible_Asset_Balances_Aggregate; + /** fetch data from the table: "current_fungible_asset_balances" using primary key columns */ + current_fungible_asset_balances_by_pk?: Maybe; + /** fetch data from the table in a streaming manner : "current_fungible_asset_balances" */ + current_fungible_asset_balances_stream: Array; + /** fetch data from the table: "current_objects" */ + current_objects: Array; + /** fetch data from the table: "current_objects" using primary key columns */ + current_objects_by_pk?: Maybe; + /** fetch data from the table in a streaming manner : "current_objects" */ + current_objects_stream: Array; /** fetch data from the table: "current_staking_pool_voter" */ current_staking_pool_voter: Array; /** fetch data from the table: "current_staking_pool_voter" using primary key columns */ @@ -6608,6 +7177,7 @@ export type Subscription_Root = { current_token_pending_claims_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "current_token_pending_claims" */ current_token_pending_claims_stream: Array; + /** An array relationship */ delegated_staking_activities: Array; /** fetch data from the table: "delegated_staking_activities" using primary key columns */ delegated_staking_activities_by_pk?: Maybe; @@ -6621,6 +7191,8 @@ export type Subscription_Root = { delegated_staking_pools_stream: Array; /** fetch data from the table: "delegator_distinct_pool" */ delegator_distinct_pool: Array; + /** fetch aggregated fields from the table: "delegator_distinct_pool" */ + delegator_distinct_pool_aggregate: Delegator_Distinct_Pool_Aggregate; /** fetch data from the table in a streaming manner : "delegator_distinct_pool" */ delegator_distinct_pool_stream: Array; /** fetch data from the table: "events" */ @@ -6629,6 +7201,18 @@ export type Subscription_Root = { events_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "events" */ events_stream: Array; + /** fetch data from the table: "fungible_asset_activities" */ + fungible_asset_activities: Array; + /** fetch data from the table: "fungible_asset_activities" using primary key columns */ + fungible_asset_activities_by_pk?: Maybe; + /** fetch data from the table in a streaming manner : "fungible_asset_activities" */ + fungible_asset_activities_stream: Array; + /** fetch data from the table: "fungible_asset_metadata" */ + fungible_asset_metadata: Array; + /** fetch data from the table: "fungible_asset_metadata" using primary key columns */ + fungible_asset_metadata_by_pk?: Maybe; + /** fetch data from the table in a streaming manner : "fungible_asset_metadata" */ + fungible_asset_metadata_stream: Array; /** fetch data from the table: "indexer_status" */ indexer_status: Array; /** fetch data from the table: "indexer_status" using primary key columns */ @@ -6673,32 +7257,10 @@ export type Subscription_Root = { nft_marketplace_v2_current_nft_marketplace_token_offers_stream: Array; /** fetch data from the table: "nft_marketplace_v2.nft_marketplace_activities" */ nft_marketplace_v2_nft_marketplace_activities: Array; - /** fetch aggregated fields from the table: "nft_marketplace_v2.nft_marketplace_activities" */ - nft_marketplace_v2_nft_marketplace_activities_aggregate: Nft_Marketplace_V2_Nft_Marketplace_Activities_Aggregate; /** fetch data from the table: "nft_marketplace_v2.nft_marketplace_activities" using primary key columns */ nft_marketplace_v2_nft_marketplace_activities_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "nft_marketplace_v2.nft_marketplace_activities" */ nft_marketplace_v2_nft_marketplace_activities_stream: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections" */ - nft_marketplace_v2_top_collections: Array; - /** fetch data from the table in a streaming manner : "nft_marketplace_v2_top_collections" */ - nft_marketplace_v2_top_collections_stream: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v1_24h" */ - nft_marketplace_v2_top_collections_token_v1_24h: Array; - /** fetch data from the table in a streaming manner : "nft_marketplace_v2_top_collections_token_v1_24h" */ - nft_marketplace_v2_top_collections_token_v1_24h_stream: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v1_48h" */ - nft_marketplace_v2_top_collections_token_v1_48h: Array; - /** fetch data from the table in a streaming manner : "nft_marketplace_v2_top_collections_token_v1_48h" */ - nft_marketplace_v2_top_collections_token_v1_48h_stream: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v2_24h" */ - nft_marketplace_v2_top_collections_token_v2_24h: Array; - /** fetch data from the table in a streaming manner : "nft_marketplace_v2_top_collections_token_v2_24h" */ - nft_marketplace_v2_top_collections_token_v2_24h_stream: Array; - /** fetch data from the table: "nft_marketplace_v2_top_collections_token_v2_48h" */ - nft_marketplace_v2_top_collections_token_v2_48h: Array; - /** fetch data from the table in a streaming manner : "nft_marketplace_v2_top_collections_token_v2_48h" */ - nft_marketplace_v2_top_collections_token_v2_48h_stream: Array; /** fetch data from the table: "num_active_delegator_per_pool" */ num_active_delegator_per_pool: Array; /** fetch data from the table in a streaming manner : "num_active_delegator_per_pool" */ @@ -6729,7 +7291,9 @@ export type Subscription_Root = { table_metadatas_by_pk?: Maybe; /** fetch data from the table in a streaming manner : "table_metadatas" */ table_metadatas_stream: Array; + /** An array relationship */ token_activities: Array; + /** An aggregate relationship */ token_activities_aggregate: Token_Activities_Aggregate; /** fetch data from the table: "token_activities" using primary key columns */ token_activities_by_pk?: Maybe; @@ -6851,6 +7415,15 @@ export type Subscription_RootAddress_Version_From_Move_ResourcesArgs = { }; +export type Subscription_RootAddress_Version_From_Move_Resources_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + export type Subscription_RootAddress_Version_From_Move_Resources_StreamArgs = { batch_size: Scalars['Int']; cursor: Array>; @@ -7156,6 +7729,57 @@ export type Subscription_RootCurrent_Delegator_Balances_StreamArgs = { }; +export type Subscription_RootCurrent_Fungible_Asset_BalancesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootCurrent_Fungible_Asset_Balances_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootCurrent_Fungible_Asset_Balances_By_PkArgs = { + storage_id: Scalars['String']; +}; + + +export type Subscription_RootCurrent_Fungible_Asset_Balances_StreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + +export type Subscription_RootCurrent_ObjectsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootCurrent_Objects_By_PkArgs = { + object_address: Scalars['String']; +}; + + +export type Subscription_RootCurrent_Objects_StreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + export type Subscription_RootCurrent_Staking_Pool_VoterArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -7382,6 +8006,15 @@ export type Subscription_RootDelegator_Distinct_PoolArgs = { }; +export type Subscription_RootDelegator_Distinct_Pool_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + export type Subscription_RootDelegator_Distinct_Pool_StreamArgs = { batch_size: Scalars['Int']; cursor: Array>; @@ -7412,6 +8045,49 @@ export type Subscription_RootEvents_StreamArgs = { }; +export type Subscription_RootFungible_Asset_ActivitiesArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootFungible_Asset_Activities_By_PkArgs = { + event_index: Scalars['bigint']; + transaction_version: Scalars['bigint']; +}; + + +export type Subscription_RootFungible_Asset_Activities_StreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + +export type Subscription_RootFungible_Asset_MetadataArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootFungible_Asset_Metadata_By_PkArgs = { + asset_type: Scalars['String']; +}; + + +export type Subscription_RootFungible_Asset_Metadata_StreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + export type Subscription_RootIndexer_StatusArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -7576,15 +8252,6 @@ export type Subscription_RootNft_Marketplace_V2_Nft_Marketplace_ActivitiesArgs = }; -export type Subscription_RootNft_Marketplace_V2_Nft_Marketplace_Activities_AggregateArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - export type Subscription_RootNft_Marketplace_V2_Nft_Marketplace_Activities_By_PkArgs = { event_index: Scalars['bigint']; transaction_version: Scalars['bigint']; @@ -7598,86 +8265,6 @@ export type Subscription_RootNft_Marketplace_V2_Nft_Marketplace_Activities_Strea }; -export type Subscription_RootNft_Marketplace_V2_Top_CollectionsArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_StreamArgs = { - batch_size: Scalars['Int']; - cursor: Array>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V1_24hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V1_24h_StreamArgs = { - batch_size: Scalars['Int']; - cursor: Array>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V1_48hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V1_48h_StreamArgs = { - batch_size: Scalars['Int']; - cursor: Array>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V2_24hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V2_24h_StreamArgs = { - batch_size: Scalars['Int']; - cursor: Array>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V2_48hArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootNft_Marketplace_V2_Top_Collections_Token_V2_48h_StreamArgs = { - batch_size: Scalars['Int']; - cursor: Array>; - where?: InputMaybe; -}; - - export type Subscription_RootNum_Active_Delegator_Per_PoolArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -8525,7 +9112,13 @@ export type Token_Activities_Sum_Order_By = { export type Token_Activities_V2 = { __typename?: 'token_activities_v2'; after_value?: Maybe; + /** An array relationship */ + aptos_names_from: Array; + /** An array relationship */ + aptos_names_to: Array; before_value?: Maybe; + /** An object relationship */ + current_token_data?: Maybe; entry_function_id_str?: Maybe; event_account_address: Scalars['String']; event_index: Scalars['bigint']; @@ -8541,6 +9134,26 @@ export type Token_Activities_V2 = { type: Scalars['String']; }; + +/** columns and relationships of "token_activities_v2" */ +export type Token_Activities_V2Aptos_Names_FromArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +/** columns and relationships of "token_activities_v2" */ +export type Token_Activities_V2Aptos_Names_ToArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + /** aggregated selection of "token_activities_v2" */ export type Token_Activities_V2_Aggregate = { __typename?: 'token_activities_v2_aggregate'; @@ -8609,7 +9222,10 @@ export type Token_Activities_V2_Bool_Exp = { _not?: InputMaybe; _or?: InputMaybe>; after_value?: InputMaybe; + aptos_names_from?: InputMaybe; + aptos_names_to?: InputMaybe; before_value?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; event_account_address?: InputMaybe; event_index?: InputMaybe; @@ -8702,7 +9318,10 @@ export type Token_Activities_V2_Min_Order_By = { /** Ordering options when selecting data from "token_activities_v2". */ export type Token_Activities_V2_Order_By = { after_value?: InputMaybe; + aptos_names_from_aggregate?: InputMaybe; + aptos_names_to_aggregate?: InputMaybe; before_value?: InputMaybe; + current_token_data?: InputMaybe; entry_function_id_str?: InputMaybe; event_account_address?: InputMaybe; event_index?: InputMaybe; diff --git a/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinDataCount.graphql b/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinDataCount.graphql new file mode 100644 index 00000000000000..a81531f24d1311 --- /dev/null +++ b/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinDataCount.graphql @@ -0,0 +1,7 @@ +query getAccountCoinsDataCount($address: String) { + current_fungible_asset_balances_aggregate(where: { owner_address: { _eq: $address } }) { + aggregate { + count + } + } +} diff --git a/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinsData.graphql b/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinsData.graphql index 897cae6ca13671..48fb5b1e6f806a 100644 --- a/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinsData.graphql +++ b/ecosystem/typescript/sdk/src/indexer/queries/getAccountCoinsData.graphql @@ -1,22 +1,32 @@ -query getAccountCoinsData($owner_address: String, $offset: Int, $limit: Int) { - current_coin_balances(where: { owner_address: { _eq: $owner_address } }, offset: $offset, limit: $limit) { +query getAccountCoinsData( + $where_condition: current_fungible_asset_balances_bool_exp! + $offset: Int + $limit: Int + $order_by: [current_fungible_asset_balances_order_by!] +) { + current_fungible_asset_balances(where: $where_condition, offset: $offset, limit: $limit, order_by: $order_by) { amount - coin_type - coin_type_hash + asset_type + is_frozen + is_primary last_transaction_timestamp last_transaction_version owner_address - coin_info { - coin_type - coin_type_hash - creator_address - decimals - name - supply_aggregator_table_handle - supply_aggregator_table_key + storage_id + token_standard + metadata { + token_standard symbol - transaction_created_timestamp - transaction_version_created + supply_aggregator_table_key_v1 + supply_aggregator_table_handle_v1 + project_uri + name + last_transaction_version + last_transaction_timestamp + icon_uri + decimals + creator_address + asset_type } } } diff --git a/ecosystem/typescript/sdk/src/providers/indexer.ts b/ecosystem/typescript/sdk/src/providers/indexer.ts index 533b821a4f40a0..0063397b301698 100644 --- a/ecosystem/typescript/sdk/src/providers/indexer.ts +++ b/ecosystem/typescript/sdk/src/providers/indexer.ts @@ -21,6 +21,7 @@ import { GetCollectionsWithOwnedTokensQuery, GetTokenCurrentOwnerDataQuery, GetOwnedTokensByTokenDataQuery, + GetAccountCoinsDataCountQuery, } from "../indexer/generated/operations"; import { GetAccountTokensCount, @@ -43,6 +44,7 @@ import { GetCollectionsWithOwnedTokens, GetTokenCurrentOwnerData, GetOwnedTokensByTokenData, + GetAccountCoinsDataCount, } from "../indexer/generated/queries"; import { ClientConfig, post } from "../client"; import { ApiError } from "./aptos_client"; @@ -50,6 +52,7 @@ import { Account_Transactions_Order_By, Current_Collections_V2_Order_By, Current_Collection_Ownership_V2_View_Order_By, + Current_Fungible_Asset_Balances_Order_By, Current_Token_Datas_V2_Order_By, Current_Token_Ownerships_V2_Order_By, InputMaybe, @@ -824,14 +827,48 @@ export class IndexerClient { */ async getAccountCoinsData( ownerAddress: MaybeHexString, - options?: IndexerPaginationArgs, + extraArgs?: { + options?: IndexerPaginationArgs; + orderBy?: IndexerSortBy[]; + }, ): Promise { const address = HexString.ensure(ownerAddress).hex(); IndexerClient.validateAddress(address); + + const whereCondition: any = { + owner_address: { _eq: address }, + }; + const graphqlQuery = { query: GetAccountCoinsData, - variables: { owner_address: address, offset: options?.offset, limit: options?.limit }, + variables: { + where_condition: whereCondition, + offset: extraArgs?.options?.offset, + limit: extraArgs?.options?.limit, + order_by: extraArgs?.orderBy, + }, }; + + return this.queryIndexer(graphqlQuery); + } + + /** + * Queries an account coin data count + * + * @param ownerAddress Owner address + * @returns GetAccountCoinsDataCountQuery response type + */ + async getAccountCoinsDataCount(ownerAddress: MaybeHexString): Promise { + const address = HexString.ensure(ownerAddress).hex(); + IndexerClient.validateAddress(address); + + const graphqlQuery = { + query: GetAccountCoinsDataCount, + variables: { + address, + }, + }; + return this.queryIndexer(graphqlQuery); } } diff --git a/ecosystem/typescript/sdk/src/tests/e2e/indexer.test.ts b/ecosystem/typescript/sdk/src/tests/e2e/indexer.test.ts index 6055be752d528a..d67eae3eb12f99 100644 --- a/ecosystem/typescript/sdk/src/tests/e2e/indexer.test.ts +++ b/ecosystem/typescript/sdk/src/tests/e2e/indexer.test.ts @@ -359,7 +359,16 @@ describe("Indexer", () => { "gets account coin data", async () => { const accountCoinData = await indexerClient.getAccountCoinsData(alice.address().hex()); - expect(accountCoinData.current_coin_balances[0].coin_type).toEqual("0x1::aptos_coin::AptosCoin"); + expect(accountCoinData.current_fungible_asset_balances[0].asset_type).toEqual("0x1::aptos_coin::AptosCoin"); + }, + longTestTimeout, + ); + + it( + "gets account coin data count", + async () => { + const accountCoinDataCount = await indexerClient.getAccountCoinsDataCount(alice.address().hex()); + expect(accountCoinDataCount.current_fungible_asset_balances_aggregate.aggregate?.count).toEqual(1); }, longTestTimeout, );