Kyle Alas-as kyle
  • Joined on 2025-09-18

create-twenty-app (1.0.1)

Published 2026-03-28 15:31:37 +00:00 by kyle

Installation

registry=
npm install create-twenty-app@1.0.1
"create-twenty-app": "1.0.1"

About this package

Twenty logo

Create Twenty App

NPM version License Join the community on Discord

Create Twenty App is the official scaffolding CLI for building apps on top of Twenty CRM. It sets up a ready‑to‑run project that works seamlessly with the twenty-sdk.

  • Zero‑config project bootstrap
  • Preconfigured scripts for auth, dev mode (watch & sync), uninstall, and function management
  • Strong TypeScript support and typed client generation

Documentation

See Twenty application documentation https://docs.twenty.com/developers/extend/capabilities/apps

Prerequisites

Quick start

npx create-twenty-app@latest my-twenty-app
cd my-twenty-app

# Get help and list all available commands
yarn twenty help

# Authenticate using your API key (you'll be prompted)
yarn twenty auth:login

# Add a new entity to your application (guided)
yarn twenty entity:add

# Start dev mode: watches, builds, and syncs local changes to your workspace
# (also auto-generates typed CoreApiClient — MetadataApiClient ships pre-built with the SDK — both available via `twenty-sdk/clients`)
yarn twenty app:dev

# Watch your application's function logs
yarn twenty function:logs

# Execute a function with a JSON payload
yarn twenty function:execute -n my-function -p '{"key": "value"}'

# Execute the pre-install function
yarn twenty function:execute --preInstall

# Execute the post-install function
yarn twenty function:execute --postInstall

# Uninstall the application from the current workspace
yarn twenty app:uninstall

Scaffolding modes

Control which example files are included when creating a new app:

Flag Behavior
-e, --exhaustive (default) Creates all example files
-m, --minimal Creates only core files (application-config.ts and default-role.ts)
# Default: all examples included
npx create-twenty-app@latest my-app

# Minimal: only core files
npx create-twenty-app@latest my-app -m

What gets scaffolded

Core files (always created):

  • application-config.ts — Application metadata configuration
  • roles/default-role.ts — Default role for logic functions
  • logic-functions/pre-install.ts — Pre-install logic function (runs before app installation)
  • logic-functions/post-install.ts — Post-install logic function (runs after app installation)
  • TypeScript configuration, Oxlint, package.json, .gitignore
  • A prewired twenty script that delegates to the twenty CLI from twenty-sdk

Example files (controlled by scaffolding mode):

  • objects/example-object.ts — Example custom object with a text field
  • fields/example-field.ts — Example standalone field extending the example object
  • logic-functions/hello-world.ts — Example logic function with HTTP trigger
  • front-components/hello-world.tsx — Example front component
  • views/example-view.ts — Example saved view for the example object
  • navigation-menu-items/example-navigation-menu-item.ts — Example sidebar navigation link
  • skills/example-skill.ts — Example AI agent skill definition
  • __tests__/app-install.integration-test.ts — Integration test that builds, installs, and verifies the app (includes vitest.config.ts, tsconfig.spec.json, and a setup file)

Next steps

  • Run yarn twenty help to see all available commands.
  • Use yarn twenty auth:login to authenticate with your Twenty workspace.
  • Explore the generated project and add your first entity with yarn twenty entity:add (logic functions, front components, objects, roles, views, navigation menu items, skills).
  • Use yarn twenty app:dev while you iterate — it watches, builds, and syncs changes to your workspace in real time.
  • CoreApiClient (for workspace data via /graphql) is auto-generated by yarn twenty app:dev. MetadataApiClient (for workspace configuration and file uploads via /metadata) ships pre-built with the SDK. Both are available via import { CoreApiClient, MetadataApiClient } from 'twenty-sdk/clients'.

Publish your application

Applications are currently stored in twenty/packages/twenty-apps.

You can share your application with all Twenty users:

# pull the Twenty project
git clone https://github.com/twentyhq/twenty.git
cd twenty

# create a new branch
git checkout -b feature/my-awesome-app
git commit -m "Add new application"
git push

Our team reviews contributions for quality, security, and reusability before merging.

Troubleshooting

  • Auth prompts not appearing: run yarn twenty auth:login again and verify the API key permissions.
  • Types not generated: ensure yarn twenty app:dev is running — it auto‑generates the typed client.

Contributing

Dependencies

Dependencies

ID Version
@genql/cli ^3.0.3
chalk ^5.3.0
commander ^12.0.0
fs-extra ^11.2.0
inquirer ^10.0.0
lodash.camelcase ^4.3.0
lodash.kebabcase ^4.1.1
lodash.startcase ^4.4.0
uuid ^13.0.0

Development Dependencies

ID Version
@types/fs-extra ^11.0.0
@types/inquirer ^9.0.0
@types/lodash.camelcase ^4.3.7
@types/lodash.kebabcase ^4.1.7
@types/lodash.startcase ^4
@types/node ^20.0.0
twenty-sdk workspace:*
twenty-shared workspace:*
typescript ^5.9.2
vite ^7.0.0
vite-plugin-dts ^4.5.4
vite-tsconfig-paths ^4.2.1

Keywords

twenty cli crm application development
Details
npm
2026-03-28 15:31:37 +00:00
1
AGPL-3.0
latest
402 KiB
Assets (1)
Versions (2) View all
1.0.1 2026-03-28
0.7.0 2026-03-28