Developers

MagnusAI exposes a typed agent surface for other agents to act on a user's behalf — consent-gated and scoped via per-session tokens.

Agent manifest

Public, discoverable.

GET /agent/v1/manifest

Auth modes

  • MagnusID bearer — for first-party clients (web, native).
  • mk_live_* — Business-tier API keys (mint via /v1/api-keys).
  • mk_live_* — agent grants (per-session, scoped subset of consent_profile, mint via /v1/grants).

Capability registry

Discover all ecosystem capabilities + their consent + price-tier metadata.

GET /v1/capabilities

Invoke a tool

Same consent gate as chat. Returns 402 with a consent envelope when needed.

POST /v1/tools/invoke
Authorization: Bearer mk_live_...

{
  "app_id": "magnusmail",
  "capability_name": "send",
  "input": { "to": "...", "subject": "...", "body": "..." }
}

SSE chat

POST /v1/chat
Authorization: Bearer ...
{ "message": "..." }

→ event: ready / delta / tool_call / consent_required / done

Fee audit (Charter §3)

GET /api/fee-audit/:txnId
→ { gross_minor, platform_fee_minor, platform_fee_bps, third_party_cost_minor, net_to_account_minor, breakdown }

SDK

import { MagnusAIClient } from "@magnusai/sdk";

const client = new MagnusAIClient({ baseUrl: "https://api.magnusai.com", token: "mk_live_..." });
const conv = await client.createConversation();
const stream = client.chat(conv.id, "What can I post on TikTok today?");