Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: 🐝 Update SDK - Generate #10

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,18 @@ id: f1a8c321-72a7-41c5-8f5e-3d925aeafa1a
management:
docChecksum: 2401c7030f847f72ab31c8f75de58a66
docVersion: 0.2.0
speakeasyVersion: 1.231.1
generationVersion: 2.295.1
releaseVersion: 0.3.0
configChecksum: 63ca38beda4ee137c4037339b326841e
speakeasyVersion: 1.252.0
generationVersion: 2.306.0
releaseVersion: 0.4.0
configChecksum: 5fd66a1ee274467aa4e0bf8a7953ef25
repoURL: https://github.com/StyraInc/opa-csharp.git
features:
csharp:
core: 3.6.0
core: 3.7.0
examples: 2.81.3
flattening: 2.81.1
globalServerURLs: 2.82.3
responseFormat: 0.0.1
unions: 0.0.2
generatedFiles:
- Api/Opa.cs
Expand Down
4 changes: 3 additions & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ generation:
auth:
oAuth2ClientCredentialsEnabled: false
csharp:
version: 0.3.0
version: 0.4.0
author: Styra
clientServerStatusCodesAsErrors: true
company: ""
disableNamespacePascalCasingApr2024: false
dotnetVersion: net6.0
flattenGlobalSecurity: true
imports:
Expand All @@ -31,3 +32,4 @@ csharp:
outputModelSuffix: output
packageName: api
product: ""
responseFormat: envelope
2 changes: 1 addition & 1 deletion Api/Api.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<PropertyGroup>
<IsPackable>true</IsPackable>
<PackageId>Api</PackageId>
<Version>0.3.0</Version>
<Version>0.4.0</Version>
<Authors>Styra</Authors>
<TargetFramework>net6.0</TargetFramework>
<Nullable>enable</Nullable>
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/Explain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Components
{
using Api.Utils;
using Newtonsoft.Json;
using System;

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/GzipAcceptEncoding.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Components
{
using Api.Utils;
using Newtonsoft.Json;
using System;

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/GzipContentEncoding.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Components
{
using Api.Utils;
using Newtonsoft.Json;
using System;

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/HealthyServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Components
{
using Api.Utils;

public class HealthyServer
{
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/Provenance.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Components
{
using Api.Models.Components;
using Api.Utils;
using Newtonsoft.Json;
using System.Collections.Generic;
using System;
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/Revision.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Components
{
using Api.Utils;
using Newtonsoft.Json;

public class Revision
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Components/SuccessfulPolicyEvaluation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Components
{
using Api.Models.Components;
using Api.Utils;
using Newtonsoft.Json;
using System.Collections.Generic;

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/ClientError.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Errors
{
using Api.Models.Errors;
using Api.Utils;
using Newtonsoft.Json;
using System.Collections.Generic;
using System;
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/Errors.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Errors
{
using Api.Models.Errors;
using Api.Utils;
using Newtonsoft.Json;

public class Errors
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/Location.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Errors
{
using Api.Utils;
using Newtonsoft.Json;

public class Location
Expand Down
6 changes: 2 additions & 4 deletions Api/Models/Errors/SDKException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,15 @@ namespace Api.Models.Errors

public class SDKException : Exception
{
public int StatusCode { get; set; }

public override string Message { get; }
public int StatusCode { get; set; }
public string Body { get; set; }

public HttpResponseMessage RawResponse { get; set; } = default!;

public SDKException(string message, int statusCode, string body, HttpResponseMessage rawResponse)
{
Message = message;
this.StatusCode = statusCode;
StatusCode = statusCode;
Body = body;
RawResponse = rawResponse;
Expand All @@ -36,7 +35,6 @@ public override string ToString(){
{
body += $"\n{Body}";
}

return Message + ": Status " + StatusCode + body;
}

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/ServerError.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Errors
{
using Api.Models.Errors;
using Api.Utils;
using Newtonsoft.Json;
using System.Collections.Generic;
using System;
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/ServerErrorErrors.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Errors
{
using Api.Models.Errors;
using Api.Utils;
using Newtonsoft.Json;

public class ServerErrorErrors
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/ServerErrorLocation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Errors
{
using Api.Utils;
using Newtonsoft.Json;

public class ServerErrorLocation
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Errors/UnhealthyServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#nullable enable
namespace Api.Models.Errors
{
using Api.Utils;
using Newtonsoft.Json;
using System;

Expand Down
1 change: 1 addition & 0 deletions Api/Models/Requests/ExecutePolicyResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Requests
{
using Api.Models.Components;
using Api.Utils;
using System.Collections.Generic;
using System.Net.Http;
using System;
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Requests/ExecutePolicyWithInputRequestBody.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Requests
{
using Api.Models.Components;
using Api.Utils;
using Newtonsoft.Json;

/// <summary>
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Requests/ExecutePolicyWithInputResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Requests
{
using Api.Models.Components;
using Api.Utils;
using System.Collections.Generic;
using System.Net.Http;
using System;
Expand Down
1 change: 1 addition & 0 deletions Api/Models/Requests/HealthResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
namespace Api.Models.Requests
{
using Api.Models.Components;
using Api.Utils;
using System.Net.Http;
using System;

Expand Down
Loading