+ );
+}
diff --git a/apps/explorer/src/app/components/txs/tx-filter.tsx b/apps/explorer/src/app/components/txs/tx-filter.tsx
new file mode 100644
index 000000000..b2b4ead30
--- /dev/null
+++ b/apps/explorer/src/app/components/txs/tx-filter.tsx
@@ -0,0 +1,164 @@
+import { t } from '@vegaprotocol/i18n';
+import {
+ DropdownMenu,
+ DropdownMenuCheckboxItem,
+ DropdownMenuContent,
+ DropdownMenuItemIndicator,
+ DropdownMenuSeparator,
+ DropdownMenuSub,
+ DropdownMenuSubTrigger,
+ DropdownMenuTrigger,
+ DropdownMenuSubContent,
+ Icon,
+ Button,
+} from '@vegaprotocol/ui-toolkit';
+import type { Dispatch, SetStateAction } from 'react';
+import { FilterLabel } from './tx-filter-label';
+
+// All possible transaction types. Should be generated.
+export type FilterOption =
+ | 'Amend LiquidityProvision Order'
+ | 'Amend Order'
+ | 'Batch Market Instructions'
+ | 'Cancel LiquidityProvision Order'
+ | 'Cancel Order'
+ | 'Cancel Transfer Funds'
+ | 'Chain Event'
+ | 'Delegate'
+ | 'Ethereum Key Rotate Submission'
+ | 'Issue Signatures'
+ | 'Key Rotate Submission'
+ | 'Liquidity Provision Order'
+ | 'Node Signature'
+ | 'Node Vote'
+ | 'Proposal'
+ | 'Protocol Upgrade'
+ | 'Register new Node'
+ | 'State Variable Proposal'
+ | 'Submit Oracle Data'
+ | 'Submit Order'
+ | 'Transfer Funds'
+ | 'Undelegate'
+ | 'Validator Heartbeat'
+ | 'Vote on Proposal'
+ | 'Withdraw';
+
+// Alphabetised list of transaction types to appear at the top level
+export const PrimaryFilterOptions: FilterOption[] = [
+ 'Amend LiquidityProvision Order',
+ 'Amend Order',
+ 'Batch Market Instructions',
+ 'Cancel LiquidityProvision Order',
+ 'Cancel Order',
+ 'Cancel Transfer Funds',
+ 'Delegate',
+ 'Liquidity Provision Order',
+ 'Proposal',
+ 'Submit Oracle Data',
+ 'Submit Order',
+ 'Transfer Funds',
+ 'Undelegate',
+ 'Vote on Proposal',
+ 'Withdraw',
+];
+
+// Alphabetised list of transaction types to nest under a 'More...' submenu
+export const SecondaryFilterOptions: FilterOption[] = [
+ 'Chain Event',
+ 'Ethereum Key Rotate Submission',
+ 'Issue Signatures',
+ 'Key Rotate Submission',
+ 'Node Signature',
+ 'Node Vote',
+ 'Protocol Upgrade',
+ 'Register new Node',
+ 'State Variable Proposal',
+ 'Validator Heartbeat',
+];
+
+export const AllFilterOptions: FilterOption[] = [
+ ...PrimaryFilterOptions,
+ ...SecondaryFilterOptions,
+];
+
+export interface TxFilterProps {
+ filters: Set;
+ setFilters: Dispatch>>;
+}
+
+/**
+ * Renders a structured dropdown menu of all of the available transaction
+ * types. It allows a user to select one transaction type to view. Later
+ * it will support multiple selection, but until the API supports that it is
+ * one or all.
+ * @param filters null or Set of tranaction types
+ * @param setFilters A function to update the filters prop
+ * @returns
+ */
+export const TxsFilter = ({ filters, setFilters }: TxFilterProps) => {
+ return (
+
+
+
+ }
+ >
+
+ {filters.size > 1 ? null : (
+ <>
+ setFilters(new Set(AllFilterOptions))}
+ >
+ {t('Clear filters')}
+
+
+ >
+ )}
+ {PrimaryFilterOptions.map((f) => (
+ {
+ // NOTE: These act like radio buttons until the API supports multiple filters
+ setFilters(new Set([f]));
+ }}
+ id={`radio-${f}`}
+ >
+ {f}
+
+
+
+
+ ))}
+
+
+ {t('More Types')}
+
+
+
+ {SecondaryFilterOptions.map((f) => (
+ {
+ // NOTE: These act like radio buttons until the API supports multiple filters
+ setFilters(new Set([f]));
+ }}
+ id={`radio-${f}`}
+ >
+ {f}
+
+
+
+
+ ))}
+
+
+
+
+ );
+};
diff --git a/apps/explorer/src/app/components/txs/txs-infinite-list.tsx b/apps/explorer/src/app/components/txs/txs-infinite-list.tsx
index a5b6d0a85..e7f1000be 100644
--- a/apps/explorer/src/app/components/txs/txs-infinite-list.tsx
+++ b/apps/explorer/src/app/components/txs/txs-infinite-list.tsx
@@ -1,4 +1,4 @@
-import React from 'react';
+import React, { useEffect, useRef } from 'react';
import { FixedSizeList as List } from 'react-window';
import InfiniteLoader from 'react-window-infinite-loader';
import { t } from '@vegaprotocol/i18n';
@@ -69,6 +69,17 @@ export const TxsInfiniteList = ({
}: TxsInfiniteListProps) => {
const { screenSize } = useScreenDimensions();
const isStacked = ['xs', 'sm'].includes(screenSize);
+ const infiniteLoaderRef = useRef(null);
+ const hasMountedRef = useRef(false);
+
+ useEffect(() => {
+ if (hasMountedRef.current) {
+ if (infiniteLoaderRef.current) {
+ infiniteLoaderRef.current.resetloadMoreItemsCache(true);
+ }
+ }
+ hasMountedRef.current = true;
+ }, [loadMoreTxs]);
if (!txs) {
if (!areTxsLoading) {
@@ -110,6 +121,7 @@ export const TxsInfiniteList = ({
isItemLoaded={isItemLoaded}
itemCount={itemCount}
loadMoreItems={loadMoreItems}
+ ref={infiniteLoaderRef}
>
{({ onItemsRendered, ref }) => (
{
// Hacky fix for param as array
let urlAsString = url.toString();
if (filters) {
- urlAsString += '&' + filters;
+ urlAsString += '&' + filters.replace(' ', '%20');
}
return urlAsString;
@@ -65,6 +65,14 @@ export const useTxsData = ({ limit, filters }: IUseTxsData) => {
}
}, [setTxsState, data]);
+ useEffect(() => {
+ setTxsState((prev) => ({
+ txsData: [],
+ hasMoreTxs: true,
+ lastCursor: '',
+ }));
+ }, [filters]);
+
const loadTxs = useCallback(() => {
return refetch({
limit: limit,
diff --git a/apps/explorer/src/app/routes/txs/home/index.tsx b/apps/explorer/src/app/routes/txs/home/index.tsx
index 08f839739..d24283de4 100644
--- a/apps/explorer/src/app/routes/txs/home/index.tsx
+++ b/apps/explorer/src/app/routes/txs/home/index.tsx
@@ -5,17 +5,43 @@ import { TxsInfiniteList } from '../../../components/txs';
import { useTxsData } from '../../../hooks/use-txs-data';
import { useDocumentTitle } from '../../../hooks/use-document-title';
-const BE_TXS_PER_REQUEST = 20;
+import { useState } from 'react';
+import { AllFilterOptions, TxsFilter } from '../../../components/txs/tx-filter';
+
+const BE_TXS_PER_REQUEST = 15;
export const TxsList = () => {
useDocumentTitle(['Transactions']);
- const { hasMoreTxs, loadTxs, error, txsData, refreshTxs, loading } =
- useTxsData({ limit: BE_TXS_PER_REQUEST });
return (
-
+ {t('Transactions')}
-
+
+
+ );
+};
+
+export const TxsListFiltered = () => {
+ const [filters, setFilters] = useState(new Set(AllFilterOptions));
+
+ const f =
+ filters && filters.size === 1
+ ? `filters[cmd.type]=${Array.from(filters)[0]}`
+ : '';
+
+ const { hasMoreTxs, loadTxs, error, txsData, refreshTxs, loading } =
+ useTxsData({
+ limit: BE_TXS_PER_REQUEST,
+ filters: f,
+ });
+
+ return (
+ <>
+
+
{
error={error}
className="mb-28"
/>
-
+ >
);
};
diff --git a/apps/explorer/src/types/explorer.d.ts b/apps/explorer/src/types/explorer.d.ts
index 9023ad67d..385b5c9fd 100644
--- a/apps/explorer/src/types/explorer.d.ts
+++ b/apps/explorer/src/types/explorer.d.ts
@@ -20,8 +20,8 @@ export interface paths {
'/info': {
/**
* Info
- * @description Retrieves information about the block explorer.
- * Response contains a semver formatted version of the data node and the commit hash, from which the block explorer was built,
+ * @description Get information about the block explorer.
+ * Response contains a semver formatted version of the data node and the commit hash, from which the block explorer was built
*/
get: operations['BlockExplorer_Info'];
};
@@ -44,7 +44,7 @@ export interface paths {
export interface components {
schemas: {
/**
- * @description Comparator describes the type of comparison.
+ * @description Operator describes the type of comparison.
*
* - OPERATOR_UNSPECIFIED: The default value
* - OPERATOR_EQUALS: Verify if the property values are strictly equal or not.
@@ -65,8 +65,8 @@ export interface components {
| 'OPERATOR_LESS_THAN'
| 'OPERATOR_LESS_THAN_OR_EQUAL';
/**
- * The supported oracle sources
- * @description - ORACLE_SOURCE_UNSPECIFIED: The default value
+ * Supported oracle sources
+ * @description - ORACLE_SOURCE_UNSPECIFIED: Default value
* - ORACLE_SOURCE_OPEN_ORACLE: Specifies that the payload will be base64 encoded JSON conforming to the Open Oracle standard
* - ORACLE_SOURCE_JSON: Specifies that the payload will be base64 encoded JSON, but does not specify the shape of the data
* @default ORACLE_SOURCE_UNSPECIFIED
@@ -86,8 +86,8 @@ export interface components {
* NOTE: this may in future be multiple types or have sub types for orders that provide different ways of specifying expiry
* - TIME_IN_FORCE_IOC: Immediate or cancel, the order trades any amount and as much as possible
* but does not remain on the book (whether it trades or not)
- * - TIME_IN_FORCE_FOK: Fill or kill, The order either trades completely (remainingSize == 0 after adding)
- * or not at all, does not remain on the book if it doesn't trade
+ * - TIME_IN_FORCE_FOK: Fill or kill, the order either trades completely i.e. remainingSize == 0 after adding,
+ * or not at all, and does not remain on the book if it doesn't trade
* - TIME_IN_FORCE_GFA: Good for auction, this order is only accepted during an auction period
* - TIME_IN_FORCE_GFN: Good for normal, this order is only accepted during normal trading (that can be continuous trading or frequent batched auctions)
* @default TIME_IN_FORCE_UNSPECIFIED
@@ -111,56 +111,56 @@ export interface components {
| 'METHOD_AT_END_OF_EPOCH';
readonly blockexplorerapiv1Transaction: {
/**
- * The height of the block the transaction was found in
+ * Height of the block the transaction was found in
* Format: uint64
*/
readonly block?: string;
/**
- * The results code of the transaction (0 is success)
+ * Results code of the transaction. 0 indicates the transaction was successful
* Format: int64
*/
readonly code?: number;
- /** The actual command of the transaction */
+ /** Actual command of the transaction */
readonly command?: components['schemas']['v1InputData'];
- /** The cursor for this transaction (in the page, used for paginated results) */
+ /** Cursor for this transaction. This is used for paginating results */
readonly cursor?: string;
/**
- * An optional error happening when processing / checking the transaction
- * Should be set if error code is not 0
+ * Optional error happening when processing / checking the transaction
+ * This should be set if error code is not 0
*/
readonly error?: string;
- /** The hash of the transaction */
+ /** Hash of the transaction */
readonly hash?: string;
/**
- * The index of the transaction in the block
+ * Index of the transaction in the block
* Format: int64
*/
readonly index?: number;
- /** Submitter's signature of transaction */
+ /** Signature generated by the submitter for the transaction */
readonly signature?: components['schemas']['v1Signature'];
- /** The submitter of the transaction (Vega public key) */
+ /** Vega public key of the transaction's submitter */
readonly submitter?: string;
- /** The type of transaction */
+ /** Type of transaction */
readonly type?: string;
};
- /** A transfer initiated by a party */
+ /** Transfer initiated by a party */
readonly commandsv1Transfer: {
- /** The amount to be taken from the source account */
+ /** @description Amount to be taken from the source account. This field is an unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
- /** The asset */
+ /** @description Asset ID of the asset to be transferred. */
readonly asset?: string;
/**
- * The account type from which the funds of the party
- * should be taken
+ * @description Account type from which the funds of the party
+ * should be taken.
*/
readonly fromAccountType?: components['schemas']['vegaAccountType'];
readonly oneOff?: components['schemas']['v1OneOffTransfer'];
readonly recurring?: components['schemas']['v1RecurringTransfer'];
- /** The reference to be attached to the transfer */
+ /** @description Reference to be attached to the transfer. */
readonly reference?: string;
- /** The public key of the destination account */
+ /** @description Public key of the destination account. */
readonly to?: string;
- /** The type of the destination account */
+ /** @description Type of the destination account. */
readonly toAccountType?: components['schemas']['vegaAccountType'];
};
readonly googlerpcStatus: {
@@ -175,42 +175,42 @@ export interface components {
};
/** Used to announce a node as a new pending validator */
readonly v1AnnounceNode: {
- /** AvatarURL of the validator */
+ /** @description AvatarURL of the validator. */
readonly avatarUrl?: string;
- /** Public key for the blockchain, required field */
+ /** @description Public key for the blockchain, required field. */
readonly chainPubKey?: string;
- /** Country code (ISO 3166-1 alpha-2) for the location of the node */
+ /** @description Country code (ISO 3166-1 alpha-2) for the location of the node. */
readonly country?: string;
- /** Ethereum public key, required field */
+ /** @description Ethereum public key, required field. */
readonly ethereumAddress?: string;
- /** Signature from the validator made using the ethereum wallet */
+ /** @description Signature from the validator made using the ethereum wallet. */
readonly ethereumSignature?: components['schemas']['v1Signature'];
/**
- * The epoch from which the validator is expected
- * to be ready to validate blocks
* Format: uint64
+ * @description Epoch from which the validator is expected
+ * to be ready to validate blocks.
*/
readonly fromEpoch?: string;
- /** ID of the validator, (public master key) */
+ /** @description Node ID of the validator, i.e. the node's public master key. */
readonly id?: string;
- /** URL with more info on the node */
+ /** @description URL with more info on the node. */
readonly infoUrl?: string;
- /** Name of the validator */
+ /** @description Name of the validator. */
readonly name?: string;
- /** Ethereum public key to use as a submitter to allow automatic signature generation */
+ /** @description Ethereum public key to use as a submitter to allow automatic signature generation. */
readonly submitterAddress?: string;
- /** Vega public key, required field */
+ /** @description Vega public key, required field. */
readonly vegaPubKey?: string;
/**
- * Vega public key derivation index
* Format: int64
+ * @description Vega public key derivation index.
*/
readonly vegaPubKeyIndex?: number;
- /** Signature from the validator made using the Vega wallet */
+ /** @description Signature from the validator made using the Vega wallet. */
readonly vegaSignature?: components['schemas']['v1Signature'];
};
/**
- * A batch of order instructions.
+ * Batch of order instructions.
* This command accepts only the following batches of commands
* and will be processed in the following order:
* - OrderCancellation
@@ -221,66 +221,66 @@ export interface components {
* "spam.protection.max.batchSize"
*/
readonly v1BatchMarketInstructions: {
- /** A list of order amendments to be processed sequentially */
+ /** @description List of order amendments to be processed sequentially. */
readonly amendments?: readonly components['schemas']['v1OrderAmendment'][];
- /** A list of order cancellations to be processed sequentially */
+ /** @description List of order cancellations to be processed sequentially. */
readonly cancellations?: readonly components['schemas']['v1OrderCancellation'][];
- /** A list of order submissions to be processed sequentially */
+ /** @description List of order submissions to be processed sequentially. */
readonly submissions?: readonly components['schemas']['v1OrderSubmission'][];
};
- /** A request for cancelling a recurring transfer */
+ /** Request for cancelling a recurring transfer */
readonly v1CancelTransfer: {
- /** The ID of the transfer to cancel */
+ /** @description Transfer ID of the transfer to cancel. */
readonly transferId?: string;
};
- /** An event forwarded to the Vega network to provide information on events happening on other networks */
+ /** Event forwarded to the Vega network to provide information on events happening on other networks */
readonly v1ChainEvent: {
- /** Built-in asset event */
+ /** @description Built-in asset event. */
readonly builtin?: components['schemas']['vegaBuiltinAssetEvent'];
- /** Ethereum ERC20 event */
+ /** @description Ethereum ERC20 event. */
readonly erc20?: components['schemas']['vegaERC20Event'];
- /** Ethereum ERC20 multisig event */
+ /** @description Ethereum ERC20 multisig event. */
readonly erc20Multisig?: components['schemas']['vegaERC20MultiSigEvent'];
/**
- * Arbitrary one-time integer used to prevent replay attacks
* Format: uint64
+ * @description Arbitrary one-time integer used to prevent replay attacks.
*/
readonly nonce?: string;
- /** Ethereum Staking event */
+ /** @description Ethereum Staking event. */
readonly stakingEvent?: components['schemas']['vegaStakingEvent'];
- /** The identifier of the transaction in which the events happened, usually a hash */
+ /** @description Transaction ID of the transaction in which the events happened, usually a hash. */
readonly txId?: string;
};
/** Condition describes the condition that must be validated by the network */
readonly v1Condition: {
- /** @description comparator is the type of comparison to make on the value. */
+ /** @description Type of comparison to make on the value. */
readonly operator?: components['schemas']['ConditionOperator'];
- /** @description value is used by the comparator. */
+ /** @description Value to be compared with by the operator. */
readonly value?: string;
};
- /** A command to submit an instruction to delegate some stake to a node */
+ /** Command to submit an instruction to delegate some stake to a node */
readonly v1DelegateSubmission: {
- /** The amount of stake to delegate */
+ /** @description Amount of stake to delegate. This field is an unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
- /** The ID for the node to delegate to */
+ /** @description Delegate to the specified node ID. */
readonly nodeId?: string;
};
readonly v1ETHAddress: {
readonly address?: string;
};
- /** A transaction to allow a validator to rotate their ethereum keys */
+ /** Transaction to allow a validator to rotate their ethereum keys */
readonly v1EthereumKeyRotateSubmission: {
- /** Currently used public address */
+ /** @description Currently used public address. */
readonly currentAddress?: string;
- /** Signature that can be verified using the new ethereum address */
+ /** @description Signature that can be verified using the new ethereum address. */
readonly ethereumSignature?: components['schemas']['v1Signature'];
- /** The new address to rotate to */
+ /** @description New address to rotate to. */
readonly newAddress?: string;
- /** Ethereum public key to use as a submitter to allow automatic signature generation */
+ /** @description Ethereum public key to use as a submitter to allow automatic signature generation. */
readonly submitterAddress?: string;
/**
- * Target block at which the key rotation will take effect on
* Format: uint64
+ * @description Target block at which the key rotation will take effect on.
*/
readonly targetBlock?: string;
};
@@ -290,31 +290,31 @@ export interface components {
*/
readonly v1Filter: {
/**
- * @description conditions are the conditions that should be matched by the data to be
+ * @description Conditions that should be matched by the data to be
* considered of interest.
*/
readonly conditions?: readonly components['schemas']['v1Condition'][];
- /** @description key is the data source data property key targeted by the filter. */
+ /** @description Data source's data property key targeted by the filter. */
readonly key?: components['schemas']['v1PropertyKey'];
};
readonly v1GetTransactionResponse: {
- /** The transaction corresponding to the hash */
+ /** Transaction corresponding to the hash */
readonly transaction?: components['schemas']['blockexplorerapiv1Transaction'];
};
readonly v1InfoResponse: {
- /** The commit hash from which the data-node was built */
+ /** Commit hash from which the data node was built */
readonly commitHash?: string;
- /** A semver formatted version of the data node */
+ /** Semver formatted version of the data node */
readonly version?: string;
};
readonly v1InputData: {
- /** A command used by a node operator to announce its node as a pending validator */
+ /** @description Command used by a node operator to announce its node as a pending validator. */
readonly announceNode?: components['schemas']['v1AnnounceNode'];
- /** A command to submit a batch of order instructions to a market */
+ /** @description Command to submit a batch of order instructions to a market. */
readonly batchMarketInstructions?: components['schemas']['v1BatchMarketInstructions'];
/**
* Format: uint64
- * @description The block height at which the transaction was made.
+ * @description Block height at which the transaction was made.
* This should be the current block height. The transaction will be valid
* from the block and up to the `tolerance` block height.
* Example: If the network has a tolerance of 150 blocks and `block_height`
@@ -324,39 +324,38 @@ export interface components {
* `block_height` prevents replay attacks in conjunction with `nonce` (see above).
*/
readonly blockHeight?: string;
- /** A command to request cancelling a recurring transfer */
+ /** @description Command to request cancelling a recurring transfer. */
readonly cancelTransfer?: components['schemas']['v1CancelTransfer'];
/**
- * Command used by a validator to submit an event forwarded to the Vega network to provide information
+ * @description Command used by a validator to submit an event forwarded to the Vega network to provide information
* on events happening on other networks, to be used by a foreign chain
- * to recognise a decision taken by the Vega network
+ * to recognise a decision taken by the Vega network.
*/
readonly chainEvent?: components['schemas']['v1ChainEvent'];
- /** Command to delegate tokens to a validator */
+ /** @description Command to delegate tokens to a validator. */
readonly delegateSubmission?: components['schemas']['v1DelegateSubmission'];
- /** Command used by a validator to allow given validator to rotate their Ethereum keys */
+ /** @description Command used by a validator to allow given validator to rotate their Ethereum keys. */
readonly ethereumKeyRotateSubmission?: components['schemas']['v1EthereumKeyRotateSubmission'];
- /** Command used by a validator to submit signatures to a smart contract */
+ /** @description Command used by a validator to submit signatures to a smart contract. */
readonly issueSignatures?: components['schemas']['v1IssueSignatures'];
- /** Command used by a validator to allow given validator to rotate their Vega keys */
+ /** @description Command used by a validator to allow given validator to rotate their Vega keys. */
readonly keyRotateSubmission?: components['schemas']['v1KeyRotateSubmission'];
- /** Command to request amending a liquidity commitment */
+ /** @description Command to request amending a liquidity commitment. */
readonly liquidityProvisionAmendment?: components['schemas']['v1LiquidityProvisionAmendment'];
- /** Command to request cancelling a liquidity commitment */
+ /** @description Command to request cancelling a liquidity commitment. */
readonly liquidityProvisionCancellation?: components['schemas']['v1LiquidityProvisionCancellation'];
- /** Command to submit a liquidity commitment */
+ /** @description Command to submit a liquidity commitment. */
readonly liquidityProvisionSubmission?: components['schemas']['v1LiquidityProvisionSubmission'];
- /** Command used by a validator to submit a signature, to be used by a foreign chain to recognise a decision taken by the Vega network */
+ /** @description Command used by a validator to submit a signature, to be used by a foreign chain to recognise a decision taken by the Vega network. */
readonly nodeSignature?: components['schemas']['v1NodeSignature'];
/**
- * Validator commands
- * Command used by a validator when a node votes for validating that a given resource exists or is valid,
- * for example, an ERC20 deposit is valid and exists on ethereum
+ * @description Command used by a validator when a node votes for validating that a given resource exists or is valid,
+ * for example, an ERC20 deposit is valid and exists on ethereum.
*/
readonly nodeVote?: components['schemas']['v1NodeVote'];
/**
* Format: uint64
- * @description A number to provide uniqueness to prevent accidental replays and,
+ * @description Number to provide uniqueness to prevent accidental replays and,
* in combination with `block_height`, deliberate attacks.
* A nonce provides uniqueness for otherwise identical transactions,
* ensuring that the transaction hash uniquely identifies a specific transaction.
@@ -368,113 +367,112 @@ export interface components {
* slightly differently, causing a different hash.
*/
readonly nonce?: string;
- /**
- * Oracles
- * Command to submit new oracle data from third party providers
- */
+ /** @description Command to submit new oracle data from third party providers. */
readonly oracleDataSubmission?: components['schemas']['v1OracleDataSubmission'];
- /** Command to amend an order */
+ /** @description Command to amend an order. */
readonly orderAmendment?: components['schemas']['v1OrderAmendment'];
- /**
- * User commands
- * Command to cancel an order
- */
+ /** @description Command to cancel an order. */
readonly orderCancellation?: components['schemas']['v1OrderCancellation'];
- /** A command for submitting an order */
+ /** @description Command for submitting an order. */
readonly orderSubmission?: components['schemas']['v1OrderSubmission'];
- /** Command to submit a governance proposal */
+ /** @description Command to submit a governance proposal. */
readonly proposalSubmission?: components['schemas']['v1ProposalSubmission'];
- /** Command used by a validator to propose a protocol upgrade */
+ /** @description Command used by a validator to propose a protocol upgrade. */
readonly protocolUpgradeProposal?: components['schemas']['v1ProtocolUpgradeProposal'];
- /** Command used by a validator to submit a floating point value */
+ /** @description Command used by a validator to submit a floating point value. */
readonly stateVariableProposal?: components['schemas']['v1StateVariableProposal'];
- /** Command to submit a transfer */
+ /** @description Command to submit a transfer. */
readonly transfer?: components['schemas']['commandsv1Transfer'];
- /** Command to remove tokens delegated to a validator */
+ /** @description Command to remove tokens delegated to a validator. */
readonly undelegateSubmission?: components['schemas']['v1UndelegateSubmission'];
/**
- * Command used by a validator to signal they are still online and validating blocks
- * or ready to validate blocks when they are still a pending validator
+ * @description Command used by a validator to signal they are still online and validating blocks
+ * or ready to validate blocks when they are still a pending validator.
*/
readonly validatorHeartbeat?: components['schemas']['v1ValidatorHeartbeat'];
- /** Command to submit a vote on a governance proposal */
+ /** @description Command to submit a vote on a governance proposal. */
readonly voteSubmission?: components['schemas']['v1VoteSubmission'];
- /** Command to submit a withdrawal */
+ /** @description Command to submit a withdrawal. */
readonly withdrawSubmission?: components['schemas']['v1WithdrawSubmission'];
};
- /** A transaction for a validator to submit signatures to a smart contract */
+ /** Transaction for a validator to submit signatures to a smart contract */
readonly v1IssueSignatures: {
- /** The kind of signatures to generate, namely for whether a signer is being added or removed */
+ /** @description What kind of signatures to generate, namely for whether a signer is being added or removed. */
readonly kind?: components['schemas']['v1NodeSignatureKind'];
- /** The ethereum address which will submit the signatures to the smart contract */
+ /** @description Ethereum address which will submit the signatures to the smart contract. */
readonly submitter?: string;
- /** The ID of the node that will be signed in or out of the smart contract */
+ /** @description Node ID of the validator node that will be signed in or out of the smart contract. */
readonly validatorNodeId?: string;
};
- /** A transaction to allow a validator to rotate their Vega keys */
+ /** Transaction to allow a validator to rotate their Vega keys */
readonly v1KeyRotateSubmission: {
- /** Hash of currently used public key */
+ /** @description Hash of currently used public key. */
readonly currentPubKeyHash?: string;
- /** The new public key to rotate to */
+ /** @description New public key to rotate to. */
readonly newPubKey?: string;
/**
- * New Vega public key derivation index
* Format: int64
+ * @description New Vega public key derivation index.
*/
readonly newPubKeyIndex?: number;
/**
- * Target block at which the key rotation will take effect on
* Format: uint64
+ * @description Target block at which the key rotation will take effect on.
*/
readonly targetBlock?: string;
};
/** Amend a liquidity provision request */
readonly v1LiquidityProvisionAmendment: {
readonly buys?: readonly components['schemas']['vegaLiquidityOrder'][];
- /** From here at least one of the following is required to consider the command valid */
+ /** @description From here at least one of the following is required to consider the command valid. */
readonly commitmentAmount?: string;
readonly fee?: string;
+ /** @description Unique ID for the market with the liquidity provision to be amended. */
readonly marketId?: string;
readonly reference?: string;
readonly sells?: readonly components['schemas']['vegaLiquidityOrder'][];
};
/** Cancel a liquidity provision request */
readonly v1LiquidityProvisionCancellation: {
+ /** @description Unique ID for the market with the liquidity provision to be cancelled. */
readonly marketId?: string;
};
/** A liquidity provision submitted for a given market */
readonly v1LiquidityProvisionSubmission: {
- /** A set of liquidity buy orders to meet the liquidity provision obligation */
+ /** @description Set of liquidity buy orders to meet the liquidity provision obligation. */
readonly buys?: readonly components['schemas']['vegaLiquidityOrder'][];
- /** Specified as a unitless number that represents the amount of settlement asset of the market */
+ /**
+ * @description Specified as a unitless number that represents the amount of settlement asset of the market.
+ * This field is an unsigned integer scaled using the asset's decimal places.
+ */
readonly commitmentAmount?: string;
- /** Nominated liquidity fee factor, which is an input to the calculation of taker fees on the market, as per setting fees and rewarding liquidity providers */
+ /** @description Nominated liquidity fee factor, which is an input to the calculation of taker fees on the market, as per setting fees and rewarding liquidity providers. */
readonly fee?: string;
- /** Market identifier for the order, required field */
+ /** @description Market ID for the order, required field. */
readonly marketId?: string;
- /** A reference to be added to every order created out of this liquidityProvisionSubmission */
+ /** @description Reference to be added to every order created out of this liquidityProvisionSubmission. */
readonly reference?: string;
- /** A set of liquidity sell orders to meet the liquidity provision obligation */
+ /** @description Set of liquidity sell orders to meet the liquidity provision obligation. */
readonly sells?: readonly components['schemas']['vegaLiquidityOrder'][];
};
readonly v1ListTransactionsResponse: {
- /** The transaction corresponding to the specific request and filters */
+ /** Transaction corresponding to the specific request and filters */
readonly transactions?: readonly components['schemas']['blockexplorerapiv1Transaction'][];
};
/** Represents a signature from a validator, to be used by a foreign chain in order to recognise a decision taken by the Vega network */
readonly v1NodeSignature: {
- /** The identifier of the resource being signed */
+ /** @description ID of the resource being signed. */
readonly id?: string;
- /** The kind of resource being signed */
+ /** @description Kind of resource being signed. */
readonly kind?: components['schemas']['v1NodeSignatureKind'];
/**
- * The signature
* Format: byte
+ * @description The signature generated by the signer.
*/
readonly sig?: string;
};
/**
- * The kind of signature created by a node, for example, allow-listing a new asset, withdrawal etc
+ * Kind of signature created by a node, for example, allow-listing a new asset, withdrawal etc
* @description - NODE_SIGNATURE_KIND_UNSPECIFIED: Represents an unspecified or missing value from the input
* - NODE_SIGNATURE_KIND_ASSET_NEW: Represents a signature for a new asset allow-listing
* - NODE_SIGNATURE_KIND_ASSET_WITHDRAWAL: Represents a signature for an asset withdrawal
@@ -492,29 +490,29 @@ export interface components {
| 'NODE_SIGNATURE_KIND_ERC20_MULTISIG_SIGNER_REMOVED'
| 'NODE_SIGNATURE_KIND_ASSET_UPDATE';
/**
- * Used when a node votes for validating that a given resource exists or is valid,
- * for example, an ERC20 deposit is valid and exists on ethereum
+ * @description Used when a node votes for validating that a given resource exists or is valid,
+ * for example, an ERC20 deposit is valid and exists on ethereum.
*/
readonly v1NodeVote: {
- /** Reference, required field */
+ /** @description Reference identifying the resource making the vote, required field. */
readonly reference?: string;
- /** type of NodeVote, also required */
+ /** @description Type of NodeVote, also required. */
readonly type?: components['schemas']['v1NodeVoteType'];
};
/**
* - TYPE_UNSPECIFIED: Represents an unspecified or missing value from the input
- * - TYPE_STAKE_DEPOSITED: A node vote a new stake deposit
- * - TYPE_STAKE_REMOVED: A node vote for a new stake removed event
- * - TYPE_FUNDS_DEPOSITED: A node vote for new collateral deposited
- * - TYPE_SIGNER_ADDED: A node vote for a new signer added to the erc20 bridge
- * - TYPE_SIGNER_REMOVED: A node vote for a signer removed from the erc20 bridge
- * - TYPE_BRIDGE_STOPPED: A node vote for a bridge stopped event
- * - TYPE_BRIDGE_RESUMED: A node vote for a bridge resumed event
- * - TYPE_ASSET_LISTED: A node vote for a newly listed asset
- * - TYPE_LIMITS_UPDATED: A node vote for an asset limits update
- * - TYPE_STAKE_TOTAL_SUPPLY: A node vote to share the total supply of the staking token
- * - TYPE_SIGNER_THRESHOLD_SET: A node vote to update the threshold of the signer set for the multisig contract
- * - TYPE_GOVERNANCE_VALIDATE_ASSET: A node vote to validate a new assert governance proposal
+ * - TYPE_STAKE_DEPOSITED: Node vote for a new stake deposit
+ * - TYPE_STAKE_REMOVED: Node vote for a new stake removed event
+ * - TYPE_FUNDS_DEPOSITED: Node vote for a new collateral deposit
+ * - TYPE_SIGNER_ADDED: Node vote for a new signer added to the erc20 bridge
+ * - TYPE_SIGNER_REMOVED: Node vote for a signer removed from the erc20 bridge
+ * - TYPE_BRIDGE_STOPPED: Node vote for a bridge stopped event
+ * - TYPE_BRIDGE_RESUMED: Node vote for a bridge resumed event
+ * - TYPE_ASSET_LISTED: Node vote for a newly listed asset
+ * - TYPE_LIMITS_UPDATED: Node vote for an asset limits update
+ * - TYPE_STAKE_TOTAL_SUPPLY: Node vote to share the total supply of the staking token
+ * - TYPE_SIGNER_THRESHOLD_SET: Node vote to update the threshold of the signer set for the multisig contract
+ * - TYPE_GOVERNANCE_VALIDATE_ASSET: Node vote to validate a new assert governance proposal
* @default TYPE_UNSPECIFIED
* @enum {string}
*/
@@ -535,22 +533,22 @@ export interface components {
/** Specific details for a one off transfer */
readonly v1OneOffTransfer: {
/**
- * A unix timestamp in seconds. Time at which the
- * transfer should be delivered into the To account
* Format: int64
+ * @description Unix timestamp in nanoseconds. Time at which the
+ * transfer should be delivered into the To account.
*/
readonly deliverOn?: string;
};
/** Command to submit new Oracle data from third party providers */
readonly v1OracleDataSubmission: {
/**
- * The data provided by the data source
- * In the case of Open Oracle - it will be the entire object - it will contain messages, signatures and price data
* Format: byte
+ * @description Data provided by the data source
+ * In the case of Open Oracle - it will be the entire object - it will contain messages, signatures and price data.
*/
readonly payload?: string;
/**
- * @description The source from which the data is coming from. Must be base64 encoded.
+ * @description Source from which the data is coming from. Must be base64 encoded.
* Oracle data is a type of external data source data.
*/
readonly source?: components['schemas']['OracleDataSubmissionOracleSource'];
@@ -558,105 +556,100 @@ export interface components {
/** An order amendment is a request to amend or update an existing order on Vega */
readonly v1OrderAmendment: {
/**
- * Amend the expiry time for the order, if the Timestamp value is set, otherwise expiry time will remain unchanged
- * - See [`VegaTimeResponse`](#api.VegaTimeResponse).`timestamp`
* Format: int64
+ * @description Amend the expiry time for the order, if the Timestamp value is set, otherwise expiry time will remain unchanged.
*/
readonly expiresAt?: string;
- /** Market identifier, this is required to find the order and will not be updated */
+ /** @description Market ID, this is required to find the order and will not be updated. */
readonly marketId?: string;
- /** Order identifier, this is required to find the order and will not be updated, required field */
+ /** @description Order ID, this is required to find the order and will not be updated, required field. */
readonly orderId?: string;
- /** Amend the pegged order offset for the order */
+ /** @description Amend the pegged order offset for the order. This field is an unsigned integer scaled to the market's decimal places. */
readonly peggedOffset?: string;
- /**
- * Amend the pegged order reference for the order
- * - See [`PeggedReference`](#vega.PeggedReference)
- */
+ /** @description Amend the pegged order reference for the order. */
readonly peggedReference?: components['schemas']['vegaPeggedReference'];
- /** Amend the price for the order, if the Price value is set, otherwise price will remain unchanged - See [`Price`](#vega.Price) */
+ /**
+ * @description Amend the price for the order if the price value is set, otherwise price will remain unchanged.
+ * This field is an unsigned integer scaled to the market's decimal places.
+ */
readonly price?: string;
/**
- * Amend the size for the order by the delta specified:
+ * Format: int64
+ * @description Amend the size for the order by the delta specified:
* - To reduce the size from the current value set a negative integer value
* - To increase the size from the current value, set a positive integer value
* - To leave the size unchanged set a value of zero
- * Format: int64
+ * This field needs to be scaled using the market's position decimal places.
*/
readonly sizeDelta?: string;
- /**
- * Amend the time in force for the order, set to TIME_IN_FORCE_UNSPECIFIED to remain unchanged
- * - See [`TimeInForce`](#api.VegaTimeResponse).`timestamp`
- */
+ /** @description Amend the time in force for the order, set to TIME_IN_FORCE_UNSPECIFIED to remain unchanged. */
readonly timeInForce?: components['schemas']['OrderTimeInForce'];
};
- /** An order cancellation is a request to cancel an existing order on Vega */
+ /** Order cancellation is a request to cancel an existing order on Vega */
readonly v1OrderCancellation: {
- /** Market identifier for the order, required field */
+ /** @description Market ID for the order, required field. */
readonly marketId?: string;
- /** Unique identifier for the order (set by the system after consensus), required field */
+ /** @description Unique ID for the order. This is set by the system after consensus. Required field. */
readonly orderId?: string;
};
- /** An order submission is a request to submit or create a new order on Vega */
+ /** Order submission is a request to submit or create a new order on Vega */
readonly v1OrderSubmission: {
/**
- * Timestamp for when the order will expire, in nanoseconds since the epoch,
- * required field only for `Order.TimeInForce`.TIME_IN_FORCE_GTT`
- * - See `VegaTimeResponse`.`timestamp`
* Format: int64
+ * @description Timestamp for when the order will expire, in nanoseconds,
+ * required field only for `Order.TimeInForce`.TIME_IN_FORCE_GTT`.
*/
readonly expiresAt?: string;
- /** Market identifier for the order, required field */
+ /** @description Market ID for the order, required field. */
readonly marketId?: string;
- /**
- * Used to specify the details for a pegged order
- * - See `PeggedOrder`
- */
+ /** @description Used to specify the details for a pegged order. */
readonly peggedOrder?: components['schemas']['vegaPeggedOrder'];
+ /** @description Only valid for Limit orders. Cannot be True at the same time as Reduce-Only. */
+ readonly postOnly?: boolean;
/**
- * Price for the order, the price is an integer, for example `123456` is a correctly
+ * @description Price for the order, the price is an integer, for example `123456` is a correctly
* formatted price of `1.23456` assuming market configured to 5 decimal places,
- * , required field for limit orders, however it is not required for market orders
+ * required field for limit orders, however it is not required for market orders.
+ * This field is an unsigned integer scaled to the market's decimal places.
*/
readonly price?: string;
/**
- * Reference given for the order, this is typically used to retrieve an order submitted through consensus, currently
- * set internally by the node to return a unique reference identifier for the order submission
+ * @description Only valid for Non-Persistent orders. Cannot be True at the same time as Post-Only.
+ * If set, order will only be executed if the outcome of the trade moves the trader's position closer to 0.
+ */
+ readonly reduceOnly?: boolean;
+ /**
+ * @description Reference given for the order, this is typically used to retrieve an order submitted through consensus, currently
+ * set internally by the node to return a unique reference ID for the order submission.
*/
readonly reference?: string;
- /**
- * Side for the order, e.g. SIDE_BUY or SIDE_SELL, required field
- * - See `Side`
- */
+ /** @description Side for the order, e.g. SIDE_BUY or SIDE_SELL, required field. */
readonly side?: components['schemas']['vegaSide'];
/**
- * Size for the order, for example, in a futures market the size equals the number of units, cannot be negative
* Format: uint64
+ * @description Size for the order, for example, in a futures market the size equals the number of units, cannot be negative.
*/
readonly size?: string;
- /**
- * Time in force indicates how long an order will remain active before it is executed or expires, required field
- * - See `Order.TimeInForce`
- */
+ /** @description Time in force indicates how long an order will remain active before it is executed or expires, required field. */
readonly timeInForce?: components['schemas']['OrderTimeInForce'];
- /** Type for the order, required field - See `Order.Type` */
+ /** @description Type for the order, required field - See `Order.Type`. */
readonly type?: components['schemas']['vegaOrderType'];
};
/** @description PropertyKey describes the property key contained in data source data. */
readonly v1PropertyKey: {
- /** @description name is the name of the property. */
+ /** @description Name of the property. */
readonly name?: string;
/**
- * An optional decimal place to be be applied on the provided value
+ * Optional decimal place to be be applied on the provided value
* valid only for PropertyType of type DECIMAL and INTEGER
* Format: uint64
*/
readonly numberDecimalPlaces?: string;
- /** @description type is the type of the property. */
+ /** @description Data type of the property. */
readonly type?: components['schemas']['v1PropertyKeyType'];
};
/**
- * @description Type describes the type of properties that are supported by the data source
+ * @description Type describes the data type of properties that are supported by the data source
* engine.
*
* - TYPE_UNSPECIFIED: The default value.
@@ -678,25 +671,25 @@ export interface components {
| 'TYPE_DECIMAL'
| 'TYPE_TIMESTAMP';
/**
- * A command to submit a new proposal for the
+ * Command to submit a new proposal for the
* Vega network governance
*/
readonly v1ProposalSubmission: {
- /** @description The rationale behind a proposal. */
+ /** @description Rationale behind a proposal. */
readonly rationale?: components['schemas']['vegaProposalRationale'];
- /** Proposal reference */
+ /** @description Reference identifying the proposal. */
readonly reference?: string;
- /** Proposal configuration and the actual change that is meant to be executed when proposal is enacted */
+ /** @description Proposal configuration and the actual change that is meant to be executed when proposal is enacted. */
readonly terms?: components['schemas']['vegaProposalTerms'];
};
- /** A transaction for a validator to suggest a protocol upgrade */
+ /** Transaction for a validator to suggest a protocol upgrade */
readonly v1ProtocolUpgradeProposal: {
/**
- * The block height at which to perform the upgrade
* Format: uint64
+ * @description Block height at which to perform the upgrade.
*/
readonly upgradeBlockHeight?: string;
- /** the release tag for the Vega binary */
+ /** @description Release tag for the Vega binary. */
readonly vegaReleaseTag?: string;
};
/**
@@ -708,86 +701,91 @@ export interface components {
};
/** Specific details for a recurring transfer */
readonly v1RecurringTransfer: {
- /** optional parameter defining how a transfer is dispatched */
+ /** @description Optional parameter defining how a transfer is dispatched. */
readonly dispatchStrategy?: components['schemas']['vegaDispatchStrategy'];
/**
- * The last epoch at which this transfer shall be paid
* Format: uint64
+ * @description Last epoch at which this transfer shall be paid.
*/
readonly endEpoch?: string;
- /** factor needs to be > 0 */
+ /** @description Factor needs to be > 0. */
readonly factor?: string;
/**
- * The first epoch from which this transfer shall be paid
* Format: uint64
+ * @description First epoch from which this transfer shall be paid.
*/
readonly startEpoch?: string;
};
/**
- * @description A signature to authenticate a transaction and to be verified by the Vega
+ * @description Signature to authenticate a transaction and to be verified by the Vega
* network.
*/
readonly v1Signature: {
- /** @description The algorithm used to create the signature. */
+ /** @description Algorithm used to create the signature. */
readonly algo?: string;
- /** @description The bytes of the signature (hex-encoded). */
+ /** @description Hex encoded bytes of the signature. */
readonly value?: string;
/**
* Format: int64
- * @description The version of the signature used to create the signature.
+ * @description Version of the signature used to create the signature.
*/
readonly version?: number;
};
readonly v1Signer: {
- /** in case of an open oracle - Ethereum address will be submitted */
+ /** In case of an open oracle - Ethereum address will be submitted */
readonly ethAddress?: components['schemas']['v1ETHAddress'];
/**
- * @description pubKeys is the list of authorized public keys that signed the data for this
+ * @description List of authorized public keys that signed the data for this
* source. All the public keys in the data should be contained in these
* public keys.
*/
readonly pubKey?: components['schemas']['v1PubKey'];
};
- /** A transaction for a validator to submit a floating point value */
+ /** Transaction for a validator to submit a floating point value */
readonly v1StateVariableProposal: {
- /** The state value proposal details */
+ /** @description State value proposal details. */
readonly proposal?: components['schemas']['vegaStateValueProposal'];
};
readonly v1UndelegateSubmission: {
- /** optional, if not specified = ALL */
+ /**
+ * @description Optional, if not specified = ALL.
+ * If provided, this field must be an unsigned integer passed as a string
+ * and needs to be scaled using the asset decimal places for the token.
+ */
readonly amount?: string;
+ /** @description Method of delegation. */
readonly method?: components['schemas']['UndelegateSubmissionMethod'];
+ /** @description Node ID to delegate to. */
readonly nodeId?: string;
};
/**
- * A message from a validator signalling they are still online and validating blocks
+ * Message from a validator signalling they are still online and validating blocks
* or ready to validate blocks when they are still a pending validator
*/
readonly v1ValidatorHeartbeat: {
- /** Signature from the validator made using the ethereum wallet */
+ /** @description Signature from the validator made using the ethereum wallet. */
readonly ethereumSignature?: components['schemas']['v1Signature'];
- /** the id of the node emitting the heartbeat */
+ /** @description Message which has been signed. */
+ readonly message?: string;
+ /** @description Node ID of the validator emitting the heartbeat. */
readonly nodeId?: string;
- /** Signature from the validator made using the vega wallet */
+ /** @description Signature from the validator made using the vega wallet. */
readonly vegaSignature?: components['schemas']['v1Signature'];
};
- /**
- * @description A command to submit a new vote for a governance
- * proposal.
- */
+ /** @description Command to submit a new vote for a governance proposal. */
readonly v1VoteSubmission: {
- /** @description The ID of the proposal to vote for. */
+ /** @description Submit vote for the specified proposal ID. */
readonly proposalId?: string;
- /** The actual value of the vote */
+ /** @description Actual value of the vote. */
readonly value?: components['schemas']['vegaVoteValue'];
};
/** Represents the submission request to withdraw funds for a party on Vega */
readonly v1WithdrawSubmission: {
- /** The amount to be withdrawn */
+ /** @description Amount to be withdrawn. This field is an unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
- /** The asset to be withdrawn */
+ /** @description Asset to be withdrawn. */
readonly asset?: string;
- /** Foreign chain specifics */
+ /** @description Foreign chain specifics. */
readonly ext?: components['schemas']['vegaWithdrawExt'];
};
/**
@@ -797,10 +795,10 @@ export interface components {
* - ACCOUNT_TYPE_SETTLEMENT: Settlement accounts exist only during settlement or mark-to-market
* - ACCOUNT_TYPE_MARGIN: Margin accounts contain funds set aside for the margin needed to support a party's open positions.
* Each party will have a margin account for each market they have traded in.
- * The required initial margin is allocated to each market from your general account.
+ * Required initial margin is allocated to each market from user's general account.
* Collateral in the margin account can't be withdrawn or used as margin on another market until
* it is released back to the general account.
- * The Vega protocol uses an internal accounting system to segregate funds held as
+ * Vega protocol uses an internal accounting system to segregate funds held as
* margin from other funds to ensure they are never lost or 'double spent'
*
* Margin account funds will vary as margin requirements on positions change
@@ -845,59 +843,59 @@ export interface components {
| 'ACCOUNT_TYPE_REWARD_MAKER_RECEIVED_FEES'
| 'ACCOUNT_TYPE_REWARD_LP_RECEIVED_FEES'
| 'ACCOUNT_TYPE_REWARD_MARKET_PROPOSERS';
- /** The Vega representation of an external asset */
+ /** Vega representation of an external asset */
readonly vegaAssetDetails: {
- /** A built-in asset */
+ /** @description Vega built-in asset. */
readonly builtinAsset?: components['schemas']['vegaBuiltinAsset'];
/**
- * Number of decimal / precision handled by this asset
* Format: uint64
+ * @description Number of decimal / precision handled by this asset.
*/
readonly decimals?: string;
- /** An Ethereum ERC20 asset */
+ /** @description Ethereum ERC20 asset. */
readonly erc20?: components['schemas']['vegaERC20'];
- /** Name of the asset (e.g: Great British Pound) */
+ /** @description Name of the asset (e.g: Great British Pound). */
readonly name?: string;
- /** The minimum economically meaningful amount in the asset */
+ /** @description Minimum economically meaningful amount in the asset. */
readonly quantum?: string;
- /** Symbol of the asset (e.g: GBP) */
+ /** @description Symbol of the asset (e.g: GBP). */
readonly symbol?: string;
};
- /** @description The changes to apply on an existing asset. */
+ /** @description Changes to apply on an existing asset. */
readonly vegaAssetDetailsUpdate: {
- /** An Ethereum ERC20 asset */
+ /** @description Ethereum ERC20 asset update. */
readonly erc20?: components['schemas']['vegaERC20Update'];
- /** The minimum economically meaningful amount in the asset */
+ /** @description Minimum economically meaningful amount in the asset. */
readonly quantum?: string;
};
- /** A Vega internal asset */
+ /** Vega internal asset */
readonly vegaBuiltinAsset: {
- /** Maximum amount that can be requested by a party through the built-in asset faucet at a time */
+ /** @description Maximum amount that can be requested by a party through the built-in asset faucet at a time. */
readonly maxFaucetAmountMint?: string;
};
- /** A deposit for a Vega built-in asset */
+ /** Deposit for a Vega built-in asset */
readonly vegaBuiltinAssetDeposit: {
- /** The amount to be deposited */
+ /** @description Amount to be deposited. This field is an unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
- /** A Vega party identifier (pub-key) */
+ /** @description Vega party ID i.e. public key. */
readonly partyId?: string;
- /** A Vega network internal asset identifier */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
- /** An event related to a Vega built-in asset */
+ /** Event related to a Vega built-in asset */
readonly vegaBuiltinAssetEvent: {
- /** Built-in asset deposit */
+ /** @description Built-in asset deposit. */
readonly deposit?: components['schemas']['vegaBuiltinAssetDeposit'];
- /** Built-in asset withdrawal */
+ /** @description Built-in asset withdrawal. */
readonly withdrawal?: components['schemas']['vegaBuiltinAssetWithdrawal'];
};
- /** A withdrawal for a Vega built-in asset */
+ /** Withdrawal for a Vega built-in asset */
readonly vegaBuiltinAssetWithdrawal: {
- /** The amount to be withdrawn */
+ /** @description The amount to be withdrawn. This field is an unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
- /** A Vega network party identifier (pub-key) */
+ /** @description Vega network party ID i.e. public key. */
readonly partyId?: string;
- /** A Vega network internal asset identifier */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
/**
@@ -929,12 +927,12 @@ export interface components {
*/
readonly vegaDataSourceSpecConfiguration: {
/**
- * @description filters describes which source data are considered of interest or not for
+ * @description Filters describes which source data are considered of interest or not for
* the product (or the risk model).
*/
readonly filters?: readonly components['schemas']['v1Filter'][];
/**
- * @description signers is the list of authorized signatures that signed the data for this
+ * @description Signers is the list of authorized signatures that signed the data for this
* source. All the signatures in the data source data should be contained in this
* external source. All the signatures in the data should be contained in this list.
*/
@@ -951,13 +949,12 @@ export interface components {
*/
readonly vegaDataSourceSpecToFutureBinding: {
/**
- * @description settlement_data_property holds the name of the property in the source data
- * that should be used as settlement data.
+ * @description Name of the property in the source data that should be used as settlement data.
* If it is set to "prices.BTC.value", then the Future will use the value of
* this property as settlement data.
*/
readonly settlementDataProperty?: string;
- /** the name of the property in the data source data that signals termination of trading */
+ /** @description Name of the property in the data source data that signals termination of trading. */
readonly tradingTerminationProperty?: string;
};
/**
@@ -975,93 +972,93 @@ export interface components {
| 'DISPATCH_METRIC_LP_FEES_RECEIVED'
| 'DISPATCH_METRIC_MARKET_VALUE';
readonly vegaDispatchStrategy: {
- /** The asset to use for metric */
+ /** @description Asset to use for metric. */
readonly assetForMetric?: string;
- /** Optional markets in scope */
+ /** @description Optional markets in scope. */
readonly markets?: readonly string[];
- /** The metric to apply */
+ /** @description Metric to apply. */
readonly metric?: components['schemas']['vegaDispatchMetric'];
};
- /** An ERC20 token based asset, living on the ethereum network */
+ /** ERC20 token based asset, living on the ethereum network */
readonly vegaERC20: {
- /** The address of the contract for the token, on the ethereum network */
+ /** @description Address of the contract for the token, on the ethereum network. */
readonly contractAddress?: string;
/**
- * The lifetime limits deposit per address
- * note: this is a temporary measure that can be changed by governance
+ * @description Lifetime limits deposit per address
+ * note: this is a temporary measure that can be changed by governance.
*/
readonly lifetimeLimit?: string;
/**
- * The maximum you can withdraw instantly. All withdrawals over the threshold will be delayed by the withdrawal delay.
+ * @description Maximum you can withdraw instantly. All withdrawals over the threshold will be delayed by the withdrawal delay.
* There’s no limit on the size of a withdrawal
- * note: this is a temporary measure that can be changed by governance
+ * note: this is a temporary measure that can be changed by governance.
*/
readonly withdrawThreshold?: string;
};
- /** An asset deny-listing for an ERC20 token */
+ /** Asset deny-listing for an ERC20 token */
readonly vegaERC20AssetDelist: {
- /** The Vega network internal identifier of the asset */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
readonly vegaERC20AssetLimitsUpdated: {
- /** The updated lifetime limits */
+ /** @description Updated lifetime limits. */
readonly lifetimeLimits?: string;
- /** The Ethereum wallet that initiated the deposit */
+ /** @description Ethereum wallet that initiated the deposit. */
readonly sourceEthereumAddress?: string;
- /** The Vega network internal identifier of the asset */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
- /** The updated withdrawal threshold */
+ /** @description Updated withdrawal threshold. */
readonly withdrawThreshold?: string;
};
- /** An asset allow-listing for an ERC20 token */
+ /** Asset allow-listing for an ERC20 token */
readonly vegaERC20AssetList: {
- /** The ethereum address of the asset */
+ /** @description Ethereum address of the asset. */
readonly assetSource?: string;
- /** The Vega network internal identifier of the asset */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
- /** An asset deposit for an ERC20 token */
+ /** Asset deposit for an ERC20 token */
readonly vegaERC20Deposit: {
- /** The amount to be deposited */
+ /** @description Amount to be deposited. */
readonly amount?: string;
- /** The Ethereum wallet that initiated the deposit */
+ /** @description Ethereum wallet that initiated the deposit. */
readonly sourceEthereumAddress?: string;
- /** The Vega party identifier (pub-key) which is the target of the deposit */
+ /** @description Vega party ID i.e. public key that is the target of the deposit. */
readonly targetPartyId?: string;
- /** The vega network internal identifier of the asset */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
- /** An event related to an ERC20 token */
+ /** Event related to an ERC20 token */
readonly vegaERC20Event: {
- /** De-list an ERC20 asset */
+ /** @description De-list an ERC20 asset. */
readonly assetDelist?: components['schemas']['vegaERC20AssetDelist'];
- /** Update an ERC20 asset */
+ /** @description Update an ERC20 asset. */
readonly assetLimitsUpdated?: components['schemas']['vegaERC20AssetLimitsUpdated'];
- /** List an ERC20 asset */
+ /** @description List an ERC20 asset. */
readonly assetList?: components['schemas']['vegaERC20AssetList'];
/**
- * The block in which the transaction was added
* Format: uint64
+ * @description Block in which the transaction was added.
*/
readonly block?: string;
- /** Bridge operations has been resumed */
+ /** @description Bridge operations has been resumed. */
readonly bridgeResumed?: boolean;
- /** Bridge operations has been stopped */
+ /** @description Bridge operations has been stopped. */
readonly bridgeStopped?: boolean;
- /** Deposit ERC20 asset */
+ /** @description Deposit ERC20 asset. */
readonly deposit?: components['schemas']['vegaERC20Deposit'];
/**
- * Index of the log in the transaction
* Format: uint64
+ * @description Index of the log in the transaction.
*/
readonly index?: string;
- /** Withdraw ERC20 asset */
+ /** @description Withdraw ERC20 asset. */
readonly withdrawal?: components['schemas']['vegaERC20Withdrawal'];
};
- /** An event related to the ERC20 MultiSig */
+ /** Event related to the ERC20 MultiSig */
readonly vegaERC20MultiSigEvent: {
/**
- * The block in which the transaction was added
+ * Block in which the transaction was added
* Format: uint64
*/
readonly block?: string;
@@ -1077,99 +1074,99 @@ export interface components {
/** Threshold set */
readonly thresholdSet?: components['schemas']['vegaERC20ThresholdSet'];
};
- /** A new signer added to the ERC20 bridge */
+ /** New signer added to the ERC20 bridge */
readonly vegaERC20SignerAdded: {
/**
* Format: int64
- * @description The time at which the block was produced
+ * @description Time at which the block was produced
* will be used to inform the core at what time
* the stake was made unavailable.
*/
readonly blockTime?: string;
- /** The ethereum address of the new signer */
+ /** Ethereum address of the new signer */
readonly newSigner?: string;
- /** The nonce create by the vega network used for this new signer */
+ /** Nonce created by the Vega network used for this new signer */
readonly nonce?: string;
};
- /** A signer removed from the ERC20 bridge */
+ /** Signer removed from the ERC20 bridge */
readonly vegaERC20SignerRemoved: {
/**
* Format: int64
- * @description The time at which the block was produced
- * will be used to inform the core at what time
+ * @description Time at which the block was produced.
+ * Will be used to inform the core at what time
* the stake was made unavailable.
*/
readonly blockTime?: string;
- /** The nonce create by the vega network used for this old signer */
+ /** Nonce created by the Vega network used for this old signer */
readonly nonce?: string;
- /** The ethereum address of the old signer */
+ /** Ethereum address of the old signer */
readonly oldSigner?: string;
};
- /** The threshold has been updated on the multisig control */
+ /** Threshold has been updated on the multisig control */
readonly vegaERC20ThresholdSet: {
/**
* Format: int64
- * @description The time at which the block was produced
- * will be used to inform the core at what time
+ * @description Time at which the block was produced.
+ * Will be used to inform the core at what time
* the stake was made unavailable.
*/
readonly blockTime?: string;
/**
- * The new threshold
+ * New threshold value to set
* Format: int64
*/
readonly newThreshold?: number;
- /** The nonce created by the Vega network */
+ /** Nonce created by the Vega network */
readonly nonce?: string;
};
readonly vegaERC20Update: {
/**
- * The lifetime limits deposit per address.
+ * @description Lifetime limits deposit per address.
* This will be interpreted against the asset decimals.
- * note: this is a temporary measure that can be changed by governance
+ * note: this is a temporary measure that can be changed by governance.
*/
readonly lifetimeLimit?: string;
/**
- * The maximum you can withdraw instantly. All withdrawals over the threshold will be delayed by the withdrawal delay.
+ * @description Maximum you can withdraw instantly. All withdrawals over the threshold will be delayed by the withdrawal delay.
* There’s no limit on the size of a withdrawal
- * note: this is a temporary measure that can be changed by governance
+ * note: this is a temporary measure that can be changed by governance.
*/
readonly withdrawThreshold?: string;
};
- /** An asset withdrawal for an ERC20 token */
+ /** Asset withdrawal for an ERC20 token */
readonly vegaERC20Withdrawal: {
- /** The reference nonce used for the transaction */
+ /** @description Reference nonce used for the transaction. */
readonly referenceNonce?: string;
- /** The target Ethereum wallet address */
+ /** @description Target Ethereum wallet address. */
readonly targetEthereumAddress?: string;
- /** The Vega network internal identifier of the asset */
+ /** @description Vega network internal asset ID. */
readonly vegaAssetId?: string;
};
- /** An extension of data required for the withdraw submissions */
+ /** Extension of data required for the withdraw submissions */
readonly vegaErc20WithdrawExt: {
- /** The address into which the bridge will release the funds */
+ /** @description Address into which the bridge will release the funds. */
readonly receiverAddress?: string;
};
/** Future product configuration */
readonly vegaFutureProduct: {
- /** The binding between the data source spec and the settlement data */
+ /** @description Binding between the data source spec and the settlement data. */
readonly dataSourceSpecBinding?: components['schemas']['vegaDataSourceSpecToFutureBinding'];
- /** The data source spec describing the data source for settlement */
+ /** @description Data source spec describing the data source for settlement. */
readonly dataSourceSpecForSettlementData?: components['schemas']['vegaDataSourceDefinition'];
- /** The external data source spec describing the data source of trading termination */
+ /** @description The external data source spec describing the data source of trading termination. */
readonly dataSourceSpecForTradingTermination?: components['schemas']['vegaDataSourceDefinition'];
- /** Product quote name */
+ /** @description Product quote name. */
readonly quoteName?: string;
- /** Asset ID for the product's settlement asset */
+ /** @description Asset ID for the product's settlement asset. */
readonly settlementAsset?: string;
};
/** Instrument configuration */
readonly vegaInstrumentConfiguration: {
- /** Instrument code, human-readable shortcode used to describe the instrument */
+ /** @description Instrument code, human-readable shortcode used to describe the instrument. */
readonly code?: string;
- /** Future */
+ /** @description Future. */
readonly future?: components['schemas']['vegaFutureProduct'];
- /** Instrument name */
+ /** @description Instrument name. */
readonly name?: string;
};
readonly vegaKeyValueBundle: {
@@ -1180,57 +1177,58 @@ export interface components {
/** LiquidityMonitoringParameters contains settings used for liquidity monitoring */
readonly vegaLiquidityMonitoringParameters: {
/**
- * Specifies by how many seconds an auction should be extended if leaving the auction were to trigger a liquidity auction
* Format: int64
+ * @description Specifies by how many seconds an auction should be extended if leaving the auction were to trigger a liquidity auction.
*/
readonly auctionExtension?: string;
- /** Specifies parameters related to target stake calculation */
+ /** @description Specifies parameters related to target stake calculation. */
readonly targetStakeParameters?: components['schemas']['vegaTargetStakeParameters'];
- /** Specifies the triggering ratio for entering liquidity auction */
+ /** @description Specifies the triggering ratio for entering liquidity auction. */
readonly triggeringRatio?: string;
};
/** Represents a liquidity order */
readonly vegaLiquidityOrder: {
- /** The offset/amount of units away for the order */
+ /** @description Offset/amount of units away for the order. This field is an unsigned integer scaled using the market's decimal places. */
readonly offset?: string;
/**
- * The relative proportion of the commitment to be allocated at a price level
* Format: int64
+ * @description Relative proportion of the commitment to be allocated at a price level.
*/
readonly proportion?: number;
- /** The pegged reference point for the order */
+ /** @description Pegged reference point for the order. */
readonly reference?: components['schemas']['vegaPeggedReference'];
};
/** Risk model parameters for log normal */
readonly vegaLogNormalModelParams: {
/**
- * Mu parameter, annualised growth rate of the underlying asset
* Format: double
+ * @description Mu parameter, annualised growth rate of the underlying asset.
*/
readonly mu?: number;
/**
- * R parameter, annualised growth rate of the risk-free asset, used for discounting of future cash flows, can be any real number
* Format: double
+ * @description R parameter, annualised growth rate of the risk-free asset, used for discounting of future cash flows, can be any real number.
*/
readonly r?: number;
/**
- * Sigma parameter, annualised volatility of the underlying asset, must be a strictly non-negative real number
* Format: double
+ * @description Sigma parameter, annualised volatility of the underlying asset, must be a strictly non-negative real number.
*/
readonly sigma?: number;
};
/** Risk model for log normal */
readonly vegaLogNormalRiskModel: {
- /** Risk model parameters for log normal */
+ /** @description Risk model parameters for log normal. */
readonly params?: components['schemas']['vegaLogNormalModelParams'];
/**
- * Risk Aversion Parameter
* Format: double
+ * @description Risk Aversion Parameter.
*/
readonly riskAversionParameter?: number;
/**
- * Tau parameter of the risk model, projection horizon measured as a year fraction used in the expected shortfall calculation to obtain the maintenance margin, must be a strictly non-negative real number
* Format: double
+ * @description Tau parameter of the risk model, projection horizon measured as a year fraction used in the expected shortfall
+ * calculation to obtain the maintenance margin, must be a strictly non-negative real number.
*/
readonly tau?: number;
};
@@ -1239,14 +1237,14 @@ export interface components {
};
/** Represents a network parameter on Vega */
readonly vegaNetworkParameter: {
- /** The unique key */
+ /** @description Unique key of the network parameter. */
readonly key?: string;
- /** The value for the network parameter */
+ /** @description Value for the network parameter. */
readonly value?: string;
};
/** New asset on Vega */
readonly vegaNewAsset: {
- /** The configuration of the new asset */
+ /** @description Configuration of the new asset. */
readonly changes?: components['schemas']['vegaAssetDetails'];
};
/**
@@ -1257,37 +1255,41 @@ export interface components {
readonly vegaNewFreeform: Record;
/** New market on Vega */
readonly vegaNewMarket: {
- /** The configuration of the new market */
+ /** @description Configuration of the new market. */
readonly changes?: components['schemas']['vegaNewMarketConfiguration'];
};
/** Configuration for a new market on Vega */
readonly vegaNewMarketConfiguration: {
/**
- * Decimal places used for the new market, sets the smallest price increment on the book
* Format: uint64
+ * @description Decimal places used for the new market, sets the smallest price increment on the book.
*/
readonly decimalPlaces?: string;
- /** New market instrument configuration */
+ /** @description New market instrument configuration. */
readonly instrument?: components['schemas']['vegaInstrumentConfiguration'];
- /** Liquidity monitoring parameters */
+ /** @description Linear slippage factor is used to cap the slippage component of maintenance margin - it is applied to the slippage volume. */
+ readonly linearSlippageFactor?: string;
+ /** @description Liquidity monitoring parameters. */
readonly liquidityMonitoringParameters?: components['schemas']['vegaLiquidityMonitoringParameters'];
- /** Log normal risk model parameters, valid only if MODEL_LOG_NORMAL is selected */
+ /** @description Log normal risk model parameters, valid only if MODEL_LOG_NORMAL is selected. */
readonly logNormal?: components['schemas']['vegaLogNormalRiskModel'];
/**
- * Percentage move up and down from the mid price which specifies the range of
- * price levels over which automated liquidity provision orders will be deployed
+ * @description Percentage move up and down from the mid price which specifies the range of
+ * price levels over which automated liquidity provision orders will be deployed.
*/
readonly lpPriceRange?: string;
- /** Optional new market metadata, tags */
+ /** @description Optional new market metadata, tags. */
readonly metadata?: readonly string[];
/**
- * Decimal places for order sizes, sets what size the smallest order / position on the market can be
* Format: int64
+ * @description Decimal places for order sizes, sets what size the smallest order / position on the market can be.
*/
readonly positionDecimalPlaces?: string;
- /** Price monitoring parameters */
+ /** @description Price monitoring parameters. */
readonly priceMonitoringParameters?: components['schemas']['vegaPriceMonitoringParameters'];
- /** Simple risk model parameters, valid only if MODEL_SIMPLE is selected */
+ /** @description Quadratic slippage factor is used to cap the slippage component of maintenance margin - it is applied to the square of the slippage volume. */
+ readonly quadraticSlippageFactor?: string;
+ /** @description Simple risk model parameters, valid only if MODEL_SIMPLE is selected. */
readonly simple?: components['schemas']['vegaSimpleModelParams'];
};
/**
@@ -1309,13 +1311,13 @@ export interface components {
* They can be used for any limit order that is valid during continuous trading
*/
readonly vegaPeggedOrder: {
- /** Offset from the price reference */
+ /** @description Offset from the price reference. */
readonly offset?: string;
- /** The price point the order is linked to */
+ /** @description Price point the order is linked to. */
readonly reference?: components['schemas']['vegaPeggedReference'];
};
/**
- * A pegged reference defines which price point a pegged order is linked to - meaning
+ * Pegged reference defines which price point a pegged order is linked to - meaning
* the price for a pegged order is calculated from the value of the reference price point
* @description - PEGGED_REFERENCE_UNSPECIFIED: Default value for PeggedReference, no reference given
* - PEGGED_REFERENCE_MID: Mid price reference
@@ -1336,21 +1338,21 @@ export interface components {
/** PriceMonitoringTrigger holds together price projection horizon τ, probability level p, and auction extension duration */
readonly vegaPriceMonitoringTrigger: {
/**
- * Price monitoring auction extension duration in seconds should the price
- * breach its theoretical level over the specified horizon at the specified
- * probability level
* Format: int64
+ * @description Price monitoring auction extension duration in seconds should the price
+ * breach its theoretical level over the specified horizon at the specified
+ * probability level.
*/
readonly auctionExtension?: string;
/**
- * Price monitoring projection horizon τ in seconds
* Format: int64
+ * @description Price monitoring projection horizon τ in seconds.
*/
readonly horizon?: string;
- /** Price monitoring probability level p */
+ /** @description Price monitoring probability level p. */
readonly probability?: string;
};
- /** @description The rationale behind a proposal. */
+ /** @description Rationale behind a proposal. */
readonly vegaProposalRationale: {
/**
* @description Description to show a short title / something in case the link goes offline.
@@ -1368,35 +1370,35 @@ export interface components {
/** Terms for a governance proposal on Vega */
readonly vegaProposalTerms: {
/**
- * Timestamp (Unix time in seconds) when voting closes for this proposal,
- * constrained by `minClose` and `maxClose` network parameters
* Format: int64
+ * @description Timestamp as Unix time in seconds when voting closes for this proposal,
+ * constrained by `minClose` and `maxClose` network parameters.
*/
readonly closingTimestamp?: string;
/**
- * Timestamp (Unix time in seconds) when proposal gets enacted (if passed),
- * constrained by `minEnact` and `maxEnact` network parameters
* Format: int64
+ * @description Timestamp as Unix time in seconds when proposal gets enacted if passed,
+ * constrained by `minEnact` and `maxEnact` network parameters.
*/
readonly enactmentTimestamp?: string;
- /** Proposal change for creating new assets on Vega */
+ /** @description Proposal change for creating new assets on Vega. */
readonly newAsset?: components['schemas']['vegaNewAsset'];
/**
- * Proposal change for a freeform request, which can be voted on but does not change the behaviour of the system,
- * and can be used to gauge community sentiment
+ * @description Proposal change for a freeform request, which can be voted on but does not change the behaviour of the system,
+ * and can be used to gauge community sentiment.
*/
readonly newFreeform?: components['schemas']['vegaNewFreeform'];
- /** Proposal change for creating new market on Vega */
+ /** @description Proposal change for creating new market on Vega. */
readonly newMarket?: components['schemas']['vegaNewMarket'];
- /** Proposal change for updating an asset */
+ /** @description Proposal change for updating an asset. */
readonly updateAsset?: components['schemas']['vegaUpdateAsset'];
- /** Proposal change for modifying an existing market on Vega */
+ /** @description Proposal change for modifying an existing market on Vega. */
readonly updateMarket?: components['schemas']['vegaUpdateMarket'];
- /** Proposal change for updating Vega network parameters */
+ /** @description Proposal change for updating Vega network parameters. */
readonly updateNetworkParameter?: components['schemas']['vegaUpdateNetworkParameter'];
/**
- * Validation timestamp (Unix time in seconds)
* Format: int64
+ * @description Validation timestamp as Unix time in seconds.
*/
readonly validationTimestamp?: string;
};
@@ -1404,7 +1406,7 @@ export interface components {
readonly value?: string;
};
/**
- * A side relates to the direction of an order, to Buy, or Sell
+ * Side relates to the direction of an order, to Buy, or Sell
* @description - SIDE_UNSPECIFIED: Default value, always invalid
* - SIDE_BUY: Buy order
* - SIDE_SELL: Sell order
@@ -1415,48 +1417,48 @@ export interface components {
/** Risk model parameters for simple modelling */
readonly vegaSimpleModelParams: {
/**
- * Pre-defined risk factor value for long
* Format: double
+ * @description Pre-defined risk factor value for long.
*/
readonly factorLong?: number;
/**
- * Pre-defined risk factor value for short
* Format: double
+ * @description Pre-defined risk factor value for short.
*/
readonly factorShort?: number;
/**
- * Pre-defined maximum price move up that the model considers as valid
* Format: double
+ * @description Pre-defined maximum price move up that the model considers as valid.
*/
readonly maxMoveUp?: number;
/**
- * Pre-defined minimum price move down that the model considers as valid
* Format: double
+ * @description Pre-defined minimum price move down that the model considers as valid.
*/
readonly minMoveDown?: number;
/**
- * Pre-defined constant probability of trading
* Format: double
+ * @description Pre-defined constant probability of trading.
*/
readonly probabilityOfTrading?: number;
};
readonly vegaStakeDeposited: {
- /** The amount deposited (base 10) */
+ /** @description Amount deposited as an unsigned base 10 integer scaled to the asset's decimal places. */
readonly amount?: string;
/**
* Format: int64
- * @description The time at which the block was produced
- * will be used to inform the core at what time
+ * @description Time at which the block was produced.
+ * Will be used to inform the core at what time
* the stake started to be available.
*/
readonly blockTime?: string;
/** Ethereum Address of the user depositing stake (hex encode with 0x prefix) */
readonly ethereumAddress?: string;
- /** The public of the party receiving the stake deposit (hex encode) */
+ /** @description Hex encoded public key of the party receiving the stake deposit. */
readonly vegaPublicKey?: string;
};
readonly vegaStakeRemoved: {
- /** The amount removed (base 10) */
+ /** @description Amount removed as a base 10 unsigned integer scaled to the asset's decimal places. */
readonly amount?: string;
/**
* Format: int64
@@ -1465,26 +1467,27 @@ export interface components {
* the stake was made unavailable.
*/
readonly blockTime?: string;
- /** Ethereum address of the user removing stake (hex encode with 0x prefix) */
+ /** @description Ethereum address of the user removing stake. This should be hex encoded with 0x prefix. */
readonly ethereumAddress?: string;
- /** The public key of the party from which to remove stake (hex encode) */
+ /** @description Hex encoded public key of the party from which to remove stake. */
readonly vegaPublicKey?: string;
};
readonly vegaStakeTotalSupply: {
- /** The address of the staking asset */
+ /** Address of the staking asset */
readonly tokenAddress?: string;
- /** The total supply observed for the token */
+ /** @description Total supply observed for the token as an unsigned based 10 integer scaled to the asset's decimal places. */
readonly totalSupply?: string;
};
+ /** @description Event related to staking on the Vega network. */
readonly vegaStakingEvent: {
/**
- * The block in which the transaction was added
* Format: uint64
+ * @description Block in which the transaction was added.
*/
readonly block?: string;
/**
- * Index of the log in the transaction
* Format: uint64
+ * @description Index of the log in the transaction.
*/
readonly index?: string;
readonly stakeDeposited?: components['schemas']['vegaStakeDeposited'];
@@ -1492,11 +1495,11 @@ export interface components {
readonly totalSupply?: components['schemas']['vegaStakeTotalSupply'];
};
readonly vegaStateValueProposal: {
- /** event identifier */
+ /** @description Event ID. */
readonly eventId?: string;
- /** key value tolerance triplets */
+ /** @description Key value tolerance triplets. */
readonly kvb?: readonly components['schemas']['vegaKeyValueBundle'][];
- /** state variable identifier */
+ /** @description State variable ID. */
readonly stateVarId?: string;
};
readonly vegaStateVarValue: {
@@ -1507,71 +1510,75 @@ export interface components {
/** TargetStakeParameters contains parameters used in target stake calculation */
readonly vegaTargetStakeParameters: {
/**
- * Specifies scaling factors used in target stake calculation
* Format: double
+ * @description Specifies scaling factors used in target stake calculation.
*/
readonly scalingFactor?: number;
/**
- * Specifies length of time window expressed in seconds for target stake calculation
* Format: int64
+ * @description Specifies length of time window expressed in seconds for target stake calculation.
*/
readonly timeWindow?: string;
};
/** Update an existing asset on Vega */
readonly vegaUpdateAsset: {
- /** The ID of the asset to be updated */
+ /** @description Asset ID the update is for. */
readonly assetId?: string;
- /** The changes to apply on an existing asset */
+ /** @description Changes to apply on an existing asset. */
readonly changes?: components['schemas']['vegaAssetDetailsUpdate'];
};
/** Future product configuration */
readonly vegaUpdateFutureProduct: {
- /** The binding between the data source spec and the settlement data */
+ /** @description The binding between the data source spec and the settlement data. */
readonly dataSourceSpecBinding?: components['schemas']['vegaDataSourceSpecToFutureBinding'];
- /** The data source spec describing the data of settlement data */
+ /** @description The data source spec describing the data of settlement data. */
readonly dataSourceSpecForSettlementData?: components['schemas']['vegaDataSourceDefinition'];
- /** The data source spec describing the data source for trading termination */
+ /** @description The data source spec describing the data source for trading termination. */
readonly dataSourceSpecForTradingTermination?: components['schemas']['vegaDataSourceDefinition'];
- /** Human-readable name/abbreviation of the quote name */
+ /** @description Human-readable name/abbreviation of the quote name. */
readonly quoteName?: string;
};
/** Instrument configuration */
readonly vegaUpdateInstrumentConfiguration: {
- /** Instrument code, human-readable shortcode used to describe the instrument */
+ /** @description Instrument code, human-readable shortcode used to describe the instrument. */
readonly code?: string;
- /** Future */
+ /** @description Future. */
readonly future?: components['schemas']['vegaUpdateFutureProduct'];
};
/** Update an existing market on Vega */
readonly vegaUpdateMarket: {
- /** The updated configuration of the market */
+ /** @description Updated configuration of the market. */
readonly changes?: components['schemas']['vegaUpdateMarketConfiguration'];
- /** The identifier of the market to update */
+ /** @description Market ID the update is for. */
readonly marketId?: string;
};
/** Configuration to update a market on Vega */
readonly vegaUpdateMarketConfiguration: {
- /** Updated market instrument configuration */
+ /** @description Updated market instrument configuration. */
readonly instrument?: components['schemas']['vegaUpdateInstrumentConfiguration'];
- /** Liquidity monitoring parameters */
+ /** @description Linear slippage factor is used to cap the slippage component of maintenance margin - it is applied to the slippage volume. */
+ readonly linearSlippageFactor?: string;
+ /** @description Liquidity monitoring parameters. */
readonly liquidityMonitoringParameters?: components['schemas']['vegaLiquidityMonitoringParameters'];
- /** Log normal risk model parameters, valid only if MODEL_LOG_NORMAL is selected */
+ /** @description Log normal risk model parameters, valid only if MODEL_LOG_NORMAL is selected. */
readonly logNormal?: components['schemas']['vegaLogNormalRiskModel'];
/**
- * Percentage move up and down from the mid price which specifies the range of
- * price levels over which automated liquidity provision orders will be deployed
+ * @description Percentage move up and down from the mid price which specifies the range of
+ * price levels over which automated liquidity provision orders will be deployed.
*/
readonly lpPriceRange?: string;
- /** Optional market metadata, tags */
+ /** @description Optional market metadata, tags. */
readonly metadata?: readonly string[];
- /** Price monitoring parameters */
+ /** @description Price monitoring parameters. */
readonly priceMonitoringParameters?: components['schemas']['vegaPriceMonitoringParameters'];
- /** Simple risk model parameters, valid only if MODEL_SIMPLE is selected */
+ /** @description Quadratic slippage factor is used to cap the slippage component of maintenance margin - it is applied to the square of the slippage volume. */
+ readonly quadraticSlippageFactor?: string;
+ /** @description Simple risk model parameters, valid only if MODEL_SIMPLE is selected. */
readonly simple?: components['schemas']['vegaSimpleModelParams'];
};
/** Update network configuration on Vega */
readonly vegaUpdateNetworkParameter: {
- /** The network parameter to update */
+ /** @description The network parameter to update. */
readonly changes?: components['schemas']['vegaNetworkParameter'];
};
readonly vegaVectorValue: {
@@ -1580,15 +1587,15 @@ export interface components {
/**
* Vote value
* @description - VALUE_UNSPECIFIED: Default value, always invalid
- * - VALUE_NO: A vote against the proposal
- * - VALUE_YES: A vote in favour of the proposal
+ * - VALUE_NO: Vote against the proposal
+ * - VALUE_YES: Vote in favour of the proposal
* @default VALUE_UNSPECIFIED
* @enum {string}
*/
readonly vegaVoteValue: 'VALUE_UNSPECIFIED' | 'VALUE_NO' | 'VALUE_YES';
/** Withdrawal external details */
readonly vegaWithdrawExt: {
- /** ERC20 withdrawal details */
+ /** @description ERC20 withdrawal details. */
readonly erc20?: components['schemas']['vegaErc20WithdrawExt'];
};
};
@@ -1605,8 +1612,8 @@ export interface operations {
BlockExplorer_Info: {
/**
* Info
- * @description Retrieves information about the block explorer.
- * Response contains a semver formatted version of the data node and the commit hash, from which the block explorer was built,
+ * @description Get information about the block explorer.
+ * Response contains a semver formatted version of the data node and the commit hash, from which the block explorer was built
*/
responses: {
/** @description A successful response. */
@@ -1629,9 +1636,9 @@ export interface operations {
* @description List transactions from the Vega blockchain
*/
parameters?: {
- /** @description The number of transactions to be returned from the blockchain. */
- /** @description An optional cursor to paginate the request. */
- /** @description An optional cursor to paginate the request. */
+ /** @description Number of transactions to be returned from the blockchain. */
+ /** @description Optional cursor to paginate the request. */
+ /** @description Optional cursor to paginate the request. */
readonly query?: {
limit?: number;
before?: string;
@@ -1659,7 +1666,7 @@ export interface operations {
* @description Get a transaction from the Vega blockchain
*/
parameters: {
- /** @description The hash of the transaction */
+ /** @description Hash of the transaction */
readonly path: {
hash: string;
};
diff --git a/libs/ui-toolkit/src/components/dropdown-menu/dropdown-menu.tsx b/libs/ui-toolkit/src/components/dropdown-menu/dropdown-menu.tsx
index 75178ca63..8dcfa217b 100644
--- a/libs/ui-toolkit/src/components/dropdown-menu/dropdown-menu.tsx
+++ b/libs/ui-toolkit/src/components/dropdown-menu/dropdown-menu.tsx
@@ -161,6 +161,51 @@ export const DropdownMenuSeparator = forwardRef<
/>
));
+/**
+ * Container element for submenus
+ */
+export const DropdownMenuSub = forwardRef<
+ React.ElementRef,
+ React.ComponentProps
+>(({ ...subProps }) => );
+
+/**
+ * Container within a DropdownMenuSub specifically for the content
+ */
+export const DropdownMenuSubContent = forwardRef<
+ React.ElementRef,
+ React.ComponentProps
+>(({ className, ...subContentProps }, forwardedRef) => (
+
+));
+
+/**
+ * Equivalent to trigger, but for triggering sub menus
+ */
+export const DropdownMenuSubTrigger = forwardRef<
+ React.ElementRef,
+ React.ComponentProps
+>(({ className, ...subTriggerProps }, forwardedRef) => (
+
+));
+
+/**
+ * Portal to ensure menu portions are rendered outwith where they appear in the
+ * DOM.
+ */
+export const DropdownMenuPortal = forwardRef<
+ React.ElementRef,
+ React.ComponentProps
+>(({ ...portalProps }) => );
+
/**
* Wraps a regular DropdownMenuItem with copy to clip board functionality
*/