Skip to content

Commit

Permalink
Merge pull request #2289 from stripe/latest-codegen
Browse files Browse the repository at this point in the history
API Updates
  • Loading branch information
richardm-stripe authored Feb 17, 2021
2 parents a05ac99 + 59e5665 commit b5dc62f
Show file tree
Hide file tree
Showing 9 changed files with 75 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ public class ChargePaymentMethodDetailsIdeal : StripeEntity<ChargePaymentMethodD
/// <summary>
/// The customer's bank. Can be one of <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>,
/// <c>handelsbanken</c>, <c>ing</c>, <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>,
/// <c>regiobank</c>, <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>regiobank</c>, <c>revolut</c>, <c>sns_bank</c>, <c>triodos_bank</c>, or
/// <c>van_lanschot</c>.
/// One of: <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>,
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>,
/// <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>,
/// <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// </summary>
[JsonProperty("bank")]
public string Bank { get; set; }
Expand All @@ -21,7 +22,7 @@ public class ChargePaymentMethodDetailsIdeal : StripeEntity<ChargePaymentMethodD
/// The Bank Identifier Code of the customer's bank.
/// One of: <c>ABNANL2A</c>, <c>ASNBNL21</c>, <c>BUNQNL2A</c>, <c>FVLBNL22</c>,
/// <c>HANDNL2A</c>, <c>INGBNL2A</c>, <c>KNABNL2H</c>, <c>MOYONL21</c>, <c>RABONL2U</c>,
/// <c>RBRBNL21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// <c>RBRBNL21</c>, <c>REVOLT21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// </summary>
[JsonProperty("bic")]
public string Bic { get; set; }
Expand Down
37 changes: 37 additions & 0 deletions src/Stripe.net/Entities/Invoices/Invoice.cs
Original file line number Diff line number Diff line change
Expand Up @@ -499,6 +499,43 @@ public List<Discount> Discounts
[JsonProperty("number")]
public string Number { get; set; }

#region Expandable OnBehalfOf

/// <summary>
/// (ID of the Account)
/// The account (if any) for which the funds of the invoice payment are intended. If set,
/// the invoice will be presented with the branding and support information of the specified
/// account. See the <a href="https://stripe.com/docs/billing/invoices/connect">Invoices
/// with Connect</a> documentation for details.
/// </summary>
[JsonIgnore]
public string OnBehalfOfId
{
get => this.InternalOnBehalfOf?.Id;
set => this.InternalOnBehalfOf = SetExpandableFieldId(value, this.InternalOnBehalfOf);
}

/// <summary>
/// (Expanded)
/// The account (if any) for which the funds of the invoice payment are intended. If set,
/// the invoice will be presented with the branding and support information of the specified
/// account. See the <a href="https://stripe.com/docs/billing/invoices/connect">Invoices
/// with Connect</a> documentation for details.
///
/// For more information, see the <a href="https://stripe.com/docs/expand">expand documentation</a>.
/// </summary>
[JsonIgnore]
public Account OnBehalfOf
{
get => this.InternalOnBehalfOf?.ExpandedObject;
set => this.InternalOnBehalfOf = SetExpandableFieldObject(value, this.InternalOnBehalfOf);
}

[JsonProperty("on_behalf_of")]
[JsonConverter(typeof(ExpandableFieldConverter<Account>))]
internal ExpandableField<Account> InternalOnBehalfOf { get; set; }
#endregion

