Skip to content
Private SDK

TypeScript native client

Install from authorized private Argand source. These SDKs are not published on external package registries.

Hosted MCP endpoint

Streamable HTTP
Server URL text
https://beta.argand.org/api/mcp

No local install needed. Configure your own instance URL to self-host.

Run the checked-in example

Use a reviewed signed checkout. The SDK paths below are part of that checkout; you need private Forgejo access. Dependencies may be obtained from their normal sources, but no Argand package is uploaded by these commands.

Run the checked-in example bash
cd sdk/typescript
pnpm install --ignore-workspace --frozen-lockfile --ignore-scripts
pnpm typecheck
pnpm test
pnpm build
node examples/native-search.mjs rust

Keep the actual evidence

This is the current checked-in native Search example. Set ARGAND_API_BASE for a different instance. Titles can be absent; source evidence and serving collection remain available.

Native Search example javascript
import { ArgandClient } from "../dist/index.js";

const client = new ArgandClient({
  baseUrl: process.env.ARGAND_API_BASE ?? "https://beta.argand.org",
  retry: { maxAttempts: 1 },
});
const response = await client.search(process.argv[2] ?? "rust", { vertical: "web" });
if (!response.collection_id || response.results.length === 0) {
  throw new Error("Native Search returned no collection identity or source results");
}
console.log(JSON.stringify({
  collection_id: response.collection_id,
  source_count: response.results.length,
  total_results: response.total_results,
  sources: response.results.map(hit => ({
    doc_id: hit.doc_id, url: hit.url, title: hit.title,
    score: hit.score, provenance: hit.provenance,
  })),
}, (_key, value) => typeof value === "bigint" ? value.toString() : value, 2));

Error and precision contracts

Responses are bounded to two MiB decoded data. The SDKs validate required native evidence and refuse unsupported operations; they do not fabricate successful results after failures. Python and Rust retain integer coordinates. TypeScript retains large integers as BigInt where native JSON token context is available, or refuses unsafe values. Its decimal-string JSON export preserves their digits.

HTTP client or MCP client?

These SDKs read native Search HTTP responses. Use a standards-compatible MCP client when you need tools/call or resources/read. Captured-source fetch and citation are MCP contracts, not implemented SDK REST methods.