Skip to content

Documentation ShoppingService (1.1)

Entities and methods to handle baskets and payments.

Download OpenAPI description
Languages
Servers

https://demo.storm.io/api/1.1/

Operations

Request

Removes all items from the basket.

Query
idinteger(int32)required

The internal id of the basket to clear.

pricelistSeedstring

A comma separated list of internal pricelist ids to use, if any. PriceLists supplied must be valid, either from the application's public priceList or any customer or company priceLists or any valid client priceLists. For clients configured to use priceListSeed exclusively in the API only the supplied priceLists will be used. If this is not configured, the supplied priceLists will be appended to the valid priceLists. If none is supplied, the default value for the application will be used in combination with any customer or company priceLists. This applies to both configurations.

cultureCodestring

Specifies in which language to display culture specific information. If none is supplied, value is resolved from Application.

currencyIdstring

Specifies in which currency internal id to display prices. If none is supplied, value is resolved from Application.

curl -i -X POST \
  'https://demo.storm.io/api/1.1/ShoppingService.svc/rest/ClearBasket?id=0'

Responses

Success

Body
Idinteger or null(int32)

The internal id of the basket. Used to get a specific basket. Ignored in CreateBasket.

CustomerIdinteger or null(int32)

The customer internal id for a specific customer associated with this basket. This can be set in CreateBasket if the user is logged in. Otherwise use UpdateBuyer to set customer.

CompanyIdinteger or null(int32)

The company internal id for a specific company associated with this basket. This can be set in CreateBasket if the user is logged in with a company. Otherwise use UpdateBuyer to set customer and company.

SalesContactIdinteger or null(int32)
StatusIdinteger(int32)

Internal id for the current status of the basket. See ListBasketStatuses.

CurrencyIdinteger(int32)

The currency internal id of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used.

CurrencyCodestring

The CurrencyCode of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used. MaxLength: 3.

Commentstring

Free text comment that will be propagated to the order. MaxLength: 250.

OrderReferencestring

An OrderReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

DiscountCodestring

A comma separated list of used discount codes. To clear the value set it to null or String.Empty an call UpdateBasket. MaxLength: max.

ReferIdinteger or null(int32)
ReferUrlstring

MaxLength: 255.

ValidTostring or null(date-time)
IsEditableboolean

Specifies if the basket is editable. If not, any method that changes the basket will throw Exceptions (Bad Request). It will be false when the basket is no longer a basket. That is when it's paid for or cancelled.

ItemsArray of objects(BasketItem)(BasketItem)

List of the items in the basket.

InfoArray of objects(ExtraInfo)(ExtraInfo)

List of information types with values that may be propagated on the order.

Summaryobject(Summary)(Summary)
AppliedPromotionsArray of objects(Promotion)(Promotion)

Contains all Promotions valid for a Basket, whether or not they are applied. If any promotions are applied more info about them are added to the corresponding Basket.Items.

IpAddressstring

The user's IpAddress when the basket was created. The value should be fetched from the user request to the application. MaxLength: 50.

AttestedByinteger or null(int32)
TypeIdinteger(int32)

The internal type id of the Basket. Can be 1 = Basket, 2 = Saved Basket, 3 = Template Basket for Subscriptions.

DoHoldboolean

DoHold specifies if the resulting order should be on hold until all items on the order can be shipped or not. Default is false. This can be set in the Checkout with UpdateBasket if the Customer does not want part deliveries.

IsBuyableboolean

IsBuyable is a rule based property indicating if the Basket's status allows the basket to be purchased. It should be regarded as readonly.

InvoiceReferencestring

An InvoiceReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

PaymentMethodIdinteger or null(int32)

The PaymentMethodId from Storm. Can be set in CreateBasket or updated in UpdatePaymentMethod.

DeliveryMethodIdinteger or null(int32)

The DeliveryMethodId from Storm. Can be set in CreateBasket or updated in UpdateDeliveryMethod.

