@assetlab/mcp-server 1.3.0 → 1.3.1

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 (2) hide show
  1. package/README.md +116 -143
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,173 +1,146 @@
1
1
  # @assetlab/mcp-server
2
2
 
3
- Connect [Claude](https://claude.ai) to your [AssetLab](https://assetlab.ca) account via the [Model Context Protocol](https://modelcontextprotocol.io). Ask Claude questions about your assets, work orders, PM schedules, and more — in plain language.
3
+ Connect [Claude](https://claude.ai) to your [AssetLab](https://assetlab.ca) account via the [Model Context Protocol](https://modelcontextprotocol.io). Ask Claude questions about your assets, work orders, PM schedules, and more — in plain language. Create and update records hands-free.
4
4
 
5
5
  ## Prerequisites
6
6
 
7
- - [Node.js](https://nodejs.org) 18 or later
8
7
  - An AssetLab account with an API key (create one in **Settings → API Keys**)
9
- - [Claude Desktop](https://claude.ai/download) or [Claude Code](https://claude.ai/code)
8
+ - [Claude.ai](https://claude.ai) Team or Enterprise plan
10
9
 
11
10
  ## Setup
12
11
 
13
- ### Claude Desktop
14
-
15
- 1. Open your Claude Desktop config file:
16
- - **Mac:** `~/Library/Application Support/Claude/claude_desktop_config.json`
17
- - **Windows:** `%APPDATA%\Claude\claude_desktop_config.json`
18
-
19
- 2. Add the following to the `mcpServers` object (replace `al_live_...` with your API key):
20
-
21
- ```json
22
- {
23
- "mcpServers": {
24
- "assetlab": {
25
- "command": "npx",
26
- "args": ["-y", "@assetlab/mcp-server"],
27
- "env": {
28
- "ASSETLAB_API_KEY": "al_live_...",
29
- "ASSETLAB_API_URL": "your-api-url"
30
- }
31
- }
32
- }
33
- }
34
- ```
35
-
36
- > **Tip:** The easiest way to get this config is to click **Copy Claude Config** directly on your API key in **AssetLab Settings → API Keys** — it pre-fills your key and API URL automatically.
37
-
38
- 3. Restart Claude Desktop. You should see the AssetLab tools available.
39
-
40
- ### Claude Code
41
-
42
- ```bash
43
- claude mcp add assetlab npx @assetlab/mcp-server \
44
- -e ASSETLAB_API_KEY=al_live_... \
45
- -e ASSETLAB_API_URL=your-api-url
46
- ```
12
+ 1. Create an API key in **AssetLab → Settings → API Keys**
13
+ 2. In Claude.ai, go to **Settings → Integrations → Add integration**
14
+ 3. Paste the connector URL: `https://mcp.assetlab.ca`
15
+ 4. When prompted for auth, paste your API key (`al_live_...`)
47
16
 
48
17
  ## Example prompts
49
18
 
50
- Once connected, you can ask Claude things like:
51
-
52
19
  - *"Show me all overdue work orders"*
53
20
  - *"List critical assets at Site A"*
54
21
  - *"What PM schedules are due this month?"*
55
- - *"Summarize the current state of our facilities"*
22
+ - *"Create a work order for the broken pump in Building 3"*
23
+ - *"Add a new vendor for electrical services"*
24
+ - *"Update the priority on WO-1234 to urgent"*
56
25
  - *"Which projects are at risk or delayed?"*
57
- - *"Show me all assets linked to the HVAC system in Building 3"*
58
- - *"List open corrective work orders at all sites"*
59
26
  - *"What's the total cost history for Asset X?"*
60
- - *"Show me all project milestones that are at risk"*
61
- - *"What's the FCI trend for Site A over the past year?"*
27
+ - *"Create a part for 10-inch butterfly valves"*
62
28
  - *"List all replacement plans due in 2027"*
63
29
 
64
30
  ## Available tools
65
31
 
66
- | Tool | Description |
67
- |------|-------------|
68
- | `list_assets` | List assets with filters for site, building, system, and search |
69
- | `get_asset` | Get full details for a specific asset |
70
- | `list_work_orders` | List work orders filtered by status, priority, type, or site |
71
- | `get_work_order` | Get full details for a specific work order |
72
- | `list_sites` | List all sites in your organization |
73
- | `get_site` | Get details for a specific site |
74
- | `list_buildings` | List buildings, optionally filtered by site |
75
- | `list_locations` | List rooms and areas, optionally filtered by building |
76
- | `list_systems` | List systems (HVAC, plumbing, electrical, etc.) |
77
- | `list_system_groups` | List system groups |
78
- | `list_system_classes` | List top-level system classifications |
79
- | `list_pm_schedules` | List PM schedules filtered by status, frequency, or site |
80
- | `get_pm_schedule` | Get a PM schedule including tasks and linked assets |
81
- | `list_pm_templates` | List reusable PM templates |
82
- | `list_projects` | List capital projects filtered by status or health |
83
- | `get_project` | Get project details including budget and progress |
84
- | `list_contracts` | List vendor contracts |
85
- | `list_compliance_items` | List compliance/regulatory items |
86
- | `get_compliance_item` | Get a compliance item with linked PM schedules |
87
- | `get_dashboard_summary` | Get aggregated stats across assets, work orders, and sites |
88
- | `list_budgets` | List annual funding budgets by year, site, building, or funding source |
89
- | `get_budget` | Get a single annual funding budget |
90
- | `list_asset_comments` | List comments on assets, filterable by asset |
91
- | `get_asset_comment` | Get a single asset comment |
92
- | `list_asset_costs` | List asset cost records (repairs, PM, operations, replacements) |
93
- | `get_asset_cost` | Get a single asset cost record with related names |
94
- | `list_asset_replacement_plans` | List asset replacement plans for lifecycle planning |
95
- | `get_asset_replacement_plan` | Get a single replacement plan |
96
- | `list_asset_risk_history` | List risk assessment history for assets |
97
- | `get_asset_risk_history_entry` | Get a single risk history entry |
98
- | `list_work_order_comments` | List comments on work orders |
99
- | `get_work_order_comment` | Get a single work order comment |
100
- | `list_project_tasks` | List project tasks with status, priority, cost tracking |
101
- | `get_project_task` | Get a single project task |
102
- | `list_project_milestones` | List project milestones |
103
- | `get_project_milestone` | Get a single milestone |
104
- | `list_project_phases` | List project phases |
105
- | `get_project_phase` | Get a single phase |
106
- | `list_project_budget_items` | List project budget line items by category |
107
- | `get_project_budget_item` | Get a single budget item |
108
- | `list_project_time_entries` | List time entries for project labor tracking |
109
- | `get_project_time_entry` | Get a single time entry |
110
- | `list_project_comments` | List comments on projects (threaded) |
111
- | `get_project_comment` | Get a single project comment |
112
- | `list_compliance_records` | List compliance check completion records |
113
- | `get_compliance_record` | Get a single compliance record |
114
- | `list_site_fci_history` | List Facility Condition Index history for sites |
115
- | `get_site_fci_history_entry` | Get a single FCI history entry |
116
- | `list_dashboard_snapshots` | List monthly aggregate dashboard snapshots |
117
- | `get_dashboard_snapshot` | Get a single dashboard snapshot |
118
- | `list_vendor_site_assignments` | List vendor-to-site service mappings |
119
- | `get_vendor_site_assignment` | Get a single vendor site assignment |
120
- | `list_contract_sites` | List contract-to-site coverage mappings |
121
- | `list_custom_field_definitions` | List custom field schemas by entity type |
122
- | `get_custom_field_definition` | Get a single custom field definition |
123
- | `list_custom_field_values` | List custom field values by entity or field |
124
- | `get_custom_field_value` | Get a single custom field value |
125
- | `list_part_categories` | List part categories |
126
- | `get_part_category` | Get a single part category |
32
+ ### Read tools
33
+
34
+ | Resource | List | Get |
35
+ |----------|------|-----|
36
+ | Assets | `list_assets` | `get_asset` |
37
+ | Work Orders | `list_work_orders` | `get_work_order` |
38
+ | Work Requests | `list_work_requests` | `get_work_request` |
39
+ | Sites | `list_sites` | `get_site` |
40
+ | Buildings | `list_buildings` | |
41
+ | Locations | `list_locations` | |
42
+ | Systems | `list_systems` | |
43
+ | System Groups | `list_system_groups` | |
44
+ | System Classes | `list_system_classes` | |
45
+ | PM Schedules | `list_pm_schedules` | `get_pm_schedule` |
46
+ | PM Templates | `list_pm_templates` | |
47
+ | Projects | `list_projects` | `get_project` |
48
+ | Contracts | `list_contracts` | |
49
+ | Compliance Items | `list_compliance_items` | `get_compliance_item` |
50
+ | Compliance Records | `list_compliance_records` | `get_compliance_record` |
51
+ | Dashboard | | `get_dashboard_summary` |
52
+ | Dashboard Snapshots | `list_dashboard_snapshots` | `get_dashboard_snapshot` |
53
+ | Vendors | `list_vendors` | `get_vendor` |
54
+ | Invoices | `list_invoices` | `get_invoice` |
55
+ | Purchase Orders | `list_purchase_orders` | `get_purchase_order` |
56
+ | Expenses | `list_expenses` | `get_expense` |
57
+ | Budgets | `list_budgets` | `get_budget` |
58
+ | Parts | `list_parts` | `get_part` |
59
+ | Part Categories | `list_part_categories` | `get_part_category` |
60
+ | Asset Comments | `list_asset_comments` | `get_asset_comment` |
61
+ | Asset Costs | `list_asset_costs` | `get_asset_cost` |
62
+ | Replacement Plans | `list_asset_replacement_plans` | `get_asset_replacement_plan` |
63
+ | Risk History | `list_asset_risk_history` | `get_asset_risk_history_entry` |
64
+ | WO Comments | `list_work_order_comments` | `get_work_order_comment` |
65
+ | Project Tasks | `list_project_tasks` | `get_project_task` |
66
+ | Project Milestones | `list_project_milestones` | `get_project_milestone` |
67
+ | Project Phases | `list_project_phases` | `get_project_phase` |
68
+ | Project Budget Items | `list_project_budget_items` | `get_project_budget_item` |
69
+ | Project Time Entries | `list_project_time_entries` | `get_project_time_entry` |
70
+ | Project Comments | `list_project_comments` | `get_project_comment` |
71
+ | Site FCI History | `list_site_fci_history` | `get_site_fci_history_entry` |
72
+ | Vendor Site Assignments | `list_vendor_site_assignments` | `get_vendor_site_assignment` |
73
+ | Contract Sites | `list_contract_sites` | |
74
+ | Custom Field Definitions | `list_custom_field_definitions` | `get_custom_field_definition` |
75
+ | Custom Field Values | `list_custom_field_values` | `get_custom_field_value` |
76
+ | Asset Types | `list_asset_types` | |
77
+ | Work Categories | `list_work_categories` | |
78
+ | Manufacturers | `list_manufacturers` | `get_manufacturer` |
79
+ | Building Types | `list_building_types` | |
80
+ | Location Types | `list_location_types` | |
81
+ | Cost Categories | `list_cost_categories` | |
82
+
83
+ ### Write tools
84
+
85
+ | Resource | Create | Update | Delete |
86
+ |----------|--------|--------|--------|
87
+ | Assets | `create_asset` | `update_asset` | `delete_asset` |
88
+ | Work Orders | `create_work_order` | `update_work_order` | `delete_work_order` |
89
+ | Work Requests | `create_work_request` | `update_work_request` | `delete_work_request` |
90
+ | Sites | `create_site` | `update_site` | `delete_site` |
91
+ | Buildings | `create_building` | `update_building` | `delete_building` |
92
+ | Locations | `create_location` | `update_location` | `delete_location` |
93
+ | Systems | `create_system` | `update_system` | `delete_system` |
94
+ | PM Schedules | `create_pm_schedule` | `update_pm_schedule` | `delete_pm_schedule` |
95
+ | Projects | `create_project` | `update_project` | `delete_project` |
96
+ | Contracts | `create_contract` | `update_contract` | `delete_contract` |
97
+ | Vendors | `create_vendor` | `update_vendor` | `delete_vendor` |
98
+ | Invoices | `create_invoice` | `update_invoice` | `delete_invoice` |
99
+ | Purchase Orders | `create_purchase_order` | `update_purchase_order` | `delete_purchase_order` |
100
+ | Expenses | `create_expense` | `update_expense` | `delete_expense` |
101
+ | Budgets | `create_budget` | `update_budget` | `delete_budget` |
102
+ | Parts | `create_part` | `update_part` | `delete_part` |
103
+ | Part Categories | `create_part_category` | `update_part_category` | `delete_part_category` |
104
+ | Asset Comments | `create_asset_comment` | `update_asset_comment` | `delete_asset_comment` |
105
+ | Asset Costs | `create_asset_cost` | `update_asset_cost` | `delete_asset_cost` |
106
+ | Replacement Plans | `create_asset_replacement_plan` | `update_asset_replacement_plan` | `delete_asset_replacement_plan` |
107
+ | WO Comments | `create_work_order_comment` | `update_work_order_comment` | `delete_work_order_comment` |
108
+ | Project Tasks | `create_project_task` | `update_project_task` | `delete_project_task` |
109
+ | Project Milestones | `create_project_milestone` | `update_project_milestone` | `delete_project_milestone` |
110
+ | Project Phases | `create_project_phase` | `update_project_phase` | `delete_project_phase` |
111
+ | Project Budget Items | `create_project_budget_item` | `update_project_budget_item` | `delete_project_budget_item` |
112
+ | Project Time Entries | `create_project_time_entry` | `update_project_time_entry` | `delete_project_time_entry` |
113
+ | Project Comments | `create_project_comment` | `update_project_comment` | `delete_project_comment` |
114
+ | Vendor Site Assignments | `create_vendor_site_assignment` | — | `delete_vendor_site_assignment` |
115
+ | Contract Sites | `create_contract_site` | — | `delete_contract_site` |
116
+ | Custom Field Definitions | `create_custom_field_definition` | `update_custom_field_definition` | `delete_custom_field_definition` |
117
+ | Custom Field Values | `create_custom_field_value` | `update_custom_field_value` | `delete_custom_field_value` |
118
+ | Asset Types | `create_asset_type` | `update_asset_type` | `delete_asset_type` |
119
+ | Work Categories | `create_work_category` | `update_work_category` | `delete_work_category` |
120
+ | Manufacturers | `create_manufacturer` | `update_manufacturer` | `delete_manufacturer` |
121
+ | Building Types | `create_building_type` | `update_building_type` | `delete_building_type` |
122
+ | Location Types | `create_location_type` | `update_location_type` | `delete_location_type` |
123
+ | Cost Categories | `create_cost_category` | `update_cost_category` | `delete_cost_category` |
127
124
 
128
125
  ## Scopes
129
126
 
130
- API keys use scopes to control what Claude can access. Grant only the scopes you need:
131
-
132
- | Scope | Access |
133
- |-------|--------|
134
- | `assets:read` | Assets |
135
- | `work_orders:read` | Work orders |
136
- | `sites:read` | Sites and buildings |
137
- | `locations:read` | Locations |
138
- | `systems:read` | Systems, system groups, system classes |
139
- | `pm_schedules:read` | PM schedules and templates |
140
- | `projects:read` | Capital projects |
141
- | `contracts:read` | Vendor contracts |
142
- | `compliance:read` | Compliance items |
143
- | `dashboard:read` | Dashboard summary stats |
144
- | `budgets:read` | Annual funding budgets |
145
- | `asset_comments:read` | Asset comments |
146
- | `asset_costs:read` | Asset cost records |
147
- | `asset_replacement_plans:read` | Asset replacement plans |
148
- | `asset_risk_history:read` | Asset risk history |
149
- | `work_order_comments:read` | Work order comments |
150
- | `project_tasks:read` | Project tasks |
151
- | `project_milestones:read` | Project milestones |
152
- | `project_phases:read` | Project phases |
153
- | `project_budget_items:read` | Project budget items |
154
- | `project_time_entries:read` | Project time entries |
155
- | `project_comments:read` | Project comments |
156
- | `compliance_records:read` | Compliance records |
157
- | `site_fci_history:read` | Site FCI history |
158
- | `dashboard_snapshots:read` | Dashboard snapshots |
159
- | `vendor_site_assignments:read` | Vendor site assignments |
160
- | `contract_sites:read` | Contract site mappings |
161
- | `custom_fields:read` | Custom field definitions and values |
162
- | `part_categories:read` | Part categories |
163
- | `*:*` | All resources |
127
+ API keys use scopes to control what Claude can access. Configure per-resource read and write access in **Settings → API Keys**.
128
+
129
+ | Scope pattern | Access |
130
+ |---------------|--------|
131
+ | `resource:read` | List and get records (e.g. `assets:read`, `work_orders:read`) |
132
+ | `resource:write` | Create, update, and delete records (e.g. `assets:write`, `parts:write`) |
133
+ | `*:*` | Full access to all resources |
134
+
135
+ Write scopes require the corresponding read scope to be useful. When creating an API key, scopes are organized by category (Operations, Facilities, Projects, Finance, etc.) with bulk-toggle controls.
164
136
 
165
137
  ## Security
166
138
 
167
- - The MCP server runs **locally** on your machine via stdio no network server is exposed
168
- - Your API key is scoped to your organization only
169
- - All data access is read-only and logged in AssetLab's audit log
170
- - API keys can be revoked at any time in **Settings → API Keys**
139
+ - Connects via OAuth 2.0 + PKCE through `mcp.assetlab.ca`. Your API key is encrypted in transit and never stored by the MCP server.
140
+ - Your API key is scoped to your organization only.
141
+ - All data access is logged in AssetLab's audit log.
142
+ - API keys can be revoked at any time in **Settings → API Keys**.
143
+ - Write operations require explicit write scopes — read-only by default.
171
144
 
172
145
  ## Support
173
146
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@assetlab/mcp-server",
3
- "version": "1.3.0",
3
+ "version": "1.3.1",
4
4
  "description": "MCP server for AssetLab — connect Claude to your asset management data",
5
5
  "type": "module",
6
6
  "bin": {