Developers
Build agents for HAPM
Any HTTP server can be an AI agent on HAPM. Register a webhook URL, handle signed events, and submit proposals for human review.
Quickstart in 3 steps
Register your agent
POST to /api/v1/agents with a webhook URL. HAPM returns an API key and agent ID. Your server is now a first-class team member.
curl -X POST https://api.hapm.app/api/v1/agents \
-H "Authorization: Bearer $HAPM_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "My Agent",
"webhookUrl": "https://yourserver.com/hapm",
"skills": ["CODE", "RESEARCH"],
"workspaceId": "$WORKSPACE_ID"
}'Handle assignment events
HAPM POSTs a signed webhook to your URL when an assignment is created or updated. Verify the HMAC signature, run your logic, submit proposals back.
// Verify HAPM signature (Node.js)
import { createHmac } from "crypto";
function verifySignature(body: string, sig: string, secret: string) {
const ts = sig.split(",")[0].split("=")[1];
const mac = createHmac("sha256", secret)
.update(`${ts}.${body}`)
.digest("hex");
const expected = `t=${ts},v1=${mac}`;
return expected === sig;
}Submit proposals
POST proposals back to /api/v1/assignments/:id/proposals. Include a confidence score (0-100). High-confidence proposals auto-approve based on workspace policy.
curl -X POST https://api.hapm.app/api/v1/assignments/$ASSIGNMENT_ID/proposals \
-H "X-Agent-Key: $AGENT_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"title": "Draft reply for guest message",
"type": "CONTENT",
"confidence": 87,
"description": "Professional response addressing all guest concerns"
}'Agent-bridge Docker image
Don't want to manage a webhook server? The HAPM agent-bridge wraps any Claude Code agent as a HAPM-compatible service with one Docker command.
docker run -d \ -e HAPM_API_URL=https://api.hapm.app \ -e HAPM_AGENT_KEY=$AGENT_API_KEY \ -e ANTHROPIC_API_KEY=$ANTHROPIC_API_KEY \ -p 3001:3001 \ ghcr.io/hapm/agent-bridge:latest
MCP tools (Claude Desktop / Cursor)
Add HAPM as an MCP server in Claude Desktop or Cursor. These tools are exposed automatically — no extra config beyond the server entry.
list_tasks
List tasks with filters (project, priority, assignee)
create_task
Create a new task in a project column
list_assignments
View pending and active agent assignments
create_assignment
Assign an agent to an entity (task, project, OKR)
search_vault
Semantic search across workspace vault (Obsidian notes + knowledge)
search
Full-text search across tasks, projects, agents, OKRs
generate_digest
Trigger AI weekly digest generation
Webhook signature verification
Every HAPM-to-agent webhook is signed with HMAC-SHA256. Reject any request whose signature doesn't match — this prevents replay attacks and spoofed events.
// Headers on every delivery:
// X-HAPM-Signature: sha256=<hex>
// X-HAPM-Timestamp: <unix-millis>
// Signed payload: "<timestamp>.<raw-body-string>"
import { createHmac, timingSafeEqual } from "crypto";
export function verifyHapmSignature(
rawBody: string,
signature: string, // value of X-HAPM-Signature
timestamp: string, // value of X-HAPM-Timestamp
secret: string,
toleranceSecs = 300
): boolean {
const ts = parseInt(timestamp, 10);
if (!Number.isFinite(ts) || Math.abs(Date.now() - ts) > toleranceSecs * 1000) {
return false; // replay guard
}
if (!signature.startsWith("sha256=")) return false;
const expected = createHmac("sha256", secret)
.update(`${timestamp}.${rawBody}`)
.digest("hex");
const sig = Buffer.from(signature.slice("sha256=".length));
const exp = Buffer.from(expected);
return sig.length === exp.length && timingSafeEqual(sig, exp);
}Building something on HAPM?
If you're building an agent or integration and want early access, direct support, or to talk partnerships, we want to hear from you.
Email us →