Loading...
Public API + Embed SDK
Cognition tracks knowledge retention with Weibull forgetting curves. Add retention intelligence to any LMS, dashboard, or internal tool with our API and embeddable components.
Integration Options
Give your team a link. They log in and see their brain health. Zero integration, works in 5 minutes.
Zero code requiredOne script tag. Three web components. Drop retention gauges, heatmaps, and risk tables into your existing dashboard.
One script tagFull API access. Build custom dashboards, pipe data into your analytics stack, trigger alerts on retention drops.
Full controlEmbed SDK
Web Components with Shadow DOM. Works in React, Vue, Angular, or plain HTML. Style with CSS variables to match your brand.
<cognition-retention-gauge>Circular gauge showing org or student retention %
<cognition-heatmap>Domain-by-domain retention breakdown with bars
<cognition-risk-table>Sortable table of at-risk students
<script src="https://cognitionus.com/sdk/cognition-embed.js"></script>
<cognition-retention-gauge
data-api-key="cog_live_xxx"
/>
<cognition-heatmap
data-api-key="cog_live_xxx"
/>
<cognition-risk-table
data-api-key="cog_live_xxx"
data-threshold="40"
/>:root {
--cognition-success: #22c55e;
--cognition-warning: #f97316;
--cognition-danger: #ef4444;
--cognition-bg: #ffffff;
--cognition-radius: 12px;
--cognition-font: system-ui, sans-serif;
}curl -H "Authorization: Bearer cog_live_xxx" \
https://www.cognitionus.com/api/v1/brain/overview
{
"success": true,
"data": {
"retention": {
"current": 72,
"strong": 120,
"fading": 45,
"critical": 12
},
"memberCount": 28,
"totalNodes": 177
}
}REST API
Every endpoint returns a consistent envelope. Rate-limited at 1,000 req/hr per key. All responses include CORS headers.
| Method | Endpoint |
|---|---|
| GET | /api/v1/brain/overviewOrg-wide retention, member count, top topics |
| GET | /api/v1/brain/studentsPaginated student list with retention scores |
| GET | /api/v1/brain/students/{email}Individual brain state + topic breakdown |
| GET | /api/v1/brain/domainsRetention by domain across the org |
| GET | /api/v1/brain/at-riskStudents below retention threshold |
| POST | /api/v1/webhooksRegister webhook for retention alerts |
Webhooks
Register a URL. We POST when retention drops below your threshold. HMAC-signed payloads, configurable event types, automatic retries.
retention.alertstudent.at_riskweekly.digestdomain.decayPOST /api/v1/webhooks
{
"url": "https://your-app.com/hooks/cognition",
"events": ["retention.alert", "student.at_risk"]
}
// We POST to your URL when:
// → A student drops below 40% retention
// → A domain starts decaying across the org
// → Weekly retention digest is readyCreate an API key, add one script tag, and see retention data flowing in minutes. Free during beta.
Quick Start
# 1. Get your API key from the dashboard # 2. Add the script tag to your page <script src="https://cognitionus.com/sdk/cognition-embed.js"></script> <cognition-retention-gauge data-api-key="YOUR_KEY" /> # 3. Or use the API directly curl -H "Authorization: Bearer YOUR_KEY" \ https://www.cognitionus.com/api/v1/brain/overview
Community
SDKs