PerpsClient.updatePositionMargin. The registered provider plugin authorizes and submits the action according to its descriptor.
Position-margin support is market-specific. Read
market.positionMarginAdjustment or use the helper predicates below instead of assuming every provider supports both directions.Capability and Constraints
PositionMarginAdjustment has three values:
getPositionMarginConstraints(position) returns the provider-owned { minimumMarginRequirement, amountIncrement } decimal strings, or undefined when the position has no individual margin adjustment. removableIsolatedMargin accounts for unrealized PnL and snaps down to the accepted increment.
updatePositionMargin
action: 'remove' (with a positive amount) to withdraw margin from the position without changing its size.
API Reference: POST /createAction · /executeAction