npx claudepluginhub martinellich/aiup-marketplace --plugin aiup-coreWant just this skill?
Add to a custom plugin, then install with one command.
Creates detailed use case specification documents with actors, preconditions, main success scenarios, alternative flows, postconditions, and business rules. Use when the user asks to "write a use case", "specify a use case", "document system behavior", "define scenarios", "write a functional spec", or mentions use case specification, acceptance criteria, or user scenarios.
This skill uses the workspace's default tool permissions.
templates/use-case.mdUse Case Specification
Instructions
Create or update use case specification documents for $ARGUMENTS in docs/use_cases/. Each use case describes a complete interaction between an actor and the system to achieve a goal.
DO NOT
- Write vague or incomplete scenarios
- Skip numbering steps in the Main Success Scenario
- Omit alternative flows for error conditions
- Leave postconditions undefined
- Mix multiple use cases in one document
- Use technical implementation details in the flow steps
Template
Use templates/use-case.md as the document structure.
Example Use Case
Use Case: Create Reservation
Overview
Use Case ID: UC-001 Use Case Name: Create Reservation Primary Actor: Front Desk Clerk Goal: Create a new room reservation for a guest Status: Approved
Preconditions
- Clerk is logged into the system
- At least one room type is available for the requested dates
Main Success Scenario
- Clerk selects "New Reservation" from the menu.
- System displays the reservation form.
- Clerk enters guest information (name, email, phone).
- Clerk selects check-in and check-out dates.
- System displays available room types for the selected dates.
- Clerk selects a room type.
- System calculates the total price.
- Clerk confirms the reservation.
- System creates the reservation and displays a confirmation number.
Alternative Flows
A1: Guest Already Exists
Trigger: Guest email matches existing record (step 3) Flow:
- System displays existing guest information.
- Clerk confirms or updates guest details.
- Use case continues at step 4.
A2: No Rooms Available
Trigger: No rooms available for selected dates (step 5) Flow:
- System displays "No availability" message.
- Clerk adjusts dates or cancels operation.
- Use case continues at step 4 or ends.
A3: Payment Required
Trigger: Business rule requires deposit (step 8) Flow:
- System prompts for payment information.
- Clerk enters payment details.
- System processes payment.
- Use case continues at step 9.
Postconditions
Success Postconditions
- Reservation is stored in the system with status "Confirmed"
- Room availability is updated for the reserved dates
- Confirmation email is sent to the guest
Failure Postconditions
- No reservation is created
- Room availability remains unchanged
- System displays error message to clerk
Business Rules
BR-001: Minimum Stay
Reservations must be for at least one night.
BR-002: Advance Booking Limit
Reservations cannot be made more than 365 days in advance.
BR-003: Deposit Requirement
Reservations of 3 or more nights require a 50% deposit.
Workflow
- Read the requirements document and use case diagram
- Identify the use case to document
- Use TodoWrite to track progress
- Write the Overview section with actor and goal
- Define preconditions (what must be true before starting)
- Write the Main Success Scenario step by step
- Identify alternative flows:
- Error conditions
- Optional paths
- Exceptional situations
- Define postconditions for both success and failure
- Document applicable business rules
- Review for completeness and clarity
- Mark todo complete