| name | create-abp-io-template |
| description | Create a new ABP.IO project using CLI commands with proper template selection, configuration, and setup. Supports all ABP templates including layered, single-layer, microservice, and modular architectures. |
Create ABP.IO Template
Create a new ABP.IO project using the ABP CLI with proper template selection, configuration, and initial setup.
Primary Directive
Your goal is to create a new ABP.IO project using the CLI with the appropriate template, configuration, and setup based on the specified requirements.
ABP CLI Installation
Install ABP CLI
dotnet tool install -g Volo.Abp.Cli
abp --version
abp update
Alternative Installation Methods
dotnet tool install -g Volo.Abp.Cli --version 8.0.0
dotnet tool install -g Volo.Abp.Cli --add-source ./local-packages
Available Templates
1. Application Template (app)
Standard layered application for most scenarios.
Use Cases:
- Medium to large applications
- Multiple developers or teams
- Long-term maintainability required
- Complex business domains
Command:
abp new <solution-name> -t app [options]
2. Single-Layer Template (app-nolayers)
Simplified template for small applications.
Use Cases:
- Small project with simple requirements
- 1-3 developers team
- Temporary or POC projects
- No expected growth in complexity
Command:
abp new <solution-name> -t app-nolayers [options]
3. Microservice Template (microservice)
For distributed microservice architectures.
Use Cases:
- Very large distributed systems
- Independent deployment needed
- Multiple technology stacks
- High scalability requirements
Command:
abp new <solution-name> -t microservice [options]
4. Empty Template (empty)
Minimal template for custom solutions.
Use Cases:
- Custom architecture requirements
- Learning ABP framework
- Minimal starting point
Command:
abp new <solution-name> -t empty [options]
Configuration Options
UI Framework Options (-u, --ui-framework)
mvc: ASP.NET Core MVC (default)
angular: Angular SPA
blazor-webapp: Blazor Web App
blazor: Blazor Server
blazor-server: Blazor Server
no-ui: No UI layer
Database Provider Options (-d, --database-provider)
ef: Entity Framework Core (default)
mongodb: MongoDB
Mobile Options (-m, --mobile)
none: No mobile app (default)
react-native: React Native
maui: .NET MAUI
Architecture Options
--tiered: Creates tiered architecture (separate API and UI layers)
--separate-tenant-schema: Different DbContext for tenant schema
Theme Options (-th, --theme)
leptonx: LeptonX Theme (premium)
leptonx-lite: LeptonX-Lite Theme (default)
basic: Basic Theme
Additional Options
--connection-string: Custom database connection string
--skip-migrations: Skip initial database migration
--skip-migrator: Skip database migrator
--public-website: Add public website (PRO)
--without-cms-kit: Exclude CmsKit module
--sample-crud-page: Add sample CRUD page
--use-open-source-template: Use open-source template
Template Selection Guide
Decision Tree
1. Project Size & Complexity
- Small/Simple → Single-Layer
- Medium/Complex → Layered
- Large/Distributed → Microservice
2. Team Size
- 1-3 developers → Single-Layer
- 4+ developers → Layered
- Multiple teams → Microservice
3. UI Requirements
- Web only → MVC
- SPA experience → Angular
- Modern web → Blazor
- No UI needed → no-ui
4. Database Needs
- Relational → EF Core
- Document → MongoDB
Common Template Commands
Standard Web Application
abp new Acme.BookStore
abp new Acme.BookStore -t app -u mvc -d ef -th leptonx-lite
abp new Acme.BookStore -t app -u mvc -d ef --connection-string "Server=localhost;Database=BookStore;Trusted_Connection=true"
Angular SPA Application
abp new Acme.BookStore -t app -u angular -d ef
abp new Acme.BookStore -t app -u angular -d ef --tiered
abp new Acme.BookStore -t app -u angular -d ef --progressive-web-app
Blazor Application
abp new Acme.BookStore -t app -u blazor-webapp -d ef
abp new Acme.BookStore -t app -u blazor-server -d ef
abp new Acme.BookStore -t app -u blazor-webapp -d ef --tiered
Microservice Solution
abp new Acme.Microservice -t microservice -u mvc -d ef
abp new Acme.Microservice -t microservice -u angular -d ef
abp new Acme.Microservice -t microservice -u mvc -d ef --tiered
Simple API Project
abp new Acme.Api -t app-nolayers -u no-ui -d ef
abp new Acme.Api -t app-nolayers -u no-ui -d ef --sample-crud-page
Implementation Workflow
Step 1: CLI Preparation
abp --version
abp update
abp list-templates
Step 2: Project Creation
abp new <solution-name> [options]
abp new Acme.BookStore -t app -u mvc -d ef -th leptonx-lite
Step 3: Initial Setup
cd <solution-name>
dotnet restore
dotnet ef database update
dotnet run --project src/<solution-name>.Web
Step 4: Verification
dotnet build
dotnet test
Project Structure Examples
Layered Application Structure
Acme.BookStore.sln
├── src/
│ ├── Acme.BookStore.Application/
│ │ ├── BookStoreApplicationModule.cs
│ │ ├── Books/
│ │ │ ├── BookAppService.cs
│ │ │ └── IBookAppService.cs
│ │ └── Acme.BookStore.Application.csproj
│ ├── Acme.BookStore.Application.Contracts/
│ │ ├── Books/
│ │ │ ├── BookDto.cs
│ │ │ └── IBookAppService.cs
│ │ └── Acme.BookStore.Application.Contracts.csproj
│ ├── Acme.BookStore.Domain/
│ │ ├── BookStoreDomainModule.cs
│ │ ├── Books/
│ │ │ ├── Book.cs
│ │ │ └── IBookRepository.cs
│ │ └── Acme.BookStore.Domain.csproj
│ ├── Acme.BookStore.Domain.Shared/
│ │ ├── BookStoreDomainSharedModule.cs
│ │ └── Acme.BookStore.Domain.Shared.csproj
│ ├── Acme.BookStore.EntityFrameworkCore/
│ │ ├── BookStoreEntityFrameworkCoreModule.cs
│ │ ├── BookStoreDbContext.cs
│ │ ├── Configurations/
│ │ │ └── BookConfiguration.cs
│ │ └── Acme.BookStore.EntityFrameworkCore.csproj
│ ├── Acme.BookStore.HttpApi/
│ │ ├── BookStoreHttpApiModule.cs
│ │ ├── Controllers/
│ │ │ └── BooksController.cs
│ │ └── Acme.BookStore.HttpApi.csproj
│ ├── Acme.BookStore.HttpApi.Client/
│ │ └── Acme.BookStore.HttpApi.Client.csproj
│ ├── Acme.BookStore.Web/
│ │ ├── BookStoreWebModule.cs
│ │ ├── Pages/
│ │ ├── wwwroot/
│ │ └── Acme.BookStore.Web.csproj
│ └── Acme.BookStore.Web.Unified/
├── test/
│ ├── Acme.BookStore.Application.Tests/
│ ├── Acme.BookStore.Domain.Tests/
│ ├── Acme.BookStore.EntityFrameworkCore.Tests/
│ ├── Acme.BookStore.Web.Tests/
│ └── Acme.BookStore.HttpApi.Host.Tests/
└── etc/
└── docker-compose.yml
Single-Layer Application Structure
Acme.SimpleApp.sln
├── src/
│ ├── Acme.SimpleApp.Application/
│ │ ├── SimpleAppApplicationModule.cs
│ │ ├── Books/
│ │ │ ├── BookAppService.cs
│ │ │ └── Book.cs
│ │ └── Acme.SimpleApp.Application.csproj
│ ├── Acme.SimpleApp.Application.Contracts/
│ │ └── Acme.SimpleApp.Application.Contracts.csproj
│ ├── Acme.SimpleApp.Domain.Shared/
│ │ └── Acme.SimpleApp.Domain.Shared.csproj
│ ├── Acme.SimpleApp.EntityFrameworkCore/
│ │ ├── SimpleAppDbContext.cs
│ │ └── Acme.SimpleApp.EntityFrameworkCore.csproj
│ ├── Acme.SimpleApp.HttpApi/
│ │ └── Acme.SimpleApp.HttpApi.csproj
│ └── Acme.SimpleApp.Web/
│ ├── Program.cs
│ ├── Pages/
│ └── Acme.SimpleApp.Web.csproj
└── test/
├── Acme.SimpleApp.Application.Tests/
├── Acme.SimpleApp.EntityFrameworkCore.Tests/
└── Acme.SimpleApp.Web.Tests/
Advanced Configuration
Database Provider Configuration
SQL Server (Default)
abp new Acme.BookStore -t app -u mvc -d ef
PostgreSQL
abp new Acme.BookStore -t app -u mvc -d ef
SQLite
abp new Acme.BookStore -t app -u mvc -d ef
MongoDB
abp new Acme.BookStore -t app -u mvc -d mongodb
Authentication Configuration
Built-in Authentication
abp new Acme.BookStore -t app -u mvc -d ef
Custom Authentication
abp new Acme.BookStore -t app -u mvc -d ef
Multi-Tenancy Configuration
Shared Database
abp new Acme.BookStore -t app -u mvc -d ef
Separate Tenant Schema
abp new Acme.BookStore -t app -u mvc -d ef --separate-tenant-schema
Post-Creation Customization
1. Package Management
abp add-package Volo.Abp.Emailing
abp add-package Volo.Abp.Sms
abp add-package Volo.Abp.Caching
abp add-module Volo.CmsKit
2. Configuration Updates
{
"ConnectionStrings": {
"Default": "Server=localhost;Database=AcmeBookStore;Trusted_Connection=true"
},
"App": {
"SelfUrl": "https://localhost:44300",
"CorsOrigins": "https://localhost:44300"
},
"AuthServer": {
"Authority": "https://localhost:44300",
"RequireHttpsMetadata": "false"
},
"StringLocalizations": {
"Languages": [
{
"CultureName": "en",
"DisplayName": "English"
},
{
"CultureName": "pt-BR",
"DisplayName": "Português"
}
]
}
}
3. Database Configuration
dotnet ef migrations add InitialCreate
dotnet ef database update
dotnet ef migrations add AddedBookEntity
4. First Entity Creation
public class Book : FullAuditedAggregateRoot<Guid>
{
public string Name { get; set; }
public BookType Type { get; set; }
public DateTime PublishDate { get; set; }
public float Price { get; set; }
protected Book() { }
public Book(
Guid id,
string name,
BookType type,
DateTime publishDate,
float price) : base(id)
{
Name = Check.NotNullOrWhiteSpace(name, nameof(name));
Type = type;
PublishDate = publishDate;
Price = price;
}
}
5. Application Service
public class BookAppService : ApplicationService, IBookAppService
{
private readonly IRepository<Book, Guid> _bookRepository;
public BookAppService(IRepository<Book, Guid> bookRepository)
{
_bookRepository = bookRepository;
}
public async Task<PagedResultDto<BookDto>> GetListAsync(GetBooksInput input)
{
var queryable = await _bookRepository.GetQueryableAsync();
var books = await AsyncExecuter.ToListAsync(
queryable
.WhereIf(!input.Filter.IsNullOrWhiteSpace(),
book => book.Name.Contains(input.Filter))
.OrderBy(book => book.Name)
.PageBy(input.SkipCount, input.MaxResultCount)
);
var totalCount = await AsyncExecuter.CountAsync(
queryable.WhereIf(!input.Filter.IsNullOrWhiteSpace(),
book => book.Name.Contains(input.Filter))
);
return new PagedResultDto<BookDto>(
totalCount,
ObjectMapper.Map<List<Book>, List<BookDto>>(books)
);
}
}
Development Tools Integration
ABP Suite Integration
ABP Studio Integration
Docker Support
docker build -t acme/bookstore .
docker-compose up -d
docker-compose exec web dotnet ef database update
Troubleshooting
Common Issues and Solutions
1. CLI Not Found
dotnet tool install -g Volo.Abp.Cli
echo $PATH
dotnet tool uninstall -g Volo.Abp.Cli
dotnet tool install -g Volo.Abp.Cli
2. Template Creation Fails
dotnet --version
dotnet nuget locals all --clear
abp new Acme.BookStore -t app --use-open-source-template
3. Database Issues
dotnet ef database update --verbose
dotnet ef database drop
dotnet ef database update
dotnet ef migrations list
4. Build Errors
dotnet clean
dotnet restore
dotnet build
dotnet list package --outdated
Validation Checklist
Pre-Development Validation
Development Readiness
Best Practices
Template Selection
- Choose the simplest template that meets requirements
- Consider future growth and scalability
- Factor in team expertise and experience
- Plan for multi-tenancy if needed
Configuration Management
- Use environment-specific configuration files
- Store sensitive data in user secrets
- Leverage ABP's setting system
- Implement proper logging
Development Workflow
- Use ABP CLI for all project operations
- Follow ABP conventions and patterns
- Implement proper unit tests
- Use version control from the start
Performance Optimization
- Choose appropriate database provider
- Implement proper caching strategies
- Use async operations consistently
- Monitor application performance
This skill provides comprehensive guidance for creating ABP.IO projects using the CLI with the right template and configuration for your specific needs.