simple-stellar-signer-api
TypeScript icon, indicating that this package has built-in type declarations

1.0.2-b • Public • Published

Simple Stellar Signer API

Handles Simple Stellar Signer popup window message-based implementation and networks, exposing its methods to handle directly as async functions.

How to use

Install package with:

    npm i simple-stellar-signer-api

Import methods into your code such as:

    import { connectWallet, Network } from 'simple-stellar-signer-api'
    
    const handleConnect = async () => {
        try {
            const { publicKey, wallet } = await connectWallet(Network.FUTURENET);
            //Do something with results...
        } catch (err: unknown){
            console.error(err);
        }
    }

Methods

All methods handle window popup, message and event handling then returns either a resolve with message data on success or reject with a string message on error.

connectWallet

signTransaction

  • Params:
    • transactionXDR: string
    • network: Network
    • (Optional) extraConfig: { description?: string, operationGroups?: OperationGroup[] }
  • Returns:
    • signedXDR: string

Exported Enums

Network


pubnet testnet futurenet

WalletType


albedo freighter rabet privateKey walletConnect xbull

Readme

Keywords

Package Sidebar

Install

npm i simple-stellar-signer-api

Weekly Downloads

2

Version

1.0.2-b

License

ISC

Unpacked Size

35.6 kB

Total Files

8

Last publish

Collaborators

  • ozkavosh