Agent skill

Platform Custom Report Type Generate

by forcedotcom in forcedotcom/sf-skills

A skill your agent uses to create, generate, or validate Salesforce Custom Report Type metadata.

Apache-2.0Auto-check passedSales & Support

Install Platform Custom Report Type Generate

skills CLI
$ npx skills add forcedotcom/sf-skills --skill platform-custom-report-type-generate -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install forcedotcom/sf-skills platform-custom-report-type-generate --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/forcedotcom/sf-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/platform-custom-report-type-generate .claude/skills/platform-custom-report-type-generate && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
platform-custom-report-type-generate
GitHub stars
1.1k
Token cost
~3.5k tokens
SKILL.md length
1,613 words
Files
6 (incl. references)
Skills in repo
251
Repo updated
First seen
Licence
Apache-2.0

At a glance

A skill your agent uses to create, generate, or validate Salesforce Custom Report Type metadata.

  • Works in 5 steps: Gather Requirements → Examine Existing Examples → Write the Specification → …
  • Validate Salesforce Custom Report Type metadata
  • SKILL.md covers Specification, Overview, Purpose and Configuration, plus 4 more sections
  • Reaches soap.sforce.com

What it does

Platform Custom Report Type Generate is an agent skill from forcedotcom/sf-skills. Use to create, generate, or validate Salesforce Custom Report Type metadata. Trigger on custom report types, CRTs, cross-object reports, report builder data sources, exposing fields for reporting across related objects, inner vs outer joins in reports, report type categories, or deployment errors for .reportType-meta.xml files. Do NOT trigger for running, editing, or filtering existing reports; creating report folders, dashboards, or list views; or non-authoring reporting questions.

