Skip to content

Commit 347da76

Browse files
W-19689010: update the mobile-mcp-server tool names to follow DX CLI tool guidance (#233)
* feat: update the mobile-mcp-server tool names to follow DX CLI tool fashion * fix: changes based on feedback --------- Co-authored-by: Willhoit <iowillhoit@users.noreply.github.com>
1 parent cc87209 commit 347da76

File tree

10 files changed

+74
-60
lines changed

10 files changed

+74
-60
lines changed

README.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -293,31 +293,31 @@ Includes these tools:
293293

294294
Includes these tools, which aren't yet generally available:
295295

296-
- `sf-mobile-web-app-review` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC App Review Service, offering expert guidance for implementing app review features in Lightning Web Components.
297-
- `sf-mobile-web-ar-space-capture` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC AR Space Capture, offering expert guidance for implementing AR space capture features in Lightning Web Components.
298-
- `sf-mobile-web-barcode-scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Barcode Scanner, offering expert guidance for implementing barcode scanning features in Lightning Web Components.
299-
- `sf-mobile-web-biometrics` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Biometrics Service, offering expert guidance for implementing biometric authentication features in Lightning Web Components.
300-
- `sf-mobile-web-calendar` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Calendar Service, offering expert guidance for implementing calendar integration features in Lightning Web Components.
301-
- `sf-mobile-web-contacts` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Contacts Service, offering expert guidance for implementing contacts management features in Lightning Web Components.
302-
- `sf-mobile-web-document-scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Document Scanner, offering expert guidance for implementing document scanning features in Lightning Web Components.
303-
- `sf-mobile-web-geofencing` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Geofencing Service, offering expert guidance for implementing geofencing features in Lightning Web Components.
304-
- `sf-mobile-web-location` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Location Service, offering expert guidance for implementing location services in Lightning Web Components.
305-
- `sf-mobile-web-nfc` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC NFC Service, offering expert guidance for implementing NFC features in Lightning Web Components.
306-
- `sf-mobile-web-payments` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Payments Service, offering expert guidance for implementing payment processing features in Lightning Web Components.
307-
- `sf-mobile-web-offline-analysis` - (NON-GA) Analyzes Lightning Web Components for mobile-specific issues and provides detailed recommendations for mobile offline compatibility and performance improvements.
308-
- `sf-mobile-web-offline-guidance` - (NON-GA) Provides structured review instructions to detect and remediate mobile offline code violations in Lightning Web Components for Salesforce Mobile Apps.
296+
- `create_mobile_lwc_app_review` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC App Review Service, offering expert guidance for implementing app review features in Lightning Web Components.
297+
- `create_mobile_lwc_ar_space_capture` - (NON-GA) Provides TypeScript API documentation for Salesforce L WC AR Space Capture, offering expert guidance for implementing AR space capture features in Lightning Web Components.
298+
- `create_mobile_lwc_barcode_scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Barcode Scanner, offering expert guidance for implementing barcode scanning features in Lightning Web Components.
299+
- `create_mobile_lwc_biometrics` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Biometrics Service, offering expert guidance for implementing biometric authentication features in Lightning Web Components.
300+
- `create_mobile_lwc_calendar` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Calendar Service, offering expert guidance for implementing calendar integration features in Lightning Web Components.
301+
- `create_mobile_lwc_contacts` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Contacts Service, offering expert guidance for implementing contacts management features in Lightning Web Components.
302+
- `create_mobile_lwc_document_scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Document Scanner, offering expert guidance for implementing document scanning features in Lightning Web Components.
303+
- `create_mobile_lwc_geofencing` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Geofencing Service, offering expert guidance for implementing geofencing features in Lightning Web Components.
304+
- `create_mobile_lwc_location` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Location Service, offering expert guidance for implementing location services in Lightning Web Components.
305+
- `create_mobile_lwc_nfc` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC NFC Service, offering expert guidance for implementing NFC features in Lightning Web Components.
306+
- `create_mobile_lwc_payments` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Payments Service, offering expert guidance for implementing payment processing features in Lightning Web Components.
307+
- `get_mobile_lwc_offline_analysis` - (NON-GA) Analyzes Lightning Web Components for mobile-specific issues and provides detailed recommendations for mobile offline compatibility and performance improvements.
308+
- `get_mobile_lwc_offline_guidance` - (NON-GA) Provides structured review instructions to detect and remediate mobile offline code violations in Lightning Web Components for Salesforce Mobile Apps.
309309

310310
**NOTE:** The tools marked NON-GA are not yet generally available, specify the `--allow-non-ga-tools` flag to use them.
311311

312312
#### Mobile-core Toolset
313313

314314
Includes these essential mobile tools, which aren't yet generally available:
315315

316-
- `sf-mobile-web-barcode-scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Barcode Scanner, offering expert guidance for implementing barcode scanning features in Lightning Web Components.
317-
- `sf-mobile-web-biometrics` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Biometrics Service, offering expert guidance for implementing biometric authentication features in Lightning Web Components.
318-
- `sf-mobile-web-location` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Location Service, offering expert guidance for implementing location services in Lightning Web Components.
319-
- `sf-mobile-web-offline-analysis` - (NON-GA) Analyzes Lightning Web Components for mobile-specific issues and provides detailed recommendations for mobile offline compatibility and performance improvements.
320-
- `sf-mobile-web-offline-guidance` - (NON-GA) Provides structured review instructions to detect and remediate mobile offline code violations in Lightning Web Components for Salesforce Mobile Apps.
316+
- `create_mobile_lwc_barcode_scanner` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Barcode Scanner, offering expert guidance for implementing barcode scanning features in Lightning Web Components.
317+
- `create_mobile_lwc_biometrics` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Biometrics Service, offering expert guidance for implementing biometric authentication features in Lightning Web Components.
318+
- `create_mobile_lwc_location` - (NON-GA) Provides TypeScript API documentation for Salesforce LWC Location Service, offering expert guidance for implementing location services in Lightning Web Components.
319+
- `get_mobile_lwc_offline_analysis` - (NON-GA) Analyzes Lightning Web Components for mobile-specific issues and provides detailed recommendations for mobile offline compatibility and performance improvements.
320+
- `get_mobile_lwc_offline_guidance` - (NON-GA) Provides structured review instructions to detect and remediate mobile offline code violations in Lightning Web Components for Salesforce Mobile Apps.
321321

322322
**NOTE:** The tools marked NON-GA are not yet generally available, specify the `--allow-non-ga-tools` flag to use them.
323323

packages/mcp-provider-mobile-web/src/provider.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@
1515
*/
1616

1717
import { McpProvider, McpTool, Services } from '@salesforce/mcp-provider-api';
18-
import { NativeCapabilityTool } from './tools/native-capabilities/sf-mobile-native-capability.js';
19-
import { OfflineAnalysisTool } from './tools/offline-analysis/sf-mobile-web-offline-analysis.js';
20-
import { OfflineGuidanceTool } from './tools/offline-guidance/sf-mobile-web-offline-guidance.js';
18+
import { NativeCapabilityTool } from './tools/native-capabilities/create_mobile_lwc_native_capabilities.js';
19+
import { OfflineAnalysisTool } from './tools/offline-analysis/get_mobile_lwc_offline_analysis.js';
20+
import { OfflineGuidanceTool } from './tools/offline-guidance/get_mobile_lwc_offline_guidance.js';
2121
import { nativeCapabilityConfigs } from './tools/native-capabilities/nativeCapabilityConfig.js';
2222

2323
export class MobileWebMcpProvider extends McpProvider {

packages/mcp-provider-mobile-web/src/tools/native-capabilities/sf-mobile-native-capability.ts renamed to packages/mcp-provider-mobile-web/src/tools/native-capabilities/create_mobile_lwc_native_capabilities.ts

File renamed without changes.

packages/mcp-provider-mobile-web/src/tools/native-capabilities/nativeCapabilityConfig.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export const AppReviewConfig: NativeCapabilityConfig = {
2727
description:
2828
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC App Review Service, laying the foundation for understanding mobile app review and offering expert-level guidance for implementing the App Review feature in a Lightning Web Component (LWC).',
2929
title: 'Salesforce Mobile App Review LWC Native Capability',
30-
toolId: 'sf-mobile-web-app-review',
30+
toolId: 'create_mobile_lwc_app_review',
3131
typeDefinitionPath: 'appReview/appReviewService.d.ts',
3232
groundingDescription:
3333
'The following content provides grounding information for generating a Salesforce LWC that leverages app review facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the app review API of the mobile device, within the LWC.',
@@ -39,7 +39,7 @@ const ArSpaceCaptureConfig: NativeCapabilityConfig = {
3939
description:
4040
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC AR Space Capture, laying the foundation for understanding mobile AR space capture and offering expert-level guidance for implementing the AR Space Capture feature in a Lightning Web Component (LWC).',
4141
title: 'Salesforce Mobile AR Space Capture LWC Native Capability',
42-
toolId: 'sf-mobile-web-ar-space-capture',
42+
toolId: 'create_mobile_lwc_ar_space_capture',
4343
typeDefinitionPath: 'arSpaceCapture/arSpaceCapture.d.ts',
4444
groundingDescription:
4545
'The following content provides grounding information for generating a Salesforce LWC that leverages AR Space Capture facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the AR Space Capture API of the mobile device, within the LWC.',
@@ -51,7 +51,7 @@ const BarcodeScannerConfig: NativeCapabilityConfig = {
5151
description:
5252
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Barcode Scanner, laying the foundation for understanding mobile barcode scanner and offering expert-level guidance for implementing the Barcode Scanner feature in a Lightning Web Component (LWC).',
5353
title: 'Salesforce Mobile Barcode Scanner LWC Native Capability',
54-
toolId: 'sf-mobile-web-barcode-scanner',
54+
toolId: 'create_mobile_lwc_barcode_scanner',
5555
typeDefinitionPath: 'barcodeScanner/barcodeScanner.d.ts',
5656
groundingDescription:
5757
'The following content provides grounding information for generating a Salesforce LWC that leverages barcode scanning facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the barcode scanning API of the mobile device, within the LWC.',
@@ -63,7 +63,7 @@ const BiometricsConfig: NativeCapabilityConfig = {
6363
description:
6464
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Biometrics Service, laying the foundation for understanding mobile biometrics and offering expert-level guidance for implementing the Biometrics feature in a Lightning Web Component (LWC).',
6565
title: 'Salesforce Mobile Biometrics Service LWC Native Capability',
66-
toolId: 'sf-mobile-web-biometrics',
66+
toolId: 'create_mobile_lwc_biometrics',
6767
typeDefinitionPath: 'biometrics/biometricsService.d.ts',
6868
groundingDescription:
6969
'The following content provides grounding information for generating a Salesforce LWC that leverages biometrics scanning facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the face recognition and the finger printing scanner of the mobile device to authorize the user, within the LWC.',
@@ -75,7 +75,7 @@ const CalendarConfig: NativeCapabilityConfig = {
7575
description:
7676
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Calendar Service, laying the foundation for understanding mobile calendar and offering expert-level guidance for implementing the Calendar feature in a Lightning Web Component (LWC).',
7777
title: 'Salesforce Mobile Calendar Service LWC Native Capability',
78-
toolId: 'sf-mobile-web-calendar',
78+
toolId: 'create_mobile_lwc_calendar',
7979
typeDefinitionPath: 'calendar/calendarService.d.ts',
8080
groundingDescription:
8181
'The following content provides grounding information for generating a Salesforce LWC that leverages calendar facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the calendar API of the mobile device, within the LWC.',
@@ -87,7 +87,7 @@ const ContactsConfig: NativeCapabilityConfig = {
8787
description:
8888
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Contacts Service, laying the foundation for understanding mobile contacts and offering expert-level guidance for implementing the Contacts feature in a Lightning Web Component (LWC).',
8989
title: 'Salesforce Mobile Contacts Service LWC Native Capability',
90-
toolId: 'sf-mobile-web-contacts',
90+
toolId: 'create_mobile_lwc_contacts',
9191
typeDefinitionPath: 'contacts/contactsService.d.ts',
9292
groundingDescription:
9393
'The following content provides grounding information for generating a Salesforce LWC that leverages contacts facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the contacts API of the mobile device, within the LWC.',
@@ -99,7 +99,7 @@ const DocumentScannerConfig: NativeCapabilityConfig = {
9999
description:
100100
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Document Scanner, laying the foundation for understanding mobile document scanner and offering expert-level guidance for implementing the Document Scanner feature in a Lightning Web Component (LWC).',
101101
title: 'Salesforce Mobile Document Scanner LWC Native Capability',
102-
toolId: 'sf-mobile-web-document-scanner',
102+
toolId: 'create_mobile_lwc_document_scanner',
103103
typeDefinitionPath: 'documentScanner/documentScanner.d.ts',
104104
groundingDescription:
105105
'The following content provides grounding information for generating a Salesforce LWC that leverages document scanning facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the document scanner API of the mobile device, within the LWC.',
@@ -111,7 +111,7 @@ const GeofencingConfig: NativeCapabilityConfig = {
111111
description:
112112
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Geofencing Service, laying the foundation for understanding mobile geofencing and offering expert-level guidance for implementing the Geofencing feature in a Lightning Web Component (LWC).',
113113
title: 'Salesforce Mobile Geofencing Service LWC Native Capability',
114-
toolId: 'sf-mobile-web-geofencing',
114+
toolId: 'create_mobile_lwc_geofencing',
115115
typeDefinitionPath: 'geofencing/geofencingService.d.ts',
116116
groundingDescription:
117117
'The following content provides grounding information for generating a Salesforce LWC that leverages geofencing facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the geofencing API of the mobile device, within the LWC.',
@@ -123,7 +123,7 @@ const LocationConfig: NativeCapabilityConfig = {
123123
description:
124124
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Location Service, laying the foundation for understanding mobile location and offering expert-level guidance for implementing the Location feature in a Lightning Web Component (LWC).',
125125
title: 'Salesforce Mobile Location Services LWC Native Capability',
126-
toolId: 'sf-mobile-web-location',
126+
toolId: 'create_mobile_lwc_location',
127127
typeDefinitionPath: 'location/locationService.d.ts',
128128
groundingDescription:
129129
'The following content provides grounding information for generating a Salesforce LWC that leverages location facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the location API of the mobile device, within the LWC.',
@@ -135,7 +135,7 @@ const NfcConfig: NativeCapabilityConfig = {
135135
description:
136136
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC NFC Service, laying the foundation for understanding mobile NFC and offering expert-level guidance for implementing the NFC feature in a Lightning Web Component (LWC).',
137137
title: 'Salesforce Mobile NFC Service LWC Native Capability',
138-
toolId: 'sf-mobile-web-nfc',
138+
toolId: 'create_mobile_lwc_nfc',
139139
typeDefinitionPath: 'nfc/nfcService.d.ts',
140140
groundingDescription:
141141
'The following content provides grounding information for generating a Salesforce LWC that leverages NFC facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the NFC API of the mobile device, within the LWC.',
@@ -147,7 +147,7 @@ const PaymentsConfig: NativeCapabilityConfig = {
147147
description:
148148
'The MCP tool provides a comprehensive TypeScript-based API documentation for Salesforce LWC Payments Service, laying the foundation for understanding mobile payments and offering expert-level guidance for implementing the Payments feature in a Lightning Web Component (LWC).',
149149
title: 'Salesforce Mobile Payments Service LWC Native Capability',
150-
toolId: 'sf-mobile-web-payments',
150+
toolId: 'create_mobile_lwc_payments',
151151
typeDefinitionPath: 'payments/paymentsService.d.ts',
152152
groundingDescription:
153153
'The following content provides grounding information for generating a Salesforce LWC that leverages payments facilities on mobile devices. Specifically, this context will cover the API types and methods available to leverage the payments API of the mobile device, within the LWC.',

packages/mcp-provider-mobile-web/src/tools/offline-analysis/sf-mobile-web-offline-analysis.ts renamed to packages/mcp-provider-mobile-web/src/tools/offline-analysis/get_mobile_lwc_offline_analysis.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ export class OfflineAnalysisTool extends McpTool<InputArgsShape, OutputArgsShape
6666
}
6767

6868
public getName(): string {
69-
return 'sf-mobile-web-offline-analysis';
69+
return 'get_mobile_lwc_offline_analysis';
7070
}
7171

7272
public getConfig(): McpToolConfig<InputArgsShape, OutputArgsShape> {

packages/mcp-provider-mobile-web/src/tools/offline-guidance/sf-mobile-web-offline-guidance.ts renamed to packages/mcp-provider-mobile-web/src/tools/offline-guidance/get_mobile_lwc_offline_guidance.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export class OfflineGuidanceTool extends McpTool<InputArgsShape, OutputArgsShape
4747
}
4848

4949
public getName(): string {
50-
return 'sf-mobile-web-offline-guidance';
50+
return 'get_mobile_lwc_offline_guidance';
5151
}
5252

5353
public getConfig(): McpToolConfig<InputArgsShape, OutputArgsShape> {

packages/mcp-provider-mobile-web/test/provider.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616

1717
import { McpProvider, McpTool, Services } from '@salesforce/mcp-provider-api';
1818
import { MobileWebMcpProvider } from '../src/provider.js';
19-
import { NativeCapabilityTool } from '../src/tools/native-capabilities/sf-mobile-native-capability.js';
20-
import { OfflineAnalysisTool } from '../src/tools/offline-analysis/sf-mobile-web-offline-analysis.js';
21-
import { OfflineGuidanceTool } from '../src/tools/offline-guidance/sf-mobile-web-offline-guidance.js';
19+
import { NativeCapabilityTool } from '../src/tools/native-capabilities/create_mobile_lwc_native_capabilities.js';
20+
import { OfflineAnalysisTool } from '../src/tools/offline-analysis/get_mobile_lwc_offline_analysis.js';
21+
import { OfflineGuidanceTool } from '../src/tools/offline-guidance/get_mobile_lwc_offline_guidance.js';
2222
import { StubServices } from './test-doubles.js';
2323

2424
describe('Tests for MobileWebMcpProvider', () => {

0 commit comments

Comments
 (0)