🇺🇲
Broearn Wallet Documentation
  • 🧬OVERVIEW
    • 💡What is Broearn Wallet?
    • 🛡️Security
    • 📋Available Networks
      • Parallel Universe Chain
      • Bitcoin
      • Ethereum
      • BNB Chain
      • Tron
      • Solana
      • OKX Chain
      • Optimism
      • Fantom
      • Ethereum Classic
      • Polygon
      • Avalanche
  • 🛸PUT
    • Extension & in Broearn app
      • Events
        • Disconnect
        • Accounts Changed
    • Detecting the Provider
  • Establishing a Connection
  • PROVIDER METHODS
    • Connect
    • Disconnect
    • SignMessage
    • SignTransaction
    • SignAllTransactions
    • SignAndSendTransaction
  • 🔹ETHEREUM & EVM
    • Getting Started with Ethereum and EVM
    • Detecting the Provider
    • Establishing a Connection
    • Sending a Transaction
    • Signing a Message
    • Provider API Reference
      • Properties
        • eth_chainId
        • eth_networkVersion
        • eth_selectedAddress
        • _events
        • _eventsCount
      • Events
        • Connect
        • Accounts Changed
        • Disconnect
        • Chain Changed
      • Methods
        • isConnected
        • request
  • Demo Applications
  • 📜ERRORS
  • ADVANCED
    • Auth
      • Web Javascript demo
      • Web Java
      • Web Golang
      • Web PHP
  • COMMUNITY AND SUPPORT
    • 🐦Twitter
    • ✈️Telegram
    • 🎮Discord
Powered by GitBook
On this page
  • Query Function
  • Query String Parameters
  • Returns
  1. PROVIDER METHODS

Connect

In order to start interacting with Broearn Wallet, an app must first establish a connection. This connection request will prompt users for permission to share their public keys, indicating that they are willing to interact further.

Once a user connects to Broearn Wallet, Broearn Wallet will return the promise type param that should be used on all subsequent methods.

Query Function

// New Connect
window.bw.put.connect()
// Check if the Dapp is linked to a wallet
window.bw.put.connect({
    session: '...'
}}

Query String Parameters

Check if the Dapp is linked to a wallet

// Some code
{
    session: string
}

Returns

Approve

  • data: An JSON object.

    // content of decrypted `data`-parameter
    {
      // base58 encoding of user public key
      "address": "BSFtCudCd4pR4LSFqWPjbtXPKSNVbGkc35gRNdnqjMCU",
    
      // session token for subsequent signatures and messages
      // dapps should send this with any other deeplinks after connect
      "session": "..."
    }
    • address: The public key of the user, represented as a base58-encoded string.

    • session: A string type. This should be treated as opaque by the connecting app, as it only needs to be passed alongside other parameters. Sessions do not expire.

// Sample code
{
    "data": {
        "address": "",
        "session": ""
    }
}

Reject

{
    "errorCode": "",
    "errorMessage": ""
}
PreviousPROVIDER METHODSNextDisconnect

Last updated 1 year ago

An errorCode and errorMessage as query parameters. Please refer to for a full list of possible error codes.

Errors