Skip to content
Termbook
Getting started

Build with Termbook

Credit inside Monad applications, backed by source collateral and recoverable app assets.

On this page

How it works

A borrower accepts a House offer, locks collateral and activates a facility. A draw sends USDC from the House to the Credit Account and executes an approved app action. Purchased assets and positions remain under that account’s control until repayment and closure.

From credit to an app action

Loading diagram…

Accept terms and prove collateral once. A ready facility can fund approved actions, then close through exit, repayment and collateral return.

From credit to an app action

Accept terms and prove collateral once. A ready facility can fund approved actions, then close through exit, repayment and collateral return.

Credit can exceed source collateral value when verified app assets provide enough recoverable backing. Each draw must pass the House’s limits and the post-action health check.

Choose your path

Participants

RoleResponsibility
BorrowerAccepts terms, locks collateral and authorizes account actions.
ApplicationBuilds approved actions and describes its holdings, obligations and exit path.
HouseProvides credit, chooses risk limits and bears its allocated lending losses.
LPSupplies the House’s settlement asset and holds shares in its net assets.
KeeperRelays proofs or executes authorized recovery and settlement steps.
GovernanceAdmits integrations and configures or upgrades protocol components.

Your first action

The SDK supplies evm_wallet to adapt your app’s connected viem WalletClient. Pass that client to open_credit. The modal connects the collateral wallet during setup.

app.ts · call from a browser click handler
import { create_termbook, evm_wallet } from "@termbook/sdk";
import type { WalletClient } from "viem";

export async function open_credit(wallet_client: WalletClient) {
  const termbook = create_termbook({
    app_token: process.env.NEXT_PUBLIC_TERMBOOK_APP_TOKEN!,
    wallet: await evm_wallet(wallet_client),
  });

  const modal = termbook.open({
    action: {
      use_case: "spot",
      capability: "place_order",
      params: {
        market_id: "0x1f57a841540fe23c2989387c18f2cb1335cbae92",
        direction: "buy",
        order_type: "market",
        amount: { spend: 10_000n },
        slippage_bps: 50,
      },
    },
  });

  await modal.ready;
  return modal;
}

This requests a 0.01 USDC spend with 0.5% slippage on the testnet Kuru market. The borrower reviews the offer and approves each required signature. Opening the modal does not automatically borrow.

Documentation
8 results

Let’s talk

Tell us what you have in mind.

Supply liquidity