---
title: Puts the catalog entry warehouse inventory.
slug: commerce-connect-15/service-api/JZDa-puts-the-catalog-entry-warehouse-inventory
docTags: 
createdAt: 2026-10-09T17:33:31.176Z
---

{
  "id": "wfP9wEy9LFk3x-jrtodz8",
  "type": "api-oas-v2",
  "data": {
    "method": "PUT",
    "url": "http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}",
    "servers": [
      {
        "url": "http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}"
      },
      {
        "url": "https://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}"
      }
    ],
    "name": "Puts the catalog entry warehouse inventory.",
    "description": "",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "entryCode",
          "type": "string",
          "description": "The entry code."
        },
        {
          "kind": "required",
          "name": "warehouseCode",
          "type": "string",
          "description": "The warehouse code."
        }
      ],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "required",
          "name": "body",
          "type": "object",
          "description": "The warehouse inventory.",
          "customType": "EPiServer.ServiceApi.Commerce.Models.Catalog.WarehouseInventory",
          "schema": [
            {
              "name": "CatalogEntryCode",
              "kind": "optional",
              "type": "string",
              "description": "Gets the catalog entry key."
            },
            {
              "name": "WarehouseCode",
              "kind": "optional",
              "type": "string",
              "description": "Represents the unique warehouse code."
            },
            {
              "name": "WarehouseLink",
              "kind": "optional",
              "type": "object",
              "description": "Class that represents linkage and more information about models.",
              "modelRef": "#/components/schemas/EPiServer.ServiceApi.Models.ResourceLink",
              "customType": "EPiServer.ServiceApi.Models.ResourceLink",
              "schema": [
                {
                  "name": "Title",
                  "kind": "optional",
                  "type": "string",
                  "description": "Gets or sets the title."
                },
                {
                  "name": "Type",
                  "kind": "optional",
                  "type": "string",
                  "description": "Gets or sets the type."
                },
                {
                  "name": "Href",
                  "kind": "optional",
                  "type": "string",
                  "description": "Gets or sets the uri."
                },
                {
                  "name": "Properties",
                  "kind": "optional",
                  "type": "array",
                  "description": "Gets or sets the properties.",
                  "modelRef": "#/components/schemas/EPiServer.ServiceApi.Models.NameValue",
                  "customType": "EPiServer.ServiceApi.Models.NameValue[]",
                  "schema": [
                    {
                      "name": "Name",
                      "kind": "optional",
                      "type": "string",
                      "description": "Gets or sets the name."
                    },
                    {
                      "name": "Value",
                      "kind": "optional",
                      "type": "string",
                      "description": "Gets or sets the type."
                    }
                  ]
                }
              ]
            },
            {
              "name": "InStockQuantity",
              "kind": "optional",
              "type": "number<double>",
              "description": "<p>Represents the inventory's in-stock quantity.</p>",
              "format": "double"
            },
            {
              "name": "ReservedQuantity",
              "kind": "optional",
              "type": "number<double>",
              "description": "Represents the inventory's reserved quantity.",
              "format": "double"
            },
            {
              "name": "ReorderMinQuantity",
              "kind": "optional",
              "type": "number<double>",
              "description": "<p>Represents the inventory's minimum re-order quantity.</p>",
              "format": "double"
            },
            {
              "name": "PreorderQuantity",
              "kind": "optional",
              "type": "number<double>",
              "description": "<p>Represents the inventory's pre-order quantity.</p>",
              "format": "double"
            },
            {
              "name": "BackorderQuantity",
              "kind": "optional",
              "type": "number<double>",
              "description": "Represents the inventory's backorder quantity.",
              "format": "double"
            },
            {
              "name": "AllowBackorder",
              "kind": "optional",
              "type": "boolean",
              "description": "Represents whether to allow backorders."
            },
            {
              "name": "AllowPreorder",
              "kind": "optional",
              "type": "boolean",
              "description": "<p>Represents whether to allow pre-orders.</p>"
            },
            {
              "name": "InventoryStatus",
              "kind": "optional",
              "type": "string",
              "description": "Indicates whether or not current inventory amount is used in determining if an order can be completed."
            },
            {
              "name": "PreorderAvailabilityDate",
              "kind": "optional",
              "type": "string<date-time>",
              "description": "<p>Represents the availability date for the inventory's pre-orders.</p>",
              "format": "date-time"
            },
            {
              "name": "BackorderAvailabilityDate",
              "kind": "optional",
              "type": "string<date-time>",
              "description": "Represents the availability date for the inventory's backorders.",
              "format": "date-time"
            },
            {
              "name": "PurchaseAvailableDate",
              "kind": "optional",
              "type": "string<date-time>",
              "description": "Represents the availability date for the inventory's purchase.",
              "format": "date-time"
            }
          ],
          "modelRef": "#/components/schemas/EPiServer.ServiceApi.Commerce.Models.Catalog.WarehouseInventory",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": [],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "204",
        "description": "The warehouse inventory is saved.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "schema": [],
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "400",
        "description": "If the catalog entry warehouse inventory model is not valid.",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "401",
        "description": "If user does not have enough permission for this request.",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "404",
        "description": "If entry or warehouse inventory does not exist.",
        "jsonExample": "",
        "isExpanded": true
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "OtYEjiJ8dCGZhiOSolNEm",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request PUT \\\n     --url http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode} \\\n     --header 'accept: application/json'"
        },
        {
          "id": "iwaVj-Z_gnKBSHR1x4H7V",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar requestOptions = {\n   method: 'PUT',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "k039ivTDosq9z0Eh4-umn",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Put.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "8x4zO12BFJ-MdmE3tGnH-",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"http://localhost:64424/episerverapi/commerce/entries/{entryCode}/inventories/{warehouseCode}\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"PUT\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "OtYEjiJ8dCGZhiOSolNEm"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-204",
          "language": "204",
          "code": "// The warehouse inventory is saved.\n{}"
        },
        {
          "id": "response-1-400",
          "language": "400",
          "code": "// If the catalog entry warehouse inventory model is not valid.\n"
        },
        {
          "id": "response-2-401",
          "language": "401",
          "code": "// If user does not have enough permission for this request.\n"
        },
        {
          "id": "response-3-404",
          "language": "404",
          "code": "// If entry or warehouse inventory does not exist.\n"
        }
      ],
      "selectedLanguageId": "response-0-204"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}