<!-- source-hash: c8f0ef8e845d23e96bf312d6c54a2314 -->
This TypeScript file defines interfaces for managing access code cohorts, which are time-based groups that control user access through invitation codes. It provides type definitions for cohort management, access code validation, and membership tracking.

## Key Components

**Core Entities:**
- `AccessCodeCohort` - Base cohort with metadata and launch date
- `AccessCode` - Individual invitation codes linked to cohorts and users
- `CohortMembership` - User registration status within cohorts

**CRUD Operations:**
- `CreateAccessCodeCohort` - Required fields for new cohort creation
- `UpdateAccessCodeCohort` - Optional fields for cohort modifications

**Validation & Usage:**
- `AccessCodeValidation` - Input for code verification requests
- `AccessCodeValidationResponse` - Response with validity status and cohort info
- `AccessCodeConsumptionResponse` - Response for code redemption attempts

**Analytics:**
- `CohortWithStats` - Extended cohort data with usage metrics

## Usage Example

```typescript
// Create a new cohort
const newCohort: CreateAccessCodeCohort = {
  name: "Beta Launch Cohort",
  description: "Early access for beta testers",
  launch_date: "2024-03-15T00:00:00Z",
  capacity: 100
};

// Validate an access code
const validation: AccessCodeValidation = {
  email: "user@example.com",
  code: "BETA2024"
};

// Handle validation response
const response: AccessCodeValidationResponse = {
  valid: true,
  cohort_name: "Beta Launch Cohort"
};

// Track membership status
const membership: CohortMembership = {
  id: "mem_123",
  cohort_id: "cohort_456",
  waitlist_entry_id: "wait_789",
  access_code_id: "code_abc",
  status: 'registered',
  created_at: "2024-03-01T10:00:00Z"
};
```