This is the initial commit for the CODEX_ADK project, a full-stack AI agent management platform featuring: BACKEND (ASP.NET Core 8.0): - CQRS architecture with 6 commands and 7 queries - 16 API endpoints (all working and tested) - PostgreSQL database with 5 entities - AES-256 encryption for API keys - FluentValidation on all commands - Rate limiting and CORS configured - OpenAPI/Swagger documentation - Docker Compose setup (PostgreSQL + Ollama) FRONTEND (Flutter 3.x): - Dark theme with Svrnty branding - Collapsible sidebar navigation - CQRS API client with Result<T> error handling - Type-safe endpoints from OpenAPI schema - Multi-platform support (Web, iOS, Android, macOS, Linux, Windows) DOCUMENTATION: - Comprehensive API reference - Architecture documentation - Development guidelines for Claude Code - API integration guides - context-claude.md project overview Status: Backend ready (Grade A-), Frontend integration pending 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
73 lines
1.9 KiB
C#
73 lines
1.9 KiB
C#
using System.Text.Json;
|
|
using Codex.Dal.Enums;
|
|
|
|
namespace Codex.Dal.Entities;
|
|
|
|
/// <summary>
|
|
/// Represents a tool or API integration available to an agent.
|
|
/// One-to-many relationship: each agent has its own tool configurations.
|
|
/// </summary>
|
|
public class AgentTool
|
|
{
|
|
/// <summary>
|
|
/// Unique identifier for this tool instance
|
|
/// </summary>
|
|
public Guid Id { get; set; }
|
|
|
|
/// <summary>
|
|
/// Foreign key to the owning agent
|
|
/// </summary>
|
|
public Guid AgentId { get; set; }
|
|
|
|
/// <summary>
|
|
/// Name of the tool (e.g., "file_reader", "code_executor", "github_api")
|
|
/// </summary>
|
|
public string ToolName { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Type of tool
|
|
/// </summary>
|
|
public ToolType Type { get; set; }
|
|
|
|
/// <summary>
|
|
/// Tool-specific configuration stored as JSON (e.g., API endpoints, file paths, MCP server URLs)
|
|
/// </summary>
|
|
public JsonDocument? Configuration { get; set; }
|
|
|
|
/// <summary>
|
|
/// MCP server URL (if Type is McpServer)
|
|
/// </summary>
|
|
public string? McpServerUrl { get; set; }
|
|
|
|
/// <summary>
|
|
/// Encrypted authentication token for MCP server (if required)
|
|
/// </summary>
|
|
public string? McpAuthTokenEncrypted { get; set; }
|
|
|
|
/// <summary>
|
|
/// Base URL for REST API (if Type is RestApi)
|
|
/// </summary>
|
|
public string? ApiBaseUrl { get; set; }
|
|
|
|
/// <summary>
|
|
/// Encrypted API key for REST API (if required)
|
|
/// </summary>
|
|
public string? ApiKeyEncrypted { get; set; }
|
|
|
|
/// <summary>
|
|
/// Whether this tool is enabled for use
|
|
/// </summary>
|
|
public bool IsEnabled { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// When this tool was added to the agent
|
|
/// </summary>
|
|
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
|
|
|
// Navigation properties
|
|
/// <summary>
|
|
/// The agent that owns this tool
|
|
/// </summary>
|
|
public Agent Agent { get; set; } = null!;
|
|
}
|