# Enable mod_rewrite RewriteEngine On # Allow access to .well-known/acme-challenge directory for SSL certificate validation RewriteCond %{REQUEST_URI} ^/.well-known/acme-challenge/ RewriteRule ^ - [L] # Redirect to HTTPS if it's not already using HTTPS and ensure it's for api.voicecon.ai domain RewriteCond %{HTTPS} off RewriteCond %{HTTP_HOST} ^api\.voicecon\.ai$ [NC] RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] # Allow Cross-Origin Resource Sharing (CORS) from all domains (optional, use with caution) Header always set Access-Control-Allow-Origin "*" # Optional: Set PHP handler if you're using PHP on this server (cPanel-generated handler) AddHandler application/x-httpd-ea-php82 .php .php8 .phtml # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php81” package as the default “PHP” programming language. AddHandler application/x-httpd-ea-php81 .php .php8 .phtml # php -- END cPanel-generated handler, do not edit