Open Closed

Generate-proxy issue with module startup template, "apiName = 'Default'" issue. #1904


User avatar
0
pontus created
  • ABP Framework version: v4.4.2
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): Angular
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

Using the latest CLI:

abp new Abc.Bookstore -t module -ui angular

I've run the migrations and the identity and host service starts up fine.

I've commented out the redis configuration and removed the DependsOn[typeof(AbpCachingStackExchangeRedisModule))] since we do not want to use Redis.

The angular project is working fine and running the dev-app.

The start-up generated component and the start-up generated service is working fine, I'm able to call the backend.

However if i try run the generate-proxy command, get an error, and it complains that the backend module 'app' does not exists in the API definition. This is fine since i can add the -a command and point to the Bookstore api-address and generate my proxys.

But!

The generated service file gets generated with the apiName = 'Default' which screws things up.

If i change it to apiName = 'Bookstore' things work.

I think it's as simple as changing the generated code to match the value given for the -a flag.

Markdown supported.
Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)

1 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    You're right. We already change it to module name in 5.0

    https://github.com/abpframework/abp/blob/dev/templates/module/aspnet-core/src/MyCompanyName.MyProjectName.HttpApi/Samples/SampleController.cs#L8

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on September 21, 2026, 06:18
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.