# `mix phoenix_micro.gen.saga`
[🔗](https://github.com/iamkanishka/phoenix_micro/blob/v1.0.0/lib/mix/tasks/phoenix_micro.gen.saga.ex#L1)

Generates a PhoenixMicro saga module with stub steps and compensations.

## Usage

    mix phoenix_micro.gen.saga MyApp.PlaceOrderSaga reserve_inventory charge_payment

## Options

    --no-compensate   Generate steps without compensation stubs

## Example

    mix phoenix_micro.gen.saga MyApp.Checkout.PlaceOrderSaga \
      reserve_inventory \
      charge_payment \
      create_shipment \
      notify_customer

Generates `lib/my_app/checkout/place_order_saga.ex` and a matching test file.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
