Enchant/disenchant (Effect) — Skript
Addon: Skript · Category: Effect · Since: 2.0, 2.13 (at level)
Syntax
enchant %~itemtypes% with %enchantmenttypes%Description
Enchant or disenchant an existing item. Enchanting at a specific level will act as if an enchanting table was used, and will apply the enchantments randomly chosen at that level. Treasure enchantments, like mending, can optionally be allowed. Note that enchanting a book at a specific level will turn it into an enchanted book, rather than a book with enchantments.
Examples
enchant the player's tool with sharpness 5
enchant the player's tool at level 30
disenchant the player's tool