/**
 * Shared Dropbox param/result types (browser-safe)
 *
 * These types define the public interface for Dropbox 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.
 *
 * Uses Uint8Array instead of Buffer for browser safety.
 *
 * Server-internal types (credentials, error handling) remain in
 * server/adapters/dropbox/fetch/
 */

// ============================================================================
// Upload File
// ============================================================================

/**
 * Upload file parameters
 */
export interface UploadFileParams {
  path: string
  contents: Uint8Array
  mode?: 'add' | 'overwrite'
  autorename?: boolean
}

/**
 * Upload file result
 */
export interface UploadFileResult {
  id: string
  name: string
  path_lower: string
  path_display: string
  rev: string
  size: number
  is_downloadable: boolean
  content_hash?: string
}

// ============================================================================
// Create Folder
// ============================================================================

/**
 * Create folder parameters
 */
export interface CreateFolderParams {
  path: string
  autorename?: boolean
}

/**
 * Create folder result
 */
export interface CreateFolderResult {
  metadata: {
    id: string
    name: string
    path_lower: string
    path_display: string
  } | null
}
