clear-inventory-data

Clears current-instance inventory transactions through a guarded PowerShell reset script.

Updated Jun 16, 2026
One-click install
npx skills add https://github.com/SSS08099/mom-system --skill clear-inventory-data-sss08099
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: clear-inventory-data
Source: https://github.com/SSS08099/mom-system/tree/main/.agents/skills/clear-inventory-data
Command: npx skills add https://github.com/SSS08099/mom-system --skill clear-inventory-data-sss08099

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Developers and testers working with an inventory system need a safe, controlled way to wipe inventory transaction data from the current development instance without risking unrelated services, databases, or Docker volumes. ## Core Features & Use Cases - Guarded Deletion Workflow: Runs the clear-business-data.ps1 script with the Inventory scope, which verifies the backend is stopped, the port is unused, database identity, Compose ownership, and the singleton instance row before deleting. - Explicit User Confirmation: Requires the user to type the exact confirmation text (CLEAR followed by the current instance ID) in an interactive PowerShell session, preventing accidental data loss. - Safety Constraints: Prohibits direct docker exec or psql calls, stopping unrelated services, deleting Compose volumes, or synthesizing confirmation text. - Use Case: A developer finishing a test cycle needs to reset the inv_ledger table on their local instance before a fresh test run, while keeping all other data and services intact. ## Quick Start Ask the assistant to clear the inventory transactions for the current instance and confirm the exact text when the script prompts you.

Frequently Asked Questions about clear-inventory-data

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I clear inventory transactions in my development environment?

Run the clear-business-data.ps1 script with the Inventory scope in an interactive PowerShell session after stopping the current instance backend. You must type the exact confirmation text, CLEAR followed by the current instance ID, before any deletion occurs.

How to reset inventory data without affecting other database tables?

Use the Inventory scope of the guarded reset script, which targets only inventory transactions in inv_ledger. The script verifies database identity and instance ownership before deletion, leaving other business data and Compose volumes untouched.

Can I clear inventory data while the backend is still running?

No, the script verifies that the current instance backend is stopped and its port is unused before proceeding. If the backend is running, only the PID and path-verified current instance may be stopped first.

Why does the inventory clear script refuse to delete data?

Deletion is blocked when safety checks fail, such as the backend still running, the port in use, mismatched database identity, missing Compose ownership, or an invalid singleton instance UUID. Resolve the reported condition and rerun the script.

When should I use sequence reset with inventory clearing?

Use the -ResetSequences flag only when the user separately requested a sequence reset alongside clearing inventory data. It is not applied by default and should never be added automatically.