# AI use cases for Twenty (twentyhq/twenty)

Repo: [twentyhq/twenty](https://github.com/twentyhq/twenty) | Use cases: 3 | Page: https://dedupedai.com/use-cases/twentyhq-twenty/

Twenty is an open-source CRM that technical teams can extend by defining objects, fields, and views as code, or run on their own infrastructure.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Define a custom CRM object as code and publish it: https://dedupedai.com/use-cases/twentyhq-twenty/define-custom-crm-object-as-code/
- Have a coding agent build Twenty apps with official skills: https://dedupedai.com/use-cases/twentyhq-twenty/let-coding-agent-build-twenty-apps/
- Run Twenty on your own server with Docker Compose: https://dedupedai.com/use-cases/twentyhq-twenty/self-host-twenty-with-docker-compose/

## How to define a custom CRM object as code and publish it with Twenty

Repo: [twentyhq/twenty](https://github.com/twentyhq/twenty) | Difficulty: Intermediate | Time: 1 hour | Basis: From the README

Scaffold a Twenty app, define a deal object in TypeScript, and publish it to your workspace.

**Who it is for:** A technical sales ops lead or developer whose CRM needs a custom record type that the standard setup does not cover.

**The problem:** Standard CRM records do not match the business, and changes made by hand in a UI are hard to track and repeat.

**The outcome:** A deal object with name, amount, and close date fields is defined in code and available in your Twenty workspace.

### Steps

1. Run `npx create-twenty-app my-app` to scaffold a new app.
2. In the new project, define an object with `defineObject` from 'twenty-sdk/define', using nameSingular 'deal', fields for name (TEXT), amount (CURRENCY), and closeDate (DATE_TIME).
3. Run `npx twenty app:publish --private` to ship the app to your workspace.
4. Open the workspace and confirm the Deal object and its fields appear.

### Prompt to paste into your agent

```text
Using the twentyhq/twenty repo, scaffold an app named <app-name> with `npx create-twenty-app <app-name>`, then define a deal object with name, amount, and closeDate fields as shown in the README example. Publish it with `npx twenty app:publish --private` and report the publish output. Verify that the Deal object appears in the <workspace-name> workspace.
```

### Caveat

The README shows the object definition and publish command but does not describe the workspace access needed for `app:publish`, so check your access before you start.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/twentyhq-twenty/define-custom-crm-object-as-code/

## How to have a coding agent build Twenty apps with official skills with Twenty

Repo: [twentyhq/twenty](https://github.com/twentyhq/twenty) | Difficulty: Intermediate | Time: 1 hour | Basis: From the README

Install the Twenty app skills so Claude Code, Codex, or Cursor can scaffold and publish apps.

**Who it is for:** A developer who already uses a coding agent and wants it to build CRM extensions for their Twenty workspace.

**The problem:** A coding agent does not know Twenty's app conventions, so its output may not match the SDK or publish flow.

**The outcome:** The agent works from the official Twenty app skills to scaffold and publish a CRM app to your workspace.

### Steps

1. Run `npx skills add https://github.com/twentyhq/twenty/tree/agent-skills --list` to see the available skills.
2. If that branch does not exist yet, follow the local build instructions in packages/twenty-agent-skills before continuing.
3. Install the listed skills into your agent following the skills CLI output. (inferred, check the README)
4. Read SKILLS.md in the repo to choose the skill family that fits your task.
5. Ask your agent to scaffold an app and publish it with the Twenty CLI, then review the code it wrote before publishing.

### Prompt to paste into your agent

```text
Install the Twenty app skills from https://github.com/twentyhq/twenty/tree/agent-skills by running `npx skills add https://github.com/twentyhq/twenty/tree/agent-skills --list` and report the skills it lists. Then use them to scaffold an app named <app-name> for <use-case>. Verify that the generated objects follow the defineObject pattern shown in the README.
```

### Caveat

The agent-skills branch is only created by the first successful publish from main, so until then you must use the local build instructions in the repo.

Risk, credentials: Publishing sends app code to your Twenty workspace, so give the agent access only to a workspace you control and review what it publishes.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/twentyhq-twenty/let-coding-agent-build-twenty-apps/

## How to run Twenty on your own server with Docker Compose with Twenty

Repo: [twentyhq/twenty](https://github.com/twentyhq/twenty) | Difficulty: Advanced | Time: 2 hours | Basis: From the README

Host the CRM on your own infrastructure using the Docker Compose guide.

**Who it is for:** An IT or DevOps engineer whose company needs its CRM data to stay on infrastructure it controls.

**The problem:** A hosted CRM may not meet data location or infrastructure rules, so the team needs the CRM running on its own servers.

**The outcome:** A self-hosted Twenty instance running on your infrastructure, set up from the official Docker Compose guide.

### Steps

1. Read the Docker Compose self-hosting guide at https://docs.twenty.com/developers/self-host/capabilities/docker-compose.
2. Install Docker on the server that will host Twenty. (inferred, check the README)
3. Follow the guide to start Twenty with Docker Compose.
4. Open the instance in a browser and confirm you can sign in and create a workspace. (inferred, check the README)

### Prompt to paste into your agent

```text
Using the Docker Compose guide at https://docs.twenty.com/developers/self-host/capabilities/docker-compose, set up a self-hosted Twenty instance on <server-host>. Report each command you ran and the final URL. Verify that the instance loads in a browser and that you can reach the sign-in page.
```

### Caveat

The README links to the Docker Compose guide but does not list the commands or server requirements, so read the guide before you plan the server.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/twentyhq-twenty/self-host-twenty-with-docker-compose/
