Additional resources and references

This document provides comprehensive information about the introduction and concepts around Nexthink Chatbot SDK, its API and use cases. The information contained herein is subject to change without notice and is not guaranteed to be error-free. If you find any errors, please report them to us via Nexthink Support Portal. This document is intended for readers with a detailed understanding of Nexthink technology.

This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited.

REST API

Nexthink Chatbot SDK offers REST API following the OpenAPI v3.0 standard. Refer to the Introduction and concepts documentation for more information.

Basic Docker commands

All the Docker Compose commands need to be executed from /var/nexthink/nexthinkchatbot-adapter

  • To start the Docker containers

$ docker compose up -d

  • To stop the Docker containers

$ docker compose down

  • To restart the Docker containers

$ docker compose down && docker compose up -d

or run the restart script

$ ./scripts/nexthink-chatbot-adapter-restart.sh

  • To list the running Docker containers

$ docker ps

  • To read logs

$ docker compose logs

For more information about these commands, refer to the Overview of docker compose CLI documentation.

Custom certificate installation

The certificate provided by default is a demo self-signed certificate. To install your own certificate follow these steps:

  • Generate your own certificate files. File names must be named ca_certificates.crt for the certificate and key.pem for the key.

  • Copy the certificate and key into the environment, for example to /var/nexthink/nexthink-chatbot-adapter/certs/

  • Grant proper permissions to the folder and certificate files:

$ chmod 755 /var/nexthink/nexthink-chatbot-adapter/certs

$ chmod 644 /var/nexthink/nexthink-chatbot-adapter/certs/*

  • Modify the /var/nexthink/nexthink-chatbot-adapter/docker-compose.yml file to use the copied certificate instead of the default certificate by adding the needed volume in the chatbotingress service.

Code
chatbotingress:     
  depends_on:       
    - nxqlwrapper 
    - topicmanager 
    - remoteactionmanager       
    - postgresql     
  build:       
    context: ../src 
    dockerfile: ../docker/chatbotingress.Dockerfile     
  image: chatbotingress     
  volumes: 
    - "/etc/localtime:/etc/localtime:ro" 
    - "/var/nexthink/nexthink-chatbot-adapter/certs:/certs:ro" 
  ports: 
    - "${CHATBOT_ADAPTER_PORT}:8090" 
  environment:       
    - NEXTHINK_USER 
    - NEXTHINK_PASS       
    - POSTGRES_PASSWORD     
  command: -logLevel ${LOG_LEVEL}     
  restart: always
  • Reload the configuration

$ docker compose up -d

Manual installation of Docker on Nexthink OS image

Nexthink provides an install script scripts/nexthink-chatbot-adapter-req-install.sh in the installation zip file. Invoke the script using sudo.

This script installs Docker and Docker Compose, adds user to docker group, then starts and enables Docker services on Nexthink Oracle Linux.

To install docker on the official Nexthink image using the script mentioned above, follow these steps:

If you have Nexthink Oracle Linux already configured, go directly to step 5.

  1. Download ISO from the Nexthink download page.

  2. Optional if using VM: Create new VM and mount Nexthink-ISO.

  3. Optional if using VM: Boot VM from ISO and finish initial setup until reboot 4.

  4. Start https://IPAddress:99/ and set passwords, hostname & DNS-server.

  5. Start SSH-client, connect to VM and login as a Nexthink user.

  6. Copy and extract the Chatbot SDK installation zip into the host.

  7. Go to the newly created directory: $ cd /home/nexthink/nexthink-chatbot-adapter-X.X.X

  8. Add execution permission to the script, if needed: $ chmod +x scripts/nexthink-chatbot-adapter-req-install.sh Launch the script using sudo: $ sudo ./scripts/nexthink-chatbot-adapter-req-install.sh

  9. Log out and log back in. Type docker in the console, it should be already available.

Other content libraries

This is a list of Nexthink Library packages that contain remote actions included in Chatbot SDK Content Library.

Last updated