{"record":{"id":"17633c64419527aa","repo":"abpframework/abp","slug":"error-modulename-module-could-not-be-found","errorCode":null,"errorMessage":"ERROR: '{moduleName}' module could not be found!","messagePattern":"ERROR: '(.+?)' module could not be found!","errorType":"exception","errorClass":"CliUsageException","httpStatus":null,"severity":"error","filePath":"framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectModification/SolutionModuleAdder.cs","lineNumber":790,"sourceCode":"\n    protected virtual async Task<ModuleWithMastersInfo> GetModuleInfoAsync(string moduleName, bool newTemplate,\n        bool newProTemplate = false)\n    {\n        if (newTemplate || newProTemplate)\n        {\n            return GetEmptyModuleProjectInfo(moduleName, newProTemplate);\n        }\n\n        var url = $\"{CliUrls.WwwAbpIo}api/app/module/byNameWithDetails/?name=\" + moduleName;\n        var client = _cliHttpClientFactory.CreateClient();\n\n        using (var response = await client.GetAsync(url, _cliHttpClientFactory.GetCancellationToken()))\n        {\n            if (!response.IsSuccessStatusCode)\n            {\n                if (response.StatusCode == HttpStatusCode.NotFound)\n                {\n                    throw new CliUsageException($\"ERROR: '{moduleName}' module could not be found!\");\n                }\n\n                await RemoteServiceExceptionHandler.EnsureSuccessfulHttpResponseAsync(response);\n            }\n\n            var responseContent = await response.Content.ReadAsStringAsync();\n            return JsonSerializer.Deserialize<ModuleWithMastersInfo>(responseContent);\n        }\n    }\n\n    private ModuleWithMastersInfo GetEmptyModuleProjectInfo(string moduleName,\n        bool newProTemplate = false)\n    {\n        var module = new ModuleWithMastersInfo\n        {\n            Name = moduleName,\n            DisplayName = moduleName,\n            MasterModuleInfos = new List<ModuleWithMastersInfo>()","sourceCodeStart":772,"sourceCodeEnd":808,"githubUrl":"https://github.com/abpframework/abp/blob/7ed43b1931b9df46a50c0c59148a18645641d0df/framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectModification/SolutionModuleAdder.cs#L772-L808","documentation":"SolutionModuleAdder.FindModuleInfoAsync GETs www.abp.io/api/app/module/byNameWithDetails/?name=<moduleName> and throws a CliUsageException on 404 NotFound when the module is not in the catalog (after the newProTemplate early-return path is skipped). The message is prefixed 'ERROR: ' and names the missing module.","triggerScenarios":"Running 'abp add-module <name>' with a module name the server does not recognise; passing a Pro module name while not licensed (so the catalog rejects it); typo in the module identifier.","commonSituations":"Misspelled module name (e.g. 'Bloging' vs 'Blogging'); requesting a Pro module without a license; module renamed or merged in a newer ABP version; mismatch between CLI version and server-side catalog.","solutions":["Verify the exact module name in ABP docs (e.g. 'Blogging', 'IdentityServer', 'AuditLogging') and re-run.","For commercial modules, ensure you are logged in with a licensed account ('abp login').","Upgrade the ABP CLI so the catalog query matches the current module list."],"exampleFix":"// before\nabp add-module Bloging\n// after\nabp add-module Blogging","handlingStrategy":"validation","validationCode":"using var http = new HttpClient();\nvar resp = await http.GetAsync($\"https://www.abp.io/api/app/module/byNameWithDetails/?name={moduleName}\");\nif (resp.StatusCode == HttpStatusCode.NotFound)\n{ Console.Error.WriteLine($\"Module '{moduleName}' not in catalog.\"); return; }","typeGuard":null,"tryCatchPattern":"try { await SolutionModuleAdder.AddAsync(moduleName); }\ncatch (CliUsageException ex) when (ex.Message.Contains(\"module could not be found\"))\n{ Console.Error.WriteLine(ex.Message); }","preventionTips":["Keep an allow-list of valid module names from ABP docs.","Confirm Pro module access before automating commercial module additions."],"tags":["cli","module-system","http","not-found","catalog"],"backgroundTag":null,"analyzedSha":"7ed43b1931b9df46a50c0c59148a18645641d0df","analyzedAt":"2026-08-13T16:26:11.351Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}