# Getting started

This documentation presents the steps that must be performed for Digibeectl to be installed and working correctly.

## Download the configuration file

Follow the steps below  to get the configuration file:

1. Log in to Digibee Integration Platform.
2. Click on the **Administration** button.
3. Click in **Digibeectl** in the menu on the left side of the screen.
4. Click on the **Create** button.
5. Give a title to your token.&#x20;
6. Insert a list of permissions to be granted to this token.
7. Set an expiration period for your token. The period ranges from 1 hour to 1 year.
8. Save your permissions list and expiration period.
9. Copy the Encryption Key generated by the Platform using the copy icon and save it to further use. Then, create the file password.
10. Save the password and download the file.

## Run the installation

Digibeectl is available as a ‘tar.gz’ file for MacOs and Linux.

{% hint style="warning" %}
While Windows does not have native support, it can be installed by setting up WSL (Windows Subsystem for Linux), allowing the tool to be installed and configured in a Linux environment within Windows. Check the [documentation](https://docs.digibee.com/documentation/developer-guide/development-cycle/digibeectl/getting-started/windows-install) to know how to install Digibeectl on Windows.
{% endhint %}

1. To install the file, open a terminal window and run the command line below:

```bash
curl -s https://storage.googleapis.com/digibee-release-test/releases/install.sh | bash
```

2. Use the following command line after install Digibeectl. Replace the words “`path/file.json`” by the configuration file address and the words "`encryption key`" and "`encryption passphrase`" by the data you set before when downloading the configuration file:

```bash
digibeectl config set --file "path/file.json" --secret-key "encryption-key" --auth-key "encryption-passphrase"
```

### Customizing the configuration directory

By default, Digibeectl stores its configuration files in the `~/.digibeectl/ directory`. However, you can customize this location by setting the `DIGIBEECTL_PATH` environment variable. Use the following commands to specify your preferred directory:<br>

* **Unix-based systems (Linux, macOS):** Run the command in the terminal or add it to your shell configuration file.

```
export DIGIBEECTL_PATH=/custom/path/to/config/directory
```

* **Windows:** Run the command in the terminal or follow [this tutorial](https://phoenixnap.com/kb/windows-set-environment-variable) to configure it through the interface.

```
set DIGIBEECTL_PATH=/custom/path/to/config/directory
```

{% hint style="info" %}
Ensure the specified directory exists and that you have the necessary read and write permissions. If the path doesn't end with a forward slash (`/`), it will be added automatically.
{% endhint %}

## Download the updates

To update Digibeectl, run the installation line again. To do this, open a terminal window and type:

```bash
curl -s https://storage.googleapis.com/digibee-release-test/releases/install.sh | bash
```
