For the complete documentation index, see llms.txt. This page is also available as Markdown.

Overview

Integrate Varial into your web application using @stellar/varial-sdk. This library lets you send and receive data from a user's Varial extension.

@stellar/varial-sdk is the new name of @stellar/freighter-api. The old package stays at 6.0.1 with no new releases. Dapps using it keep working with every method on these pages except ones added after 6.0.1, such as disconnect().

@stellar/varial-sdk adheres to the SEP-43 standard for wallet interfaces on Stellar, and also offers additional methods beyond the spec such as getNetworkDetails, addToken, and WatchWalletChanges.

Error Type

All methods return an optional error field of type FreighterApiError (the type keeps its previous name):

interface FreighterApiError {
  code: number;
  message: string;
  ext?: string[];
}

API Reference

Category
Description

Detect Varial, check permissions, request access, disconnect

Get the user's address and network configuration

Sign transactions, auth entries, and messages

Add contract tokens to the user's wallet

Monitor wallet state changes in real time

Last updated

Was this helpful?