Claude Skills
CollectionsCompareWorkflowsNominate
Sign inSign up
© 2026 Curated Agent Skills·Learn more about Agent Skills
Back to repository

frappe-doctype

verified

Create a Frappe Framework v15 DocType with proper controller, service layer, repository, and test files. Triggers: "create doctype", "new doctype", "frappe doctype", "add doctype", "/frappe-doctype". Generates production-ready DocType with type annotations, lifecycle hooks, and multi-layer architecture integration.

View on GitHub

Marketplace

bershadsky-claude-tools

sergio-bershadsky/ai

Plugin

frappe-dev

development

Repository

sergio-bershadsky/ai
4stars

plugins/frappe-dev/skills/frappe-doctype/SKILL.md

Last Verified

February 2, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/sergio-bershadsky/ai/blob/main/plugins/frappe-dev/skills/frappe-doctype/SKILL.md -a claude-code --skill frappe-doctype

Installation paths:

Claude
.claude/skills/frappe-doctype/
Powered by add-skill CLI

Instructions

# Frappe DocType Creation

Create a production-ready Frappe v15 DocType with complete controller implementation, service layer integration, repository pattern, and test coverage.

## When to Use

- Creating a new DocType for a Frappe application
- Need proper controller with lifecycle hooks
- Want service layer for business logic separation
- Require repository for clean data access
- Building submittable/amendable documents

## Arguments

```
/frappe-doctype <doctype_name> [--module <module>] [--submittable] [--child]
```

**Examples:**
```
/frappe-doctype Sales Order
/frappe-doctype Invoice Item --child
/frappe-doctype Purchase Request --submittable
```

## Procedure

### Step 1: Gather DocType Requirements

Ask the user for:

1. **DocType Name** (Title Case, e.g., "Sales Order")
2. **Module** (which module this belongs to)
3. **DocType Type:**
   - Standard (regular CRUD document)
   - Submittable (has workflow: Draft → Submitted → Cancelled)
   - Child Table (embedded in parent documents)
   - Single (configuration/settings document)
4. **Key Fields** (at least the primary fields needed)
5. **Naming Pattern:**
   - Autoname (series like `SO-.YYYY.-.#####`)
   - Field-based (use a specific field value)
   - Prompt (user enters name)

### Step 2: Analyze and Design

Based on requirements, determine:

- Field types and properties
- Link relationships to other DocTypes
- Required indexes for performance
- Permission model (roles that can access)
- Workflow requirements

### Step 3: Generate DocType JSON

Create the DocType definition `<doctype_folder>/<doctype_name>.json`:

```json
{
  "name": "<DocType Name>",
  "module": "<Module>",
  "doctype": "DocType",
  "naming_rule": "By \"Naming Series\" field",
  "autoname": "naming_series:",
  "is_submittable": 0,
  "is_tree": 0,
  "istable": 0,
  "editable_grid": 1,
  "track_changes": 1,
  "track_seen": 1,
  "engine": "InnoDB",
  "fields": [
    {
      "fieldname": "naming_series",
      "fieldtype": "Select",
      "la

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
16351 chars