User login, sessions info & ecommerce apps - best practices

Hi all,
I’m looking for the best practices regarding user login and temporary information storage in ecommerce apps (I’m developing one). I’m a bit puzzled as the requirements are contradictory. Any advice is highly appreciated.

From ecommerce perspective, it is better to defer user login as far as possible (ideally - avoid it at all). User should not be forced to enter login, password etc. at the beginning - it’s better to create the account later during checkout.

But from App perspective (meaning Adalo app), app has to store the information somewhere. So in most of the examples I’ve seen the info about shopping cart, items, etc. is related to “Users” collection and connected to specific user.

And here comes my question: are there any known best practices how to match these two approaches? Any way to store some information (shopping cart for example) BEFORE logging the user in? Or may be any way to autocreate the accounts for the users?

I’ve found some workarounds, for example, specific “Session” collection with auto-generated session IDs, where I can store temporary info. But I don’t want to reinvent the wheel - therefore asking for advice.

Thanks a lot!

Hi @Victor,

I like your idea for the workaround for storing a session but unfortunately you won’t have any way to tie that back to the user making those actions later.

There is currently a feature request that this would fall under and that is the ability to make use of, or track a “visitor” in order to create data from the unregistered user. Give it an upvote and you will be notified when this feature is released! https://ideas.adalo.com/feature-requests/p/guest-tracking

3 Likes

Yes, that is something Amaz*me :smile: understood, letting us place all wanted items in a basket, and only while wanting to purchase…having to log-in - very friendly/smart

…I guess they do it with cookies…and if no cookies…we’ll remain hungry !
:man_shrugging: :yum:

1 Like

Hi @Colin,

I experimented a bit and have created the POC for late login. I use auto-generated logins, so user is able to:

  • perform a completely anonymous purchase;
  • start anonymously, create order and Sign Up (register) on checkout stage. I experimented with two options: (1) User login is converted from “pseudo-login” to real one, and order is attached to it, and (2) Completely new account is created and order is attached to it.
  • start anonymously and Login with the existing credentials on checkout stage. Order is re-attached to existing login after login.

Here is the app: https://previewer.adalo.com/836be7ca-61ca-404d-9207-e6ea64a2d684
A lot of debug info is there, it’s not ready for production :).

I would be very thankful for comments from Adalo experts - if this solution looks feasible for production, and if any improvements could be made.

I’ve made a video with some explanations (8 mins), so that one can understand the logic better.

Thanks!

6 Likes

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.