Data Trades
This mod adds the ability for players, serverowners or modpack creators to overwrite villager trades using datapacks.
The amount of trades per level and the actual items traded can be customized using json files.
A command for development purposes called /villagers refresh will manually trigger a re-asign of trades to all loaded villagers.
Folder Structure
Using a datapack, the trades of a specific villager profession can be overwritten by creating a JSON file following this
pattern:
data/[namespace]/villager/professions/[path].json
[namespace] and [path] should be overwritten by the specific villager professions ID.
For example, to create trades for the minecraft:fletcher profession,
a file under data/minecraft/villager/professions/fletcher.json should be created.
Examples
Datapacks with examples can be found here.
JSON-Schema
More information about the actual JSON schema and properties can be found here