---
sourceDocument: Asset Management
sourceDocumentLink: https://www.servicenow.com/docs/r/it-asset-management

 Release :

    - brazil

ft:locale :

    - en-US

ft:publication_title :

    - Asset Management

ft:clusterId :

    - itam

bundleId :

    - itam

workflow :

    - Technology


---

# Stock rules

# Stock rules {#ariaid-title1}

Release version: Brazil  
Updated September 10, 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 4 minutes to read
Summarize  
![AI sparkle icon](https://servicenow.com/docs/portal-asset/ai-sparkle-icon) Summarized using AI  
This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.  

## Summary of Stock rules

Stock rules in ServiceNow define criteria to automatically manage inventory replenishment when stock levels of particular assets in specific stockrooms reach predetermined thresholds.
These rules facilitate transferring stock from other stockrooms or ordering from vendors, ensuring inventory levels are maintained efficiently.
Show full answer Show less  

## Key Features

* **Restocking Options:**
  * **Email Notifications:** Sent to stockroom managers when inventory falls below thresholds, customizable by timing, recipients, and content.
  * **Automatic Task or Order Creation:** Tasks for stockroom managers, purchase orders (if Procurement plugin is active), or transfer orders are generated automatically.
* **Stock Rule Runner Job:** Runs daily to check inventory levels against stock rules and triggers corresponding tasks, orders, or notifications without creating duplicates when restocking is in progress.
* **System Properties and Flags:**
  * `glide.sc.checkout.twostep` controls automatic submission of Service Catalog requests affecting the Stock Rule Runner workflow.
  * `pendingdelivery` flag indicates whether a stock rule is awaiting fulfillment, preventing duplicate processing.
* **Integration with Plugins:** Behavior varies based on activated plugins like Procurement and Hardware Asset Management, influencing whether tasks, purchase orders, or Service Catalog requests are created.

## Stock Rule Runner Job Behavior by Rule Type

* **Stockroom:** Automatically creates transfer orders to replenish stock from other stockrooms; avoids duplicate orders if one is already in progress.
* **Vendor:** When Procurement plugin is active and hardware models are published as vendor catalog items, purchase orders with line items are created for replenishment.
* **Vendor or Service Catalog (with Hardware Asset Management):** Submits Service Catalog requests automatically for stock replenishment, adding items to the cart for stockroom manager approval, with the `pendingdelivery` flag managing request status.

## Practical Considerations for ServiceNow Customers

* Ensure hardware models are published as vendor catalog items to enable automatic purchase order creation.
* Update the `pendingdelivery` flag appropriately to avoid redundant tasks or orders.
* Check the status of the `glide.sc.checkout.twostep` system property to understand how Service Catalog requests are processed within your environment.
* If Procurement or Hardware Asset Management plugins are not activated, expect the system to create tasks prompting manual action instead of automated purchase orders or requests.

## Next Steps

To implement stock rules effectively, create and configure stock rules tailored to your inventory needs, ensuring proper plugin activation and settings alignment for automation to function smoothly.  
Stock rules are defined criteria stating that when the inventory of a particular asset
in a particular stockroom reaches a specified threshold, a certain number should either be
transferred from another stockroom or ordered from a vendor.

For example, a specific model of computer keyboard reaches an inventory of 10 in a particular
stockroom and, because a stock rule is in place, a transfer order is automatically created to
transfer 50 from a different stockroom. Because there can be multiple assets of a model within a
stockroom, stock rules enable you to check all assets fitting the criteria and view a total
count.

There are two restocking options:

* Email notifications can be sent to the stockroom manager (specified in the Manager field on the stockroom record) through the Asset Restocking email action when the inventory of a particular asset in the stockroom reaches a specified threshold. You can customize this email notification by updating the details in the following tabs:
  * When to send: Set the conditions under which the email should be triggered.
  * Who will receive: Specify the recipients of the email.
  * What it will contain: Define the content and information included in the email.
  {#c_StockRules__ul_jbw_xjm_gfc}A task is automatically created for the stockroom manager or, if Procurement is active, a purchase order and a purchase order line item are created.
* A transfer order can be generated automatically to restock the item from another stockroom.

{#c_StockRules__ul_o4g_mjt_lq}

## Stock Rule Runner job {#c_StockRules__section_x2v_xh2_d2c}

The Stock Rule Runner job runs everyday to check if the inventory in the stockroom has reached the threshold set by the stock rule. The job then triggers tasks or workflows to restock the inventory. This job creates tasks for stockroom managers and also sends email notifications to them.  
Important:  
If restocking is in progress, the system doesn't create duplicate email messages or duplicate transfer orders. It's important to act on it promptly.

By default, the glide.sc.checkout.twostep system property that's set to false, results in the automatic submission of requests when items are added to the Service Catalog cart. Also, with this setting of the system property, the Stock Rule Runner job triggers the creation of tasks, purchase orders, transfer orders, and Service Catalog requests.

If the value of the glide.sc.checkout.twostep system property is set to true, then the CartJS API adds items to the cart but the requests aren't submitted
automatically. Instead, the request submission requires additional actions to be performed, affecting the automatic flow of the Stock Rule Runner job.

The pending_delivery is used to indicate whether a stock rule is awaiting fulfillment or delivery. The pending_delivery can be set to any of the following values:

* When this flag is set to true, the stock rule is in progress, and the system doesn't generate duplicate tasks or orders for the same item.
* When this flag is set to false, the system reprocesses the stock rule and triggers the creation of tasks and orders again.

{#c_StockRules__ul_aqv_j32_d2c}  
Note:  
Make sure that the pending_delivery flag is updated to false when a stock rule has been processed, enabling the Stock Rule Runner job to run without redundancy.

Based on the Stock rule type and the plugin activated on your ServiceNow instance, the Stock Rule Runner job creates purchase orders, transfer orders, Service Catalog requests, or tasks.  
Important:  
If the Procurement plugin and the Hardware Asset Management application aren't activated, the Stock Rule Runner job creates a task instead of a purchase order or a Service Catalog request. This task prompts the stockroom manager to take the necessary actions to replenish the inventory.
{#c_StockRules__table_xsx_532_d2c__entry__2}

| Stock rule type | Orders/Requests created |
|-|-|
| Stockroom | A transfer order is created automatically when the inventory in a stockroom reaches the threshold set by the stock rule. The transfer order is created to transfer stock from another stockroom to replenish the inventory. Note: If a transfer order is already in progress, then additional transfer orders aren't created. |
| Vendor | When the Procurement plugin (com.snc.procurement) is activated, a purchase order and corresponding purchase order line items are created. Important: The automatic purchase order action works only for hardware models that are published as vendor catalog items. If a model isn't published as a vendor catalog item, the stock rule still triggers when stock falls below the minimum quantity, but it can't generate a purchase order. To publish a hardware model as a vendor catalog item, see [Publish an item to the hardware catalog](https://www.servicenow.com/docs/o6Qx7uh8J1ERI80mHGbNoQ "After you create a hardware item for the vendor catalog, publish it to the hardware catalog for viewing. The hardware catalog is a section within the service catalog."). Purchase orders and purchase order line items are created when the inventory in a stockroom reaches the defined threshold and needs replenishment directly from the vendor. Note: You must have a procurement_user role to access the purchase order and purchase order line item. |
| Vendor or Service Catalog | When the Hardware Asset Management application is installed and the stock rule is set to Vendor or Service Catalog, then note the following points: * The Stock Rule Runner job submits a Service Catalog request instead of creating a purchase order. * The Service Catalog request is automatically submitted for stock replenishment through the Service Catalog. The items are added to the Service Catalog cart for the Stockroom manager to review and approve. * The pending_delivery flag is used to track the status of the Service Catalog requests. This flag guarantees that the Service Catalog requests are processed correctly, avoiding duplicate actions. {#c_StockRules__ul_tvd_qk2_d2c} |
[Table 1. Stock Rule Runner job behavior]

{#c_StockRules__table_xsx_532_d2c}
**Related tasks**   

* [Create a stock rule](https://www.servicenow.com/docs/LYgBkag6~SgA9p2E~dqvKQ "Create a stock rule to control what happens when the inventory of a particular asset in a particular stockroom reaches a specified threshold.")

