*/ class Aitoce_Admin_Notifications { /** * Display relevant admin error messages based on account and model settings. * * Checks the user's account status and LLM settings, and displays * error notifications if there are issues with the account or configuration. */ public function aitoce_display_admin_errors() { $type = 'error'; $message = __( 'Nimbot by AI tool Center is shutting down please select weather or not to delete database tables and settings for Nimbot. Deactivate and uninstall.', 'ai-tool-center' ); add_settings_error( 'aitoce-admin-notice', esc_attr( 'settings_updated' ), $message, $type ); /* $api_call = new Aitoce_Api; $account_membership = $api_call->aitoce_get_account(); $agent = new Aitoce_Agent_Settings(); $mysql_agent_data = $agent->aitoce_get_agent_data('ALL'); // Check if the account is valid. if (!in_array($account_membership['label'], AITOCE_ACCOUNT_LEVELS, true)) { $type = 'error'; $message = __( 'It looks like your Account Membership or API Key is missing or invalid. Head over to ai-tool-center.com to check your account details and get your API key.', 'ai-tool-center' ); add_settings_error( 'aitoce-admin-notice', esc_attr( 'settings_updated' ), $message, $type ); } // Check if any Agents created. if (!$mysql_agent_data || count($mysql_agent_data) <= 0) { $type = 'error'; $message = __( 'You will need to create an Agent to be able to use AI Tool Centers, AI NimBot Assistant. You can create an Agent Here.', 'ai-tool-center' ); add_settings_error( 'aitoce-admin-notice', esc_attr( 'settings_updated' ), $message, $type ); } */ } }