SalesAreaIdinteger(int32)

The SalesArea internal id of the basket. This defines the default VAT-rate used. Can be set when creating a Basket or change later with UpdateBasket. If not specified, the default for the Application will be used.

Response
{ "Id": 0, "CustomerId": 0, "CompanyId": 0, "SalesContactId": 0, "StatusId": 0, "CurrencyId": 0, "CurrencyCode": "string", "Comment": "string", "OrderReference": "string", "DiscountCode": "string", "ReferId": 0, "ReferUrl": "string", "ValidTo": "2019-08-24T14:15:22Z", "IsEditable": true, "Items": [ {} ], "Info": [ {} ], "Summary": { "Items": {}, "Freigt": {}, "Fees": {}, "Total": {} }, "AppliedPromotions": [ {} ], "IpAddress": "string", "AttestedBy": 0, "TypeId": 0, "DoHold": true, "IsBuyable": true, "InvoiceReference": "string", "PaymentMethodId": 0, "DeliveryMethodId": 0, "SalesAreaId": 0 }

Request

Closes the basket for post purchase.

Query
basketIdinteger(int32)required

The internal id of the basket to close.

curl -i -X POST \
  'https://demo.storm.io/api/1.1/ShoppingService.svc/rest/CloseBasketForPostPurchaseUpsell?basketId=0'

Responses

Success

Body

Request

Creates a new Basket.

Query
ipAddressstringrequired

The ip-address of the end user.

createdByinteger(int32)required

Account internal id of current user.

pricelistSeedstring

A comma separated list of internal pricelist ids to use, if any. PriceLists supplied must be valid, either from the application's public priceList or any customer or company priceLists or any valid client priceLists. For clients configured to use priceListSeed exclusively in the API only the supplied priceLists will be used. If this is not configured, the supplied priceLists will be appended to the valid priceLists. If none is supplied, the default value for the application will be used in combination with any customer or company priceLists. This applies to both configurations.

cultureCodestring

Specifies in which language to display culture specific information. If none is supplied, value is resolved from Application.

currencyIdstring

Specifies in which internal currency id to display prices. If none is supplied, value is resolved from Application. Note that if price is specified on items, then it must be in the same currency.

Bodyrequired

The Basket to create. Pass in null or an empty Basket to create a new empty Basket. See Basket for what properties can be used when creating baskets.

Idinteger or null(int32)

The internal id of the basket. Used to get a specific basket. Ignored in CreateBasket.

CustomerIdinteger or null(int32)

The customer internal id for a specific customer associated with this basket. This can be set in CreateBasket if the user is logged in. Otherwise use UpdateBuyer to set customer.

CompanyIdinteger or null(int32)

The company internal id for a specific company associated with this basket. This can be set in CreateBasket if the user is logged in with a company. Otherwise use UpdateBuyer to set customer and company.

SalesContactIdinteger or null(int32)
StatusIdinteger(int32)

Internal id for the current status of the basket. See ListBasketStatuses.

CurrencyIdinteger(int32)

The currency internal id of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used.

CurrencyCodestring

The CurrencyCode of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used. MaxLength: 3.

Commentstring

Free text comment that will be propagated to the order. MaxLength: 250.

OrderReferencestring

An OrderReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

DiscountCodestring

A comma separated list of used discount codes. To clear the value set it to null or String.Empty an call UpdateBasket. MaxLength: max.

ReferIdinteger or null(int32)
ReferUrlstring

MaxLength: 255.

ValidTostring or null(date-time)
IsEditableboolean

Specifies if the basket is editable. If not, any method that changes the basket will throw Exceptions (Bad Request). It will be false when the basket is no longer a basket. That is when it's paid for or cancelled.

ItemsArray of objects(BasketItem)(BasketItem)

List of the items in the basket.

InfoArray of objects(ExtraInfo)(ExtraInfo)

