Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

community_pool source realm

Package community\_pool manages the GnoSwap community treasury.

Overview

Package community_pool manages the GnoSwap community treasury.

This contract holds protocol-owned assets that can be allocated through governance proposals. It receives a portion of GNS emissions and can be used for ecosystem development, grants, and protocol improvements.

Functions 2

func GetBalanceOf

Action
1func GetBalanceOf(tokenPath string) int64
source

GetBalanceOf returns the balance of a specific token held by the community pool.

Parameters:

  • tokenPath: the path to the token contract (e.g., "gno.land/r/gnoswap/gns")

Returns the balance of the specified token held by the community pool.

func TransferToken

crossing Action
1func TransferToken(cur realm, tokenPath string, to address, amount int64)
source

TransferToken transfers tokens from the community pool.

Parameters:

  • cur: current realm
  • tokenPath: token contract path
  • to: recipient address
  • amount: transfer amount

Only callable by admin or governance.

Imports 6

Source Files 3