import Foundation

struct AuthConfig: Codable, Sendable {
    let url: String
    let username: String
    let password: String
}

struct AuthResponse: Codable, Sendable {
    let authorized: Bool
    let config: AuthConfig

    func toXStreamCredentials() -> XStreamCredentials {
        XStreamCredentials(
            baseURL: config.url,
            username: config.username,
            password: config.password
        )
    }
}
