openapi: 3.0.1
info:
  title: Documentation Supplier Service
  description: >-
    The Supplier sub component has Entities and Operations to create and update
    supplier products and content in Norce Commerce.
  version: '4.0'
servers:
  - url: https://connect.lab.storm.io/4.0/api
paths:
  /Product/ImportProducts:
    post:
      tags:
        - Product
      summary: Import supplier products.
      description: >-
        Use this to import whole supplier product catalogs with their prices
        (costs) and availability (onhand).<br/>Read more about the method <a
        href='/supplierintegration/#automatically-integrate-a-supplier-catalog-to-norce-storm'>here</a>.
      operationId: ImportProducts
      parameters:
        - name: X-StormConnect-Header
          in: header
          description: >-
            JSON or XML serialized string of the SupplierProductHeader
            object.<br/>Note that the enums must be of integer values when using
            application/xml encoding and can be both string or integer for
            application/json.
          required: true
          schema:
            type: string
      requestBody:
        description: List of supplier products to import.
        content:
          application/json:
            schema:
              type: array
              items:
                $ref: '#/components/schemas/SupplierProduct'
          application/xml:
            schema:
              type: array
              items:
                $ref: '#/components/schemas/SupplierProduct'
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JobResponse'
            application/xml:
              schema:
                $ref: '#/components/schemas/JobResponse'
        '400':
          description: Bad Request
          content: {}
        '500':
          description: Internal Server Error
          content: {}
      x-codegen-request-body-name: supplierProducts
