> ## Documentation Index
> Fetch the complete documentation index at: https://mbcz.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Configuration

> Configuring Pyramid

The `config.yml` controls the economic parameters and retention settings of the plugin.

## Default Configuration

```yaml theme={null}
# Pyramid Configuration

# Revenue distribution rates.
rates:
  tier1: 0.05 #(5%) Direct Upline Commission
  tier2: 0.01 #(1%) Indirect (Tier 2) Commission
  referral-bonus: 100.0 # One-time bonus for successful recruitment.

# Operation Mode:
# 'tax' = Commission is deducted from the recruit's income. (Deflationary)
# 'printer' = Commission is generated by the server. (Inflationary)
mode: tax

# Retention & Activity Settings
retention:
  enabled: true
  inactivity-days: 14  # Days before a player is removed from a downline
  check-interval-hours: 24  # Frequency of retention checks
  
  # Activity Requirement: Upline must be active to receive commissions
  upline-activity-required: true
  upline-activity-threshold-hours: 24 # Hours since last login required to receive payout

database:
  type: sqlite # Options: sqlite, mysql
  host: localhost
  port: 3306
  database: pyramid
  username: root
  password: ""
  ssl: false
  pool-name: "Pyramid-Capital-Pool"
  max-pool-size: 10
```

## Settings Explained

### Rates

* `tier1`: The percentage (0.05 = 5%) allocated to the direct recruiter.
* `tier2`: The percentage allocated to the second-level recruiter.
* `referral-bonus`: A fixed amount paid to the recruiter immediately upon a successful join.

### Operation Mode

* **tax**: The commission is taken from the invitee's earnings. This mimics a traditional tax or fee structure.
* **printer**: The commission is added on top of the invitee's earnings. This rewards recruiters without penalizing new players, but introduces more currency into the server.

### Retention

Automated system to manage inactive associations.

* `upline-activity-required`: Enforces active participation. If an upline player has not logged in within the threshold, they forfeit commissions until they return.
