Skip to content

Commit

Permalink
Add list enum comments and autogenerate more options (#2789)
Browse files Browse the repository at this point in the history
  • Loading branch information
pakrym-stripe authored Oct 30, 2023
1 parent 22f509b commit 9eba253
Show file tree
Hide file tree
Showing 128 changed files with 2,402 additions and 69 deletions.
1 change: 1 addition & 0 deletions src/Stripe.net/Entities/BankAccounts/BankAccount.cs
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ public Account Account
/// <summary>
/// A set of available payout methods for this bank account. Only values from this set
/// should be passed as the <c>method</c> when creating a payout.
/// One of: <c>instant</c>, or <c>standard</c>.
/// </summary>
[JsonProperty("available_payout_methods")]
public List<string> AvailablePayoutMethods { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ public class ConfigurationFeaturesCustomerUpdate : StripeEntity<ConfigurationFea
/// <summary>
/// The types of customer updates that are supported. When empty, customers are not
/// updateable.
/// One of: <c>address</c>, <c>email</c>, <c>name</c>, <c>phone</c>, <c>shipping</c>, or
/// <c>tax_id</c>.
/// </summary>
[JsonProperty("allowed_updates")]
public List<string> AllowedUpdates { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public class ConfigurationFeaturesSubscriptionCancelCancellationReason : StripeE

/// <summary>
/// Which cancellation reasons will be given as options to the customer.
/// One of: <c>customer_service</c>, <c>low_quality</c>, <c>missing_features</c>,
/// <c>other</c>, <c>switched_service</c>, <c>too_complex</c>, <c>too_expensive</c>, or
/// <c>unused</c>.
/// </summary>
[JsonProperty("options")]
public List<string> Options { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ public class ConfigurationFeaturesSubscriptionUpdate : StripeEntity<Configuratio
/// <summary>
/// The types of subscription updates that are supported for items listed in the
/// <c>products</c> attribute. When empty, subscriptions are not updateable.
/// One of: <c>price</c>, <c>promotion_code</c>, or <c>quantity</c>.
/// </summary>
[JsonProperty("default_allowed_updates")]
public List<string> DefaultAllowedUpdates { get; set; }
Expand Down
1 change: 1 addition & 0 deletions src/Stripe.net/Entities/Cards/Card.cs
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ public Account Account
/// <summary>
/// A set of available payout methods for this card. Only values from this set should be
/// passed as the <c>method</c> when creating a payout.
/// One of: <c>instant</c>, or <c>standard</c>.
/// </summary>
[JsonProperty("available_payout_methods")]
public List<string> AvailablePayoutMethods { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ public class ChargePaymentMethodDetailsPaypalSellerProtection : StripeEntity<Cha
{
/// <summary>
/// An array of conditions that are covered for the transaction, if applicable.
/// One of: <c>fraudulent</c>, or <c>product_not_received</c>.
/// </summary>
[JsonProperty("dispute_categories")]
public List<string> DisputeCategories { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ public class SessionPaymentMethodOptionsAcssDebitMandateOptions : StripeEntity<S
/// <summary>
/// List of Stripe products where this mandate can be selected automatically. Returned when
/// the Session is in <c>setup</c> mode.
/// One of: <c>invoice</c>, or <c>subscription</c>.
/// </summary>
[JsonProperty("default_for")]
public List<string> DefaultFor { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ public class SessionPaymentMethodOptionsCustomerBalanceBankTransfer : StripeEnti
/// not specified, all valid types will be returned.
///
/// Permitted values include: <c>sort_code</c>, <c>zengin</c>, <c>iban</c>, or <c>spei</c>.
/// One of: <c>aba</c>, <c>iban</c>, <c>sepa</c>, <c>sort_code</c>, <c>spei</c>,
/// <c>swift</c>, or <c>zengin</c>.
/// </summary>
[JsonProperty("requested_address_types")]
public List<string> RequestedAddressTypes { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ public class SessionPaymentMethodOptionsUsBankAccountFinancialConnections : Stri
/// <summary>
/// The list of permissions to request. The <c>payment_method</c> permission must be
/// included.
/// One of: <c>balances</c>, <c>ownership</c>, <c>payment_method</c>, or
/// <c>transactions</c>.
/// </summary>
[JsonProperty("permissions")]
public List<string> Permissions { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,36 @@ public class SessionShippingAddressCollection : StripeEntity<SessionShippingAddr
/// An array of two-letter ISO country codes representing which countries Checkout should
/// provide as options for shipping locations. Unsupported country codes: <c>AS, CX, CC, CU,
/// HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI</c>.
/// One of: <c>AC</c>, <c>AD</c>, <c>AE</c>, <c>AF</c>, <c>AG</c>, <c>AI</c>, <c>AL</c>,
/// <c>AM</c>, <c>AO</c>, <c>AQ</c>, <c>AR</c>, <c>AT</c>, <c>AU</c>, <c>AW</c>, <c>AX</c>,
/// <c>AZ</c>, <c>BA</c>, <c>BB</c>, <c>BD</c>, <c>BE</c>, <c>BF</c>, <c>BG</c>, <c>BH</c>,
/// <c>BI</c>, <c>BJ</c>, <c>BL</c>, <c>BM</c>, <c>BN</c>, <c>BO</c>, <c>BQ</c>, <c>BR</c>,
/// <c>BS</c>, <c>BT</c>, <c>BV</c>, <c>BW</c>, <c>BY</c>, <c>BZ</c>, <c>CA</c>, <c>CD</c>,
/// <c>CF</c>, <c>CG</c>, <c>CH</c>, <c>CI</c>, <c>CK</c>, <c>CL</c>, <c>CM</c>, <c>CN</c>,
/// <c>CO</c>, <c>CR</c>, <c>CV</c>, <c>CW</c>, <c>CY</c>, <c>CZ</c>, <c>DE</c>, <c>DJ</c>,
/// <c>DK</c>, <c>DM</c>, <c>DO</c>, <c>DZ</c>, <c>EC</c>, <c>EE</c>, <c>EG</c>, <c>EH</c>,
/// <c>ER</c>, <c>ES</c>, <c>ET</c>, <c>FI</c>, <c>FJ</c>, <c>FK</c>, <c>FO</c>, <c>FR</c>,
/// <c>GA</c>, <c>GB</c>, <c>GD</c>, <c>GE</c>, <c>GF</c>, <c>GG</c>, <c>GH</c>, <c>GI</c>,
/// <c>GL</c>, <c>GM</c>, <c>GN</c>, <c>GP</c>, <c>GQ</c>, <c>GR</c>, <c>GS</c>, <c>GT</c>,
/// <c>GU</c>, <c>GW</c>, <c>GY</c>, <c>HK</c>, <c>HN</c>, <c>HR</c>, <c>HT</c>, <c>HU</c>,
/// <c>ID</c>, <c>IE</c>, <c>IL</c>, <c>IM</c>, <c>IN</c>, <c>IO</c>, <c>IQ</c>, <c>IS</c>,
/// <c>IT</c>, <c>JE</c>, <c>JM</c>, <c>JO</c>, <c>JP</c>, <c>KE</c>, <c>KG</c>, <c>KH</c>,
/// <c>KI</c>, <c>KM</c>, <c>KN</c>, <c>KR</c>, <c>KW</c>, <c>KY</c>, <c>KZ</c>, <c>LA</c>,
/// <c>LB</c>, <c>LC</c>, <c>LI</c>, <c>LK</c>, <c>LR</c>, <c>LS</c>, <c>LT</c>, <c>LU</c>,
/// <c>LV</c>, <c>LY</c>, <c>MA</c>, <c>MC</c>, <c>MD</c>, <c>ME</c>, <c>MF</c>, <c>MG</c>,
/// <c>MK</c>, <c>ML</c>, <c>MM</c>, <c>MN</c>, <c>MO</c>, <c>MQ</c>, <c>MR</c>, <c>MS</c>,
/// <c>MT</c>, <c>MU</c>, <c>MV</c>, <c>MW</c>, <c>MX</c>, <c>MY</c>, <c>MZ</c>, <c>NA</c>,
/// <c>NC</c>, <c>NE</c>, <c>NG</c>, <c>NI</c>, <c>NL</c>, <c>NO</c>, <c>NP</c>, <c>NR</c>,
/// <c>NU</c>, <c>NZ</c>, <c>OM</c>, <c>PA</c>, <c>PE</c>, <c>PF</c>, <c>PG</c>, <c>PH</c>,
/// <c>PK</c>, <c>PL</c>, <c>PM</c>, <c>PN</c>, <c>PR</c>, <c>PS</c>, <c>PT</c>, <c>PY</c>,
/// <c>QA</c>, <c>RE</c>, <c>RO</c>, <c>RS</c>, <c>RU</c>, <c>RW</c>, <c>SA</c>, <c>SB</c>,
/// <c>SC</c>, <c>SE</c>, <c>SG</c>, <c>SH</c>, <c>SI</c>, <c>SJ</c>, <c>SK</c>, <c>SL</c>,
/// <c>SM</c>, <c>SN</c>, <c>SO</c>, <c>SR</c>, <c>SS</c>, <c>ST</c>, <c>SV</c>, <c>SX</c>,
/// <c>SZ</c>, <c>TA</c>, <c>TC</c>, <c>TD</c>, <c>TF</c>, <c>TG</c>, <c>TH</c>, <c>TJ</c>,
/// <c>TK</c>, <c>TL</c>, <c>TM</c>, <c>TN</c>, <c>TO</c>, <c>TR</c>, <c>TT</c>, <c>TV</c>,
/// <c>TW</c>, <c>TZ</c>, <c>UA</c>, <c>UG</c>, <c>US</c>, <c>UY</c>, <c>UZ</c>, <c>VA</c>,
/// <c>VC</c>, <c>VE</c>, <c>VG</c>, <c>VN</c>, <c>VU</c>, <c>WF</c>, <c>WS</c>, <c>XK</c>,
/// <c>YE</c>, <c>YT</c>, <c>ZA</c>, <c>ZM</c>, <c>ZW</c>, or <c>ZZ</c>.
/// </summary>
[JsonProperty("allowed_countries")]
public List<string> AllowedCountries { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ public AccountOwnership Ownership

/// <summary>
/// The list of permissions granted by this account.
/// One of: <c>balances</c>, <c>ownership</c>, <c>payment_method</c>, or
/// <c>transactions</c>.
/// </summary>
[JsonProperty("permissions")]
public List<string> Permissions { get; set; }
Expand Down Expand Up @@ -152,6 +154,7 @@ public AccountOwnership Ownership
/// The <a
/// href="https://stripe.com/docs/api/payment_methods/object#payment_method_object-type">PaymentMethod
/// type</a>(s) that can be created from this account.
/// One of: <c>link</c>, or <c>us_bank_account</c>.
/// </summary>
[JsonProperty("supported_payment_method_types")]
public List<string> SupportedPaymentMethodTypes { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,15 @@ public class Session : StripeEntity<Session>, IHasId, IHasObject

/// <summary>
/// Permissions requested for accounts collected during this session.
/// One of: <c>balances</c>, <c>ownership</c>, <c>payment_method</c>, or
/// <c>transactions</c>.
/// </summary>
[JsonProperty("permissions")]
public List<string> Permissions { get; set; }

/// <summary>
/// Data features requested to be retrieved upon account creation.
/// One of: <c>balances</c>, or <c>ownership</c>.
/// </summary>
[JsonProperty("prefetch")]
public List<string> Prefetch { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ public class FundingInstructionsBankTransferFinancialAddress : StripeEntity<Fund

/// <summary>
/// The payment networks supported by this FinancialAddress.
/// One of: <c>bacs</c>, <c>fps</c>, <c>sepa</c>, <c>spei</c>, or <c>zengin</c>.
/// </summary>
[JsonProperty("supported_networks")]
public List<string> SupportedNetworks { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public class VerificationReportOptionsDocument : StripeEntity<VerificationReport
/// Array of strings of allowed identity document types. If the provided identity document
/// isn’t one of the allowed types, the verification check will fail with a
/// document_type_not_allowed error code.
/// One of: <c>driving_license</c>, <c>id_card</c>, or <c>passport</c>.
/// </summary>
[JsonProperty("allowed_types")]
public List<string> AllowedTypes { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public class VerificationSessionOptionsDocument : StripeEntity<VerificationSessi
/// Array of strings of allowed identity document types. If the provided identity document
/// isn’t one of the allowed types, the verification check will fail with a
/// document_type_not_allowed error code.
/// One of: <c>driving_license</c>, <c>id_card</c>, or <c>passport</c>.
/// </summary>
[JsonProperty("allowed_types")]
public List<string> AllowedTypes { get; set; }
Expand Down
6 changes: 6 additions & 0 deletions src/Stripe.net/Entities/Invoices/InvoicePaymentSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ public class InvoicePaymentSettings : StripeEntity<InvoicePaymentSettings>
/// customer’s default payment method, and your <a
/// href="https://dashboard.stripe.com/settings/billing/invoice">invoice template
/// settings</a>.
/// One of: <c>ach_credit_transfer</c>, <c>ach_debit</c>, <c>acss_debit</c>,
/// <c>au_becs_debit</c>, <c>bacs_debit</c>, <c>bancontact</c>, <c>boleto</c>, <c>card</c>,
/// <c>cashapp</c>, <c>customer_balance</c>, <c>fpx</c>, <c>giropay</c>, <c>grabpay</c>,
/// <c>ideal</c>, <c>konbini</c>, <c>link</c>, <c>paynow</c>, <c>paypal</c>,
/// <c>promptpay</c>, <c>sepa_credit_transfer</c>, <c>sepa_debit</c>, <c>sofort</c>,
/// <c>us_bank_account</c>, or <c>wechat_pay</c>.
/// </summary>
[JsonProperty("payment_method_types")]
public List<string> PaymentMethodTypes { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ public class InvoicePaymentSettingsPaymentMethodOptionsUsBankAccountFinancialCon
/// <summary>
/// The list of permissions to request. The <c>payment_method</c> permission must be
/// included.
/// One of: <c>balances</c>, <c>payment_method</c>, or <c>transactions</c>.
/// </summary>
[JsonProperty("permissions")]
public List<string> Permissions { get; set; }
Expand Down
1 change: 1 addition & 0 deletions src/Stripe.net/Entities/Issuing/Cardholders/Cardholder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ public class Cardholder : StripeEntity<Cardholder>, IHasId, IHasMetadata, IHasOb
/// <c>de</c>, <c>en</c>, <c>es</c>, <c>fr</c>, or <c>it</c>. This changes the language of
/// the <a href="https://stripe.com/docs/issuing/3d-secure">3D Secure flow</a> and one-time
/// password messages sent to the cardholder.
/// One of: <c>de</c>, <c>en</c>, <c>es</c>, <c>fr</c>, or <c>it</c>.
/// </summary>
[JsonProperty("preferred_locales")]
public List<string> PreferredLocales { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ public class CardholderRequirements : StripeEntity<CardholderRequirements>
/// <summary>
/// Array of fields that need to be collected in order to verify and re-enable the
/// cardholder.
/// One of: <c>company.tax_id</c>,
/// <c>individual.card_issuing.user_terms_acceptance.date</c>,
/// <c>individual.card_issuing.user_terms_acceptance.ip</c>, <c>individual.dob.day</c>,
/// <c>individual.dob.month</c>, <c>individual.dob.year</c>, <c>individual.first_name</c>,
/// <c>individual.last_name</c>, or <c>individual.verification.document</c>.
/// </summary>
[JsonProperty("past_due")]
public List<string> PastDue { get; set; }
Expand Down
Loading

0 comments on commit 9eba253

Please sign in to comment.