INNER CODE UNIT · Go

resourceStripeCoupon

franckverrot/terraform-provider-stripe · stripe/resource_stripe_coupon.go:14

func resourceStripeCoupon() *schema.Resource {
	return &schema.Resource{
		Create: resourceStripeCouponCreate,
		Read:   resourceStripeCouponRead,
		Update: resourceStripeCouponUpdate,
		Delete: resourceStripeCouponDelete,
		Importer: &schema.ResourceImporter{
			State: schema.ImportStatePassthrough,
		},

		Schema: map[string]*schema.Schema{
			"code": &schema.Schema{
				Type:     schema.TypeString,
				Required: true, // require it as the default one is more trouble than it's worth
			},
			"amount_off": &schema.Schema{
				Type:     schema.TypeInt,
				Optional: true,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…