Use the Lightning Data Service (LDS) MCP Tools (Beta)
The LDS MCP tools help you work better with Salesforce records by providing guidance on the UI API and applying data consistency and referential integrity best practices.
MCP Tools for LWC is a pilot or beta service that is subject to the Beta Services Terms at Agreements - Salesforce.com or a written Unified Pilot Agreement if executed by Customer, and applicable terms in the Product Terms Directory. Use of this pilot or beta service is at the Customer's sole discretion.
guide_lds_development- LDS development guidelines and component integrationguide_lds_data_consistency- Data consistency patterns and best practices for using LDS-based components and wire adaptersguide_lds_referential_integrity- Referential integrity patterns for LDS data managementexplore_lds_uiapi- Explores and documents Lightning Design System UI API capabilitiesorchestrate_lds_data_requirements- Analyzes and clarifies LDS data requirements to produce PRD-ready specifications
When working with these tools using Agentforce Vibes Extension, you must enable the a4d-general-rules-no-edit.md and a4d-lwc-rules-no-edit.md global rules. The a4d-general-rules-no-edit.md rule is enabled by default. For more information on configuring rules in Agentforce Vibes, see Agentforce Rules in the Agentforce Vibes Extension Developer Guide.
Here are some possible prompts that invoke the LDS MCP tools.
Ask about using UI API for LWC development.
- List the available UI API wire adapters and when to use each.
- Generate the UI API field schema and types for
Account.Name, Account.Industry, Contact.Email. - Compare imperative vs wired UI API calls for fetching and updating records.
Ask about maintaining data consistency using LDS-based wire adapters and other data strategies.
- Explain how to use
getRecordNotifyChangeto keep multiple components in sync. - Recommend strategies to handle concurrent edits and stale data with LDS.
- Outline cache invalidation rules when creating, updating, and deleting related records.
Ask about evaluating a component using LDS development guidelines.
- Recommend when to use base components (
lightning-record-form) vs custom LDS wires. - Provide a checklist for building a record editor: validation, errors, toasts, and refresh.
- Suggest performance tips for LDS-heavy pages (field minimization, batching, memoization).
Ask about referential integrity recommendations.
- Describe how to prevent orphaned contact records when deleting a parent account.
- Recommend validations before updating lookups to maintain relationship integrity.
- Handle missing or soft-deleted related records gracefully in UI and data flows.
Ask about LDS data requirements covering objects and fields, relationships, data operations, security, offline considerations, and recommended UI API adapters vs Apex.
- Generate a step-by-step LDS data requirements spec for my LWC.
- Help me define objects, fields, and adapters for my LWC using LDS.
- Create a PRD-ready LDS data access plan for my LWC.
See Also