E-Commerce Plugin

This stock plugin includes puzzles that can be used for implementing various e-commerce applications. It supports basic PayPal payments, WooCommerce 3D product views and configurators, as well as advanced ordering puzzles which work with WordPress-based e-commerce solution shipped with Verge3D.

E-commerce visual programming blocks

Contents

Puzzles Reference

paypal create order

Place PayPal order. This puzzle is the simplest ecommerce solution possible because it does not require any server-side configuration. To use it you only need verified PayPal business account.

Visual programming block to create PayPal orders
client ID
PayPal business account client ID. Use the following page to obtain it. For testing purposes there are Sandbox credentials, while for real selling you need to perform additional steps to receive Live credentials.
title
Product title.
item price
Product item price.
currency
Currency.
quantity
Amount of product.
on success do
Puzzles in this slot are executed upon successfull transaction.
on error do
Puzzles in this slot are executed upon errors (insufficient funds or so).

connect to WooCommerce

Connect to WooCommerce system to start receiving product information.

Using WooCommerce with visual logic blocks

For usage example, check out the following demo from the Asset Store: Drink Shop.

See this tutorial for more details.

product info

Returns a dictionary with product information retrieved by the connect to WooCommerce puzzle. This dictionary (a JavaScript object) contains the following fields:

Getting product info by using visual programming

product attribute

Returns the value for an attribute of the product option selected by the customer, e.g. "Yellow".

Visual programming block for getting product attributes

See this tutorial for more details.

place order

Composes and submits an order form to a specified URL. By default the order form is submitted to the sandbox ordering page.

Placing e-commerce order with visual programming block

For usage example, check out the following demo from the Asset Store: Ring.

Verge3D comes with a free WordPress plug-in that is able to handle requests submitted by this puzzle. Upon receiving such a request, this WordPress plug-in renders a page with an extended form supplemented with contact info, comments fields, and optional screenshot. Filled out form is finally submitted by the customer and a new order is created in WordPress admin interface.

send to
The URL of the order form provided by the WordPress plugin. Please refer to the following guide for setup information.
content
Order contents in human-readable form.
item price
Product item price.
quantity
Amount of product.
make screenshot
Make application screenshot and attach it to the order. Be sure to enable screenshots in the configure application puzzle otherwise the screenshot may be rendered in black.
Example of visual scripting blocks used for placing e-commerce orders

It's up to you (or sales manager) to verify corectness of the order content and price. Though very unlikely, a hacker may malform content submited by this puzzle and try to purchase a product for lesser price. To prevent it, you need to verify your orders by using the place order + puzzle which rely on product info assigned on the server.

place order +

Composes and submits an order form to a specified URL. This puzzle works similar to place order, but has more features, greater security, and allows for customizations.

Visual programming block to place advanced orders

For usage example, check out the following demo from the Asset Store: Recliner.

send to
The URL of the order form provided by the WordPress plugin. Please refer to the following guide for setup information.
item(s)
Order item or a list of order items. See below for more info.
attachment(s)
Order attachment or a list of order attachments. Attachment is a Data URI link which represents a screenshot, image, sound, video, PDF, text, or a glTF model.

Example usage:

Set of visual programming blocks for placing e-commerce orders

order item (sku, qty)

Order item to be used in the place order + puzzle.

Order item visual programming block
sku
The SKU (stock keeping unit) of the product registered by WordPress plugin. Please refer to the following guide to find out how setup products.
quantity
Amount of product.

Having Troubles with Puzzles?

Seek help on the forums!