diff --git a/Automate/Speckle.Automate.Sdk/AutomationContext.cs b/Automate/Speckle.Automate.Sdk/AutomationContext.cs
index 5844df540a..bacf101565 100644
--- a/Automate/Speckle.Automate.Sdk/AutomationContext.cs
+++ b/Automate/Speckle.Automate.Sdk/AutomationContext.cs
@@ -3,6 +3,7 @@
using Speckle.Automate.Sdk.Schema;
using Speckle.Automate.Sdk.Schema.Triggers;
using Speckle.Core.Api;
+using Speckle.Core.Api.GraphQL.Models;
using Speckle.Core.Credentials;
using Speckle.Core.Logging;
using Speckle.Core.Models;
diff --git a/Automate/Speckle.Automate.Sdk/Speckle.Automate.Sdk.csproj b/Automate/Speckle.Automate.Sdk/Speckle.Automate.Sdk.csproj
index bbdb0d9a65..3b9b37c95e 100644
--- a/Automate/Speckle.Automate.Sdk/Speckle.Automate.Sdk.csproj
+++ b/Automate/Speckle.Automate.Sdk/Speckle.Automate.Sdk.csproj
@@ -13,7 +13,7 @@
true
- $(WarningsNotAsErrors);CS8618;
+ $(WarningsNotAsErrors);CS8618;CS0618;
diff --git a/Core/Core/Api/Exceptions.cs b/Core/Core/Api/Exceptions.cs
index 7d10bd9974..f100fd22c3 100644
--- a/Core/Core/Api/Exceptions.cs
+++ b/Core/Core/Api/Exceptions.cs
@@ -9,50 +9,55 @@ namespace Speckle.Core.Api;
///
/// Base class for GraphQL API exceptions
///
-public class SpeckleGraphQLException : SpeckleException
+public class SpeckleGraphQLException : SpeckleGraphQLException
{
- private readonly GraphQLRequest _request;
- public GraphQLResponse? Response { get; }
-
- public SpeckleGraphQLException(string message, GraphQLRequest request, GraphQLResponse? response)
- : base(message)
- {
- _request = request;
- Response = response;
- }
+ public new GraphQLResponse? Response => (GraphQLResponse?)base.Response;
- public SpeckleGraphQLException(string message, Exception inner, GraphQLRequest request, GraphQLResponse? response)
- : this(message, inner)
- {
- _request = request;
- Response = response;
- }
+ public SpeckleGraphQLException(
+ string message,
+ GraphQLRequest request,
+ GraphQLResponse? response,
+ Exception? innerException = null
+ )
+ : base(message, request, response, innerException) { }
public SpeckleGraphQLException() { }
- public SpeckleGraphQLException(string message)
+ public SpeckleGraphQLException(string? message)
: base(message) { }
- public SpeckleGraphQLException(string message, Exception innerException)
+ public SpeckleGraphQLException(string? message, Exception? innerException)
: base(message, innerException) { }
+}
+
+public class SpeckleGraphQLException : SpeckleException
+{
+ private readonly GraphQLRequest _request;
+ public IGraphQLResponse? Response { get; }
public IEnumerable ErrorMessages =>
Response?.Errors != null ? Response.Errors.Select(e => e.Message) : Enumerable.Empty();
public IDictionary? Extensions => Response?.Extensions;
-}
-public class SpeckleGraphQLException : SpeckleGraphQLException