<?php
/**
 * PhonePe Configuration
 * Real credentials for production
 */

class PhonePeConfig {
    // PhonePe API Configuration
    const MERCHANT_ID = "ASTRO";
    const CLIENT_ID = "SU2509232050194428161935";
    const CLIENT_SECRET = "ac7d0d8f-8bb1-45c4-baab-5f6f5e6ac3a2";
    const CLIENT_VERSION = "1";
    
    // Environment Configuration
    const ENVIRONMENT = "PRODUCTION"; // or "SANDBOX" for testing
    
    // API URLs
    const BASE_URL_SANDBOX = "https://api-preprod.phonepe.com/apis/pg-sandbox";
    const BASE_URL_PRODUCTION = "https://api.phonepe.com/apis/pg-sandbox";
    
    // App Configuration
    const APP_SCHEME = "astrosidhi";
    const REDIRECT_URL = "https://astrosidhi.com/payment/callback";
    const CALLBACK_URL = "https://astrosidhi.com/payment/webhook";
    
    /**
     * Get base URL based on environment
     */
    public static function getBaseUrl() {
        return self::ENVIRONMENT === "PRODUCTION" 
            ? self::BASE_URL_PRODUCTION 
            : self::BASE_URL_SANDBOX;
    }
    
    /**
     * Get merchant ID
     */
    public static function getMerchantId() {
        return self::MERCHANT_ID;
    }
    
    /**
     * Get client credentials
     */
    public static function getClientCredentials() {
        return [
            'client_id' => self::CLIENT_ID,
            'client_secret' => self::CLIENT_SECRET,
            'client_version' => self::CLIENT_VERSION
        ];
    }
}
?>
