Process of Connecting to the Agent