Launch survey at the end of Call answered by the agent

Yes, build your own dial plan and add it to a hook for hang up.

I’d recommend moving to a supported version of the PBX. Beyond feature enchantments, there are numerous security patches.