New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

simple-stellar-signer-api

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

simple-stellar-signer-api

Handles SimpleSigner operations and exposes its async methods

latest
Source
npmnpm
Version
1.0.3
Version published
Maintainers
0
Created
Source

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

  • Params:
  • Returns:
    • wallet: { publicKey: string, wallet: WalletType }

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

Keywords

stellar

FAQs

Package last updated on 23 Jan 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts