Docs / Templates

v0.1.10 · Study guide

Starter templates

Ship a realistic schema.tpy, sample seeds, and an admin theme instead of an empty project.

What you will learn
  • How to list and apply templates
  • What each starter includes
  • How admin themes work

1. Setup

$ tpy templates list
$ tpy templates show crm
$ tpy new myapp --template crm
$ cd myapp
$ tpy build --skip-db && tpy migrate && tpy seed

2. Included templates

NameModels (summary)
crmCompany, Contact, Deal, Activity
institute-adminTeacher, Course, Batch, Student, Attendance, FeePayment, Exam
inventorySupplier, Warehouse, Product, PurchaseOrder, StockMovement
helpdeskCategory, Agent, SLA, Ticket, Comment
blog-cmsAuthor, Category, Tag, Post, PostTag, Comment

3. How it works

  1. Each template lives under tpy/templates/<name>/ with schema.tpy, admin-theme.json, seeds/, and README.md.
  2. tpy new --template scaffolds the normal project, then copies those files in.
  3. admin-theme.json sets dashboard title, accent color, and landing model for tpy admin.

4. Admin themes

$ tpy admin --template crm
# or place admin-theme.json in the project root

5. Common mistakes

  • Unknown template name — run tpy templates list first.
  • Expecting fake bulk data — starter seeds are small demos; tpy seed --fake is planned separately.

6. Related