--- title: "Setup" url: https://docs.catalyst.zoho.com/en/sdk/python/v1/setup/ description: "This page describes the steps to follow to setup and initialize the Python SDK." last_updated: 2026-09-28T11:04:26Z service: All Services type: general related_links: - name: "Install Python" url: https://www.python.org/ - name: "Install Pip" url: https://pip.pypa.io/en/stable/installation/# - name: "SDK Scopes" url: /en/sdk/python/v1/sdk-scopes --- # Python SDK Setup ### Prerequisites Before you begin developing your application logic with Catalyst Python SDK in your local environment, please ensure you have the following package manager and programming environment installed on your local machine: * **[Pip](https://pip.pypa.io/en/stable/installation/#) - Python Package Manager** * **[Python version 3.10 to 3.13](https://www.python.org/)** You can install Python from their [official website](https://www.python.org/) and the pip package manager will be auto-installed in your local system. Please make sure you install the pip package manually if you install Python from other sources. You can refer to the [pip installation documentation](https://pip.pypa.io/en/stable/installation/#) for installing pip. > **Note:** If you have other versions of Python installed in your local machine (any version outside the supported range of Python 3.10 to 3.13), then the execution of the Python functions in your directory will be skipped when the application is being [served](https://docs.catalyst.zoho.com/en/cli/v1/serve-resources/introduction) or [deployed](https://docs.catalyst.zoho.com/en/cli/v1/deploy-resources/introduction). These Python functions are also excluded when you [pull](https://docs.catalyst.zoho.com/en/cli/v1/pull-resources/introduction) the functions from the console to the [CLI](https://docs.catalyst.zoho.com/en/getting-started/installing-catalyst-cli/). If you are creating Python functions in an existing Catalyst project in your local directory, you can install the prerequisites mentioned above, and proceed to set up the function. The steps to set up a Python function in an existing [project directory](https://docs.catalyst.zoho.com/en/cli/v1/project-directory-structure/introduction) are given in [this help page](https://docs.catalyst.zoho.com/en/cli/v1/working-with-functions/introduction). To learn about initalizing a Python function during Catalyst project initialization, refer [this help page](https://docs.catalyst.zoho.com/en/cli/v1/initialize-resources/introduction). ### Installing the SDK When you initialize a Catalyst project in the CLI and [create](https://docs.catalyst.zoho.com/en/cli/v1/initialize-resources/initialize-functions/#initialize-a-python-function-of-any-type) or [set up](https://docs.catalyst.zoho.com/en/cli/v1/working-with-functions/set-up-functions/#set-up-a-python-function-of-any-type) a Python function in an existing project directory in your local environment, the Python SDK package (`zcatalyst-sdk`) will automatically be installed inside the [functions directory](https://docs.catalyst.zoho.com/en/cli/v1/project-directory-structure/introduction) of your current project. A main function file and a configuration file will be auto-generated with the boilerplate code in your function's directory by default when you create a [Catalyst Serverless function](https://docs.catalyst.zoho.com/en/serverless/help/functions/introduction) of any programming stack. For Python functions, an additional file named [`requirements.txt`](https://docs.catalyst.zoho.com/en/cli/v1/project-directory-structure/functions-directory/#python-modules-and-function-dependencies) will also be created. This file contains the list of installed dependencies that are needed to implement the Python function. By default, it contains the entry for Catalyst's Python SDK package (`zcatalyst-sdk`), when you create the Python function from the CLI. When you need to install external dependencies, you will need to add the name of the dependency manually in the `requirements.txt` file. > **Note:** If it is your first time initializing a Python function, you will need to additionally set the path information of Python installed in your system. You can set this information in a specific configuration file that is present in your local system as a hidden file. The path will need to be set using the `config:set <key=value>` CLI command. You can find out more about this command from [ this help page](https://docs.catalyst.zoho.com/en/cli/v1/cli-config/). You can use the following command to install the Catalyst Python SDK globally in your system: ```json pip install zcatalyst-sdk ``` ### Initializing the SDK After Python SDK is installed in your function's directory, you can begin coding the Python function. You must first initialize the SDK within the function's code, using the `initialize()` method to access the Catalyst components of the current project. The initialization methods for the Catalyst function types are given below: **Basic I/O Functions** ```python import zcatalyst_sdk def handler(context, basicio): app = zcatalyst_sdk.initialize() #This app variable is used to access the Catalyst components. #Your business logic comes here ``` **Advanced I/O Functions** ```python import zcatalyst_sdk def handler(request: Request): app = zcatalyst_sdk.initialize() #This app variable is used to access the Catalyst components. #Your business logic comes her ``` **Event Functions** ```python import zcatalyst_sdk def handler(event, context): app = zcatalyst_sdk.initialize() #This app variable is used to access the Catalyst components. #Your business logic comes here ``` **Cron Functions** ```python import zcatalyst_sdk def handler(cron_details, context): app = zcatalyst_sdk.initialize() #This app variable is used to access the Catalyst components. #Your business logic comes here ``` When you initialize the SDK package inside the function, it returns a Python object as the response. This object can be used to call the component-specific methods defined in the Python classes and access the required Catalyst components. > **Note :** You can create Python functions both from the web console or the CLI, based on your preference. However, you can only upload the function bundle from the local and can't code it in the console directly for now. We will be providing support for online editors in the future. ### Initializing with Scopes Catalyst allows you to initialize the SDK in a project using the following scopes: * **Admin**: You have unrestricted access to all the components and their respective functionalities. For example, you have complete access to the [Data Store](https://docs.catalyst.zoho.com/en/cloud-scale/help/data-store/introduction/) to perform all operations like Read, Write, Delete, etc. * **User**: You can restrict access to components, and specific functionalities. For example, you can provide Read access alone to Data Store. > **Note:** * It is not mandatory for you to initialize the projects with scopes. By default, a project that is initialized will have *Admin* privileges. * Ensure you have initialized the Catalyst SDK with the appropriate scope while you engineer your business logic. The permissions you define for your scope control your end-user's actions. * To learn more about the scopes of the SDK operations that can be performed in various components, refer to the [Scopes Table](https://docs.catalyst.zoho.com/en/sdk/python/v1/sdk-scopes) * Depending on how you engineer your business logic, you can decide if your end-users can perform *Admin* or *User* actions. This is decided based on the [role](https://docs.catalyst.zoho.com/en/cloud-scale/help/authentication/user-management/roles/introduction/) assigned to your end-user when they sign up to your application in Catalyst Authentication. The permissions for the roles can be configured in the *Scopes & Permissions* or the *Bucket Permissions* section of the [Data Store](https://docs.catalyst.zoho.com/en/cloud-scale/help/data-store/scopes-and-permissions/) and [Stratus](https://docs.catalyst.zoho.com/en/cloud-scale/help/stratus/introduction/) respectively. The SDK snippets below will allow you to initialize the SDK using either *Admin* or *User* scope : **Admin Scope** ```python import zcatalyst_sdk def handler(request: Request): app = zcatalyst_sdk.initialize(scope='admin') #This app variable is used to access the catalyst components. #You can refer the SDK docs for code samples. #Your business logic comes her ``` **User Scope** ```python import zcatalyst_sdk def handler(request: Request): app = zcatalyst_sdk.initialize(scope='user') #This app variable is used to access the catalyst components. #You can refer the SDK docs for code samples. #Your business logic comes here ``` We will be discussing about upgrading the Python SDK in the next section.