List of information types with values that may be propagated on the order.

Summaryobject(Summary)(Summary)
AppliedPromotionsArray of objects(Promotion)(Promotion)

Contains all Promotions valid for a Basket, whether or not they are applied. If any promotions are applied more info about them are added to the corresponding Basket.Items.

IpAddressstring

The user's IpAddress when the basket was created. The value should be fetched from the user request to the application. MaxLength: 50.

AttestedByinteger or null(int32)
TypeIdinteger(int32)

The internal type id of the Basket. Can be 1 = Basket, 2 = Saved Basket, 3 = Template Basket for Subscriptions.

DoHoldboolean

DoHold specifies if the resulting order should be on hold until all items on the order can be shipped or not. Default is false. This can be set in the Checkout with UpdateBasket if the Customer does not want part deliveries.

IsBuyableboolean

IsBuyable is a rule based property indicating if the Basket's status allows the basket to be purchased. It should be regarded as readonly.

InvoiceReferencestring

An InvoiceReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

PaymentMethodIdinteger or null(int32)

The PaymentMethodId from Storm. Can be set in CreateBasket or updated in UpdatePaymentMethod.

DeliveryMethodIdinteger or null(int32)

The DeliveryMethodId from Storm. Can be set in CreateBasket or updated in UpdateDeliveryMethod.

SalesAreaIdinteger(int32)

The SalesArea internal id of the basket. This defines the default VAT-rate used. Can be set when creating a Basket or change later with UpdateBasket. If not specified, the default for the Application will be used.

