From itential-builder
Manages resource models, instances, actions, and lifecycle executions in Itential Lifecycle Manager. Define models, run actions on instances, track history. Argument: [action or resource-name].
How this command is triggered — by the user, by Claude, or both
Slash command
/itential-builder:SKILL [action or resource-name]skills/itential-lcm/Files this command reads when invoked
The summary Claude sees in its command listing — used to decide when to auto-load this command
# Lifecycle Manager - Developer Skills Guide Lifecycle Manager (LCM) provides a declarative framework for managing the lifecycle of reusable resources. Define a resource model (schema + actions), create instances of it, and run workflow-driven actions to create, update, or delete those instances — with full execution history and optional pre/post transformations. ## Concepts - **Resource Model** — a template defining what a resource looks like (JSON Schema) and what actions can be performed on it. Actions link to workflows. - **Resource Instance** — a concrete instantiation of a model. S...
Lifecycle Manager (LCM) provides a declarative framework for managing the lifecycle of reusable resources. Define a resource model (schema + actions), create instances of it, and run workflow-driven actions to create, update, or delete those instances — with full execution history and optional pre/post transformations.
instanceData conforming to the model's schema. Tracks state and last action.LCM_GROUPS_ENABLED=true./lifecycle-manager (hyphens), NOT /lifecycle_manager (underscores){message, data, metadata} — same as projects, NOT {status, result} like inventory manager{skip, limit, total, currentPageSize, nextPageSkip, previousPageSkip}sort and order parameters: ?sort=startTime&order=-1. The - prefix syntax (sort=-startTime) does NOT work — returns error.PUT /resources/{modelId}/instances/{instanceId} only updates name and description — NOT instanceData. You must run an action to modify instance data.instance parameter is forbidden, use instanceName insteadinstance (ID or object) is required_id is a 4-char hex string (same as workflow task IDs)"0001" = Ready, "0000" = Error, "0002" = DeletedDELETE /resources/{id} does NOT delete instances by default — pass ?delete-associated-instances=true to cascadeLCM_GROUPS_ENABLED=true environment variableinstance containing the instance data. Without it, the action fails validation with "workflow does not output a value for 'instance'". Use a merge task to build the instance object and wire outgoing to $var.job.instance.'resource:action', not 'automation'preWorkflowJst / postWorkflowJst)Base Path: /lifecycle-manager
| Method | Endpoint | Description |
|---|---|---|
| POST | /lifecycle-manager/resources | Create a new resource model |
| GET | /lifecycle-manager/resources | List resource models (searchable) |
| GET | /lifecycle-manager/resources/{id} | Get a single resource model |
| PUT | /lifecycle-manager/resources/{id} | Update a resource model |
| DELETE | /lifecycle-manager/resources/{id} | Delete a resource model |
| POST | /lifecycle-manager/resources/import | Import a resource model |
| GET | /lifecycle-manager/resources/{modelId}/export | Export a resource model |
| POST | /lifecycle-manager/resources/{modelId}/edit | Auto-generate action workflows and transformations |
| POST | /lifecycle-manager/resources/{modelId}/actions/validate | Validate action definitions |
Create a resource model:
POST /lifecycle-manager/resources
{
"name": "Network Service",
"description": "Manages network service lifecycle",
"schema": {
"$id": "network-service",
"type": "object",
"required": ["service_name", "vlan_id"],
"properties": {
"service_name": {"type": "string"},
"vlan_id": {"type": "integer"},
"status": {"type": "string", "enum": ["provisioned", "active", "decommissioned"]}
}
},
"actions": [
{
"_id": "a1b2",
"name": "Provision",
"type": "create",
"workflow": null,
"preWorkflowJst": null,
"postWorkflowJst": null
},
{
"_id": "c3d4",
"name": "Update Config",
"type": "update",
"workflow": null,
"preWorkflowJst": null,
"postWorkflowJst": null
},
{
"_id": "e5f6",
"name": "Decommission",
"type": "delete",
"workflow": null,
"preWorkflowJst": null,
"postWorkflowJst": null
}
]
}
schema — JSON Schema (draft-07) defining valid instance dataactions[]._id — 4-char hex ID (same convention as workflow task IDs)actions[].type — "create", "update", "delete", or "import"actions[].workflow — workflow ID to execute (set after creating the workflow, or use the edit endpoint to auto-generate)actions[].preWorkflowJst / postWorkflowJst — template IDs for Jinja2 transformations before/after the workflowResponse:
{
"message": "Successfully created resource model",
"data": {
"_id": "687fe493ef863896dcba8d78",
"name": "Network Service",
"schema": {...},
"actions": [...],
"created": "2026-03-04T...",
"createdBy": "[email protected]"
},
"metadata": {}
}
Auto-generate action workflows:
POST /lifecycle-manager/resources/{modelId}/edit
{
"editType": "generate-action-workflow",
"actionId": "a1b2"
}
Edit types: generate-action-workflow, generate-action-pre-transformation, generate-action-post-transformation
Delete with cascade:
DELETE /lifecycle-manager/resources/{id}?delete-associated-instances=true
| Method | Endpoint | Description |
|---|---|---|
| GET | /lifecycle-manager/resources/{modelId}/instances | List instances (searchable) |
| GET | /lifecycle-manager/resources/{modelId}/instances/{instanceId} | Get a single instance |
| PUT | /lifecycle-manager/resources/{modelId}/instances/{instanceId} | Update instance name/description only |
| POST | /lifecycle-manager/resources/{modelId}/instances/import | Import an instance |
| GET | /lifecycle-manager/resources/{modelId}/instances/{instanceId}/export | Export an instance |
Instance structure:
{
"_id": "687fea14ef863896dcba8d79",
"name": "customer-portal",
"description": "Customer portal service",
"modelId": "687fe493ef863896dcba8d78",
"instanceData": {
"service_name": "customer-portal",
"vlan_id": 100,
"status": "active"
},
"stateId": "0001",
"lastAction": {
"_id": "a1b2",
"executionId": "67d07212df84d4150b6498f7",
"name": "Provision",
"type": "create",
"status": "complete"
},
"created": "2026-03-04T...",
"lastUpdated": "2026-03-04T..."
}
Note: instanceData can only be modified by running an action — NOT by PUT. The PUT endpoint only updates name and description.
| Method | Endpoint | Description |
|---|---|---|
| POST | /lifecycle-manager/resources/{modelId}/run-action | Run an action on a single instance |
| POST | /lifecycle-manager/resources/{modelId}/run-bulk-action | Run an action on multiple instances |
Run a create action (new instance):
POST /lifecycle-manager/resources/{modelId}/run-action
{
"actionId": "a1b2",
"instanceName": "customer-portal",
"instanceDescription": "Customer portal service",
"inputs": {
"service_name": "customer-portal",
"vlan_id": 100
}
}
Run an update/delete action (existing instance):
{
"actionId": "c3d4",
"instance": "687fea14ef863896dcba8d79",
"inputs": {
"new_vlan_id": 200
}
}
instance — instance ID or full instance object (required for update/delete, forbidden for create)inputs — workflow input variables (optional, passed to the action workflow)Response:
{
"success": true,
"data": {
"executionId": "67d07212df84d4150b6498f7"
}
}
Run bulk action (requires LCM_GROUPS_ENABLED):
{
"actionId": "c3d4",
"instances": ["id1", "id2", "id3"],
"inputs": {"base_config": "standard"},
"inputOverrides": [
{"instanceId": "id1", "inputs": {"vlan_id": 100}},
{"instanceId": "id2", "inputs": {"vlan_id": 200}}
]
}
| Method | Endpoint | Description |
|---|---|---|
| GET | /lifecycle-manager/action-executions | List all action executions (searchable) |
| GET | /lifecycle-manager/action-executions/{id} | Get a single execution record |
| POST | /lifecycle-manager/action-executions/{executionId}/cancel | Cancel a running execution |
Execution record:
{
"_id": "67d07212df84d4150b6498f7",
"modelId": "687fe493ef863896dcba8d78",
"modelName": "Network Service",
"instanceId": "687fea14ef863896dcba8d79",
"instanceName": "customer-portal",
"actionId": "a1b2",
"actionName": "Provision",
"actionType": "create",
"status": "complete",
"startTime": "2026-03-04T12:00:00Z",
"endTime": "2026-03-04T12:00:05Z",
"jobId": "24-char-workflow-engine-job-id",
"progress": [
{"_id": "preTransformation", "status": "complete"},
{"_id": "workflow", "status": "complete"},
{"_id": "postTransformation", "status": "complete"}
],
"errors": []
}
Execution statuses: running, complete, error, canceled, paused
Query parameters for filtering:
equals[status]=complete — exact matchcontains[modelName]=Network — substring matchin[status]=running,complete — match any in listgt[startTime]=2026-03-01 — greater thansort=startTime&order=-1 — sort descending (requires BOTH sort and order)skip=0&limit=25 — paginationRequires LCM_GROUPS_ENABLED=true environment variable.
| Method | Endpoint | Description |
|---|---|---|
| POST | /lifecycle-manager/resources/{modelId}/groups | Create a group |
| GET | /lifecycle-manager/resources/{modelId}/groups | List groups |
| GET | /lifecycle-manager/resources/{modelId}/groups/{groupId} | Get a group |
| PATCH | /lifecycle-manager/resources/{modelId}/groups/{groupId} | Update a group |
| DELETE | /lifecycle-manager/resources/{modelId}/groups/{groupId} | Delete a group |
Group types:
manual — explicit list of instance IDs: {"type": "manual", "instances": ["id1", "id2"]}dynamic — filter-based: {"type": "dynamic", "filter": {"status": "active"}}When an action runs, it goes through 3 phases:
1. Pre-Transformation (optional)
└── Jinja2 template transforms inputs before workflow
2. Workflow Execution
└── Runs the action's linked workflow with (transformed) inputs
3. Post-Transformation (optional)
└── Jinja2 template transforms workflow outputs
└── Can produce/update instance data
Errors at any phase stop execution. Each phase has its own status tracked in the progress array.
| File | Purpose |
|---|---|
${CLAUDE_PLUGIN_ROOT}/helpers/lcm-action-workflow.json | LCM action workflow with merge task that outputs instance variable. Start from this — it prevents the "workflow does not output a value for 'instance'" error. |
1. POST /lifecycle-manager/resources → create model with schema + actions
2. Create workflows for each action in /itential-studio
3. PUT /lifecycle-manager/resources/{id} → update actions with workflow IDs
4. POST /lifecycle-manager/resources/{id}/actions/validate → verify actions are valid
1. POST /lifecycle-manager/resources/{id}/run-action → create action (new instance)
2. GET /lifecycle-manager/action-executions/{execId} → check execution status
3. GET /lifecycle-manager/resources/{id}/instances → see created instance
4. POST /lifecycle-manager/resources/{id}/run-action → update action (modify instance)
5. POST /lifecycle-manager/resources/{id}/run-action → delete action (decommission)
1. GET /lifecycle-manager/action-executions?equals[status]=error → find failed executions
2. GET /lifecycle-manager/action-executions/{id} → check progress phases + errors
3. Check errors[].origin to identify which phase failed
4. Fix the workflow/transformation and re-run the action
npx claudepluginhub itential/builder-skills/SKILLResolves GitHub issue via isolated worktree, TDD workflow, and auto-closing PR creation.
/SKILLCreates conventional git commit from conversation intent using git-agent and pushes to remote. Accepts optional Claude model name for co-author.
/SKILLSurfaces current session task from state file, evaluates clarity (prompts for clarification if needed), assesses completion, and verifies if fully done.