Agent skill

Data360 Code Extension Generate

by forcedotcom in forcedotcom/sf-skills

Develop and deploy Data Cloud Code Extensions using SF CLI plugin.

Apache-2.0Auto-check passedData & Analytics

Install Data360 Code Extension Generate

skills CLI
$ npx skills add forcedotcom/sf-skills --skill data360-code-extension-generate -a claude-code

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

GitHub CLI
$ gh skill install forcedotcom/sf-skills data360-code-extension-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/data360-code-extension-generate .claude/skills/data360-code-extension-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
data360-code-extension-generate
GitHub stars
1.1k
Token cost
~2.7k tokens
SKILL.md length
1,011 words
Files
3 (incl. references)
Skills in repo
251
Repo updated
First seen
Licence
Apache-2.0

At a glance

Develop and deploy Data Cloud Code Extensions using SF CLI plugin.

  • Works in 6 steps: Initialize Project → Develop Transformation → Scan for Permissions → …
  • Creating custom Python transformations for Data Cloud
  • SKILL.md covers Overview, When to Use, Prerequisites Check and Skill Workflow, plus 7 more sections
  • Calls sf, pip and python

What it does

Data360 Code Extension Generate is an agent skill from forcedotcom/sf-skills. Develop and deploy Data Cloud Code Extensions using SF CLI plugin. Use this skill when creating custom Python transformations for Data Cloud, deploying code extensions, or testing data transformations. Supports init, run, scan, and deploy operations.

