/**
 * Shared Resend param/result types (browser-safe)
 *
 * These types define the public interface for Resend email operations -- used by both
 * the server-side adapter and the SDK typed wrappers. They contain zero Node.js
 * dependencies and are safe to import in any environment.
 *
 * Prefixed with "Resend" to avoid collision with Gmail types.
 *
 * Server-internal types (API response shapes, credentials) remain in
 * server/adapters/resend/fetch/utils/types.ts
 */

// ============================================================================
// Send Email
// ============================================================================

/**
 * Send email parameters
 */
export interface ResendSendEmailParams {
  from: string
  to: string | string[]
  subject: string
  html?: string
  text?: string
  replyTo?: string | string[]
  cc?: string | string[]
  bcc?: string | string[]
  headers?: Record<string, string>
  tags?: Array<{ name: string; value: string }>
}

/**
 * Send email result
 */
export interface ResendSendEmailResult {
  id: string
  success: boolean
}

// ============================================================================
// Get Email
// ============================================================================

/**
 * Get email parameters
 */
export interface ResendGetEmailParams {
  emailId: string
}

/**
 * Get email result
 */
export interface ResendGetEmailResult {
  id: string
  to: string[]
  from: string
  subject: string
  lastEvent: string
  createdAt: string
}
