vibecodingmachine-core 2026.3.9-907 → 2026.3.10-1548
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/package.json +1 -1
- package/src/auth/access-denied.html +119 -119
- package/src/auth/shared-auth-storage.js +267 -267
- package/src/autonomous-mode/feature-implementer.cjs +70 -70
- package/src/autonomous-mode/feature-implementer.js +425 -425
- package/src/beta-request.js +160 -160
- package/src/chat-management/chat-manager.cjs +71 -71
- package/src/chat-management/chat-manager.js +342 -342
- package/src/compliance/compliance-prompt.js +183 -183
- package/src/ide-integration/aider-cli-manager.cjs +850 -850
- package/src/ide-integration/applescript-manager.cjs +3215 -3215
- package/src/ide-integration/applescript-utils.js +314 -314
- package/src/ide-integration/cdp-manager.cjs +221 -221
- package/src/ide-integration/claude-code-cli-manager.cjs +456 -456
- package/src/ide-integration/cline-cli-manager.cjs +2252 -2252
- package/src/ide-integration/continue-cli-manager.js +431 -431
- package/src/ide-integration/provider-manager.cjs +595 -595
- package/src/ide-integration/quota-detector.cjs +399 -399
- package/src/ide-integration/windows-automation-manager.js +532 -4
- package/src/ide-integration/windows-ide-manager.js +12 -3
- package/src/index.cjs +142 -142
- package/src/llm/direct-llm-manager.cjs +1299 -1299
- package/src/localization/index.js +147 -147
- package/src/quota-management/index.js +108 -108
- package/src/requirement-numbering.js +164 -164
- package/src/sync/aws-setup.js +445 -445
- package/src/ui/ButtonComponents.js +247 -247
- package/src/ui/ChatInterface.js +499 -499
- package/src/ui/StateManager.js +259 -259
- package/src/utils/audit-logger.cjs +116 -116
- package/src/utils/config-helpers.cjs +94 -94
- package/src/utils/config-helpers.js +94 -94
- package/src/utils/env-helpers.js +54 -54
- package/src/utils/error-reporter.js +117 -117
- package/src/utils/gcloud-auth.cjs +394 -394
- package/src/utils/git-branch-manager.js +278 -278
- package/src/utils/logger.cjs +193 -193
- package/src/utils/logger.js +191 -191
- package/src/utils/repo-helpers.cjs +120 -120
- package/src/utils/repo-helpers.js +120 -120
- package/src/utils/update-checker.js +246 -246
- package/src/utils/version-checker.js +170 -170
package/src/beta-request.js
CHANGED
|
@@ -1,160 +1,160 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Beta Request Management for VibeCodingMachine
|
|
3
|
-
*
|
|
4
|
-
* Handles beta access requests from web, CLI, and GUI applications
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
const crypto = require('crypto');
|
|
8
|
-
|
|
9
|
-
class BetaRequestManager {
|
|
10
|
-
constructor(apiBaseUrl = null) {
|
|
11
|
-
this.apiBaseUrl = apiBaseUrl || process.env.VIBECODINGMACHINE_API_URL || 'https://api.vibecodingmachine.com';
|
|
12
|
-
this.authToken = null;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Set authentication token for API requests
|
|
17
|
-
*/
|
|
18
|
-
setAuthToken(token) {
|
|
19
|
-
this.authToken = token;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* Make authenticated API request
|
|
24
|
-
*/
|
|
25
|
-
async apiRequest(endpoint, options = {}) {
|
|
26
|
-
const url = `${this.apiBaseUrl}${endpoint}`;
|
|
27
|
-
const headers = {
|
|
28
|
-
'Content-Type': 'application/json',
|
|
29
|
-
...options.headers
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
if (this.authToken) {
|
|
33
|
-
headers.Authorization = `Bearer ${this.authToken}`;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
const fetch = globalThis.fetch || require('node-fetch');
|
|
37
|
-
const response = await fetch(url, {
|
|
38
|
-
...options,
|
|
39
|
-
headers
|
|
40
|
-
});
|
|
41
|
-
|
|
42
|
-
if (!response.ok) {
|
|
43
|
-
const error = await response.json().catch(() => ({ error: 'Network error' }));
|
|
44
|
-
throw new Error(error.error || `HTTP ${response.status}`);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
return response.json();
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/**
|
|
51
|
-
* Submit a beta access request
|
|
52
|
-
*/
|
|
53
|
-
async submitBetaRequest(requestData) {
|
|
54
|
-
try {
|
|
55
|
-
const result = await this.apiRequest('/api/beta/request', {
|
|
56
|
-
method: 'POST',
|
|
57
|
-
body: JSON.stringify({
|
|
58
|
-
...requestData,
|
|
59
|
-
requestDate: Date.now(),
|
|
60
|
-
status: 'REQUEST'
|
|
61
|
-
})
|
|
62
|
-
});
|
|
63
|
-
return result;
|
|
64
|
-
} catch (error) {
|
|
65
|
-
console.error('Beta request submission failed:', error);
|
|
66
|
-
throw error;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* Check if user already has a pending or approved request
|
|
72
|
-
*/
|
|
73
|
-
async checkExistingRequest(email) {
|
|
74
|
-
try {
|
|
75
|
-
const userId = this.generateUserId(email);
|
|
76
|
-
const result = await this.apiRequest(`/api/users/${userId}`);
|
|
77
|
-
return result.user;
|
|
78
|
-
} catch (error) {
|
|
79
|
-
// User doesn't exist or API error
|
|
80
|
-
return null;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
/**
|
|
85
|
-
* Validate request data
|
|
86
|
-
*/
|
|
87
|
-
validateRequestData(data) {
|
|
88
|
-
const errors = [];
|
|
89
|
-
|
|
90
|
-
if (!data.email || !data.email.trim()) {
|
|
91
|
-
errors.push('Email is required');
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
if (data.email && !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(data.email)) {
|
|
95
|
-
errors.push('Invalid email format');
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
if (!data.name || !data.name.trim()) {
|
|
99
|
-
errors.push('Name is required');
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
if (!data.language) {
|
|
103
|
-
errors.push('Language preference is required');
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
if (!data.appPurpose || !data.appPurpose.trim()) {
|
|
107
|
-
errors.push('App purpose description is required');
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
return {
|
|
111
|
-
isValid: errors.length === 0,
|
|
112
|
-
errors
|
|
113
|
-
};
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
* Get supported languages
|
|
118
|
-
*/
|
|
119
|
-
getSupportedLanguages() {
|
|
120
|
-
return {
|
|
121
|
-
'en': 'English',
|
|
122
|
-
'es': 'Spanish'
|
|
123
|
-
};
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
/**
|
|
127
|
-
* Generate user ID from email (consistent with existing system)
|
|
128
|
-
*/
|
|
129
|
-
generateUserId(email) {
|
|
130
|
-
return crypto.createHash('sha256').update(email.toLowerCase()).digest('hex').substring(0, 16);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
/**
|
|
134
|
-
* Format request data for email notification
|
|
135
|
-
*/
|
|
136
|
-
formatRequestForEmail(requestData) {
|
|
137
|
-
const supportedLanguages = this.getSupportedLanguages();
|
|
138
|
-
const languageName = supportedLanguages[requestData.language] || requestData.language;
|
|
139
|
-
|
|
140
|
-
return {
|
|
141
|
-
recipient: 'jesse.d.olsen@gmail.com',
|
|
142
|
-
subject: `New Beta Request: ${requestData.name} (${requestData.email})`,
|
|
143
|
-
body: `
|
|
144
|
-
New VibeCodingMachine beta access request received:
|
|
145
|
-
|
|
146
|
-
Name: ${requestData.name}
|
|
147
|
-
Email: ${requestData.email}
|
|
148
|
-
Language: ${languageName}
|
|
149
|
-
App Purpose: ${requestData.appPurpose}
|
|
150
|
-
Other Info: ${requestData.otherInfo || 'None provided'}
|
|
151
|
-
Request Date: ${new Date(requestData.requestDate).toLocaleString()}
|
|
152
|
-
Source: ${requestData.source || 'Unknown'}
|
|
153
|
-
|
|
154
|
-
Please review and approve/reject this request in the admin panel.
|
|
155
|
-
`.trim()
|
|
156
|
-
};
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
module.exports = BetaRequestManager;
|
|
1
|
+
/**
|
|
2
|
+
* Beta Request Management for VibeCodingMachine
|
|
3
|
+
*
|
|
4
|
+
* Handles beta access requests from web, CLI, and GUI applications
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
const crypto = require('crypto');
|
|
8
|
+
|
|
9
|
+
class BetaRequestManager {
|
|
10
|
+
constructor(apiBaseUrl = null) {
|
|
11
|
+
this.apiBaseUrl = apiBaseUrl || process.env.VIBECODINGMACHINE_API_URL || 'https://api.vibecodingmachine.com';
|
|
12
|
+
this.authToken = null;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Set authentication token for API requests
|
|
17
|
+
*/
|
|
18
|
+
setAuthToken(token) {
|
|
19
|
+
this.authToken = token;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Make authenticated API request
|
|
24
|
+
*/
|
|
25
|
+
async apiRequest(endpoint, options = {}) {
|
|
26
|
+
const url = `${this.apiBaseUrl}${endpoint}`;
|
|
27
|
+
const headers = {
|
|
28
|
+
'Content-Type': 'application/json',
|
|
29
|
+
...options.headers
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
if (this.authToken) {
|
|
33
|
+
headers.Authorization = `Bearer ${this.authToken}`;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
const fetch = globalThis.fetch || require('node-fetch');
|
|
37
|
+
const response = await fetch(url, {
|
|
38
|
+
...options,
|
|
39
|
+
headers
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
if (!response.ok) {
|
|
43
|
+
const error = await response.json().catch(() => ({ error: 'Network error' }));
|
|
44
|
+
throw new Error(error.error || `HTTP ${response.status}`);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
return response.json();
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Submit a beta access request
|
|
52
|
+
*/
|
|
53
|
+
async submitBetaRequest(requestData) {
|
|
54
|
+
try {
|
|
55
|
+
const result = await this.apiRequest('/api/beta/request', {
|
|
56
|
+
method: 'POST',
|
|
57
|
+
body: JSON.stringify({
|
|
58
|
+
...requestData,
|
|
59
|
+
requestDate: Date.now(),
|
|
60
|
+
status: 'REQUEST'
|
|
61
|
+
})
|
|
62
|
+
});
|
|
63
|
+
return result;
|
|
64
|
+
} catch (error) {
|
|
65
|
+
console.error('Beta request submission failed:', error);
|
|
66
|
+
throw error;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Check if user already has a pending or approved request
|
|
72
|
+
*/
|
|
73
|
+
async checkExistingRequest(email) {
|
|
74
|
+
try {
|
|
75
|
+
const userId = this.generateUserId(email);
|
|
76
|
+
const result = await this.apiRequest(`/api/users/${userId}`);
|
|
77
|
+
return result.user;
|
|
78
|
+
} catch (error) {
|
|
79
|
+
// User doesn't exist or API error
|
|
80
|
+
return null;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* Validate request data
|
|
86
|
+
*/
|
|
87
|
+
validateRequestData(data) {
|
|
88
|
+
const errors = [];
|
|
89
|
+
|
|
90
|
+
if (!data.email || !data.email.trim()) {
|
|
91
|
+
errors.push('Email is required');
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
if (data.email && !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(data.email)) {
|
|
95
|
+
errors.push('Invalid email format');
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
if (!data.name || !data.name.trim()) {
|
|
99
|
+
errors.push('Name is required');
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
if (!data.language) {
|
|
103
|
+
errors.push('Language preference is required');
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
if (!data.appPurpose || !data.appPurpose.trim()) {
|
|
107
|
+
errors.push('App purpose description is required');
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
return {
|
|
111
|
+
isValid: errors.length === 0,
|
|
112
|
+
errors
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Get supported languages
|
|
118
|
+
*/
|
|
119
|
+
getSupportedLanguages() {
|
|
120
|
+
return {
|
|
121
|
+
'en': 'English',
|
|
122
|
+
'es': 'Spanish'
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* Generate user ID from email (consistent with existing system)
|
|
128
|
+
*/
|
|
129
|
+
generateUserId(email) {
|
|
130
|
+
return crypto.createHash('sha256').update(email.toLowerCase()).digest('hex').substring(0, 16);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
/**
|
|
134
|
+
* Format request data for email notification
|
|
135
|
+
*/
|
|
136
|
+
formatRequestForEmail(requestData) {
|
|
137
|
+
const supportedLanguages = this.getSupportedLanguages();
|
|
138
|
+
const languageName = supportedLanguages[requestData.language] || requestData.language;
|
|
139
|
+
|
|
140
|
+
return {
|
|
141
|
+
recipient: 'jesse.d.olsen@gmail.com',
|
|
142
|
+
subject: `New Beta Request: ${requestData.name} (${requestData.email})`,
|
|
143
|
+
body: `
|
|
144
|
+
New VibeCodingMachine beta access request received:
|
|
145
|
+
|
|
146
|
+
Name: ${requestData.name}
|
|
147
|
+
Email: ${requestData.email}
|
|
148
|
+
Language: ${languageName}
|
|
149
|
+
App Purpose: ${requestData.appPurpose}
|
|
150
|
+
Other Info: ${requestData.otherInfo || 'None provided'}
|
|
151
|
+
Request Date: ${new Date(requestData.requestDate).toLocaleString()}
|
|
152
|
+
Source: ${requestData.source || 'Unknown'}
|
|
153
|
+
|
|
154
|
+
Please review and approve/reject this request in the admin panel.
|
|
155
|
+
`.trim()
|
|
156
|
+
};
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
module.exports = BetaRequestManager;
|
|
@@ -1,71 +1,71 @@
|
|
|
1
|
-
// @vibecodingmachine/core - Chat Manager (CommonJS) - Stub
|
|
2
|
-
// Handles chat message management, polling, and response detection
|
|
3
|
-
|
|
4
|
-
class ChatManager {
|
|
5
|
-
constructor(options = {}) {
|
|
6
|
-
this.logger = options.logger || console;
|
|
7
|
-
this.electronAPI = options.electronAPI || null;
|
|
8
|
-
this.onMessageUpdate = options.onMessageUpdate || (() => {});
|
|
9
|
-
this.onStatusUpdate = options.onStatusUpdate || (() => {});
|
|
10
|
-
this.onProgressUpdate = options.onProgressUpdate || (() => {});
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
async sendMessage(message, ide, tabId) {
|
|
14
|
-
this.logger.log('sendMessage stub called with:', { message: message.substring(0, 50) + '...', ide, tabId });
|
|
15
|
-
return {
|
|
16
|
-
success: true,
|
|
17
|
-
method: 'stub',
|
|
18
|
-
message: 'Message sent via stub'
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
startPolling(ide, tabId) {
|
|
23
|
-
this.logger.log('startPolling stub for:', ide, tabId);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
stopPolling() {
|
|
27
|
-
this.logger.log('stopPolling stub');
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
pause() {
|
|
31
|
-
this.logger.log('pause stub');
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
resume() {
|
|
35
|
-
this.logger.log('resume stub');
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
stop() {
|
|
39
|
-
this.logger.log('stop stub');
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
reset() {
|
|
43
|
-
this.logger.log('reset stub');
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
getState() {
|
|
47
|
-
return {
|
|
48
|
-
isPolling: false,
|
|
49
|
-
isPaused: false,
|
|
50
|
-
isStopped: false
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
setElectronAPI(electronAPI) {
|
|
55
|
-
this.electronAPI = electronAPI;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
setCallbacks(callbacks) {
|
|
59
|
-
if (callbacks.onMessageUpdate) {
|
|
60
|
-
this.onMessageUpdate = callbacks.onMessageUpdate;
|
|
61
|
-
}
|
|
62
|
-
if (callbacks.onStatusUpdate) {
|
|
63
|
-
this.onStatusUpdate = callbacks.onStatusUpdate;
|
|
64
|
-
}
|
|
65
|
-
if (callbacks.onProgressUpdate) {
|
|
66
|
-
this.onProgressUpdate = callbacks.onProgressUpdate;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
module.exports = { ChatManager };
|
|
1
|
+
// @vibecodingmachine/core - Chat Manager (CommonJS) - Stub
|
|
2
|
+
// Handles chat message management, polling, and response detection
|
|
3
|
+
|
|
4
|
+
class ChatManager {
|
|
5
|
+
constructor(options = {}) {
|
|
6
|
+
this.logger = options.logger || console;
|
|
7
|
+
this.electronAPI = options.electronAPI || null;
|
|
8
|
+
this.onMessageUpdate = options.onMessageUpdate || (() => {});
|
|
9
|
+
this.onStatusUpdate = options.onStatusUpdate || (() => {});
|
|
10
|
+
this.onProgressUpdate = options.onProgressUpdate || (() => {});
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
async sendMessage(message, ide, tabId) {
|
|
14
|
+
this.logger.log('sendMessage stub called with:', { message: message.substring(0, 50) + '...', ide, tabId });
|
|
15
|
+
return {
|
|
16
|
+
success: true,
|
|
17
|
+
method: 'stub',
|
|
18
|
+
message: 'Message sent via stub'
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
startPolling(ide, tabId) {
|
|
23
|
+
this.logger.log('startPolling stub for:', ide, tabId);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
stopPolling() {
|
|
27
|
+
this.logger.log('stopPolling stub');
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
pause() {
|
|
31
|
+
this.logger.log('pause stub');
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
resume() {
|
|
35
|
+
this.logger.log('resume stub');
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
stop() {
|
|
39
|
+
this.logger.log('stop stub');
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
reset() {
|
|
43
|
+
this.logger.log('reset stub');
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
getState() {
|
|
47
|
+
return {
|
|
48
|
+
isPolling: false,
|
|
49
|
+
isPaused: false,
|
|
50
|
+
isStopped: false
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
setElectronAPI(electronAPI) {
|
|
55
|
+
this.electronAPI = electronAPI;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
setCallbacks(callbacks) {
|
|
59
|
+
if (callbacks.onMessageUpdate) {
|
|
60
|
+
this.onMessageUpdate = callbacks.onMessageUpdate;
|
|
61
|
+
}
|
|
62
|
+
if (callbacks.onStatusUpdate) {
|
|
63
|
+
this.onStatusUpdate = callbacks.onStatusUpdate;
|
|
64
|
+
}
|
|
65
|
+
if (callbacks.onProgressUpdate) {
|
|
66
|
+
this.onProgressUpdate = callbacks.onProgressUpdate;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
module.exports = { ChatManager };
|