API
Türkçe

Guides

Managing products

Add and update your products in StockMount from your own system and manage their images. StockMount sends these products to your connected marketplaces.

Product endpoints need an active Product package. Accounts without one get 70018 on every product call.

1. Pick a product source

Every product in StockMount belongs to a product source, and product codes are unique within a source. GetProductSources lists the sources you can add and update products in through the API; use a ProductSourceId from that list in other calls. XML, marketplace and Excel sources are not listed.

Categories are free text. If you send a Category name the source does not have yet, it is created. See existing names with GetProductCategories. Currency IDs come from GetCurrencies.

2. Add a product

AddProduct requires ProductSourceId, Code, Name, Category, CurrencyId and a Price above zero. You can send variants, images and specs in the same call.

Define the variant axes on the product with VariantName1–VariantName6 and each variant's values with VariantValue1–VariantValue6. The variant Code is the key later updates match on; send a unique, non-empty code for every variant.

{
  "ApiCode": "API_CODE",
  "ProductSourceId": 1234,
  "Code": "TSHIRT-001",
  "Name": "Basic Cotton T-Shirt",
  "Category": "T-Shirts",
  "Price": 249.90,
  "CurrencyId": 4,
  "TaxRate": 20,
  "Brand": "Sample Brand",
  "VariantName1": "Color",
  "VariantName2": "Size",
  "Images": [
    { "Url": "https://cdn.example.com/tshirt-001-1.jpg" }
  ],
  "Variants": [
    { "Code": "TSHIRT-001-BLK-M", "Barcode": "8690000000024", "Quantity": 10, "Price": 249.90, "VariantValue1": "Black", "VariantValue2": "M" },
    { "Code": "TSHIRT-001-BLK-L", "Barcode": "8690000000031", "Quantity": 20, "Price": 249.90, "VariantValue1": "Black", "VariantValue2": "L" }
  ],
  "Specs": [
    { "Name": "Material", "Value": "Cotton" }
  ]
}

Result: true does not always mean a new product. If a product with the same code already exists in the source, nothing changes and the response is Result: true, ErrorCode: "70004" and the existing product's ProductId in Response. Check ErrorCode on successful responses too.

To “add, or update if it exists” in one call, send UpdateProductByCode: true. If the code exists, the product is updated under the UpdateProduct rules.

Images, variants and specs are saved after the product itself, and problems with them are not always reflected in the response. We recommend reading the product back with GetProduct after adding it.

3. Update a product

UpdateProduct is not a partial update: it rewrites the product with the values you send. Optional fields you leave out (barcode, brand, description and so on) are cleared, and panel-managed values such as sold count and SEO fields are reset. Images, Price2–Price5 and the product code do not change.

Variants are matched by Code: matches are updated, new codes are added, and existing variants missing from the list become passive.

To change a single thing, use the narrower endpoints:

4. Images

  • A product takes up to 12 images, in array order.
  • Prefer a public https address in Url. With Base64 the image is uploaded to the StockMount image server, which makes the request large and slow.
  • The image update endpoints replace the whole list: images missing from the request are removed.
  • The API does not check image formats. Some marketplaces reject .webp or non-https addresses; those errors show up in the panel when the product is sent to the marketplace.

5. Take a product off sale

Products cannot be deleted through the API; DeleteProduct was removed on 1 July 2025 and returns HTTP 410. To take a product off sale, use StopProduct or set its stock to 0. To put a stopped product back on sale, send a stock above zero with UpdateProduct.

6. Read products

  • GetProduct: one product with images, variants and specs. Variants and specs come back only when you look up by ProductId.
  • GetProducts: a filtered, paged list; at most 100 products per page.
  • GetProductSummary: ID, code, name, barcode and status of every product in a source, in one response. Useful for matching your products to StockMount ProductId values.

Marketplace checks

The product endpoints do not apply marketplace-specific rules (required brand, barcode format, VAT rate, catalogue approval, image format). Those checks run when the product is sent to a marketplace, and the results appear in the StockMount panel. The rules differ per marketplace.

Use ↑ ↓ to move, Enter to open, Esc to close.

Connect to the Out API

DoLogin is called and the returned ApiCode is kept in this tab. Your API password is never sent to this site.