Its SKILL.md is about 3.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/category-values.md` and `references/errors-and-troubleshooting.md`).

It sits in Sales & Support, covering CRM management. It works with Salesforce. The repository describes itself as: Salesforce's curated collection of agent skills for building applications. Optimized for Agentforce Vibes, compatible with all AI tools. The licence is Apache-2.0.

When your agent uses it

  • Validate Salesforce Custom Report Type metadata
  • Custom report types
  • Cross-object reports
  • Report builder data sources

Example prompts

  • “/platform-custom-report-type-generate”

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. Gather Requirements
  2. Examine Existing Examples
  3. Write the Specification
  4. Author the Metadata File
  5. Validate

What it can do on your machine

Read from SKILL.md and the folder at commit e5164d9. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are xml).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • soap.sforce.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Platform Custom Report Type Generate loads about 3.5k tokens when it runs, and up to ~4.5k if it reads all its reference files. Until then it costs about 131 tokens; SKILL.md has 1,613 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~131
When it runs · the whole SKILL.md, loaded when a task matches
~3.5k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~4.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from forcedotcom/sf-skills at commit e5164d9, republished under its Apache-2.0 licence (© forcedotcom). 1,613 words, ~3,529 tokens.

Download SKILL.mdSave it as .claude/skills/platform-custom-report-type-generate/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.
name
platform-custom-report-type-generate
description
Use to create, generate, or validate Salesforce Custom Report Type metadata. Trigger on custom report types, CRTs, cross-object reports, report builder data sources, exposing fields for reporting across related objects, inner vs outer joins in reports, report type categories, or deployment errors for .reportType-meta.xml files. Do NOT trigger for running, editing, or filtering existing reports; creating report folders, dashboards, or list views; or non-authoring reporting questions.
metadata.version
1.0
metadata.domains
Platform
metadata.minApiVersion
51.0

Specification

Salesforce Custom Report Type Metadata Knowledge

Overview

Custom Report Types (CRTs) define the data framework for Salesforce reports. They specify a primary object, up to 3 related objects, the relationship (join) between them, and which fields are available in the report builder.

Purpose

  • Enable reporting across custom objects and custom relationships not covered by standard report types
  • Curate a focused set of fields for report builders (including fields reached via lookup)
  • Control inner/outer join behavior to include or exclude primary records without related records

Configuration

File extension: .reportType-meta.xml. The file basename is the report type's developer name (e.g. AccountsWithProjects.reportType-meta.xml). Each CRT is a single file, not nested under an object folder.

Key Elements

Top-level <ReportType> children:

ElementRequiredNotes
<fullName>YesAPI identifier; must match the file name. Letters, numbers, underscores; must begin with a letter; no spaces; no trailing underscore; no consecutive underscores
<label>YesHuman-friendly name shown in the report type picker
<description>RecommendedState the business "why" — who uses this and what they learn
<baseObject>YesAPI name of the primary object (e.g. Account, Project__c). Cannot be changed after initial creation. All objects, including custom and external, are supported (external objects from API 38.0+)
<category>RecommendedReport builder category — see references/category-values.md
<deployed>Yestrue to expose to users; false while building/iterating
<join>ConditionalAdds a related object and its join behavior. Nest further <join> blocks for deeper relationships
<sections>RecommendedGroups of columns available to the report type. Though not strictly required, a report without columns isn't useful

<sections> (group of columns) sub-elements:

ElementRequiredNotes
<masterLabel>YesSection heading shown in the report builder
<columns>ConditionalOne per field exposed in the section

<columns> (single field) sub-elements:

ElementRequiredNotes
<field>YesField API name (or dotted lookup-traversal path)
<table>YesThe object the field belongs to — base object name or dotted relationship path
<checkedByDefault>Yestrue if the column is selected by default in the report builder
<displayNameOverride>NoCustom column label shown in the report builder, overriding the field's default label

Critical Rules (Read First)

Rule 1: If <fullName> Is Present, It Must Match the File Name

In source format, fullName is inherited from Metadata and derived from the file name, so the <fullName> element is technically optional. The repo convention is to include it. If you include <fullName>, its value must equal the file name (everything before .reportType-meta.xml) exactly — same characters, same casing, same underscores.

Wrong — file name and <fullName> differ:

  • File: account_projects.reportType-meta.xml
  • <fullName>AccountProjects</fullName> (Mismatch: file uses account_projects, fullName uses AccountProjects)

Right — file name and <fullName> are identical:

  • File: AccountProjects.reportType-meta.xml
  • <fullName>AccountProjects</fullName>
Rule 2: Join Semantics — outerJoin Controls Inclusion

Each <join> block has an <outerJoin> element that determines which primary records appear in the report:

<outerJoin> valueBehaviorReport Builder Label
falseInner join — only primary records that HAVE at least one related record"Each 'A' record must have at least one related 'B' record"
trueOuter join — all primary records, with or without related records"'A' records may or may not have related 'B' records"

Default when unspecified: Use true (outer join) when the user wants to see all primary records regardless of children. Use false when the report only makes sense if children exist.

Rule 3: Each Object Needs Its Own <sections> Block

Every object in the CRT (primary + each joined object) must have a corresponding <sections> block that lists the fields exposed for reporting. Without a section for an object, none of its fields appear in the report builder.

  • <masterLabel> on each section is the section heading in the report builder
  • <columns> entries list the fields — each with a <field> (API name) and <table> (object API name)
  • For fields reached via lookup, use the relationship path in <field> (e.g. Owner.Name with <table> set to the owning object)
Rule 4: Field API Names, Not Labels

Use exact API names for fields: standard fields use their defined names (Name, CreatedDate, OwnerId), custom fields use Field__c. Custom objects must include __c.

Wrong:

  • <field>Account Name</field>

Right:

  • <field>Name</field> with <table>Account</table>
Rule 5: Relationship Path for Joined Objects

When adding a <join>, the <relationship> element must use the child relationship name as defined on the lookup/master-detail field pointing from the child object to the parent. For custom relationships, this typically ends in __r.

Wrong:

  • <relationship>Project</relationship> (for a custom child relationship)

Right:

  • <relationship>Projects__r</relationship> (child relationship name)
  • <relationship>Contacts</relationship> (standard, non-custom child relationship)
Rule 6: Maximum 4 Objects Total in a Join Chain

A single CRT can join a maximum of four objects total (the base object + up to 3 additional objects via nested <join> blocks).

Rule 7: No Inner Join After an Outer Join

Once the join chain contains an outer join (<outerJoin>true</outerJoin>), every subsequent nested join must also be an outer join. An inner join that follows an outer join earlier in the sequence is not allowed.

Wrong:

xml
<join>
    <outerJoin>true</outerJoin>        <!-- outer join first -->
    <relationship>Contacts</relationship>
    <join>
        <outerJoin>false</outerJoin>   <!-- WRONG: inner join after outer -->
        <relationship>Assets</relationship>
    </join>
</join>

Right:

xml
<join>
    <outerJoin>true</outerJoin>
    <relationship>Contacts</relationship>
    <join>
        <outerJoin>true</outerJoin>    <!-- outer stays outer -->
        <relationship>Assets</relationship>
    </join>
</join>
Rule 8: <table> for Joined Objects Uses Dotted Path

In <sections>, the <table> element identifies which object in the join chain each column belongs to. For the base object, use the object name directly (e.g. Account). For joined objects, use the dotted relationship path from the base object.

Object in chain<table> value
Base (Account)Account
First join (Account → Contacts)Account.Contacts
Nested join (Account → Contacts → Assets)Account.Contacts.Assets
Rule 9: Field Paths Can Traverse Lookups

<field> values may reference fields reached via lookup relationships using dot notation — for example Owner.Email (owner User's email) or ReportsTo.CreatedBy.Contact.Owner.MobilePhone. The <table> must still be the object that owns the starting field.

For a field with trackTrending=true, the API name in <field> and <table> uses the _hst suffix:

xml
<columns>
    <checkedByDefault>false</checkedByDefault>
    <field>Field2__c_hst</field>
    <table>CustomTrendedObject__c.CustomTrendedObject__c_hst</table>
</columns>
Rule 11: Primary Object Cannot Be Changed After Deployment

Once deployed, the <baseObject> of a CRT is locked. To change the primary object, create a new CRT and retire the old one.

Show full SKILL.md (649 more words)Show less

The <autogenerated> element (API 29.0+) marks CRTs that Salesforce created automatically when historical trending was enabled on an object. Do not set this manually on hand-authored CRTs.

Generation Workflow

Step 1: Gather Requirements
  • Primary object API name (e.g. Account, Project__c)
  • Related objects and the relationship between each (which has the lookup/master-detail to which)
  • For each relationship: inner join (children required) or outer join (children optional)?
  • Which fields to expose per object — aim for task-relevant, not the full field list
  • Audience and category — where should this appear in the report builder picker?
  • Whether this ships as deployed=true now or stays deployed=false during iteration
Step 2: Examine Existing Examples
  • Look in the project for in-project CRT patterns
  • If existing report types have been retrieved from an org, compare against those structures
Step 3: Write the Specification

Document before authoring:

  • fullName and label
  • baseObject
  • Category and deployed state
  • Join chain: for each related object — relationship name, outer vs inner join
  • Section layout: one section per object, ordered list of fields
  • Acceptance criteria: which records should appear when the report runs, which fields are available in the builder
Step 4: Author the Metadata File

Start from the closest example in examples/ and adapt it to the user's scenario:

  • Primary object only (no joins) → examples/AccountsWithIndustry.reportType-meta.xml
  • Outer join (primary records included even without children) → examples/AccountsWithProjects.reportType-meta.xml
  • Nested inner join (every level requires children) → examples/AccountProjectsWithTasks.reportType-meta.xml

Name the file <DeveloperName>.reportType-meta.xml.

Step 5: Validate
  • Well-formed XML with correct namespace (xmlns="http://soap.sforce.com/2006/04/metadata")
  • File name (without .reportType-meta.xml) matches <fullName> when <fullName> is included
  • <baseObject> is a valid API name and the object is deployed
  • Every <relationship> uses the correct child relationship name (__r suffix for custom)
  • Each object referenced in <sections> is part of the CRT (primary or joined)
  • All <field> references exist on the parent <table> and use API names (not labels)
  • <category> is a valid Salesforce category value
  • <deployed> is true if users need to access the CRT immediately

Reference File Index

FileWhen to read
examples/AccountsWithIndustry.reportType-meta.xmlStep 2 / Step 4 — primary-object-only template
examples/AccountsWithProjects.reportType-meta.xmlStep 2 / Step 4 — outer-join template (primary included even without children)
examples/AccountProjectsWithTasks.reportType-meta.xmlStep 2 / Step 4 — nested inner-join template (every level requires children)
references/category-values.mdStep 3 — to choose a valid <category> value from the ReportTypeCategory enum
references/errors-and-troubleshooting.mdWhen fields don't appear in the report builder or join requirements conflict

Verification Checklist

Universal Checks
  • File extension is .reportType-meta.xml
  • File basename satisfies the developer-name rules (begins with a letter, only letters/numbers/underscores, no spaces, no trailing underscore, no consecutive underscores)
  • If <fullName> is included, it matches the file basename exactly (same characters, casing, and underscores)
  • <label> is human-readable and under 40 characters
  • <description> explains the business purpose
  • <baseObject> uses a valid API name and that object is deployed
  • <category> is a valid ReportTypeCategory enum value
  • <deployed> is set appropriately (true for user access, false for in-progress iteration)
  • <autogenerated> is NOT set manually (reserved for historical-trending CRTs)
Join Checks
  • Each <join> uses the correct child relationship name (not the lookup field API name)
  • Custom relationships use __r suffix
  • <outerJoin> is set intentionally: true = optional children, false = required children
  • No inner join (<outerJoin>false</outerJoin>) appears after an outer join earlier in the sequence
  • Total object count (base + joins, including nested) is 4 or fewer
Section Checks
  • Every object in the CRT has a corresponding <sections> block
  • <masterLabel> on each section is descriptive
  • Every <columns> has both <field> (API name) and <table> (object API name or dotted path)
  • <checkedByDefault> is set for each column
  • <table> for base object is the object API name (e.g. Account)
  • <table> for joined objects uses the dotted relationship path (e.g. Account.Projects__r, Account.Projects__r.Tasks__r)
  • Field references use API names (not labels); custom fields use __c
  • Lookup traversal fields use dot notation (e.g. Owner.Email) with <table> set to the object owning the starting field
  • Historical trending fields use _hst suffix in both <field> and <table> when applicable
  • No duplicate fields within a section

© forcedotcom, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 5 other files (references) in skills/platform-custom-report-type-generate of forcedotcom/sf-skills.

  • SKILL.md
  • examples/AccountProjectsWithTasks.reportType-meta.xml
  • examples/AccountsWithIndustry.reportType-meta.xml
  • examples/AccountsWithProjects.reportType-meta.xml
  • references/category-values.md
  • references/errors-and-troubleshooting.md

Open the folder on GitHubat commit e5164d9

Compare with similar skills

Platform Custom Report Type Generate next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Platform Custom Report Type Generate compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Platform Custom Report Type Generate this skillforcedotcom/sf-skills1.1k—~3.5kAutomated safety check: PassApache-2.0
Soql Lib Query Builderbeyond-the-cloud-dev/soql-lib154—~4.3kAutomated safety check: PassMIT
Sf DatacloudJaganpro/sf-skills424—~2.7kAutomated safety check: PassMIT
Soql Lib Selectorbeyond-the-cloud-dev/soql-lib154—~2kAutomated safety check: PassMIT
Dev SetupPortwood-Global-Solutions/Portwood125—~1.1kAutomated safety check: PassApache-2.0
Sf FlowJaganpro/sf-skills424—~1.8kAutomated safety check: PassMIT

Similar skills

  • Soql Lib Query Builder

    beyond-the-cloud-dev/soql-lib

    Builds Salesforce SOQL queries using the SOQL Lib fluent builder API (SOQL.cls).

    154 GitHub stars~4.3k tokensUpdated 5 days ago
    Sales & SupportAuto-check passed
  • Sf Datacloud

    Jaganpro/sf-skills

    Salesforce Data Cloud product orchestrator for connect→prepare→harmonize→segment→act workflows.

    424 GitHub stars~2.7k tokensUpdated 5 mo ago
    Sales & SupportAuto-check passed
  • Soql Lib Selector

    beyond-the-cloud-dev/soql-lib

    Creates Salesforce Apex selector classes using the SOQL Lib selector pattern.

    154 GitHub stars~2k tokensUpdated 5 days ago
    Sales & SupportAuto-check passed
  • Dev Setup

    Portwood-Global-Solutions/Portwood

    Get from a fresh clone of Portwood to a working, fully-tested Salesforce org.

    125 GitHub stars~1.1k tokensUpdated today
    Sales & SupportAuto-check passed
  • Sf Flow

    Jaganpro/sf-skills

    Creates and validates Salesforce Flows with 110-point scoring.

    424 GitHub stars~1.8k tokensUpdated 5 mo ago
    Sales & SupportAuto-check passed
  • Google Maps Export

    gmapsscraper/google-maps-agent-skills

    Export Google Maps business data to CSV, JSON, or CRM format (HubSpot, Pipedrive, Salesforce).

    132 GitHub stars~1.2k tokensUpdated 4 mo ago
    Sales & SupportAuto-check passed

More from forcedotcom/sf-skills

All 251 skills in this repo
  • Agentforce Architecture Analyze

    forcedotcom/sf-skills

    Declared architecture snapshot for one Agentforce agent: planner, topics, actions, flows, Apex, prompt templates, and NGA plugins.

    1.1k GitHub stars~4.5k tokensUpdated yesterday
    Auto-check passed
  • Agentforce D360 Analyze

    forcedotcom/sf-skills

    Data Cloud 360° view of a single Agentforce session. An agent skill from forcedotcom/sf-skills.

    1.1k GitHub stars~3.4k tokensUpdated yesterday
    Auto-check passed
  • Apply a Salesforce sandbox post-copy automation JSON config against a target org.

    1.1k GitHub stars~5.3k tokensUpdated yesterday
    Auto-check: notes
  • Apply a Salesforce sandbox post-copy automation JSON config against a target org.

    1.1k GitHub stars~5.4k tokensUpdated yesterday
    Auto-check: notes
  • Design Systems Slds Apply

    forcedotcom/sf-skills

    Apply SLDS-compliant UI using the correct blueprints, styling hooks, utility classes, and icons.

    1.1k GitHub stars~3.7k tokensUpdated yesterday
    Auto-check passed
  • Experience Lwc Generate

    forcedotcom/sf-skills

    Lightning Web Components with PICKLES methodology and 165-point scoring.

    1.1k GitHub stars~2.4k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Platform Custom Report Type Generate

What does Platform Custom Report Type Generate do?

A skill your agent uses to create, generate, or validate Salesforce Custom Report Type metadata. Platform Custom Report Type Generate is an agent skill from forcedotcom/sf-skills. Use to create, generate, or validate Salesforce Custom Report Type metadata.

When should I use Platform Custom Report Type Generate?

Platform Custom Report Type Generate fits situations like: validate Salesforce Custom Report Type metadata; custom report types; cross-object reports; report builder data sources.

How do I install Platform Custom Report Type Generate in Claude Code?

Run `npx skills add forcedotcom/sf-skills --skill platform-custom-report-type-generate -a claude-code`. Or copy the skill folder (skills/platform-custom-report-type-generate in forcedotcom/sf-skills) into .claude/skills/platform-custom-report-type-generate in your project. Claude Code loads it when a task matches its description.

How do I install Platform Custom Report Type Generate in Codex?

Run `npx skills add forcedotcom/sf-skills --skill platform-custom-report-type-generate -a codex`. Or copy the skill folder (skills/platform-custom-report-type-generate in forcedotcom/sf-skills) into .agents/skills/platform-custom-report-type-generate in your project. Codex loads it when a task matches its description.

Can I use Platform Custom Report Type Generate in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add forcedotcom/sf-skills --skill platform-custom-report-type-generate -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/platform-custom-report-type-generate, .gemini/skills/platform-custom-report-type-generate, .github/skills/platform-custom-report-type-generate and .opencode/skills/platform-custom-report-type-generate in your project.

What does Platform Custom Report Type Generate need to run?

SKILL.md names no scripts, command-line tools or credentials: Platform Custom Report Type Generate is instructions for the agent only.

Does Platform Custom Report Type Generate access the network?

SKILL.md names 1 domain. In commands or code: soap.sforce.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is Platform Custom Report Type Generate safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Platform Custom Report Type Generate use?

Platform Custom Report Type Generate is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Platform Custom Report Type Generate use?

About 3.5k tokens (SKILL.md is roughly 14k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1k tokens, read only when the agent opens those files.

What are the alternatives to Platform Custom Report Type Generate?

Skills that share tags, products or a category with Platform Custom Report Type Generate: Soql Lib Query Builder (beyond-the-cloud-dev/soql-lib, 154 stars), Sf Datacloud (Jaganpro/sf-skills, 424 stars), Soql Lib Selector (beyond-the-cloud-dev/soql-lib, 154 stars) and Dev Setup (Portwood-Global-Solutions/Portwood, 125 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Platform Custom Report Type Generate?

forcedotcom (a GitHub organization) maintains it in forcedotcom/sf-skills, which has 1,060 GitHub stars. The repository holds 251 skills in this directory. The repository was last updated on October 7, 2026.

Source: forcedotcom/sf-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.