Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

logstash-filter-mautic

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

logstash-filter-mautic

  • 0.3
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Logstash Plugin

Build
Status

This is a plugin for Logstash.

It is fully free and fully open source. The license is Apache 2.0, meaning you are pretty much free to use it however you want in whatever way.

  1. Install this plugin using
./plugin install logstash-filter-mautic
  1. Setup your Logstash configuration like so
input {
	http {
		host => "127.0.0.1"
		port => "5543"
		type => "mautic-lead"
	}

}
filter {

if [type] == "mautic-lead" {
		mautic {
			source => "message"
			remove_field => ["headers", "message", "host"]
		}
		if [type] == "lead"{
			mutate {
				replace => { "@timestamp" => "%{dateAdded}"}
			}
		}
		if [type] == "form_submission"{
			mutate {
				replace => { "@timestamp" => "%{dateSubmmited}"}
			}
		}
		if [type] == "email"{
			mutate {
				replace => { "@timestamp" => "%{dateSent}"}
			}
		}
		if [type] == "page_hit"{
			mutate {
				replace => { "@timestamp" => "%{dateHit}"}
			}
		}
		
	}

}
output {
	if [type] == "lead" {
		elasticsearch { 
			hosts => ["localhost:9200"] 
			index => ["mautic-leads"]
			#document_id => "%{[leadid]}"
		}
	}
	else if [type] == "form_submission" {
		elasticsearch { 
			hosts => ["localhost:9200"] 
			index => ["mautic-leads"]
			document_id => "F%{[leadid]}-%{[form][id]}-%{[submissionid]}"
			routing => "%{[leadid]}"
		}
	}
	else if [type] == "page_hit" {
		elasticsearch { 
			hosts => ["localhost:9200"] 
			index => ["mautic-leads"]
			routing => "%{[leadid]}"
		}
	}
	else if [type] == "email" {
		elasticsearch { 
			hosts => ["localhost:9200"] 
			index => ["mautic-leads"]
			document_id => "E%{[leadid]}-%{[email][id]}-%{[emailopenid]}"
			routing => "%{[leadid]}"
		}
	}
	}

FAQs

Package last updated on 22 Dec 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc