feat: add agent instance lifecycle contracts (#2427)