Last updated

Customer Service schemas

The Customers namespace is concerned with Customer and Company management.

Accounts

Account

An Account is related to a Customer. Each Account can belong to only one Application. When creating Customers you need to define a Customer.Account if you want the customer to be able to login. This is useful when the application supports My page with order history and such.

Idinteger or null(int32)

The internal Id of the Account. This value should be used as updatedBy/createdBy in API-Methods. When creating a new Account on a Customer leave this blank as Storm will generate the Id.

Keystring(guid)

The system wide unique Key for the Account.

LoginNamestring

This is the login name used when logging in. Normally this is the email address. Care must be taken when user updates their emailAddress. Normally this update is just for Customer.Email. It is up to the Application to keep Customer.Email in sync with Account.LoginName if they are the same. MaxLength: 255.

Namestring

This is the full name of the connected Customer's first and last name. MaxLength: 100.

RolesArray of integers(int32)

This is an integer list of Role.Ids. See Application.Roles for available roles for the Application. This can be used to authorize roles to different parts of an Application.

AuthorizationsArray of objects(IdValue)(IdValue)

This is an IdValue list of Authorizations. See Application.Authorizations for available values for the Application. This can be used to authorize users to different parts of an Application.

IsActiveboolean

Indicates if the Account is Active or not. Use UpdateAccountStatus to change this value.

AgreementAccount

An AgreementAccount is a special account connected to a priceList. Users can login to an AgreementAccount if the priceList is setup with a code. Note that when using AgreementAccounts any agreement code must be unique amongst all priceLists.

PricelistIdinteger(int32)

The PriceListId of the PriceList logged in to.

Namestring

The Name of the AgreementAccount/PriceList. MaxLength: 50.

StartDatestring or null(date-time)

The StartDate of the AgreementAccount/PriceList.

EndDatestring or null(date-time)

The EndDate of the AgreementAccount/PriceList.

ImageKeystring or null(guid)

A unique id for the image at our image server. Url for images are formed like http://[client specific CDN]/{ImageKey}. Preset, height and width can be sent as parameters.

ShowPricesIncVatboolean or null

Indicates if prices should be shown inc or ex VAT.

Address

Information about an address. Addresses appear as InvoiceAddress or DeliveryAddresses or when ever an Address is needed

Idinteger or null(int32)

The internal Id of the Address. When creating a new Address leave this blank as Storm will generate the Id.

CareOfstring

The CareOf of the Address. MaxLength: 100.

Line1string

The first address line of the Address. MaxLength: 255.

Line2string

The second address line of the Address. MaxLength: 255.

Zipstring

The zip code of the Address. MaxLength: 50.

Citystring

The City of the Address. MaxLength: 50.

CountryIdinteger(int32)

The internal Id for the country associated to the Address. When creating or updating Country on an Address either specify the CountryId or just the Country string. If Id is specified it will be used to resolve the Name. If none is specified the default for the Application will be used.

Countrystring

The country name of the Address. When creating or updating Country on an Address either specify the CountryId or just the Country string. If Name is specified it will be used to resolve the Name and Id. Name should then be specified as Country.Code since Names are culture specific. If none is specified the default for the Application will be used. MaxLength: 50.

Regionstring

The Region of the Address. MaxLength: 50.

IsValidatedboolean

Indicates if the address had been validated. It is up to the Application to validate addresses. Use normal address-methods to update this value.

GlobalLocationNostring

The Global Location Number (GLN) is part of the GS1 systems of standards. It is a simple tool used to identify a location and can identify locations uniquely where required. This is only used for invoice addresses. MaxLength: 50.

ShippingPhoneNumberstring

Phone number for shipping address. Only applicable in shipping addresses. MaxLength: 50.

Companies

Company

Information about a Company.

Idinteger or null(int32)

The internal Storm Id for the Company. When creating a new Company leave this blank as Storm will generate the Id.

Keystring(guid)

The system wide unique Key of the Company.

Codestring

The external code. Usually the id in the erp system. MaxLength: 50.

Namestring

The Name of the Company. MaxLength: 100.

OrgNostring

The organizational number of the Company. Used to identify the Company for some payment methods. The combination of OrgNo and Name must be unique. MaxLength: 50.

Phonestring

The Phone number of the Company. MaxLength: 50.

ReferIdinteger or null(int32)

Used to tag a Company with some external id.

ReferUrlstring

Used to tag a Company with an incoming URL. MaxLength: 255.

DeliveryAddressesArray of objects(Address)(Address)

A list of delivery Addresses for the Company. When needed the first address in the list will be used. So it is vital in the checkout process to either sort them or just supply one delivery address. Company addresses will override Customer addresses if both exists in the Checkout process.

InvoiceAddressobject(Address)(Address)
UseInvoiceAddressAsDeliveryAddressboolean

