If you run the command npm start  and get the following error:
 VirgilCryptoError: Cannot import private key. rawPrivateKey must be a Buffer or string in base64     

full error code can look like this:

Problem: it means that you didn't put correct APP_KEY (API Private Key)  into a config.json  file. 


  1. check your config.json  file, to be sure you didn't miss to admit API_KEY 
  2. Go to your Virgil Dashboard (https://dashboard.virgilsecurity.com/) -> API KEYS section  -> create a new API Key -> 

copy and save it into a config.json  file.  Remember, Virgil doesn't have a copy of your API Private Key, thus be sure that store it after its generation.

3. Back to dashboard and copy also API Key ID (your API Key ID must be related to your API private Key) -> 

paste your App_Key_ID into your config.json -> save config file -> open CLI and run npm start. 

Did this answer your question?