UNPKG

pulumi-stripe

Version:

A Pulumi package for creating and managing Stripe resources.

217 lines (216 loc) 9.26 kB
import * as pulumi from "@pulumi/pulumi"; /** * With this resource, you can create a tax rate - [Stripe API tax rate documentation](https://stripe.com/docs/api/tax_rates). * * Tax rates can be applied to invoices, subscriptions and Checkout Sessions to collect tax. * * ## Example Usage * * <!--Start PulumiCodeChooser --> * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as stripe from "pulumi-stripe"; * * const taxRate = new stripe.TaxRate("taxRate", { * active: true, * country: "AU", * description: "GST Australia", * displayName: "GST", * inclusive: true, * jurisdiction: "AU", * metadata: {}, * percentage: 10, * state: "", * taxType: "", * }); * ``` * <!--End PulumiCodeChooser --> */ export declare class TaxRate extends pulumi.CustomResource { /** * Get an existing TaxRate resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: TaxRateState, opts?: pulumi.CustomResourceOptions): TaxRate; /** * Returns true if the given object is an instance of TaxRate. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is TaxRate; /** * Bool. Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set. */ readonly active: pulumi.Output<boolean | undefined>; /** * String. Two-letter country code (ISO 3166-1 alpha-2). */ readonly country: pulumi.Output<string | undefined>; /** * Int. Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: pulumi.Output<number>; /** * String. An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers. */ readonly description: pulumi.Output<string | undefined>; /** * String. The display name of the tax rate, which will be shown to users. */ readonly displayName: pulumi.Output<string>; /** * Bool. This specifies if the tax rate is inclusive or exclusive. * * `percentage ` - (Required) Float. This represents the tax rate percent out of 100. */ readonly inclusive: pulumi.Output<boolean>; /** * String. The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice. */ readonly jurisdiction: pulumi.Output<string | undefined>; /** * Bool. Has the value true if the object exists in live mode or the value false if the object exists in test mode. */ readonly livemode: pulumi.Output<boolean>; /** * Map(String). Set 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. */ readonly metadata: pulumi.Output<{ [key: string]: string; } | undefined>; /** * String. String representing the object’s type. Objects of the same type share the same value. */ readonly object: pulumi.Output<string>; /** * This represents the tax rate percent out of 100. */ readonly percentage: pulumi.Output<number>; /** * String. ISO 3166-2 subdivision code, without country prefix. For example, “NY” for New York, United States. */ readonly state: pulumi.Output<string | undefined>; /** * String. The high-level tax type, such as vat or sales_tax. */ readonly taxType: pulumi.Output<string | undefined>; /** * Create a TaxRate resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: TaxRateArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering TaxRate resources. */ export interface TaxRateState { /** * Bool. Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set. */ active?: pulumi.Input<boolean>; /** * String. Two-letter country code (ISO 3166-1 alpha-2). */ country?: pulumi.Input<string>; /** * Int. Time at which the object was created. Measured in seconds since the Unix epoch. */ created?: pulumi.Input<number>; /** * String. An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers. */ description?: pulumi.Input<string>; /** * String. The display name of the tax rate, which will be shown to users. */ displayName?: pulumi.Input<string>; /** * Bool. This specifies if the tax rate is inclusive or exclusive. * * `percentage ` - (Required) Float. This represents the tax rate percent out of 100. */ inclusive?: pulumi.Input<boolean>; /** * String. The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice. */ jurisdiction?: pulumi.Input<string>; /** * Bool. Has the value true if the object exists in live mode or the value false if the object exists in test mode. */ livemode?: pulumi.Input<boolean>; /** * Map(String). Set 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. */ metadata?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * String. String representing the object’s type. Objects of the same type share the same value. */ object?: pulumi.Input<string>; /** * This represents the tax rate percent out of 100. */ percentage?: pulumi.Input<number>; /** * String. ISO 3166-2 subdivision code, without country prefix. For example, “NY” for New York, United States. */ state?: pulumi.Input<string>; /** * String. The high-level tax type, such as vat or sales_tax. */ taxType?: pulumi.Input<string>; } /** * The set of arguments for constructing a TaxRate resource. */ export interface TaxRateArgs { /** * Bool. Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set. */ active?: pulumi.Input<boolean>; /** * String. Two-letter country code (ISO 3166-1 alpha-2). */ country?: pulumi.Input<string>; /** * String. An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers. */ description?: pulumi.Input<string>; /** * String. The display name of the tax rate, which will be shown to users. */ displayName: pulumi.Input<string>; /** * Bool. This specifies if the tax rate is inclusive or exclusive. * * `percentage ` - (Required) Float. This represents the tax rate percent out of 100. */ inclusive: pulumi.Input<boolean>; /** * String. The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice. */ jurisdiction?: pulumi.Input<string>; /** * Map(String). Set 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. */ metadata?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * This represents the tax rate percent out of 100. */ percentage: pulumi.Input<number>; /** * String. ISO 3166-2 subdivision code, without country prefix. For example, “NY” for New York, United States. */ state?: pulumi.Input<string>; /** * String. The high-level tax type, such as vat or sales_tax. */ taxType?: pulumi.Input<string>; }