/// <summary>
/// Whether payment was successfully collected for this invoice. An invoice can be paid
/// (most commonly) with a charge or with credit from the customer's account balance.
Expand Down
10 changes: 5 additions & 5 deletions src/Stripe.net/Entities/PaymentMethods/PaymentMethodIdeal.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ public class PaymentMethodIdeal : StripeEntity<PaymentMethodIdeal>
/// <summary>
/// The customer's bank, if provided. Can be one of <c>abn_amro</c>, <c>asn_bank</c>,
/// <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>, <c>knab</c>, <c>moneyou</c>,
/// <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>, <c>triodos_bank</c>, or
/// <c>van_lanschot</c>.
/// <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>, <c>sns_bank</c>, <c>triodos_bank</c>,
/// or <c>van_lanschot</c>.
/// One of: <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>,
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>,
/// <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>,
/// <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// </summary>
[JsonProperty("bank")]
public string Bank { get; set; }
Expand All @@ -21,7 +21,7 @@ public class PaymentMethodIdeal : StripeEntity<PaymentMethodIdeal>
/// The Bank Identifier Code of the customer's bank, if the bank was provided.
/// One of: <c>ABNANL2A</c>, <c>ASNBNL21</c>, <c>BUNQNL2A</c>, <c>FVLBNL22</c>,
/// <c>HANDNL2A</c>, <c>INGBNL2A</c>, <c>KNABNL2H</c>, <c>MOYONL21</c>, <c>RABONL2U</c>,
/// <c>RBRBNL21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// <c>RBRBNL21</c>, <c>REVOLT21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// </summary>
[JsonProperty("bic")]
public string Bic { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ public class SetupAttemptPaymentMethodDetailsIdeal : StripeEntity<SetupAttemptPa
/// <summary>
/// The customer's bank. Can be one of <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>,
/// <c>handelsbanken</c>, <c>ing</c>, <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>,
/// <c>regiobank</c>, <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>regiobank</c>, <c>revolut</c>, <c>sns_bank</c>, <c>triodos_bank</c>, or
/// <c>van_lanschot</c>.
/// One of: <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>,
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>,
/// <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>,
/// <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// </summary>
[JsonProperty("bank")]
public string Bank { get; set; }
Expand All @@ -21,7 +22,7 @@ public class SetupAttemptPaymentMethodDetailsIdeal : StripeEntity<SetupAttemptPa
/// The Bank Identifier Code of the customer's bank.
/// One of: <c>ABNANL2A</c>, <c>ASNBNL21</c>, <c>BUNQNL2A</c>, <c>FVLBNL22</c>,
/// <c>HANDNL2A</c>, <c>INGBNL2A</c>, <c>KNABNL2H</c>, <c>MOYONL21</c>, <c>RABONL2U</c>,
/// <c>RBRBNL21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// <c>RBRBNL21</c>, <c>REVOLT21</c>, <c>SNSBNL2A</c>, or <c>TRIONL2U</c>.
/// </summary>
[JsonProperty("bic")]
public string Bic { get; set; }
Expand Down
9 changes: 9 additions & 0 deletions src/Stripe.net/Services/Invoices/InvoiceCreateOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,15 @@ public class InvoiceCreateOptions : BaseOptions, IHasMetadata
[JsonProperty("metadata")]
public Dictionary<string, string> Metadata { get; set; }

/// <summary>
/// The account (if any) for which the funds of the invoice payment are intended. If set,
/// the invoice will be presented with the branding and support information of the specified
/// account. See the <a href="https://stripe.com/docs/billing/invoices/connect">Invoices
/// with Connect</a> documentation for details.
/// </summary>
[JsonProperty("on_behalf_of")]
public string OnBehalfOf { get; set; }

/// <summary>
/// Configuration settings for the PaymentIntent that is generated when the invoice is
/// finalized.
Expand Down
2 changes: 1 addition & 1 deletion src/Stripe.net/Services/Invoices/InvoiceFinalizeOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ public class InvoiceFinalizeOptions : BaseOptions
{
/// <summary>
/// Controls whether Stripe will perform <a
/// href="https://stripe.com/docs/billing/invoices/workflow/#auto_advance">automatic
/// href="https://stripe.com/docs/billing/invoices/overview#auto-advance">automatic
/// collection</a> of the invoice. When <c>false</c>, the invoice's state will not
/// automatically advance without an explicit action.
/// </summary>
Expand Down
9 changes: 9 additions & 0 deletions src/Stripe.net/Services/Invoices/InvoiceUpdateOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,15 @@ public class InvoiceUpdateOptions : BaseOptions, IHasMetadata
[JsonProperty("metadata")]
public Dictionary<string, string> Metadata { get; set; }

/// <summary>
/// The account (if any) for which the funds of the invoice payment are intended. If set,
/// the invoice will be presented with the branding and support information of the specified
/// account. See the <a href="https://stripe.com/docs/billing/invoices/connect">Invoices
/// with Connect</a> documentation for details.
/// </summary>
[JsonProperty("on_behalf_of")]
public string OnBehalfOf { get; set; }

/// <summary>
/// Configuration settings for the PaymentIntent that is generated when the invoice is
/// finalized.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ public class PaymentIntentPaymentMethodDataIdealOptions : INestedOptions
/// <summary>
/// The customer's bank.
/// One of: <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>,
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>,
/// <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>,
/// <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// </summary>
[JsonProperty("bank")]
public string Bank { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ public class PaymentMethodIdealOptions : INestedOptions
/// <summary>
/// The customer's bank.
/// One of: <c>abn_amro</c>, <c>asn_bank</c>, <c>bunq</c>, <c>handelsbanken</c>, <c>ing</c>,
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>sns_bank</c>,
/// <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// <c>knab</c>, <c>moneyou</c>, <c>rabobank</c>, <c>regiobank</c>, <c>revolut</c>,
/// <c>sns_bank</c>, <c>triodos_bank</c>, or <c>van_lanschot</c>.
/// </summary>
[JsonProperty("bank")]
public string Bank { get; set; }
Expand Down

0 comments on commit b5dc62f

Please sign in to comment.