generate service
The generate service command adds service components to an existing Apiand project.
Usage
apiand generate service <name> [options]Examples
Generate a service:
apiand generate service UserServiceBehaviors
-
DDD: Generates a service interface in the Application layer and a service implementation in the Infrastructure layer; DI is done automagically with theServiceattribute. -
Standalone: Creates both the service interface and implementation in the sameEntity/pathfolder (where ‘path’ is derived from the service name). For example, if the service name isUser.Auth, the files will be created in theEntity/Userfolder. -
SingleLayer: Same as Standalone - creates both interface and implementation files in theEntity/pathfolder based on the service name structure.