API & MCP
Use Spencer from Eden programmatically. Your clinic's software gets the REST API, your AI assistant gets the MCP endpoint — both do exact draw math on the values you supply and answer catalog facts, nothing more.
Your key
Every request to the API and the MCP endpoint carries your clinic's key. Enter your clinic slug — the last part of your clinic's access link — and generate it here.
One key per clinic. Treat it like a password — Spencer can rotate access.
REST API
Three endpoints, JSON in and out, authorized with Authorization: Bearer <your key>. The calculator does math on the values your system supplies and the catalog serves published facts — nothing else.
POST /api/v1/calculateDraw math on the values your system supplies.GET /api/v1/catalogThe Eden catalog — filter with ?q= and ?category=.GET /api/v1/catalog/{id}One catalog entry by product id.curl -X POST https://spencerfromeden.com/api/v1/calculate \
-H "Authorization: Bearer sfe_yourclinic_…" \
-H "Content-Type: application/json" \
-d '{
"supply": "lyophilized",
"vialMg": 10,
"diluentMl": 2,
"dose": 500,
"doseUnit": "mcg",
"syringeId": "u100_100"
}'{
"drawUnits": 10,
"drawMl": 0.1,
"concentrationMgPerMl": 5,
"dosesPerVial": 20,
"warnings": [],
"disclaimer": "Calculated from caller-supplied values. Not medical advice; verify independently. Never a dose suggestion."
}MCP
MCP connects your AI assistant — Claude, or anything else that speaks the Model Context Protocol — directly to the calculator and catalog. Point the assistant at the endpoint below with your key, and it can run exact draw math and look up catalog facts itself instead of guessing.
{
"mcpServers": {
"spencer-from-eden": {
"type": "http",
"url": "https://spencerfromeden.com/api/mcp/mcp",
"headers": {
"Authorization": "Bearer sfe_yourclinic_…"
}
}
}
}Endpoint https://spencerfromeden.com/api/mcp/mcp (streamable HTTP)
Header Authorization: Bearer sfe_yourclinic_…calculate_drawRuns the same draw math as the on-site calculator on values the assistant supplies.search_catalogSearches the Eden catalog by name or category.get_productReturns the full catalog entry for a product id.Embed
Drop the calculator straight into your clinic's intranet or portal with a single iframe.
<iframe
src="https://spencerfromeden.com/?embed=1"
title="Spencer from Eden calculator"
width="100%"
height="720"
style="border: 0;"
></iframe>Embed mode is coming soon — the snippet above will work as-is the moment it goes live.