Export and Import Shop Accounts

Sana Commerce Cloud allows to export and import shop accounts. For example, if you have several webstores or different Sana environments, for example, beta and live, then you can export shop accounts from one webstore or environment and import them to another.

Also, if you have a list of new shop accounts which you want to use in a webstore, using the import functionality, you can easily import the list to Sana Admin and use the imported shop accounts in your webstore.

Export Shop Accounts

To export shop accounts, in Sana Admin click: Customers > Shop accounts and then, click Export.

All existing shop accounts will be exported from Sana Admin to the CSV file. In the CSV file, you will see the name, email address, account type, account Id, account role of each shop account and also whether a shop account is activated or not activated. The field Password will be empty, because shop account passwords are not exported to the CSV file and they cannot be used during import.

Import Shop Accounts

If you have a customer list that you want to use in Sana, you can add it to a CSV file and then import to Sana Admin. You can use the CSV template to create a list of shop accounts. Importing shop accounts is the fastest way to add new shop accounts in bulk.

Also, you can export shop accounts from Sana Admin to the CSV file, update the shop account details if necessary, and then import them to Sana Admin for another webstore or environment.

Step 1: In Sana Admin click: Customers > Shop accounts.

Step 2: Click Import.

Step 3: Download the CSV Example file and open it. This is just a template where you can enter the details of all shop accounts which you want to import. You will need to enter the same data as if you create a shop account in Sana Admin. See the CSV Example file. It can be downloaded directly from Sana Admin.

Step 4: Fill in the CSV Example file with the shop account details.

Field

Description

Name

The name of the customer (contact or sales agent).

EmailAddress

The e-mail address of the customer (contact or sales agent) which is used as a login name in the webstore.

If you use the Single sign-on authentication type, the customer's e-mail address must be the same in the identity provider.

Password

The password of a shop account which is used to log in the webstore.

When the password field is empty, a password will be auto-generated. In this case, customers can change the auto-generated password in the webstore using the Forgot password feature on the Login page.

If you use the Single sign-on authentication type, leave this field blank, because the customer must use the credentials from the identity provider to log in to the Sana webstore.

Activated

Determines whether a shop account is activated. Possible values:

  • "0" - Not activated

  • "1" - Activated

AccountType

The shop account type. Possible values:

  • "1" - Customer

  • "2" - Contact

  • "3" - Sales agent

AccountIds

Account ID of the shop account. The account ID should be taken from your ERP system. You can add one account ID or multiple account IDs to a shop account. Multiple account IDs must be separated with the vertical bar “|” character. Multiple account IDs are allowed only for the Customer shop account type with the Regular account or Account manager account role.

AccountRole

The shop account role. Possible values:

  • "1" - Regular account

  • "2" - Account manager

  • "3" - Sub-account

The shop account role will be set to regular account, if value is empty. Only shop accounts of the Customer type can have the Account manager and Sub-account roles.

When using the Single sign-on authentication type, only shop accounts with the Regular account role are supported.

CanOrderProducts

Determines whether a shop account can order products in the webstore. Possible values:

  • "0" – Cannot order products

  • "1" – Can order products

CanSeePrices

Determines whether a shop account can see prices in the webstore. Possible values:

  • "0" – Cannot see prices

  • "1" – Can see prices

CanSeeStock

Determines whether a shop account can see stock in the webstore. Possible values:

  • "0" – Cannot see stock

  • "1" – Can see stock

AuthenticationType

Sana Commerce Cloud supports two different types of authentication for webstore customers – Sana’s internal shop accounts and single sign-on with accounts that exist in your identity provider.

Leave this field empty if internal Sana authentication should be used with this account, or specify SSO for single sign-on.

SingleSignOnUserId

A unique identifier of the user in the identity provider when single sign-on is used.

Approved

Determines whether an account is approved. Possible values:

  • “0” – Approval is pending

  • “1” – Account is approved

Pending approval status can be set only for shop accounts with Customer type. Account is approved by default if the field is left empty.

NOTE

If you use Microsoft Excel to fill in the CSV file with shop accounts, please remember that Excel does not correctly handle the special characters (after it is saved) that are specific for some languages, for example Spanish. Thus, if you have special characters, for example in the customer's name, you should use some other editor (for example Notepad) to fill in the CSV file that can correctly handle the special characters.

Step 5: When the CSV file is filled in with shop account details, on the Import shop accounts page, click Select file to add the file.

Step 6: Enable the option Send confirmation email to new activated shop accounts to send the confirmation e-mail to new activated shop accounts. The confirmation e-mail will be sent to the e-mail address entered in the shop account details. The e-mail contains a link, using which a customer can reset the default password generated by a webstore administrator and log in to the webstore.

The New Shop Account By Shop Admin e-mail template is used to send a confirmation e-mail to a customer. For more information, see E-mail Templates.

Step 7: Enable the option Send confirmation email to existing activated shop accounts to send the confirmation e-mail to existing activated shop accounts changed by a webstore administrator. The confirmation e-mail will be sent to the e-mail address entered in the shop account details. The e-mail contains a link, using which a customer can reset the default password generated by a webstore administrator and log in to the webstore.

The New Shop Account By Shop Admin e-mail template is used to send a confirmation e-mail to a customer. For more information, see E-mail Templates.

Step 8: Enable or disable the Generate new passwords for existing shop accounts option. Below see the explanation of how this option works in case the shop accounts which already exist in Sana Admin are imported and in case new shop accounts are imported to Sana Admin.

Existing Shop Accounts Are Imported to Sana Admin

  • If the Generate new passwords for existing shop accounts option is disabled, then the passwords which already exist in Sana Admin are used for the imported shop accounts.

  • If the Generate new passwords for existing shop accounts option is enabled and passwords are not entered for the shop accounts in the CSV file, then Sana automatically generates random passwords for the shop accounts during import. In this case, a customer needs to use the Forgot password functionality on the login page in the Sana web store to reset the password which was automatically generated by Sana during import and create a new password.

  • If the Generate new passwords for existing shop accounts option is enabled and passwords are entered for the shop accounts in the CSV file, then after import the passwords from the CSV file will be used for the shop accounts.

New Shop Accounts Are Imported to Sana Admin

  • If the Generate new passwords for existing shop accounts option is enabled and passwords are not entered for the shop accounts in the CSV file, then Sana automatically generates random passwords for the shop accounts during import. In this case, a customer needs to use the Forgot password functionality on the login page in the Sana web store to reset the password which was automatically generated by Sana during import and create a new password.

  • If the Generate new passwords for existing shop accounts option is enabled and passwords are entered for the shop accounts in the CSV file, then after import the passwords from the CSV file will be used for the shop accounts.

Step 9: Click Upload to import shop accounts from the CSV file.

NOTE

If a shop account already exists (based on the e-mail address), it will be updated.