# Installation and Configuration Guide

Step-by-step instructions for installing, configuring, and setting up the Synology WHMCS module, including Synology DSM preparation, WHMCS integration, email templates, and product configuration.

# WHMCS setup (install/update)

### Synology module **[WHMCS](https://puqcloud.com/whmcs-module-synology.php)**
#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

## System requirements

| Requirement | Minimum version |
|-------------|-----------------|
| **PHP** | 7.4 or higher (7.4 / 8.1 / 8.2) |
| **WHMCS** | 8.x or higher |
| **ionCube Loader** | v13 or newer (v14, v15) |
| **Synology DSM** | 7.x or higher |

> **Note:** The module uses ionCube encoding. Make sure ionCube Loader is installed and active on your server.

---

## Backward compatibility

This module supports older PHP versions and older WHMCS versions for maximum compatibility with existing hosting environments. PHP-version-specific builds are provided:

- **PHP 7.4** — for legacy WHMCS 8 installations running PHP 7.4
- **PHP 8.1** — for WHMCS 8 installations running PHP 8.1
- **PHP 8.2** — for WHMCS 8/9 installations running PHP 8.2

Each build is encoded with the appropriate ionCube version for the target PHP runtime.

---

## Download

The module can be ordered and downloaded from PUQ Cloud:

