Konect CLI
The Konect command line interface (CLI) is a unified tool that provides a consistent interface for importing and exporting data and configuration from the Konect cloud.
The Konect CLI requires a valid API key with access to the required environments to run. Konect API keys can be created in the Konect portal by an account administrator (when the organisation has a valid license).
Installation
The Konect CLI is a self contained 64 bit .NET application that is currently only supported by 64 bit Windows 10 and 11 or Windows Server 2016 and above. The Konect CLI can be downloaded from here:
The Konect CLI ships with the third party tool GDAL (version 3.5) for transforming between GIS formats. GDAL requires the latest 64 bit Microsoft Visual C++ redistributable, which can be found here:
Steps to install
Download the Konect CLI zip file
Create a new folder to install the CLI, such as C:\konect
Unzip the Konect CLI zip file into the new folder
Install the GDAL prerequisites
The konect.exe program is used to run all commands
Command structure in the Konect CLI
The Konect CLI uses a multipart structure on the command line that must be specified in this order:
The base call to the
konect
program.The top-level command, which corresponds to an import or export.
The parameter -k [API_KEY] that specifies the key to allow the Konect CLI to work with your organisation.
The parameter -e [ENVIRONMENT_NAME] that specifies the environment the Konect CLI will work with.
General Konect CLI parameters or flags required by the command type. You can specify these in any order as long as they follow the first two parts.
$ konect <command> -k [API_KEY] -e [ENVIRONMENT_NAME] [parameters and flags]
Parameters
Parameters are passed to the Konect CLI by specifying 2 minus symbols and the parameter name or 1 minus symbol and the parameter abbreviation character followed by the value/s separated by spaces. Not all parameters have an abbreviated version. The key and environment parameters shown above are examples of abbreviated parameters.
Parameter values that have spaces need to be qualified with double quotes around the value.
"value with space"
Parameter values that include double quotes, need the double quotes to be escaped with either a backslash or 2 double quotes.
"my \"quoted\" value"
"my ""quoted"" value"
Parameters that can take more than 1 value need to be separated by spaces
value1 value2 "quoted value"
Flags
Flags are parameters that do not have values, but are either on or off. An omitted flag is off, while an included flag is on. For example including --photos
would tell the CLI to download photo fields during an export, omitting the flag defaults to not download photos during an export.
Usage text
Executing just the base Konect CLI program will display a usage text with all available commands.
$ konect
Executing just the base Konect CLI program and the command will display usage text for the given command.
$ konect <command>