Home›Java›Mods›AutoKeyall | Minehut Friendly | AFK Detection
AutoKeyall | Minehut Friendly | AFK Detection
ModsJava

AutoKeyall | Minehut Friendly | AFK Detection

Java mod listed for Minecraft 1.17–26.x. Downloads from the MC Java Mods app on Android.

⬇ Download on Spigot

AutoKeyall | Automatic Key Rewards | AFK Detection | PlaceholderAPI


AutoKeyall is a lightweight Spigot plugin that automatically rewards active (non-AFK) players with keys based on two systems:

⏱ Timed Rewards — Give keys to players every X minutes based on their rank/permission.
Player Count Milestones — Give keys to all active players when the server hits a certain player count.

Discord Support: https://discord.gg/U5UaGJB2Ve​


⚡ Features

Requirements

Configuration
Spoiler: Click to view full config
Code (Text):

# =============================================
#           AutoKeyall Configuration
#          Authoer: Abood_8001
#        github.com/Abood8001/AutoKeyall
# =============================================

# -----------------------------------------------
# AFK CHECK
# If true, AFK players will NOT receive rewards.
# If false, all online players get rewards.
#
# A player is treated as AFK if EITHER:
#   - EssentialsX reports them AFK (manual /afk or Essentials' auto-afk), OR
#   - Native idle detection (below) sees no activity for the threshold time.
#
# Fail-safe: if afk-check is on but NO reliable AFK signal is available
# (EssentialsX missing/erroring AND native-afk-detection disabled), players
# are skipped rather than rewarded, so AFK players never slip through.
# -----------------------------------------------
afk-check: true

# -----------------------------------------------
# NATIVE AFK DETECTION
# Lets AutoKeyall detect AFK players on its own, without needing
# EssentialsX' auto-afk timer to be configured.
# A player counts as active when they move, interact, chat, run a
# command, or click in an inventory.
#
#   native-afk-detection - true to enable plugin-side idle tracking
#   native-afk-seconds   - seconds of no activity before a player is AFK
# -----------------------------------------------
native-afk-detection: true
native-afk-seconds: 300

# WORLD BLACKLISTS
# Players in these worlds will NOT receive rewards
blacklisted-worlds-rewards:
  - "world_event"
  - "creative"

# Players in these worlds will NOT count toward milestone player count
blacklisted-worlds-milestone-count:
  - "world_event"

# -----------------------------------------------
# TIMED REWARDS (Interval-based)
# Gives rewards to active players every X minutes.
#
# Options:
#   interval   - How often (in minutes) to give the reward
#   permission - Leave empty ("") for all players
#                Or set a permission node for a specific rank
#                Example: "autokeyall.vip"
#   commands   - Commands to run. Use %player% for the player's name
#   message    - Broadcast message when reward is given. Leave empty ("") to disable
# -----------------------------------------------
groups:
  # Default group — applies to all players with no special permission
  default:
    interval: 15
    permission: ""
    commands:
      - "crate key give %player% playtime 1"
    message: "&aA playtime key has been given to all active players!"

  # Example ranked group — only players with this permission get this reward
  clientid:
    interval: 10
    permission: "autokeyall.clientid"
    commands:
      - "crate key give %player% playtime 1"
    message: "&6[VIP] &aA VIP key has been given to all active VIP players!"

# -----------------------------------------------
# PLAYER COUNT REWARDS (Milestone-based)
# Gives rewards when the server hits a certain player count.
#
# Options:
#   cooldown-seconds - How long (in seconds) before the same milestone
#                      can trigger again. Prevents abuse (join/leave spam).
#                      Example: 900 = 15 minutes cooldown
#
# Milestone options:
#   permission     - Leave empty ("") for all players
#                    Or set a permission node for a specific rank
#   commands       - Commands to run. Use %player% for the player's name
#   reached-message - Broadcast message when milestone is hit. Leave empty ("") to disable
#   next-message   - Broadcast message hinting at the next milestone. Leave empty ("") to disable
#                    Use %current% for current player count and %next% for next milestone count
# -----------------------------------------------
player-count-rewards:
  cooldown-seconds: 900

  milestones:
    20:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e20&a! Keys given to all active players!"
      next-message: ""
    25:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e25&a! Keys given to all active players!"
      next-message: "&eNext keyall at &b%next% players&e! Currently &b%current%&e/&b%next%&e."
    30:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e30&a! Keys given to all active players!"
      next-message: "&eNext keyall at &b%next% players&e! Currently &b%current%&e/&b%next%&e."
    35:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e35&a! Keys given to all active players!"
      next-message: "&eNext keyall at &b%next% players&e! Currently &b%current%&e/&b%next%&e."
    40:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e40&a! Keys given to all active players!"
      next-message: "&eNext keyall at &b%next% players&e! Currently &b%current%&e/&b%next%&e."
    45:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e45&a! Keys given to all active players!"
      next-message: "&eNext keyall at &b%next% players&e! Currently &b%current%&e/&b%next%&e."
    50:
      permission: ""
      commands:
        - "crate key give %player% playtime 5"
      reached-message: "&aPlayer count reached &e50&a! Keys given to all active players!"
      next-message: ""
 


❓ FAQ

Q: Does it work with any crate plugin?
A: Yes! Just put your crate plugin's command in the commands: section.

Q: What if EssentialsX is not installed?
A: Yes! The plugin will still work without EssentialsX.

Q: Will AFK players count toward the player count milestone?
A: Yes they are counted in the total but they will NOT receive the reward.

Commands

Plugin details

Read from the plugin's own plugin.yml.

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

AutoKeyall | Minehut Friendly | AFK Detection is a free Minecraft Java mod. Compatible with Minecraft 1.17, 1.18, 1.19, 1.20 and newer. Downloaded 29 times (via Spigot). Download it and open it directly in the game.

Explore more