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

# Position

> Get a position and its legs

```bash theme={null}
curl "https://api.bendbasis.com/v1/positions/POSITION_ID" \
  -H "Authorization: Bearer $BENDBASIS_API_KEY"
```


## OpenAPI

````yaml GET /v1/positions/{position_id}
openapi: 3.1.0
info:
  title: bendbasis API
  description: Funding market and arbitrage data from bendbasis.
  version: 1.0.0-preview
servers:
  - url: https://api.bendbasis.com
security: []
tags:
  - name: Portfolio
    description: Read-only access to your portfolios and positions.
paths:
  /v1/positions/{position_id}:
    get:
      tags:
        - Portfolio
      summary: Get position
      operationId: getPosition
      parameters:
        - name: position_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Position
          headers:
            X-API-Version:
              schema:
                type: string
              example: v1
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PositionResponse'
              example:
                data:
                  position_id: de3e7930-4762-4b6d-80f0-13aa8a66ecfa
                  portfolio_id: 2f69612d-3b97-4820-babc-6c482a70fb68
                  asset: BTC
                  status: open
                  note: null
                  opened_at: '2026-09-01T08:00:00.000Z'
                  closed_at: null
                  legs:
                    - leg_id: 43bed8b5-8764-456d-9fd6-c7df9c960a76
                      side: long
                      market_id: 15036
                      exchange: binance
                      symbol: BTCUSDT
                      leverage: 2
                      quantity: 0.1
                      open_price: 108000
                      mark_price: 108240.5
                      mark_price_updated_at: '2026-09-13T11:59:57.000Z'
                      close_price: null
                      open_fee_paid: 4.32
                      close_fee_paid: null
                      funding:
                        calculated: 18.42
                        override: null
        '400':
          $ref: '#/components/responses/ValidationFailed'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/ResourceNotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
      security:
        - BearerAuth: []
components:
  schemas:
    PositionResponse:
      type: object
      required:
        - data
      properties:
        data:
          $ref: '#/components/schemas/Position'
    Position:
      type: object
      additionalProperties: false
      required:
        - position_id
        - portfolio_id
        - asset
        - status
        - note
        - opened_at
        - closed_at
        - legs
      properties:
        position_id:
          type: string
          format: uuid
        portfolio_id:
          type: string
          format: uuid
        asset:
          type: string
        status:
          $ref: '#/components/schemas/PositionStatus'
        note:
          type:
            - string
            - 'null'
        opened_at:
          type: string
          format: date-time
        closed_at:
          type:
            - string
            - 'null'
          format: date-time
        legs:
          type: array
          items:
            $ref: '#/components/schemas/PositionLeg'
    ValidationError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - VALIDATION_ERROR
        message:
          type: string
      example:
        code: VALIDATION_ERROR
        message: Invalid parameter
    UnauthorizedError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - UNAUTHORIZED
        message:
          type: string
      example:
        code: UNAUTHORIZED
        message: Valid API key required
    ForbiddenError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - FORBIDDEN
        message:
          type: string
      example:
        code: FORBIDDEN
        message: API key does not grant the required scope
    NotFoundError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - NOT_FOUND
        message:
          type: string
      example:
        code: NOT_FOUND
        message: Funding market not found
    PositionStatus:
      type: string
      enum:
        - open
        - closed
    PositionLeg:
      type: object
      additionalProperties: false
      required:
        - leg_id
        - side
        - market_id
        - exchange
        - symbol
        - leverage
        - quantity
        - open_price
        - mark_price
        - mark_price_updated_at
        - close_price
        - open_fee_paid
        - close_fee_paid
        - funding
      properties:
        leg_id:
          type: string
          format: uuid
        side:
          type: string
          enum:
            - long
            - short
        market_id:
          type:
            - integer
            - 'null'
        exchange:
          type: string
        symbol:
          type: string
        leverage:
          type:
            - number
            - 'null'
        quantity:
          type: number
          description: Current quantity after size adjustments.
        open_price:
          type:
            - number
            - 'null'
        mark_price:
          type:
            - number
            - 'null'
          description: Latest available mark price for an open position.
        mark_price_updated_at:
          type:
            - string
            - 'null'
          format: date-time
          description: Time the mark price was last updated.
        close_price:
          type:
            - number
            - 'null'
        open_fee_paid:
          type:
            - number
            - 'null'
          description: Opening fee in USD.
        close_fee_paid:
          type:
            - number
            - 'null'
          description: Closing fee in USD.
        funding:
          $ref: '#/components/schemas/LegFunding'
    LegFunding:
      type: object
      additionalProperties: false
      required:
        - calculated
        - override
      properties:
        calculated:
          type:
            - number
            - 'null'
          description: Automatically calculated lifetime funding in USD.
        override:
          type:
            - number
            - 'null'
          description: >-
            Manual lifetime funding in USD. Replaces calculated funding in
            performance totals when set.
  responses:
    ValidationFailed:
      description: Invalid request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationError'
    Unauthorized:
      description: Missing or invalid API key.
      headers:
        WWW-Authenticate:
          schema:
            type: string
          example: Bearer
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnauthorizedError'
    Forbidden:
      description: The API key does not grant the required scope.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ForbiddenError'
    ResourceNotFound:
      description: Resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/NotFoundError'
    RateLimited:
      description: Rate limit exceeded.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: Personal API key created at bendbasis.com/account/api-keys.

````