<?php
require_once __DIR__ . '/../db/config.php';
require_once __DIR__ . '/../includes/exchange.php';

header('Content-Type: application/json');

$rates = get_exchange_rates();

echo json_encode([
    'success' => true,
    'rates' => $rates,
    'timestamp' => time(),
    'timezone' => date_default_timezone_get()
]);
