partnercore-proxy 0.1.4 → 0.4.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.
- package/CHANGELOG.md +136 -6
- package/README.md +168 -130
- package/dist/al/language-server.d.ts +315 -2
- package/dist/al/language-server.d.ts.map +1 -1
- package/dist/al/language-server.js +676 -1
- package/dist/al/language-server.js.map +1 -1
- package/dist/cli.js +3 -1
- package/dist/cli.js.map +1 -1
- package/dist/cloud/relay-client.d.ts +20 -0
- package/dist/cloud/relay-client.d.ts.map +1 -1
- package/dist/cloud/relay-client.js +70 -0
- package/dist/cloud/relay-client.js.map +1 -1
- package/dist/config/types.d.ts.map +1 -1
- package/dist/config/types.js +66 -0
- package/dist/config/types.js.map +1 -1
- package/dist/container/bc-container.d.ts +212 -0
- package/dist/container/bc-container.d.ts.map +1 -0
- package/dist/container/bc-container.js +740 -0
- package/dist/container/bc-container.js.map +1 -0
- package/dist/git/git-operations.d.ts +182 -0
- package/dist/git/git-operations.d.ts.map +1 -0
- package/dist/git/git-operations.js +446 -0
- package/dist/git/git-operations.js.map +1 -0
- package/dist/memory/project-memory.d.ts +83 -0
- package/dist/memory/project-memory.d.ts.map +1 -0
- package/dist/memory/project-memory.js +310 -0
- package/dist/memory/project-memory.js.map +1 -0
- package/dist/router/tool-router.d.ts +63 -0
- package/dist/router/tool-router.d.ts.map +1 -1
- package/dist/router/tool-router.js +2577 -195
- package/dist/router/tool-router.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,137 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.4.0] - 2024-12-26
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
#### AL Language Server Enhancements
|
|
15
|
+
- `al_restart_server` - Restart the language server (recovery from hangs)
|
|
16
|
+
- `al_find_referencing_symbols` - Enhanced reference navigation with context snippets
|
|
17
|
+
- `al_insert_before_symbol` - Insert content before a symbol (for imports, decorators)
|
|
18
|
+
|
|
19
|
+
#### File Operations
|
|
20
|
+
- `find_file` - Find files by pattern with wildcards (*, ?)
|
|
21
|
+
- `replace_content` - Powerful search/replace with regex support
|
|
22
|
+
|
|
23
|
+
#### Memory Management
|
|
24
|
+
- `edit_memory` - Edit memories with search/replace (supports regex)
|
|
25
|
+
|
|
26
|
+
#### BC Container Tools
|
|
27
|
+
- `bc_get_extensions` - List installed apps in container
|
|
28
|
+
- `bc_uninstall_app` - Uninstall apps from container
|
|
29
|
+
- `bc_compile_warnings` - Quick compilation warning check
|
|
30
|
+
|
|
31
|
+
### Changed
|
|
32
|
+
- Total tool count increased from 47 to 57 local tools
|
|
33
|
+
|
|
34
|
+
## [0.3.0] - 2024-12-26
|
|
35
|
+
|
|
36
|
+
### Added
|
|
37
|
+
- **100% LSP Feature Coverage** - Complete implementation of all standard LSP features
|
|
38
|
+
- **BC Container Management** - Full container lifecycle management
|
|
39
|
+
- `bc_create_container` - Create new BC containers with full configuration options
|
|
40
|
+
- `bc_remove_container` - Remove containers with optional force flag
|
|
41
|
+
|
|
42
|
+
#### Core LSP Tools
|
|
43
|
+
- `al_code_actions` - Get quick fixes and refactorings at a position
|
|
44
|
+
- `al_signature_help` - Get function parameter hints
|
|
45
|
+
- `al_format` - Format entire document or a range
|
|
46
|
+
|
|
47
|
+
#### Document Analysis
|
|
48
|
+
- `al_document_highlight` - Highlight all occurrences of symbol under cursor
|
|
49
|
+
- `al_folding_ranges` - Get code folding ranges (regions, procedures, comments)
|
|
50
|
+
- `al_selection_range` - Smart expand/shrink selection
|
|
51
|
+
- `al_semantic_tokens` - Get semantic tokens for syntax highlighting
|
|
52
|
+
|
|
53
|
+
#### Navigation
|
|
54
|
+
- `al_type_definition` - Go to the type of a variable
|
|
55
|
+
- `al_implementation` - Find interface implementations
|
|
56
|
+
|
|
57
|
+
#### Advanced Editing
|
|
58
|
+
- `al_format_on_type` - Format code after typing specific characters
|
|
59
|
+
- `al_code_lens` - Get inline hints (reference counts, run tests)
|
|
60
|
+
- `al_document_links` - Get clickable links in comments
|
|
61
|
+
|
|
62
|
+
#### Lifecycle Management
|
|
63
|
+
- `al_close_document` - Close a document (cleanup resources)
|
|
64
|
+
- `al_save_document` - Send save notification (trigger recompile)
|
|
65
|
+
- `al_execute_command` - Execute LSP commands
|
|
66
|
+
|
|
67
|
+
### Changed
|
|
68
|
+
- AL Language Server now supports all standard LSP features
|
|
69
|
+
- Tool count increased from 35 to 47 local tools
|
|
70
|
+
|
|
71
|
+
## [0.2.0] - 2024-12-26
|
|
72
|
+
|
|
73
|
+
### Added
|
|
74
|
+
|
|
75
|
+
#### Symbol-Based Editing
|
|
76
|
+
- `al_rename_symbol` - Rename symbols across the entire workspace using LSP refactoring
|
|
77
|
+
- `al_insert_after_symbol` - Insert content after a named symbol
|
|
78
|
+
- `al_replace_symbol_body` - Replace the entire body of a symbol
|
|
79
|
+
|
|
80
|
+
#### Advanced File Operations
|
|
81
|
+
- `delete_lines` - Delete a range of lines from a file
|
|
82
|
+
- `replace_lines` - Replace a range of lines with new content
|
|
83
|
+
- `insert_at_line` - Insert content at a specific line number
|
|
84
|
+
|
|
85
|
+
#### Project Memory System
|
|
86
|
+
- `write_memory` - Save project-specific knowledge/memory for future sessions
|
|
87
|
+
- `read_memory` - Read a specific memory by name
|
|
88
|
+
- `list_memories` - List all saved project memories
|
|
89
|
+
- `delete_memory` - Delete a specific memory
|
|
90
|
+
|
|
91
|
+
#### BC Container Tools
|
|
92
|
+
- `bc_list_containers` - List all Business Central Docker containers
|
|
93
|
+
- `bc_compile` - Compile AL project in a BC container with CodeCops
|
|
94
|
+
- `bc_publish` - Publish app to BC container with sync modes
|
|
95
|
+
- `bc_run_tests` - Run automated tests in BC container
|
|
96
|
+
- `bc_container_logs` - Get container logs for debugging
|
|
97
|
+
- `bc_start_container` - Start a stopped container
|
|
98
|
+
- `bc_stop_container` - Stop a running container
|
|
99
|
+
- `bc_restart_container` - Restart a container
|
|
100
|
+
- `bc_download_symbols` - Download symbol files from container
|
|
101
|
+
|
|
102
|
+
#### Git Operations
|
|
103
|
+
- `git_status` - Get current Git status with branch info
|
|
104
|
+
- `git_diff` - Show diff of changes (staged/unstaged)
|
|
105
|
+
- `git_stage` - Stage files for commit
|
|
106
|
+
- `git_commit` - Commit staged changes
|
|
107
|
+
- `git_log` - Show commit history with filters
|
|
108
|
+
- `git_branches` - List Git branches
|
|
109
|
+
- `git_checkout` - Switch/create branches
|
|
110
|
+
- `git_pull` - Pull changes from remote
|
|
111
|
+
- `git_push` - Push commits to remote
|
|
112
|
+
- `git_stash` - Manage Git stashes
|
|
113
|
+
|
|
114
|
+
### Changed
|
|
115
|
+
- AL Language Server now supports rename operations (`workspace/rename`)
|
|
116
|
+
- Added `findSymbolByName` and `getSymbolAtPosition` methods to ALLanguageServer
|
|
117
|
+
- Tool router now supports 30+ new local tools
|
|
118
|
+
|
|
119
|
+
## [0.1.5] - 2024-12-26
|
|
120
|
+
|
|
121
|
+
### Added
|
|
122
|
+
- **NEW**: `al_get_started` tool - Single entry point for AL development
|
|
123
|
+
- Shows workspace status (detected or not)
|
|
124
|
+
- Shows AL Language Server status
|
|
125
|
+
- Shows cloud connection status
|
|
126
|
+
- Lists all available prompts/workflows from PartnerCore MCP
|
|
127
|
+
- Provides step-by-step quick start guide
|
|
128
|
+
- Lists available local and cloud tools
|
|
129
|
+
- Includes helpful tips for AL development
|
|
130
|
+
|
|
131
|
+
### Changed
|
|
132
|
+
- CloudRelayClient now supports fetching prompts from cloud MCP
|
|
133
|
+
- Added `getPrompts()` and `getStatus()` methods to CloudRelayClient
|
|
134
|
+
|
|
135
|
+
## [0.1.4] - 2024-12-26
|
|
136
|
+
|
|
137
|
+
### Fixed
|
|
138
|
+
- Fixed absolute path handling in `sanitizePath` - now allows absolute paths within workspace
|
|
139
|
+
- Fixed CLI version display to read from package.json dynamically
|
|
140
|
+
|
|
10
141
|
## [0.1.1] - 2024-12-26
|
|
11
142
|
|
|
12
143
|
### Changed
|
|
@@ -18,7 +149,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
18
149
|
|
|
19
150
|
### Fixed
|
|
20
151
|
- Removed hardcoded workspace path requirement in MCP configuration
|
|
21
|
-
- Proxy now works seamlessly without manual workspace configuration
|
|
152
|
+
- Proxy now works seamlessly without manual workspace configuration
|
|
22
153
|
|
|
23
154
|
## [0.1.0] - 2024-12-26
|
|
24
155
|
|
|
@@ -60,8 +191,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
60
191
|
- MCP marketplace manifest (`mcp.json`)
|
|
61
192
|
|
|
62
193
|
### Security
|
|
63
|
-
-
|
|
64
|
-
-
|
|
65
|
-
-
|
|
66
|
-
-
|
|
67
|
-
|
|
194
|
+
- Path traversal prevention in file operations
|
|
195
|
+
- API keys never logged
|
|
196
|
+
- HTTPS-only cloud communication
|
|
197
|
+
- Workspace sandboxing for file access
|
package/README.md
CHANGED
|
@@ -1,46 +1,42 @@
|
|
|
1
|
-
#
|
|
1
|
+
# PartnerCore Proxy
|
|
2
2
|
|
|
3
|
-
**
|
|
3
|
+
**Complete MCP server for Business Central AL development**
|
|
4
4
|
|
|
5
|
-
[](https://www.npmjs.com/package/partnercore-proxy)
|
|
6
6
|
[](https://opensource.org/licenses/MIT)
|
|
7
7
|
|
|
8
8
|
## Overview
|
|
9
9
|
|
|
10
|
-
PartnerCore Proxy
|
|
10
|
+
PartnerCore Proxy is a comprehensive MCP (Model Context Protocol) server that brings professional AL development capabilities to AI assistants. It provides:
|
|
11
11
|
|
|
12
|
-
- **
|
|
13
|
-
- **
|
|
14
|
-
- **
|
|
15
|
-
- **
|
|
12
|
+
- **Full AL Language Server** - Complete LSP integration with real compiler diagnostics
|
|
13
|
+
- **BC Container Management** - Create, compile, publish, and test in Docker containers
|
|
14
|
+
- **Git Operations** - Version control directly from AI agents
|
|
15
|
+
- **Project Memory** - Persistent context across sessions
|
|
16
|
+
- **Cloud AI Tools** - Code review, knowledge base, templates (optional)
|
|
16
17
|
|
|
17
18
|
## Quick Start
|
|
18
19
|
|
|
19
|
-
###
|
|
20
|
+
### Installation
|
|
20
21
|
|
|
21
22
|
```bash
|
|
22
|
-
npm install -g
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
### Run with npx (no install)
|
|
26
|
-
|
|
27
|
-
```bash
|
|
28
|
-
npx @ciellos/partnercore-proxy start --workspace /path/to/al-project
|
|
23
|
+
npm install -g partnercore-proxy
|
|
29
24
|
```
|
|
30
25
|
|
|
31
26
|
### MCP Configuration
|
|
32
27
|
|
|
33
28
|
Add to your AI assistant's MCP configuration:
|
|
34
29
|
|
|
35
|
-
**Cursor (`~/.cursor/mcp.json`)
|
|
30
|
+
**Cursor** (`~/.cursor/mcp.json` or `%USERPROFILE%\.cursor\mcp.json`):
|
|
31
|
+
|
|
36
32
|
```json
|
|
37
33
|
{
|
|
38
34
|
"mcpServers": {
|
|
39
|
-
"partnercore": {
|
|
40
|
-
"
|
|
41
|
-
"
|
|
35
|
+
"partnercore-proxy": {
|
|
36
|
+
"type": "stdio",
|
|
37
|
+
"command": "partnercore-proxy",
|
|
38
|
+
"args": ["start"],
|
|
42
39
|
"env": {
|
|
43
|
-
"AL_WORKSPACE_ROOT": "/path/to/your/al-project",
|
|
44
40
|
"PARTNERCORE_API_KEY": "your-api-key"
|
|
45
41
|
}
|
|
46
42
|
}
|
|
@@ -48,13 +44,14 @@ Add to your AI assistant's MCP configuration:
|
|
|
48
44
|
}
|
|
49
45
|
```
|
|
50
46
|
|
|
51
|
-
**Claude Desktop (`claude_desktop_config.json`)
|
|
47
|
+
**Claude Desktop** (`claude_desktop_config.json`):
|
|
48
|
+
|
|
52
49
|
```json
|
|
53
50
|
{
|
|
54
51
|
"mcpServers": {
|
|
55
|
-
"partnercore": {
|
|
52
|
+
"partnercore-proxy": {
|
|
56
53
|
"command": "partnercore-proxy",
|
|
57
|
-
"args": ["start"
|
|
54
|
+
"args": ["start"],
|
|
58
55
|
"env": {
|
|
59
56
|
"PARTNERCORE_API_KEY": "your-api-key"
|
|
60
57
|
}
|
|
@@ -63,78 +60,138 @@ Add to your AI assistant's MCP configuration:
|
|
|
63
60
|
}
|
|
64
61
|
```
|
|
65
62
|
|
|
63
|
+
### First Steps
|
|
64
|
+
|
|
65
|
+
Once configured, start with:
|
|
66
|
+
|
|
67
|
+
```
|
|
68
|
+
al_get_started
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
This shows workspace status, available tools, and suggested workflows.
|
|
72
|
+
|
|
66
73
|
## Features
|
|
67
74
|
|
|
68
|
-
###
|
|
75
|
+
### AL Language Server (57 Tools)
|
|
76
|
+
|
|
77
|
+
| Category | Tools |
|
|
78
|
+
|----------|-------|
|
|
79
|
+
| **Core LSP** | `al_get_symbols`, `al_find_symbol`, `al_find_references`, `al_go_to_definition`, `al_hover`, `al_completion`, `al_get_diagnostics` |
|
|
80
|
+
| **Code Actions** | `al_code_actions`, `al_signature_help`, `al_format`, `al_format_on_type` |
|
|
81
|
+
| **Navigation** | `al_type_definition`, `al_implementation`, `al_document_highlight` |
|
|
82
|
+
| **Symbol Editing** | `al_rename_symbol`, `al_insert_after_symbol`, `al_insert_before_symbol`, `al_replace_symbol_body`, `al_find_referencing_symbols` |
|
|
83
|
+
| **Document** | `al_folding_ranges`, `al_selection_range`, `al_code_lens`, `al_document_links`, `al_semantic_tokens` |
|
|
84
|
+
| **Lifecycle** | `al_close_document`, `al_save_document`, `al_restart_server`, `al_execute_command` |
|
|
85
|
+
|
|
86
|
+
### BC Container Tools
|
|
69
87
|
|
|
70
88
|
| Tool | Description |
|
|
71
89
|
|------|-------------|
|
|
72
|
-
| `
|
|
73
|
-
| `
|
|
74
|
-
| `
|
|
75
|
-
| `
|
|
76
|
-
| `
|
|
77
|
-
| `
|
|
78
|
-
| `
|
|
79
|
-
| `
|
|
80
|
-
| `
|
|
81
|
-
| `
|
|
82
|
-
| `
|
|
90
|
+
| `bc_list_containers` | List all BC Docker containers |
|
|
91
|
+
| `bc_create_container` | Create new BC container |
|
|
92
|
+
| `bc_remove_container` | Remove a container |
|
|
93
|
+
| `bc_start_container` | Start a stopped container |
|
|
94
|
+
| `bc_stop_container` | Stop a running container |
|
|
95
|
+
| `bc_restart_container` | Restart a container |
|
|
96
|
+
| `bc_compile` | Compile AL project with CodeCops |
|
|
97
|
+
| `bc_publish` | Publish app to container |
|
|
98
|
+
| `bc_run_tests` | Run automated tests |
|
|
99
|
+
| `bc_container_logs` | Get container logs |
|
|
100
|
+
| `bc_download_symbols` | Download symbol files |
|
|
101
|
+
| `bc_get_extensions` | List installed apps |
|
|
102
|
+
| `bc_uninstall_app` | Uninstall an app |
|
|
103
|
+
|
|
104
|
+
### Git Operations
|
|
105
|
+
|
|
106
|
+
| Tool | Description |
|
|
107
|
+
|------|-------------|
|
|
108
|
+
| `git_status` | Current Git status with branch info |
|
|
109
|
+
| `git_diff` | Show changes (staged/unstaged) |
|
|
110
|
+
| `git_stage` | Stage files for commit |
|
|
111
|
+
| `git_unstage` | Unstage files |
|
|
112
|
+
| `git_commit` | Commit staged changes |
|
|
113
|
+
| `git_log` | Show commit history |
|
|
114
|
+
| `git_branches` | List branches |
|
|
115
|
+
| `git_checkout` | Switch/create branches |
|
|
116
|
+
| `git_pull` | Pull from remote |
|
|
117
|
+
| `git_push` | Push to remote |
|
|
118
|
+
| `git_stash` | Manage stashes |
|
|
119
|
+
|
|
120
|
+
### File Operations
|
|
121
|
+
|
|
122
|
+
| Tool | Description |
|
|
123
|
+
|------|-------------|
|
|
124
|
+
| `read_file` | Read file contents |
|
|
125
|
+
| `write_file` | Write/create files |
|
|
126
|
+
| `list_files` | List directory contents |
|
|
127
|
+
| `search_files` | Search text in files |
|
|
128
|
+
| `find_file` | Find files by pattern |
|
|
129
|
+
| `replace_content` | Search/replace with regex |
|
|
130
|
+
| `delete_lines` | Delete line range |
|
|
131
|
+
| `replace_lines` | Replace line range |
|
|
132
|
+
| `insert_at_line` | Insert at line number |
|
|
133
|
+
|
|
134
|
+
### Project Memory
|
|
135
|
+
|
|
136
|
+
| Tool | Description |
|
|
137
|
+
|------|-------------|
|
|
138
|
+
| `write_memory` | Save project knowledge |
|
|
139
|
+
| `read_memory` | Read a memory |
|
|
140
|
+
| `list_memories` | List all memories |
|
|
141
|
+
| `delete_memory` | Delete a memory |
|
|
142
|
+
| `edit_memory` | Edit with search/replace |
|
|
83
143
|
|
|
84
144
|
### Cloud Tools (API Key Required)
|
|
85
145
|
|
|
86
146
|
| Tool | Description |
|
|
87
147
|
|------|-------------|
|
|
88
|
-
| `partnercore_review` | AI
|
|
89
|
-
| `
|
|
90
|
-
| `
|
|
91
|
-
| `
|
|
92
|
-
| `
|
|
93
|
-
|
|
94
|
-
|
|
148
|
+
| `partnercore_review` | AI code review (252+ patterns) |
|
|
149
|
+
| `partnercore_kb_search` | Knowledge base search |
|
|
150
|
+
| `partnercore_template` | Production-ready templates |
|
|
151
|
+
| `partnercore_generate` | Generate AL code |
|
|
152
|
+
| `partnercore_validate` | AppSource compliance check |
|
|
153
|
+
|
|
154
|
+
## Recommended Workflow
|
|
155
|
+
|
|
156
|
+
```
|
|
157
|
+
1. al_get_started → See available tools and status
|
|
158
|
+
2. partnercore_kb_search → Search for best practices
|
|
159
|
+
3. partnercore_template → Get code template
|
|
160
|
+
4. write_file → Write the AL code
|
|
161
|
+
5. al_get_diagnostics → Check compilation errors (ALWAYS!)
|
|
162
|
+
6. partnercore_review → Code review
|
|
163
|
+
7. bc_compile → Compile in container
|
|
164
|
+
8. bc_publish → Deploy to container
|
|
165
|
+
9. git_commit → Save your work
|
|
166
|
+
```
|
|
95
167
|
|
|
96
168
|
## CLI Commands
|
|
97
169
|
|
|
98
170
|
```bash
|
|
99
|
-
# Start the MCP
|
|
100
|
-
partnercore-proxy start
|
|
101
|
-
|
|
102
|
-
Options:
|
|
103
|
-
-w, --workspace <path> AL workspace root (containing app.json)
|
|
104
|
-
-v, --verbose Enable verbose logging
|
|
105
|
-
--no-cloud Disable cloud connection (local tools only)
|
|
171
|
+
# Start the MCP server
|
|
172
|
+
partnercore-proxy start
|
|
106
173
|
|
|
107
174
|
# Check configuration
|
|
108
175
|
partnercore-proxy check
|
|
109
176
|
|
|
110
177
|
# Download/update AL extension
|
|
111
178
|
partnercore-proxy download-extension
|
|
179
|
+
|
|
180
|
+
# Show version
|
|
181
|
+
partnercore-proxy --version
|
|
112
182
|
```
|
|
113
183
|
|
|
114
184
|
## Environment Variables
|
|
115
185
|
|
|
116
186
|
| Variable | Required | Description |
|
|
117
187
|
|----------|----------|-------------|
|
|
118
|
-
| `
|
|
119
|
-
| `
|
|
120
|
-
| `
|
|
121
|
-
| `PARTNERCORE_CLOUD_URL` | No | Override cloud URL (takes precedence over ENV) |
|
|
122
|
-
| `LOG_LEVEL` | No | `debug`, `info`, `warn`, `error` (default: `info`) |
|
|
123
|
-
|
|
124
|
-
*Cloud tools require API key. Local tools work without it.
|
|
188
|
+
| `PARTNERCORE_API_KEY` | For cloud | API key for cloud tools |
|
|
189
|
+
| `AL_WORKSPACE_ROOT` | No | Override workspace (auto-detected) |
|
|
190
|
+
| `LOG_LEVEL` | No | debug, info, warn, error |
|
|
125
191
|
|
|
126
|
-
###
|
|
192
|
+
### Automatic Workspace Detection
|
|
127
193
|
|
|
128
|
-
|
|
129
|
-
|-------------|-----|
|
|
130
|
-
| **Production** (default) | `https://partnercore-mcp-prod.agreeablebush-0fe29c4e.eastus.azurecontainerapps.io` |
|
|
131
|
-
| **UAT** | `https://partnercore-mcp-uat.happysand-4085830a.eastus.azurecontainerapps.io` |
|
|
132
|
-
|
|
133
|
-
To use UAT environment:
|
|
134
|
-
```bash
|
|
135
|
-
export PARTNERCORE_ENV=uat
|
|
136
|
-
partnercore-proxy start
|
|
137
|
-
```
|
|
194
|
+
The proxy automatically finds your AL workspace by looking for `app.json`. No hardcoded paths needed!
|
|
138
195
|
|
|
139
196
|
## Architecture
|
|
140
197
|
|
|
@@ -145,90 +202,71 @@ partnercore-proxy start
|
|
|
145
202
|
│
|
|
146
203
|
▼ MCP Protocol (stdio)
|
|
147
204
|
┌─────────────────────────────────────────────────────────────────────┐
|
|
148
|
-
│
|
|
149
|
-
│
|
|
150
|
-
│ │
|
|
151
|
-
│ │
|
|
152
|
-
│
|
|
153
|
-
│
|
|
154
|
-
│
|
|
205
|
+
│ PartnerCore Proxy │
|
|
206
|
+
│ ┌──────────────────┐ ┌──────────────────┐ ┌──────────────────┐ │
|
|
207
|
+
│ │ AL Language │ │ BC Container │ │ Git Operations │ │
|
|
208
|
+
│ │ Server (LSP) │ │ (BcContainerHelper) │ │ (Git CLI) │ │
|
|
209
|
+
│ └──────────────────┘ └──────────────────┘ └──────────────────┘ │
|
|
210
|
+
│ ┌──────────────────┐ ┌──────────────────┐ ┌──────────────────┐ │
|
|
211
|
+
│ │ File System │ │ Project Memory │ │ Cloud Relay │ │
|
|
212
|
+
│ │ (Sandboxed) │ │ (JSON Files) │ │ (PartnerCore) │ │
|
|
213
|
+
│ └──────────────────┘ └──────────────────┘ └──────────────────┘ │
|
|
155
214
|
└─────────────────────────────────────────────────────────────────────┘
|
|
156
|
-
│ │
|
|
157
|
-
▼ ▼
|
|
158
|
-
┌──────────────────┐ ┌─────────────────────────────────┐
|
|
159
|
-
│ Your AL Files │ │ PartnerCore Cloud │
|
|
160
|
-
│ (local only) │ │ - Knowledge Base │
|
|
161
|
-
└──────────────────┘ │ - 252+ Patterns │
|
|
162
|
-
│ - AI Code Review │
|
|
163
|
-
└─────────────────────────────────┘
|
|
164
215
|
```
|
|
165
216
|
|
|
166
217
|
## Security
|
|
167
218
|
|
|
168
|
-
|
|
169
|
-
-
|
|
170
|
-
-
|
|
171
|
-
-
|
|
172
|
-
|
|
173
|
-
### API Key Protection
|
|
174
|
-
- API keys are **never logged** at any level
|
|
175
|
-
- Keys transmitted only over HTTPS
|
|
176
|
-
- Automatic masking in error messages
|
|
177
|
-
|
|
178
|
-
### Network Security
|
|
179
|
-
- Cloud communication uses HTTPS/TLS only
|
|
180
|
-
- Only connects to:
|
|
181
|
-
- `marketplace.visualstudio.com` (Microsoft VS Code Marketplace)
|
|
182
|
-
- `partnercore-mcp-prod.*.azurecontainerapps.io` (PartnerCore Production)
|
|
183
|
-
- `partnercore-mcp-uat.*.azurecontainerapps.io` (PartnerCore UAT)
|
|
184
|
-
|
|
185
|
-
See [SECURITY.md](./SECURITY.md) for full security documentation.
|
|
219
|
+
- **File Sandboxing** - All file operations restricted to workspace
|
|
220
|
+
- **Path Traversal Prevention** - Blocked at multiple levels
|
|
221
|
+
- **API Key Protection** - Never logged, HTTPS only
|
|
222
|
+
- **Memory Isolation** - Project memories stored in `.partnercore/`
|
|
186
223
|
|
|
187
|
-
##
|
|
188
|
-
|
|
189
|
-
1. Visit [https://partnercore.ai](https://partnercore.ai)
|
|
190
|
-
2. Sign up for a PartnerCore account
|
|
191
|
-
3. Generate an API key in your dashboard
|
|
192
|
-
4. Add it to your MCP configuration
|
|
224
|
+
## Requirements
|
|
193
225
|
|
|
194
|
-
**
|
|
226
|
+
- **Node.js** 18.0.0 or higher
|
|
227
|
+
- **Windows/macOS/Linux** for AL Language Server
|
|
228
|
+
- **Docker** for BC Container tools (optional)
|
|
229
|
+
- **Git** for Git operations (optional)
|
|
230
|
+
- **BcContainerHelper** PowerShell module for container tools (optional)
|
|
195
231
|
|
|
196
232
|
## Troubleshooting
|
|
197
233
|
|
|
198
234
|
### "AL Language Server not initialized"
|
|
199
|
-
- Ensure `app.json` exists in your
|
|
200
|
-
-
|
|
201
|
-
|
|
202
|
-
### "File not found" errors
|
|
203
|
-
- Paths must be relative to the workspace root
|
|
204
|
-
- Absolute paths outside workspace are blocked for security
|
|
235
|
+
- Ensure `app.json` exists in your project
|
|
236
|
+
- Run `partnercore-proxy download-extension`
|
|
205
237
|
|
|
206
|
-
### Cloud tools return
|
|
207
|
-
-
|
|
238
|
+
### Cloud tools return errors
|
|
239
|
+
- Check `PARTNERCORE_API_KEY` is set
|
|
208
240
|
- Verify with `partnercore-proxy check`
|
|
209
241
|
|
|
242
|
+
### Container tools fail
|
|
243
|
+
- Install BcContainerHelper: `Install-Module BcContainerHelper -Force`
|
|
244
|
+
- Ensure Docker Desktop is running
|
|
245
|
+
|
|
210
246
|
### Verbose logging
|
|
211
247
|
```bash
|
|
212
|
-
partnercore-proxy start
|
|
248
|
+
LOG_LEVEL=debug partnercore-proxy start
|
|
213
249
|
```
|
|
214
250
|
|
|
215
|
-
##
|
|
216
|
-
|
|
217
|
-
- **Node.js**: 18.0.0 or higher
|
|
218
|
-
- **Operating System**: Windows, macOS, or Linux
|
|
219
|
-
- **AL Project**: Valid `app.json` in workspace
|
|
251
|
+
## Workflows
|
|
220
252
|
|
|
221
|
-
|
|
253
|
+
See [docs/WORKFLOWS.md](../docs/WORKFLOWS.md) for complete workflow diagrams:
|
|
222
254
|
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
255
|
+
| Workflow | Tools |
|
|
256
|
+
|----------|-------|
|
|
257
|
+
| **New AL Object** | KB search → template → write → diagnostics → review |
|
|
258
|
+
| **Code Review** | read → symbols → diagnostics → review → improve |
|
|
259
|
+
| **BC Container** | list → compile → publish → run tests |
|
|
260
|
+
| **Git** | status → diff → stage → commit → push |
|
|
261
|
+
| **Refactoring** | symbols → references → rename → format → diagnostics |
|
|
262
|
+
| **Project Memory** | write → list → read (persist across sessions) |
|
|
228
263
|
|
|
229
264
|
## Links
|
|
230
265
|
|
|
231
266
|
- [PartnerCore Cloud](https://partnercore.ai)
|
|
232
|
-
- [
|
|
233
|
-
- [GitHub Repository](https://github.com/ciellos-dev/partnercore-proxy)
|
|
267
|
+
- [npm Package](https://www.npmjs.com/package/partnercore-proxy)
|
|
234
268
|
- [MCP Specification](https://modelcontextprotocol.io)
|
|
269
|
+
|
|
270
|
+
## License
|
|
271
|
+
|
|
272
|
+
MIT
|