Skip to content

Commit

Permalink
Multiple breaking API changes
Browse files Browse the repository at this point in the history
* `PaymentIntent` is now expandable on `Charge`
* `Percentage` was removed as a filter when listing `TaxRate`
* Removed `RenewalInterval` on `SubscriptionSchedule`
* Removed `Country` and `RoutingNumber` from `ChargePaymentMethodDetailsAcssDebit`
  • Loading branch information
remi-stripe committed Apr 16, 2020
1 parent 28c24cf commit c918c5a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 19 deletions.
8 changes: 3 additions & 5 deletions charge.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,10 +193,8 @@ type ChargePaymentMethodDetailsAchDebit struct {

// ChargePaymentMethodDetailsAcssDebit represents details about the ACSS Debit PaymentMethod.
type ChargePaymentMethodDetailsAcssDebit struct {
Country string `json:"country"`
Fingerprint string `json:"fingerprint"`
Last4 string `json:"last4"`
RoutingNumber string `json:"routing_number"`
Fingerprint string `json:"fingerprint"`
Last4 string `json:"last4"`
}

// ChargePaymentMethodDetailsAlipay represents details about the Alipay PaymentMethod.
Expand Down Expand Up @@ -487,7 +485,7 @@ type Charge struct {
OnBehalfOf *Account `json:"on_behalf_of"`
Outcome *ChargeOutcome `json:"outcome"`
Paid bool `json:"paid"`
PaymentIntent string `json:"payment_intent"`
PaymentIntent *PaymentIntent `json:"payment_intent"`
PaymentMethod string `json:"payment_method"`
PaymentMethodDetails *ChargePaymentMethodDetails `json:"payment_method_details"`
ReceiptEmail string `json:"receipt_email"`
Expand Down
7 changes: 0 additions & 7 deletions subschedule.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,12 +178,6 @@ type SubscriptionSchedulePhase struct {
TaxPercent float64 `json:"tax_percent"`
}

// SubscriptionScheduleRenewalInterval represents the interval and duration of a schedule.
type SubscriptionScheduleRenewalInterval struct {
Interval PlanInterval `form:"interval"`
Length int64 `form:"length"`
}

// SubscriptionSchedule is the resource representing a Stripe subscription schedule.
type SubscriptionSchedule struct {
APIResource
Expand All @@ -200,7 +194,6 @@ type SubscriptionSchedule struct {
Object string `json:"object"`
Phases []*SubscriptionSchedulePhase `json:"phases"`
ReleasedSubscription *Subscription `json:"released_subscription"`
RenewalInterval *SubscriptionScheduleRenewalInterval `json:"renewal_interval"`
Status SubscriptionScheduleStatus `json:"status"`
Subscription *Subscription `json:"subscription"`
}
Expand Down
12 changes: 5 additions & 7 deletions taxrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,11 @@ type TaxRatePercentageRangeQueryParams struct {
// TaxRateListParams is the set of parameters that can be used when listing tax rates.
// For more detail see https://stripe.com/docs/api/tax_rates/list.
type TaxRateListParams struct {
ListParams `form:"*"`
Active *bool `form:"active"`
Created *int64 `form:"created"`
CreatedRange *RangeQueryParams `form:"created"`
Inclusive *bool `form:"inclusive"`
Percentage *float64 `form:"percentage"`
PercentageRange *TaxRatePercentageRangeQueryParams `form:"percentage"`
ListParams `form:"*"`
Active *bool `form:"active"`
Created *int64 `form:"created"`
CreatedRange *RangeQueryParams `form:"created"`
Inclusive *bool `form:"inclusive"`
}

// TaxRate is the resource representing a Stripe tax rate.
Expand Down

0 comments on commit c918c5a

Please sign in to comment.