Build on
Nirium
TypeScript SDK, 44+ REST endpoints, MCP server for Claude/Cursor, and native support for x402 + MPP.
npm install niriumRegulatory Disclosure
Nirium is a non-custodial software infrastructure. We do not provide financial advice, manage third-party assets, or process fiat directly. All financial operations are executed on the Stellar network by the user via non-custodial wallets. Regulatory compliance for fiat operations is handled by our third-party regulated partners in alignment with local laws (e.g., Art. 80 Ley Fintech).
Quickstart: 5 Lines
Autonomous rebalancing + cross-border in production.
import { NiriumAgent } from "nirium";
const agent = new NiriumAgent({ apiKey: process.env.NIRIUM_API_KEY });
// Rebalance: keep 60% in CETES (gov. rate), 40% USDC (liquid)
await agent.rebalance({ cetes: 60, usdc: 40 });
// Send cross-border: USD → MXN receiver gets USDC instantly
await agent.transfer({ to: "G...", amount: 1000, asset: "USDC" });Agentic Payments
x402 for per-call micropayments. MPP for session budgets, passive funding, and mass payroll.
x402 — Per-call Payment
Linux Foundation Standard
import { NiriumAgent } from "nirium";
const agent = new NiriumAgent({ apiKey: process.env.NIRIUM_API_KEY });
// x402: per-call payment — agent pays $0.05 per API call automatically
const result = await agent.callPaidEndpoint({
url: "https://api.example.com/data",
maxFee: "0.05", // USD, reject if server asks more
asset: "USDC",
});MPP — Budget Session
Stripe/Tempo Spec
import { NiriumAgent } from "nirium";
const agent = new NiriumAgent({ apiKey: process.env.NIRIUM_API_KEY });
// MPP session: pre-authorize $10 budget, pay per use
const session = await agent.openMPPSession({
vendor: "G...", // vendor Stellar address
budget: "10", // USDC budget
maxPerCall: "0.05",
});
await session.call("/analyze"); // deducts $0.05
await session.call("/summarize"); // deducts $0.05
await session.settle(); // returns unspent balance
| Feature | x402 | MPP Charge | MPP Channel |
|---|---|---|---|
| On-chain tx per call | ✓ | ✓ | ✗ |
| Needs facilitator | ✓ | ✗ | ✗ |
| Client needs XLM | ✗ | Opt. | ✓ |
| Best for | Quick setup | No 3rd party | High-freq |
MCP Server
Claude & Cursor
Connect your Claude Desktop or Cursor instance to your vault in 2 minutes. Enable your AI assistant to manage capital, query rates, and sign audit trails directly.
// Claude Desktop config (~/.claude/claude_desktop_config.json)
{
"mcpServers": {
"nirium": {
"command": "npx",
"args": ["@nirium/mcp-server"],
"env": {
"NIRIUM_API_KEY": "your_key_here"
}
}
}
}12 Real-world Tools
nirium_get_vault_statusGet balances, rates, and pending operations
nirium_rebalanceRebalance USDC↔CETES with target allocation
nirium_transferSend cross-border payment to any Stellar address
nirium_get_ratesGet live CETES rate and USDC lending rates
nirium_audit_logQuery audit trail (last N records)
nirium_export_cnbvExport CNBV-format compliance report
nirium_create_vaultDeploy new Soroban multisig vault
nirium_pause_vaultEmergency vault pause (requires 2-of-3)
Execution Hub
44+ Endpoints architected for institutional autonomous treasury and audit trails.
Core Infrastructure
/v1/agent/rebalanceTrigger USDC↔CETES rebalance
/v1/agent/transferCross-border USDC transfer
/v1/vault/statusGet vault balances + rates
/v1/vault/createDeploy new 2-of-3 Soroban vault
/v1/vault/pauseEmergency pause (2-of-3 required)
/v1/vault/withdrawWithdraw >$10K (2-of-3 required)
/v1/x402/challengeCreate x402 payment challenge
/v1/x402/verifyVerify x402 payment proof
Protocol Explorer
Auth & Security
/api/auth/token/api/auth/keys/api/health/api/authenticateTreasury Engine
/api/loop/start/api/loop/stop/api/execute/api/loop/statusCompliance & IPFS
/v1/compliance/audit/v1/compliance/ipfs/v1/compliance/export/v1/compliance/verify/:cidMarket Intelligence
/api/market/api/tickers/api/strategies/api/signals/recent+18 Additional subsystems for Fleet Orchestration
Verified Nodes
Immutable smart contracts deployed on Stellar Testnet.
CAU2XBJTQUBTMPAUFRX7GMZ337I5WLBI4GYPWHZEVXTMJ66D3CP6DEL4CC6Z3WJWRKVEAXEKIQ5S3LFEMKRF4L2FTN5YZDQU27MQRQAWA5QBJWF2CB6Q3LKBJ7CAAZY4MK7EG5R6FDDTJHB52ZEENI6BQLBJNFKBQRIAUABCCCP5OY3TTDVIREQYGOUZUXS2MZJO3LLJD6Z22Z3VROWFCPJAON22WPY2CANZP2OJUS2Y5VXE4YHRR75LE2WKE7QTJOCCWENR7X65DWE6QEJZV6KSCB4JM3PP7GWKJUAYIZ7ZULWFTFJ57FTTUFZTFIDF4JCAPF664OJCXIEICC72F57YTPX76HAA64JQOEGHQAPSADQWSY5DWVBR66JINPFDLNCQYHICCBIELTK6YBZJU5UP2WWQEQ4YkVDt3QOF4D7TaNz5WBqVIJgF57e