Select Supported Platforms

Select Supported Architectures

Select Tier

Github Name

v3.0.0 · public · Published about 4 years ago

Asset Definition
Release Notes
Release Assets


Build Status
Gem Version
Code Climate
Test Coverage
Dependency Status
Sensu Bonsai Asset



  • bin/handler-victorops.rb


bin/handler-victorops.rb --help
Usage: bin/handler-victorops.rb (options)
    -a, --api-url APIURL             VictorOps API URL without routing key. Or use envvar VICTOROPS_API_URL.
        --dryrun                     Report settings, and take no action
        --map-go-event-into-ruby     Enable Sensu Go to Sensu Ruby event mapping. Alternatively set envvar SENSU_MAP_GO_EVENT_INTO_RUBY=1.
    -r, --routingkey KEY             Routing key. Or use envvar VICTOROPS_ROUTING_KEY.

Sensu Go Enabled

Plugin versions 2.0 and higher are now Sensu Go enabled. You can map Sensu Go events into Sensu Classic events by using the flag --map_go_event_into_ruby as part of your command. Now that Sensu Classic is now EOL, a future version of this plugin will drop support for Sensu Classic and will assume Sensu Go event structuring.

Here is an example Sensu Go handler resource definition for reference. Please note, this plugin's Sensu Asset should be used in conjunction with the Sensu Ruby runtime asset.

type: Handler
    name: victorops
    namespace: default
  type: pipe
  command: handler-victorops.rb --map_go_event_into_ruby
  timeout: 0
  handlers: []
  - is_incident
  - sensu-plugins-victorops
  - sensu-ruby-runtime

You'll note that the plugin supports environment variables for both routing key and api url. You can define this in the Sensu Go handler resource definition. You can support multiple VictorOps accounts by having a different handler definition, each with appropriate environment variables defined.

Sensu Classic Support

Here is an example handlers configuration for Sensu Classic. Please note, Sensu Classic has now reached EOL, and support for Sensu Classic events is planned to be removed in a future version of this plugin.

  "victorops": {
    "routing_key": "everyone"
  "handlers": {
    "victorops": {
      "type": "pipe",
      "command": "handler-victorops.rb"

If you have multiple VictorOps accounts and need to route alerts to different endpoints, specifying the handler name in the config is necessary otherwise, the handler will attempt to route to the default victorops. You will therefore need to use the -name switch to specify the API endpoint as noted below.

"victorops_enpoint1": {
      "type": "pipe",
      "command": "/opt/sensu/embedded/bin/handler-victorops.rb -name victorops_endpoint1"


Installation and Setup

Are you sure you want to report this asset?

Please describe the reason for reporting this asset. Our moderators will be notified and will disable the asset if it is found to be inappropriate.


You must be signed in to report this asset.

Sign In with Github



Either download the source code:

Download Source

Or download the asset definition: