Claude Slash Commands
This project defines four slash commands in .claude/commands/. Each command automates a repetitive development workflow so it can be triggered with a single instruction.
/new-operation {#new-operation}
File: .claude/commands/new-operation.md
Trigger: when adding a new SOAP operation to the module.
Automated workflow:
- Asks for the SOAP operation name and the corresponding Python method
- Creates the envelope template in
_xml.py(build_*+parse_*) - Adds the method in
operations.py - Adds the public method in
gateway.py - Creates the XML fixture in
tests/fixtures/ - Creates tests in
test_xml.pyandtest_operations.py - Suggests whether a new ADR is needed
/check-adr
File: .claude/commands/check-adr.md
Trigger: periodic audit or before opening a PR.
Automated workflow:
- Reads all ADRs in
docs/adr/ - Compares decisions against the current code in
src/ - Produces a report with: ✅ aligned / ⚠️ drift detected / ❌ contradiction
- For each drift, suggests whether to update the code or the ADR
/soap-fixture
File: .claude/commands/soap-fixture.md
Trigger: when an XML fixture for a t-Server response is needed.
Automated workflow:
- Asks for the SOAP operation name
- Generates a plausible XML fixture based on the response structure documented in
docs/requirements/ - Saves the file to
tests/fixtures/response_<operation>_ok.xml - Also generates a version with
returnValue != 0and one with a SOAP fault
/run-tests
File: .claude/commands/run-tests.md
Trigger: run the test suite with a coverage report.
Automated workflow:
- Runs
pytest tests/ --tb=short -q --cov=src/hanel_warehouse_gateway --cov-report=term-missing - Shows failing tests with context
- Shows coverage per module
- Warns if coverage drops below the configured threshold (80%)