Params
The Params Contract provides market, vault, and perp data. It is mandatory to whitelist and enable markets throughout the Mars Protocol ecosystem.
Deployments
Neutron: neutron1x4rgd7ry23v2n49y7xdzje0743c5tgrnqrqsvwyya2h6m48tz4jqqex06x
Osmosis: osmo1nlmdxt9ctql2jr47qd4fpgzg84cjswxyw6q99u4y4u4q6c2f5ksq7ysent
Types
The types of the Params Contract can be found here.
For reference on the Queries and Methods:
type Addr = string
type Decimal = string
type Uint128 = string
Queries
all_asset_params (outdated)
Returns all asset params.
{
all_asset_params: {
limit?: number | null
start_after?: string | null
}
}
{
data: [
{
close_factor: Decimal
credit_manager: {
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
whitelisted: boolean
withdraw_enabled: boolean
}
denom: string
deposit_cap: Uint128
liquidation_bonus: {
max_lb: Decimal
min_lb: Decimal
slope: Decimal
starting_lb: Decimal
}
liquidation_threshold: Decimal
max_loan_to_value: Decimal
protocol_liquidation_fee: Decimal
red_bank: {
borrow_enabled: boolean
deposit_enabled: boolean
withdraw_enabled: boolean
}
},
...
]
}
all_asset_params_v2
{
all_asset_params_v2: {
limit?: number | null
start_after?: string | null
}
}
{
data: {
data: [
{
close_factor: Decimal
credit_manager: {
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
whitelisted: boolean
withdraw_enabled: boolean
}
denom: string
deposit_cap: Uint128
liquidation_bonus: {
max_lb: Decimal
min_lb: Decimal
slope: Decimal
starting_lb: Decimal
}
liquidation_threshold: Decimal
max_loan_to_value: Decimal
protocol_liquidation_fee: Decimal
red_bank: {
borrow_enabled: boolean
deposit_enabled: boolean
withdraw_enabled: boolean
}
},
...
]
metadata: {
has_more: boolean
}
}
}
all_perp_params (outdated)
{
all_perp_params: {
limit?: number | null
start_after?: string | null
}
}
{
data: [
closing_fee_rate: Decimal
denom: string
enabled: boolean
liquidation_threshold: Decimal
max_funding_velocity: Decimal
max_loan_to_value: Decimal
max_long_oi_value: Uint128
max_net_oi_value: Uint128
max_position_value?: Uint128 | null
max_short_oi_value: Uint128
min_position_value: Uint128
opening_fee_rate: Decimal
skew_scale: Uint128
]
}
all_perp_params_v2
{
all_perp_params_v2: {
limit?: number | null
start_after?: string | null
}
}
{
data: {
data: [
closing_fee_rate: Decimal
denom: string
enabled: boolean
liquidation_threshold: Decimal
max_funding_velocity: Decimal
max_loan_to_value: Decimal
max_long_oi_value: Uint128
max_net_oi_value: Uint128
max_position_value?: Uint128 | null
max_short_oi_value: Uint128
min_position_value: Uint128
opening_fee_rate: Decimal
skew_scale: Uint128
]
metadata: {
has_more: boolean
}
}
}
all_total_deposits_v2
{
all_total_deposits_v2: {
limit?: number | null
start_after?: string | null
}
}
{
data: {
data: [
{
amount: Uint128
cap: Uint128
denom: string
},
...
]
metadata: {
has_more: boolean
}
}
}
all_vault_configs (outdated)
{
all_vault_configs: {
limit?: number | null
start_after?: string | null
}
}
{
data: [
{
addr: Addr
deposit_cap: Coin
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
liquidation_threshold: Decimal
max_loan_to_value: Decimal
whitelisted: boolean
},
...
]
}
all_vault_configs_v2
{
all_vault_configs_v2: {
limit?: number | null
start_after?: string | null
}
}
{
data: {
data: [
{
addr: Addr
deposit_cap: Coin
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
liquidation_threshold: Decimal
max_loan_to_value: Decimal
whitelisted: boolean
},
...
],
metadata: {
has_more: boolean
}
}
}
asset_params
{
asset_params: {
denom: string
}
}
{
data: {
close_factor: Decimal
credit_manager: {
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
whitelisted: boolean
withdraw_enabled: boolean
}
denom: string
deposit_cap: Uint128
liquidation_bonus: {
max_lb: Decimal
min_lb: Decimal
slope: Decimal
starting_lb: Decimal
}
liquidation_threshold: Decimal
max_loan_to_value: Decimal
protocol_liquidation_fee: Decimal
red_bank: {
borrow_enabled: boolean
deposit_enabled: boolean
withdraw_enabled: boolean
}
}
}
config
{
config: {}
}
{
data: {
address_provider: string
max_perp_params: number
}
}
managed_vault_config
{
managed_vault_config: {}
}
{
data: {
code_ids: number[]
min_creation_fee_in_uusd: number
}
}
owner
{
owner: {}
}
{
data: {
abolished: boolean
emergency_owner?: string | null
initialized: boolean
owner?: string | null
proposed?: string | null
}
}
perp_params
{
perp_params: {
denom: string
}
}
{
data: {
closing_fee_rate: Decimal
denom: string
enabled: boolean
liquidation_threshold: Decimal
max_funding_velocity: Decimal
max_loan_to_value: Decimal
max_long_oi_value: Uint128
max_net_oi_value: Uint128
max_position_value?: Uint128 | null
max_short_oi_value: Uint128
min_position_value: Uint128
opening_fee_rate: Decimal
skew_scale: Uint128
}
}
risk_manager
{
risk_manager: {}
}
{
data: {
abolished: boolean
emergency_owner?: string | null
initialized: boolean
owner?: string | null
proposed?: string | null
}
}
total_deposit
{
total_deposit: {
denom: string
}
}
{
data: {
amount: Uint128
cap: Uint128
denom: string
}
}
vault_config
{
vault_config: {
address: string
}
}
{
data: {
addr: Addr
deposit_cap: Coin
hls?: {
correlations: [
{
coin: {
denom: string
}
} | {
vault: {
addr: Addr
}
},
...
]
liquidation_threshold: Decimal
max_loan_to_value: Decimal
} | null
liquidation_threshold: Decimal
max_loan_to_value: Decimal
whitelisted: boolean
}
}
Methods
Only the owner of the contract can call its methods. That's why they are not part of the documentation.
Last updated