title: How to design a web api for mobile app usage?
body: <p>We are building a mobile app, specifically an android app, and it needs to connect to the server to get data. It is not like twitter, we do not need to expose some kind of public apis. We just need to keep it simple and safe because user will exchange some private data with the server.</p>
  
  <p>My questions is mainly on authentication. Our server will have a user database.</p>
  
  <ol>
  <li>How to register and login in my mobile app ? What kind of mechanism should be implemented in the server side and the client side.</li>
  <li>How to keep the session after login?</li>
  <li>If I need to let user could login without input his username/password next time when he open the app, What should I do? I just think to store his password in the mobile client is not a good idea.</li>
  </ol>