View Source Stripe.TaxRate (Striped v0.5.0) (generated)
Tax rates can be applied to invoices, subscriptions and Checkout Sessions to collect tax.
Related guide: Tax Rates.
Link to this section Summary
Functions
Creates a new tax rate.
Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
Retrieves a tax rate with the given I.
Updates an existing tax rate.
Link to this section Types
@type t() :: %Stripe.TaxRate{ active: boolean(), country: binary() | nil, created: integer(), description: binary() | nil, display_name: binary(), id: binary(), inclusive: boolean(), jurisdiction: binary() | nil, livemode: boolean(), metadata: term() | nil, object: binary(), percentage: term(), state: binary() | nil, tax_type: binary() | nil }
The tax_rate type.
activeDefaults totrue. When set tofalse, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.countryTwo-letter country code (ISO 3166-1 alpha-2).createdTime at which the object was created. Measured in seconds since the Unix epoch.descriptionAn arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.display_nameThe display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.idUnique identifier for the object.inclusiveThis specifies if the tax rate is inclusive or exclusive.jurisdictionThe jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.livemodeHas the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.metadataSet of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.objectString representing the object's type. Objects of the same type share the same value.percentageThis represents the tax rate percent out of 100.stateISO 3166-2 subdivision code, without country prefix. For example, "NY" for New York, United States.tax_typeThe high-level tax type, such asvatorsales_tax.
Link to this section Functions
@spec create( client :: Stripe.t(), params :: %{ optional(:active) => boolean(), optional(:country) => binary(), optional(:description) => binary(), optional(:display_name) => binary(), optional(:expand) => [binary()], optional(:inclusive) => boolean(), optional(:jurisdiction) => binary(), optional(:metadata) => %{optional(binary()) => binary()}, optional(:percentage) => number(), optional(:state) => binary(), optional(:tax_type) => :gst | :hst | :jct | :pst | :qst | :rst | :sales_tax | :vat }, opts :: Keyword.t() ) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Creates a new tax rate.
Details
- Method:
post - Path:
/v1/tax_rates
@spec list( client :: Stripe.t(), params :: %{ optional(:active) => boolean(), optional(:created) => created() | integer(), optional(:ending_before) => binary(), optional(:expand) => [binary()], optional(:inclusive) => boolean(), optional(:limit) => integer(), optional(:starting_after) => binary() }, opts :: Keyword.t() ) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
Details
- Method:
get - Path:
/v1/tax_rates
@spec retrieve( client :: Stripe.t(), tax_rate :: binary(), params :: %{optional(:expand) => [binary()]}, opts :: Keyword.t() ) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Retrieves a tax rate with the given I.
Details
- Method:
get - Path:
/v1/tax_rates/{tax_rate}
@spec update( client :: Stripe.t(), tax_rate :: binary(), params :: %{ optional(:active) => boolean(), optional(:country) => binary(), optional(:description) => binary(), optional(:display_name) => binary(), optional(:expand) => [binary()], optional(:jurisdiction) => binary(), optional(:metadata) => %{optional(binary()) => binary()} | binary(), optional(:state) => binary(), optional(:tax_type) => :gst | :hst | :jct | :pst | :qst | :rst | :sales_tax | :vat }, opts :: Keyword.t() ) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Updates an existing tax rate.
Details
- Method:
post - Path:
/v1/tax_rates/{tax_rate}