<?php
declare(strict_types=1);

// Global configuration for the Herbal Wellness Care API
// Update these values for your local/production environment.

return [
    'db' => [
        'host' => '127.0.0.1',
        'port' => 3306,
        'database' => 'atasbngc_toa_system', // create this DB and import schema.sql
        'username' => 'atasbngc_admin', // default for XAMPP
        'password' => '@Nifemi2301',     // default for XAMPP (empty)
        'charset' => 'utf8mb4',
    ],
    'security' => [
        // Change this to a long, random string in production
        'jwt_secret' => 'change-this-in-production-9c7c3a3f1f0f4c16a0b9b574f9fef97f',
        'jwt_issuer' => 'herbal-wellness',
        // Token expiration (seconds) - default 7 days
        'jwt_exp' => 60 * 60 * 24 * 7,
    ],
    'app' => [
        // App base URL mounted under XAMPP htdocs
        'base_url' => '/atasteofafricanmarketplace',
        // Set to true if serving over HTTPS (for Secure cookies)
        'cookie_secure' => false,
        'cookie_domain' => '', // leave empty for default host
    ],
    // AI configuration (MVP)
    'ai' => [
        // provider: openai (default) — uses OPENAI_API_KEY env var if present
        'provider' => 'openai',
        'api_key' => getenv('OPENAI_API_KEY') ?: '',
        'model' => 'gpt-3.5-turbo',
        // Rate limits: requests per hour per user
        'rate_limit_per_hour' => 100,
        // Simple moderation blacklist (substring match)
        'moderation_blocklist' => [
            'bomb', 'suicide', 'rape', 'kill', 'terror', 'child porn'
        ],
    ],
];
