trustlinedocs
Getting started

Install

One package for almost everyone. Here is what to install, and when.

For most integrations you install a single package. It bundles @trustline-onboarder/core as a regular dependency and re-exports the helpers and types you’ll actually touch.

$pnpm add @trustline-onboarder/sdk

The one required peer

@trustline-onboarder/sdk builds transactions with the Stellar JavaScript SDK. If your project doesn’t have it yet, add it:

$pnpm add @stellar/stellar-sdk
That is the only required peer dependency. Everything else — the mechanism builders, the sponsorship helper, the discovery utilities — is included and re-exported from @trustline-onboarder/sdk.

Issuer-side packages

If you run the approval server for a regulated asset, also install the signer package, which provides the issuer signing adapters and the SEP-8 approval helpers:

$pnpm add @trustline-onboarder/signer

Verify the install

Quick sanity check. Add this to any script; you should see the supported mechanisms logged.

import { SDK_VERSION } from "@trustline-onboarder/sdk";
import { supportedMechanisms } from "@trustline-onboarder/core";

console.log(SDK_VERSION);            // "0.1.0"
console.log(supportedMechanisms());  // ["claimable", "authorize", "intermediate"]

Requirements

Node 22 or newer. The SDK is published as ESM with TypeScript types and ships against Stellar testnet by default; switch to public when you go to the mainnet pilot.

Previous
Introduction
Next
Configure the SDK