Purchase of goods and services without user registration

In this example, we demonstrate how to place a guest order without requiring user registration.

✅ Purpose of the scenario:
  • User is not authorized.
  • The user fills out a form with contacts (for example, guest_orders).
  • Selects products (you can pre-set a list).
  • The order is placed for the user guest_user.
✅ What you need:
  • A valid PROJECT_URL and APP_TOKEN for authentication with the OneEntry API.
  • marker of the guest order form, for example guest_orders
  • list productId and quantity
📌 Important:
  • The form fields (marker, type) must match the form settings in the admin panel.
  • If you need to send a notification about an order, you can use Events.
  • These examples do not include error handling.
  • You can manage errors using a try-catch block or by employing a construction like await Promise.catch((error) => error).
Loading sandbox…