curl -i -X POST \
  'https://demo.storm.io/api/1.1/ShoppingService.svc/rest/CreateBasket?ipAddress=string&createdBy=0' \
  -H 'Content-Type: application/json' \
  -d '{
    "Id": 0,
    "CustomerId": 0,
    "CompanyId": 0,
    "SalesContactId": 0,
    "StatusId": 0,
    "CurrencyId": 0,
    "CurrencyCode": "string",
    "Comment": "string",
    "OrderReference": "string",
    "DiscountCode": "string",
    "ReferId": 0,
    "ReferUrl": "string",
    "ValidTo": "2019-08-24T14:15:22Z",
    "IsEditable": true,
    "Items": [
      {
        "Id": 0,
        "LineNo": 0,
        "ParentLineNo": 0,
        "ProductId": 0,
        "PartNo": "string",
        "ManufacturerPartNo": "string",
        "Name": "string",
        "SubHeader": "string",
        "ThumbnailImage": "string",
        "FlagIdSeed": "string",
        "Type": 0,
        "PriceDisplay": 0,
        "Price": 0,
        "PriceOriginal": 0,
        "Cost": 0,
        "VatRate": 0,
        "Quantity": 0,
        "UOM": "string",
        "UOMCount": 0,
        "Comment": "string",
        "PriceListId": 0,
        "ReferId": 0,
        "ReferUrl": "string",
        "IsEditable": true,
        "IsDiscountable": true,
        "Info": [
          {
            "TypeId": 0,
            "Value": "string",
            "Code": "string"
          }
        ],
        "OptionalItems": [
          {}
        ],
        "OnHandValue": 0,
        "IncomingValue": 0,
        "NextDeliveryDate": "2019-08-24T14:15:22Z",
        "LeadtimeDayCount": 0,
        "PromotionIdSeed": "string",
        "ImageKey": "string",
        "ManufacturerName": "string",
        "CategoryId": 0,
        "OnHand": {
          "Value": 0,
          "IncomingValue": 0,
          "NextDeliveryDate": "2019-08-24T14:15:22Z",
          "LeadtimeDayCount": 0,
          "LastChecked": "2019-08-24T14:15:22Z",
          "IsActive": true,
          "IsReturnable": true,
          "Info": [
            {
              "Id": 0,
              "Value": "string",
              "Code": "string"
            }
          ]
        },
        "OnHandSupplier": {
          "Value": 0,
          "IncomingValue": 0,
          "NextDeliveryDate": "2019-08-24T14:15:22Z",
          "LeadtimeDayCount": 0,
          "LastChecked": "2019-08-24T14:15:22Z",
          "IsActive": true,
          "IsReturnable": true,
          "Info": [
            {
              "Id": 0,
              "Value": "string",
              "Code": "string"
            }
          ]
        },
        "PriceRecommended": 0,
        "ManufacturerId": 0,
        "UniqueName": "string",
        "StatusId": 0,
        "StockDisplayBreakPoint": 0,
        "PriceCatalog": 0,
        "IsBuyable": true,
        "SubDescription": "string",
        "CategoryIdSeed": "string",
        "RecommendedQuantity": 0,
        "IsRecommendedQuantityFixed": true,
        "AppliedPromotions": [
          {
            "Id": 0,
            "Name": "string",
            "DiscountCode": "string",
            "AppliedAmount": 0,
            "AppliedAmountIncVat": 0
          }
        ],
        "RequirementPromotionIdSeed": "string",
        "IsSubscribable": true,
        "DescriptionHeader": "string",
        "IsPriceManual": true,
        "PriceStandard": 0,
        "EanCode": "string",
        "CostUnit": 0,
        "PriceDisplayIncVat": 0,
        "PriceListLocked": true,
        "PriceOriginalIncVat": 0,
        "PriceRecommendedIncVat": 0,
        "PriceCatalogIncVat": 0,
        "PriceStandardIncVat": 0
      }
    ],
    "Info": [
      {
        "TypeId": 0,
        "Value": "string",
        "Code": "string"
      }
    ],
    "Summary": {
      "Items": {
        "Amount": 0,
        "Vat": 0,
        "AmountIncVat": 0
      },
      "Freigt": {
        "Amount": 0,
        "Vat": 0,
        "AmountIncVat": 0
      },
      "Fees": {
        "Amount": 0,
        "Vat": 0,
        "AmountIncVat": 0
      },
      "Total": {
        "Amount": 0,
        "Vat": 0,
        "AmountIncVat": 0
      }
    },
    "AppliedPromotions": [
      {
        "Id": 0,
        "Name": "string",
        "Header": "string",
        "ShortDescription": "string",
        "Description1": "string",
        "Description2": "string",
        "StartDate": "2019-08-24T14:15:22Z",
        "EndDate": "2019-08-24T14:15:22Z",
        "ImageKey": "string",
        "RequirementSeed": "string",
        "DiscountCode": "string",
        "IsExcludedFromPriceCalculation": true,
        "AllowProductListing": true,
        "Images": [
          {
            "Id": 0,
            "Type": 0,
            "Name": "string",
            "Description": "string",
            "Key": "string"
          }
        ],
        "ProductFilters": [
          {
            "ManufacturerId": 0,
            "CategorySeed": "string",
            "TypeId": 0,
            "ProductId": 0,
            "VariantProductId": 0,
            "PartNo": "string",
            "PricelistId": 0,
            "FlagId": 0
          }
        ],
        "AppliedAmount": 0,
        "EffectSeed": "string",
        "FreightDiscountPct": 0,
        "IsStackable": true,
        "AppliedAmountIncVat": 0,
        "ExclusivityType": 0
      }
    ],
    "IpAddress": "string",
    "AttestedBy": 0,
    "TypeId": 0,
    "DoHold": true,
    "IsBuyable": true,
    "InvoiceReference": "string",
    "PaymentMethodId": 0,
    "DeliveryMethodId": 0,
    "SalesAreaId": 0
  }'

Responses

Success

Body
Idinteger or null(int32)

The internal id of the basket. Used to get a specific basket. Ignored in CreateBasket.

CustomerIdinteger or null(int32)

The customer internal id for a specific customer associated with this basket. This can be set in CreateBasket if the user is logged in. Otherwise use UpdateBuyer to set customer.

