Build Close Position REST API Endpoint
Parameters
Body Parameters
action
object
REQUIRED
Loading...
type
string
Loading...
asset
string
Loading...
user
string
Loading...
fraction
number
Loading...
Returns
hash
string
Loading...
nonce
integer
Loading...
action
object
Loading...
type
string
Loading...
orders
array
Loading...
a
integer
Loading...
b
boolean
Loading...
p
string
Loading...
s
string
Loading...
r
boolean
Loading...
t
object
Loading...
limit
object
Loading...
tif
string
Loading...
grouping
string
Loading...
isSpot
boolean
Loading...
builderFee
string
Loading...
builderFeeRaw
integer
Loading...
builder
string
Loading...
nextStep
string
Loading...
closePositionContext
object
Loading...
originalAction
string
Loading...
asset
integer
Loading...
assetName
string
Loading...
isSpot
boolean
Loading...
positionSide
string
Loading...
positionSize
number
Loading...
closeSize
number
Loading...
fraction
number
Loading...
closeSide
string
Loading...
midPrice
number
Loading...
slippedPrice
string
Loading...
Request
1curl -s -X POST https://docs-demo.hype-mainnet.quiknode.pro/hypercore/exchange \2-H "Content-Type: application/json" \3-d '{4"action": {5"type": "closePosition",6"asset": "MEGA",7"user": "0x2ba553d9f990a3b66b03b2dc0d030dfc1c061036",8"fraction": 1.09}10}'11
1curl -s -X POST https://docs-demo.hype-mainnet.quiknode.pro/hypercore/exchange \2-H "Content-Type: application/json" \3-d '{4"action": {5"type": "closePosition",6"asset": "MEGA",7"user": "0x2ba553d9f990a3b66b03b2dc0d030dfc1c061036",8"fraction": 1.09}10}'11
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free