### Setup Database in PHP Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Installs the database using provided form values for admin user and company information. ```php public Install::setupDB(array $values, string $db = ''): bool ``` -------------------------------- ### Initialize Get Controller Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Files/Controllers/Get.md Initializes the `Get` controller with necessary dependencies. This method is part of the controller's setup process. ```php public Get::init(\Leantime\Domain\Files\Repositories\Files $filesRepo, \Leantime\Domain\Files\Services\Files $filesService, \Leantime\Core\Configuration\Environment $config): void ``` -------------------------------- ### Leantime.Domain.Auth.Controllers.UserInvite.post.onboarding_schedule_start_ Source: https://github.com/leantime/docs/blob/master/technical/hooks.md Handles POST requests for setting the start time during user onboarding schedule setup. ```APIDOC ## POST onboarding_schedule_start_ ### Description Handles POST requests for setting the start time during user onboarding schedule setup. ### Method POST ### Endpoint /onboarding_schedule_start/ ``` -------------------------------- ### Install::__construct Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Initializes the Install repository with configuration and application settings. ```APIDOC ## Install::__construct ### Description Initializes the Install repository with configuration and application settings. ### Method `__construct` ### Parameters #### Path Parameters - `config` (**\Leantime\Core\Configuration\Environment**) - Description not provided - `settings` (**\Leantime\Core\Configuration\AppSettings**) - Description not provided ### Return Value `mixed` ``` -------------------------------- ### Install Leantime with Docker Compose Source: https://github.com/leantime/docs/blob/master/installation/frequently-asked-questions.md Clone the Docker repository, navigate to the directory, and start the containers to install Leantime using Docker Compose. ```bash git clone https://github.com/Leantime/docker-leantime.git cd docker-leantime docker-compose up -d ``` -------------------------------- ### Install Middleware Constructor Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/CustomFields/Middleware/Install.md Initializes the Install middleware with necessary services. ```APIDOC ## __construct ### Description Initializes the Install middleware with the CustomFields service and environment configuration. ### Method __construct ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response None ``` -------------------------------- ### install Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Plugins/Contracts/PluginInterface.md Installs the plugin. Returns true if the installation is successful, false otherwise. ```APIDOC ## install ### Description Installs the plugin. ### Method ```php public PluginInterface::install(): bool ``` ### Return Value True if the installation is successful, false otherwise. ``` -------------------------------- ### Constructor for Install class in PHP Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Initializes the Install class by obtaining the necessary database connection and configuration settings. ```php public Install::__construct(\Leantime\Core\Configuration\Environment $config, \Leantime\Core\Configuration\AppSettings $settings): mixed ``` -------------------------------- ### Pomodoro::install Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Pomodoro/Services/Pomodoro.md Installs the Pomodoro functionality. This method is used for setup or initial configuration. ```APIDOC ## install ### Description Installs the Pomodoro functionality. ### Method install ### Parameters None ### Return Value Mixed ``` -------------------------------- ### Install Constructor - PHP Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/CustomFields/Middleware/Install.md Initializes the Install middleware with CustomFields service and Environment configuration dependencies. ```php public Install::__construct(\Leantime\Plugins\CustomFields\Services\CustomFields $customFieldsSrv, \Leantime\Core\Environment $config): mixed ``` -------------------------------- ### Install Middleware Handle Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/CustomFields/Middleware/Install.md Handles the installation of the custom fields plugin database if necessary. ```APIDOC ## handle ### Description Installs the custom fields plugin DB if necessary. This method is part of the middleware stack and processes incoming requests. ### Method handle ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **response** (\Symfony\Component\HttpFoundation\Response) - The response from the middleware chain. #### Response Example None ``` -------------------------------- ### PgmPro Install Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/PgmPro/Services/PgmPro.md Handles the installation process for the PgmPro service. The return value is not specified. ```php public PgmPro::install(): mixed ``` -------------------------------- ### Clone and Run Docker Compose for Leantime Source: https://context7.com/leantime/docs/llms.txt Clone the Docker Leantime repository, configure your .env file with database credentials, and start the services with docker-compose up -d. Navigate to the install URL afterward. ```bash git clone https://github.com/Leantime/docker-leantime.git cd docker-leantime cp sample.env .env # Edit .env with your database credentials docker-compose up -d # Then navigate to https://yourdomain.com/install ``` -------------------------------- ### SponsorLeantime Install Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/SponsorLeantime/Services/SponsorLeantime.md Handles the installation process for the SponsorLeantime service. The return value is not specified. ```php public SponsorLeantime::install(): mixed ``` -------------------------------- ### Pomodoro Install Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Pomodoro/Services/Pomodoro.md Handles the installation process for the Pomodoro plugin. The return value is generic. ```php public Pomodoro::install(): mixed ``` -------------------------------- ### Install::checkIfInstalled Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Checks if the Leantime installation is complete by verifying the existence of the user table. ```APIDOC ## Install::checkIfInstalled ### Description Checks if Leantime is installed by verifying the existence of the user table. ### Method `checkIfInstalled` ### Return Value `bool` ``` -------------------------------- ### LDAP Quick Start Configuration Source: https://github.com/leantime/docs/blob/master/installation/authentication-configuration.md Quick start environment variables for enabling and configuring LDAP integration. ```env LEAN_LDAP_USE_LDAP=true LEAN_LDAP_LDAP_TYPE=OL LEAN_LDAP_HOST=ldap.example.com LEAN_LDAP_PORT=389 LEAN_LDAP_DN=CN=users,DC=example,DC=com ``` -------------------------------- ### Install::setupDB Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Sets up the database with initial values, including admin user and company information. ```APIDOC ## Install::setupDB ### Description Installs the database with provided values. ### Method `setupDB` ### Parameters #### Path Parameters - `values` (**array**) - Form values for admin user and company information - `db` (**string**) - Description not provided ### Return Value `bool` ``` -------------------------------- ### install Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/StrategyPro/Services/StrategyPro.md Installs the StrategyPro plugin. This method is intended for internal use or automated setup processes. ```APIDOC ## install ### Description Installs the StrategyPro plugin. ### Method ```php public StrategyPro::install(): mixed ``` ### Return Value Mixed type, specific return value depends on the installation outcome. ``` -------------------------------- ### Leantime Database Configuration Example Source: https://context7.com/leantime/docs/llms.txt Example of database connection settings for Leantime, to be placed in the .env file. Ensure these match your MySQL server configuration. ```env LEAN_DB_HOST=localhost LEAN_DB_USER=leantime_user LEAN_DB_PASSWORD=your_password LEAN_DB_DATABASE=leantime LEAN_DB_PORT=3306 LEAN_APP_URL=https://yourdomain.com LEAN_SESSION_PASSWORD=your-secret-session-key ``` -------------------------------- ### GET Request Example: Get Ticket Source: https://github.com/leantime/docs/blob/master/api/usage.md This is the equivalent GET request for retrieving a ticket. Parameters must be base64 encoded and URL encoded. POST requests are generally recommended. ```url https://{{YOURDOMAIN}}/api/jsonrpc/?method=leantime.rpc.tickets.getTicket&jsonrpc=2.0&id=1¶ms=eyJpZCI6IjkifQ%3D%3D ``` -------------------------------- ### Get Request URI Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/ApiRequest.md Gets the request URI (the path part of the URL behind the domain name), adjusting for subfolder installations. ```php public IncomingRequest::getRequestUri(): string ``` -------------------------------- ### init Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Connector/Controllers/Show.md Initializes the Show controller by setting up the project service. ```APIDOC ## init ### Description Initializes the Show controller with a project service. ### Method `public Show::init(\Leantime\Domain\Connector\Services\Providers $projectService): mixed` ### Parameters #### Path Parameters - **projectService** (\Leantime\Domain\Connector\Services\Providers) - Description: ### Return Value ``` -------------------------------- ### ShowAll::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Files/Controllers/ShowAll.md Initializes the ShowAll controller with necessary repositories and services. ```APIDOC ## ShowAll::init ### Description Initializes the ShowAll controller with necessary repositories and services. ### Method public ### Signature ShowAll::init(\Leantime\Domain\Files\Repositories\Files $filesRepo, \Leantime\Domain\Files\Services\Files $filesService): void ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Parameters - **filesRepo** (\Leantime\Domain\Files\Repositories\Files) - Description: - **filesService** (\Leantime\Domain\Files\Services\Files) - Description: ### Response #### Success Response (void) No specific return value. ``` -------------------------------- ### ShowMy::init() Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Projects/Controllers/ShowMy.md Initializes the ShowMy controller with various service and repository dependencies required for project management. ```APIDOC ## init() ### Description Initializes the ShowMy controller with necessary services and repositories. ### Method `ShowMy::init(Projects $projectService, Tickets $ticketService, Reports $reportService, Comments $commentService, Clients $clientRepo, Menu $menuService): void` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Response None ``` -------------------------------- ### Get Number of Users Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to get the total number of users. Can filter by active users and include API users. ```json { "method": "leantime.rpc.Users.Users.getNumberOfUsers", "jsonrpc": "2.0", "id": 1, "params": { "activeOnly": bool, "includeApi": bool, } } ``` -------------------------------- ### getPluginClassName Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Plugins/Services/Plugins.md Gets the main class name for a given installed plugin. ```APIDOC ## getPluginClassName ### Description Gets the main class name for an installed plugin. ### Method `public Plugins::getPluginClassName( Leantime Domain Plugins Models InstalledPlugin $plugin): string` ### Parameters #### Query Parameters - **plugin** ( Leantime Domain Plugins Models InstalledPlugin) - Required - The installed plugin object. ``` -------------------------------- ### ShowAll::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/ShowAll.md Initializes the ShowAll controller with necessary service dependencies. ```APIDOC ## ShowAll::init ### Description Initializes the ShowAll controller with necessary service dependencies. ### Method public ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (void) This method does not return a value. #### Response Example None ``` -------------------------------- ### Start Apache Web Server Source: https://github.com/leantime/docs/blob/master/installation/upgrade-guide.md Command to start the Apache web server after completing an upgrade or rollback. ```bash sudo systemctl start apache2 ``` -------------------------------- ### Get Base Path Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Bootstrap/Application.md Returns the absolute base path of the application installation. ```APIDOC ## basePath ### Description Gets the base path of the application. ### Method `public Application::basePath(): string` ``` -------------------------------- ### Setup Database - PHP Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Repositories/Notification.md Sets up the database with provided values. This method is inherited from the BaseRepository. ```php public BaseRepository::setupDB(array $values): mixed ``` -------------------------------- ### Get User Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to retrieve a specific user by their ID. ```json { "method": "leantime.rpc.Users.Users.getUser", "jsonrpc": "2.0", "id": 1, "params": { "id": , } } ``` -------------------------------- ### Navigate and Copy Environment File Source: https://github.com/leantime/docs/blob/master/installation/docker.md Change into the cloned directory and copy the sample environment file to create a local configuration file. This file will store your database and Leantime settings. ```bash cd docker-leantime cp sample.env .env ``` -------------------------------- ### Manual Plugin Installation via Command Line Source: https://github.com/leantime/docs/blob/master/installation/plugin-installation.md Upload and extract a plugin manually using the command line, ensuring correct ownership and permissions. ```bash cd /var/www/html/leantime/app/Plugins unzip /path/to/PluginName.zip chown -R www-data:www-data PluginName chmod -R 755 PluginName ``` -------------------------------- ### POST Request Example: Get Ticket Source: https://github.com/leantime/docs/blob/master/api/usage.md An example of a fully formed POST request body to retrieve a specific ticket by its ID. The method format is 'leantime.rpc.{{SERVICE DOMAIN}}.{{METHOD_NAME}}'. ```json { "method": "leantime.rpc.tickets.getTicket", "jsonrpc": "2.0", "id": "1", "params": {"id":"9" } } ``` -------------------------------- ### Get All Users Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to retrieve all users. Can filter to only active users. ```json { "method": "leantime.rpc.Users.Users.getAll", "jsonrpc": "2.0", "id": 1, "params": { "activeOnly": false, } } ``` -------------------------------- ### Home::init() Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Dashboard/Controllers/Home.md Initializes the Home controller with various service and repository dependencies. ```APIDOC ## Home::init() ### Description Initializes the Home controller with various service and repository dependencies. ### Method `init` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Parameters - **projectsService** (*\Leantime\Domain\Projects\Services\Projects*) - Description: - **ticketsService** (*\Leantime\Domain\Tickets\Services\Tickets*) - Description: - **usersService** (*\Leantime\Domain\Users\Services\Users*) - Description: - **timesheetsService** (*\Leantime\Domain\Timesheets\Services\Timesheets*) - Description: - **settingRepo** (*\Leantime\Domain\Setting\Repositories\Setting*) - Description: - **calendarRepo** (*\Leantime\Domain\Calendar\Repositories\Calendar*) - Description: - **reactionsService** (*\Leantime\Domain\Reactions\Services\Reactions*) - Description: - **reportsService** (*\Leantime\Domain\Reports\Services\Reports*) - Description: - **widgetService** (*\Leantime\Domain\Widgets\Services\Widgets*) - Description: ### Return Value void ``` -------------------------------- ### Server Migration: Verify Installation Source: https://github.com/leantime/docs/blob/master/installation/backup-restore.md Commands to run after restoring data on the new server to clear cache and apply database migrations. This ensures the Leantime installation is consistent and functional. ```bash php ./bin/leantime db:migrate php ./bin/leantime cache:clear ``` -------------------------------- ### BaseRepository::setupDB Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Repositories/BaseRepository.md Sets up the database connection or configuration for the repository. ```APIDOC ## BaseRepository::setupDB ### Description Sets up the database connection or configuration for the repository. ### Method setupDB ### Parameters #### Path Parameters - `values` (**array**) - ### Return Value ``` -------------------------------- ### handle Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Help/Contracts/OnboardingSteps.md Handles the execution of the onboarding step with given parameters. ```APIDOC ## handle ### Description Handles the execution of the onboarding step with given parameters. ### Method public ### Signature OnboardingSteps::handle(mixed $params): bool ### Parameters #### Path Parameters - **params** (mixed) - Required - Description of the parameters. ### Return Value bool - Indicates whether the handling was successful. ``` -------------------------------- ### Get Application Base Path (PHP) Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Application.md Returns the absolute base path of the application's installation directory. ```php public Application::basePath(): string ``` -------------------------------- ### Install PHP Dependencies Source: https://github.com/leantime/docs/blob/master/installation/development.md Run this command in the project root after cloning the repository to install all necessary PHP packages via Composer. ```bash composer install ``` -------------------------------- ### Initialize Show Controller with Wiki and Comment Services Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Wiki/Controllers/Show.md Constructor method that initializes the Show controller with wiki and comment service dependencies. Required for setting up the controller before handling requests. ```php public Show::init(\Leantime\Domain\Wiki\Services\Wiki $wikiService, \Leantime\Domain\Comments\Services\Comments $commentService): void ``` -------------------------------- ### Get All Users By Source Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to retrieve users based on their source. Requires a source identifier. ```json { "method": "leantime.rpc.Users.Users.getAllBySource", "jsonrpc": "2.0", "id": 1, "params": { "source": , } } ``` -------------------------------- ### Show::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Wiki/Controllers/Show.md Initializes the controller with necessary services. ```APIDOC ## Show::init ### Description Initializes the controller with necessary services. ### Method `init` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Parameters - **wikiService** (\Leantime\Domain\Wiki\Services\Wiki) - Required - Description: - **commentService** (\Leantime\Domain\Comments\Services\Comments) - Required - Description: ### Return Value void ``` -------------------------------- ### Add Helm Repository and Install Leantime Source: https://github.com/leantime/docs/blob/master/installation/kubernetes.md Add the Leantime Helm repository and install the chart. Ensure you review chart options for persistence and other configurations. ```bash helm repo add gissilabs https://gissilabs.github.io/charts/ helm repo update helm install myleantime gissilabs/leantime ``` -------------------------------- ### Get User By Email Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to retrieve a user by their email address. Can also filter by status. ```json { "method": "leantime.rpc.Users.Users.getUserByEmail", "jsonrpc": "2.0", "id": 1, "params": { "email": , "status": mixed, } } ``` -------------------------------- ### _before Source: https://github.com/leantime/docs/blob/master/technical/classes/Acceptance/InstallCest.md The _before method is a setup method that runs before each test method in the InstallCest class. It initializes the AcceptanceTester. ```APIDOC ## _before ### Description Setup method that runs before each test. ### Method `public` ### Signature `InstallCest::_before(AcceptanceTester $I): mixed` ### Parameters #### Parameters - **I** (`AcceptanceTester`) - The AcceptanceTester instance. ``` -------------------------------- ### Environment::boot Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Providers/Environment.md Boots the environment provider, performing necessary setup operations. ```APIDOC ## Environment::boot ### Description Boots the environment provider. ### Method public ### Signature `Environment::boot(): mixed` ### Return Value mixed ``` -------------------------------- ### Get User Profile Picture Request Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Users/Services/Users.md Example JSON request to retrieve a user's profile picture. Requires a user ID. ```json { "method": "leantime.rpc.Users.Users.getProfilePicture", "jsonrpc": "2.0", "id": 1, "params": { "id": , } } ``` -------------------------------- ### Replace Application Files (Package Install) Source: https://github.com/leantime/docs/blob/master/installation/upgrade-guide.md Backup the current Leantime installation and replace it with the new version. Restore configuration, user files, and plugins. ```bash # Backup current installation sudo mv /var/www/leantime /var/www/leantime.old # Move new version into place sudo mv /tmp/leantime /var/www/leantime # Restore your config and files sudo cp /var/www/leantime.old/config/.env /var/www/leantime/config/ sudo cp -r /var/www/leantime.old/userfiles/* /var/www/leantime/userfiles/ sudo cp -r /var/www/leantime.old/app/Plugins/* /var/www/leantime/app/Plugins/ ``` -------------------------------- ### Get Weekly Timesheets RPC Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Timesheets/Services/Timesheets.md Retrieve timesheet data for a specific week, filtered by project and user. Requires project ID, a starting date, and user ID. ```json { "method": "leantime.rpc.Timesheets.Timesheets.getWeeklyTimesheets", "jsonrpc": "2.0", "id": 1, "params": { "projectId": int, "fromDate": \Carbon\CarbonInterface, "userId": int, } } ``` -------------------------------- ### Get Active Tickets by Project ID and Date Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Api/Repositories/Ticket.md Retrieves a list of active tickets for a specific project on a given date. Requires the project ID and the start date as a string. ```php public Ticket::getActiveTicketsByProjectIdAndDate(int $projectId, string $startDate): array ``` -------------------------------- ### ShowKanban::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/ShowKanban.md Initializes the ShowKanban controller with necessary services. ```APIDOC ## ShowKanban::init ### Description Initializes the ShowKanban controller with necessary services. ### Method `public ShowKanban::init( Leantime *\Leantime\Domain\Projects\Services\Projects $projectService, \Leantime\Domain\Tickets\Services\Tickets $ticketService, \Leantime\Domain\Sprints\Services\Sprints $sprintService, \Leantime\Domain\Timesheets\Services\Timesheets $timesheetService): void ### Parameters #### Path Parameters * None #### Query Parameters * None #### Request Body * None ### Response #### Success Response (200) * None ### Response Example * None ``` -------------------------------- ### Authenticate and Connect to Leantime JSON-RPC API Source: https://context7.com/leantime/docs/llms.txt Example of how to authenticate with the Leantime JSON-RPC API using an API key in the x-api-key header and making a request to get a specific ticket. ```bash curl https://yourdomain.com/api/jsonrpc \ -H "x-api-key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "method": "leantime.rpc.tickets.getTicket", "jsonrpc": "2.0", "id": 1, "params": {"id": "9"} }' ``` -------------------------------- ### Leantime.Domain.Auth.Controllers.UserInvite.post.onboarding_themechoice_{$postTheme} Source: https://github.com/leantime/docs/blob/master/technical/hooks.md Handles POST requests for theme choices during user onboarding. ```APIDOC ## POST onboarding_themechoice_{$postTheme} ### Description Handles POST requests for theme choices during user onboarding. ### Method POST ### Endpoint /onboarding_themechoice/{$postTheme} ``` -------------------------------- ### Plugin Installation Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Plugins/Hxcontrollers/Details.md The install method is responsible for handling the installation process of a plugin. It returns a string, likely indicating the status or result of the installation. ```php public Details::install(): string ``` -------------------------------- ### Package Installation Steps for Leantime Source: https://context7.com/leantime/docs/llms.txt Steps for installing Leantime on a Linux server using Apache/Nginx. This involves creating directories, setting permissions, uploading the release package, and configuring the web server. Ensure your web server points to the public/ directory. ```bash # Create directory and set permissions cd /var/www/html/ sudo mkdir leantime sudo chown -R www-data:www-data leantime sudo chmod -R 755 leantime # Upload release package, then configure web server to point to public/ # Rename config/.env.sample to config/.env and set DB credentials ``` -------------------------------- ### Install Leantime MCP Bridge from Source Source: https://github.com/leantime/docs/blob/master/installation/leantime-mcp.md Alternatively, install the MCP bridge from its source code repository. This involves cloning the repository, installing dependencies, building the project, and then installing it globally. ```bash git clone https://github.com/leantime/leantime-mcp.git cd leantime-mcp npm install npm run build npm install -g . ``` -------------------------------- ### ShowKanban::init Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/ShowKanban.md Initializes the ShowKanban controller with necessary service dependencies. This method is part of the controller's setup process. ```php public ShowKanban::init( Leantime Domain Projects Services Projects $projectService, Leantime Domain Tickets Services Tickets $ticketService, Leantime Domain Sprints Services Sprints $sprintService, Leantime Domain Timesheets Services Timesheets $timesheetService ): void ``` -------------------------------- ### Install::createDB Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Repositories/Install.md Creates the database for Leantime. ```APIDOC ## Install::createDB ### Description Creates the database. ### Method `createDB` ### Parameters #### Path Parameters - `dbName` (**mixed**) - Description not provided ### Return Value `bool` ``` -------------------------------- ### Show Controller GET Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Reports/Controllers/Show.md The `get` method handles HTTP GET requests to retrieve report data. ```APIDOC ## get ### Description Handles HTTP GET requests to retrieve report data. ### Method `get(): \Symfony\Component\HttpFoundation\Response` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Response #### Success Response (200) - **response** (\Symfony\Component\HttpFoundation\Response) - The HTTP response object containing the report data. #### Response Example None provided in source. ``` -------------------------------- ### bootstrap Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/HttpKernel.md Initializes the application by performing necessary bootstrapping steps if the application has not been bootstrapped already. ```APIDOC ## bootstrap ### Description Bootstrap the application if it has not been previously bootstrapped. ### Method `public HttpKernel::bootstrap(): void` ### Return Value void ``` -------------------------------- ### Installed::handle Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Middleware/Installed.md Checks if Leantime is installed. This method is part of the middleware stack and is invoked to determine the application's installation status. ```APIDOC ## handle ### Description Check if Leantime is installed ### Method public ### Signature `Installed::handle( Leantime\Core\Http\IncomingRequest $request, Closure $next ): Symfony\Component\HttpFoundation\Response` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **response** (Symfony\Component\HttpFoundation\Response) - The HTTP response. #### Response Example None ``` -------------------------------- ### ShowMy::init Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Projects/Controllers/ShowMy.md Initializes the ShowMy controller with various service dependencies. This method is part of the controller's setup process. ```php public ShowMy::init( Leantime\Domain\Projects\Services\Projects $projectService, Leantime \Domain\Tickets\Services\Tickets $ticketService, Leantime \Domain\Reports\Services\Reports $reportService, Leantime \Domain\Comments\Services\Comments $commentService, Leantime \Domain\Clients\Repositories\Clients $clientRepo, Leantime \Domain\Menu\Services\Menu $menuService ): void ``` -------------------------------- ### Callback get Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Oidc/Controllers/Callback.md Signature for the get method of the Callback controller. It handles incoming GET requests and returns a response. ```php public Callback::get( $params): \Symfony\Component\HttpFoundation\Response ``` -------------------------------- ### Update Controller GET Request Handler Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Controllers/Update.md Signature for the `get` method in the `Update` controller, used to handle GET requests. ```php public Update::get(mixed $params): mixed ``` -------------------------------- ### booting Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Bootstrap/Application.md Registers a callback to be executed just before the application's booting process begins. ```APIDOC ## booting ### Description Register a new boot listener. ### Method `public Application::booting(callable $callback): void` ### Parameters #### Path Parameters - **callback** (callable) - Required - The callback function to execute. ### Return Value void ``` -------------------------------- ### Index Controller Get Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Install/Controllers/Index.md Signature for the get method, which handles GET requests. It accepts parameters that can be part of the request. ```php public Index::get( $params): mixed ``` -------------------------------- ### Initialize ShowProgram Controller Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/PgmPro/Controllers/ShowProgram.md Initializes the `ShowProgram` controller by setting up various service and repository dependencies required for its operation. ```php public ShowProgram::init( Leantime\Domain\Projects\Services\Projects $projectService, Leantime \Domain\Comments\Services\Comments $commentService, Leantime \Domain\Files\Services\Files $fileService, Leantime \Domain\Tickets\Services\Tickets $ticketService, Leantime \Domain\Setting\Repositories\Setting $settingsRepo, Leantime \Domain\Projects\Repositories\Projects $projectRepo, Leantime \Domain\Users\Repositories\Users $userRepo, Leantime \Domain\Clients\Repositories\Clients $clientsRepo, Leantime \Domain\Files\Repositories\Files $fileRepo, Leantime \Domain\Comments\Repositories\Comments $commentsRepo, Leantime \Domain\Menu\Repositories\Menu $menuRepo ): mixed ``` -------------------------------- ### install SponsorLeantime Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/SponsorLeantime/Services/SponsorLeantime.md Installs the SponsorLeantime service. ```APIDOC ## install SponsorLeantime ### Description Installs the SponsorLeantime service. ### Method install ### Parameters None ### Return Value Mixed ``` -------------------------------- ### Install PgmPro Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/PgmPro/Services/PgmPro.md Installs the PgmPro service. ```APIDOC ## install ### Description Installs the PgmPro service. ### Method install ### Parameters None ### Return Value Mixed ``` -------------------------------- ### __construct Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Setting/Repositories/Setting.md Initializes the Setting repository with a database connection. ```APIDOC ## __construct ### Description Initializes the Setting repository with a database connection. ### Method __construct ### Parameters #### Path Parameters - None #### Query Parameters - None #### Request Body - None ### Request Example ```php // Example usage (assuming $db is a valid Db object) $settingRepository = new Setting($db); ``` ### Response #### Success Response - The constructor does not return a value directly, but initializes the object. #### Response Example ```json null ``` ``` -------------------------------- ### Newteam Controller GET Request Handling Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Accounts/Controllers/Newteam.md The get method handles GET requests for the Newteam controller. It accepts parameters and returns mixed. ```php public Newteam::get(mixed $params): mixed ``` -------------------------------- ### Details::install Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Plugins/Hxcontrollers/Details.md Handles the installation process for a plugin. ```APIDOC ## Details::install ### Description Handles the installation process for a plugin. ### Method public ### Signature Details::install(): string ### Return Value string ``` -------------------------------- ### ProjectIntroStep::handle Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Help/Services/ProjectIntroStep.md Handles the given parameters to process the project introduction step. ```APIDOC ## handle ### Description Handle the given parameters. ### Method handle ### Parameters #### Path Parameters - `params` (array) - Required - The parameters passed to the handle method. ### Return Value Returns true on success. ``` -------------------------------- ### Verify Controller get Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/TwoFA/Controllers/Verify.md Signature for the get method of the Verify controller. It handles GET requests and accepts mixed parameters. ```php public Verify::get(mixed $params): mixed ``` -------------------------------- ### get Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Controllers/CurrentStatusUpdate.md Handles GET requests for status updates. ```APIDOC ## get ### Description Handles GET requests for status updates. ### Method public ### Signature `CurrentStatusUpdate::get(mixed $params): void` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Parameters - **params** (*mixed*) - ### Return Value Void ``` -------------------------------- ### Register::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Accounts/Controllers/Register.md Initializes the Register controller with the install repository. ```APIDOC ## Register::init ### Description Initializes the Register controller with the install repository. ### Method `public` ### Parameters #### Path Parameters - **installRepo** (`\Leantime\Domain\Install\Repositories\Install`) - Required - The install repository instance. ``` -------------------------------- ### ShowAll Controller Init Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Comments/Controllers/ShowAll.md Initializes the ShowAll controller with project and comment services. This method is called automatically upon controller instantiation. ```php public ShowAll::init( Leantime\Domain\Projects\Services\Projects $projectService, Leantime\Domain\Comments\Services\Comments $commentService ): void ``` -------------------------------- ### get Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Connector/Controllers/Show.md Handles GET requests for the connector. ```APIDOC ## get ### Description Handles GET requests, processing any provided parameters. ### Method `public Show::get(mixed $params): mixed` ### Parameters #### Path Parameters - **params** (mixed) - Description: ### Return Value ``` -------------------------------- ### GET Request Structure Source: https://github.com/leantime/docs/blob/master/api/usage.md While POST is recommended, GET requests can also be used. For GET requests, the `params` must be base64 encoded and URL encoded. ```APIDOC ## Sending a GET Request ### Description GET requests can be used as an alternative to POST, though POST is recommended. For GET requests, all parameters must be included in the URL, and the `params` field needs to be base64 encoded and then URL encoded. ### Method `GET` ### Endpoint `{{YOURDOMAIN}}/api/jsonrpc/?method={{LEANTIMEMETHOD}}&jsonrpc=2.0&id={{ANY ID}}¶ms={{BASE64_ENCODED_PARAMS}}` ### Request Example To get a ticket with ID "9" using GET: ``` https://{{YOURDOMAIN}}/api/jsonrpc/?method=leantime.rpc.tickets.getTicket&jsonrpc=2.0&id=1¶ms=eyJpZCI6IjkifQ%3D%3D ``` ``` -------------------------------- ### __invoke Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Bootstrap/Bootloader.md Boot the Application. This method is invoked to start the application's main process. ```APIDOC ## __invoke ### Description Boot the Application. ### Method `public Bootloader::__invoke(): void` ### Return Value - **void** ``` -------------------------------- ### getProjectSetupChecklist Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Projects/Services/Projects.md Retrieves the setup checklist for a project. ```APIDOC ## getProjectSetupChecklist ### Description Retrieves the setup checklist for a project. ### Method `Projects::getProjectSetupChecklist(int $projectId): array` ### Parameters #### Path Parameters - **projectId** (int) - Required - The ID of the project. ### Return Value The setup checklist for the project. ``` -------------------------------- ### EditMilestone Controller GET Request Handler Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/EditMilestone.md Handles GET requests for the EditMilestone controller. This method is invoked when a GET request is made to the controller's endpoint. ```php public EditMilestone::get(mixed $params): mixed ``` -------------------------------- ### Start Stopwatch Timer Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Timesheets/Hxcontrollers/Stopwatch.md Starts or resumes the stopwatch timer. ```APIDOC ## startTimer Stopwatch::startTimer ### Description Starts or resumes the stopwatch timer. ### Method public ### Return Value void ``` -------------------------------- ### Handle GET Requests in Submenu Controller Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Api/Controllers/Submenu.md The get method handles GET requests for the Submenu controller. It accepts an array of parameters and returns a Symfony Response object. ```php public Submenu::get(array $params): \Symfony\Component\HttpFoundation\Response ``` -------------------------------- ### Create Leantime Directory and Set Permissions Source: https://github.com/leantime/docs/blob/master/installation/package-installation.md Creates a directory for Leantime and sets the correct ownership and permissions for the web server. Ensure 'www-data' is the correct user/group for your system. ```bash cd /var/www/html/ sudo mkdir leantime sudo chown -R www-data:www-data leantime sudo chmod -R 755 leantime ``` -------------------------------- ### GET Request Format (Base64-encoded params) Source: https://context7.com/leantime/docs/llms.txt This section details how to make GET requests to the Leantime API by encoding parameters in Base64 and URL-encoding them. This is useful for clients that only support GET requests. ```APIDOC ## GET Request Format (Base64-encoded params) For GET-only clients, encode params in base64 and URL-encode them. ```bash # params {"id":"9"} base64-encodes to eyJpZCI6IjkifQ== curl "https://yourdomain.com/api/jsonrpc?method=leantime.rpc.tickets.getTicket&jsonrpc=2.0&id=1¶ms=eyJpZCI6IjkifQ%3D%3D" \ -H "x-api-key: YOUR_API_KEY" ``` ``` -------------------------------- ### ShowList::init Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/ShowList.md Initializes the ShowList controller with necessary service dependencies. This method is part of the controller's setup process. ```php public ShowList::init( Leantime Domain Projects Services Projects $projectService, Leantime Domain Tickets Services Tickets $ticketService, Leantime Domain Sprints Services Sprints $sprintService, Leantime Domain Timesheets Services Timesheets $timesheetService ): void ``` -------------------------------- ### Success Controller GET Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Billing/Controllers/Success.md Handles GET requests for the Success controller. ```php public Success::get(mixed $params): mixed ``` -------------------------------- ### boot Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Bootstrap/Application.md Initiates the booting process for all registered service providers in the application. ```APIDOC ## boot ### Description Boot the application's service providers. ### Method `public Application::boot(): void` ### Return Value void ``` -------------------------------- ### EditCanvasItem GET Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Canvas/Controllers/EditCanvasItem.md Handles GET requests for editing canvas items. ```APIDOC ## get EditCanvasItem ### Description Handles GET requests to edit a canvas item. ### Method `public EditCanvasItem::get(mixed $params): mixed` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) None #### Response Example None ``` -------------------------------- ### _before Source: https://github.com/leantime/docs/blob/master/technical/classes/Acceptance/TicketsCest.md Initializes the test environment by setting up the tester and login page objects. ```APIDOC ## _before ### Description Initializes the test environment by setting up the tester and login page objects. ### Method PHP Method ### Parameters #### Path Parameters - **I** (*\Tests\Support\AcceptanceTester*) - Required - The acceptance tester instance. - **loginPage** (*\Tests\Support\Page\Acceptance\Login*) - Required - The login page object. ### Return Value Mixed ``` -------------------------------- ### Home Controller GET Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Dashboard/Controllers/Home.md The `get` method handles HTTP GET requests for the Home controller. It is expected to return a Symfony HTTP response object, typically rendering a dashboard view. ```php public Home::get(): SymfonyComponentHttpFoundationResponse ``` -------------------------------- ### Frontcontroller::__construct Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Core/Controller/Frontcontroller.md Initializes the Frontcontroller by setting the root path of the server. ```APIDOC ## __construct ### Description Set the rootpath of the server. ### Method __construct ### Parameters #### Path Parameters - **incomingRequest** (\Leantime\Core\Http\IncomingRequest) - Description: ### Return Value void ``` -------------------------------- ### Initialize Show Controller with Dependencies Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Reports/Controllers/Show.md Constructor method that injects all required services for the Reports Show controller. Must be called before using the controller to set up dashboard repository, project, sprint, ticket, user, timesheet, and report services. ```php public Show::init(\Leantime\Domain\Dashboard\Repositories\Dashboard $dashboardRepo, \Leantime\Domain\Projects\Services\Projects $projectService, \Leantime\Domain\Sprints\Services\Sprints $sprintService, \Leantime\Domain\Tickets\Services\Tickets $ticketService, \Leantime\Domain\Users\Services\Users $userService, \Leantime\Domain\Timesheets\Services\Timesheets $timesheetService, \Leantime\Domain\Reports\Services\Reports $reportService): void ``` -------------------------------- ### NotesDialog::get Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Notes/Controllers/NotesDialog.md Signature for the get method, which handles GET requests. ```php public NotesDialog::get(mixed $params): mixed ``` -------------------------------- ### Handle GET Request (PHP) Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Controllers/StoryTime.md Handles incoming GET requests with the given parameters. ```php public StoryTime::get(mixed $params): void ``` -------------------------------- ### Show::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Plugins/Controllers/Show.md Initializes the Show controller with a plugin service. ```APIDOC ## Show::init ### Description Initializes the Show controller with a plugin service. ### Method public ### Parameters #### Path Parameters - **pluginService** (\Leantime\Domain\Plugins\Services\Plugins) - Required - Description of the plugin service parameter. ``` -------------------------------- ### Register Controller GET Request Handler Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Accounts/Controllers/Register.md Handles GET requests for the Register controller. ```php public Register::get(mixed $params): mixed ``` -------------------------------- ### ShowProject::init Method Signature Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Projects/Controllers/ShowProject.md Initializes private variables for the ShowProject controller. Requires various service and repository instances for project, comment, file, ticket, settings, user, and client management. ```php public ShowProject::init( Leantime\Domain\Projects\Services\Projects $projectService, LeantimeDomainCommentsServicesComments $commentService, LeantimeDomainFilesServicesFiles $fileService, LeantimeDomainTicketsServicesTickets $ticketService, LeantimeDomainSettingRepositoriesSetting $settingsRepo, LeantimeDomainProjectsRepositoriesProjects $projectRepo, LeantimeDomainUsersRepositoriesUsers $userRepo, LeantimeDomainClientsRepositoriesClients $clientsRepo, LeantimeDomainFilesRepositoriesFiles $fileRepo, LeantimeDomainCommentsRepositoriesComments $commentsRepo, LeantimeDomainMenuRepositoriesMenu $menuRepo ): mixed ``` -------------------------------- ### Manual Plugin Installation via Docker Copy Source: https://github.com/leantime/docs/blob/master/installation/plugin-installation.md Copy a plugin into the Docker container and then set the correct ownership and permissions. ```bash # Copy plugin to container docker cp /path/to/PluginName :/var/www/html/app/Plugins/ # Fix permissions docker exec -it chown -R www-data:www-data /var/www/html/app/Plugins/PluginName ``` -------------------------------- ### ShowList::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Domain/Tickets/Controllers/ShowList.md Initializes the ShowList controller with necessary service dependencies. ```APIDOC ## init ### Description Initializes the ShowList controller with necessary service dependencies. ### Method public ### Signature ShowList::init( Leantime\Domain\Projects\Services\Projects $projectService, Leantime\Domain\Tickets\Services\Tickets $ticketService, Leantime\Domain\Sprints\Services\Sprints $sprintService, Leantime\Domain\Timesheets\Services\Timesheets $timesheetService ): void ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Response #### Success Response (void) This method does not return a value. ``` -------------------------------- ### Create::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/CustomFields/Controllers/Create.md Initializes the Create controller with necessary services and configuration. ```APIDOC ## init ### Description Initializes the Create controller with necessary services and configuration. ### Method `public` ### Signature `Create::init(\Leantime\Plugins\CustomFields\Services\CustomFields $customFieldsService, \Leantime\Core\Environment $config): void` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Parameters - **customFieldsService** (\Leantime\Plugins\CustomFields\Services\CustomFields) - Required - Description not specified. - **config** (\Leantime\Core\Environment) - Required - Description not specified. ### Return Value `void` ``` -------------------------------- ### Install Marketplace Plugin Source: https://github.com/leantime/docs/blob/master/api/classes/Leantime/Domain/Plugins/Services/Plugins.md Installs a plugin from the marketplace. Requires the plugin identifier and the desired version. ```APIDOC ## installMarketplacePlugin ### Description Installs a plugin from the marketplace. ### Method leantime.rpc.Plugins.Plugins.installMarketplacePlugin ### Parameters #### Request Body - **plugin** (\Leantime\Domain\Plugins\Models\MarketplacePlugin) - Required - The plugin to install. - **version** (string) - Required - The version of the plugin to install. ### Response #### Success Response (200) - **result** (void) - Indicates successful installation. ``` -------------------------------- ### ShowStatusUpdate Controller Get Method Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/Llamadorian/Controllers/ShowStatusUpdate.md The 'get' method handles incoming parameters for the ShowStatusUpdate controller. ```php public ShowStatusUpdate::get(mixed $params): void ``` -------------------------------- ### Kanban::init Source: https://github.com/leantime/docs/blob/master/technical/classes/Leantime/Plugins/StrategyPro/Controllers/Kanban.md Initializes the Kanban controller by setting up necessary services. ```APIDOC ## Kanban::init ### Description Initializes the Kanban controller with project and program services. ### Method `Kanban::init(Projects $projectService, Programs $programService): mixed` ### Parameters #### Path Parameters - None #### Query Parameters - None #### Request Body - None ### Request Example ```php // Example usage (conceptual, actual instantiation may vary) $kanbanController = new Kanban(); $kanbanController->init($projectService, $programService); ``` ### Response #### Success Response (200) - Returns mixed type, specific return value depends on implementation. #### Response Example ```json // No specific response example provided in source ``` ```