Required profile, concepts and tools

<< Click to Display Table of Contents >>

Navigation:  Bizagi Studio > Process wizard > Integrate > Application integration > Integrating APIs and extending Bizagi > Bizagi connectors > Creating connectors > Custom connectors >

Required profile, concepts and tools

Overview

When creating your own Bizagi connectors, and specifically a custom connector, make sure you meet with the required profile and are familiar with the concepts presented below.

Recall that in custom connectors you write your own code, as described at Custom connectors.

 

Profile

You will require the following profile:

Programming skills, namely experience with JavaScript (web-application oriented development).

It is optimal and best if you have worked with asynchronous/event-driven coding practices before (e.g jQuery and AJAX).

Understanding of basic structures such as XML and JSON.

Being familiar with package managers such as npm (https://www.npmjs.com/) -or even code/git repositories such as GitHub.

You may need to install npm and use its command prompt options to download and package any open source API (available MIT-licensed libraries for Node.js -https://nodejs.org/en/).

 

 

Concepts

While you will be including your own code in JavaScript programming language, it is of great importance that you also understand the notation and capabilities offered by Node.js.

 

The most important quick facts regarding Node.js that you will need to consider are:

It is a runtime that executes JavaScript code on server-side (using Chrome's V8 JavaScript engine).

The Node.js version used by Bizagi is v0.12.5, and therefore, any third-party libraries you use will need to run in this version.

Note that if you wish to extend user interfaces in Bizagi, that is the functionality offered on the client-side, you may do so by creating Bizagi Widgets instead.

Unlike PHP or other server-side technologies, it runs asynchronously as non-blocking (while using a single thread).

The above concepts are supported and intertwined with the fact that Node.js relies on event-driven programming (i.e, the observer pattern).

In this pattern, "finish" events are attached to invocations so that responses are handled in an asynchronous fashion, via callbacks.

 

note_pin

In case you are new to Node.js, you may rely on external blogs, tutorials and documentation to understand the main purpose of its use, and its advantages (in which scenarios it is applicable and a good idea to use).

For instance, refer to links such as https://www.toptal.com/nodejs/why-the-hell-would-i-use-node-js or http://www.tutorialspoint.com/nodejs/index.htm to make sure you are aware that not all scenarios and requirements are ideal to be approached by the use of Node.js.

 

Software requirements

For Custom connectors, and given that these will likely rely on third-party libraries, installing npm is required.

Npm is the package manager for Node.js libraries (which means, it allows you to download and pack available libraries at https://www.npmjs.com/, as suggested by its acronym meaning: Node Package Manager).

 

Supported versions

Though you may download the latest version from https://nodejs.org, you will need to ensure that the library and code you will be using is compliant to the Node.js and npm version used by Bizagi.

The current Node.js version bundled in Bizagi is 0.12.5. while having npm version 3.1.3.

 

note_pin

Supported npm versions are  3.1.3 or above.

 

For such reason, it is recommended to download the current release.

You may download and install npm directly from https://nodejs.org/en/download/.

 

NodeJS_download

 

 

note_pin

In case you wish to alternatively download a Node JS portable installation (no .exe file), while ensuring you use the same version used by Bizagi, you may download it from www.bizagi.com at:

http://download.bizagi.com/connectors/forecast/nodejs.zip

 

Installation considerations

When installing npm, required components are the Node.js runtime and the npm package manager:

 

NodeJS_install

 

Note that including the Add to PATH setting is not mandatory, and it is recommended that leave it out but choose instead to configure you own NODEJS_HOME within your environment variables:

 

NODEJS_HOME

 

The sample NODEJS_HOME shown above, illustrates where npm and nodejs executable files are installed:

 

NODEJS_Folder

 

This way, you may run npm commands directly from the console prompt, while standing in the folder location you want to use to download a specific package (the sample image below considers that a forecast.io library will be downloaded into C:\tmp\node_modules\):

 

NODEJS_Npmcommand

 

note_pin

In case you identify that you will need to use two or more completely different and separate libraries from www.npmjs,com, it is recommended to use a package.json definition file to avoid potential conflicts when packaging both into Bizagi's connector.

 

At any time you may review which npm version you have installed, by using npm -version:

 

Npm_version

 

note_pin

In npm versions 3.x or above, the npm install command will by default download the libraries into a flattened structure that considers dependencies as Bizagi expects it.

However, the --greedy switch may be useful as well in order to enforce this compliance.

For more information about these commands, refer to https://docs.npmjs.com/how-npm-works/npm3.