Sidekick
Search…
⌃K

Installation

First install the node agent by running
npm install @runsidekick/sidekick-agent-nodejs
There are two way to integrate Sidekick agent to your application.

Integrate Agent with Environment Variable

You can easily integrate Sidekick using below environment variables.
  • set SIDEKICK_APIKEY environment variable with your Sidekick api key.
  • set NODE_OPTIONS environment variable with '-r @runsidekick/sidekick-agent-nodejs/dist/bootstrap'

Integrate Agent with Code

You can easily integrate Sidekick adding below code block to top of your project.
JS example
const SidekickDebugger = require('@runsidekick/sidekick-agent-nodejs');
SidekickDebugger.start({
apiKey: '<Your_Api_Key>'
});
...
TS example
import * as SidekickDebugger from '@runsidekick/sidekick-agent-nodejs';
SidekickDebugger.start({
apiKey: '<Your_Api_Key>'
});
...
note: You also need to define brokerHost & brokerPort parameters if you are using On-prem or a self-hosted version.

Configs

Config
Requirement
Environment Variable
Default
apiKey
Required
SIDEKICK_APIKEY
None
logLevel
Optional
SIDEKICK_AGENT_LOG_LEVEL
info
disable
Optional
SIDEKICK_AGENT_DISABLE
false
brokerHost
Optional
SIDEKICK_AGENT_BROKER_HOST
Sidekick broker address
brokerPort
Optional
SIDEKICK_AGENT_BROKER_PORT
Sidekick broker port
brokerClient
Optional
SIDEKICK_AGENT_BROKER_CLIENT
Logged in user
applicationId
Optional
SIDEKICK_AGENT_APPLICATION_ID
Generated by agent
applicationName
Optional
SIDEKICK_AGENT_APPLICATION_NAME
Empty string
applicationInstanceId
Optional
SIDEKICK_AGENT_APPLICATION_INSTANCE_ID
Generated by agent
applicationVersion
Optional
SIDEKICK_AGENT_APPLICATION_VERSION
Empty string
applicationStage
Optional
SIDEKICK_AGENT_APPLICATION_STAGE
Empty string
applicationTag
Optional
SIDEKICK_AGENT_APPLICATION_TAG
None
maxFrames
Optional
SIDEKICK_AGENT_MAX_FRAMES
20
maxExpandFrames
Optional
SIDEKICK_AGENT_MAX_EXPAND_FRAMES
1
maxProperties
Optional
SIDEKICK_AGENT_MAX_PROPERTIES
10
maxParseDepth
Optional
SIDEKICK_AGENT_MAX_PARSE_DEPTH
3
scriptPrefix
Optional
SIDEKICK_AGENT_SCRIPT_PREFIX
'./'
rejectOnStartup
Optional
SIDEKICK_AGENT_REJECT_ON_STARTUP
false
captureFrameDataReductionCallback
Optional
None
logMessageDataReductionCallback
Optional
None
errorCollectionEnable
Optional
SIDEKICK_AGENT_ERROR_COLLECTION_ENABLE
false
errorCollectionEnableCaptureFrame
Optional
SIDEKICK_AGENT_ERROR_COLLECTION_CAPTURE_FRAME
false