Use the first-party Python SDK where you want client ergonomics, and call the main TrendsAGI HTTPS API directly from JavaScript and TypeScript runtimes. This page lists the required credentials, setup example, mapped endpoints, and production notes.
Base URL
https://api.trendsagi.com114
Routes
16
Guides
3
Languages
Official Python package plus direct REST for JavaScript
Use the first-party Python SDK where you want client ergonomics, and call the main TrendsAGI HTTPS API directly from JavaScript and TypeScript runtimes.
Install
# No TrendsAGI package required
# Use native fetch in Node.js 18+ or modern browsersRequired credentials
const API_BASE_URL = process.env.API_BASE_URL ?? "https://api.trendsagi.com";
const apiKey = process.env.TRENDSAGI_API_KEY;
if (!apiKey) throw new Error("Set TRENDSAGI_API_KEY first");
async function main() {
const response = await fetch(`${API_BASE_URL}/api/trends?category=Technology&limit=5`, {
headers: { Authorization: `Bearer ${apiKey}` },
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const signals = await response.json();
console.log((signals.trends ?? []).map((signal) => signal.name));
}
main().catch(console.error);# Save as quickstart.mjs
node quickstart.mjs1. Install
Add SDK/dependency for this integration path.
2. Authenticate
Set API key and any provider-specific credentials.
3. Map Endpoints
Use mapped endpoints below to build deterministic flow.
4. Harden
Add rate-limit backoff, idempotency, and safety gates.
Endpoint Mapping
Each integration is mapped to specific API endpoints so teams can compose deterministic workflows.
Production Notes