# Have manitu install an application

> Installs an application (WordPress, Joomla, Nextcloud ...) into a website or a folder.

- Effect: Write - Changes the account. Agents ask first.
- Idempotent: no
- Stability: beta
- MCP tool: `manitu_webhosting_web_application_installation_create` on https://mcp.manitu.de/mcp
- REST: `POST https://api.manitu.de/v1/webhosting/web/application/installation/create`
- Needs: `service_webhosting`
- Page: /reference/webhosting/web/application/installation/create/

**Changes the account. Agents say what will happen and wait for an explicit yes before calling it.**

## MCP tool

`manitu_webhosting_web_application_installation_create`

### Description for the model

Has manitu install an application into a web hosting package of the manitu customer account this connection works in, by its site_id from manitu_webhosting_list: application.type (and version, default the newest) from manitu_webhosting_web_application_catalog_list, into a website (fqdn, type website showing a folder - its folder) or a folder (directory); an application that needs a database gets one of the package (database_id, see manitu_webhosting_web_database_list; table_prefix defaults to the application's). The folder must be empty unless overwrite is true - then files there are replaced. It runs in the background: follow it with manitu_workflow_get and its workflow_token. Where manitu sets it up right away, admin holds the administrator: login name and mail address; the password is withheld here - the customer sets his own with the application's "password forgotten". Show the notes from the catalog first. Refused with E2002 per field (not_offered, not_found, not_a_website_with_folder, directory_not_empty, required, server_type_not_supported ...) or a conflict when an installation is running (workflow_running), the package has no application installation (feature_not_in_package) or cannot be changed now (not_configurable). Tell the customer what goes where and ask for an explicit yes first.

Provide at least one of: fqdn, directory.

### Arguments

- `site_id` (integer | string, required) - The site_id from manitu_webhosting_list - never guess one. (pattern `"^[1-9][0-9]*$"`; minimum `1`)
- `application` (object, required)
  - `application.type` (string, required) - From manitu_webhosting_web_application_catalog_list, e.g. wordpress. (minLength `1`; maxLength `64`)
  - `application.version` (string) - A version on offer; default: the newest. (minLength `1`; maxLength `64`)
- `fqdn` (string) - The website to install into (its folder), from manitu_webhosting_web_vhost_list. Not together with directory. (minLength `3`; maxLength `253`)
- `directory` (string) - A folder of the package to install into, e.g. /web/blog - for a website that does not exist yet. Not together with fqdn. (minLength `1`; maxLength `255`)
- `overwrite` (boolean) - Replace files already in the folder (default false: the folder must be empty).
- `database_id` (integer) - For an application that needs a database: one of the package, of a server type the catalog names. (minimum `1`)
- `table_prefix` (string) - Prefix of its tables - letters, digits, underscores, starting with a letter; default the application's (the catalog's table_prefix_default). (minLength `1`; maxLength `32`)

### Example

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "manitu_webhosting_web_application_installation_create",
    "arguments": {
      "site_id": 12345,
      "application": {
        "type": "string"
      },
      "fqdn": "example.com"
    }
  }
}
```

## REST

`POST https://api.manitu.de/v1/webhosting/web/application/installation/create`

### Authentication

One of `X-API-Key`, `Authorization: Bearer …` - never more than one in a request.

### Request body

JSON; unknown fields are refused.

Provide at least one of: fqdn, directory.

- `site_id` (integer | string, required) - The site_id from manitu_webhosting_list - never guess one. (pattern `"^[1-9][0-9]*$"`; minimum `1`)
- `application` (object, required)
  - `application.type` (string, required) - From manitu_webhosting_web_application_catalog_list, e.g. wordpress. (minLength `1`; maxLength `64`)
  - `application.version` (string) - A version on offer; default: the newest. (minLength `1`; maxLength `64`)
