Using RocketChat engine in a ERP

I’m thinking about integrating Rocket Chat in a CRM, so users can chat each other, but I don’t want to synchronize rocket user database with the CRM database.

I was thinking to solve this way: each time 2 users want to chat, with the API commands, I create a temporary room, then I create temporary users in rocket with permission only to that room, and then I add an IFRAME in my CRM website accessing to that chat room, with the “?layout=embedded” thing to embed it perfectly in the iframe.

Does it make sense ?
Is there any way or easier way to have the rocket chat engine, to create chats (always) between 2 users, fully integrated in a CRM, ERP or other software ?

thank you