The aim of this paper, is to provide a logical framework for reasoning about actions, agency, and powers of agents and coalitions in game-like multi-agent systems. First we define our basic Dynamic Logic of Agency (DLA). Differently from other logics of individual and coalitional capability such as Alternating-time Temporal Logic (ATL) and Coalition Logic, in DLA cooperation modalities for expressing powers of agents and coalitions are not primitive, but are defined from more basic dynamic logic operators of action and (historic) necessity. We show that STIT logic can be reconstructed in DLA. We then extend DLA with epistemic operators, which allows us to distinguish capability and power. We finally characterize the conditions under which agents are aware of their capabilities and powers. Keywords Logic of agency