diff --git a/apps/trading/client-pages/liquidity/liquidity.tsx b/apps/trading/client-pages/liquidity/liquidity.tsx index 70ee0fff7..4bd75fc4b 100644 --- a/apps/trading/client-pages/liquidity/liquidity.tsx +++ b/apps/trading/client-pages/liquidity/liquidity.tsx @@ -69,10 +69,7 @@ export const Liquidity = () => { } = useDataProvider({ dataProvider: lpAggregatedDataProvider, update, - variables: useMemo( - () => ({ marketId, partyId: pubKey }), - [marketId, pubKey] - ), + variables: useMemo(() => ({ marketId }), [marketId]), }); // To be removed when liquidityProvision subscriptions are working diff --git a/libs/accounts/src/lib/Accounts.graphql b/libs/accounts/src/lib/Accounts.graphql index b9776b2fd..ca7bb9ba3 100644 --- a/libs/accounts/src/lib/Accounts.graphql +++ b/libs/accounts/src/lib/Accounts.graphql @@ -7,6 +7,9 @@ fragment AccountFields on AccountBalance { asset { id } + party { + id + } } query Accounts($partyId: ID!) { @@ -22,11 +25,12 @@ query Accounts($partyId: ID!) { } } -subscription AccountEvents($partyId: ID!) { +subscription AccountEvents($partyId: ID) { accounts(partyId: $partyId) { type balance assetId marketId + partyId } } diff --git a/libs/accounts/src/lib/__generated__/Accounts.ts b/libs/accounts/src/lib/__generated__/Accounts.ts index d55b3ed96..dad027a18 100644 --- a/libs/accounts/src/lib/__generated__/Accounts.ts +++ b/libs/accounts/src/lib/__generated__/Accounts.ts @@ -3,21 +3,21 @@ import { Schema as Types } from '@vegaprotocol/types'; import { gql } from '@apollo/client'; import * as Apollo from '@apollo/client'; const defaultOptions = {} as const; -export type AccountFieldsFragment = { __typename?: 'AccountBalance', type: Types.AccountType, balance: string, market?: { __typename?: 'Market', id: string } | null, asset: { __typename?: 'Asset', id: string } }; +export type AccountFieldsFragment = { __typename?: 'AccountBalance', type: Types.AccountType, balance: string, market?: { __typename?: 'Market', id: string } | null, asset: { __typename?: 'Asset', id: string }, party?: { __typename?: 'Party', id: string } | null }; export type AccountsQueryVariables = Types.Exact<{ partyId: Types.Scalars['ID']; }>; -export type AccountsQuery = { __typename?: 'Query', party?: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string, market?: { __typename?: 'Market', id: string } | null, asset: { __typename?: 'Asset', id: string } } } | null> | null } | null } | null }; +export type AccountsQuery = { __typename?: 'Query', party?: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string, market?: { __typename?: 'Market', id: string } | null, asset: { __typename?: 'Asset', id: string }, party?: { __typename?: 'Party', id: string } | null } } | null> | null } | null } | null }; export type AccountEventsSubscriptionVariables = Types.Exact<{ - partyId: Types.Scalars['ID']; + partyId?: Types.InputMaybe; }>; -export type AccountEventsSubscription = { __typename?: 'Subscription', accounts: Array<{ __typename?: 'AccountUpdate', type: Types.AccountType, balance: string, assetId: string, marketId?: string | null }> }; +export type AccountEventsSubscription = { __typename?: 'Subscription', accounts: Array<{ __typename?: 'AccountUpdate', type: Types.AccountType, balance: string, assetId: string, marketId?: string | null, partyId: string }> }; export const AccountFieldsFragmentDoc = gql` fragment AccountFields on AccountBalance { @@ -29,6 +29,9 @@ export const AccountFieldsFragmentDoc = gql` asset { id } + party { + id + } } `; export const AccountsDocument = gql` @@ -74,12 +77,13 @@ export type AccountsQueryHookResult = ReturnType; export type AccountsLazyQueryHookResult = ReturnType; export type AccountsQueryResult = Apollo.QueryResult; export const AccountEventsDocument = gql` - subscription AccountEvents($partyId: ID!) { + subscription AccountEvents($partyId: ID) { accounts(partyId: $partyId) { type balance assetId marketId + partyId } } `; @@ -100,7 +104,7 @@ export const AccountEventsDocument = gql` * }, * }); */ -export function useAccountEventsSubscription(baseOptions: Apollo.SubscriptionHookOptions) { +export function useAccountEventsSubscription(baseOptions?: Apollo.SubscriptionHookOptions) { const options = {...defaultOptions, ...baseOptions} return Apollo.useSubscription(AccountEventsDocument, options); } diff --git a/libs/accounts/src/lib/accounts-data-provider.spec.ts b/libs/accounts/src/lib/accounts-data-provider.spec.ts index 7f25d2e4a..5c34b3259 100644 --- a/libs/accounts/src/lib/accounts-data-provider.spec.ts +++ b/libs/accounts/src/lib/accounts-data-provider.spec.ts @@ -26,6 +26,7 @@ describe('getId', () => { balance: '1', assetId: 'assetId', marketId: '', + partyId: 'partyId', }) ); expect( @@ -41,6 +42,7 @@ describe('getId', () => { balance: '1', assetId: 'assetId', marketId: 'testId', + partyId: 'partyId', }) ); }); diff --git a/libs/liquidity/src/lib/__generated__/MarketLiquidity.ts b/libs/liquidity/src/lib/__generated__/MarketLiquidity.ts index 4717d9fae..9c8600e07 100644 --- a/libs/liquidity/src/lib/__generated__/MarketLiquidity.ts +++ b/libs/liquidity/src/lib/__generated__/MarketLiquidity.ts @@ -10,14 +10,14 @@ export type MarketLpQueryVariables = Types.Exact<{ export type MarketLpQuery = { __typename?: 'Query', market?: { __typename?: 'Market', id: string, decimalPlaces: number, positionDecimalPlaces: number, tradableInstrument: { __typename?: 'TradableInstrument', instrument: { __typename?: 'Instrument', code: string, name: string, product: { __typename?: 'Future', settlementAsset: { __typename?: 'Asset', id: string, symbol: string, decimals: number } } } }, data?: { __typename?: 'MarketData', marketTradingMode: Types.MarketTradingMode, suppliedStake?: string | null, openInterest: string, targetStake?: string | null, trigger: Types.AuctionTrigger, marketValueProxy: string, market: { __typename?: 'Market', id: string } } | null } | null }; -export type LiquidityProvisionFieldsFragment = { __typename?: 'LiquidityProvision', createdAt: string, updatedAt?: string | null, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus, party: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string } } | null> | null } | null } }; +export type LiquidityProvisionFieldsFragment = { __typename?: 'LiquidityProvision', createdAt: any, updatedAt?: any | null, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus, party: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string } } | null> | null } | null } }; export type LiquidityProvisionsQueryVariables = Types.Exact<{ marketId: Types.Scalars['ID']; }>; -export type LiquidityProvisionsQuery = { __typename?: 'Query', market?: { __typename?: 'Market', liquidityProvisionsConnection?: { __typename?: 'LiquidityProvisionsConnection', edges?: Array<{ __typename?: 'LiquidityProvisionsEdge', node: { __typename?: 'LiquidityProvision', createdAt: string, updatedAt?: string | null, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus, party: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string } } | null> | null } | null } } } | null> | null } | null } | null }; +export type LiquidityProvisionsQuery = { __typename?: 'Query', market?: { __typename?: 'Market', liquidityProvisionsConnection?: { __typename?: 'LiquidityProvisionsConnection', edges?: Array<{ __typename?: 'LiquidityProvisionsEdge', node: { __typename?: 'LiquidityProvision', createdAt: any, updatedAt?: any | null, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus, party: { __typename?: 'Party', id: string, accountsConnection?: { __typename?: 'AccountsConnection', edges?: Array<{ __typename?: 'AccountEdge', node: { __typename?: 'AccountBalance', type: Types.AccountType, balance: string } } | null> | null } | null } } } | null> | null } | null } | null }; export type LiquidityProvisionsUpdateSubscriptionVariables = Types.Exact<{ partyId?: Types.InputMaybe; @@ -25,7 +25,7 @@ export type LiquidityProvisionsUpdateSubscriptionVariables = Types.Exact<{ }>; -export type LiquidityProvisionsUpdateSubscription = { __typename?: 'Subscription', liquidityProvisions?: Array<{ __typename?: 'LiquidityProvisionUpdate', id?: string | null, partyID: string, createdAt: string, updatedAt?: string | null, marketID: string, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus }> | null }; +export type LiquidityProvisionsUpdateSubscription = { __typename?: 'Subscription', liquidityProvisions?: Array<{ __typename?: 'LiquidityProvisionUpdate', id?: string | null, partyID: string, createdAt: any, updatedAt?: any | null, marketID: string, commitmentAmount: string, fee: string, status: Types.LiquidityProvisionStatus }> | null }; export type LiquidityProviderFeeShareFieldsFragment = { __typename?: 'LiquidityProviderFeeShare', equityLikeShare: string, averageEntryValuation: string, party: { __typename?: 'Party', id: string } }; diff --git a/libs/liquidity/src/lib/liquidity-data-provider.ts b/libs/liquidity/src/lib/liquidity-data-provider.ts index 0dce0a377..3dcc240b0 100644 --- a/libs/liquidity/src/lib/liquidity-data-provider.ts +++ b/libs/liquidity/src/lib/liquidity-data-provider.ts @@ -189,6 +189,11 @@ export const getLiquidityProvision = ( const market = marketLiquidity?.market; const feeShare = liquidityFeeShare.find((f) => f.party.id === lp.party.id); if (!feeShare) return lp; + const bondAccounts = accounts?.filter( + (a) => + a?.type === Schema.AccountType.ACCOUNT_TYPE_BOND && + (!a.party?.id || a.party?.id === lp.party.id) + ); const lpData: LiquidityProvisionData = { ...lp, averageEntryValuation: feeShare?.averageEntryValuation, @@ -196,8 +201,7 @@ export const getLiquidityProvision = ( assetDecimalPlaces: market?.tradableInstrument.instrument.product.settlementAsset.decimals, balance: - accounts - ?.filter((a) => a?.type === Schema.AccountType.ACCOUNT_TYPE_BOND) + bondAccounts ?.reduce( (acc, a) => acc.plus(new BigNumber(a.balance ?? 0)), new BigNumber(0) diff --git a/libs/types/src/__generated__/types.ts b/libs/types/src/__generated__/types.ts index 64830953e..2fb6554a8 100644 --- a/libs/types/src/__generated__/types.ts +++ b/libs/types/src/__generated__/types.ts @@ -133,6 +133,8 @@ export type AccountUpdate = { balance: Scalars['String']; /** Market id (only relevant to margin accounts) */ marketId?: Maybe; + /** The party owning the account */ + partyId: Scalars['ID']; /** Account type (General, Margin, etc) */ type: AccountType; }; @@ -177,19 +179,25 @@ export type AggregatedBalanceEdge = { export type AggregatedLedgerEntries = { __typename?: 'AggregatedLedgerEntries'; - /** Account type, if query was grouped by account type - else null */ - accountType?: Maybe; /** Asset identifier, if query was grouped by asset - else null */ assetId?: Maybe; - /** Market identifier, if query was grouped by market - else null */ - marketId?: Maybe; - /** Party identifier, if query was grouped by party - else null */ - partyId?: Maybe; /** Net amount of ledger entries for the accounts specified in the filter at this time */ quantity: Scalars['String']; + /** Account type, if query was grouped by receiver account type - else null */ + receiverAccountType?: Maybe; + /** Market identifier, if query was grouped by receiver market - else null */ + receiverMarketId?: Maybe; + /** Party identifier, if query was grouped by receiver party - else null */ + receiverPartyId?: Maybe; + /** Account type, if query was grouped by sender account type - else null */ + senderAccountType?: Maybe; + /** Market identifier, if query was grouped by sender market - else null */ + senderMarketId?: Maybe; + /** Party identifier, if query was grouped by sender party - else null */ + senderPartyId?: Maybe; transferType?: Maybe; /** RFC3339Nano time from at which this ledger entries records were relevant */ - vegaTime: Scalars['String']; + vegaTime: Scalars['Timestamp']; }; export type AggregatedLedgerEntriesConnection = { @@ -287,9 +295,9 @@ export type AuctionDuration = { export type AuctionEvent = { __typename?: 'AuctionEvent'; /** RFC3339Nano optional end time of auction */ - auctionEnd: Scalars['String']; + auctionEnd: Scalars['Timestamp']; /** RFC3339Nano start time of auction */ - auctionStart: Scalars['String']; + auctionStart: Scalars['Timestamp']; /** What, if anything, extended the ongoing auction */ extensionTrigger?: Maybe; /** Event fired because of auction end */ @@ -399,13 +407,13 @@ export type Candle = { /** High price (uint64) */ high: Scalars['String']; /** RFC3339Nano formatted date and time for the candle end time, or last updated time if the candle is still open */ - lastUpdateInPeriod: Scalars['String']; + lastUpdateInPeriod: Scalars['Timestamp']; /** Low price (uint64) */ low: Scalars['String']; /** Open price (uint64) */ open: Scalars['String']; /** RFC3339Nano formatted date and time for the candle start time */ - periodStart: Scalars['String']; + periodStart: Scalars['Timestamp']; /** Volume price (uint64) */ volume: Scalars['String']; }; @@ -472,7 +480,7 @@ export type Data = { * with a matching data spec. * It has no value when the source data does not match any data spec. */ - broadcastAt: Scalars['String']; + broadcastAt: Scalars['Timestamp']; /** properties contains all the properties sent by a data source */ data?: Maybe>; /** @@ -521,14 +529,14 @@ export type DataSourceKind = DataSourceDefinitionExternal | DataSourceDefinition export type DataSourceSpec = { __typename?: 'DataSourceSpec'; /** RFC3339Nano creation date time */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; data: DataSourceDefinition; /** ID is a hash generated from the DataSourceSpec data. */ id: Scalars['ID']; /** Status describes the status of the data source spec */ status: DataSourceSpecStatus; /** RFC3339Nano last updated timestamp */ - updatedAt?: Maybe; + updatedAt?: Maybe; }; /** @@ -628,9 +636,9 @@ export type Deposit = { /** The asset to be withdrawn */ asset: Asset; /** RFC3339Nano time at which the deposit was created */ - createdTimestamp: Scalars['String']; + createdTimestamp: Scalars['Timestamp']; /** RFC3339Nano time at which the deposit was finalised */ - creditedTimestamp?: Maybe; + creditedTimestamp?: Maybe; /** The Vega internal ID of the deposit */ id: Scalars['ID']; /** The Party initiating the deposit */ @@ -805,37 +813,17 @@ export type ETHAddress = { /** Epoch describes a specific period of time in the Vega network */ export type Epoch = { __typename?: 'Epoch'; - /** - * Delegations data for this epoch - * @deprecated Use delegationsConnection instead - */ - delegations: Array; /** Delegations data for this epoch */ delegationsConnection?: Maybe; /** Numeric sequence number used to identify the epoch */ id: Scalars['ID']; /** Timestamps for start and end of epochs */ timestamps: EpochTimestamps; - /** - * Validators that participated in this epoch - * @deprecated Use validatorsConnection instead - */ - validators: Array; /** Validators that participated in this epoch */ validatorsConnection?: Maybe; }; -/** Epoch describes a specific period of time in the Vega network */ -export type EpochdelegationsArgs = { - first?: InputMaybe; - last?: InputMaybe; - nodeId?: InputMaybe; - partyId?: InputMaybe; - skip?: InputMaybe; -}; - - /** Epoch describes a specific period of time in the Vega network */ export type EpochdelegationsConnectionArgs = { nodeId?: InputMaybe; @@ -865,9 +853,9 @@ export type EpochParticipation = { __typename?: 'EpochParticipation'; epoch?: Maybe; /** RFC3339 timestamp */ - offline?: Maybe; + offline?: Maybe; /** RFC3339 timestamp */ - online?: Maybe; + online?: Maybe; /** Total amount rewarded for participation in the given epoch */ totalRewards?: Maybe; }; @@ -876,11 +864,11 @@ export type EpochParticipation = { export type EpochTimestamps = { __typename?: 'EpochTimestamps'; /** RFC3339 timestamp - Vega time of epoch end, null if not ended */ - end?: Maybe; + end?: Maybe; /** RFC3339 timestamp - Vega time of epoch expiry */ - expiry?: Maybe; + expiry?: Maybe; /** RFC3339 timestamp - Vega time of epoch start, null if not started */ - start?: Maybe; + start?: Maybe; }; /** Response for the signature bundle to allowlist an ERC20 token in the collateral bridge */ @@ -909,7 +897,7 @@ export type Erc20WithdrawalApproval = { /** Timestamp at which the withdrawal was created */ creation: Scalars['String']; /** Timestamp in seconds for expiry of the approval */ - expiry: Scalars['String']; + expiry: Scalars['Timestamp']; /** The nonce to be used in the request */ nonce: Scalars['String']; /** @@ -954,7 +942,7 @@ export type EthereumKeyRotation = { export type EthereumKeyRotationEdge = { __typename?: 'EthereumKeyRotationEdge'; cursor?: Maybe; - ethereumKeyRotation: EthereumKeyRotation; + node: EthereumKeyRotation; }; /** A paginated type for returning Ethereum key rotation records */ @@ -1054,11 +1042,6 @@ export type FutureProduct = { settlementDataDecimals: Scalars['Int']; }; -export type GroupOptions = { - ByAccountField?: InputMaybe>>; - ByLedgerEntryField?: InputMaybe>>; -}; - /** A segment of datanode history */ export type HistorySegment = { __typename?: 'HistorySegment'; @@ -1162,7 +1145,7 @@ export type LedgerEntry = { /** The amount transferred */ amount: Scalars['String']; /** RFC3339Nano time at which the transfer was made */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; /** Type of ledger entry */ type: Scalars['String']; }; @@ -1173,9 +1156,9 @@ export enum LedgerEntryField { /** Filter for historical entry ledger queries */ export type LedgerEntryFilter = { - AccountFromFilter?: InputMaybe; - AccountToFilter?: InputMaybe; CloseOnAccountFilters?: InputMaybe; + ReceiverAccountFilter?: InputMaybe; + SenderAccountFilter?: InputMaybe; TransferTypes?: InputMaybe>>; }; @@ -1226,7 +1209,7 @@ export type LiquidityProvision = { /** Specified as a unit-less number that represents the amount of settlement asset of the market. */ commitmentAmount: Scalars['String']; /** When the liquidity provision was initially created (formatted RFC3339) */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** Nominated liquidity fee factor, which is an input to the calculation of liquidity fees on the market, as per setting fees and rewarding liquidity providers. */ fee: Scalars['String']; /** Unique identifier for the order (set by the system after consensus) */ @@ -1242,7 +1225,7 @@ export type LiquidityProvision = { /** The current status of this liquidity provision */ status: LiquidityProvisionStatus; /** RFC3339Nano time of when the liquidity provision was updated */ - updatedAt?: Maybe; + updatedAt?: Maybe; /** The version of this liquidity provision */ version: Scalars['String']; }; @@ -1275,7 +1258,7 @@ export type LiquidityProvisionUpdate = { /** Specified as a unit-less number that represents the amount of settlement asset of the market. */ commitmentAmount: Scalars['String']; /** When the liquidity provision was initially created (formatted RFC3339) */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** Nominated liquidity fee factor, which is an input to the calculation of liquidity fees on the market, as per setting fees and rewarding liquidity providers. */ fee: Scalars['String']; /** Unique identifier for the order (set by the system after consensus) */ @@ -1291,7 +1274,7 @@ export type LiquidityProvisionUpdate = { /** The current status of this liquidity provision */ status: LiquidityProvisionStatus; /** RFC3339Nano time of when the liquidity provision was updated */ - updatedAt?: Maybe; + updatedAt?: Maybe; /** The version of this liquidity provision */ version: Scalars['String']; }; @@ -1385,7 +1368,7 @@ export type MarginLevels = { /** If the margin is between maintenance and search, the network will initiate a collateral search (unsigned integer) */ searchLevel: Scalars['String']; /** RFC3339Nano time from at which this margin level was relevant */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; }; /** Margins for a given a party */ @@ -1409,17 +1392,12 @@ export type MarginLevelsUpdate = { /** If the margin is between maintenance and search, the network will initiate a collateral search (unsigned integer) */ searchLevel: Scalars['String']; /** RFC3339Nano time from at which this margin level was relevant */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; }; /** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ export type Market = { __typename?: 'Market'; - /** - * Get account for a party or market - * @deprecated Use the accountsConnection instead - */ - accounts?: Maybe>; /** Get account for a party or market */ accountsConnection?: Maybe; /** Candles on a market, for the 'last' n candles, at 'interval' seconds as specified by parameters using cursor based pagination */ @@ -1451,11 +1429,6 @@ export type Market = { id: Scalars['ID']; /** Liquidity monitoring parameters for the market */ liquidityMonitoringParameters: LiquidityMonitoringParameters; - /** - * The list of the liquidity provision commitments for this market - * @deprecated Use liquidityProvisionsConnection instead - */ - liquidityProvisions?: Maybe>; /** The list of the liquidity provision commitments for this market */ liquidityProvisionsConnection?: Maybe; /** Timestamps for state changes in the market */ @@ -1465,11 +1438,6 @@ export type Market = { * duration and optionally a minimum traded volume). */ openingAuction: AuctionDuration; - /** - * Orders on a market - * @deprecated Use the 'ordersConnection' field instead - */ - orders?: Maybe>; /** Orders on a market */ ordersConnection?: Maybe; /** @@ -1489,23 +1457,12 @@ export type Market = { state: MarketState; /** An instance of, or reference to, a tradable instrument. */ tradableInstrument: TradableInstrument; - /** - * Trades on a market - * @deprecated Use tradesConnection for cursor based pagination instead - */ - trades?: Maybe>; tradesConnection?: Maybe; /** Current mode of execution of the market */ tradingMode: MarketTradingMode; }; -/** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ -export type MarketaccountsArgs = { - partyId?: InputMaybe; -}; - - /** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ export type MarketaccountsConnectionArgs = { pagination?: InputMaybe; @@ -1528,12 +1485,6 @@ export type MarketdepthArgs = { }; -/** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ -export type MarketliquidityProvisionsArgs = { - partyId?: InputMaybe; -}; - - /** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ export type MarketliquidityProvisionsConnectionArgs = { pagination?: InputMaybe; @@ -1541,14 +1492,6 @@ export type MarketliquidityProvisionsConnectionArgs = { }; -/** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ -export type MarketordersArgs = { - first?: InputMaybe; - last?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ export type MarketordersConnectionArgs = { dateRange?: InputMaybe; @@ -1556,14 +1499,6 @@ export type MarketordersConnectionArgs = { }; -/** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ -export type MarkettradesArgs = { - first?: InputMaybe; - last?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a product & associated parameters that can be traded on Vega, has an associated OrderBook and Trade history */ export type MarkettradesConnectionArgs = { dateRange?: InputMaybe; @@ -1624,6 +1559,8 @@ export type MarketData = { marketValueProxy: Scalars['String']; /** The arithmetic average of the best bid price and best offer price. */ midPrice: Scalars['String']; + /** RFC3339Nano time indicating the next time positions will be marked to market */ + nextMarkToMarket: Scalars['String']; /** The sum of the size of all positions greater than 0. */ openInterest: Scalars['String']; /** A list of valid price ranges per associated trigger */ @@ -1635,7 +1572,7 @@ export type MarketData = { /** The amount of stake targeted for this market */ targetStake?: Maybe; /** RFC3339Nano time at which this market price was relevant */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; /** What triggered an auction (if an auction was started) */ trigger: AuctionTrigger; }; @@ -1768,13 +1705,13 @@ export type MarketTick = { export type MarketTimestamps = { __typename?: 'MarketTimestamps'; /** Time when the market is closed */ - close?: Maybe; + close?: Maybe; /** Time when the market is open and ready to accept trades */ - open?: Maybe; + open?: Maybe; /** Time when the market has been voted in and waiting to be created */ - pending?: Maybe; + pending?: Maybe; /** Time when the market is first proposed */ - proposed?: Maybe; + proposed?: Maybe; }; /** What market trading mode is the market in */ @@ -1882,11 +1819,6 @@ export type NewMarket = { export type Node = { __typename?: 'Node'; avatarUrl?: Maybe; - /** - * All delegation for a node by a given party if specified, or all delegations. - * @deprecated Use delegationsConnection instead - */ - delegations?: Maybe>; /** All delegation for a node by a given party if specified, or all delegations. */ delegationsConnection?: Maybe; /** Summary of epoch data across all nodes */ @@ -1921,15 +1853,6 @@ export type Node = { }; -/** Information available for a node */ -export type NodedelegationsArgs = { - first?: InputMaybe; - last?: InputMaybe; - partyId?: InputMaybe; - skip?: InputMaybe; -}; - - /** Information available for a node */ export type NodedelegationsConnectionArgs = { pagination?: InputMaybe; @@ -1939,11 +1862,17 @@ export type NodedelegationsConnectionArgs = { /** Summary of data across all nodes */ export type NodeData = { __typename?: 'NodeData'; - /** Number of inactive nodes */ + /** Details on the set of ersatz (standby) nodes in the network */ + ersatzNodes?: Maybe; + /** Total number of nodes that had a performance score of 0 at the end of the last epoch */ inactiveNodes: Scalars['Int']; + /** Details on the set of pending nodes in the network */ + pendingNodes?: Maybe; /** Total staked amount across all nodes */ stakedTotal: Scalars['String']; - /** Total number of nodes */ + /** Details on the set of consensus nodes in the network */ + tendermintNodes: NodeSet; + /** Total number of nodes across all node sets */ totalNodes: Scalars['Int']; /** Total uptime for all epochs across all nodes. Or specify a number of epochs */ uptime: Scalars['Float']; @@ -1958,6 +1887,21 @@ export type NodeEdge = { node: Node; }; +/** Details on the collection of nodes for particular validator status */ +export type NodeSet = { + __typename?: 'NodeSet'; + /** IDs of the nodes that were demoted into this node set at the start of the epoch */ + demoted?: Maybe>; + /** Number of nodes in the node set that had a performance score of 0 at the end of the last epoch */ + inactive: Scalars['Int']; + /** Total number of nodes allowed in the node set */ + maximum?: Maybe; + /** IDs of the nodes that were promoted into this node set at the start of the epoch */ + promoted?: Maybe>; + /** Total number of nodes in the node set */ + total: Scalars['Int']; +}; + /** Represents a signature for the approval of a resource from a validator */ export type NodeSignature = { __typename?: 'NodeSignature'; @@ -2072,6 +2016,8 @@ export type ObservableMarketData = { marketValueProxy: Scalars['String']; /** The arithmetic average of the best bid price and best offer price */ midPrice: Scalars['String']; + /** RFC3339Nano time indicating the next time positions will be marked to market */ + nextMarkToMarket: Scalars['String']; /** The sum of the size of all positions greater than 0 */ openInterest: Scalars['String']; /** A list of valid price ranges per associated trigger */ @@ -2083,7 +2029,7 @@ export type ObservableMarketData = { /** The amount of stake targeted for this market */ targetStake?: Maybe; /** RFC3339Nano time at which this market price was relevant */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; /** What triggered an auction (if an auction was started) */ trigger: AuctionTrigger; }; @@ -2140,7 +2086,7 @@ export type OffsetPagination = { export type OneOffTransfer = { __typename?: 'OneOffTransfer'; /** An optional time when the transfer should be delivered */ - deliverOn?: Maybe; + deliverOn?: Maybe; }; export type Oracle = EthereumEvent; @@ -2197,9 +2143,9 @@ export type OracleSpecsConnection = { export type Order = { __typename?: 'Order'; /** RFC3339Nano formatted date and time for when the order was created (timestamp) */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** Expiration time of this order (ISO-8601 RFC3339+Nano formatted date) */ - expiresAt?: Maybe; + expiresAt?: Maybe; /** Hash of the order data */ id: Scalars['ID']; /** The liquidity provision this order was created from */ @@ -2226,17 +2172,12 @@ export type Order = { status: OrderStatus; /** The timeInForce of order (determines how and if it executes, and whether it persists on the book) */ timeInForce: OrderTimeInForce; - /** - * Trades relating to this order - * @deprecated Use tradesConnection instead - */ - trades?: Maybe>; /** Trades relating to this order */ tradesConnection?: Maybe; /** The order type */ type?: Maybe; /** RFC3339Nano time the order was altered */ - updatedAt?: Maybe; + updatedAt?: Maybe; /** Version of this order, counts the number of amends */ version: Scalars['String']; }; @@ -2427,9 +2368,9 @@ export enum OrderType { export type OrderUpdate = { __typename?: 'OrderUpdate'; /** RFC3339Nano formatted date and time for when the order was created (timestamp) */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** Expiration time of this order (ISO-8601 RFC3339+Nano formatted date) */ - expiresAt?: Maybe; + expiresAt?: Maybe; /** Hash of the order data */ id: Scalars['ID']; /** The liquidity provision this order was created from */ @@ -2459,7 +2400,7 @@ export type OrderUpdate = { /** The order type */ type?: Maybe; /** RFC3339Nano time the order was altered */ - updatedAt?: Maybe; + updatedAt?: Maybe; /** Version of this order, counts the number of amends */ version: Scalars['String']; }; @@ -2492,108 +2433,39 @@ export type Pagination = { /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type Party = { __typename?: 'Party'; - /** - * Collateral accounts relating to a party - * @deprecated Use accountsConnection instead - */ - accounts?: Maybe>; /** Collateral accounts relating to a party */ accountsConnection?: Maybe; - /** @deprecated Use delegationsConnection instead */ - delegations?: Maybe>; delegationsConnection?: Maybe; - /** - * The list of all deposits for a party by the party - * @deprecated Use depositsConnection instead - */ - deposits?: Maybe>; /** The list of all deposits for a party by the party */ depositsConnection?: Maybe; /** Party identifier */ id: Scalars['ID']; - /** - * The list of the liquidity provision commitment from this party - * @deprecated Use liquidityProvisionsConnection instead - */ - liquidityProvisions?: Maybe>; /** The list of the liquidity provision commitment for this party */ liquidityProvisionsConnection?: Maybe; - /** - * Margin Levels - * @deprecated Use marginsConnection instead - */ - margins?: Maybe>; /** Margin levels for a market */ marginsConnection?: Maybe; - /** - * Orders relating to a party - * @deprecated Use ordersConnection instead - */ - orders?: Maybe>; /** Orders relating to a party */ ordersConnection?: Maybe; - /** - * Trading positions relating to a party - * @deprecated Use the 'positionsConnection' field instead - */ - positions?: Maybe>; /** Trading positions relating to a party */ positionsConnection?: Maybe; - /** @deprecated Use proposalsConnection instead */ - proposals?: Maybe>>; /** All governance proposals in the Vega network */ proposalsConnection?: Maybe; - /** - * Return reward information - * @deprecated Use rewardSummaries or rewards instead. - */ - rewardDetails?: Maybe>>; /** Return net reward information */ rewardSummaries?: Maybe>>; - /** - * Return individual reward information - * @deprecated Use rewardsConnection instead - */ - rewards?: Maybe>>; /** Rewards information for the party */ rewardsConnection?: Maybe; - /** - * The staking information for this Party - * @deprecated Use stakingSummary instead - */ - stake: PartyStake; /** The staking information for this Party */ stakingSummary: StakingSummary; - /** - * Trades relating to a party (specifically where party is either buyer OR seller) - * @deprecated Use tradesConnection for cursor based pagination instead - */ - trades?: Maybe>; tradesConnection?: Maybe; /** All transfers for a public key */ transfersConnection?: Maybe; - /** @deprecated Use votesConnection instead */ - votes?: Maybe>>; /** All votes on proposals in the Vega network by the given party */ votesConnection?: Maybe; - /** - * The list of all withdrawals initiated by the party - * @deprecated Use withdrawalsConnection instead - */ - withdrawals?: Maybe>; /** The list of all withdrawals initiated by the party */ withdrawalsConnection?: Maybe; }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartyaccountsArgs = { - assetId?: InputMaybe; - marketId?: InputMaybe; - type?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartyaccountsConnectionArgs = { assetId?: InputMaybe; @@ -2603,15 +2475,6 @@ export type PartyaccountsConnectionArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartydelegationsArgs = { - first?: InputMaybe; - last?: InputMaybe; - nodeId?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartydelegationsConnectionArgs = { nodeId?: InputMaybe; @@ -2626,13 +2489,6 @@ export type PartydepositsConnectionArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartyliquidityProvisionsArgs = { - market?: InputMaybe; - reference?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartyliquidityProvisionsConnectionArgs = { marketId?: InputMaybe; @@ -2641,12 +2497,6 @@ export type PartyliquidityProvisionsConnectionArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartymarginsArgs = { - marketId?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartymarginsConnectionArgs = { marketId?: InputMaybe; @@ -2654,14 +2504,6 @@ export type PartymarginsConnectionArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartyordersArgs = { - first?: InputMaybe; - last?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartyordersConnectionArgs = { dateRange?: InputMaybe; @@ -2676,12 +2518,6 @@ export type PartypositionsConnectionArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartyproposalsArgs = { - inState?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartyproposalsConnectionArgs = { inState?: InputMaybe; @@ -2696,15 +2532,6 @@ export type PartyrewardSummariesArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartyrewardsArgs = { - assetId?: InputMaybe; - first?: InputMaybe; - last?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartyrewardsConnectionArgs = { assetId?: InputMaybe; @@ -2718,15 +2545,6 @@ export type PartystakingSummaryArgs = { }; -/** Represents a party on Vega, could be an ethereum wallet address in the future */ -export type PartytradesArgs = { - first?: InputMaybe; - last?: InputMaybe; - marketId?: InputMaybe; - skip?: InputMaybe; -}; - - /** Represents a party on Vega, could be an ethereum wallet address in the future */ export type PartytradesConnectionArgs = { dataRange?: InputMaybe; @@ -2814,11 +2632,6 @@ export type Position = { __typename?: 'Position'; /** Average entry price for this position */ averageEntryPrice: Scalars['String']; - /** - * Margins of the party for the given position - * @deprecated Use marginsConnection instead - */ - margins?: Maybe>; /** Margins of the party for the given position */ marginsConnection?: Maybe; /** Market relating to this position */ @@ -2832,7 +2645,7 @@ export type Position = { /** Unrealised Profit and Loss (int64) */ unrealisedPNL: Scalars['String']; /** RFC3339Nano time the position was updated */ - updatedAt?: Maybe; + updatedAt?: Maybe; }; @@ -2897,7 +2710,7 @@ export type PositionUpdate = { /** Unrealised Profit and Loss (int64) */ unrealisedPNL: Scalars['String']; /** RFC3339Nano time the position was updated */ - updatedAt?: Maybe; + updatedAt?: Maybe; }; /** Represents a price on either the buy or sell side and all the orders at that price */ @@ -2995,7 +2808,7 @@ export enum PropertyKeyType { export type Proposal = { __typename?: 'Proposal'; /** RFC3339Nano time and date when the proposal reached Vega network */ - datetime: Scalars['String']; + datetime: Scalars['Timestamp']; /** Error details of the rejectionReason */ errorDetails?: Maybe; /** Proposal ID that is filled by Vega once proposal reaches the network */ @@ -3166,15 +2979,15 @@ export type ProposalTerms = { * RFC3339Nano time and date when voting closes for this proposal. * Constrained by "minClose" and "maxClose" network parameters. */ - closingDatetime: Scalars['String']; + closingDatetime: Scalars['Timestamp']; /** * RFC3339Nano time and date when this proposal is executed (if passed). Note that it has to be after closing date time. * Constrained by "minEnactInSeconds" and "maxEnactInSeconds" network parameters. * Note: Optional as free form proposals do not require it. */ - enactmentDatetime?: Maybe; + enactmentDatetime?: Maybe; /** RFC3339Nano time and when node validation of the proposal stops, accepted only with new asset proposals */ - validationDatetime?: Maybe; + validationDatetime?: Maybe; }; /** Various proposal types that are supported by Vega */ @@ -3309,11 +3122,6 @@ export type Query = { __typename?: 'Query'; /** An asset which is used in the vega network */ asset?: Maybe; - /** - * The list of all assets in use in the Vega network - * @deprecated Use assetsConnection instead - */ - assets?: Maybe>; /** The list of all assets in use in the Vega network or the specified asset if ID is provided */ assetsConnection?: Maybe; /** Get historical balances for an account within the given date range */ @@ -3345,11 +3153,6 @@ export type Query = { getMarketDataHistoryByID?: Maybe>>; /** Get market data history for a specific market. If no dates are given, the latest snapshot will be returned. If only the start date is provided all history from the given date will be provided, and if only the end date is provided, all history from the start up to and including the end date will be provided. Pagination is provided using a cursor based pagination model */ getMarketDataHistoryConnectionByID?: Maybe; - /** - * Query for historic key rotations - * @deprecated use keyRotationsConnection instead - */ - keyRotations?: Maybe>; /** Query for historic key rotations */ keyRotationsConnection: KeyRotationConnection; /** The last block process by the blockchain */ @@ -3358,11 +3161,6 @@ export type Query = { ledgerEntries: AggregatedLedgerEntriesConnection; /** An instrument that is trading on the Vega network */ market?: Maybe; - /** - * One or more instruments that are trading on the VEGA network - * @deprecated Use marketsConnection instead - */ - markets?: Maybe>; /** One or more instruments that are trading on the Vega network */ marketsConnection?: Maybe; /** The most recent history segment */ @@ -3371,101 +3169,36 @@ export type Query = { networkLimits?: Maybe; /** Return a single network parameter */ networkParameter?: Maybe; - /** - * Return the full list of network parameters - * @deprecated Use networkParametersConnection instead - */ - networkParameters?: Maybe>; /** Return the full list of network parameters */ networkParametersConnection: NetworkParametersConnection; - /** - * Governance proposals that aim to update Vega network parameters - * @deprecated Use proposalsConnection instead - */ - networkParametersProposals?: Maybe>; - /** - * Governance proposals that aim to create new assets in Vega - * @deprecated Use proposalsConnection instead - */ - newAssetProposals?: Maybe>; - /** - * Freeform governance proposals, which can be voted on but do not change the behaviour of the system, and can be used to gauge community sentiment in Vega - * @deprecated Use proposalsConnection instead - */ - newFreeformProposals?: Maybe>; - /** - * Governance proposals that aim to create new markets - * @deprecated Use proposalsConnection instead - */ - newMarketProposals?: Maybe>; /** Specific node in network */ node?: Maybe; /** Returns information about nodes */ nodeData?: Maybe; - /** - * Return a list of aggregated node signature for a given resource ID - * @deprecated Use nodeSignaturesConnection instead - */ - nodeSignatures?: Maybe>; /** Return a list of aggregated node signature for a given resource ID */ nodeSignaturesConnection?: Maybe; - /** - * All known network nodes - * @deprecated use nodesConnection instead - */ - nodes?: Maybe>; /** All known network nodes */ nodesConnection: NodesConnection; - /** - * All registered oracle specs - * @deprecated Use oracleDataConnection instead - */ - oracleData?: Maybe>; - /** - * All oracle data for a given oracle spec ID - * @deprecated Use oracleDataBySpecConnection instead - */ - oracleDataBySpec?: Maybe>; /** All oracle data for a given oracle spec ID */ oracleDataBySpecConnection?: Maybe; /** All registered oracle specs */ oracleDataConnection?: Maybe; /** An oracle spec for a given oracle spec ID */ oracleSpec?: Maybe; - /** - * All registered oracle specs - * @deprecated Use oracleSpecsConnection instead - */ - oracleSpecs?: Maybe>; /** All registered oracle specs */ oracleSpecsConnection?: Maybe; /** An order in the Vega network found by orderID */ orderByID: Order; /** An order in the Vega network found by referenceID */ orderByReference: Order; - /** - * Order versions (created via amendments if any) found by orderID - * @deprecated Use orderVersionsConnection instead - */ - orderVersions?: Maybe>; /** Order versions (created via amendments if any) found by orderID */ orderVersionsConnection?: Maybe; - /** - * One or more entities that are trading on the Vega network - * @deprecated Use partiesConnection instead. - */ - parties?: Maybe>; /** One or more entities that are trading on the Vega network */ partiesConnection?: Maybe; /** An entity that is trading on the Vega network */ party?: Maybe; /** A governance proposal located by either its ID or reference. If both are set, ID is used. */ proposal?: Maybe; - /** - * All governance proposals in the Vega network - * @deprecated Use proposalsConnection instead - */ - proposals?: Maybe>; /** All governance proposals in the Vega network */ proposalsConnection?: Maybe; /** List protocol upgrade proposals, optionally filtering on status or approver */ @@ -3474,18 +3207,8 @@ export type Query = { protocolUpgradeStatus?: Maybe; /** Get statistics about the Vega node */ statistics: Statistics; - /** - * Get a list of all transfers for a public key - * @deprecated Use transfersConnection instead - */ - transfers?: Maybe>; /** Get a list of all transfers for a public key */ transfersConnection?: Maybe; - /** - * Governance proposals that aim to update existing markets - * @deprecated Use proposalsConnection instead - */ - updateMarketProposals?: Maybe>; /** Find a withdrawal using its ID */ withdrawal?: Maybe; /** Fetch all withdrawals */ @@ -3571,7 +3294,7 @@ export type Queryerc20WithdrawalApprovalArgs = { /** Queries allow a caller to read data and filter data via GraphQL. */ export type QueryestimateOrderArgs = { - expiration?: InputMaybe; + expiration?: InputMaybe; marketId: Scalars['ID']; partyId: Scalars['ID']; price?: InputMaybe; @@ -3590,27 +3313,21 @@ export type QueryethereumKeyRotationsArgs = { /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerygetMarketDataHistoryByIDArgs = { - end?: InputMaybe; + end?: InputMaybe; first?: InputMaybe; id: Scalars['ID']; last?: InputMaybe; skip?: InputMaybe; - start?: InputMaybe; + start?: InputMaybe; }; /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerygetMarketDataHistoryConnectionByIDArgs = { - end?: InputMaybe; + end?: InputMaybe; id: Scalars['ID']; pagination?: InputMaybe; - start?: InputMaybe; -}; - - -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerykeyRotationsArgs = { - id?: InputMaybe; + start?: InputMaybe; }; @@ -3625,7 +3342,6 @@ export type QuerykeyRotationsConnectionArgs = { export type QueryledgerEntriesArgs = { dateRange?: InputMaybe; filter?: InputMaybe; - groupOptions?: InputMaybe; pagination?: InputMaybe; }; @@ -3636,12 +3352,6 @@ export type QuerymarketArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerymarketsArgs = { - id?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerymarketsConnectionArgs = { id?: InputMaybe; @@ -3661,42 +3371,12 @@ export type QuerynetworkParametersConnectionArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerynetworkParametersProposalsArgs = { - inState?: InputMaybe; -}; - - -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerynewAssetProposalsArgs = { - inState?: InputMaybe; -}; - - -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerynewFreeformProposalsArgs = { - inState?: InputMaybe; -}; - - -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerynewMarketProposalsArgs = { - inState?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerynodeArgs = { id: Scalars['ID']; }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerynodeSignaturesArgs = { - resourceId: Scalars['ID']; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerynodeSignaturesConnectionArgs = { pagination?: InputMaybe; @@ -3710,19 +3390,6 @@ export type QuerynodesConnectionArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryoracleDataArgs = { - pagination?: InputMaybe; -}; - - -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryoracleDataBySpecArgs = { - oracleSpecId: Scalars['ID']; - pagination?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QueryoracleDataBySpecConnectionArgs = { oracleSpecId: Scalars['ID']; @@ -3742,12 +3409,6 @@ export type QueryoracleSpecArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryoracleSpecsArgs = { - pagination?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QueryoracleSpecsConnectionArgs = { pagination?: InputMaybe; @@ -3767,15 +3428,6 @@ export type QueryorderByReferenceArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryorderVersionsArgs = { - first?: InputMaybe; - last?: InputMaybe; - orderId: Scalars['ID']; - skip?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QueryorderVersionsConnectionArgs = { orderId?: InputMaybe; @@ -3783,12 +3435,6 @@ export type QueryorderVersionsConnectionArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerypartiesArgs = { - id?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerypartiesConnectionArgs = { id?: InputMaybe; @@ -3809,12 +3455,6 @@ export type QueryproposalArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryproposalsArgs = { - inState?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QueryproposalsConnectionArgs = { inState?: InputMaybe; @@ -3831,14 +3471,6 @@ export type QueryprotocolUpgradeProposalsArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QuerytransfersArgs = { - isFrom?: InputMaybe; - isTo?: InputMaybe; - pubkey: Scalars['String']; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerytransfersConnectionArgs = { direction?: InputMaybe; @@ -3847,13 +3479,6 @@ export type QuerytransfersConnectionArgs = { }; -/** Queries allow a caller to read data and filter data via GraphQL. */ -export type QueryupdateMarketProposalsArgs = { - inState?: InputMaybe; - marketId?: InputMaybe; -}; - - /** Queries allow a caller to read data and filter data via GraphQL. */ export type QuerywithdrawalArgs = { id: Scalars['ID']; @@ -3911,7 +3536,7 @@ export type Reward = { /** Percentage out of the total distributed reward */ percentageOfTotal: Scalars['String']; /** Time at which the rewards was received */ - receivedAt: Scalars['String']; + receivedAt: Scalars['Timestamp']; /** The type of reward */ rewardType: AccountType; }; @@ -3925,22 +3550,6 @@ export type RewardEdge = { node: Reward; }; -/** RewardPerAssetDetail is deprecated, use RewardSummmary instead */ -export type RewardPerAssetDetail = { - __typename?: 'RewardPerAssetDetail'; - /** Asset in which the reward was paid */ - asset: Asset; - /** - * ID of asset in which the reward was paid - * @deprecated Use asset{ID} instead - */ - assetId: Scalars['ID']; - /** A list of rewards received for this asset */ - rewards?: Maybe>>; - /** The total amount of rewards received for this asset. */ - totalAmount: Scalars['String']; -}; - export type RewardScore = { __typename?: 'RewardScore'; /** The multisig score of the validator */ @@ -3963,23 +3572,11 @@ export type RewardSummary = { amount: Scalars['String']; /** The asset for which these rewards are associated */ asset: Asset; - /** - * List of individual reward payouts, ordered by epoch - * @deprecated Use rewardsConnection instead - */ - rewards?: Maybe>>; /** List of individual reward payouts, ordered by epoch */ rewardsConnection?: Maybe; }; -export type RewardSummaryrewardsArgs = { - first?: InputMaybe; - last?: InputMaybe; - skip?: InputMaybe; -}; - - export type RewardSummaryrewardsConnectionArgs = { assetId?: InputMaybe; pagination?: InputMaybe; @@ -4097,14 +3694,14 @@ export type StakeLinking = { /** The amount linked or unlinked */ amount: Scalars['String']; /** The time at which the stake linking was fully processed by the Vega network, null until defined */ - finalizedAt?: Maybe; + finalizedAt?: Maybe; id: Scalars['ID']; /** The party initiating the stake linking */ party: Party; /** The status of the linking */ status: StakeLinkingStatus; /** The time at which the request happened on ethereum */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; /** The transaction hash (ethereum) which initiated the link/unlink */ txHash: Scalars['String']; /** Type of linking: link|unlink */ @@ -4198,9 +3795,9 @@ export type Statistics = { /** Version of the chain (semver) */ chainVersion: Scalars['String']; /** RFC3339Nano current time (real) */ - currentTime: Scalars['String']; + currentTime: Scalars['Timestamp']; /** RFC3339Nano genesis time of the chain */ - genesisTime: Scalars['String']; + genesisTime: Scalars['Timestamp']; /** Number of orders per seconds */ ordersPerSecond: Scalars['String']; /** Status of the Vega application connection with the chain */ @@ -4226,7 +3823,7 @@ export type Statistics = { /** RFC3339Nano uptime of the node */ upTime: Scalars['String']; /** RFC3339Nano current time of the chain (decided through consensus) */ - vegaTime: Scalars['String']; + vegaTime: Scalars['Timestamp']; }; /** Subscriptions allow a caller to receive new information as it is available from the Vega network. */ @@ -4381,7 +3978,7 @@ export type TargetStakeParameters = { export type TimeUpdate = { __typename?: 'TimeUpdate'; /** RFC3339Nano time of new block time */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; }; /** A tradable instrument is a combination of an instrument and a risk model */ @@ -4409,7 +4006,7 @@ export type Trade = { /** The fee paid by the buyer side of the trade */ buyerFee: TradeFee; /** RFC3339Nano time for when the trade occurred */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** The hash of the trade data */ id: Scalars['ID']; /** The market the trade occurred on */ @@ -4491,7 +4088,7 @@ export type TradeUpdate = { /** The party that bought */ buyerId: Scalars['ID']; /** RFC3339Nano time for when the trade occurred */ - createdAt: Scalars['String']; + createdAt: Scalars['Timestamp']; /** The hash of the trade data */ id: Scalars['ID']; /** The market the trade occurred on */ @@ -4552,7 +4149,7 @@ export type Transfer = { /** The status of this transfer */ status: TransferStatus; /** The time at which the transfer was submitted */ - timestamp: Scalars['String']; + timestamp: Scalars['Timestamp']; /** The public key of the recipient of the funds */ to: Scalars['String']; /** The account type that has received the funds */ @@ -4742,7 +4339,7 @@ export enum ValidatorStatus { export type Vote = { __typename?: 'Vote'; /** RFC3339Nano time and date when the vote reached Vega network */ - datetime: Scalars['String']; + datetime: Scalars['Timestamp']; /** The weight of this vote based on the total equity like share */ equityLikeShareWeight: Scalars['String']; /** Total number of governance tokens for the party that cast the vote */ @@ -4790,11 +4387,11 @@ export type Withdrawal = { /** The asset to be withdrawn */ asset: Asset; /** RFC3339Nano time at which the withdrawal was created */ - createdTimestamp: Scalars['String']; + createdTimestamp: Scalars['Timestamp']; /** Foreign chain specific details about the withdrawal */ details?: Maybe; /** RFC3339Nano time until the withdrawal will be invalid */ - expiry: Scalars['String']; + expiry: Scalars['Timestamp']; /** The Vega internal ID of the withdrawal */ id: Scalars['ID']; /** The Party initiating the withdrawal */ @@ -4808,7 +4405,7 @@ export type Withdrawal = { /** Hash of the transaction on the foreign chain */ txHash?: Maybe; /** RFC3339Nano time at which the withdrawal was finalised */ - withdrawnTimestamp?: Maybe; + withdrawnTimestamp?: Maybe; }; export type WithdrawalDetails = Erc20WithdrawalDetails;