Wallet
Local-first wallet backed by an encrypted vault. Desktops use the OS keychain by default; headless environments can use password-derived encryption.
import { Wallet } from "steelyard/buyer";
const wallet = await Wallet.create({
project: true,
password: "your-vault-password",
card: { number: "4242424242424242", exp: "12/30", name: "Buyer" },
billing: {
email: "buyer@example.com",
address: {
line1: "1 Market St",
city: "San Francisco",
postal_code: "94105",
country: "US",
},
},
limits: { daily: { USD: 100 } },
allowedMerchants: ["coffee.example"],
});
// Reopen later — vault is on disk, unlocked via OS keychain or password.
// await wallet.close();
// const reopened = await Wallet.open({
// project: true,
// password: "your-vault-password",
// });