Skip to content

BGT Berachain

Git Source

This precompile is responsible for allowing users to redeem their BGT into BERA.

Note: Link to existing contract ABI's can be found on Github here.

Interface of the BGT module's precompiled contract

Functions

redeem

Burns BGT tokens from the msg.sender and mints bera to the receiver address.

solidity
function redeem(address receiver, uint256 amount) external returns (uint256);
function redeem(address receiver, uint256 amount) external returns (uint256);

Parameters

NameTypeDescription
receiveraddressThe address to mint bera to.
amountuint256The amount of BGT tokens to redeem

Returns

NameTypeDescription
<none>uint256The amount of bera minted.

Events

Redeem

Emitted when BGT tokens are redeemed.

solidity
event Redeem(address indexed bgtburner, address indexed berareceiver, uint256 redeemed);
event Redeem(address indexed bgtburner, address indexed berareceiver, uint256 redeemed);

Parameters

NameTypeDescription
bgtburneraddressThe address that burned BGT tokens.
berareceiveraddressThe address that received bera.
redeemeduint256The amount of BGT tokens redeemed.