Skip to main content
Glama

gmx-mcp

Server Details

Gmx MCP server — 139 tools for AI agent integration. Hosted by Junct.

Status
Healthy
Last Tested
Transport
Streamable HTTP
URL
Repository
junct-bot/gmx-mcp
GitHub Stars
0

See and control every tool call

Log every tool call with full inputs and outputs
Control which tools are enabled per connector
Manage credentials once, use from any MCP client
Monitor uptime and get alerted when servers go down

Available Tools

139 tools
addRouterInspect

Calls addRouter(_router: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_routerYesaddress (Ethereum address, 0x-prefixed).
adjustForDecimalsInspect

Calls adjustForDecimals(_amount: string, _tokenDiv: string, _tokenMul: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_amountYesuint256 (uint256, pass as decimal string).
_tokenDivYesaddress (Ethereum address, 0x-prefixed).
_tokenMulYesaddress (Ethereum address, 0x-prefixed).
allWhitelistedTokensInspect

Calls allWhitelistedTokens(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesuint256 (uint256, pass as decimal string).
allWhitelistedTokensLengthInspect

Calls allWhitelistedTokensLength(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

approvedRoutersInspect

Calls approvedRouters(param0: string, param1: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
param1Yesaddress (Ethereum address, 0x-prefixed).
BASIS_POINTS_DIVISORInspect

Calls BASIS_POINTS_DIVISOR(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

bufferAmountsInspect

Calls bufferAmounts(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
buyUSDGInspect

Calls buyUSDG(_token: string, _receiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_receiverYesaddress (Ethereum address, 0x-prefixed).
BuyUSDGInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
accountYesaddress (Ethereum address, 0x-prefixed).
usdgAmountYesuint256 (uint256, pass as decimal string).
tokenAmountYesuint256 (uint256, pass as decimal string).
feeBasisPointsYesuint256 (uint256, pass as decimal string).
clearTokenConfigInspect

Calls clearTokenConfig(_token: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
ClosePositionInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
keyYesbytes32 (32-byte hex string, 0x-prefixed).
sizeYesuint256 (uint256, pass as decimal string).
collateralYesuint256 (uint256, pass as decimal string).
realisedPnlYesint256 (int256, pass as decimal string).
averagePriceYesuint256 (uint256, pass as decimal string).
reserveAmountYesuint256 (uint256, pass as decimal string).
entryFundingRateYesuint256 (uint256, pass as decimal string).
CollectMarginFeesInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
feeUsdYesuint256 (uint256, pass as decimal string).
feeTokensYesuint256 (uint256, pass as decimal string).
CollectSwapFeesInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
feeUsdYesuint256 (uint256, pass as decimal string).
feeTokensYesuint256 (uint256, pass as decimal string).
cumulativeFundingRatesInspect

Calls cumulativeFundingRates(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
DecreaseGuaranteedUsdInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
DecreasePoolAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
decreasePositionInspect

Calls decreasePosition(_account: string, _collateralToken: string, _indexToken: string, _collateralDelta: string, _sizeDelta: string, _isLong: boolean, _receiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_receiverYesaddress (Ethereum address, 0x-prefixed).
_sizeDeltaYesuint256 (uint256, pass as decimal string).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralDeltaYesuint256 (uint256, pass as decimal string).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
DecreasePositionInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
feeYesuint256 (uint256, pass as decimal string).
keyYesbytes32 (32-byte hex string, 0x-prefixed).
priceYesuint256 (uint256, pass as decimal string).
isLongYesbool.
accountYesaddress (Ethereum address, 0x-prefixed).
sizeDeltaYesuint256 (uint256, pass as decimal string).
indexTokenYesaddress (Ethereum address, 0x-prefixed).
collateralDeltaYesuint256 (uint256, pass as decimal string).
collateralTokenYesaddress (Ethereum address, 0x-prefixed).
DecreaseReservedAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
DecreaseUsdgAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
directPoolDepositInspect

Calls directPoolDeposit(_token: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
DirectPoolDepositInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
errorControllerInspect

Calls errorController(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

errorsInspect

Calls errors(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns string.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesuint256 (uint256, pass as decimal string).
feeReservesInspect

Calls feeReserves(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
fundingIntervalInspect

Calls fundingInterval(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

fundingRateFactorInspect

Calls fundingRateFactor(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

FUNDING_RATE_PRECISIONInspect

Calls FUNDING_RATE_PRECISION(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

getDeltaInspect

Calls getDelta(_indexToken: string, _size: string, _averagePrice: string, _isLong: boolean, _lastIncreasedTime: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { _0: boolean, _1: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
_sizeYesuint256 (uint256, pass as decimal string).
_isLongYesbool.
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_averagePriceYesuint256 (uint256, pass as decimal string).
_lastIncreasedTimeYesuint256 (uint256, pass as decimal string).
getFeeBasisPointsInspect

Calls getFeeBasisPoints(_token: string, _usdgDelta: string, _feeBasisPoints: string, _taxBasisPoints: string, _increment: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_incrementYesbool.
_usdgDeltaYesuint256 (uint256, pass as decimal string).
_feeBasisPointsYesuint256 (uint256, pass as decimal string).
_taxBasisPointsYesuint256 (uint256, pass as decimal string).
getFundingFeeInspect

Calls getFundingFee(_token: string, _size: string, _entryFundingRate: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_sizeYesuint256 (uint256, pass as decimal string).
_tokenYesaddress (Ethereum address, 0x-prefixed).
_entryFundingRateYesuint256 (uint256, pass as decimal string).
getGlobalShortDeltaInspect

Calls getGlobalShortDelta(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { _0: boolean, _1: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getMaxPriceInspect

Calls getMaxPrice(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getMinPriceInspect

Calls getMinPrice(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getNextAveragePriceInspect

Calls getNextAveragePrice(_indexToken: string, _size: string, _averagePrice: string, _isLong: boolean, _nextPrice: string, _sizeDelta: string, _lastIncreasedTime: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_sizeYesuint256 (uint256, pass as decimal string).
_isLongYesbool.
_nextPriceYesuint256 (uint256, pass as decimal string).
_sizeDeltaYesuint256 (uint256, pass as decimal string).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_averagePriceYesuint256 (uint256, pass as decimal string).
_lastIncreasedTimeYesuint256 (uint256, pass as decimal string).
getNextFundingRateInspect

Calls getNextFundingRate(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getNextGlobalShortAveragePriceInspect

Calls getNextGlobalShortAveragePrice(_indexToken: string, _nextPrice: string, _sizeDelta: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_nextPriceYesuint256 (uint256, pass as decimal string).
_sizeDeltaYesuint256 (uint256, pass as decimal string).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
getPositionInspect

Calls getPosition(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { _0: string, _1: string, _2: string, _3: string, _4: string, _5: string, _6: boolean, _7: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
getPositionDeltaInspect

Calls getPositionDelta(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { _0: boolean, _1: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
getPositionFeeInspect

Calls getPositionFee(_sizeDelta: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_sizeDeltaYesuint256 (uint256, pass as decimal string).
getPositionKeyInspect

Calls getPositionKey(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bytes32.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
getPositionLeverageInspect

Calls getPositionLeverage(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
getRedemptionAmountInspect

Calls getRedemptionAmount(_token: string, _usdgAmount: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_usdgAmountYesuint256 (uint256, pass as decimal string).
getRedemptionCollateralInspect

Calls getRedemptionCollateral(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getRedemptionCollateralUsdInspect

Calls getRedemptionCollateralUsd(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getTargetUsdgAmountInspect

Calls getTargetUsdgAmount(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
getUtilisationInspect

Calls getUtilisation(_token: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
globalShortAveragePricesInspect

Calls globalShortAveragePrices(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
globalShortSizesInspect

Calls globalShortSizes(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
govInspect

Calls gov(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

guaranteedUsdInspect

Calls guaranteedUsd(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
hasDynamicFeesInspect

Calls hasDynamicFees(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

includeAmmPriceInspect

Calls includeAmmPrice(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

IncreaseGuaranteedUsdInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
IncreasePoolAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
increasePositionInspect

Calls increasePosition(_account: string, _collateralToken: string, _indexToken: string, _sizeDelta: string, _isLong: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_sizeDeltaYesuint256 (uint256, pass as decimal string).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
IncreasePositionInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
feeYesuint256 (uint256, pass as decimal string).
keyYesbytes32 (32-byte hex string, 0x-prefixed).
priceYesuint256 (uint256, pass as decimal string).
isLongYesbool.
accountYesaddress (Ethereum address, 0x-prefixed).
sizeDeltaYesuint256 (uint256, pass as decimal string).
indexTokenYesaddress (Ethereum address, 0x-prefixed).
collateralDeltaYesuint256 (uint256, pass as decimal string).
collateralTokenYesaddress (Ethereum address, 0x-prefixed).
IncreaseReservedAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
IncreaseUsdgAmountInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
amountYesuint256 (uint256, pass as decimal string).
initializeInspect

Calls initialize(_router: string, _usdg: string, _priceFeed: string, _liquidationFeeUsd: string, _fundingRateFactor: string, _stableFundingRateFactor: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_usdgYesaddress (Ethereum address, 0x-prefixed).
_routerYesaddress (Ethereum address, 0x-prefixed).
_priceFeedYesaddress (Ethereum address, 0x-prefixed).
_fundingRateFactorYesuint256 (uint256, pass as decimal string).
_liquidationFeeUsdYesuint256 (uint256, pass as decimal string).
_stableFundingRateFactorYesuint256 (uint256, pass as decimal string).
inManagerModeInspect

Calls inManagerMode(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

inPrivateLiquidationModeInspect

Calls inPrivateLiquidationMode(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

isInitializedInspect

Calls isInitialized(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

isLeverageEnabledInspect

Calls isLeverageEnabled(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

isLiquidatorInspect

Calls isLiquidator(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
isManagerInspect

Calls isManager(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
isSwapEnabledInspect

Calls isSwapEnabled(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

lastFundingTimesInspect

Calls lastFundingTimes(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
liquidatePositionInspect

Calls liquidatePosition(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean, _feeReceiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_feeReceiverYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
LiquidatePositionInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
keyYesbytes32 (32-byte hex string, 0x-prefixed).
sizeYesuint256 (uint256, pass as decimal string).
isLongYesbool.
accountYesaddress (Ethereum address, 0x-prefixed).
markPriceYesuint256 (uint256, pass as decimal string).
collateralYesuint256 (uint256, pass as decimal string).
indexTokenYesaddress (Ethereum address, 0x-prefixed).
realisedPnlYesint256 (int256, pass as decimal string).
reserveAmountYesuint256 (uint256, pass as decimal string).
collateralTokenYesaddress (Ethereum address, 0x-prefixed).
liquidationFeeUsdInspect

Calls liquidationFeeUsd(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

marginFeeBasisPointsInspect

Calls marginFeeBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

MAX_FEE_BASIS_POINTSInspect

Calls MAX_FEE_BASIS_POINTS(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

MAX_FUNDING_RATE_FACTORInspect

Calls MAX_FUNDING_RATE_FACTOR(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

maxGasPriceInspect

Calls maxGasPrice(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

maxLeverageInspect

Calls maxLeverage(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

MAX_LIQUIDATION_FEE_USDInspect

Calls MAX_LIQUIDATION_FEE_USD(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

maxUsdgAmountsInspect

Calls maxUsdgAmounts(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
MIN_FUNDING_RATE_INTERVALInspect

Calls MIN_FUNDING_RATE_INTERVAL(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

MIN_LEVERAGEInspect

Calls MIN_LEVERAGE(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

minProfitBasisPointsInspect

Calls minProfitBasisPoints(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
minProfitTimeInspect

Calls minProfitTime(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

mintBurnFeeBasisPointsInspect

Calls mintBurnFeeBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

poolAmountsInspect

Calls poolAmounts(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
positionsInspect

Calls positions(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { size: string, collateral: string, averagePrice: string, entryFundingRate: string, reserveAmount: string, realisedPnl: string, lastIncreasedTime: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesbytes32 (32-byte hex string, 0x-prefixed).
priceFeedInspect

Calls priceFeed(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

PRICE_PRECISIONInspect

Calls PRICE_PRECISION(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

removeRouterInspect

Calls removeRouter(_router: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_routerYesaddress (Ethereum address, 0x-prefixed).
reservedAmountsInspect

Calls reservedAmounts(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
routerInspect

Calls router(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

sellUSDGInspect

Calls sellUSDG(_token: string, _receiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_receiverYesaddress (Ethereum address, 0x-prefixed).
SellUSDGInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
accountYesaddress (Ethereum address, 0x-prefixed).
usdgAmountYesuint256 (uint256, pass as decimal string).
tokenAmountYesuint256 (uint256, pass as decimal string).
feeBasisPointsYesuint256 (uint256, pass as decimal string).
setBufferAmountInspect

Calls setBufferAmount(_token: string, _amount: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_amountYesuint256 (uint256, pass as decimal string).
setErrorInspect

Calls setError(_errorCode: string, _error: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_errorYesstring.
_errorCodeYesuint256 (uint256, pass as decimal string).
setErrorControllerInspect

Calls setErrorController(_errorController: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_errorControllerYesaddress (Ethereum address, 0x-prefixed).
setFeesInspect

Calls setFees(_taxBasisPoints: string, _stableTaxBasisPoints: string, _mintBurnFeeBasisPoints: string, _swapFeeBasisPoints: string, _stableSwapFeeBasisPoints: string, _marginFeeBasisPoints: string, _liquidationFeeUsd: string, _minProfitTime: string, _hasDynamicFees: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_minProfitTimeYesuint256 (uint256, pass as decimal string).
_hasDynamicFeesYesbool.
_taxBasisPointsYesuint256 (uint256, pass as decimal string).
_liquidationFeeUsdYesuint256 (uint256, pass as decimal string).
_swapFeeBasisPointsYesuint256 (uint256, pass as decimal string).
_marginFeeBasisPointsYesuint256 (uint256, pass as decimal string).
_stableTaxBasisPointsYesuint256 (uint256, pass as decimal string).
_mintBurnFeeBasisPointsYesuint256 (uint256, pass as decimal string).
_stableSwapFeeBasisPointsYesuint256 (uint256, pass as decimal string).
setFundingRateInspect

Calls setFundingRate(_fundingInterval: string, _fundingRateFactor: string, _stableFundingRateFactor: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_fundingIntervalYesuint256 (uint256, pass as decimal string).
_fundingRateFactorYesuint256 (uint256, pass as decimal string).
_stableFundingRateFactorYesuint256 (uint256, pass as decimal string).
setGovInspect

Calls setGov(_gov: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_govYesaddress (Ethereum address, 0x-prefixed).
setInManagerModeInspect

Calls setInManagerMode(_inManagerMode: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_inManagerModeYesbool.
setInPrivateLiquidationModeInspect

Calls setInPrivateLiquidationMode(_inPrivateLiquidationMode: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_inPrivateLiquidationModeYesbool.
setIsLeverageEnabledInspect

Calls setIsLeverageEnabled(_isLeverageEnabled: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isLeverageEnabledYesbool.
setIsSwapEnabledInspect

Calls setIsSwapEnabled(_isSwapEnabled: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isSwapEnabledYesbool.
setLiquidatorInspect

Calls setLiquidator(_liquidator: string, _isActive: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_isActiveYesbool.
_liquidatorYesaddress (Ethereum address, 0x-prefixed).
setManagerInspect

Calls setManager(_manager: string, _isManager: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_managerYesaddress (Ethereum address, 0x-prefixed).
_isManagerYesbool.
setMaxGasPriceInspect

Calls setMaxGasPrice(_maxGasPrice: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_maxGasPriceYesuint256 (uint256, pass as decimal string).
setMaxLeverageInspect

Calls setMaxLeverage(_maxLeverage: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_maxLeverageYesuint256 (uint256, pass as decimal string).
setPriceFeedInspect

Calls setPriceFeed(_priceFeed: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_priceFeedYesaddress (Ethereum address, 0x-prefixed).
setTokenConfigInspect

Calls setTokenConfig(_token: string, _tokenDecimals: string, _tokenWeight: string, _minProfitBps: string, _maxUsdgAmount: string, _isStable: boolean, _isShortable: boolean). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_isStableYesbool.
_isShortableYesbool.
_tokenWeightYesuint256 (uint256, pass as decimal string).
_minProfitBpsYesuint256 (uint256, pass as decimal string). Value in basis points (e.g. 500 = 5%, 10000 = 100%).
_maxUsdgAmountYesuint256 (uint256, pass as decimal string).
_tokenDecimalsYesuint256 (uint256, pass as decimal string).
setUsdgAmountInspect

Calls setUsdgAmount(_token: string, _amount: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_amountYesuint256 (uint256, pass as decimal string).
shortableTokensInspect

Calls shortableTokens(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
stableFundingRateFactorInspect

Calls stableFundingRateFactor(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

stableSwapFeeBasisPointsInspect

Calls stableSwapFeeBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

stableTaxBasisPointsInspect

Calls stableTaxBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

stableTokensInspect

Calls stableTokens(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
swapInspect

Calls swap(_tokenIn: string, _tokenOut: string, _receiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenInYesaddress (Ethereum address, 0x-prefixed).
_receiverYesaddress (Ethereum address, 0x-prefixed).
_tokenOutYesaddress (Ethereum address, 0x-prefixed).
SwapInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
accountYesaddress (Ethereum address, 0x-prefixed).
tokenInYesaddress (Ethereum address, 0x-prefixed).
amountInYesuint256 (uint256, pass as decimal string).
tokenOutYesaddress (Ethereum address, 0x-prefixed).
amountOutYesuint256 (uint256, pass as decimal string).
feeBasisPointsYesuint256 (uint256, pass as decimal string).
amountOutAfterFeesYesuint256 (uint256, pass as decimal string).
swapFeeBasisPointsInspect

Calls swapFeeBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

taxBasisPointsInspect

Calls taxBasisPoints(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

tokenBalancesInspect

Calls tokenBalances(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
tokenDecimalsInspect

Calls tokenDecimals(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
tokenToUsdMinInspect

Calls tokenToUsdMin(_token: string, _tokenAmount: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_tokenAmountYesuint256 (uint256, pass as decimal string).
tokenWeightsInspect

Calls tokenWeights(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
totalTokenWeightsInspect

Calls totalTokenWeights(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

updateCumulativeFundingRateInspect

Calls updateCumulativeFundingRate(_token: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
UpdateFundingRateInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
tokenYesaddress (Ethereum address, 0x-prefixed).
fundingRateYesuint256 (uint256, pass as decimal string).
UpdatePnlInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
keyYesbytes32 (32-byte hex string, 0x-prefixed).
deltaYesuint256 (uint256, pass as decimal string).
hasProfitYesbool.
UpdatePositionInspect

Event emitted by the contract. Subscribe via log filters.

ParametersJSON Schema
NameRequiredDescriptionDefault
keyYesbytes32 (32-byte hex string, 0x-prefixed).
sizeYesuint256 (uint256, pass as decimal string).
collateralYesuint256 (uint256, pass as decimal string).
realisedPnlYesint256 (int256, pass as decimal string).
averagePriceYesuint256 (uint256, pass as decimal string).
reserveAmountYesuint256 (uint256, pass as decimal string).
entryFundingRateYesuint256 (uint256, pass as decimal string).
upgradeVaultInspect

Calls upgradeVault(_newVault: string, _token: string, _amount: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. No return value.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_amountYesuint256 (uint256, pass as decimal string).
_newVaultYesaddress (Ethereum address, 0x-prefixed).
usdgInspect

Calls usdg(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns address.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

usdgAmountsInspect

Calls usdgAmounts(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
USDG_DECIMALSInspect

Calls USDG_DECIMALS(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

usdToTokenInspect

Calls usdToToken(_token: string, _usdAmount: string, _price: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_priceYesuint256 (uint256, pass as decimal string).
_tokenYesaddress (Ethereum address, 0x-prefixed).
_usdAmountYesuint256 (uint256, pass as decimal string).
usdToTokenMaxInspect

Calls usdToTokenMax(_token: string, _usdAmount: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_usdAmountYesuint256 (uint256, pass as decimal string).
usdToTokenMinInspect

Calls usdToTokenMin(_token: string, _usdAmount: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_usdAmountYesuint256 (uint256, pass as decimal string).
useSwapPricingInspect

Calls useSwapPricing(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

validateLiquidationInspect

Calls validateLiquidation(_account: string, _collateralToken: string, _indexToken: string, _isLong: boolean, _raise: boolean). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns { _0: string, _1: string }.

ParametersJSON Schema
NameRequiredDescriptionDefault
_raiseYesbool.
_isLongYesbool.
_accountYesaddress (Ethereum address, 0x-prefixed).
_indexTokenYesaddress (Ethereum address, 0x-prefixed).
_collateralTokenYesaddress (Ethereum address, 0x-prefixed).
whitelistedTokenCountInspect

Calls whitelistedTokenCount(). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

whitelistedTokensInspect

Calls whitelistedTokens(param0: string). Read-only — does not modify contract state. Unrestricted — any address can call this read function. Returns bool.

ParametersJSON Schema
NameRequiredDescriptionDefault
param0Yesaddress (Ethereum address, 0x-prefixed).
withdrawFeesInspect

Calls withdrawFees(_token: string, _receiver: string). Write function — may have access control restrictions (e.g. onlyOwner). Check contract source for modifier requirements before calling. Returns uint256.

ParametersJSON Schema
NameRequiredDescriptionDefault
_tokenYesaddress (Ethereum address, 0x-prefixed).
_receiverYesaddress (Ethereum address, 0x-prefixed).

Discussions

No comments yet. Be the first to start the discussion!

Try in Browser

Your Connectors

Sign in to create a connector for this server.