You can choose to consume both your Reaction, and the required AP of an action, to perform an action at a set trigger. You must describe the trigger preemptively. When the trigger is met, the action is performed. If you ready a spell, the Cast is consumed in the process of readying the spell.