Sana Assistant (online)
Table of Contents

ProductConfiguratorContext reference

This article provides reference material about ProductConfiguratorContext class.

ProductConfiguratorContext class is used during the process of specific product configuration to pass information from Sana to the configurator extension. It is available as a parameter in GetConfiguratorUrlAsync method of product configurator extensions.

Properties

ProductConfiguratorContext class

Account

The current ERP account which is used to communicate with ERP.

CallbackUrl

Gets the callback URL to which the configurator service can post values back to Sana.

ConfigurationId

The globally unique value identifying selected configuration options.

This value is also sent to the ERP with the corresponding configured sales lines and can be used to match these lines with the configuration details on the ERP side.

ConfiguratorModel

Gets the configurator model specific to currently configured product.

Product configurator may have a few different models to configure products. For example product configuration result can be:

  • pre-created (already existing) product item in ERP
  • new product which is saved to ERP

This property contains the value that comes from configurator model field of product entity.

ExternalConfigurationId

Gets the identifier of current product configuration on configurator service's side.

This is the value that the external configurator service may generate and use as it's ID for this particular configuration. Sana refers to it as a session ID on configurator service's side. It can be used to edit existing product configuration that has been created by a user some time before.

IsAuthenticated

Gets the value indicating whether user browsing the web store is authenticated. Guest user is not considered Authenticated.

IsConfigurationCopy

Gets a value indicating whether the product configuration was created as a copy of the already existing configuration.

The user may copy the current basket to the wishlist or to the to order templates and order the same products next time, in this case this property will have true value.

When the user orders the same products the ExternalConfigurationId will contain an ID of already existing configuration in external configurator service, because it had been created already previously. It is recommended that the configurator extension creates a new product configuration when IsConfigurationCopy value is true.

IsEditOrder

Gets a value indicating whether the current basket is created to edit order. When the user edits existing order in Sana, this property will have true value.

When the user is editing existing order the ExternalConfigurationId will contain an ID of already existing configuration in external configurator service, because it had been created already previously. It is recommended that the configurator extension creates a new product configuration when the user is editing existing order.

IsReorder

Gets a value indicating whether the current basket is created to re-order. The user may choose to re-order existing sales order, in this case this property will have true value.

Here the same rule applies as with IsEditOrder property.

When the user is re-ordering existing order the ExternalConfigurationId will contain an ID of already existing configuration in external configurator service, because it had been created already previously. It is recommended that the configurator extension creates a new product configuration when the user is re-ordering existing order.

LanguageId

Gets the identifier of the language selected by the user in the web store.

ProductId

Gets the identifier of the master product from which the configuration is created.

Quantity

Gets the quantity of the product being configured as selected by the user to pass it from Sana to the configurator extension.

UnitOfMeasureId

Gets the unit of measure of the product being configured as selected by the user to pass it from the Sana to the configurator extension.

User

The current user browsing the web store.

See also