If you're using UCCX 4.0, then you can route to an agent (but not queue to an agent). You could capture the ID of the agent handling the call and store it in a session variable. The "Implementation ID" can be used as the session mapping variable to pass information between applications.
You would have to handle the situation when the destination agent is unavailable.
These are the paths to get to each CCX logs through CLI. They may be helpful if you are having issues accessing RTMT or downloading logs through it.
If you want to download them you have to prefix "file get " and you can add one of the options (re...