package com.optix.android.domain.repository

import com.optix.android.domain.model.AiProviderConfig
import com.optix.android.domain.model.AppSettings
import com.optix.android.domain.model.NetworkSettings
import kotlinx.coroutines.flow.Flow

interface SettingsRepository {
    fun getAiConfig(): Flow<AiProviderConfig>
    suspend fun saveAiConfig(config: AiProviderConfig)
    fun getAppSettings(): Flow<AppSettings>
    suspend fun saveAppSettings(settings: AppSettings)
    suspend fun toggleFavorite(toolId: String)
    fun getNetworkSettings(): Flow<NetworkSettings>
    suspend fun saveNetworkSettings(settings: NetworkSettings)
    fun getOsintApiKeys(): Flow<Map<String, String>>
    suspend fun saveOsintApiKey(service: String, key: String)

    /** Whether the user has acknowledged the per-session ethical-use gate. */
    fun hasEthicalAck(): Flow<Boolean>
    suspend fun setEthicalAck(acknowledged: Boolean)
}