Can be used when updating or inserting addresses on Company. If set to true the invoice address will be used as a delivery address as well. Then just an invoice address needs to be passed in. The deliveryAddress will be ignored. If set to false both invoice address and delivery address must be specified.

InfoArray of objects(IdValue)(IdValue)

Contains a list of id-value pairs specific to the client for this company. Use ApplicationService.ListCompanyInfoTypes for id lookup.

PricelistIdsArray of integers(int32)

Contains a list of priceList ids valid for this company. It will be empty if no priceLists exist. It can be used to check products lists if they are from a company specific priceList. No need to pass this into List-methods since they are considered any way in the methods. This property should be considered as ReadOnly as priceLists are maintained else where.

ParentIdinteger or null(int32)

Points to an optional parent company. Used when companies are connected some how.

DeliveryMethodIdsArray of integers(int32)

Contains a list of delivery method ids valid for this company. It will be empty if no delivery methods exist.

PaymentMethodIdsArray of integers(int32)

Contains a list of payment method ids valid for this company. It will be empty if no payment methods exist.

Emailstring

The Email address of the Company. MaxLength: 255.

FlagsArray of objects(Flag)(Flag)

A list of Flags of the Company. See Flag for information about flags. Flags can be used in Promotions or otherwise to provide custom handling of specific Companies.

VatNostring

This is the VAT registration number for the company. MaxLength: 50.

CompanyDiscount

Company discounts are specific discounts that are not based on priceLists and applied on product prices before display. Best price will be taken. Discounts are not stackable.

TypeIdinteger(int32)

The TypeId defines the rule for how Value is interpreted. 1 = Category discount, 2 = DiscountCode on product. Cannot be changed.

Valuestring

The value to check for on products. If TypeID = 1 then discounts are valid for all products belonging to Category with Category.Code = Value. If TypeId = 2 then the product's discount code is checked. Cannot be changed. MaxLength: 50.

Discountnumber(decimal)

The actual discount percentage. Ex: 15.00 equals 15% discount.

PriceListTypeSeedstring

An optional comma-separated list of priceList type-ids for which the discount is valid. MaxLength: 50.

CompanyPaymentMethod

Defined payment method for a Company.

CompanyCodestring

The external code of the company. MaxLength: 50.

PaymentMethodCodestring

The external code of the payment method. MaxLength: 50.

InvoiceCaptureSettingsCodestring

The invoice capture settings code (if any is set). MaxLength: 50.

IsActiveboolean

Whether or not the company payment method is active.

Contact

Obsolete, will be removed in a coming version. Information about a Contact. Contacts are people not acting ac Customers in an Application. Contacts are created in the Admin UI.

Idinteger or null(int32)

The internal Id of the Contact.

Keystring(guid)

The system wide unique Key for the Contact.

Codestring

The external code. Usually the id in the erp system. MaxLength: 50.

ResponsibilityIdinteger(int32)

The ResponsibilityId of the Contact.

Emailstring

The Email of the Contact. MaxLength: 255.

FirstNamestring

The FirstName of the Contact. MaxLength: 50.

LastNamestring

The LastName of the Contact. MaxLength: 50.

Phonestring

The Phone number of the Contact. MaxLength: 50.

CellPhonestring

The CellPhone number of the Contact. MaxLength: 50.

ImagePathstring

MaxLength: 255. Obsolete! - Use ImageKey

ImageKeystring or null(guid)

A unique id for the image at our image server. Url for images are formed like http://[client specific CDN]/{ImageKey}. Preset, height and width can be sent as parameters.

Customers

Customer

Information about a Customer.

Idinteger or null(int32)

The internal Storm Id of the Customer. When creating a new Customer leave this blank as Storm will generate the Id.

Keystring(guid)

The system wide unique Key of the Customer.

Codestring

The external code. Usually the id in the erp system. MaxLength: 50.

Emailstring

The Email address of the Customer. MaxLength: 255.

SSNstring

The social security number of the Customer. Used to identify the Customer for some payment methods. MaxLength: 50.

FirstNamestring

The FirstName of the Customer. MaxLength: 50.

LastNamestring

The LastName of the Customer. MaxLength: 50.

Phonestring

The PhoneNumber of the Customer. MaxLength: 50.

CellPhonestring

The CellPhone number of the Customer. MaxLength: 50.

ReferIdinteger or null(int32)

Used to tag a Customer with some external id.

ReferUrlstring

Used to tag a Customer with an incoming URL. MaxLength: 255.

Accountobject(Account)(Account)
CompaniesArray of objects(Company)(Company)

A list of Companies. A Customer can have many Companies. The first will be used as default. In the Checkout process just pass in one Company if any is to be used or the first will be used as default.

DeliveryAddressesArray of objects(Address)(Address)

