v2.2.0
npmjs
Highlight — a single email_passwordless provider with a known email (loginHint) now logs the user in without opening the selection modal.
✨ Changes
Email Passwordless without a modal. When a single
email_passwordlesslogin provider is configured together with aloginHint(the user's email, known in advance),login()now starts the passwordless flow directly and skips the login-provider selection modal.New
loginHintoption, accepted both on the constructor config and on the per-calllogin()override.If
loginHintis missing or not a valid email, the modal opens as before — so the behaviour is safe to adopt incrementally.
Quieter by default — new
debugflag. The SDK no longer prints verbose logs to the browser console. Passdebug: truein the constructor config to re-enable detailed logging while developing.mfaLevelis deprecated. It has no effect since Torus-embed v6 (the underlying ws-embed API has no MFA-level support). Existing code that passesmfaLevelkeeps working, but the option is ignored.
const sdk = new Startrail({
env: 'staging',
loginProvider: ['email_passwordless'],
loginHint: 'user@example.com', // known email → passwordless starts directly, no modal
})
await sdk.login()🤖 Agent & LLM friendly
This release ships first-class resources so AI coding tools (Claude, Cursor, Copilot, …) integrate the SDK correctly with minimal context.
📄 llms.txt
Machine-readable API reference — install, lifecycle, every method signature, the environment table and the error catalogue.
Bundled in the npm package
node_modules/@startbahn/startrail-sdk-js/llms.txt
🤖 AGENTS.md
Rules + the canonical construct → login → action pattern for agents writing code against the SDK.
In the SDK source repository
💬 Typed TSDoc
Rich hover docs and autocomplete on the public class and request/response types, straight from your editor.
Bundled in the package types
🛠️ Internal
Migrated the build/release toolchain from Yarn to pnpm 11 (Node 22) and refreshed the lint/build config. No change to how you install or consume the package.
Refactored the Torus login flow (more reliable early-EOA return) and resolved outstanding Dependabot security alerts.
Last updated
Was this helpful?