@atlashub/smartstack-cli 3.25.0 → 3.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/dist/mcp-entry.mjs +11 -5
  2. package/dist/mcp-entry.mjs.map +1 -1
  3. package/package.json +1 -1
  4. package/templates/skills/apex/SKILL.md +26 -5
  5. package/templates/skills/apex/_shared.md +3 -3
  6. package/templates/skills/apex/references/agent-teams-protocol.md +8 -8
  7. package/templates/skills/apex/references/challenge-questions.md +165 -0
  8. package/templates/skills/apex/{steps/step-04-validate.md → references/post-checks.md} +82 -214
  9. package/templates/skills/apex/references/smartstack-api.md +91 -14
  10. package/templates/skills/apex/references/smartstack-layers.md +16 -4
  11. package/templates/skills/apex/steps/step-00-init.md +84 -56
  12. package/templates/skills/apex/steps/step-01-analyze.md +73 -87
  13. package/templates/skills/apex/steps/step-03-execute.md +2 -2
  14. package/templates/skills/apex/steps/step-04-examine.md +198 -0
  15. package/templates/skills/apex/steps/{step-05-examine.md → step-05-deep-review.md} +6 -6
  16. package/templates/skills/apex/steps/step-06-resolve.md +2 -2
  17. package/templates/skills/business-analyse/SKILL.md +28 -0
  18. package/templates/skills/business-analyse/references/agent-module-prompt.md +255 -0
  19. package/templates/skills/business-analyse/references/agent-pooling-best-practices.md +26 -10
  20. package/templates/skills/business-analyse/references/team-orchestration.md +437 -0
  21. package/templates/skills/business-analyse/steps/step-02-decomposition.md +31 -4
  22. package/templates/skills/business-analyse/steps/step-03a1-setup.md +21 -0
  23. package/templates/skills/business-analyse/steps/step-03d-validate.md +84 -0
  24. package/templates/skills/ralph-loop/references/core-seed-data.md +45 -10
  25. package/templates/skills/ralph-loop/steps/step-02-execute.md +47 -0
@@ -34504,28 +34504,32 @@ using System.Linq;
34504
34504
  using Microsoft.EntityFrameworkCore;
34505
34505
  using Microsoft.Extensions.Logging;
34506
34506
  using SmartStack.Application.Common.Interfaces.Identity;
34507
+ using SmartStack.Application.Common.Interfaces.Tenants;
34507
34508
  using SmartStack.Application.Common.Interfaces.Persistence;
34508
34509
 
34509
34510
  namespace {{implNamespace}};
34510
34511
 
34511
34512
  /// <summary>
34512
34513
  /// Service implementation for {{name}} operations.
34513
- /// IMPORTANT: All queries MUST filter by _currentUser.TenantId for multi-tenant isolation.
34514
+ /// IMPORTANT: All queries MUST filter by tenant ID for multi-tenant isolation.
34514
34515
  /// IMPORTANT: GetAllAsync MUST support search parameter for frontend EntityLookup component.
34515
34516
  /// </summary>
34516
34517
  public class {{name}}Service : I{{name}}Service
34517
34518
  {
34518
34519
  private readonly IExtensionsDbContext _db;
34519
- private readonly ICurrentUser _currentUser;
34520
+ private readonly ICurrentUserService _currentUser;
34521
+ private readonly ICurrentTenantService _currentTenant;
34520
34522
  private readonly ILogger<{{name}}Service> _logger;
34521
34523
 
34522
34524
  public {{name}}Service(
34523
34525
  IExtensionsDbContext db,
34524
- ICurrentUser currentUser,
34526
+ ICurrentUserService currentUser,
34527
+ ICurrentTenantService currentTenant,
34525
34528
  ILogger<{{name}}Service> logger)
34526
34529
  {
34527
34530
  _db = db;
34528
34531
  _currentUser = currentUser;
34532
+ _currentTenant = currentTenant;
34529
34533
  _logger = logger;
34530
34534
  }
34531
34535
 
@@ -34533,8 +34537,10 @@ public class {{name}}Service : I{{name}}Service
34533
34537
  /// <inheritdoc />
34534
34538
  public async Task<object> {{this}}(CancellationToken cancellationToken = default)
34535
34539
  {
34536
- _logger.LogInformation("Executing {{this}} for tenant {TenantId}", _currentUser.TenantId);
34537
- // TODO: Implement {{this}} \u2014 ALL queries must filter by _currentUser.TenantId
34540
+ var tenantId = _currentTenant.TenantId
34541
+ ?? throw new UnauthorizedAccessException("Tenant context is required");
34542
+ _logger.LogInformation("Executing {{this}} for tenant {TenantId}", tenantId);
34543
+ // TODO: Implement {{this}} \u2014 ALL queries must filter by tenantId
34538
34544
  // IMPORTANT: GetAllAsync MUST accept (string? search, int page, int pageSize) parameters
34539
34545
  // to enable EntityLookup search on the frontend. Example:
34540
34546
  // if (!string.IsNullOrWhiteSpace(search))