# `Stripe.Resources.Tax.Transaction`
[🔗](https://github.com/jeffhuen/tiger_stripe/blob/main/lib/stripe/resources/tax/transaction.ex#L2)

TaxProductResourceTaxTransaction

A Tax Transaction records the tax collected from or refunded to your customer.

Related guide: [Calculate tax in your custom payment flow](https://docs.stripe.com/tax/custom#tax-transaction)

# `t`

```elixir
@type t() :: %Stripe.Resources.Tax.Transaction{
  created: integer(),
  currency: String.t(),
  customer: String.t(),
  customer_details: Stripe.Resources.Tax.Transaction.CustomerDetails.t(),
  id: String.t(),
  line_items: Stripe.Resources.Tax.Transaction.LineItems.t() | nil,
  livemode: boolean(),
  metadata: %{required(String.t()) =&gt; String.t()},
  object: String.t(),
  posted_at: integer(),
  reference: String.t(),
  reversal: Stripe.Resources.Tax.Transaction.Reversal.t(),
  ship_from_details: Stripe.Resources.Tax.Transaction.ShipFromDetails.t(),
  shipping_cost: Stripe.Resources.Tax.Transaction.ShippingCost.t(),
  tax_date: integer(),
  type: String.t()
}
```

* `created` - Time at which the object was created. Measured in seconds since the Unix epoch. Format: Unix timestamp.
* `currency` - Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Max length: 5000.
* `customer` - The ID of an existing [Customer](https://docs.stripe.com/api/customers/object) used for the resource. Max length: 5000. Nullable.
* `customer_details` - Expandable.
* `id` - Unique identifier for the transaction. Max length: 5000.
* `line_items` - The tax collected or refunded, by line item. Nullable. Expandable.
* `livemode` - Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
* `metadata` - Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Nullable.
* `object` - String representing the object's type. Objects of the same type share the same value. Possible values: `tax.transaction`.
* `posted_at` - The Unix timestamp representing when the tax liability is assumed or reduced. Format: Unix timestamp.
* `reference` - A custom unique identifier, such as 'myOrder_123'. Max length: 5000.
* `reversal` - If `type=reversal`, contains information about what was reversed. Nullable. Expandable.
* `ship_from_details` - The details of the ship from location, such as the address. Nullable. Expandable.
* `shipping_cost` - The shipping cost details for the transaction. Nullable. Expandable.
* `tax_date` - Timestamp of date at which the tax rules and rates in effect applies for the calculation. Format: Unix timestamp.
* `type` - If `reversal`, this transaction reverses an earlier transaction. Possible values: `reversal`, `transaction`.

# `expandable_fields`

# `object_name`

---

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