maintainx-core-workflow-b
Execute MaintainX secondary workflow: Asset and Location management. Use when managing equipment assets, organizing locations/facilities, building asset hierarchies, and tracking equipment maintenance history. Trigger with phrases like "maintainx asset", "maintainx location", "equipment tracking", "asset management", "facility hierarchy".
Best use case
maintainx-core-workflow-b is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Execute MaintainX secondary workflow: Asset and Location management. Use when managing equipment assets, organizing locations/facilities, building asset hierarchies, and tracking equipment maintenance history. Trigger with phrases like "maintainx asset", "maintainx location", "equipment tracking", "asset management", "facility hierarchy".
Teams using maintainx-core-workflow-b should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/maintainx-core-workflow-b/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How maintainx-core-workflow-b Compares
| Feature / Agent | maintainx-core-workflow-b | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Execute MaintainX secondary workflow: Asset and Location management. Use when managing equipment assets, organizing locations/facilities, building asset hierarchies, and tracking equipment maintenance history. Trigger with phrases like "maintainx asset", "maintainx location", "equipment tracking", "asset management", "facility hierarchy".
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
ChatGPT vs Claude for Agent Skills
Compare ChatGPT and Claude for AI agent skills across coding, writing, research, and reusable workflow execution.
Cursor vs Codex for AI Workflows
Compare Cursor and Codex for AI coding workflows, repository assistance, debugging, refactoring, and reusable developer skills.
SKILL.md Source
# MaintainX Core Workflow B: Asset & Location Management
## Overview
Manage equipment assets and facility locations in MaintainX. Assets represent equipment that requires maintenance; locations organize your facilities into a manageable hierarchy.
## Prerequisites
- Completed `maintainx-install-auth` setup
- `MAINTAINX_API_KEY` environment variable configured
- MaintainX account with asset management permissions
## Instructions
### Step 1: Create a Location Hierarchy
```typescript
import { MaintainXClient } from './maintainx/client';
const client = new MaintainXClient();
// Create top-level facility
const { data: plant } = await client.request('POST', '/locations', {
name: 'Manufacturing Plant - Austin',
description: 'Main production facility',
address: '1234 Industrial Blvd, Austin, TX 78701',
});
// Create sub-locations
const { data: floor } = await client.request('POST', '/locations', {
name: 'Production Floor - Building A',
parentId: plant.id,
description: 'Primary manufacturing area with 12 production lines',
});
const { data: mechRoom } = await client.request('POST', '/locations', {
name: 'Mechanical Room - B2',
parentId: plant.id,
description: 'Pumps, compressors, and HVAC equipment',
});
console.log(`Location hierarchy created: ${plant.id} → ${floor.id}, ${mechRoom.id}`);
```
### Step 2: Register Assets
```typescript
// Create an asset linked to a location
const { data: pump } = await client.request('POST', '/assets', {
name: 'Centrifugal Pump #3',
description: 'Grundfos CR 45-2, 15HP, installed 2023',
locationId: mechRoom.id,
serialNumber: 'GF-CR45-2-00891',
model: 'CR 45-2',
manufacturer: 'Grundfos',
});
const { data: conveyor } = await client.request('POST', '/assets', {
name: 'Conveyor Belt - Line 7',
description: 'Main assembly line conveyor, 120ft span',
locationId: floor.id,
serialNumber: 'DRV-CONV-7-2024',
model: 'Heavy Duty BD-120',
manufacturer: 'Dorner',
});
console.log(`Assets registered: Pump #${pump.id}, Conveyor #${conveyor.id}`);
```
### Step 3: List and Filter Assets
```typescript
// Get all assets at a location
const { data: locationAssets } = await client.getAssets({
locationId: mechRoom.id,
limit: 50,
});
for (const asset of locationAssets.assets) {
console.log(` ${asset.name} (SN: ${asset.serialNumber || 'N/A'})`);
}
// Paginate through all assets
async function getAllAssets() {
const all = [];
let cursor: string | undefined;
do {
const { data } = await client.getAssets({ limit: 100, cursor });
all.push(...data.assets);
cursor = data.cursor;
} while (cursor);
return all;
}
const allAssets = await getAllAssets();
console.log(`Total assets: ${allAssets.length}`);
```
### Step 4: Query Locations
```typescript
// Get all locations (flat list)
const { data: locations } = await client.getLocations({ limit: 100 });
// Build a tree structure from flat list
function buildTree(locations: any[]) {
const map = new Map();
const roots: any[] = [];
for (const loc of locations) {
map.set(loc.id, { ...loc, children: [] });
}
for (const loc of locations) {
const node = map.get(loc.id);
if (loc.parentId && map.has(loc.parentId)) {
map.get(loc.parentId).children.push(node);
} else {
roots.push(node);
}
}
return roots;
}
const tree = buildTree(locations.locations);
console.log(JSON.stringify(tree, null, 2));
```
### Step 5: Create Work Orders Linked to Assets
```typescript
// Corrective maintenance on a specific asset
const { data: wo } = await client.createWorkOrder({
title: 'Centrifugal Pump #3 - Bearing Noise',
description: 'Unusual grinding noise detected during morning inspection.',
priority: 'HIGH',
assetId: pump.id,
locationId: mechRoom.id,
categories: ['CORRECTIVE'],
});
console.log(`Work order #${wo.id} linked to asset ${pump.id}`);
```
## Output
- Location hierarchy created with parent-child relationships
- Assets registered with serial numbers, models, and location links
- Paginated asset and location queries
- Work orders linked to specific assets and locations
## Error Handling
| Error | Cause | Solution |
|-------|-------|----------|
| 404 Not Found | Invalid asset or location ID | Verify ID exists with a GET request first |
| 400 Bad Request | Missing `name` field | Assets and locations require at least `name` |
| 409 Conflict | Duplicate serial number | Use unique serial numbers per asset |
| Empty results | Wrong filter or no data | Check query parameters, try without filters |
## Resources
- [MaintainX API Reference](https://developer.maintainx.com/reference)
- [Assets Help](https://help.getmaintainx.com/about-assets)
- [Locations Help](https://help.getmaintainx.com/about-locations)
## Next Steps
For troubleshooting common issues, see `maintainx-common-errors`.
## Examples
**Bulk import assets from CSV**:
```typescript
import { parse } from 'csv-parse/sync';
import { readFileSync } from 'fs';
const csv = readFileSync('assets.csv', 'utf-8');
const rows = parse(csv, { columns: true });
for (const row of rows) {
await client.request('POST', '/assets', {
name: row.name,
serialNumber: row.serial_number,
locationId: parseInt(row.location_id),
model: row.model,
manufacturer: row.manufacturer,
});
console.log(`Imported: ${row.name}`);
}
```
**Get maintenance history for an asset**:
```bash
# Fetch all work orders linked to a specific asset
curl -s "https://api.getmaintainx.com/v1/workorders?assetId=98765&limit=50" \
-H "Authorization: Bearer $MAINTAINX_API_KEY" \
| jq '.workOrders[] | {id, title, status, completedAt}'
```Related Skills
calendar-to-workflow
Converts calendar events and schedules into Claude Code workflows, meeting prep documents, and standup notes. Use when the user mentions calendar events, meeting prep, standup generation, or scheduling workflows. Trigger with phrases like "prep for my meetings", "generate standup notes", "create workflow from calendar", or "summarize today's schedule".
workhuman-core-workflow-b
Workhuman core workflow b for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman core workflow b".
workhuman-core-workflow-a
Workhuman core workflow a for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman core workflow a".
wispr-core-workflow-b
Wispr Flow core workflow b for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr core workflow b".
wispr-core-workflow-a
Wispr Flow core workflow a for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr core workflow a".
windsurf-core-workflow-b
Execute Windsurf's secondary workflow: Workflows, Memories, and reusable automation. Use when creating reusable Cascade workflows, managing persistent memories, or automating repetitive development tasks. Trigger with phrases like "windsurf workflow", "windsurf automation", "windsurf memories", "cascade workflow", "windsurf slash command".
windsurf-core-workflow-a
Execute Windsurf's primary workflow: Cascade Write mode for multi-file agentic coding. Use when building features, refactoring across files, or performing complex code tasks. Trigger with phrases like "windsurf cascade write", "windsurf agentic coding", "windsurf multi-file edit", "cascade write mode", "windsurf build feature".
webflow-core-workflow-b
Execute Webflow secondary workflows — Sites management, Pages API, Forms submissions, Ecommerce (products/orders/inventory), and Custom Code via the Data API v2. Use when managing sites, reading pages, handling form data, or working with Webflow Ecommerce products and orders. Trigger with phrases like "webflow sites", "webflow pages", "webflow forms", "webflow ecommerce", "webflow products", "webflow orders".
webflow-core-workflow-a
Execute the primary Webflow workflow — CMS content management: list collections, CRUD items, publish items, and manage content lifecycle via the Data API v2. Use when working with Webflow CMS collections and items, managing blog posts, team members, or any dynamic content. Trigger with phrases like "webflow CMS", "webflow collections", "webflow items", "create webflow content", "manage webflow CMS", "webflow content management".
veeva-core-workflow-b
Veeva Vault core workflow b for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva core workflow b".
veeva-core-workflow-a
Veeva Vault core workflow a for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva core workflow a".
vastai-core-workflow-b
Execute Vast.ai secondary workflow: multi-instance orchestration, spot recovery, and cost optimization. Use when running distributed training, handling spot preemption, or optimizing GPU spend across multiple instances. Trigger with phrases like "vastai distributed training", "vastai spot recovery", "vastai multi-gpu", "vastai cost optimization".