---
title: Integrate with external plugins
description: External plugins are external programs that are built outside of Telegraf that can run through an execd plugin.
url: https://docs.influxdata.com/telegraf/v1/configure_plugins/external_plugins/
estimated_tokens: 1205
product: Telegraf
version: v1
---

# Integrate with external plugins

[External plugins](https://github.com/influxdata/telegraf/blob/master/EXTERNAL_PLUGINS.md) are external programs that are built outside of Telegraf that can run through an `execd` plugin. These external plugins allow for more flexibility compared to internal Telegraf plugins. Benefits to using external plugins include:

-   Access to libraries not written in Go
-   Using licensed software (not available to open source community)
-   Including large dependencies that would otherwise bloat Telegraf
-   Using your external plugin immediately without waiting for the Telegraf team to publish
-   Easily convert plugins between internal and external using the [shim](https://github.com/influxdata/telegraf/blob/master/plugins/common/shim/README.md)

## [Use the `execd` shim](/telegraf/v1/configure_plugins/external_plugins/shim/)

The shim makes it easy to extract an internal input, processor, or output plugin from the main Telegraf repo out to a stand-alone repo. This allows anyone to build and run it as a separate app using one of the `execd` plugins:

-   [inputs.execd](https://github.com/influxdata/telegraf/blob/master/plugins/inputs/execd)
-   [processors.execd](https://github.com/influxdata/telegraf/blob/master//plugins/processors/execd)
-   [outputs.execd](https://github.com/influxdata/telegraf/blob/master/plugins/outputs/execd)

## Extract a plugin using the shim wrapper

1. Move the project to an external repo. We recommend preserving the path structure: for example, if your plugin was located at `plugins/inputs/cpu` in the Telegraf repo, move it to `plugins/inputs/cpu` in the new repo.
2. Copy [main.go](https://github.com/influxdata/telegraf/blob/master/plugins/common/shim/example/cmd/main.go) into your project under the `cmd` folder. This serves as the entry point to the plugin when run as a stand-alone program.
    
    The shim isn’t designed to run multiple plugins at the same time, so include only one plugin per repo.
    
    ## [Write an external plugin](/telegraf/v1/configure_plugins/external_plugins/write_external_plugin/)
    
    Set up your plugin to use it with `execd`.
    
    For listed [external plugins](https://github.com/influxdata/telegraf/blob/master/EXTERNAL_PLUGINS.md), the author of the external plugin is also responsible for the maintenance and feature development of external plugins.
    
    1. Write your Telegraf plugin. Follow InfluxData’s best practices:
        -   [Input plugins](https://github.com/influxdata/telegraf/blob/master/docs/INPUTS.md)
        -   [Processor plugins](https://github.com/influxdata/telegraf/blob/master/docs/PROCESSORS.md)
        -   [Aggregator plugins](https://github.com/influxdata/telegraf/blob/master/docs/AGGREGATORS.md)
        -   [Output plugins](https://github.com/influxdata/telegraf/blob/master/docs/OUTPUTS.md)
    2. If your plugin is written in Go, follow the steps for the [Execd Go Shim](/telegraf/v1/configure_plugins/external_plugins/shim).
    3. Add usage and development instructions in the homepage of your repository for running your plugin with its respective `execd` plugin. Refer to [openvpn](https://github.com/danielnelson/telegraf-execd-openvpn#usage) and [awsalarms](https://github.com/vipinvkmenon/awsalarms#installation) for examples. Include the following steps:
        -   How to download the release package for your platform or how to clone the binary for your external plugin
        -   Commands to build your binary
        -   Location to edit your `telegraf.conf`
        -   Configuration to run your external plugin with [inputs.execd](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/execd), [processors.execd](https://github.com/influxdata/telegraf/tree/master/plugins/processors/execd) or [outputs.execd](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/execd)
    4. Submit your plugin by opening a PR to add your external plugin to the [/EXTERNAL\_PLUGINS.md](https://github.com/influxdata/telegraf/blob/master/EXTERNAL_PLUGINS.md) list. Include the plugin name, a link to the plugin repository and a short description of the plugin.
