Add session functionality.