require_once 'CRM/Core/ClassLoader.php'; CRM_Core_ClassLoader::singleton()->register(); CRM_Utils_System::loadBootStrap();
if (!defined('ENTRY_POINT_TYPE')) { define('ENTRY_POINT_TYPE', 'api'); } CRM_Utils_System::loadBootStrap();In this example, the loadBootStrap function is called after defining the ENTRY_POINT_TYPE constant. This constant specifies the type of entry point that the application is using (in this case, an API entry point). The loadBootStrap function must be called after the constant is defined, as it relies on this constant to properly load the necessary environment variables. Package Library: CRM_Utils is a package library in CiviCRM that provides utility functions and classes for use in the core CiviCRM codebase and in external extensions. The CRM_Utils_System class, which contains the loadBootStrap function, is part of this package library.