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

# Returns detailed information about user's position in the pool



## OpenAPI

````yaml https://backend.swap.coffee/openapi get /v1/yield/pool/{pool_address}/{user_address}
openapi: 3.0.3
info:
  title: Swap Coffee API
  version: 1.0.0
servers:
  - url: https://backend.swap.coffee/
  - url: http://localhost:8080/
security:
  - {}
  - ApiKey: []
tags:
  - name: Entity
    description: Tokens, pools, DEXes, etc.
  - name: Routing
    description: >-
      Core functionality of the aggregation service. Build routes, get
      transactions, etc.
  - name: Strategies
    description: Limit orders, DCA, VCA, etc.
  - name: Yield
    description: >-
      Yield aggregator functionality. Provides and handles routes to pools with
      the best yield.
  - name: Referral
    description: Everything related to the referral program of swap.coffee.
  - name: Cashback
    description: Cashback programs conducted on swap.coffee.
  - name: Claim
    description: Claiming various rewards available on swap.coffee.
  - name: Contests
    description: Timed contests based on trading volumes for certain token-pairs.
  - name: Staking
    description: Responsible of managing staked funds, corresponding rewards, etc.
  - name: DEX
    description: Core functionality of the Coffee DEX service.
  - name: LiquidityProvisioning
    description: Everything related to liquidity provisioning in DEXes.
  - name: Boosts
    description: >-
      Functionality to support incentives and rewards for liquidity providers
      among all DEXes.
  - name: Profile
    description: Retrieve information about user profiles.
  - name: Partnership
    description: Various functionality for our partners.
  - name: Statistics
    description: Retrieve information about dex aggregation stats.
  - name: Ton
    description: Retrieve information about TON entities.
  - name: Auth
    description: Auth operations. For internal usage only.
paths:
  /v1/yield/pool/{pool_address}/{user_address}:
    get:
      tags:
        - Yield
      summary: Returns detailed information about user's position in the pool
      operationId: getYieldUserDetails
      parameters:
        - name: pool_address
          in: path
          required: true
          description: Pool address
          schema:
            type: string
        - name: user_address
          in: path
          required: true
          description: User address
          schema:
            type: string
      responses:
        '200':
          description: >-
            Detailed information about user's position in requested pool, with
            incentives and so on
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiYieldUserDetails'
        default:
          $ref: '#/components/responses/ApiError'
