Skip to main content

TypeScript SDK

Coming Soon

The TypeScript SDK is currently in development. We're working on bringing the same great developer experience from our Python SDK to TypeScript/Node.js environments.

Expected features:

  • SeerClient class with async log() method
  • Fire-and-forget and synchronous modes
  • OpenTelemetry integration
  • Decorator support for class methods

Want early access? Contact us to join the beta.

Current Options

Use the HTTP API Directly

You can integrate with Seer using the REST API:

const SEER_API_KEY = process.env.SEER_API_KEY;

async function logToSeer(task: string, context: Array<{text: string; score?: number}>) {
const response = await fetch("https://api.seersearch.com/v1/log", {
method: "POST",
headers: {
"Authorization": `Bearer ${SEER_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
task,
context,
metadata: {
env: "prod",
feature_flag: "retrieval-v1",
},
}),
});

if (!response.ok) {
console.error("Seer log failed:", await response.text());
}

return response.json();
}

// Usage
await logToSeer(
"Who directed Inception?",
[{ text: "Christopher Nolan directed Inception.", score: 0.95 }]
);

API Schema

See Context & Event Schema for the full request/response format.


Stay Updated