- **Order / Download:** [https://puqcloud.com/whmcs-module-synology.php](https://puqcloud.com/whmcs-module-synology.php)
- **Community:** [https://community.puqcloud.com/](https://community.puqcloud.com/)
- **Direct download links for the latest version:**

```
# PHP 7.4
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php74/PUQ_WHMCS-Synology-latest.zip

# PHP 8.1
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php81/PUQ_WHMCS-Synology-latest.zip

# PHP 8.2
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php82/PUQ_WHMCS-Synology-latest.zip
```

After downloading, extract the archive:

```
unzip PUQ_WHMCS-Synology-latest.zip
```

---

## Installation

### Step 1: Upload files

Extract the module archive and copy the `puqSynology` directory to the WHMCS servers module directory:

```
WHMCS_WEB_DIR/modules/servers/puqSynology
```

### Step 2: Add server

Navigate to **System Settings** → **Servers** → **Add New Server**:

1. Enter the correct **Name** and **Hostname**
2. In Server Details, select the **PUQ Synology** module
3. Enter valid Synology DSM credentials (username and password)
4. Click **Test connection** to verify

### Step 3: Create product

Navigate to **System Settings** → **Products/Services** → **Create a New Product**:

1. Select the **PUQ Synology** module in the Module settings section
2. Configure the product parameters

---

## Update

### Step 1: Backup

Before updating, it is recommended to back up:
- WHMCS database
- Module files in `modules/servers/puqSynology/`

### Step 2: Upload new files

Download and extract the new version, then overwrite all files in:

```
WHMCS_WEB_DIR/modules/servers/puqSynology/
```

### Step 3: Verification

1. Log in to the WHMCS admin panel
2. Check the module is functioning correctly
3. Verify product settings

> **Important (v3.0):** Product reconfiguration is required after updating to version 3.0.


<!-- sync:df907a5f1e4e11e4 -->

# Synology part setup guide

### Synology module **[WHMCS](https://puqcloud.com/link.php?id=77)** 

#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

Here are the initial steps of configuring Synology devices to prepare them for use with the WHMCS module.

> **Note:** At the beginning, you should prepare the appropriate domain with the correct DNS entries so that you can generate a correct SSL certificate for Your Synology NAS server. 

##### 1. Generate an SSL certificate for your domain.

Connect the certificate for all services that will be used in the server.(FTPS, System, Synology Drive, etc...)

![04-synology-setup-1.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-h4iqnrht.png)

##### 2. Make sure the partition is formatted in BTRFS

![07-synology-setup-4.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-lolxyriq.png)

##### 3. Enable the user's home folder.

![08-synology-setup-5.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-ylwohm2j.png)

##### 4. Enable all necessary file services (ie: FTP, FTPS, SFTP, etc.).

![09-synology-setup-6.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-bdpnga5f.png)

##### 5. Create user groups with the necessary quotas and permissions.

![05-synology-setup-2.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-3qvmksrx.png)

![06-synology-setup-3.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-dy5t6vxn.png)

<!-- sync:12f4747822087655 -->

# WHMCS part setup guide

### Synology module **[WHMCS](https://puqcloud.com/link.php?id=77)**
#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

##### 1. Download the latest version of the module

Choose the build that matches your server's PHP version:

PHP 8.2
```bash
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php82/PUQ_WHMCS-Synology-latest.zip
```

PHP 8.1
```bash
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php81/PUQ_WHMCS-Synology-latest.zip
```

PHP 7.4
```bash
wget https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/php74/PUQ_WHMCS-Synology-latest.zip
```

> **Note:** All versions are available here: [https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/)

##### 2. Unzip the archive with the module

```bash
unzip PUQ_WHMCS-Synology-latest.zip
```

##### 3. Copy "puqSynology" to "WHMCS_WEB_DIR/modules/servers/"

##### 4. Add the Synology NAS server in WHMCS

```
System Settings -> Servers -> Add New Server
```

- Enter the correct **Name** and **Hostname**

![10-add-server-1.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-utczbpnv.png)

- In the **Server Details** section, select the **PUQ Synology** module and enter the correct **username** and **password** of the **Synology DSM** account.
- Click **Test connection** to verify.

![11-add-server-2.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-gdnxc3tc.png)

> **Warning:** The **ACCESS HASH** field is used to store the server access key and is updated automatically — do not edit it manually.

For more details, see **[Add server (Synology NAS)](05-add-server.md)**.

##### 5. Create the product

```
System Settings -> Products/Services -> Create a New Product
```

In the **Module Settings** section, select the **PUQ Synology** module and the **Server Group** that contains your Synology server, then click **Save Changes** to load the configuration panel.

![14-product-configuration-overview.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-t1qzyw9j.png)

Every setting in this panel (License key, Disk, Synology group, Notifications, History, Client Area and User rules) is described in detail on the **[Product Configuration](06-product-configuration.md)** page.


<!-- sync:d605d2b24ad08df1 -->

# Email Template (puqSynology Notification disk limit)

### Synology module **[WHMCS](https://puqcloud.com/link.php?id=77)** 

#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

##### Create an email template for customer notifications.

```
System Settings->Email Templates->Create New Email Template
```

- **Email Type:** Product/service
- **Unique Name:** puqSynology Notification disk limit

![12-email-template-1.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-qyh1uesn.png)

**Subject:**

```PHP
Disk space usage {$disk_used_percentage} % - {$username}
```

**Body:**

```PHP
Dear {$client_name},

This letter informs you that the disk space usage limit is coming to an end.

Product/Service: {$service_product_name}
Due Date: {$service_next_due_date}

Username: {$username}

Disk limit: {$disk_limit_bytes*$unit_coefficient} {$unit}
Disk used: {$disk_used_unit} {$unit} ({$disk_used_percentage} %)
Disk free: {$disk_free_unit} {$unit} ({$disk_free_percentage} %)

{$signature}
```

![13-email-template-2.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-a7ljvwxf.png)

<!-- sync:15a4d9a7f1fa4fbe -->

# Add server (Synology NAS)

### Synology module **[WHMCS](https://puqcloud.com/link.php?id=77)** 

#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

##### Add a new server to the system WHMCS.

```
System Settings->Servers->Add New Server
```

- Enter the correct **Name** and **Hostname**

![10-add-server-1.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-o37ugvyv.png)

- In the **Server Details** section, select the "**PUQ Synology**" module and enter the correct **username** and **password** for the **Synology NAS web interface**.
- To check, click the **"Test connection"** button

![11-add-server-2.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-1nrhfsfh.png)

> **Warning:** WARNING: **ACCESS HASH** field Used to store the access key to the server and is updated automatically.

<!-- sync:7b2e8191e0f89a1b -->

# Product Configuration

### Synology module **[WHMCS](https://puqcloud.com/link.php?id=77)**
#####  [Order now](https://puqcloud.com/whmcs-module-synology.php) | [Download](https://download.puqcloud.com/WHMCS/servers/PUQ_WHMCS-Synology/) | [Community](https://community.puqcloud.com/)

##### Add a new product to WHMCS

```
System Settings -> Products/Services -> Create a New Product
```

In the **Module Settings** section, select the **PUQ Synology** module and the **Server Group** that
contains your Synology server, then click **Save Changes**. The module then renders its modern
configuration panel.

![14-product-configuration-overview.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-niq7m616.png)

> **Note:** Select the **Server Group** and save the product first — the **Synology group** drop-down
> (in the Disk section) is populated live from the server assigned to that group.

At the top of the panel:

- **Module Name** — the provisioning module (**PUQ Synology**).
- **Server Group** — the WHMCS server group whose Synology server this product is provisioned on.
- **License key** — your pre-purchased **PUQ Synology** license key. The validation status and the
  paid-through date are shown right below the field; the key must be **active** for the module to work.

---

### Disk

![20-product-config-disk.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-6kadxozw.png)

> **Note:** **Display only.** The disk size/unit are shown to the client in the client area (and used for
> the usage-percentage chart and notifications). They do **not** enforce a limit on Synology. The real
> quota/permission limits must be configured on the **Synology group** selected here
> (Control Panel → User & Group → Group → Quota).

- **Disk size** — disk space shown to the client (display only). `0` = Unlimited.
- **Disk unit** — unit (MB / GB / TB) for the displayed disk space.
- **Synology group (enforces the real limits)** — the pre-configured Synology group assigned to
  provisioned users, chosen from a live drop-down of the groups that actually exist on the server.
  Use the refresh button to reload the list. Configure the real disk quota / permissions on this group in DSM.

---

### Notifications

![21-product-config-notifications.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-klmaloyz.png)

- **Notify at %** — usage threshold; when a client exceeds it, a low-disk-space notification is sent.
- **Email template** — the WHMCS email template used for low-disk-space notifications (`None` to disable).

---

### History

![22-product-config-history.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-a5azbs7u.png)

- **Save history (days)** — how many days of disk-usage statistics to keep in WHMCS.

---

### Client Area

![23-product-config-client-area.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-hgg8vr9h.png)

- **Link to instruction** — an optional URL; when set, a **User manual** button is shown in the client area.
- **Show password** — how the password is presented in the client area (**Show button** / plain text / hidden).

---

### User

![24-product-config-user.png](https://doc.puq.info/uploads/images/gallery/2026-06/embedded-image-h8z0bh9y.png)

- **Username rule** — template for the generated username, using macros:
  - Base: `{client_id}`, `{service_id}`
  - Random: `{random_digit_x}`, `{random_letter_x}` (where *x* is the length, e.g. `{random_digit_4}`)
  - Date & time: `{unixtime}`, `{year}`, `{month}`, `{day}`, `{hour}`, `{minute}`, `{second}`
  - Example: `{client_id}-{service_id}-{random_digit_4}`
  - The generated name is automatically normalised to be Synology/DSM compliant, and collisions with other
    services are resolved automatically.
- **Password rule** — generated password length (minimum 8), e.g. `12`. The generated password always
  includes lowercase, uppercase, digit and special characters to satisfy the Synology DSM
  password-strength rules.


<!-- sync:b9cf583a5b640c8f -->