components:
  schemas:
    ApiYieldUserDetails:
      type: object
      required:
        - pool
      properties:
        pool:
          oneOf:
            - $ref: '#/components/schemas/ApiYieldUserDetails_Dex'
            - $ref: '#/components/schemas/ApiYieldUserDetails_DexCLMM'
            - $ref: '#/components/schemas/ApiYieldUserDetails_DexDLMM'
            - $ref: '#/components/schemas/ApiYieldUserDetails_LiquidStaking'
            - $ref: '#/components/schemas/ApiYieldUserDetails_Lending'
            - $ref: '#/components/schemas/ApiYieldUserDetails_Perpetual'
            - $ref: '#/components/schemas/ApiYieldUserDetails_FarmixLending'
          discriminator:
            propertyName: yieldTypeResolver
            mapping:
              dex_pool:
                $ref: '#/components/schemas/ApiYieldUserDetails_Dex'
              dex_pool_clmm:
                $ref: '#/components/schemas/ApiYieldUserDetails_DexCLMM'
              dex_pool_dlmm:
                $ref: '#/components/schemas/ApiYieldUserDetails_DexDLMM'
              liquid_staking:
                $ref: '#/components/schemas/ApiYieldUserDetails_LiquidStaking'
              lending:
                $ref: '#/components/schemas/ApiYieldUserDetails_Lending'
              perpetual_vault_pool:
                $ref: '#/components/schemas/ApiYieldUserDetails_Perpetual'
              farmix_lending_pool:
                $ref: '#/components/schemas/ApiYieldUserDetails_FarmixLending'
    ApiYieldUserDetails_Dex:
      type: object
      required:
        - user_lp_amount
        - user_lp_wallet
        - boosts
      properties:
        user_lp_amount:
          type: string
          description: Absolute value, user's LP amount
        user_lp_wallet:
          type: string
          description: User's jetton wallet, where LP tokens are stored
        boosts:
          description: Available boosts to claim
          type: array
          items:
            $ref: '#/components/schemas/ApiClaimingTokenStats'
    ApiYieldUserDetails_DexCLMM:
      type: object
      required:
        - positions
        - boosts
      properties:
        positions:
          type: array
          items:
            $ref: '#/components/schemas/ApiDexClmmPosition'
        boosts:
          description: Available boosts to claim
          type: array
          items:
            $ref: '#/components/schemas/ApiClaimingTokenStats'
    ApiYieldUserDetails_DexDLMM:
      type: object
      required:
        - positions
        - boosts
      properties:
        positions:
          type: array
          items:
            $ref: '#/components/schemas/ApiDexDlmmPosition'
        boosts:
          description: Available boosts to claim
          type: array
          items:
            $ref: '#/components/schemas/ApiClaimingTokenStats'
    ApiYieldUserDetails_LiquidStaking:
      type: object
      required:
        - base_token_amount
        - liquid_token_amount
      properties:
        base_token_amount:
          type: string
        liquid_token_amount:
          type: string
    ApiYieldUserDetails_Lending:
      type: object
      required:
        - amount
      properties:
        amount:
          type: string
          format: bigint
          description: >-
            Amount of token. Positive value denotes supplied token. Negative
            value denotes borrowed token.
    ApiYieldUserDetails_Perpetual:
      type: object
      required:
        - lp_amount
        - quote_amount
      properties:
        lp_amount:
          type: string
          format: bigint
          description: Amount of lp token, which can be burned to get quote token.
        quote_amount:
          type: string
          format: bigint
          description: Amount of quote tokens which can be deposited into vault.
    ApiYieldUserDetails_FarmixLending:
      type: object
      required:
        - lp_amount
      properties:
        lp_amount:
          type: string
          format: bigint
          description: Amount of lp token, which can be burned to get underlying  token.
    ApiClaimingTokenStats:
      type: object
      required:
        - token
        - wallet
        - type
        - claimed
        - locked
        - available
        - available_usd
      properties:
        token:
          $ref: '#/components/schemas/ApiToken'
        wallet:
          type: string
          description: Wallet's address where token resides
        type:
          $ref: '#/components/schemas/ApiClaimingType'
        claimed:
          type: string
          format: int128
        locked:
          type: string
          format: int128
        available:
          type: string
          format: int128
        available_usd:
          type: number
          format: double
    ApiDexClmmPosition:
      type: object
      required:
        - tick_lower
        - tick_upper
        - is_active
        - position_id
        - position_address
        - liquidity
        - fee_owed_0
        - fee_owed_1
      properties:
        tick_lower:
          type: integer
          format: int64
          description: Tick index, where position starts
        tick_upper:
          type: integer
          format: int64
          description: Tick index, where position ends
        is_active:
          type: boolean
          description: Whether position is active or not
        position_id:
          type: integer
          format: int64
          description: Position id, used for interaction with CLMM protocol
        position_address:
          type: string
          description: Position address, used for interaction with CLMM protocol
        liquidity:
          type: string
          description: Position liquidity, absolute value
        fee_owed_0:
          type: string
          description: Fee available to claim in token 0
        fee_owed_1:
          type: string
          description: Fee available to claim in token 1
    ApiDexDlmmPosition:
      type: object
      required:
        - bin
        - is_active
        - position_address
        - liquidity
        - amount_x
        - amount_y
        - price_lower
        - price_upper
      properties:
        bin:
          type: integer
          format: int32
          description: Bin index
        is_active:
          type: boolean
          description: Whether the position is active
        position_address:
          type: string
          description: Position address
        liquidity:
          type: string
          description: Raw liquidity amount
        amount_x:
          type: number
          format: double
          description: Amount of token X
        amount_y:
          type: number
          format: double
          description: Amount of token X
        price_lower:
          type: number
          format: double
          description: Lower bound of the price
        price_upper:
          type: number
          format: double
          description: Upper bound of the price
    ApiToken:
      type: object
      required:
        - address
        - metadata
      properties:
        address:
          $ref: '#/components/schemas/ApiTokenAddress'
        metadata:
          $ref: '#/components/schemas/ApiTokenMetadata'
    ApiClaimingType:
      type: string
      enum:
        - all
        - referral
        - cashback
        - staking
        - rewards_stonfi
        - rewards_dedust
        - coffee_dex
        - boost
    ApiTokenAddress:
      type: object
      required:
        - blockchain
        - address
      properties:
        blockchain:
          type: string
          example: ton
        address:
          type: string
          example: native
    ApiTokenMetadata:
      type: object
      required:
        - name
        - symbol
        - decimals
        - listed
        - verification
      properties:
        name:
          type: string
          example: ARBUZ
        symbol:
          type: string
          example: ARBUZ
        decimals:
          type: integer
          format: int32
        image_url:
          type: string
        listed:
          type: boolean
        verification:
          $ref: '#/components/schemas/ApiTokenVerification'
    ApiTokenVerification:
      type: string
      enum:
        - whitelisted
        - blacklisted
        - community
        - unknown
  responses:
    ApiError:
      description: Some error during request processing
      content:
        application/json:
          schema:
            type: object
            required:
              - error
            properties:
              error:
                type: string
  securitySchemes:
    ApiKey:
      type: apiKey
      name: X-Api-Key
      in: header

````