Make API_PREFIX use SCRIPT_NAME