Skip to main content

Team Management

Teams are first-class meta-agents in Mnemom. Create a team, add agents, derive a collective alignment card, and monitor team reputation — all through the API or dashboard. This guide covers the full team lifecycle: creation, roster management, alignment cards, reputation monitoring, and team badges.
Team operations require the team_reputation feature flag, available on Team and Enterprise plans. See Pricing for details.

Quick Start

Create a team, add members, and derive a card in three API calls:
import { createTeam, deriveTeamCard } from '@mnemom/teams';

// 1. Create a team with initial members
const team = await createTeam({
  org_id: 'org-abc123',
  name: 'Support Pipeline Alpha',
  description: 'Customer support agent team',
  agent_ids: ['agent-a', 'agent-b', 'agent-c'],
});

console.log(`Team created: ${team.team.id}`);
console.log(`Members: ${team.members.length}`);

// 2. Derive a team alignment card from member cards
const derived = await deriveTeamCard(team.team.id);
console.log(`Card derived from ${derived.members_with_cards} members`);
console.log(`Card source: ${derived.card_source}`);

Team Lifecycle

Create → Add Members → Derive Card → Monitor Reputation → Archive
  │          │              │               │                 │
  ▼          ▼              ▼               ▼                 ▼
POST      POST           POST           GET              DELETE
/teams    /members       /card/derive   /reputation      /teams/{id}

1. Create a Team

Teams require an organization, a name, and at least 2 initial members (max 50).
curl -X POST https://api.mnemom.ai/v1/teams \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "org_id": "org-abc123",
    "name": "Support Pipeline Alpha",
    "description": "Customer support agent team",
    "agent_ids": ["agent-a", "agent-b", "agent-c"],
    "metadata": { "environment": "production", "domain": "support" }
  }'
Team names must be unique within an organization. The response includes the team object and the initial member list.

2. Manage Roster

Add or remove members as your team evolves. Every roster change is logged in the audit trail. Add members:
curl -X POST https://api.mnemom.ai/v1/teams/{team_id}/members \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ "agent_ids": ["agent-d", "agent-e"] }'
The response tells you which agents were added and which were already members (idempotent). Remove a member:
curl -X DELETE https://api.mnemom.ai/v1/teams/{team_id}/members/{agent_id} \
  -H "Authorization: Bearer $TOKEN"
Teams must have at least 2 members. Removing the second-to-last member will fail with a 400 error. Archive the team instead if it’s no longer needed.
View roster history:
curl https://api.mnemom.ai/v1/teams/{team_id}/roster-history \
  -H "Authorization: Bearer $TOKEN"
Returns a paginated audit trail of all roster changes with timestamps, change types, and actors.

3. Team Alignment Cards

Team alignment cards declare the team’s collective values, autonomy boundaries, and coordination mode. There are two approaches: Auto-derive from members (recommended):
curl -X POST https://api.mnemom.ai/v1/teams/{team_id}/card/derive \
  -H "Authorization: Bearer $TOKEN"
The derivation algorithm merges member cards:
  • Values are unioned and ordered by frequency
  • Forbidden actions from any member apply to the team
  • The strictest audit retention policy wins
  • Requires at least 2 members with active alignment cards
Set manually:
curl -X PUT https://api.mnemom.ai/v1/teams/{team_id}/card \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "principal": {
      "type": "organization",
      "identifier": "org-abc123",
      "relationship": "delegated_authority"
    },
    "values": {
      "declared": ["reliability", "transparency", "user_safety"]
    },
    "autonomy_envelope": {
      "bounded_actions": ["respond_to_customer", "escalate_ticket"],
      "forbidden_actions": ["delete_customer_data", "modify_billing"],
      "escalation_triggers": ["customer_complaint", "refund_request_over_100"]
    },
    "audit_commitment": {
      "retention_days": 90
    }
  }'
View card history:
curl https://api.mnemom.ai/v1/teams/{team_id}/card/history \
  -H "Authorization: Bearer $TOKEN"

4. Monitor Reputation

Once your team has 10+ risk assessments, a Team Trust Rating is published.
curl https://api.mnemom.ai/v1/teams/{team_id}/reputation
Track score trends over time:
curl https://api.mnemom.ai/v1/teams/{team_id}/reputation/history
See Team Trust Rating for details on the 5-component scoring model.

5. Archive a Team

Archiving soft-deletes the team. Historical data and reputation scores are preserved.
curl -X DELETE https://api.mnemom.ai/v1/teams/{team_id} \
  -H "Authorization: Bearer $TOKEN"

Team Badges

Embed team reputation badges anywhere — READMEs, documentation, dashboards.
GET https://api.mnemom.ai/v1/teams/{team_id}/badge.svg?variant={variant}
Six badge variants are available:
VariantDisplay
score[ Team Trust | 812 ]
grade[ Team Trust | AA ]
score_grade[ Team Trust | AA 812 ]
score_trend[ Team Trust | AA 812 ↑ ]
score_tier[ Mnemom Team | 812 Established ]
compact[ AA ]
Pre-eligible teams (fewer than 10 assessments) show a progress badge:
[ Team Trust | Building 4/10 ]
Markdown embed:
[![Team Trust Rating](https://api.mnemom.ai/v1/teams/team-abc123/badge.svg?variant=score)](https://www.mnemom.ai/teams/team-abc123/reputation)
HTML embed:
<a href="https://www.mnemom.ai/teams/team-abc123/reputation">
  <img src="https://api.mnemom.ai/v1/teams/team-abc123/badge.svg?variant=score"
       alt="Team Trust Rating" />
</a>
React:
function TeamBadge({ teamId }) {
  const badgeUrl = `https://api.mnemom.ai/v1/teams/${teamId}/badge.svg?variant=score`;
  const pageUrl = `https://www.mnemom.ai/teams/${teamId}/reputation`;

  return (
    <a href={pageUrl} target="_blank" rel="noopener noreferrer">
      <img src={badgeUrl} alt="Team Trust Rating" />
    </a>
  );
}
Badges are cached for 60 minutes at the CDN edge. For real-time data, use the API directly.

RBAC Requirements

OperationRequired Role
Create teamowner or admin
Update teamowner or admin
Archive teamowner or admin
Add/remove membersowner or admin
Set team cardowner or admin
Derive team cardowner or admin
View team detailsAny org member
View roster historyAny org member
View card historyAny org member
View reputationPublic (no auth for public teams)

Feature Requirements

Team operations require the team_reputation feature flag:
PlanTeam Features
FreeNot available
DeveloperNot available
Team200 team reputation computations included/mo ($0.005/ea overage)
EnterpriseUnlimited

See Also