<!-- source-hash: a990391bb43e6e44b547ca32debddb41 -->
Defines unified platform types used across announcements, blog posts, and platform configuration throughout the Flamingo/OpenFrame stack.

## Key Components

| Export | Type | Description |
|--------|------|-------------|
| `PlatformName` | `type` | Union of all valid platform identifiers (e.g. `'flamingo'`, `'openframe'`, `'openmsp'`) |
| `PlatformRecord` | `interface` | Full database model from the `platforms` table, including chat/RAG wiring fields |
| `PlatformConfig` | `interface` | API-facing configuration shape with display metadata (color, icon, description) |
| `PlatformOption` | `interface` | Minimal `value`/`label` pair for dropdowns and filter UIs |
| `PlatformFilter` | `type` | Extends `PlatformName` with an `'all'` wildcard for filter contexts |
| `LegacyPlatform` | `type` | Backward-compatible alias scoped to the original three platforms |
| `PlatformStats` | `interface` | Aggregate counts of announcements and blog posts per platform |

## Usage Example

```typescript
import type { PlatformName, PlatformRecord, PlatformFilter } from './platform';

// Type-safe platform reference
const platform: PlatformName = 'openframe';

// Filter selection (includes 'all' wildcard)
const filter: PlatformFilter = 'all';

// Working with a database record
const record: PlatformRecord = {
  id: 'uuid-123',
  name: 'flamingo',
  display_name: 'Flamingo',
  is_active: true,
  is_internal: false,
  chat_source_id: 'src-abc',
  chat_source_rag_tables_version: 3,
  chat_enabled: true,
  created_at: '2024-01-01T00:00:00Z',
  updated_at: '2024-01-01T00:00:00Z',
};
```

> `chat_source_rag_tables_version` is bumped by the `replace_chat_source_rag_tables` RPC and drives cross-Lambda cache invalidation — do not modify this field manually.