I am trying to use the base Raids endpoint to enumerate all wings and encounters. The account specific endpoint that displays weekly clears is working correctly.
GW2Sharp is installed with version 1.7.2 via NuGet inside a BlishHud module.
try
{
Logger.Debug("Getting wings from the API.");
var apiData = await Gw2ApiManager.Gw2ApiClient.V2.Raids.AllAsync()
//... process raid wings
}
catch (Exception ex)
{
Logger.Debug(ex, "Failed to load ");
}
Returned Exception
Gw2Sharp.WebApi.Exceptions.NotFoundException: not found
at Gw2Sharp.WebApi.Middleware.ExceptionMiddleware.<>c__DisplayClass1_0.<<OnRequestAsync>g__ExecAsync|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.Middleware.RequestSplitterMiddleware.<>c__DisplayClass4_0.<<OnRequestAsync>g__ExecAsync|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.Middleware.CacheMiddleware.<RequestGetAsync>d__8.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.Caching.BaseCacheMethod.<>c__DisplayClass4_0.<<GetOrUpdateAsync>g__ExecAsync|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.Middleware.CacheMiddleware.<OnAllRequestAsync>d__6.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.Http.WebApiRequest.<ExecuteAsync>d__10`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Gw2Sharp.WebApi.V2.Clients.BaseEndpointBulkAllClient`2.<AllAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Soeed.RaidClears.RaidClearsModule.<QueryRaidWings>d__25.MoveNext() in Module.cs:line 139
I am trying to use the base Raids endpoint to enumerate all wings and encounters. The account specific endpoint that displays weekly clears is working correctly.
GW2Sharp is installed with version 1.7.2 via NuGet inside a BlishHud module.
Returned Exception
Potential Fix I think the issue is the endpoint path for this client is missing the pluralization. https://github.com/Archomeda/Gw2Sharp/blob/f8338e05ead17d3cdb5de55d308f060afe2134d4/Gw2Sharp/WebApi/V2/Clients/Raids/RaidsClient.cs#L9
[EndpointPath("raid")]
instead of being[EndpointPath("raids")]
to render the api urlhttps://api.guildwars2.com/v2/raids