> ## 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.

# Get aggregated information about staking



## OpenAPI

````yaml https://backend.swap.coffee/openapi get /v2/staking/{master_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:
  /v2/staking/{master_address}:
    get:
      tags:
        - Staking
      summary: Get aggregated information about staking
      operationId: getStakingGlobalInfo
      parameters:
        - $ref: '#/components/parameters/pathStakingMasterAddress'
      responses:
        '200':
          description: Aggregated staking info
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiStakingGlobalInfo'
        default:
          $ref: '#/components/responses/ApiError'
components:
  parameters:
    pathStakingMasterAddress:
      in: path
      name: master_address
      required: true
      schema:
        type: string
        example: EQCMtrnKhK82Yw6xHrLm_rJLkMYxeYIilhdmn6BnVGZ1PnBM
  schemas:
    ApiStakingGlobalInfo:
      type: object
      required:
        - total_points
        - apr
        - total_locked_native
        - locked_tokens
        - distributed_rewards
        - actual_rewards
        - periods
      properties:
        total_points:
          type: number
        apr:
          type: number
          format: double
        total_locked_native:
          type: number
        locked_tokens:
          type: array
          items:
            $ref: '#/components/schemas/ApiStakingTokenInfoLock'
        distributed_rewards:
          type: array
          items:
            $ref: '#/components/schemas/ApiStakingTokenInfo'
        actual_rewards:
          type: array
          items:
            $ref: '#/components/schemas/ApiStakingRewardsTokenInfo'
        periods:
          type: array
          items:
            $ref: '#/components/schemas/ApiStakingPositionPeriods'
        calculated_at_time:
          type: integer
          format: int64
    ApiStakingTokenInfoLock:
      type: object
      required:
        - token
        - normalizer
        - price_per_token_usd
      properties:
        token:
          $ref: '#/components/schemas/ApiToken'
          description: Token to be staked for rewards.
        normalizer:
          type: number
        price_per_token_usd:
          type: number
          format: double
    ApiStakingTokenInfo:
      type: object
      required:
        - token_address
        - asset_raw
        - asset_usd
      properties:
        token_address:
          type: string
          description: Reward token address.
          example: EQDY6PMeMbQSz7dltNN4RRTIxyuBJX4dQESOy8cWR2tUgBxH
        asset_usd:
          type: number
          format: double
        asset_raw:
          type: number
    ApiStakingRewardsTokenInfo:
      type: object
      required:
        - token_address
        - end_distribution_unix
        - reward_rate
      properties:
        token_address:
          type: string
          description: Token address.
          example: EQDY6PMeMbQSz7dltNN4RRTIxyuBJX4dQESOy8cWR2tUgBxH
        end_distribution_unix:
          type: integer
          format: int64
          description: Timestamp in unix seconds
        reward_rate:
          type: number
    ApiStakingPositionPeriods:
      type: object
      required:
        - period_id
        - percentage
        - lock_duration
      properties:
        period_id:
          type: integer
          format: int32
          description: Period id, to be passed into protocol.
        percentage:
          type: integer
          format: int64
          description: How much additional points will be accrued.
        lock_duration:
          type: integer
          format: int64
          description: How much wait till position unlock.
    ApiToken:
      type: object
      required:
        - address
        - metadata
      properties:
        address:
          $ref: '#/components/schemas/ApiTokenAddress'
        metadata:
          $ref: '#/components/schemas/ApiTokenMetadata'
    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

````