Quick Start Guide

This quick start guide will familiarize you with setting up the Catalyst work environment in under ten minutes. With this guide, you can quickly learn the basic steps involved in developing a Catalyst application in a generic way, with the most popular services.

You can access detailed step-by-step tutorials on building applications and microservices involving different Catalyst services and components from the Tutorials section.

Access all Catalyst resources and check out the various help resources available.

Note: Refer to the links provided in this guide for detailed help on various topics.

Prerequisites

  1. Node.js and NPM for your platform to install Catalyst CLI and to develop Node.js functions
  2. Java SE Development Kit to develop Java functions
  3. Python for your platform to develop Python functions
  4. Any IDE tool for coding the client, functions, or AppSail.

Step 1: Create a Catalyst project

The first step in developing a Catalyst application is to create a Catalyst project for it.

  1. Log in to the Catalyst console and click Create a new Project.
  2. Enter the project’s name in the pop-up window.
  3. Click Access Project to open it.

You can now set up and work with the Catalyst services and components from the console. Refer to each service’s index page from the help resources to learn about it and the components in detail.


Step 2: Install Catalyst CLI

Install Catalyst CLI to develop, test, and deploy Catalyst applications from your local system.

Execute this command in your terminal:

copy
$
npm install -g zcatalyst-cli

Execute this command to verify if the CLI is properly installed:

copy
$
catalyst --version

Note: If you are unable to install Catalyst CLI, execute the install command using sudo.

You will now be able to access the catalyst command from your terminal. Refer to the CLI help resources for detailed help with the CLI commands and actions.


Step 3: Log in from your CLI

  1. Execute this command to log in to your Zoho account from the CLI:
copy
$
catalyst login
  1. Press Y to allow Catalyst to collect CLI error reports and press Enter.

  2. Sign in using your credentials in the Zoho accounts login page.

  3. Click Accept to provide data access permissions to the CLI.

  4. Close the browser window and continue using the CLI in your terminal.


Step 4: Initialize the project from the CLI

  1. Create a folder for the project on your local machine and navigate to it from the terminal.
  2. Execute this command from that directory to initialize a Catalyst project in it:
copy
$
catalyst init

Note: The first Catalyst project can only be created from the web console, and not from the CLI. However, you can create subsequent projects directly from the CLI.
  1. Select the components that you need to set up for your Catalyst application and press Enter. You can initialize Serverless functions and CloudScale client.
Note: You can also initialize Serverless AppSail and deploy your app's build files onto the PaaS.
  1. Associate the directory with a Catalyst project by selecting a project from the list and press Enter.

  2. If you initialize a function, select a function type and the stack, and press Enter.

    • If you initialize a Java function, provide the reference name and the main class name, then install the Catalyst Java SDK package.
    • If you initialize a Node.js function, provide the values for the package name, the entry point file name, and the author’s email address. Install the dependencies when prompted.
    • If you initialize a Python function, provide the values for the package name and the entry point file name.
  3. If you initialize the client, provide a name for the client package.

The components will be installed and the project directory will be set up with the necessary dependencies and configuration. Refer to the standard project directory structure help page for details.


Step 5: Develop the application

You can now work with the components you initialized in your Catalyst project and use any IDE tool of your choice to code the functions or the client. Refer to the following help documentations for detailed help on working with the Catalyst SDK and API resources, and incorporating Catalyst components in your business logic:


Step 6: Test the application locally

After you develop the Catalyst application or microservice, you can test it locally from the CLI before deploying it to the Catalyst web console.

Execute this command from your project directory:

copy
$
catalyst serve

Note: You can also launch an exclusive Node shell from the CLI to test the functions.

You can access the functions, client, and AppSail from its local URL displayed in the CLI, and test them.


Step 7: Deploy the project

After you test the application, you can deploy it to the remote console by executing this command from your project directory:

copy
$
catalyst deploy

Your application can now be accessed from its web app URL in the Development environment. To access the application in the Production environment, you must set up Catalyst payments and deploy the project to production.

Note: You can also host web applications directly from the console through web client hosting or upload function bundles in the console. You can host and distribute a mobile application using Mobile Device Management.

Access Tutorials to try out some sample applications.

Last Updated 2023-09-02 13:42:08 +0530 +0530