Base solution for your next web application
Open Closed

How use Client Api generate by NSwagStudio doesn't work #11656


User avatar
0
martp00 created

So basically using NSwagStudio or Unchase openAPI to generate a c# client api work. But when using it, the return data are null. I see some thread telling to deactivate the wrapresult in PreInitialize() of Core WebCoreModule.cs

Like this:

Configuration.Modules.AbpAspNetCore().DefaultWrapResultAttribute.WrapOnError = false;
Configuration.Modules.AbpAspNetCore().DefaultWrapResultAttribute.WrapOnSuccess = false;

So doing this, make the client api working but, all the website is not working anymore.

Trying to change any data making display the general error box.

Using ASP.NET CORE MVC & jQuery v12.2.0


3 Answer(s)