Rocket chat Integration in my web sites

How to integrate Rocket Chat into our application using jQuery or Javascript as a Service??

Is there any free API available to do the integration??

Did you read the manual ?

yes, Still need more clarity. API to integrate Live Chat with our PHP application, it can be a javascript code (or) SDK.

Also, we must have a prolonged session, (i.e.,) the user once logged in with rocket chat must be available till he gets logged out of browser

The docs are pretty clear. Exactly what don’t you understand?

I think what you actually want is someone to write it for you, and that is not really what the forum is about.