Skip to content

Commit

Permalink
Merge upstream and update generated code for v712
Browse files Browse the repository at this point in the history
  • Loading branch information
stripe-openapi[bot] committed Dec 14, 2023
2 parents 2bec2ea + 777a599 commit 94efa9a
Show file tree
Hide file tree
Showing 16 changed files with 86 additions and 13 deletions.
17 changes: 15 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ jobs:
3.1.x
5.0.x
6.0.x
7.0.307
7.0.404
8.0.x
- name: Install tools
run: |
Expand Down Expand Up @@ -97,6 +98,18 @@ jobs:
name: nuget
path: nuget/

compat:
name: Compat
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 8.0.x
- name: Run backcompat check
run: dotnet pack src/Stripe.net -p:RunBaselineCheck=true

publish:
name: Publish
if: (((github.event_name == 'push') || (github.event_name == 'workflow_dispatch')) && startsWith(github.ref, 'refs/tags/v') && endsWith(github.actor, '-stripe'))
Expand All @@ -111,7 +124,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x
dotnet-version: 8.0.x
- name: Publish NuGet packages to NuGet
run: dotnet nuget push nuget/*.nupkg --api-key ${{ secrets.NUGET_KEY }} --source "nuget.org"
- uses: stripe/openapi/actions/notify-release@master
Expand Down
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v709
v712
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"projects": [ "src" ],
"sdk": {
"version": "7.0.100",
"version": "8.0.100",
"rollForward": "latestFeature"
}
}
2 changes: 1 addition & 1 deletion src/Stripe.net/Constants/ApiVersion.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ namespace Stripe
internal class ApiVersion
{
public const string Current = "2023-10-16";
public const string CurrentPreview = "2023-10-26.preview-v2";
public const string CurrentPreview = "2023-12-11.preview-v2";
}
}
2 changes: 2 additions & 0 deletions src/Stripe.net/Entities/PaymentIntents/PaymentIntent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ public Application Application
public string ClientSecret { get; set; }

/// <summary>
/// Describes whether we can confirm this PaymentIntent automatically, or if it requires
/// customer action to confirm the payment.
/// One of: <c>automatic</c>, or <c>manual</c>.
/// </summary>
[JsonProperty("confirmation_method")]
Expand Down
7 changes: 7 additions & 0 deletions src/Stripe.net/Services/Balances/BalanceGetOptions.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// File generated from our OpenAPI spec
namespace Stripe
{
public class BalanceGetOptions : BaseOptions
{
}
}
14 changes: 12 additions & 2 deletions src/Stripe.net/Services/Balances/BalanceService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ public BalanceService(IStripeClient client)
{
}

public override string BasePath => "/v1/balance";

protected override string InstanceUrl(string id)
{
return this.ClassUrl();
}

public override string BasePath => "/v1/balance";

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Balances/BalanceService.cs

View workflow job for this annotation

GitHub Actions / Build and test


public virtual Balance Get(RequestOptions requestOptions = null)
{
return this.Request<Balance>(HttpMethod.Get, $"/v1/balance", null, requestOptions);
Expand All @@ -34,5 +34,15 @@ public virtual Task<Balance> GetAsync(RequestOptions requestOptions = null, Canc
{
return this.RequestAsync<Balance>(HttpMethod.Get, $"/v1/balance", null, requestOptions, cancellationToken);
}

public virtual Balance Get(BalanceGetOptions options, RequestOptions requestOptions = null)
{
return this.Request<Balance>(HttpMethod.Get, $"/v1/balance", options, requestOptions);
}

public virtual Task<Balance> GetAsync(BalanceGetOptions options, RequestOptions requestOptions = null, CancellationToken cancellationToken = default)
{
return this.RequestAsync<Balance>(HttpMethod.Get, $"/v1/balance", options, requestOptions, cancellationToken);
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// File generated from our OpenAPI spec
namespace Stripe.Capital
{
public class FinancingSummaryGetOptions : BaseOptions
{
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ public FinancingSummaryService(IStripeClient client)
{
}

public override string BasePath => "/v1/capital/financing_summary";

protected override string InstanceUrl(string id)
{
return this.ClassUrl();
}

public override string BasePath => "/v1/capital/financing_summary";

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Capital/FinancingSummaries/FinancingSummaryService.cs

View workflow job for this annotation

GitHub Actions / Build and test


public virtual FinancingSummary Get(RequestOptions requestOptions = null)
{
return this.Request<FinancingSummary>(HttpMethod.Get, $"/v1/capital/financing_summary", null, requestOptions);
Expand All @@ -34,5 +34,15 @@ public virtual Task<FinancingSummary> GetAsync(RequestOptions requestOptions = n
{
return this.RequestAsync<FinancingSummary>(HttpMethod.Get, $"/v1/capital/financing_summary", null, requestOptions, cancellationToken);
}

public virtual FinancingSummary Get(FinancingSummaryGetOptions options, RequestOptions requestOptions = null)
{
return this.Request<FinancingSummary>(HttpMethod.Get, $"/v1/capital/financing_summary", options, requestOptions);
}

public virtual Task<FinancingSummary> GetAsync(FinancingSummaryGetOptions options, RequestOptions requestOptions = null, CancellationToken cancellationToken = default)
{
return this.RequestAsync<FinancingSummary>(HttpMethod.Get, $"/v1/capital/financing_summary", options, requestOptions, cancellationToken);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ public class PaymentIntentCreateOptions : BaseOptions, IHasMetadata
public bool? Confirm { get; set; }

/// <summary>
/// Describes whether we can confirm this PaymentIntent automatically, or if it requires
/// customer action to confirm the payment.
/// One of: <c>automatic</c>, or <c>manual</c>.
/// </summary>
[JsonProperty("confirmation_method")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ namespace Stripe.Radar
{
using Newtonsoft.Json;

public class EarlyFraudWarningListOptions : ListOptions
public class EarlyFraudWarningListOptions : ListOptionsWithCreated
{
/// <summary>
/// Only return early fraud warnings for the charge specified by this charge ID.
Expand Down
7 changes: 7 additions & 0 deletions src/Stripe.net/Services/Tax/Settings/SettingsGetOptions.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// File generated from our OpenAPI spec
namespace Stripe.Tax
{
public class SettingsGetOptions : BaseOptions
{
}
}
14 changes: 12 additions & 2 deletions src/Stripe.net/Services/Tax/Settings/SettingsService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ public SettingsService(IStripeClient client)
{
}

public override string BasePath => "/v1/tax/settings";

protected override string InstanceUrl(string id)
{
return this.ClassUrl();
}

public override string BasePath => "/v1/tax/settings";

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Compat

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Build and test

Check failure on line 26 in src/Stripe.net/Services/Tax/Settings/SettingsService.cs

View workflow job for this annotation

GitHub Actions / Build and test


public virtual Settings Get(RequestOptions requestOptions = null)
{
return this.Request<Settings>(HttpMethod.Get, $"/v1/tax/settings", null, requestOptions);
Expand All @@ -35,6 +35,16 @@ public virtual Task<Settings> GetAsync(RequestOptions requestOptions = null, Can
return this.RequestAsync<Settings>(HttpMethod.Get, $"/v1/tax/settings", null, requestOptions, cancellationToken);
}

public virtual Settings Get(SettingsGetOptions options, RequestOptions requestOptions = null)
{
return this.Request<Settings>(HttpMethod.Get, $"/v1/tax/settings", options, requestOptions);
}

public virtual Task<Settings> GetAsync(SettingsGetOptions options, RequestOptions requestOptions = null, CancellationToken cancellationToken = default)
{
return this.RequestAsync<Settings>(HttpMethod.Get, $"/v1/tax/settings", options, requestOptions, cancellationToken);
}

public virtual Settings Update(SettingsUpdateOptions options, RequestOptions requestOptions = null)
{
return this.Request<Settings>(HttpMethod.Post, $"/v1/tax/settings", options, requestOptions);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ public class AuthorizationCreateOptions : BaseOptions
{
/// <summary>
/// The total amount to attempt to authorize. This amount is in the provided currency, or
/// defaults to the cards currency, and in the <a
/// defaults to the card's currency, and in the <a
/// href="https://stripe.com/docs/currencies#zero-decimal">smallest currency unit</a>.
/// </summary>
[JsonProperty("amount")]
Expand Down
4 changes: 4 additions & 0 deletions src/Stripe.net/Stripe.net.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<DebugType>embedded</DebugType>
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<EnablePackageValidation>true</EnablePackageValidation>
<PackageValidationBaselineVersion Condition="'$(RunBaselineCheck)' == 'true'">$(Version)</PackageValidationBaselineVersion>
<NuGetAudit>false</NuGetAudit>
</PropertyGroup>

<ItemGroup>
Expand Down Expand Up @@ -73,4 +76,5 @@
<None Include="..\..\LICENSE" Pack="true" PackagePath="" />
<None Include="icon.png" Pack="true" Visible="false" PackagePath="" />
</ItemGroup>

</Project>
1 change: 1 addition & 0 deletions src/StripeTests/StripeTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<LangVersion>8</LangVersion>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<NuGetAudit>false</NuGetAudit>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit 94efa9a

Please sign in to comment.