CompanyIdinteger or null(int32)

The company internal id for a specific company associated with this basket. This can be set in CreateBasket if the user is logged in with a company. Otherwise use UpdateBuyer to set customer and company.

SalesContactIdinteger or null(int32)
StatusIdinteger(int32)

Internal id for the current status of the basket. See ListBasketStatuses.

CurrencyIdinteger(int32)

The currency internal id of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used.

CurrencyCodestring

The CurrencyCode of the basket. This defines the currency used when processing payments. Can be set when creating a Basket or change later with UpdateBasket. Use either CurrencyId or CurrencyCode. If not specified, the default for the Application will be used. MaxLength: 3.

Commentstring

Free text comment that will be propagated to the order. MaxLength: 250.

OrderReferencestring

An OrderReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

DiscountCodestring

A comma separated list of used discount codes. To clear the value set it to null or String.Empty an call UpdateBasket. MaxLength: max.

ReferIdinteger or null(int32)
ReferUrlstring

MaxLength: 255.

ValidTostring or null(date-time)
IsEditableboolean

Specifies if the basket is editable. If not, any method that changes the basket will throw Exceptions (Bad Request). It will be false when the basket is no longer a basket. That is when it's paid for or cancelled.

ItemsArray of objects(BasketItem)(BasketItem)

List of the items in the basket.

InfoArray of objects(ExtraInfo)(ExtraInfo)

List of information types with values that may be propagated on the order.

Summaryobject(Summary)(Summary)
AppliedPromotionsArray of objects(Promotion)(Promotion)

Contains all Promotions valid for a Basket, whether or not they are applied. If any promotions are applied more info about them are added to the corresponding Basket.Items.

IpAddressstring

The user's IpAddress when the basket was created. The value should be fetched from the user request to the application. MaxLength: 50.

AttestedByinteger or null(int32)
TypeIdinteger(int32)

The internal type id of the Basket. Can be 1 = Basket, 2 = Saved Basket, 3 = Template Basket for Subscriptions.

DoHoldboolean

DoHold specifies if the resulting order should be on hold until all items on the order can be shipped or not. Default is false. This can be set in the Checkout with UpdateBasket if the Customer does not want part deliveries.

IsBuyableboolean

IsBuyable is a rule based property indicating if the Basket's status allows the basket to be purchased. It should be regarded as readonly.

InvoiceReferencestring

An InvoiceReference which will be tagged on the order. Can be set in CreateBasket or updated in UpdateBasket. MaxLength: 50.

PaymentMethodIdinteger or null(int32)

The PaymentMethodId from Storm. Can be set in CreateBasket or updated in UpdatePaymentMethod.

DeliveryMethodIdinteger or null(int32)

The DeliveryMethodId from Storm. Can be set in CreateBasket or updated in UpdateDeliveryMethod.

SalesAreaIdinteger(int32)

The SalesArea internal id of the basket. This defines the default VAT-rate used. Can be set when creating a Basket or change later with UpdateBasket. If not specified, the default for the Application will be used.

Response
{ "Id": 0, "CustomerId": 0, "CompanyId": 0, "SalesContactId": 0, "StatusId": 0, "CurrencyId": 0, "CurrencyCode": "string", "Comment": "string", "OrderReference": "string", "DiscountCode": "string", "ReferId": 0, "ReferUrl": "string", "ValidTo": "2019-08-24T14:15:22Z", "IsEditable": true, "Items": [ {} ], "Info": [ {} ], "Summary": { "Items": {}, "Freigt": {}, "Fees": {}, "Total": {} }, "AppliedPromotions": [ {} ], "IpAddress": "string", "AttestedBy": 0, "TypeId": 0, "DoHold": true, "IsBuyable": true, "InvoiceReference": "string", "PaymentMethodId": 0, "DeliveryMethodId": 0, "SalesAreaId": 0 }
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations