# `LatticeStripe.BillingPortal.Session.FlowData`
[🔗](https://github.com/szTheory/lattice_stripe/blob/v1.1.0/lib/lattice_stripe/billing_portal/session/flow_data.ex#L1)

The `flow` sub-object echoed back on a `LatticeStripe.BillingPortal.Session`.

Polymorphic on `type`: one of `"subscription_cancel"`, `"subscription_update"`,
`"subscription_update_confirm"`, `"payment_method_update"`. Only the branch
matching `type` is populated; the others are `nil`. Unknown flow types added
by future Stripe API versions land in `:extra` unchanged — existing branches
continue to work and consumers read the new type from `flow.extra["<new>"]`
until LatticeStripe promotes it to a first-class sub-struct.

# `t`

```elixir
@type t() :: %LatticeStripe.BillingPortal.Session.FlowData{
  after_completion:
    LatticeStripe.BillingPortal.Session.FlowData.AfterCompletion.t() | nil,
  extra: map(),
  subscription_cancel:
    LatticeStripe.BillingPortal.Session.FlowData.SubscriptionCancel.t() | nil,
  subscription_update:
    LatticeStripe.BillingPortal.Session.FlowData.SubscriptionUpdate.t() | nil,
  subscription_update_confirm:
    LatticeStripe.BillingPortal.Session.FlowData.SubscriptionUpdateConfirm.t()
    | nil,
  type: String.t() | nil
}
```

# `from_map`

```elixir
@spec from_map(map() | nil) :: t() | nil
```

---

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