In this study we develop a flexible modeling toolbox for decentralized electricity systems with an agent-based simulation approach at its core. Two RES-E generation models for wind and PV each with a high temporal and spatial resolution are presented and approaches to model specific aspects of the demand side in detail are introduced. The implementation of an AC load flow algorithm is described and the concept of a market-based congestion management mechanism is outlined.