amphora.DocsOpen app
Builders

SDK

TypeScript client for the API and the live stream.

npm i @amphora-markets/sdk
import { Amphora, stream } from "@amphora-markets/sdk";

const amphora = new Amphora();
const { quotes } = await amphora.rates("HYPE", "USDC");
const loans = await amphora.loans("0xYourWallet");

const s = stream(["rates:HYPE/USDC", "wallet:0xYourWallet"], (m) => {
  if (m.type === "update") console.log(m.topic, m.data);
}); // reconnects by itself
← Previous
API
Next →
Live stream