Its SKILL.md is about 2.7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/README.md` and `references/quick-reference.md`).

It sits in Data & Analytics, covering Data cleaning. It works with Python and 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

  • Creating custom Python transformations for Data Cloud
  • Deploying code extensions
  • Testing data transformations

Example prompts

  • “/data360-code-extension-generate”

Requirements

  • Python 3
  • Docker

Workflow steps

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

  1. Initialize Project
  2. Develop Transformation
  3. Scan for Permissions
  4. Validate DLO Schema (Pre-Test Check)
  5. Test Locally
  6. Deploy to Data Cloud

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

    Shell commands in SKILL.md call:

    • sf
    • pip
    • python
    • pyenv
    • docker
    • python3

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

  • Network

    Links to these hosts (documentation or services it may open):

    • github.com
    • help.salesforce.com
    • pypi.org

    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

Data360 Code Extension Generate loads about 2.7k tokens when it runs, and up to ~5.7k if it reads all its reference files. Until then it costs about 71 tokens; SKILL.md has 1,011 words of instructions outside code blocks.

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

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,011 words, ~2,729 tokens.

Download SKILL.mdSave it as .claude/skills/data360-code-extension-generate/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
data360-code-extension-generate
description
Develop and deploy Data Cloud Code Extensions using SF CLI plugin. Use this skill when creating custom Python transformations for Data Cloud, deploying code extensions, or testing data transformations. Supports init, run, scan, and deploy operations.
metadata.version
1.0
metadata.domains
Data 360, Developer Experience
metadata.relatedSkills
data360-schema-get

data360-code-extension-generate Skill

Overview

This skill provides a complete workflow for developing, testing, and deploying custom Python code extensions to Salesforce Data Cloud. Code extensions allow you to write Python transformations that read from and write to Data Lake Objects (DLOs) and Data Model Objects (DMOs).

When to Use

  • User wants to create a new code extension project
  • User needs to test a code extension locally
  • User wants to scan code for required permissions
  • User needs to deploy a code extension to Data Cloud
  • User is working with Data Cloud transformations
  • User wants to read/write DLO or DMO data programmatically

Prerequisites Check

Before executing any code extension commands, verify prerequisites:

  1. SF CLI with plugin installed

    bash
    sf plugins --core | grep data-code-extension

    If not installed:

    bash
    sf plugins install @salesforce/plugin-data-code-extension
  2. Python 3.11

    bash
    python --version  # Should show 3.11.x
  3. Data Cloud Custom Code SDK

    bash
    pip list | grep salesforce-data-customcode

    If not installed:

    bash
    pip install salesforce-data-customcode
  4. Docker running (for deploy only)

    bash
    docker ps
  5. Authenticated org

    bash
    sf org display --target-org <org_alias> --json

Skill Workflow

Phase 1: Initialize Project

Create a new code extension project with scaffolding.

Commands:

For script-based code extensions (batch transformations):

bash
sf data-code-extension script init --package-dir <directory>

For function-based code extensions (real-time):

bash
sf data-code-extension function init --package-dir <directory>

Required Option:

  • --package-dir, -p - Directory path where the package will be created

What it creates:

text
my-transform/              # Project root
├── payload/               # CRITICAL: This is what --package-dir must point to for deploy
│   ├── entrypoint.py      # Main transformation code
│   └── config.json        # Code extension configuration
├── requirements.txt       # Python dependencies
└── README.md

Directory Context During Workflow

IMPORTANT: Understanding the directory structure is critical for successful deployment.

Commands and their directory requirements:

CommandRun FromPath/File Argument
initParent directory<project-name> or .
scanProject root./payload/entrypoint.py
runProject root./payload/entrypoint.py
deployProject root--package-dir ./payload (REQUIRED)

CRITICAL: The --package-dir argument in deploy command MUST point to the payload directory, not the project root.

Phase 2: Develop Transformation

Edit payload/entrypoint.py with transformation logic.

Script Example (Batch):

python
from datacustomcode import Client

client = Client()

# Read from DLO
df = client.read_dlo('Employee__dll')

# Transform data (uppercase position field)
df['position_upper'] = df['position'].str.upper()

# Write to output DLO
client.write_to_dlo('Employee_Upper__dll', df, 'overwrite')

Function Example (Real-time):

python
from datacustomcode import FunctionClient

def transform(event, context):
    client = FunctionClient(context)
    input_data = event['data']
    output = {
        'name': input_data['name'].upper(),
        'status': 'processed'
    }
    return output

Common Operations:

  • client.read_dlo('DLO_Name__dll') - Read from DLO
  • client.read_dmo('DMO_Name') - Read from DMO
  • client.write_to_dlo('DLO_Name__dll', df, 'overwrite') - Write to DLO
  • client.write_to_dmo('DMO_Name', df, 'upsert') - Write to DMO
Phase 3: Scan for Permissions

Scan the entrypoint file to detect required permissions and generate config.json.

Command:

bash
sf data-code-extension script scan --entrypoint ./payload/entrypoint.py

What it detects:

  • Read permissions for DLOs/DMOs
  • Write permissions for DLOs/DMOs
  • Python package dependencies
  • Updates config.json and requirements.txt
Phase 4: Validate DLO Schema (Pre-Test Check)

CRITICAL: Before running tests locally, validate that all DLOs used in your code exist and have the expected fields.

Step 4a: Extract DLOs from config.json

After scanning, review the generated config.json to identify all DLOs:

bash
cat payload/config.json
Step 4b: Validate Each DLO Schema

Use the data360-schema-get skill to verify DLOs exist and check field names.

For each DLO referenced in your code:

  1. Verify DLO exists:

    bash
    python3 scripts/get_dlo_schema.py <org_alias> <dlo_name>
  2. Verify field names match — compare fields used in your entrypoint.py against the DLO schema.

  3. Check all DLOs:

    • Validate all DLOs in read permissions
    • Validate all DLOs in write permissions
    • Check field names match exactly (case-sensitive)
    • Verify data types are compatible with operations
Step 4c: Validation Checklist

Before proceeding to run, ensure:

  • All DLOs in config.json exist in target org
  • All field names used in code exist in DLO schemas
  • Field data types match your transformation logic
  • Primary key fields are correctly identified
  • Write target DLOs are created and accessible
Phase 5: Test Locally

After validating DLO schemas, run the code extension locally against your Data Cloud org.

Command:

bash
sf data-code-extension script run --entrypoint <entrypoint_file> --target-org <org_alias> [options]

Options:

  • --target-org, -o - SF CLI org alias (required)
  • --config-file, -c - Custom config file path

If you get errors:

  • Re-validate DLO schemas
  • Check field names are exact matches
  • Verify data types are compatible
  • Review error messages for field/DLO issues
Show full SKILL.md (480 more words)Show less
Phase 6: Deploy to Data Cloud

Deploy the code extension to Data Cloud for scheduled or on-demand execution.

CRITICAL: You MUST specify --package-dir ./payload to point to the payload directory created by init.

Command:

bash
sf data-code-extension script deploy --target-org <org_alias> --name <name> --package-dir ./payload --package-version <version> --description <description> [options]

Required Options:

  • --target-org, -o - SF CLI org alias
  • --name, -n - Name for code extension deployment
  • --package-dir - Path to payload directory (REQUIRED - must be ./payload when running from project root)
  • --package-version - Version string (default: 0.0.1)
  • --description - Description of code extension

Optional Options:

  • --cpu-size - CPU size: CPU_L, CPU_XL, CPU_2XL (default), CPU_4XL
  • --function-invoke-opt - Function invoke options (for function type)
  • --network - Docker network (default: default)

After deployment:

  • Navigate to Data Cloud in Salesforce UI
  • Go to Data Transforms section
  • Find your deployment by name
  • Click "Run Now" to execute
  • Schedule for recurring execution

Error Handling

Common Issues and Solutions
ErrorSolution
command data-code-extension not foundsf plugins install @salesforce/plugin-data-code-extension
datacustomcode CLI not foundpip install salesforce-data-customcode
Python version mismatchUse pyenv: pyenv install 3.11.0 && pyenv local 3.11.0
Cannot connect to Docker daemonStart Docker Desktop
No org found for aliassf org login web --alias <org_alias>
config.json not foundsf data-code-extension script scan --entrypoint ./payload/entrypoint.py
DLO not foundVerify DLO exists (use data360-schema-get skill), check spelling and __dll suffix
Permission denied writingRe-run scan, verify target DLO exists and is writable
Deploy fails - wrong directoryEnsure --package-dir points to payload/ directory, not project root

Best Practices

Development
  1. Always scan before testing — run scan after code changes
  2. Test locally first — use run command before deploying
  3. Use version control — git commit after each successful test
  4. Version your deployments — use semantic versioning (1.0.0, 1.1.0, etc.)
  5. Deploy from project root with --package-dir ./payload
Performance
  • CPU_L: Small datasets (< 1M records)
  • CPU_2XL: Medium datasets (1M-10M records)
  • CPU_4XL: Large datasets (> 10M records)
Security
  1. No hardcoded credentials — use SF CLI authentication only
  2. Validate input data — check for nulls and data types
  3. Limit write permissions — only grant necessary DLO/DMO access

Integration with Other Skills

Use with data360-schema-get skill (CRITICAL for validation):

The data360-schema-get skill is required for validating DLOs before testing code extensions.

Use with Datakit Workflow:

  1. Create DLO via code extension
  2. Map DLO to DMO using datakit workflow
  3. Use DMO in segments and activations

Command Reference

CommandPurposeRequired Args
script initCreate new script project--package-dir
function initCreate new function project--package-dir
script scanGenerate configentrypoint file
script runTest locallyentrypoint file, --target-org
script deployDeploy to Data Cloud--target-org, --name, --package-dir, --package-version, --description

Resources

Notes

  • Code extensions run in isolated Python 3.11 environment
  • Docker is required only for deployment, not for local testing
  • Use SF CLI authentication only (no separate credential files)
  • Scan command auto-detects permissions from code
  • Local run uses actual Data Cloud data (not mocked)
  • Deployments are versioned and can be rolled back in UI

© 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 2 other files (references) in skills/data360-code-extension-generate of forcedotcom/sf-skills.

  • SKILL.md
  • references/README.md
  • references/quick-reference.md

Open the folder on GitHubat commit e5164d9

Compare with similar skills

Data360 Code Extension 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.

Data360 Code Extension Generate compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Data360 Code Extension Generate this skillforcedotcom/sf-skills1.1k—~2.7kAutomated safety check: PassApache-2.0
CRM Data CleanupOneWave-AI/claude-skills3231 repos~2.5kAutomated safety check: PassMIT
Pandas ProJeffallan/claude-skills12k1 repos~1.5kAutomated safety check: PassMIT
Openbb Data Fetchermonarchjuno/vibe-investing299—~2.9kAutomated safety check: NotesMIT
Credit Risk Data Cleaninggithub/awesome-copilot40k1 repos~1.5kAutomated safety check: PassMIT
Aic Collector Op Developmentai-dynamo/aiconfigurator455—~3kAutomated safety check: PassApache-2.0

Similar skills

  • CRM Data Cleanup

    OneWave-AI/claude-skills

    Finds duplicate and junk records in a CRM CSV export with fuzzy matching, normalizes fields and writes a reviewable merge plan plus import-ready files without touching the live CRM.

    323 GitHub starsUsed in 1 repo~2.5k tokens
    Sales & SupportAuto-check passed
  • Pandas Pro

    Jeffallan/claude-skills

    Handles pandas DataFrame work: cleaning, merging, groupby aggregation, pivots, time-series resampling and memory tuning, with checks on dtypes, shapes and nulls.

    12k GitHub starsUsed in 1 repo~1.5k tokens
    Data & AnalyticsAuto-check passed
  • Openbb Data Fetcher

    monarchjuno/vibe-investing

    Fetch financial, market, economic, fundamental, news, options, crypto, ETF, index, and macro data through the OpenBB Python interface instead of the OpenBB MCP server.

    299 GitHub stars~2.9k tokensUpdated 5 mo ago
    Data & AnalyticsAuto-check: notes
  • Credit Risk Data Cleaning

    github/awesome-copilot

    Official

    Cleans raw credit data and screens variables before loan modeling, dropping unstable, noisy or redundant features and writing an Excel report of every step.

    40k GitHub starsUsed in 1 repo~1.5k tokens
    Data & AnalyticsAuto-check passed
  • Aic Collector Op Development

    ai-dynamo/aiconfigurator

    Design, add, review, or modify AIC Collector operations and their case population.

    455 GitHub stars~3k tokensUpdated 19 days ago
    Data & AnalyticsAuto-check passed
  • Code Engineer

    openJiuwen-ai/sciencediscovery

    A skill your agent uses when you need to write and execute Python/R code to process, transform, and analyze data, delivering reproducible computational results with complete code-level methodology…

    151 GitHub stars~2.8k tokensUpdated today
    Data & AnalyticsAuto-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 today
    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 today
    Auto-check passed
  • Apply a Salesforce sandbox post-copy automation JSON config against a target org.

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

    1.1k GitHub stars~5.4k tokensUpdated today
    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 today
    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 today
    Auto-check passed

Questions about Data360 Code Extension Generate

What does Data360 Code Extension Generate do?

Develop and deploy Data Cloud Code Extensions using SF CLI plugin. Data360 Code Extension Generate is an agent skill from forcedotcom/sf-skills. Develop and deploy Data Cloud Code Extensions using SF CLI plugin.

When should I use Data360 Code Extension Generate?

Data360 Code Extension Generate fits situations like: creating custom Python transformations for Data Cloud; deploying code extensions; testing data transformations.

How do I install Data360 Code Extension Generate in Claude Code?

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

How do I install Data360 Code Extension Generate in Codex?

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

Can I use Data360 Code Extension 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 data360-code-extension-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/data360-code-extension-generate, .gemini/skills/data360-code-extension-generate, .github/skills/data360-code-extension-generate and .opencode/skills/data360-code-extension-generate in your project.

What does Data360 Code Extension Generate need to run?

Going by SKILL.md and its folder, Data360 Code Extension Generate needs the command-line tools its instructions call (sf, pip, python, pyenv, docker and python3). Our summary lists: Python 3; Docker.

Does Data360 Code Extension Generate access the network?

SKILL.md names 3 domains. As links in the text: github.com, help.salesforce.com and pypi.org. This is read from the text; nothing was executed.

Is Data360 Code Extension 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 Data360 Code Extension Generate use?

Data360 Code Extension 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 Data360 Code Extension Generate use?

About 2.7k tokens (SKILL.md is roughly 11k 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 2.9k tokens, read only when the agent opens those files.

What are the alternatives to Data360 Code Extension Generate?

Skills that share tags, products or a category with Data360 Code Extension Generate: CRM Data Cleanup (OneWave-AI/claude-skills, 323 stars), Pandas Pro (Jeffallan/claude-skills, 12k stars), Openbb Data Fetcher (monarchjuno/vibe-investing, 299 stars) and Credit Risk Data Cleaning (github/awesome-copilot, 40k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Data360 Code Extension 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.