How do I spawn a trigger box only after having a variable?

your trigger box set default to active. or deactive…
then, when u got a key. find the ref of trigger box use get actor by tag, by class, etc. then set to active.