Skip to content

Lightrun for Express

To start using Lightrun with an Express application, please follow the instructions below.

Instructions

  1. In your project's folder, install the node agent by running npm install lightrun.

  2. Import Lightrun at the start of your your application file (i.e. index.js or app.js) by adding the following code:

    require('lightrun').start({
         company: '<COMPANY-NAME>',
         lightrunSecret: '<COMPANY-SECRET>',
    });
    
  3. Run the application as you normally would, i.e. node index.js or npm start.

Getting Company Details

You can get <COMPANY_NAME> and <COMPANY_SECRET> by logging into the the Management Portal and looking inside the Download the Agent section.


Last update: September 27, 2021