Creating your development environment

Use the QRadar® GUI Application Framework SDK (Software Development Kit) to create a basic development environment for your app.

About this task

The SDK provides a sample template app that you use as a template to create your own app. Use Python 2.7.9 to develop your QRadar apps.

Procedure

  1. Create a folder on your computer for the QRadar sample app. Name the directory according to the following format.
    <Author Namespace>.<App_Name>.<App_Version>
    For example, the following directory name is an example of a good naming convention:
    com.me.myApp.1.0.0 
  2. Depending on your operating system, type the following command: qradar_app_creator create -w <path_to_app_folder>/com.me.myApp.1.0.0
    • On UNIX and Linux operating systems, type the following command:
      qradar_app_creator create -w <path_to_app_folder>/com.me.myApp.1.0.0
      Important: On Linux operating systems, keep the absolute path to your workspace short. File paths might be truncated because of the BINPRM_BUF_SIZE kernel constant (79 or 127 characters, depending on kernel version), leading to failure of this command.
    • On Windows operating systems, type the following command:
      qradar_app_creator create -w <path_to_app_folder>\com.me.myApp.1.0.0
      Important: Folder and file names in paths must not contain spaces.

Results

When you run the development environment script, the following folders and files that are described in the table are added to your app development folder.
Table 1. QRadar App files and folders in the development folder
Files/Folders Description
app The root directory for application files. This directory contains the following files:

The qpylib folder contains the Python library files that your app uses to run QRadar tasks. For example; you can use the qpylib library to connect to API endpoints, and get the storage path.

The __init__.py sample initialization file for your app. Creates a Flask instance, imports views from views.py and functions from the qpylib library.

The views.py file is the main entry point into the web app. This file and the manifest.json file are the only files that are required for every app. This file contains sample code for the "Hello World" application.

store The directory where the app data is stored. It is not packaged into your app.
qradar_appfw_venv Contains the Python virtual environment where the dependencies are installed.
__init__.py Creates an instance of the Flask micro-framework that is used to serve content to QRadar.
manifest.json Describes what the sample "Hello World" app does.
run.py Contains instructions to run the code that is in the app subdirectory.

What to do next

You are now ready to begin coding your app. Familiarize yourself with the requirements for the app and manifest file structures.