A list of delivery Addresses for the Customer. When needed the first address in the list will be used. So it is vital in the checkout process to either sort them or just supply one delivery address. Company addresses will override Customer addresses if both exists in the Checkout process.

InvoiceAddressobject(Address)(Address)
FlagsArray of objects(Flag)(Flag)

A list of Flags for the Customer. See Flag for information about flags. Flags can be used in Promotions or otherwise to provide custom handling of specific Customers.

UseInvoiceAddressAsDeliveryAddressboolean

Can be use when updating or inserting addresses on Customer. If set to true the invoice address will be used as a delivery address as well. Then just an invoice address needs to be passed in. The deliveryAddress will be ignored. If set to false both invoice address and delivery address must be specified.

InfoArray of objects(IdValue)(IdValue)

Contains a list of id-value pairs specific to the client for this customer. Use ApplicationService.ListCustomerInfoTypes for id lookup.

PricelistIdsArray of integers(int32)

Contains a list of priceList ids valid for this customer. It will be empty if no priceLists exist. It can be used to check products lists if they are from a customer specific priceList. No need to pass this into List-methods since they are considered any way in the methods. This property should be considered as ReadOnly as priceLists are maintained else where.

CrmIdstring

Used to save the Customers external id from a crm-system MaxLength: 50.

IsActiveboolean or null

Specifies if the Customer is active or not.

Createdstring or null(date-time)

When the customer was created.

Updatedstring or null(date-time)

When the customer was last updated.

Flags

CustomerFlag

Information about all available flags for Customer or Company.

Idinteger(int32)

The internal Id of the CustomerFlag.

Namestring

The name of the CustomerFlag. MaxLength: 50.

Descriptionstring

The description of the CustomerFlag. MaxLength: max.

SortOrderinteger(int32)

The sort order of the CustomerFlag.

Groupobject(IdNameDescription)(IdNameDescription)

Flag

Information about a flag set on Customer or Company. See CustomerFlags for information about available flags.

Idinteger(int32)

The internal Id of the Flag.

Namestring

The Name of the Flag. MaxLength: 50.

Groupinteger(int32)

The GroupId of the Flag.

IsSelectedboolean

Indicates if the Flag is selected or not.

InfoTypes

No entities. See IdValues

PriceLists

Pricelist

Defines a pricelist in this namespace. This is used when setting up Company specific priceLists for resellers. Insert and Update methods are provided. In order to delete a priceList just use DeleteCompanyPricelist.

Idinteger or null(int32)

The internal pricelist id. Set to null when creating a new pricelist.

ParentIdinteger or null(int32)

The parent internal pricelist id. If any.

Namestring

The name of the pricelist. MaxLength: 50.

Descriptionstring

The description of the pricelist. MaxLength: max.

Agreementstring

The agreement code of the pricelist. Can be an external id of the priceList. MaxLength: 50.

Typeinteger(int32)

The type of the pricelist. 0 is default. Other values are application specific.

IsActiveboolean

Specifies if the pricelist is active or not. Set this to false before update if you want to delete the pricelist.

PriceRuleobject(PricelistPriceRule)(PricelistPriceRule)
PopulationRulesArray of objects(PricelistPopulationRule)(PricelistPopulationRule)

A list of population rules for this pricelist.

CurrencyIdinteger(int32)

The currencyId for this pricelist.

IsExclusiveboolean

Indicates if the pricelist should be used exclusively for this Company, or not. Exclusive pricelists are not used with any standard pricelists and only exclusive pricelists will be in scope if the Company has any.

PricelistItem

Defines a pricelist item in this namespace.

PartNostring

PartNo of the SKU for this price item. MaxLength: 50.

PricelistIdinteger(int32)

The internal pricelist id.

Pricenumber(decimal)

The price. Read only. Currency is from the pricelist.

PriceRecommendednumber or null(decimal)

The price from inherited pricelist, if any.

IsActiveboolean

Specifies if the pricelist item is active or not. Ignored when inserting new pricelist items.

PriceRuleobject(PricelistPriceRule)(PricelistPriceRule)

PricelistPopulationRule

Defines a price rule for a pricelist in this namespace.

RuleIdinteger or null(int32)

An internal id for a specific rule. Set to null when creating a rule.

ManufacturerIdinteger or null(int32)

An optional internal manufacturer id. Used if the priceList is restricted to a specific manufacturer.

CategoryIdinteger or null(int32)

An optional internal category id. Used if the priceList is restricted to a specific category.

IsSupplierRequiredboolean

Specifies if the populations is from a supplier.

IsInclusiveboolean

Specifies if the population rule is inclusive or exclusive.

PricelistPriceRule

Defines a price rule for a priceList in this namespace.

RuleIdinteger or null(int32)

An internal id for a specific rule. Consult Norce for a list of valid ids and what they mean.

Valuenumber or null(decimal)

The value associated with the rule. The ruleId specifies how this value is used.