import { AlertTriangle, CheckCircle2, Folder, Info, Route, ShieldCheck, TerminalSquare, XCircle, } from 'lucide-react'; import { QuickCommands } from '@/components/shared'; import { Badge } from '@/components/ui/badge'; import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'; import { ScrollArea } from '@/components/ui/scroll-area'; import { Separator } from '@/components/ui/separator'; import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow, } from '@/components/ui/table'; import type { CodexDashboardDiagnostics } from '@/hooks/use-codex-types'; import { cn } from '@/lib/utils'; const CLIPROXY_NATIVE_CODEX_RECIPE = `model_provider = "cliproxy" [model_providers.cliproxy] base_url = "http://127.0.0.1:8317/api/provider/codex" env_key = "CLIPROXY_API_KEY" wire_api = "responses"`; function formatTimestamp(value: number | null | undefined): string { if (!value || !Number.isFinite(value)) return 'N/A'; return new Date(value).toLocaleString(); } function formatBytes(value: number | null | undefined): string { if (!value || value <= 0) return '0 B'; if (value < 1024) return `${value} B`; if (value < 1024 * 1024) return `${(value / 1024).toFixed(1)} KB`; return `${(value / (1024 * 1024)).toFixed(2)} MB`; } function DetailRow({ label, value, mono = false, }: { label: string; value: string; mono?: boolean; }) { return (
{label} {value}
); } interface CodexOverviewTabProps { diagnostics: CodexDashboardDiagnostics; } export function CodexOverviewTab({ diagnostics }: CodexOverviewTabProps) { return (
How Codex works in CCS

Codex is a first-class runtime target in CCS, but it stays runtime-only in v1.

ccs-codex and ccsx launch native Codex against your saved native config, while ccsxp is the opinionated shortcut for{' '} ccs codex --target codex.

Plain codex or a personal alias like cxp needs{' '} model_provider = "cliproxy" plus a matching{' '} [model_providers.cliproxy] entry if you want CLIProxy as the saved native default.

Saved default targets for API profiles and variants still remain on Claude or Droid.

CCS-backed Codex launches can apply transient -c overrides and inject CCS_CODEX_API_KEY, so effective runtime values may not match this file exactly.

Runtime install
Status {diagnostics.binary.installed ? 'Detected' : 'Not found'}
--config override support {diagnostics.binary.supportsConfigOverrides ? 'Available' : 'Missing'}
CLIProxy-backed native Codex

There are two supported paths. Use ccsxp if you want the built-in CCS Codex provider shortcut. Use the saved recipe below if you want plain{' '} codex or a personal alias like cxp to default to CLIProxy.

Saved native Codex recipe

                {CLIPROXY_NATIVE_CODEX_RECIPE}
              

1. Save a provider named cliproxy with the base URL and env key above.

2. In Top-level settings, set Default provider to{' '} cliproxy.

3. Export CLIPROXY_API_KEY in your shell before launching native Codex.

Config file
User config {diagnostics.file.exists ? ( ) : ( )}
{diagnostics.file.parseError && (

TOML warning: {diagnostics.file.parseError}

)} {diagnostics.file.readError && (

Read warning: {diagnostics.file.readError}

)}
Current user-layer summary
providers: {diagnostics.config.modelProviderCount} profiles: {diagnostics.config.profileCount} enabled features: {diagnostics.config.enabledFeatures.length} MCP servers: {diagnostics.config.mcpServerCount}
{diagnostics.config.topLevelKeys.length > 0 && (

User-layer keys present

{diagnostics.config.topLevelKeys.map((key) => ( {key} ))}
)}
Runtime vs provider

Native Codex runtime

Use ccs-codex, ccsx, or --target codex when you want the local Codex CLI to honor your saved native user config.

CCS Codex provider / bridge

Use ccsxp or ccs codex --target codex when you want the built-in CCS Codex provider on native Codex. That path uses transient CCS-managed overrides and is separate from the saved cliproxy recipe above.

Supported flows Flow Status Notes {diagnostics.supportMatrix.map((entry) => ( {entry.label} {entry.supported ? 'Yes' : 'No'} {entry.notes} ))}
{diagnostics.warnings.length > 0 && ( Warnings {diagnostics.warnings.map((warning) => (

- {warning}

))}
)}
); }