lsc-db-schema
Skill10 starsChanged 29 days agoApache-2.0View on GitHub
Manages Life Sciences Cloud (LSC) DB Schema records (mobile object metadata cache configuration). Use when user asks about DB Schema, DbSchema, mobile sync objects, SOQL filter conditions on DbSchema, enabling/disabling objects for mobile, object metadata cache settings, or which objects sync to iPad.
In this repository39 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- roz-uiSkill
- lsc-account-managementSkill
- lsc-activity-planSkill
- lsc-agentforceSkill
- lsc-app-alertsSkill
- lsc-briefingsSkill
- lsc-calendar-tot-routineSkill
- lsc-config-migrationSkill
- lsc-consent-managementSkill
- lsc-custom-scriptsSkill
- lsc-data-migrationSkill
- lsc-data-modelSkill
- lsc-demo-data-loadingSkill
- lsc-events-managementSkill
- lsc-field-emailSkill
- lsc-health-checkSkill
- lsc-home-page-configurationSkill
- lsc-implementation-reviewSkill
- lsc-implementationSkill
- lsc-integration-patternsSkill
- lsc-intelligent-contentSkill
- lsc-key-account-managementSkill
- lsc-lists-filtersSkill
- lsc-mobile-app-settingsSkill
- lsc-mobile-validationSkill
- lsc-next-bestSkill
- lsc-performance-validationSkill
- lsc-product-managementSkill
- lsc-provider-engagement-complianceSkill
- lsc-quick-actions-configurationSkill
- lsc-reporting-analyticsSkill
- lsc-sample-managementSkill
- lsc-surveysSkill
- lsc-territory-alignmentSkill
- lsc-troubleshootSkill
- lsc-user-managementSkill
- lsc-visit-managementSkill
- salesforce-querySkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 3 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Always call MCP tools to get sourced documentation: Do not answer from general knowledge alone.
- Distinctive: line 25
When the user asks about DB Schema configuration, ask them which mode they prefer:
- Distinctive: line 30
Default to guided setup when connected to an org, or documentation mode if no org is connected.
- Very specific: line 46
Use the appropriate dedicated tool (create_db_schema, update_db_schema, toggle_db_schema).
- Very specific: line 51
If user provides profiles: generate_mobile_metadata_cache({ profileNames: ["ProfileName"] })
- Very specific: line 93
Use RecordType.DeveloperName (not RecordTypeId) for record type filtering
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
How to Answer DB Schema Questions
Always call MCP tools to get sourced documentation. Do not answer from general knowledge alone.
| User asks about... | Call this tool |
| DB Schema concepts, field reference, pre-configured records | search_lsc_knowledge({ query: "DB Schema mobile object sync" }) |
| Mobile metadata cache configuration | get_lsc_module_docs({ module: "mobile-metadata-cache" }) |
| List all DB Schema records | list_db_schema() |
| Full details for a specific record | get_db_schema({ name: "Visit" }) |
| Create a new DB Schema record | create_db_schema({ objectName: "Product2" }) |
| Update a DB Schema record | update_db_schema({ name: "Visit", whereSoql: "..." }) |
| Enable/disable a DB Schema record | toggle_db_schema({ name: "Visit", active: false }) |
| Mobile cache status | check_mobile_cache_status() |
Configuration Mode
When the user asks about DB Schema configuration, ask them which mode they prefer:
- Show me the documentation — call
search_lsc_knowledge({ query: "DB Schema configuration" })and present the relevant sections - Walk me through it — configure it directly in their org step-by-step (guided setup below)
Default to guided setup when connected to an org, or documentation mode if no org is connected.
Guided Setup Workflow
Step 1: Check Current State
list_db_schema()Step 2: Report Findings
Present the summary table. Include counts: total records, active, inactive, DATA type, CONFIGURATION type.
Step 3: Propose Changes
Based on the user's request, propose specific changes and wait for user confirmation.
Step 4: Apply Changes (with user confirmation)
Use the appropriate dedicated tool (create_db_schema, update_db_schema, toggle_db_schema).
Step 5: Verify and Remind About Cache
- Re-run
list_db_schema()to confirm changes - Always remind the user: "DbSchema changes require regenerating the mobile metadata cache. Which profiles should I generate the cache for?"
- If user provides profiles:
generate_mobile_metadata_cache({ profileNames: ["ProfileName"] })
Tool Usage Rules
CRITICAL: Use Dedicated DbSchema Tools Only
DB Schema records are LifeSciConfigRecord / LifeSciConfigFieldValue entries accessible ONLY through the Tooling API.
NEVER use these for DbSchema records:
run_soql,get_record,describe_sobject, or ANY standard SOQL/record tool- The following objects DO NOT EXIST in standard SOQL:
LifeSciConfigRecord,LifeSciConfigFieldValue,LifeSciConfigCategory,DbSchema__c,DbSchema__mdt
CORRECT field names: SObject, Type, WhereSoql, DeltaDateField, OneWaySync, AttachmentsSupport, MandatoryFields, PermissionSets, EnableDataUploadNotification, Status, SobjectPlatformEvents, Errors, Category.
WRONG field names (DO NOT USE): EntityType, SOQLFilterCondition, DeltaSyncDateField, WebToMobileSync, AttachmentDownloadMethod.
Field Reference
| Field | Type | Purpose |
SObject | OBJECT | API name of the object to sync |
Type | PICKLIST | DATA (synced records) or CONFIGURATION (metadata-like records) |
WhereSoql | LONGTEXT | WHERE-clause filter (see SOQL Filter Rules below) |
DeltaDateField | FIELD | Field used for delta/incremental sync (default LastModifiedDate) |
OneWaySync | BOOLEAN | true = web→mobile only. Disables offline edit/DCR for the object — see Critical Behaviors |
AttachmentsSupport | PICKLIST | CACHE (during sync), BACKGROUND (after sync), or empty (none) |
MandatoryFields | LONGTEXT | Comma-separated fields that must always sync |
PermissionSets | LONGTEXT | Semicolon-delimited permission set API names that gate sync (in addition to profile assignments). The mobile app syncs the object for users holding any listed permission set. Set via the permissionSets param on create_db_schema/update_db_schema |
EnableDataUploadNotification | BOOLEAN | Whether the app surfaces a data-upload notification for this object |
Status | PICKLIST | Validity status of the record (e.g., VALID) |
SobjectPlatformEvents | — | Platform-event configuration for the object |
Errors | — | Validation/generation errors recorded against the record |
Critical Behaviors (warn the user about these)
- Disabling a DB Schema record is destructive to local iPad data.
toggle_db_schema({ active: false })(or removing the record) is not just a visibility toggle — on each device's next sync the app runsDELETE FROM <table>for objects no longer in the metadata, wiping all locally cached records for that object and any unsynced offline edits. Re-enabling re-syncs from the server, but local-only data does not come back. Only disable when you intend to remove the object from mobile. OneWaySync = truedisables offline edit / DCR for the object. One-way (web→mobile) objects get no offline-tracking columns and are treated as unsyncable for edits — so Data Change Requests and any offline modifications to that object will silently fail. Only useOneWaySyncfor read-only or platform-event-style reference data.
SOQL Filter Rules (WhereSoql)
- Enter only the WHERE clause — no
SELECT,FROM, orWHEREkeyword - Encase the entire condition in parentheses to prevent SQLite errors on mobile
- Use
RecordType.DeveloperName(notRecordTypeId) for record type filtering - Examples:
(IsActive = true),(RecordType.DeveloperName = 'Detail_Visit')
Naming Convention
DbSchema records are named DbSchema_ followed by the object API name (e.g., DbSchema_Account). The dedicated tools accept either "Visit" or "DbSchema_Visit".
After Any DbSchema Change
Always remind the user to regenerate the mobile metadata cache. Ask which profiles, then call generate_mobile_metadata_cache.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

