Generate a controller for a Strapi API.

controller, generate, generator, strapi, api, cms, customizable, dashboard, graphql, hacktoberfest, headless-cms, jamstack, javascript, koa, koa2, nodejs, rest
npm install strapi-generate-controller@3.5.0-next.0


Strapi logo

API creation made simple, secure and fast.

The most advanced open-source Content Management Framework (headless-CMS) to build powerful API with no effort.

NPM Version Monthly download on NPM Travis Build Status Strapi on Slack

Getting Started

Read the Getting Started tutorial or follow the steps below:

🖐 Requirements

Operating system:

Please note that Strapi may work on other Operating Systems, but are not tested at this time.


  • NodeJS >= 10.x
  • NPM >= 6.x

Please note that right now Node 11 is not supported, and the current Node LTS (v10) should be used.


  • MongoDB >= 3.6
  • MySQL >= 5.6
  • MariaDB >= 10.1
  • PostgreSQL >= 10


npm install strapi@alpha -g

We recommend always using the latest version of Strapi to start your new project. As this project is currently in Alpha, some breaking changes may occur. New releases are shipped every two weeks to fix/enhance the project.

🏗 Create a new project

strapi new my-project

This command will generate a brand new project with the default features (authentication, permissions, content management, content type builder & file upload).

🚀 Start your project

cd my-project
strapi start

Congratulations, you made it! Enjoy 🎉

Try on Heroku

You can also give it a try using Heroku in one click!


Be aware that one of the content type builder won't work due to the writing files restriction on the Heroku servers. If you do want to change content types, you need to follow these steps:

  1. Click the button above and deploy your app
  2. Clone that repo by using heroku git:clone -a followed by your repo's name
  3. Go into the cloned projects' folder using cd followed by your repo's name
  4. Add the Heroku boilerplate as a remote by running git remote add boilerplate
  5. Pull from this new origin by running git pull boilerplate master


  • Modern Admin Panel: Elegant, entirely customizable and fully extensible admin panel.
  • Secure by default: Reusable policies, CSRF, CORS, P3P, Xframe, XSS, and more.
  • Plugins Oriented: Install auth system, content management, custom plugins, and more, in seconds.
  • Blazing Fast: Built on top of Node.js, Strapi delivers amazing performances.
  • Front-end Agnostic: Use any front-end frameworks (React, Vue, Angular, etc.), mobile apps or even IoT.
  • Powerful CLI: Scaffold projects and APIs on the fly.
  • SQL & NoSQL databases: Work with Mongo as a main database, also supports Postgres, MySQL, etc.

See more on our website


⚠️ We have stopped merging PRs for now to the Strapi core.

The reason is that we are developing new architecture for the admin panel and for the plugins.
This new architecture will provide stability of the Strapi core as we approach the release of Beta.
We appreciate and welcome all your contributions, but until further notice, please do not submit a PR as it will not be merged.
Furthermore, you will have to rewrite it based on the new architecture.

Please read our Contributing Guide before submitting a Pull Request to the project.


For more information on the upcoming version, please take a look to our ROADMAP.

Community support

For general help using Strapi, please refer to the official Strapi documentation. For additional help, you can use one of this channel to ask question:

Professional support

Strapi Solutions, the company behind Strapi, provides a full range of solutions to get better results, faster. We're always looking for the next challenge: coaching, consulting, training, customization, etc.

Drop us an email to see how we can help you.


Follow our migration guides on the wiki to keep your projects up-to-date.


Check out our roadmap to get informed by the latest feature released and the upcoming ones. You can also give us insights and vote for a specific feature.


Become a sponsor and get your logo on our README on GitHub with a link to your site.


MIT License Copyright (c) 2015-2019 Strapi Solutions.