stripeapi-2.0.0.1: Stripe-Library
Safe HaskellNone
LanguageHaskell2010

StripeAPI.Types.Item

Description

Contains the types generated from the schema Item

Synopsis

Documentation

data Item Source #

Defines the object schema located at components.schemas.item in the specification.

A line item.

Constructors

Item 

Fields

Instances

Instances details
Eq Item Source # 
Instance details

Defined in StripeAPI.Types.Item

Methods

(==) :: Item -> Item -> Bool #

(/=) :: Item -> Item -> Bool #

Show Item Source # 
Instance details

Defined in StripeAPI.Types.Item

Methods

showsPrec :: Int -> Item -> ShowS #

show :: Item -> String #

showList :: [Item] -> ShowS #

ToJSON Item Source # 
Instance details

Defined in StripeAPI.Types.Item

FromJSON Item Source # 
Instance details

Defined in StripeAPI.Types.Item

mkItem Source #

Create a new Item with all required fields.

data ItemPrice' Source #

Defines the object schema located at components.schemas.item.properties.price.anyOf in the specification.

The price used to generate the line item.

Constructors

ItemPrice' 

Fields

mkItemPrice' :: ItemPrice' Source #

Create a new ItemPrice' with all required fields.

data ItemPrice'BillingScheme' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.billing_scheme in the specification.

Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.

Constructors

ItemPrice'BillingScheme'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'BillingScheme'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'BillingScheme'EnumPerUnit

Represents the JSON value "per_unit"

ItemPrice'BillingScheme'EnumTiered

Represents the JSON value "tiered"

data ItemPrice'Object' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.object in the specification.

String representing the object's type. Objects of the same type share the same value.

Constructors

ItemPrice'Object'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'Object'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'Object'EnumPrice

Represents the JSON value "price"

data ItemPrice'Recurring' Source #

Defines the object schema located at components.schemas.item.properties.price.anyOf.properties.recurring.anyOf in the specification.

The recurring components of a price such as \`interval\` and \`usage_type\`.

Constructors

ItemPrice'Recurring' 

Fields

  • itemPrice'Recurring'AggregateUsage :: Maybe ItemPrice'Recurring'AggregateUsage'

    aggregate_usage: Specifies a usage aggregation strategy for prices of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.

  • itemPrice'Recurring'Interval :: Maybe ItemPrice'Recurring'Interval'

    interval: The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.

  • itemPrice'Recurring'IntervalCount :: Maybe Int

    interval_count: The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.

  • itemPrice'Recurring'UsageType :: Maybe ItemPrice'Recurring'UsageType'

    usage_type: Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.

data ItemPrice'Recurring'AggregateUsage' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.recurring.anyOf.properties.aggregate_usage in the specification.

Specifies a usage aggregation strategy for prices of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.

Constructors

ItemPrice'Recurring'AggregateUsage'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'Recurring'AggregateUsage'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'Recurring'AggregateUsage'EnumLastDuringPeriod

Represents the JSON value "last_during_period"

ItemPrice'Recurring'AggregateUsage'EnumLastEver

Represents the JSON value "last_ever"

ItemPrice'Recurring'AggregateUsage'EnumMax

Represents the JSON value "max"

ItemPrice'Recurring'AggregateUsage'EnumSum

Represents the JSON value "sum"

data ItemPrice'Recurring'Interval' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.recurring.anyOf.properties.interval in the specification.

The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.

Constructors

ItemPrice'Recurring'Interval'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'Recurring'Interval'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'Recurring'Interval'EnumDay

Represents the JSON value "day"

ItemPrice'Recurring'Interval'EnumMonth

Represents the JSON value "month"

ItemPrice'Recurring'Interval'EnumWeek

Represents the JSON value "week"

ItemPrice'Recurring'Interval'EnumYear

Represents the JSON value "year"

data ItemPrice'Recurring'UsageType' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.recurring.anyOf.properties.usage_type in the specification.

Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.

Constructors

ItemPrice'Recurring'UsageType'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'Recurring'UsageType'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'Recurring'UsageType'EnumLicensed

Represents the JSON value "licensed"

ItemPrice'Recurring'UsageType'EnumMetered

Represents the JSON value "metered"

data ItemPrice'TaxBehavior' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.tax_behavior in the specification.

Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.

Constructors

ItemPrice'TaxBehavior'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'TaxBehavior'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'TaxBehavior'EnumExclusive

Represents the JSON value "exclusive"

ItemPrice'TaxBehavior'EnumInclusive

Represents the JSON value "inclusive"

ItemPrice'TaxBehavior'EnumUnspecified

Represents the JSON value "unspecified"

data ItemPrice'TiersMode' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.tiers_mode in the specification.

Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.

Constructors

ItemPrice'TiersMode'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'TiersMode'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'TiersMode'EnumGraduated

Represents the JSON value "graduated"

ItemPrice'TiersMode'EnumVolume

Represents the JSON value "volume"

data ItemPrice'TransformQuantity' Source #

Defines the object schema located at components.schemas.item.properties.price.anyOf.properties.transform_quantity.anyOf in the specification.

Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with \`tiers\`.

Constructors

ItemPrice'TransformQuantity' 

Fields

data ItemPrice'TransformQuantity'Round' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.transform_quantity.anyOf.properties.round in the specification.

After division, either round the result `up` or `down`.

Constructors

ItemPrice'TransformQuantity'Round'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'TransformQuantity'Round'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'TransformQuantity'Round'EnumDown

Represents the JSON value "down"

ItemPrice'TransformQuantity'Round'EnumUp

Represents the JSON value "up"

data ItemPrice'Type' Source #

Defines the enum schema located at components.schemas.item.properties.price.anyOf.properties.type in the specification.

One of `one_time` or `recurring` depending on whether the price is for a one-time purchase or a recurring (subscription) purchase.

Constructors

ItemPrice'Type'Other Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

ItemPrice'Type'Typed Text

This constructor can be used to send values to the server which are not present in the specification yet.

ItemPrice'Type'EnumOneTime

Represents the JSON value "one_time"

ItemPrice'Type'EnumRecurring

Represents the JSON value "recurring"