Initialize the Project
You can now begin working on your Catalyst project from the CLI. The first step is to initialize the project in an empty directory. This will be the home directory of your project, and all of the project files will be saved in it.
You can learn more about this from the Project Directory Structure help page. You can learn about initializing a project in detail from the CLI help documentation.
For this application, we will initialize a Basic I/O function, which will contain the logic for Custom User Validation and a React web app as the client component. Later, we will also initialize an Advanced I/O function and a Job Function.
-
Create a folder for the project on your local machine and navigate to it from the terminal.
-
Initialize a project by executing the following command from that directory:
- Navigate using the arrow keys, select your preferred portal, and press the Enter key. If you have no other organizations associated with the account, then the default one will be selected automatically.
-
The CLI will now ask you to associate a Catalyst project with the directory. Associate it with the project that we created earlier from the console. Select BirthdayGreetings from the list and click Enter.
-
Select Functions and Client using the space bar, then click Enter to initialize.
-
The CLI will initiate the function setup. Select Basic IO as the function type to code your Custom User Validation function.
-
Select the latest runtime of Node.js as the function stack.
-
Enter “basic_function” as the package name, “index.js” as the entry point, and your email address as the author, then press Enter. Alternatively, you can press Enter without entering inputs to fill in the default values. The CLI will prompt the initialization of the Node dependencies. Press Y to confirm the installation, and press Enter to confirm your choice. The Node modules will be installed.
The CLI will now initiate the client setup.
-
Select React web app and press Enter to initialize your client as a React web app.
-
Select JavaScript as the React app type and press Enter.
-
Enter “birthdaygreetings” as the name of your client package and click Enter. You can also provide any name of your choice. Enter “y” at the prompt to install the required React packages, such as “react”, “react-dom,” and “react-scripts.” These packages will be installed through the Catalyst React plugin (zcatalyst-cli-plugin-react).
The client is now successfully initialized as a React web application.

The client directory will be created in the standard structure in the project directory.
This is the current structure of the Birthday Greetings project’s directory.

Now, we will begin initializing the Advanced I/O Function and Job Function using the following CLI command in the BirthdayGreetings/functions/ directory:
This CLI command will trigger the function set up and allow you to add the required functions to your project directory.
-
Select the Advanced IO function once the function setup starts.
-
Select the latest runtime of Node.js as the function stack.
-
Enter “advance_function” as the package name, “index.js” as the entry point, and your email address as the author, then press Enter. Alternatively, you can press Enter without entering inputs to fill in the default values. The CLI will prompt the initialization of the Node dependencies. Press Y to confirm the installation, and press Enter to confirm your choice. The Node modules will be installed.
The Advanced I/O function has been initialized.
Let’s initialize the Job Function using the same CLI command.
-
Select Job as the function type once the function setup starts.
-
Select the latest runtime of Node.js as the function stack.
-
Enter “dynamic_cron” as the package name, “index.js” as the entry point, and your email address as the author, then press Enter. Alternatively, you can press Enter without entering inputs to fill in the default values. The CLI will prompt the initialization of the Node dependencies. Press Y to confirm the installation, and press Enter to confirm your choice. The Node modules will be installed.
All of the required client and function components have been initialized for your application. This is the current structure of the project directory:

Last Updated 2025-04-01 11:10:20 +0530 +0530