> ## Documentation Index
> Fetch the complete documentation index at: https://api.docs.rocketfi.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get position

> ### Parameters

| Parameter | Required | Type | Description |
| --------- | -------- | ---- | ----------- |
| account | yes | string (hex) | Ethereum-style account address for the sub-account context. |
| instrumentId | yes | integer (int64) | Target instrument identifier. |

### Response fields

| Parameter | Required | Type | Description |
| --------- | -------- | ---- | ----------- |
| `positions` | no | object | — |

### Response example

A sample **`200`** JSON body is attached to this operation as an OpenAPI **example** (Mintlify shows it in the example panel, similar to other exchange API docs).



## OpenAPI

````yaml /specs/openapi.json get /position
openapi: 3.1.0
info:
  title: RocketFi REST API
  description: REST API for Rocket Chain / RocketFi integrations.
  license:
    name: ''
  version: 0.1.0
servers:
  - url: https://beta.rocketfi.io
    description: Beta
  - url: https://testnet.rocket-cluster-1.com
    description: Testnet
  - url: https://devnet.rocket-cluster-1.com
    description: Devnet
security: []
tags:
  - name: Service
    description: Health and availability.
  - name: Market data
    description: Instruments, candles, fees, leverage, and funding data.
  - name: Account
    description: Account nonce, fees, collateral, positions, and orders.
  - name: Trading
    description: Transactions and order activity.
  - name: Vault and bridge
    description: Vaults, history, and bridge events.
  - name: Faucet (testnet)
    description: Testnet faucet for development.
paths:
  /position:
    get:
      tags:
        - Account
      summary: Get position
      description: >-
        ### Parameters


        | Parameter | Required | Type | Description |

        | --------- | -------- | ---- | ----------- |

        | account | yes | string (hex) | Ethereum-style account address for the
        sub-account context. |

        | instrumentId | yes | integer (int64) | Target instrument identifier. |


        ### Response fields


        | Parameter | Required | Type | Description |

        | --------- | -------- | ---- | ----------- |

        | `positions` | no | object | — |


        ### Response example


        A sample **`200`** JSON body is attached to this operation as an OpenAPI
        **example** (Mintlify shows it in the example panel, similar to other
        exchange API docs).
      operationId: get_position
      parameters:
        - name: account
          in: path
          required: true
          schema:
            $ref: '#/components/schemas/AccountAddress'
          description: Ethereum-style account address for the sub-account context.
        - name: instrumentId
          in: path
          required: true
          schema:
            oneOf:
              - type: 'null'
              - $ref: '#/components/schemas/InstrumentId'
          description: Target instrument identifier.
      responses:
        '200':
          description: Positions by account
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetPositionsResponse'
              example:
                positions: null
components:
  schemas:
    AccountAddress:
      type: string
      format: hex
      description: An Ethereum-style account address (20 bytes).
    InstrumentId:
      type: integer
      format: int64
      description: An instrument identifier (8-byte hash).
      minimum: 0
    GetPositionsResponse:
      type: object
      properties:
        positions:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/PositionSetView'
    PositionSetView:
      type: object
      additionalProperties:
        $ref: '#/components/schemas/PositionView'
      propertyNames:
        type: integer
        format: int64
        description: An instrument identifier (8-byte hash).
        minimum: 0
    PositionView:
      type: object
      required:
        - quantity
        - averagePrice
        - liquidationPrice
        - accruedFunding
        - unrealizedPnl
        - reservedMargin
        - leverageSetting
        - createdAt
        - updatedAt
      properties:
        accruedFunding:
          type: string
        averagePrice:
          type: string
        createdAt:
          $ref: '#/components/schemas/u64'
        leverageSetting:
          type: integer
          format: int64
          minimum: 0
        liquidationPrice:
          type: string
        quantity:
          type: string
        reservedMargin:
          type: string
        unrealizedPnl:
          type: string
        updatedAt:
          $ref: '#/components/schemas/u64'
    u64:
      type: integer
      format: int64
      minimum: 0

````