components:
  schemas:
    JobResponse:
      type: object
      properties:
        StatusCode:
          type: string
          description: Status of the job
        Description:
          type: string
          description: Short message describing the job
        JobId:
          type: string
          description: >-
            Norce Commerce's interal id created for this job. Refer to this for
            future requests.
          format: int32
        ValidationSummary:
          $ref: '#/components/schemas/ValidationSummary'
      description: General response for async Connect jobs
      format: JobResponse
    ValidationSummary:
      type: object
      properties:
        NrOfItemsInTotal:
          type: integer
          description: Total number of items in payload.
          format: int32
        NrOfValidationFailures:
          type: integer
          description: Number of items that failed initial validation.
          format: int32
        Messages:
          type: array
          description: Messages concerning the validation.
          items:
            type: string
      description: Validation data for accepted payload
      format: ValidationSummary
    Image:
      required:
        - ExternalCode
        - FileTypeName
        - Url
      type: object
      properties:
        ExternalCode:
          type: string
          description: Must match code from Administration setting in Norce Commerce.
        FileTypeName:
          type: string
          description: >-
            File type. Should match file info set up in Norce Commerce, e.g.
            "MainImage", "Additional", "Embedded".
        Url:
          type: string
          description: >-
            Ulr to image that is accessible for Norce Commerce Connect for
            upload to the CDN.
          format: uri
        Filename:
          type: string
          description: Image file name. If omitted will be parsed from the url.
        LastModified:
          type: string
          description: Deprecated
          format: DateTime
      description: >-
        Represents an image that should be uploaded to Norce Commerce from the
        supplier regarding the specified article. The type and code must be set
        up in Norce Commerce Administration settings.
      format: Image
    Parametric:
      required:
        - ParametricCode
      type: object
      properties:
        ParametricCode:
          type: string
          description: >-
            Must be set to the specific code the parameter has in Norce
            Commerce. Max length: 50
        MultipleValues:
          type: array
          description: >-
            If parameter is of type multiple list this field is used and all
            other fields are ignored.
          items:
            $ref: '#/components/schemas/ParametricMultipleCodeValuePair'
        ValueBoolean:
          type: boolean
          description: >-
            If parameter is of type boolean this field is used and all other
            fields are ignored.
        ValueCode:
          type: string
          description: >-
            If parameter is of type list this field is used and all other fields
            are ignored. Max length: 255
        ValueDateTime:
          type: string
          description: >-
            If parameter is of type datetime this field is used and all other
            fields are ignored.
          format: DateTime
        ValueDecimal:
          type: number
          description: >-
            If parameter is of type decimal this field is used and all other
            fields are ignored.
        ValueInt:
          type: integer
          description: >-
            If parameter is of type integer this field is used and all other
            fields are ignored.
          format: int32
        ValueText:
          type: string
          description: >-
            This value field is preferred for supplier integrations. If
            parameter is of type text value this field is used and all other
            fields are ignored. Max length: 255
      description: Represents a content attribute on an article.
      format: Parametric
    ParametricMultipleCodeValuePair:
      required:
        - Code
        - Value
      type: object
      properties:
        Code:
          type: string
          description: >-
            Parametric selection value code. Used for matching in Norce
            Commerce. Max length: 255
        Value:
          type: string
          description: 'Value for selection. Max length: 255'
      description: Represent a value item in an multuple value list.
      format: ParametricMultipleCodeValuePair
    ProductCulture:
      required:
        - CultureCode
      type: object
      properties:
        CultureCode:
          type: string
          description: ISO language codes, e.g. "sv-SE".
        Description:
          type: string
          description: Article description.
        DescriptionHeader:
          type: string
          description: 'Article description header. Max length: 255'
        IsUniqueUrlNameManuallyMaintained:
          type: boolean
          description: Determines if UniqueUrlName is manually maintained.
        MetaDescription:
          type: string
          description: Aricle meta descriptions.
        MetaTags:
          type: string
          description: Article meta tags.
        Name:
          type: string
          description: 'Article name. Max length: 255'
        SubDescription:
          type: string
          description: Article additional description.
        SubHeader:
          type: string
          description: 'Article additional header. Max length: 255'
        Synonyms:
          type: string
          description: 'List of words used in search. Max length: 500'
        Tags:
          type: string
          description: Article tags.
        Title:
          type: string
          description: 'Article title. Max length: 255'
        UniqueUrlName:
          type: string
          description: >-
            Used for bread crumbs, if provided and enabled in Admin GUI, it will
            override Norce Commerce automation tool.
      description: Represents article text information in different languages.
      format: ProductCulture
    SupplierOnHand:
      required:
        - LocationCode
        - Value
        - WarehouseCode
      type: object
      properties:
        LocationCode:
          type: string
          description: >-
            Name of location, must match supplier location name configured in
            Norce Commerce. Max length: 50
        WarehouseCode:
          type: string
          description: >-
            Name of Warehouse, must match supplier warehouse name configured in
            Norce Commerce. Max length: 50
        ExternalStockValue:
          type: number
          description: Stock value for external display.
        IncomingValue:
          type: number
          description: Quantity of items currently inbound to warehouse.
        IsActive:
          type: boolean
          description: Sets on hand information to active or inactive. Defaults to true.
        IsReturnable:
          type: boolean
          description: Determines if article is returnable.
        LeadTimeDayCount:
          type: integer
          description: Indication of time for delivery from warehouse to client.
          format: int32
        MinimumOrderValue:
          type: number
          description: Minimum quantity of items on a purchase order, default is 1.
        Name:
          type: string
          description: 'Storage site name, for presentation only. Max length: 255'
        NextDeliveryDate:
          type: string
          description: Expected next delivery date for incoming stock.
          format: DateTime
        PackageValue:
          type: number
          description: Quantity of items in a package, default is 1.
        StoppedDate:
          type: string
          description: Date when on hand information was deactivated.
          format: DateTime
        Value:
          type: number
          description: Onhand value
      description: Represents stock value information on an article.
      format: SupplierOnHand
    SupplierPrice:
      required:
        - PriceListCode
      type: object
      properties:
        PriceListCode:
          type: string
          description: >-
            Must match code from the supplier price list in Norce Commerce. Max
            length: 50
        CostFee:
          type: number
          description: Cost fee
        CostPurchase:
          type: number
          description: Supplier sale price
        CostPurchaseValidTo:
          type: string
          description: Valid to date for price information.
          format: DateTime
        CurrencyCode:
          type: string
          description: >-
            Currency Code, in ISO 4217 format. For example "SEK", "EUR", "USD",
            default is currency on configured sales area in Norce Commerce. Max
            length: 3
        DiscountPct:
          type: number
          description: Discount
        FreightCost:
          type: number
          description: Freight cost.
        IsActive:
          type: boolean
          description: Sets price to active or inactive. Defaults to true.
        IsFocus:
          type: boolean
          description: Is focus.
        IsPromotion:
          type: boolean
          description: True if price information is based on temporary campaign.
        PriceCatalog:
          type: number
          description: Catalog price.
        PriceDealer:
          type: number
          description: Dealer price.
        PriceMax:
          type: number
          description: Max price for end customer.
        PriceRanking:
          type: integer
          description: Price ranking.
          format: int32
        PriceRecommended:
          type: number
          description: Recommended price for end customer.
        QtyBreak:
          type: integer
          description: >-
            Quantity of items required for price, default is 1. This is used for
            discounts for large orders.
          format: int32
      description: Represents supplier price information on article.
      format: SupplierPrice
    SupplierProduct:
      required:
        - SupplierPartNo
      type: object
      properties:
        SupplierPartNo:
          type: string
          description: 'Supplier article number. Max length: 50'
        CategoryCode:
          type: string
          description: >-
            Name or code of the category, ideally this something readable, like
            "Utensils" or with a hierachy "Kitchen|Utensils". Max length: 255
        CommodityCode:
          type: string
          description: >-
            A classification of goods for import and export between countries.
            Max length: 50
        ContentList:
          type: array
          description: List of culture specific texts on article.
          items:
            $ref: '#/components/schemas/ProductCulture'
        EanCode:
          type: string
          description: 'Bar code. Max length: 50'
        GrossWeight:
          type: number
          description: Actual weight including package etc.
        Images:
          type: array
          description: >-
            Additional images, use high definition. Norce Commerce will provide
            real-time resizing when used in Norce Commerce Services and Norce
            Administration GUI.
          items:
            $ref: '#/components/schemas/Image'
        LogisticDepth:
          type: number
          description: Logistic depth.
        LogisticHeight:
          type: number
          description: Logistic height
        LogisticWidth:
          type: number
          description: Logistic width
        MainImage:
          $ref: '#/components/schemas/Image'
        Manufacturer:
          type: string
          description: >-
            Manufacturer code or name, required together with ManufacturerPartNo
            to be unique. Max length: 50
        ManufacturerPartNo:
          type: string
          description: >-
            Manufacturer article number, required together with Manufacturer to
            be unique. Max length: 50
        NetWeight:
          type: number
          description: Obsolete. Weight of item, without packaging.
        OnHand:
          type: array
          description: Stock values, at least one is required.
          items:
            $ref: '#/components/schemas/SupplierOnHand'
        Parametrics:
          type: array
          description: List of supplier specific content attributes, like color or size.
          items:
            $ref: '#/components/schemas/Parametric'
        PriceList:
          type: array
          description: Purchase cost and other price information. At least one is required.
          items:
            $ref: '#/components/schemas/SupplierPrice'
        ProductInfo:
          type: array
          description: >-
            List of supplier specific setting attributes. This is article
            specific information needed for supplier integrations, but will not
            be shown as content. For example "OnlySoldInSweden".
          items:
            $ref: '#/components/schemas/SupplierProductInfo'
        ProductName:
          type: string
          description: 'Name of the article in default language. Max length: 500'
        ProductType:
          type: string
          description: Product type.
        UnitOfMeasurementCode:
          type: integer
          description: >-
            Unit of measurement code for item: 0 = Unknown, 1 = Pieces, 2 =
            Hours, 3 = Kilograms, 4 = Litres. Default is pieces.
          format: int32
        UnitOfMeasurementCount:
          type: integer
          description: Number of units in the package.
          format: int32
        VatCode:
          type: integer
          description: Vat rate in percent
          format: int32
      description: >-
        Represents an article from a Supplier. Product content import (e.g.
        contentlist, images, parametrics) via Supplier will soon be deprecated.
      format: SupplierProduct
    SupplierProductHeader:
      required:
        - AccountId
        - FieldsThatAreSet
        - FullFile
        - SupplierId
      type: object
      properties:
        AccountId:
          type: integer
          description: >-
            Account which initiated the import. Learn about system accounts <a
            href='/connectintegration/#using-system-accounts'>here</a>.
          format: int32
        FieldsThatAreSet:
          type: array
          description: >-
            Specifies which product fields to be updated.<br/>(Use the integer
            instead of the name for the xml content type)<br/><br/>0 =
            SupplierPartNo<br>1 = ProductName<br>2 = CategoryCode<br>3 =
            ProductType<br>4 = Manufacturer<br>5 = ManufacturerPartNo<br>6 =
            EanCode<br>7 = CommodityCode<br>8 = GrossWeight<br>9 =
            NetWeight<br>10 = UnitOfMeasurementCode<br>11 =
            UnitOfMeasurementCount<br>12 = VatCode<br>13 = LogisticWidth<br>14 =
            LogisticHeight<br>15 = LogisticDepth
          items:
            type: string
            enum:
              - SupplierPartNo
              - ProductName
              - CategoryCode
              - ProductType
              - Manufacturer
              - ManufacturerPartNo
              - EanCode
              - CommodityCode
              - GrossWeight
              - NetWeight
              - UnitOfMeasurementCode
              - UnitOfMeasurementCount
              - VatCode
              - LogisticWidth
              - LogisticHeight
              - LogisticDepth
        FullFile:
          type: boolean
          description: >-
            Flag that specified how Norce Commerce Connect will handle the
            import. If true, all articles not in this feed will be handled as
            deleted and are deactivated in Norce. If false, the import will be
            handled as an update only on the articles in the feed, other
            articles will not be changed.
        ContentFieldsThatAreSet:
          type: array
          description: >-
            Specifies which product culture fields to be updated.<br/>(Use the
            integer instead of the name for the xml content type)<br/><br/>0 =
            Name<br>1 = NameCreateOnly (Value is only set if the entity is
            created by the import)<br>2 = SubHeader<br>3 = SubDescription<br>4 =
            DescriptionHeader<br>5 = Description<br>6 = DescriptionCreateOnly
            (Value is only set if the entity is created by the import)<br>7 =
            Synonyms<br>8 = Title<br>9 = Tags<br>10 = MetaTags<br>11 =
            MetaDescription<br>12 = NameLimitedUpdate  (If name is manually
            changed in the Admin UI, import is ignored)<br>13 =
            UniqueUrlName<br>14 = IsUniqueUrlNameManuallyMaintained<br>15 =
            UniqueUrlNameCreateOnly (Value is only set if the entity is created
            by the import)
          items:
            type: string
            enum:
              - Name
              - NameCreateOnly
              - SubHeader
              - SubDescription
              - DescriptionHeader
              - Description
              - DescriptionCreateOnly
              - Synonyms
              - Title
              - Tags
              - MetaTags
              - MetaDescription
              - NameLimitedUpdate
              - UniqueUrlName
              - IsUniqueUrlNameManuallyMaintained
              - UniqueUrlNameCreateOnly
        JobId:
          type: string
          description: >-
            Norce Commerce Connect job id. Only exists in import logs. Should be
            omitted in the import request.
        OnhandFieldsThatAreSet:
          type: array
          description: >-
            Specifies which on hand fields to be updated.<br/>(Use the integer
            instead of the name for the xml content type)<br/><br/>0 =
            Value<br>1 = IncomingValue<br>2 = NextDeliveryDate<br>3 =
            StoppedDate<br>4 = IsReturnable<br>5 = LeadTimeDayCount<br>6 =
            ExternalStockValue<br>7 = PackageValue<br>8 = MinimumOrderValue<br>9
            = IsActive
          items:
            type: string
            enum:
              - Value
              - IncomingValue
              - NextDeliveryDate
              - StoppedDate
              - IsReturnable
              - LeadTimeDayCount
              - ExternalStockValue
              - PackageValue
              - MinimumOrderValue
              - IsActive
        PriceFieldsThatAreSet:
          type: array
          description: >-
            Specifies which price fields to be updated.<br/>(Use the integer
            instead of the name for the xml content type)<br/><br/>0 =
            CostPurchase<br>1 = CostPurchaseValidTo<br>2 = PriceRecommended<br>3
            = PriceMax<br>4 = PriceDealer<br>5 = IsPromotion<br>6 = IsFocus<br>7
            = PriceRanking<br>8 = FreightCost<br>9 = CostFee<br>10 =
            DiscountPct<br>11 = IsActive<br>12 = PriceCatalog
          items:
            type: string
            enum:
              - CostPurchase
              - CostPurchaseValidTo
              - PriceRecommended
              - PriceMax
              - PriceDealer
              - IsPromotion
              - IsFocus
              - PriceRanking
              - FreightCost
              - CostFee
              - DiscountPct
              - IsActive
              - PriceCatalog
        ProductInfoFieldsThatAreSet:
          type: array
          description: >-
            Specifies which product info fields to be updated.<br/>(Use the
            integer instead of the name for the xml content type)<br/><br/>0 =
            Value
          items:
            type: string
            enum:
              - Value
        SerializationType:
          type: array
          description: >-
            Request serialization type.(Use the integer instead of the name for
            the xml content type)<br/><br/>0 = JSON, 1 = XML
          items:
            type: string
            enum:
              - JSON
              - XML
        StorageName:
          type: string
          description: >-
            Location of the import file on Norce's file area. Can be used
            instead of sending data directly in payload.
          format: uri
        SupplierId:
          type: integer
          description: Norce Commerce's internal Supplier identifier.
          format: int32
      description: ''
      format: SupplierProductHeader
    SupplierProductInfo:
      required:
        - Code
        - Value
      type: object
      properties:
        Code:
          type: string
          description: 'Information field code. Max length: 50'
        Value:
          type: string
          description: 'Value to set. Max length: 255'
      description: Additional product information defined by 3rd party
      format: SupplierProductInfo
x-original-swagger-version: '2.0'
