From prism-devtools
Use when implementing strangler pattern for legacy migrations. Safely migrates controllers with feature flag control.
npx claudepluginhub resolve-io/.prismThis skill uses the workspace's default tool permissions.
<!-- Powered by Prism Coreâ„¢ -->
Enables AI agents to execute x402 payments with per-task budgets, spending controls, and non-custodial wallets via MCP tools. Use when agents pay for APIs, services, or other agents.
Provides patterns for autonomous Claude Code loops: sequential pipelines, agentic REPLs, PR cycles, de-sloppify cleanups, and RFC-driven multi-agent DAGs. For continuous dev workflows without intervention.
Applies NestJS patterns for modules, controllers, providers, DTO validation, guards, interceptors, config, and production TypeScript backends with project structure and bootstrap examples.
Implement the strangler pattern to safely migrate controllers from express-web-api to actions.api with feature flag control.
Execute a controlled migration of legacy endpoints to the new actions.api using the strangler pattern, ensuring zero downtime and instant rollback capability through feature flags.
Related Documents:
Use strangler pattern for:
Skip strangler pattern for:
// Express-Web-API Controller - Real example from WorkflowController
public async Task<HttpResponseMessage> StartWorkflowExecution([FromBody] EyeShareWorkflowDesignerModel workflowDesigner)
{
var tenant = Features.ResolveTenant(Request.Headers);
if (await FeatureResolverSingleton.GetIsFeatureEnabledAsync(Features.WorkflowStrangle, tenant))
return CreateResponseMessage(await strangledService.Value.StartWorkflowExecution(workflowDesigner));
return CreateResponseMessage(legacyService.Value.StartWorkflowExecution(workflowDesigner, EyeShareToken));
}
public class WorkflowController : ApiBaseController
{
private Lazy<EyeShareWorkflowService> legacyService;
private Lazy<WorkflowService> strangledService; // Handles actions.api communication
public WorkflowController()
{
legacyService = new Lazy<EyeShareWorkflowService>(() => {
var token = TokenManager.GetTokenInfo();
return new EyeShareWorkflowService(token, new DalService(token));
});
strangledService = new Lazy<WorkflowService>(() => new WorkflowService(ControllerContext));
}
}
// Actions.API - No strangler terminology
app.MapPost("/api/Workflow/startExecution",
async (StartWorkflowExecutionRequest request, IMediator mediator) =>
{
var result = await mediator.Send(request);
return Results.Ok(result);
}).RequireAuthorization();
public record StartWorkflowExecutionRequest : IRequest<WorkflowExecutionResponse>
{
public EyeShareWorkflowDesignerModel WorkflowDesigner { get; init; }
}
public class StartWorkflowExecutionHandler : IRequestHandler<StartWorkflowExecutionRequest, WorkflowExecutionResponse>
{
public async Task<WorkflowExecutionResponse> Handle(StartWorkflowExecutionRequest request, CancellationToken cancellationToken)
{
return await _service.StartWorkflowExecutionAsync(request.WorkflowDesigner);
}
}
✅ Feature flag routing works between legacy and new systems ✅ Response behavior identical to captured baseline ✅ All tests pass in actions.api integration suite ✅ No regressions in existing functionality ✅ Performance maintains or exceeds baseline ✅ Rollback capability tested and verified
For Implementation:
For Validation:
For Process: