diff --git a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextAction.cs b/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextAction.cs index a645089ed7..5478c4dd6c 100644 --- a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextAction.cs +++ b/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextAction.cs @@ -1,6 +1,7 @@ // File generated from our OpenAPI spec namespace Stripe { + using System.Collections.Generic; using Newtonsoft.Json; #if NET6_0_OR_GREATER using STJS = System.Text.Json.Serialization; @@ -107,7 +108,7 @@ public class PaymentIntentNextAction : StripeEntity #if NET6_0_OR_GREATER [STJS.JsonPropertyName("use_stripe_sdk")] #endif - public PaymentIntentNextActionUseStripeSdk UseStripeSdk { get; set; } + public Dictionary UseStripeSdk { get; set; } [JsonProperty("verify_with_microdeposits")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextActionUseStripeSdk.cs b/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextActionUseStripeSdk.cs deleted file mode 100644 index cdf002d2ad..0000000000 --- a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentNextActionUseStripeSdk.cs +++ /dev/null @@ -1,7 +0,0 @@ -// File generated from our OpenAPI spec -namespace Stripe -{ - public class PaymentIntentNextActionUseStripeSdk : StripeEntity - { - } -} diff --git a/src/Stripe.net/Entities/SetupIntents/SetupIntentNextAction.cs b/src/Stripe.net/Entities/SetupIntents/SetupIntentNextAction.cs index dc6e4b5bfa..1ce3c34c16 100644 --- a/src/Stripe.net/Entities/SetupIntents/SetupIntentNextAction.cs +++ b/src/Stripe.net/Entities/SetupIntents/SetupIntentNextAction.cs @@ -1,6 +1,7 @@ // File generated from our OpenAPI spec namespace Stripe { + using System.Collections.Generic; using Newtonsoft.Json; #if NET6_0_OR_GREATER using STJS = System.Text.Json.Serialization; @@ -47,7 +48,7 @@ public class SetupIntentNextAction : StripeEntity #if NET6_0_OR_GREATER [STJS.JsonPropertyName("use_stripe_sdk")] #endif - public SetupIntentNextActionUseStripeSdk UseStripeSdk { get; set; } + public Dictionary UseStripeSdk { get; set; } [JsonProperty("verify_with_microdeposits")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/SetupIntents/SetupIntentNextActionUseStripeSdk.cs b/src/Stripe.net/Entities/SetupIntents/SetupIntentNextActionUseStripeSdk.cs deleted file mode 100644 index 71794eb783..0000000000 --- a/src/Stripe.net/Entities/SetupIntents/SetupIntentNextActionUseStripeSdk.cs +++ /dev/null @@ -1,7 +0,0 @@ -// File generated from our OpenAPI spec -namespace Stripe -{ - public class SetupIntentNextActionUseStripeSdk : StripeEntity - { - } -} diff --git a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceBillingCycleMonth.cs b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceBillingCycleMonth.cs index 3c37c2a53a..980c2eb0ba 100644 --- a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceBillingCycleMonth.cs +++ b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceBillingCycleMonth.cs @@ -19,6 +19,16 @@ public class CadenceBillingCycleMonth : StripeEntity #endif public long DayOfMonth { get; set; } + /// + /// The month to anchor the billing on for a type="month" billing cycle from 1-12. + /// Occurrences are calculated from the month anchor. + /// + [JsonProperty("month_of_year")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("month_of_year")] +#endif + public long? MonthOfYear { get; set; } + /// /// The time at which the billing cycle ends. /// diff --git a/src/Stripe.net/Entities/V2/Billing/IntentActions/IntentActionDeactivateEffectiveAt.cs b/src/Stripe.net/Entities/V2/Billing/IntentActions/IntentActionDeactivateEffectiveAt.cs index a2eac61380..787f945510 100644 --- a/src/Stripe.net/Entities/V2/Billing/IntentActions/IntentActionDeactivateEffectiveAt.cs +++ b/src/Stripe.net/Entities/V2/Billing/IntentActions/IntentActionDeactivateEffectiveAt.cs @@ -21,7 +21,8 @@ public class IntentActionDeactivateEffectiveAt : StripeEntity /// When the deactivate action will take effect. - /// One of: current_billing_period_start, on_reserve, or timestamp. + /// One of: current_billing_period_end, current_billing_period_start, + /// on_reserve, or timestamp. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Billing/PricingPlanSubscriptions/PricingPlanSubscriptionServicingStatusTransitions.cs b/src/Stripe.net/Entities/V2/Billing/PricingPlanSubscriptions/PricingPlanSubscriptionServicingStatusTransitions.cs index 569e405f85..c85226072e 100644 --- a/src/Stripe.net/Entities/V2/Billing/PricingPlanSubscriptions/PricingPlanSubscriptionServicingStatusTransitions.cs +++ b/src/Stripe.net/Entities/V2/Billing/PricingPlanSubscriptions/PricingPlanSubscriptionServicingStatusTransitions.cs @@ -34,5 +34,23 @@ public class PricingPlanSubscriptionServicingStatusTransitions : StripeEntity + /// When the servicing is scheduled to transition to activate. + /// + [JsonProperty("will_activate_at")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("will_activate_at")] +#endif + public string WillActivateAt { get; set; } + + /// + /// When the servicing is scheduled to cancel. + /// + [JsonProperty("will_cancel_at")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("will_cancel_at")] +#endif + public string WillCancelAt { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Billing/RateCardSubscriptions/RateCardSubscriptionServicingStatusTransitions.cs b/src/Stripe.net/Entities/V2/Billing/RateCardSubscriptions/RateCardSubscriptionServicingStatusTransitions.cs index 01dbb69b2c..f5cde657d6 100644 --- a/src/Stripe.net/Entities/V2/Billing/RateCardSubscriptions/RateCardSubscriptionServicingStatusTransitions.cs +++ b/src/Stripe.net/Entities/V2/Billing/RateCardSubscriptions/RateCardSubscriptionServicingStatusTransitions.cs @@ -34,5 +34,23 @@ public class RateCardSubscriptionServicingStatusTransitions : StripeEntity + /// When the servicing is scheduled to transition to activate. + /// + [JsonProperty("will_activate_at")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("will_activate_at")] +#endif + public string WillActivateAt { get; set; } + + /// + /// When the servicing is scheduled to cancel. + /// + [JsonProperty("will_cancel_at")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("will_cancel_at")] +#endif + public string WillCancelAt { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrant.cs b/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrant.cs index 1d2921acac..a0f09c9023 100644 --- a/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrant.cs +++ b/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrant.cs @@ -26,6 +26,16 @@ public class ServiceActionCreditGrant : StripeEntity #endif public ServiceActionCreditGrantApplicabilityConfig ApplicabilityConfig { get; set; } + /// + /// The category of the credit grant. + /// One of: paid, or promotional. + /// + [JsonProperty("category")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("category")] +#endif + public string Category { get; set; } + /// /// The expiry configuration for the credit grant. /// @@ -43,5 +53,15 @@ public class ServiceActionCreditGrant : StripeEntity [STJS.JsonPropertyName("name")] #endif public string Name { get; set; } + + /// + /// The desired priority for applying this credit grant. If not specified, it will be set to + /// the default value of 50. The highest priority is 0 and the lowest is 100. + /// + [JsonProperty("priority")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("priority")] +#endif + public long? Priority { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrantPerTenant.cs b/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrantPerTenant.cs index b744112960..a62242faa8 100644 --- a/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrantPerTenant.cs +++ b/src/Stripe.net/Entities/V2/Billing/ServiceActions/ServiceActionCreditGrantPerTenant.cs @@ -26,6 +26,16 @@ public class ServiceActionCreditGrantPerTenant : StripeEntity + /// The category of the credit grant. + /// One of: paid, or promotional. + /// + [JsonProperty("category")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("category")] +#endif + public string Category { get; set; } + /// /// The expiry configuration for the credit grant. /// @@ -43,5 +53,15 @@ public class ServiceActionCreditGrantPerTenant : StripeEntity + /// The desired priority for applying this credit grant. If not specified, it will be set to + /// the default value of 50. The highest priority is 0 and the lowest is 100. + /// + [JsonProperty("priority")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("priority")] +#endif + public long? Priority { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandbox.cs b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandbox.cs index cc957cff09..f1eb0764cf 100644 --- a/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandbox.cs +++ b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandbox.cs @@ -38,23 +38,24 @@ public class ClaimableSandbox : StripeEntity, IHasId, IHasObje public string Object { get; set; } /// - /// Keys that can be used to set up an integration for this sandbox and operate on the - /// account. + /// URL for user to claim sandbox into their existing Stripe account. The value will be null + /// if the sandbox status is claimed or expired. /// - [JsonProperty("api_keys")] + [JsonProperty("claim_url")] #if NET6_0_OR_GREATER - [STJS.JsonPropertyName("api_keys")] + [STJS.JsonPropertyName("claim_url")] #endif - public ClaimableSandboxApiKeys ApiKeys { get; set; } + public string ClaimUrl { get; set; } /// - /// URL for user to claim sandbox into their existing Stripe account. + /// The timestamp the sandbox was claimed. The value will be null if the sandbox status is + /// not claimed. /// - [JsonProperty("claim_url")] + [JsonProperty("claimed_at")] #if NET6_0_OR_GREATER - [STJS.JsonPropertyName("claim_url")] + [STJS.JsonPropertyName("claimed_at")] #endif - public string ClaimUrl { get; set; } + public DateTime? ClaimedAt { get; set; } /// /// When the sandbox is created. @@ -65,6 +66,16 @@ public class ClaimableSandbox : StripeEntity, IHasId, IHasObje #endif public DateTime Created { get; set; } = Stripe.Infrastructure.DateTimeUtils.UnixEpoch; + /// + /// The timestamp the sandbox will expire. The value will be null if the sandbox is + /// claimed. + /// + [JsonProperty("expires_at")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("expires_at")] +#endif + public DateTime? ExpiresAt { get; set; } + /// /// Has the value true if the object exists in live mode or the value false if /// the object exists in test mode. @@ -83,5 +94,24 @@ public class ClaimableSandbox : StripeEntity, IHasId, IHasObje [STJS.JsonPropertyName("prefill")] #endif public ClaimableSandboxPrefill Prefill { get; set; } + + /// + /// Data about the Stripe sandbox object. + /// + [JsonProperty("sandbox_details")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("sandbox_details")] +#endif + public ClaimableSandboxSandboxDetails SandboxDetails { get; set; } + + /// + /// Status of the sandbox. One of unclaimed, expired, claimed. + /// One of: claimed, expired, or unclaimed. + /// + [JsonProperty("status")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("status")] +#endif + public string Status { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetails.cs b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetails.cs new file mode 100644 index 0000000000..566800c6d9 --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetails.cs @@ -0,0 +1,40 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class ClaimableSandboxSandboxDetails : StripeEntity + { + /// + /// The sandbox's Stripe account ID. + /// + [JsonProperty("account")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("account")] +#endif + public string Account { get; set; } + + /// + /// Keys that can be used to set up an integration for this sandbox and operate on the + /// account. + /// + [JsonProperty("api_keys")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("api_keys")] +#endif + public ClaimableSandboxSandboxDetailsApiKeys ApiKeys { get; set; } + + /// + /// The livemode sandbox Stripe account ID. This field is only set if the user activates + /// their sandbox and chooses to install your platform's Stripe App in their live account. + /// + [JsonProperty("owner_account")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("owner_account")] +#endif + public string OwnerAccount { get; set; } + } +} diff --git a/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxApiKeys.cs b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetailsApiKeys.cs similarity index 91% rename from src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxApiKeys.cs rename to src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetailsApiKeys.cs index b846bdd5c6..2c204f3847 100644 --- a/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxApiKeys.cs +++ b/src/Stripe.net/Entities/V2/Core/ClaimableSandboxes/ClaimableSandboxSandboxDetailsApiKeys.cs @@ -6,7 +6,7 @@ namespace Stripe.V2.Core using STJS = System.Text.Json.Serialization; #endif - public class ClaimableSandboxApiKeys : StripeEntity + public class ClaimableSandboxSandboxDetailsApiKeys : StripeEntity { /// /// Used to communicate with Stripe's MCP server. diff --git a/src/Stripe.net/Events/PushedV2CoreClaimableSandboxClaimedEvent.cs b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxClaimedEvent.cs new file mode 100644 index 0000000000..7c03fb5405 --- /dev/null +++ b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxClaimedEvent.cs @@ -0,0 +1,52 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is claimed. + /// + public class PushedV2CoreClaimableSandboxClaimedEvent : V2.PushedEvent + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + + public V2CoreClaimableSandboxClaimedEvent Pull() + { + return this.PullEvent(); + } + + public Task PullAsync() + { + return this.PullEventAsync(); + } + } +} diff --git a/src/Stripe.net/Events/PushedV2BillingCadenceErroredEvent.cs b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiredEvent.cs similarity index 57% rename from src/Stripe.net/Events/PushedV2BillingCadenceErroredEvent.cs rename to src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiredEvent.cs index 78e9ae23c5..e282d7fc91 100644 --- a/src/Stripe.net/Events/PushedV2BillingCadenceErroredEvent.cs +++ b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiredEvent.cs @@ -8,9 +8,9 @@ namespace Stripe.Events #endif /// - /// Occurs when a billing Cadence encounters an error during a tick. + /// Occurs when a claimable sandbox expires. /// - public class PushedV2BillingCadenceErroredEvent : V2.PushedEvent + public class PushedV2CoreClaimableSandboxExpiredEvent : V2.PushedEvent { /// /// Object containing the reference to API resource relevant to the event. @@ -26,27 +26,27 @@ public class PushedV2BillingCadenceErroredEvent : V2.PushedEvent /// Asynchronously retrieves the related object from the API. Make an API request on every /// call. /// - public Task FetchRelatedObjectAsync() + public Task FetchRelatedObjectAsync() { - return this.FetchRelatedObjectAsync(this.RelatedObject); + return this.FetchRelatedObjectAsync(this.RelatedObject); } /// /// Retrieves the related object from the API. Make an API request on every call. /// - public V2.Billing.Cadence FetchRelatedObject() + public V2.Core.ClaimableSandbox FetchRelatedObject() { - return this.FetchRelatedObject(this.RelatedObject); + return this.FetchRelatedObject(this.RelatedObject); } - public V2BillingCadenceErroredEvent Pull() + public V2CoreClaimableSandboxExpiredEvent Pull() { - return this.PullEvent(); + return this.PullEvent(); } - public Task PullAsync() + public Task PullAsync() { - return this.PullEventAsync(); + return this.PullEventAsync(); } } } diff --git a/src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiringEvent.cs b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiringEvent.cs new file mode 100644 index 0000000000..802b6d0d51 --- /dev/null +++ b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxExpiringEvent.cs @@ -0,0 +1,52 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is expiring in 7 days. + /// + public class PushedV2CoreClaimableSandboxExpiringEvent : V2.PushedEvent + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + + public V2CoreClaimableSandboxExpiringEvent Pull() + { + return this.PullEvent(); + } + + public Task PullAsync() + { + return this.PullEventAsync(); + } + } +} diff --git a/src/Stripe.net/Events/PushedV2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs new file mode 100644 index 0000000000..53aedd3541 --- /dev/null +++ b/src/Stripe.net/Events/PushedV2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs @@ -0,0 +1,53 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is activated by the user with the intention to go live + /// and your Stripe app is installed on the live account. + /// + public class PushedV2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent : V2.PushedEvent + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + + public V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent Pull() + { + return this.PullEvent(); + } + + public Task PullAsync() + { + return this.PullEventAsync(); + } + } +} diff --git a/src/Stripe.net/Events/V2BillingCadenceBilledEvent.cs b/src/Stripe.net/Events/V2BillingCadenceBilledEvent.cs index 7c20818fe2..d9054641e6 100644 --- a/src/Stripe.net/Events/V2BillingCadenceBilledEvent.cs +++ b/src/Stripe.net/Events/V2BillingCadenceBilledEvent.cs @@ -12,6 +12,16 @@ namespace Stripe.Events /// public class V2BillingCadenceBilledEvent : V2.Event { + /// + /// Data for the v2.billing.cadence.billed event. + /// + [JsonProperty("data")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("data")] +#endif + + public V2BillingCadenceBilledEventData Data { get; set; } + /// /// Object containing the reference to API resource relevant to the event. /// diff --git a/src/Stripe.net/Events/V2BillingCadenceBilledEventData.cs b/src/Stripe.net/Events/V2BillingCadenceBilledEventData.cs new file mode 100644 index 0000000000..1a87a0c626 --- /dev/null +++ b/src/Stripe.net/Events/V2BillingCadenceBilledEventData.cs @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Collections.Generic; + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class V2BillingCadenceBilledEventData : StripeEntity + { + /// + /// The IDs of the invoices that were generated by the tick for this Cadence. + /// + [JsonProperty("invoices")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("invoices")] +#endif + public List Invoices { get; set; } + } +} diff --git a/src/Stripe.net/Events/V2CoreClaimableSandboxClaimedEvent.cs b/src/Stripe.net/Events/V2CoreClaimableSandboxClaimedEvent.cs new file mode 100644 index 0000000000..257e70dd76 --- /dev/null +++ b/src/Stripe.net/Events/V2CoreClaimableSandboxClaimedEvent.cs @@ -0,0 +1,42 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is claimed. + /// + public class V2CoreClaimableSandboxClaimedEvent : V2.Event + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + } +} diff --git a/src/Stripe.net/Events/V2BillingCadenceErroredEvent.cs b/src/Stripe.net/Events/V2CoreClaimableSandboxExpiredEvent.cs similarity index 67% rename from src/Stripe.net/Events/V2BillingCadenceErroredEvent.cs rename to src/Stripe.net/Events/V2CoreClaimableSandboxExpiredEvent.cs index 038011e6b8..3f8e44b974 100644 --- a/src/Stripe.net/Events/V2BillingCadenceErroredEvent.cs +++ b/src/Stripe.net/Events/V2CoreClaimableSandboxExpiredEvent.cs @@ -8,9 +8,9 @@ namespace Stripe.Events #endif /// - /// Occurs when a billing Cadence encounters an error during a tick. + /// Occurs when a claimable sandbox expires. /// - public class V2BillingCadenceErroredEvent : V2.Event + public class V2CoreClaimableSandboxExpiredEvent : V2.Event { /// /// Object containing the reference to API resource relevant to the event. @@ -26,17 +26,17 @@ public class V2BillingCadenceErroredEvent : V2.Event /// Asynchronously retrieves the related object from the API. Make an API request on every /// call. /// - public Task FetchRelatedObjectAsync() + public Task FetchRelatedObjectAsync() { - return this.FetchRelatedObjectAsync(this.RelatedObject); + return this.FetchRelatedObjectAsync(this.RelatedObject); } /// /// Retrieves the related object from the API. Make an API request on every call. /// - public V2.Billing.Cadence FetchRelatedObject() + public V2.Core.ClaimableSandbox FetchRelatedObject() { - return this.FetchRelatedObject(this.RelatedObject); + return this.FetchRelatedObject(this.RelatedObject); } } } diff --git a/src/Stripe.net/Events/V2CoreClaimableSandboxExpiringEvent.cs b/src/Stripe.net/Events/V2CoreClaimableSandboxExpiringEvent.cs new file mode 100644 index 0000000000..60a63d8bdc --- /dev/null +++ b/src/Stripe.net/Events/V2CoreClaimableSandboxExpiringEvent.cs @@ -0,0 +1,42 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is expiring in 7 days. + /// + public class V2CoreClaimableSandboxExpiringEvent : V2.Event + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + } +} diff --git a/src/Stripe.net/Events/V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs b/src/Stripe.net/Events/V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs new file mode 100644 index 0000000000..57f6583068 --- /dev/null +++ b/src/Stripe.net/Events/V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent.cs @@ -0,0 +1,43 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + /// + /// Occurs when a claimable sandbox is activated by the user with the intention to go live + /// and your Stripe app is installed on the live account. + /// + public class V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent : V2.Event + { + /// + /// Object containing the reference to API resource relevant to the event. + /// + [JsonProperty("related_object")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("related_object")] +#endif + + public V2.EventRelatedObject RelatedObject { get; set; } + + /// + /// Asynchronously retrieves the related object from the API. Make an API request on every + /// call. + /// + public Task FetchRelatedObjectAsync() + { + return this.FetchRelatedObjectAsync(this.RelatedObject); + } + + /// + /// Retrieves the related object from the API. Make an API request on every call. + /// + public V2.Core.ClaimableSandbox FetchRelatedObject() + { + return this.FetchRelatedObject(this.RelatedObject); + } + } +} diff --git a/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs b/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs index 63439a21d8..b4116a1c2c 100644 --- a/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs +++ b/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs @@ -344,7 +344,6 @@ public static class StripeTypeRegistry { "v2.billing.cadence.billed", typeof(Events.V2BillingCadenceBilledEvent) }, { "v2.billing.cadence.canceled", typeof(Events.V2BillingCadenceCanceledEvent) }, { "v2.billing.cadence.created", typeof(Events.V2BillingCadenceCreatedEvent) }, - { "v2.billing.cadence.errored", typeof(Events.V2BillingCadenceErroredEvent) }, { "v2.billing.license_fee.created", typeof( Events.V2BillingLicenseFeeCreatedEvent) @@ -538,6 +537,22 @@ public static class StripeTypeRegistry "v2.core.account_person.updated", typeof( Events.V2CoreAccountPersonUpdatedEvent) }, + { + "v2.core.claimable_sandbox.claimed", typeof( + Events.V2CoreClaimableSandboxClaimedEvent) + }, + { + "v2.core.claimable_sandbox.expired", typeof( + Events.V2CoreClaimableSandboxExpiredEvent) + }, + { + "v2.core.claimable_sandbox.expiring", typeof( + Events.V2CoreClaimableSandboxExpiringEvent) + }, + { + "v2.core.claimable_sandbox.sandbox_details_owner_account_updated", typeof( + Events.V2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent) + }, { "v2.core.event_destination.ping", typeof( Events.V2CoreEventDestinationPingEvent) @@ -814,10 +829,6 @@ public static class StripeTypeRegistry "v2.billing.cadence.created", typeof( Events.PushedV2BillingCadenceCreatedEvent) }, - { - "v2.billing.cadence.errored", typeof( - Events.PushedV2BillingCadenceErroredEvent) - }, { "v2.billing.license_fee.created", typeof( Events.PushedV2BillingLicenseFeeCreatedEvent) @@ -1017,6 +1028,22 @@ public static class StripeTypeRegistry "v2.core.account_person.updated", typeof( Events.PushedV2CoreAccountPersonUpdatedEvent) }, + { + "v2.core.claimable_sandbox.claimed", typeof( + Events.PushedV2CoreClaimableSandboxClaimedEvent) + }, + { + "v2.core.claimable_sandbox.expired", typeof( + Events.PushedV2CoreClaimableSandboxExpiredEvent) + }, + { + "v2.core.claimable_sandbox.expiring", typeof( + Events.PushedV2CoreClaimableSandboxExpiringEvent) + }, + { + "v2.core.claimable_sandbox.sandbox_details_owner_account_updated", typeof( + Events.PushedV2CoreClaimableSandboxSandboxDetailsOwnerAccountUpdatedEvent) + }, { "v2.core.event_destination.ping", typeof( Events.PushedV2CoreEventDestinationPingEvent) diff --git a/src/Stripe.net/Services/V2/Billing/Cadences/CadenceCreateBillingCycleMonthOptions.cs b/src/Stripe.net/Services/V2/Billing/Cadences/CadenceCreateBillingCycleMonthOptions.cs index d66b549930..fbc3a4abb4 100644 --- a/src/Stripe.net/Services/V2/Billing/Cadences/CadenceCreateBillingCycleMonthOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/Cadences/CadenceCreateBillingCycleMonthOptions.cs @@ -20,6 +20,18 @@ public class CadenceCreateBillingCycleMonthOptions : INestedOptions #endif public long? DayOfMonth { get; set; } + /// + /// The month to anchor the billing on for a type="month" billing cycle from 1-12. If not + /// provided, this will default to the month the cadence was created. This setting can only + /// be used for monthly billing cycles with interval_count of 2, 3, 4 or 6. All + /// occurrences will be calculated from month provided. + /// + [JsonProperty("month_of_year")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("month_of_year")] +#endif + public long? MonthOfYear { get; set; } + /// /// The time at which the billing cycle ends. This field is optional, and if not provided, /// it will default to the time at which the cadence was created in UTC timezone. diff --git a/src/Stripe.net/Services/V2/Billing/Intents/IntentCreateActionDeactivateEffectiveAtOptions.cs b/src/Stripe.net/Services/V2/Billing/Intents/IntentCreateActionDeactivateEffectiveAtOptions.cs index dd5c325d34..a40712ae82 100644 --- a/src/Stripe.net/Services/V2/Billing/Intents/IntentCreateActionDeactivateEffectiveAtOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/Intents/IntentCreateActionDeactivateEffectiveAtOptions.cs @@ -21,7 +21,8 @@ public class IntentCreateActionDeactivateEffectiveAtOptions : INestedOptions /// /// When the deactivate action will take effect. - /// One of: current_billing_period_start, on_reserve, or timestamp. + /// One of: current_billing_period_end, current_billing_period_start, + /// on_reserve, or timestamp. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Billing/MeterEventStreams/MeterEventStreamCreateOptions.cs b/src/Stripe.net/Services/V2/Billing/MeterEventStreams/MeterEventStreamCreateOptions.cs index e928d13fbd..8917d41b17 100644 --- a/src/Stripe.net/Services/V2/Billing/MeterEventStreams/MeterEventStreamCreateOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/MeterEventStreams/MeterEventStreamCreateOptions.cs @@ -10,7 +10,7 @@ namespace Stripe.V2.Billing public class MeterEventStreamCreateOptions : BaseOptions { /// - /// List of meter events to include in the request. + /// List of meter events to include in the request. Supports up to 100 events per request. /// [JsonProperty("events")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantOptions.cs b/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantOptions.cs index ad447c0264..f9a49f3ca7 100644 --- a/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantOptions.cs @@ -26,6 +26,16 @@ public class ServiceActionCreateCreditGrantOptions : INestedOptions #endif public ServiceActionCreateCreditGrantApplicabilityConfigOptions ApplicabilityConfig { get; set; } + /// + /// The category of the credit grant. + /// One of: paid, or promotional. + /// + [JsonProperty("category")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("category")] +#endif + public string Category { get; set; } + /// /// The expiry configuration for the credit grant. /// @@ -43,5 +53,15 @@ public class ServiceActionCreateCreditGrantOptions : INestedOptions [STJS.JsonPropertyName("name")] #endif public string Name { get; set; } + + /// + /// The desired priority for applying this credit grant. If not specified, it will be set to + /// the default value of 50. The highest priority is 0 and the lowest is 100. + /// + [JsonProperty("priority")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("priority")] +#endif + public long? Priority { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantPerTenantOptions.cs b/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantPerTenantOptions.cs index 112acd46da..9c13188319 100644 --- a/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantPerTenantOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/ServiceActions/ServiceActionCreateCreditGrantPerTenantOptions.cs @@ -26,6 +26,16 @@ public class ServiceActionCreateCreditGrantPerTenantOptions : INestedOptions #endif public ServiceActionCreateCreditGrantPerTenantApplicabilityConfigOptions ApplicabilityConfig { get; set; } + /// + /// The category of the credit grant. + /// One of: paid, or promotional. + /// + [JsonProperty("category")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("category")] +#endif + public string Category { get; set; } + /// /// The expiry configuration for the credit grant. /// @@ -52,5 +62,15 @@ public class ServiceActionCreateCreditGrantPerTenantOptions : INestedOptions [STJS.JsonPropertyName("name")] #endif public string Name { get; set; } + + /// + /// The desired priority for applying this credit grant. If not specified, it will be set to + /// the default value of 50. The highest priority is 0 and the lowest is 100. + /// + [JsonProperty("priority")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("priority")] +#endif + public long? Priority { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxGetOptions.cs b/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxGetOptions.cs new file mode 100644 index 0000000000..66f5a132ba --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxGetOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + public class ClaimableSandboxGetOptions : BaseOptions + { + } +} diff --git a/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxService.cs b/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxService.cs index 7ca9965791..06912aba8c 100644 --- a/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxService.cs +++ b/src/Stripe.net/Services/V2/Core/ClaimableSandboxes/ClaimableSandboxService.cs @@ -2,6 +2,7 @@ namespace Stripe.V2.Core { using System; + using System.Net; using System.Net.Http; using System.Threading; using System.Threading.Tasks; @@ -35,5 +36,25 @@ public virtual Task CreateAsync(ClaimableSandboxCreateOptions { return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/core/claimable_sandboxes", options, requestOptions, cancellationToken); } + + /// + /// Retrieves the details of a claimable sandbox that was previously been created. Supply + /// the unique claimable sandbox ID that was returned from your creation request, and Stripe + /// will return the corresponding sandbox information. + /// + public virtual ClaimableSandbox Get(string id, ClaimableSandboxGetOptions options = null, RequestOptions requestOptions = null) + { + return this.Request(BaseAddress.Api, HttpMethod.Get, $"/v2/core/claimable_sandboxes/{WebUtility.UrlEncode(id)}", options, requestOptions); + } + + /// + /// Retrieves the details of a claimable sandbox that was previously been created. Supply + /// the unique claimable sandbox ID that was returned from your creation request, and Stripe + /// will return the corresponding sandbox information. + /// + public virtual Task GetAsync(string id, ClaimableSandboxGetOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync(BaseAddress.Api, HttpMethod.Get, $"/v2/core/claimable_sandboxes/{WebUtility.UrlEncode(id)}", options, requestOptions, cancellationToken); + } } } diff --git a/src/StripeTests/Services/GeneratedExamplesTest.cs b/src/StripeTests/Services/GeneratedExamplesTest.cs index a24489ad5a..814f56bf96 100644 --- a/src/StripeTests/Services/GeneratedExamplesTest.cs +++ b/src/StripeTests/Services/GeneratedExamplesTest.cs @@ -6289,6 +6289,7 @@ public void TestV2BillingCadencePost() Month = new Stripe.V2.Billing.CadenceCreateBillingCycleMonthOptions { DayOfMonth = 1361669285, + MonthOfYear = 82933018, Time = new Stripe.V2.Billing.CadenceCreateBillingCycleMonthTimeOptions { Hour = 3208676, @@ -6613,7 +6614,7 @@ public void TestV2BillingIntentPost() Timestamp = DateTimeOffset.Parse( "1970-01-01T15:18:46.294Z") .UtcDateTime, - Type = "current_billing_period_start", + Type = "on_reserve", }, PricingPlanSubscriptionDetails = new Stripe.V2.Billing.IntentCreateActionDeactivatePricingPlanSubscriptionDetailsOptions { @@ -6903,10 +6904,7 @@ public void TestV2BillingLicenseFeePost2() "/v2/billing/license_fees/id_123", (HttpStatusCode)200, "{\"id\":\"obj_123\",\"object\":\"v2.billing.license_fee\",\"active\":true,\"created\":\"1970-01-12T21:42:34.472Z\",\"currency\":\"usd\",\"display_name\":\"display_name\",\"latest_version\":\"latest_version\",\"licensed_item\":{\"id\":\"obj_123\",\"object\":\"v2.billing.licensed_item\",\"created\":\"1970-01-12T21:42:34.472Z\",\"display_name\":\"display_name\",\"livemode\":true,\"lookup_key\":null,\"metadata\":null,\"tax_details\":null,\"unit_label\":null},\"live_version\":\"live_version\",\"livemode\":true,\"lookup_key\":null,\"metadata\":null,\"service_interval\":\"month\",\"service_interval_count\":1375336415,\"tax_behavior\":\"exclusive\",\"tiering_mode\":null,\"tiers\":[{\"flat_amount\":null,\"unit_amount\":null,\"up_to_decimal\":null,\"up_to_inf\":null}],\"transform_quantity\":null,\"unit_amount\":null}"); - var options = new Stripe.V2.Billing.LicenseFeeUpdateOptions - { - DisplayName = "display_name", - }; + var options = new Stripe.V2.Billing.LicenseFeeUpdateOptions(); var client = new StripeClient(this.Requestor); var service = client.V2.Billing.LicenseFees; Stripe.V2.Billing.LicenseFee licenseFee = service.Update( @@ -7409,7 +7407,7 @@ public void TestV2BillingPricingPlanSubscriptionGet() HttpMethod.Get, "/v2/billing/pricing_plan_subscriptions", (HttpStatusCode)200, - "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.billing.pricing_plan_subscription\",\"billing_cadence\":\"billing_cadence\",\"collection_status\":\"past_due\",\"collection_status_transitions\":{\"awaiting_customer_action_at\":null,\"current_at\":null,\"past_due_at\":null,\"paused_at\":null,\"unpaid_at\":null},\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"metadata\":null,\"pricing_plan\":\"pricing_plan\",\"pricing_plan_version\":\"pricing_plan_version\",\"servicing_status\":\"pending\",\"servicing_status_transitions\":{\"activated_at\":null,\"canceled_at\":null,\"paused_at\":null},\"test_clock\":null}],\"next_page_url\":null,\"previous_page_url\":null}"); + "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.billing.pricing_plan_subscription\",\"billing_cadence\":\"billing_cadence\",\"collection_status\":\"past_due\",\"collection_status_transitions\":{\"awaiting_customer_action_at\":null,\"current_at\":null,\"past_due_at\":null,\"paused_at\":null,\"unpaid_at\":null},\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"metadata\":null,\"pricing_plan\":\"pricing_plan\",\"pricing_plan_version\":\"pricing_plan_version\",\"servicing_status\":\"pending\",\"servicing_status_transitions\":{\"activated_at\":null,\"canceled_at\":null,\"paused_at\":null,\"will_activate_at\":null,\"will_cancel_at\":null},\"test_clock\":null}],\"next_page_url\":null,\"previous_page_url\":null}"); var client = new StripeClient(this.Requestor); var service = client.V2.Billing.PricingPlanSubscriptions; Stripe.V2.StripeList pricingPlanSubscriptions = service @@ -7426,7 +7424,7 @@ public void TestV2BillingPricingPlanSubscriptionGet2() HttpMethod.Get, "/v2/billing/pricing_plan_subscriptions/id_123", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.billing.pricing_plan_subscription\",\"billing_cadence\":\"billing_cadence\",\"collection_status\":\"past_due\",\"collection_status_transitions\":{\"awaiting_customer_action_at\":null,\"current_at\":null,\"past_due_at\":null,\"paused_at\":null,\"unpaid_at\":null},\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"metadata\":null,\"pricing_plan\":\"pricing_plan\",\"pricing_plan_version\":\"pricing_plan_version\",\"servicing_status\":\"pending\",\"servicing_status_transitions\":{\"activated_at\":null,\"canceled_at\":null,\"paused_at\":null},\"test_clock\":null}"); + "{\"id\":\"obj_123\",\"object\":\"v2.billing.pricing_plan_subscription\",\"billing_cadence\":\"billing_cadence\",\"collection_status\":\"past_due\",\"collection_status_transitions\":{\"awaiting_customer_action_at\":null,\"current_at\":null,\"past_due_at\":null,\"paused_at\":null,\"unpaid_at\":null},\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"metadata\":null,\"pricing_plan\":\"pricing_plan\",\"pricing_plan_version\":\"pricing_plan_version\",\"servicing_status\":\"pending\",\"servicing_status_transitions\":{\"activated_at\":null,\"canceled_at\":null,\"paused_at\":null,\"will_activate_at\":null,\"will_cancel_at\":null},\"test_clock\":null}"); var client = new StripeClient(this.Requestor); var service = client.V2.Billing.PricingPlanSubscriptions; Stripe.V2.Billing.PricingPlanSubscription pricingPlanSubscription = service @@ -8032,7 +8030,7 @@ public void TestV2CoreClaimableSandboxPost() HttpMethod.Post, "/v2/core/claimable_sandboxes", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.core.claimable_sandbox\",\"api_keys\":{\"mcp\":null,\"publishable\":\"publishable\",\"secret\":\"secret\"},\"claim_url\":\"claim_url\",\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"prefill\":{\"country\":\"af\",\"email\":\"email\",\"name\":\"name\"}}"); + "{\"id\":\"obj_123\",\"object\":\"v2.core.claimable_sandbox\",\"claim_url\":null,\"claimed_at\":null,\"created\":\"1970-01-12T21:42:34.472Z\",\"expires_at\":null,\"livemode\":true,\"prefill\":{\"country\":\"af\",\"email\":\"email\",\"name\":\"name\"},\"sandbox_details\":{\"account\":\"account\",\"api_keys\":null,\"owner_account\":null},\"status\":\"claimed\"}"); var options = new Stripe.V2.Core.ClaimableSandboxCreateOptions { EnableMcpAccess = true, @@ -8050,6 +8048,23 @@ public void TestV2CoreClaimableSandboxPost() this.AssertRequest(HttpMethod.Post, "/v2/core/claimable_sandboxes"); } + [Fact] + public void TestV2CoreClaimableSandboxGet() + { + this.StubRequest( + HttpMethod.Get, + "/v2/core/claimable_sandboxes/id_123", + (HttpStatusCode)200, + "{\"id\":\"obj_123\",\"object\":\"v2.core.claimable_sandbox\",\"claim_url\":null,\"claimed_at\":null,\"created\":\"1970-01-12T21:42:34.472Z\",\"expires_at\":null,\"livemode\":true,\"prefill\":{\"country\":\"af\",\"email\":\"email\",\"name\":\"name\"},\"sandbox_details\":{\"account\":\"account\",\"api_keys\":null,\"owner_account\":null},\"status\":\"claimed\"}"); + var client = new StripeClient(this.Requestor); + var service = client.V2.Core.ClaimableSandboxes; + Stripe.V2.Core.ClaimableSandbox claimableSandbox = service.Get( + "id_123"); + this.AssertRequest( + HttpMethod.Get, + "/v2/core/claimable_sandboxes/id_123"); + } + [Fact] public void TestV2CoreEventGet() {