Add Agent to Team Command

The agent team add command adds an existing AI Agent to a team, enabling collaboration with other team members.

Usage

xpander agent team add <team_name> <agent_id> [--role <role>] [--config <json>]

Options

OptionDescription
--role <role>Optional. Agent’s role in the team: primary, secondary, or support
--config <json>Optional. Role-specific configuration in JSON format

Examples

Basic Agent Addition

xpander agent team add "Support Team" agent_123 --role primary

Response:

Adding Agent to Team
===================
Team: Support Team
Agent: Support Agent (agent_123)
Role: primary

Step 1/3: Validating
✓ Team exists and is active
✓ Agent is available
✓ Role is valid

Step 2/3: Configuring
✓ Team permissions applied
✓ Communication channels established
✓ Shared resources allocated

Step 3/3: Integration
✓ Agent added to team
✓ Role configuration applied
✓ Team state synchronized

Agent successfully added to team!

Advanced Role Configuration

xpander agent team add "Analytics Team" agent_234 \
  --role primary \
  --config '{
    "responsibilities": ["data_analysis", "report_generation"],
    "permissions": {
      "data_access": ["analytics_db", "reporting_tools"],
      "action_scope": ["read", "write", "execute"]
    },
    "collaboration": {
      "can_delegate": true,
      "supervision_level": "high",
      "subordinates": ["agent_235", "agent_236"]
    },
    "communication": {
      "broadcast_events": ["analysis_complete", "report_ready"],
      "notification_level": "all"
    }
  }'

Role-specific Configurations

Different roles can have different configurations:

Primary Role

{
  "responsibilities": ["string"],
  "permissions": {
    "data_access": ["string"],
    "action_scope": ["string"]
  },
  "collaboration": {
    "can_delegate": boolean,
    "supervision_level": "string",
    "subordinates": ["string"]
  }
}

Secondary Role

{
  "responsibilities": ["string"],
  "permissions": {
    "data_access": ["string"],
    "action_scope": ["string"]
  },
  "reporting_to": ["string"],
  "escalation_path": ["string"]
}

Support Role

{
  "responsibilities": ["string"],
  "permissions": {
    "data_access": ["string"],
    "action_scope": ["string"]
  },
  "availability": {
    "schedule": ["string"],
    "response_time": "string"
  }
}

Notes

  • Agents can be members of multiple teams
  • Role determines:
    • Agent’s responsibilities
    • Permission levels
    • Collaboration patterns
    • Communication channels
  • Default role is support if not specified
  • Configuration inherits team defaults if not specified
  • Use agent team list to verify team membership
  • Use agent team remove to remove an agent from a team