Illuminate
  • Illuminate - DeFi: Fixed
    • iPTs: Meta Principal Tokens
    • Lending
    • Maturity & Redemption
    • Integrations
    • YieldSpace AMM
    • Pricing & Arbitrage
  • Smart Contracts
    • Lender
      • Lender.sol
    • Redeemer
      • Redeemer.sol
    • Marketplace
      • Marketplace.sol
    • Illuminate Principal Token (ERC5095)
      • ERC5095.sol
    • Deployed Contract Addresses
    • Critical Attributes
    • Key Roles
    • Contract Relationships
    • Operation Checklists
    • Deposit Lifecycle
    • Error Codes
    • Smart Contract Integration
  • IlluminAPI
    • GET
      • Get Markets
      • Get Quotes
      • Get Best Quote
      • Get Pools
      • Get Pool
      • Get Raw Pool APYs
      • Get User Positions
      • Get Status
    • POST
  • Illuminate-js
  • Media Kit
  • Misc
  • FAQ
Powered by GitBook
On this page
  1. IlluminAPI
  2. GET

Get User Positions

GET https://illumigate.swivel.exchange/v1/users/:address/positions?type=t&status=s

This endpoint allows you to request a list of user lending and pooling positions.

Path Parameters

Name
Type
Description

address

string

User public address in hex.

Query Parameters

Name
Type
Description

type

string

Positions type: lending or pooling. If not specified, both lending and pooling positions will be returned.

status

string

Market status: active or matured. If not specified, only positions for active markets will be returned.

{
  "id": "0xD83F3CE852bcC65231054099A2270642700ADADD",
  "lending": {
    "0x07865c6E87B9F70255377e024ace6630C1Eaa37F": {
      "1688085200": {
        "totalSpent": "707882988",
        "totalReturned": "719523434",
        "costBasis": "0.983822",
        "lastPrice": "0.984748",
        "interestEarned": "11640446"
      },
      "1696115940": {
        "totalSpent": "120000000",
        "totalReturned": "119880000",
        "costBasis": "1.001001",
        "lastPrice": "1.001001",
        "interestEarned": "-120000"
      }
    }
  },
  "pooling": {
    "0x07865c6E87B9F70255377e024ace6630C1Eaa37F": {
      "1688085200": {
        "created": "1673380691"
      }
    },
    "0x2899a03ffDab5C90BADc5920b4f53B0884EB13cC": {
      "1688086200": {
        "created": "1674069975"
      }
    }
  }
}
PreviousGet Raw Pool APYsNextGet Status

Last updated 2 years ago