> ## Documentation Index
> Fetch the complete documentation index at: https://koreai.mintlify.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Installing the BotKit SDK

<Badge icon="arrow-left" color="gray">[Back to BotKit SDK Overview](/ai-for-service/sdk/botkit-sdk)</Badge>

The BotKit SDK runs as a Node.js application. You can add a reverse proxy, firewall, and load balancer to meet your availability, scalability, and performance requirements.

For a full end-to-end tutorial, see [BotKit SDK Tutorial — Flight Search](/ai-for-service/sdk/tutorials/flight-search-sample-bot#botkit-sdk-tutorial-—-flight-search-sample-bot).

***

## Prerequisites

Register your app on the Platform to get authentication credentials:

1. Go to **Deploy > Integrations > BotKit**.
2. Create or register an app for your bot to generate **Client ID** and **Client Secret**.

Copy these values into your `config.json`:

* `appId` → Client ID
* `appKey` → Client Secret

See [SDK App Registration](/ai-for-service/sdk/app-registration#sdk-app-registration) for details.

***

## Download and Install

Download the BotKit SDK from GitHub:

```
https://github.com/Koredotcom/BotKit
```

***

## Configure config.json

Set the following keys in `config.json`:

| Key                             | Description                                                                     |
| ------------------------------- | ------------------------------------------------------------------------------- |
| `server.port`                   | Port for the BotKit Node.js app (default: `8003`)                               |
| `app.apiPrefix`                 | API path prefix for the Express route (empty in sample code)                    |
| `app.url`                       | ngrok forwarding URL or your callback server URL                                |
| `validations.leastNodeVersion`  | Minimum Node.js version — must be `10` or higher                                |
| `credentials.apikey`            | **Client Secret** from the Platform                                             |
| `credentials.appId`             | **Client ID** from the Platform                                                 |
| `credentials.st-<botId>.apikey` | Per-bot override for Client Secret (falls back to parent if absent)             |
| `credentials.st-<botId>.appId`  | Per-bot override for Client ID                                                  |
| `jwt.jwtAlgorithm`              | JWT signing algorithm: `HS256`, `HS512`, `RS256`, or `RS512` (default: `HS256`) |
| `jwt.jwt-expiry`                | JWT expiry in seconds (default: `60`)                                           |
| `jwt.st-<botId>`                | Per-bot JWT algorithm and expiry overrides                                      |
| `redis.options.host`            | Redis host (default: `localhost`)                                               |
| `redis.options.port`            | Redis port (default: `6379`)                                                    |
| `redis.available`               | Set `true` to enable Redis for async webhook payload storage                    |
| `examples.mockServicesHost`     | Host for mock services used in testing                                          |
| `liveagentlicense`              | LiveChat license key for agent transfer integrations                            |
| `supportsMessageAck`            | Set `true` to enable message acknowledgment                                     |
| `languages`                     | List of supported language codes, for example, `["en", "de"]`                   |

**Example `config.json`:**

```json theme={null}
{
  "server": { "port": 8003 },
  "app": {
    "apiPrefix": "",
    "url": "https://your-ngrok-url.ngrok-free.app"
  },
  "validations": { "leastNodeVersion": 10 },
  "credentials": {
    "apikey": "your-client-secret",
    "appId": "cs-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "st-67890": {
      "apikey": "bot-specific-secret",
      "appId": "bot-specific-client-id"
    }
  },
  "jwt": {
    "jwtAlgorithm": "HS256",
    "jwt-expiry": 60,
    "st-67890": {
      "jwtAlgorithm": "HS512",
      "jwt-expiry": 60
    }
  },
  "redis": {
    "options": { "host": "localhost", "port": 6379 },
    "available": false
  },
  "examples": { "mockServicesHost": "https://localhost:8004" },
  "liveagentlicense": "your-livechat-license",
  "supportsMessageAck": true,
  "languages": ["en", "de"]
}
```

The default JWT token expiry is 60 seconds. Override with the KoreConfig setting:

```json theme={null}
"botkit": { "jwt_expiry": 300 }
```

***

## Run the SDK

In a Terminal window, navigate to your BotKit SDK folder and run:

```bash theme={null}
node app.js
```

Requires Node.js version 10 or higher.

***
