Reference > Shop flow URLs > Trading subsystem URLs > Account and contract URLs


AccountImport URL

This URL imports a business account in XML format into WebSphere Commerce.


URL structure

https:// host_name/path

The fully qualified name of the WebSphere Commerce Server and the configuration path.

Diagram of the URL structure: The URL starts with the fully qualified name of the WebSphere Commerce Server and the configuration path, followed by the URL name, AccountImport , and the ? character. End the URL with a list of parameters in the form of name-value pairs. Separate each <a href=name-value pair with the & character. For a detailed description of the parameters and their values, see the list entitled Parameter values." />

Before issuing This URL, be logged into WebSphere Commerce. You can log in to WebSphere Commerce using the Logon command. For more information in the Logon command, see the related reference below.


Parameter values

fileName

Required: The name of the XML file that to import as a business account. The XML file must be validated with the B2BTrading DTD.

The XML file being imported must exist in the location specified in the WebSphere Commerce configuration file, and the file must be validated with the B2BTrading DTD or Package.xsd.

The location for the business account XML file to be imported is specified in the XMLPath attribute of the Trading tag in the WebSphere Commerce configuration file. For example, if the WebSphere Commerce configuration file contains the following lines:

<Trading
DTDFileName="B2BTrading.dtd"
DTDPath="/trading/dtd"
XMLPath="/trading/xml"
XSDPath="/trading/xsd" />

The business account XML file to be imported using This URL must be in WC_EAR /xml/trading/xml.

xsd

Required: Specifies whether the account XML is in DTD or XSD format. Use true to specify the account XML is in XSD format, otherwise use false.

validate

Specifies whether the account XML should be validated by the XML parser. Valid values for this parameter are true and false. Use true to have the account validated. Use false to prevent the account from being validated by the XML parser.

If this parameter is not specified, a value of true is assumed.

URL

Required: The URL to be called when the command completes successfully.


Example

The following example imports an account:

https://myhostname/webapp/wcs/stores/servlet/
AccountImport?fileName=myaccountfile.xml&xsd=false&URL=StoreCatalogDisplay?storeId=512&catalogId=512


Behavior

This URL imports a business account into the WebSphere Commerce database from an XML file. Before importing the business account, the command checks to ensure the business account being imported meets the following conditions:


Exception conditions

The following exceptions may be thrown by this comment:


+

Search Tips   |   Advanced Search