- `fqdn` (string) - The website to install into (its folder), from manitu_webhosting_web_vhost_list. Not together with directory. (minLength `3`; maxLength `253`)
- `directory` (string) - A folder of the package to install into, e.g. /web/blog - for a website that does not exist yet. Not together with fqdn. (minLength `1`; maxLength `255`)
- `overwrite` (boolean) - Replace files already in the folder (default false: the folder must be empty).
- `database_id` (integer) - For an application that needs a database: one of the package, of a server type the catalog names. (minimum `1`)
- `table_prefix` (string) - Prefix of its tables - letters, digits, underscores, starting with a letter; default the application's (the catalog's table_prefix_default). (minLength `1`; maxLength `32`)

### Response

In `data`; the rest of the body as on every call.

- `workflow` (string | null, required) - What is being done, e.g. power_reboot or ngcobalt_site_web_database_copy. (one of `"create"`, `"destroy"`, `"power_start"`, `"power_stop"`, `"power_reboot"`, `"reinstall"`, `"ptr_set"`, `"vnc_enable"`, `"vnc_disable"`, `"rescuesystem_enable"`, `"rescuesystem_disable"`, `"snapshot_create"`, `"snapshot_delete"`, `"snapshot_delete_all"`, `"snapshot_revert"`, `"telemetry_await"`, `"iso_eject"`, `"none"`, `"account_contract_termination_finish"`, `"ngcobalt_site_web_application_installation_set"`, `"ngcobalt_site_web_application_installation_update"`, `"ngcobalt_site_web_permission_set"`, `"ngcobalt_site_web_database_copy"`, `"network_librenms_discover"`, `null`)
- `workflow_id` (string | null, required) - The id of this run, as vserver/workflow/list names it; null for a workflow not kept as tasks.
- `status` (string, required) - pending: waiting to start; running: started, not finished (can take a while); done: finished, everything went through; error: finished, but it or part of it failed. (one of `"pending"`, `"running"`, `"done"`, `"error"`)
- `created_at` (string | null, required) - When it was asked for. (format `date-time`)
- `started_at` (string | null, required) - When it started; null while pending, and for a workflow that does not record it. (format `date-time`)
- `ended_at` (string | null, required) - When it finished; null until then. (format `date-time`)
- `updated_at` (string | null, required) - When it last changed. (format `date-time`)
- `workflow_token` (string | null, required) - Pass it to manitu_workflow_get to see how far the workflow is - as it is, never built or changed. A secret of this workflow: do not show it to anyone. null if there is none.
- `application` (object, required)
  - `application.type` (string, required)
  - `application.version` (string, required)
- `directory` (string, required) - The folder it goes into, relative to the package.
- `admin` (object | null, required) - The administrator manitu sets up; null: the customer finishes the setup in the browser (is_configured_right_away false in the catalog).
  - `admin.username` (string, required) - The administrator's login name.
  - `admin.password` (string | null, required) - His password - a secret; null where it is withheld (secrets_withheld): the customer then sets his own with the application's "password forgotten" and mail_address.
  - `admin.mail_address` (string, required) - The administrator's mail address - the account user's.
- `secrets_withheld` (boolean, required) - The password is left out here (an answer to an agent).

### Statuses

- `200` Success.
- `400` The request does not match the declared input schema.
- `401` No credential was presented, or it was not recognised.
- `403` The credential is not permitted to use this operation.
- `500` The server failed. Nothing about the request was wrong. Whether a change took effect is not known - check before trying it again.
- `503` The channel this operation forwards through is unavailable.

### Example

```sh
curl -X POST 'https://api.manitu.de/v1/webhosting/web/application/installation/create' \
  -H 'X-API-Key: $API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"site_id":12345,"application":{"type":"string"},"fqdn":"example.com"}'
```

## Example result

```json
{
  "workflow": "create",
  "workflow_id": "string",
  "status": "pending",
  "created_at": "2026-10-23T12:00:00+02:00",
  "started_at": "2026-10-23T12:00:00+02:00",
  "ended_at": "2026-10-23T12:00:00+02:00",
  "updated_at": "2026-10-23T12:00:00+02:00",
  "workflow_token": "eyJwYWdlIjoyfQ",
  "application": {
    "type": "string",
    "version": "string"
  },
  "directory": "string",
  "admin": {
    "username": "string",
    "password": "correct-horse-battery",
    "mail_address": "info@example.com"
  },
  "secrets_withheld": true
}
```
