Marcos Lommez
Marcos Lommez

Reputation: 136

How to configure Dynamic WebAPI in AspNetCore

How can I configure the dynamic WebAPI in aspnetcore version of abp?

Configuration.Modules.AbpWebApi()

The method AbpWebApi doesn't exists.

Do I need to install an extra nuget package?

Upvotes: 0

Views: 1140

Answers (4)

PowerMan2015
PowerMan2015

Reputation: 1418

Ive just run into the same thing.

Ive not got everything up and running however there seems to be a number of nuget packages to install which isnt made particulary clear in the help documentation.

I have just installed the "AbpAspNetCore" package to the application layer

The same is true for the .Net version except the package name is "Abp.Web.Api"

Installing the required package will enable to to access the AbpAspNetCore method

Upvotes: 0

dantey89
dantey89

Reputation: 2287

I spend about 4 hours trying to find AbpAspNetCore() method. Finally I came up with decorating methods and classes with [RemoteService(isEnabled:false)] attribute

Upvotes: 0

Alper Ebicoglu
Alper Ebicoglu

Reputation: 9624

in PreInitialize method of your abp module add this line;

Configuration.Modules.AbpAspNetCore().CreateControllersForAppServices(typeof(MyApplicationModule).Assembly, moduleName: 'app', useConventionalHttpVerbs: true);

Upvotes: 1

hikalkan
hikalkan

Reputation: 2282

It's different for AspNet Core. See documentation: https://aspnetboilerplate.com/Pages/Documents/AspNet-Core#application-services-as-controllers

Upvotes: 1

Related Questions