SBCWrapper
Gnosis0x647507a70ff598f386cb96ae5046486389368c66
Proxy implementation: 0x0b91d1e3312aeef7e9e641606ad0aa19aa05673d
Solidity v0.8.9+commit.e5eed63a
🤖
Query this contract from your AI
Reference:
0x647507a70ff598f386cb96ae5046486389368c66
Sample prompt:
"Tell me the current state of gnosis/0x647507a70ff598f386cb96ae5046486389368c66"
No AI wired up yet? →
mcp.smarts.md
Gnosis is a docs-only chain on Smarts: source code and ABI are indexed, but live on-chain data (state, recent events, admin profile) is not currently available. AI agents can still query get_contract_info and get_contract_source via MCP.
Overview
Read Functions
5
Write Functions
8
Events
7
Read Functions
paused()
view
dev: Returns true if the contract is paused, and false otherwise.
Returns
| Name | Type | Description |
|---|---|---|
| — | bool |
sbcDepositContract()
view
Returns
| Name | Type | Description |
|---|---|---|
| — | address |
sbcToken()
view
Returns
| Name | Type | Description |
|---|---|---|
| — | address |
tokenRate(address)
view
Parameters
| Name | Type | Description |
|---|---|---|
| — | address |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
tokenStatus(address)
view
Parameters
| Name | Type | Description |
|---|---|---|
| — | address |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint8 |
Write Functions
claimTokens(_token: address, _to: address)
nonpayable
dev: Allows to transfer any locked token from this contract. Only admin can call this method. While it is not allowed to claim previously enabled or paused tokens, the admin should still verify that the claimed token is a valid ERC20 token contract.
Parameters
| Name | Type | Description |
|---|---|---|
| _token | address | address of the token, if it is not provided (0x00..00), native coins will be transferred. |
| _to | address | address that will receive the locked tokens on this contract. |
enableToken(_token: address, _rate: uint256)
nonpayable
dev: Enables swapping of new token into wrapped SBC token at a given rate. Only admin can call this method.
Parameters
| Name | Type | Description |
|---|---|---|
| _token | address | address of the enabled or reenabled token contract. |
| _rate | uint256 | exchange rate for the new pair, multiplied by 10**18. |
onTokenTransfer(from: address, value: uint256, data: bytes)
nonpayable
dev: ERC677 callback for swapping tokens in the simpler way during transferAndCall.
Parameters
| Name | Type | Description |
|---|---|---|
| from | address | address of the received token contract. |
| value | uint256 | amount of the received tokens. |
| data | bytes | should be empty for a simple token swap, otherwise will pass it further to the deposit contract. |
Returns
| Name | Type | Description |
|---|---|---|
| — | bool |
pause()
nonpayable
pauseToken(_token: address)
nonpayable
dev: Temporary pauses swapping of some particular token, which can be reenaled later. Only admin can call this method.
Parameters
| Name | Type | Description |
|---|---|---|
| _token | address | address of the paused token contract. |
swap(_token: address, _amount: uint256, _permitData: bytes)
nonpayable
dev: Swaps some of the whitelisted tokens for the newly created wrapped tokens. Tokens must be pre-approved before calling this function.
Parameters
| Name | Type | Description |
|---|---|---|
| _token | address | address of the swapped token contract. |
| _amount | uint256 | amount of tokens to swap. |
| _permitData | bytes | optional permit calldata to use for preliminary token approval. supports STAKE permit and EIP2612 standards. |
unpause()
nonpayable
unwrap(_token: address, _amount: uint256)
nonpayable
dev: Swaps some of the wrapped tokens to the whitelisted token. Wrapped tokens will be burned.
Parameters
| Name | Type | Description |
|---|---|---|
| _token | address | Address of the whitelisted token contract. |
| _amount | uint256 | Amount of tokens to swap. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 | Amount of returned tokens. |
Events
Paused(account: address)
| Name | Type | Indexed | Description |
|---|---|---|---|
| account | address |
Swap(token: address, user: address, amount: uint256, received: uint256)
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ | |
| user | address | ✓ | |
| amount | uint256 | ||
| received | uint256 |
SwapRateUpdated(token: address, rate: uint256)
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ | |
| rate | uint256 |
TokenSwapEnabled(token: address)
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ |
TokenSwapPaused(token: address)
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ |
Unpaused(account: address)
| Name | Type | Indexed | Description |
|---|---|---|---|
| account | address |
Unwrap(token: address, user: address, amount: uint256, received: uint256)
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ | |
| user | address | ✓ | |
| amount | uint256 | ||
| received | uint256 |