Documentation

Get started with Telegraf Controller

After you’ve installed Telegraf Controller and set up your owner account, you’re ready to start managing Telegraf configurations and agents. This guide walks you through the core workflow: creating a configuration, starting a Telegraf agent using the configuration, and verifying that the agent reports back to Telegraf Controller.

  1. Create an API token
  2. Create a Telegraf configuration
  3. Start a Telegraf agent
  4. View the reporting agent
  5. Update the configuration
  6. Verify the configuration update

Create an API token

API tokens authenticate Telegraf agents when they retrieve configurations and send heartbeats to Telegraf Controller.

  1. Navigate to the API Tokens page.

  2. Click + Create API Token.

  3. Enter a description–for example, Getting started agent token.

  4. Select a token Expiration.

  5. Select the permissions to assign to the token. For convenience, you can select one of the available Permission Presets.

    The Telegraf Agent preset includes all permissions a Telegraf agent needs to interact with Telegraf Controller.

    Telegraf agents need the following permissions to interact with Telegraf Controller:

    • Configurations: Read
    • Heartbeat: Write
  6. Click Create Token.

Copy and store your token

Copy your API token immediately after creation. The full token value is only displayed once and cannot be retrieved later.

For more information about token permissions, see Manage API tokens.

Create a Telegraf configuration

Configurations define what data Telegraf collects, how it processes the data, and where it sends it. For this guide, you’ll create a simple configuration that prints a message to stdout and reports agent health back to Telegraf Controller.

  1. In the Telegraf Controller user interface (UI), select Configurations in the navigation bar.

  2. Click Add Config.

  3. Enter a name and description for the configuration–for example, “Getting Started.”

  4. In the Code Editor, enter the following TOML:

    [[inputs.exec]]
      commands = [
        ["echo", "Started with a config from Telegraf Controller"]
      ]
      data_format = "value"
      data_type = "string"
    
    [[outputs.file]]
      files = ["stdout"]
      data_format = "template"
      template = "{{ .Time.Format \"15:04:05\" }}: {{ .Field \"value\" }}\n"
    
    [[outputs.heartbeat]]
      url = "http://localhost:8000/agents/heartbeat"
      instance_id = "&{agent_id}"
      interval = "1m"
      include = ["hostname", "statistics", "configs", "status"]
      # Include to authorize with Telegraf Controller
      # Note: If using Telegraf 1.38.x or earlier, use INFLUX_TOKEN
      token = "${TELEGRAF_CONTROLLER_TOKEN}"
    
      [outputs.heartbeat.status]
        default = "ok"
    [[inputs.exec]]
      commands = [
        ["cmd", "/C", "echo Started with a config from Telegraf Controller"]
      ]
      data_format = "value"
      data_type = "string"
    
    [[outputs.file]]
      files = ["stdout"]
      data_format = "template"
      template = "{{ .Time.Format \"15:04:05\" }}: {{ .Field \"value\" }}\n"
    
    [[outputs.heartbeat]]
      url = "http://localhost:8000/agents/heartbeat"
      instance_id = "&{agent_id}"
      interval = "1m"
      include = ["hostname", "statistics", "configs", "status"]
      # Include to authorize with Telegraf Controller
      # Note: If using Telegraf 1.38.x or earlier, use INFLUX_TOKEN
      token = "${TELEGRAF_CONTROLLER_TOKEN}"
    
      [outputs.heartbeat.status]
        default = "ok"

    This configuration does the following:

    • Uses the exec input plugin to execute an echo command to output a message.
    • Uses the file output plugin to output the message to stdout, formatted using a template that includes a timestamp and the message.
    • Uses the heartbeat plugin to periodically send agent status information back to Telegraf Controller, which lets you monitor agent health, track which configurations are loaded, and detect when agents stop reporting.
    • Uses the TELEGRAF_CONTROLLER_TOKEN (Telegraf 1.39+) or the INFLUX_TOKEN (Telegraf 1.38.x or earlier) environment variable to authorize with Telegraf Controller.
    • Uses the agent_id parameter to set the instance_id which uniquely identifies the Telegraf agent.

    Heartbeat URL and port

    The example above uses http://localhost and the default heartbeat port, 8000. Your Telegraf Controller instance provides a default heartbeat configuration with the heartbeat URL and port for your instance.

  5. Click Create Configuration.

Start a Telegraf agent

With a configuration and token ready, start a Telegraf agent that pulls its configuration from Telegraf Controller and reports back via the heartbeat plugin.

Use the command builder

Telegraf Controller can build the telegraf command for you:

  1. In Telegraf Controller, select Configurations in the navigation bar.

  2. Click the name of the configuration you created.

  3. Click Use this Configuration.

  4. In the command builder modal:

    1. In the Environment Variables section, define the INFLUX_TOKEN environment variable using the raw token string of the API token you created. This authorizes the Telegraf agent to interact with Telegraf Controller.
    2. In the Parameters section, define the agent_id parameter with a unique agent identifier.
    3. In the Auto Update section, enable auto-update and set the interval to 30s. This instructs Telegraf to check for configuration updates every 30 seconds.
    Telegraf Controller Command Builder
  5. Click Copy Commands to copy the generated command to your clipboard.

  6. Paste and run the command in your terminal.

Run manually

Alternatively, start the agent manually by running the following commands in your terminal. Replace the placeholder values with your actual Telegraf Controller URL and port, configuration ID, API token, and agent ID:

# Note: If using Telegraf 1.38.x or earlier, use INFLUX_TOKEN environment variable
export TELEGRAF_CONTROLLER_TOKEN=
YOUR_TC_API_TOKEN
telegraf \ --config "http://localhost:8888/api/configs/
YOUR_CONFIG_ID
/toml?agent_id=
AGENT_ID
"
\
--config-url-watch-interval 30s
# Note: If using Telegraf 1.38.x or earlier, use INFLUX_TOKEN environment variable
$env:TELEGRAF_CONTROLLER_TOKEN="
YOUR_TC_API_TOKEN
"
telegraf.exe ` --config "http://localhost:8888/api/configs/
YOUR_CONFIG_ID
/toml?agent_id=
AGENT_ID
"
`
--config-url-watch-interval 30s

Replace the following:

  • YOUR_TC_API_TOKEN: API token you created in the previous step
  • YOUR_CONFIG_ID: Configuration ID from your configuration’s detail page in Telegraf Controller
  • AGENT_ID: A unique ID for your Telegraf agent

The TELEGRAF_CONTROLLER_TOKEN (Telegraf 1.39+) or the INFLUX_TOKEN (Telegraf 1.38.x or earlier) environment variables authorize the agent to retrieve the configuration and send heartbeats to Telegraf Controller.

The --config-url-watch-interval flag tells Telegraf to check for configuration updates at the specified interval. In this example, the agent checks every 30 seconds and automatically reloads the configuration if it has changed.

After starting, Telegraf retrieves the configuration from Telegraf Controller and begins collecting metrics. You should see the timestamp and message printed to stdout.

View the reporting agent

Once the agent sends its first heartbeat (within about one minute), it appears in Telegraf Controller.

  1. In Telegraf Controller, select Agents in the navigation bar.
  2. Confirm your agent appears in the list with an Ok status.
  3. Click the More button () and select View Details to see agent metadata, the loaded configuration, and reporting history.

Update the configuration

To see how configuration changes propagate to running agents, update the message generated by the exec input plugin.

  1. In Telegraf Controller, select Configurations in the navigation bar.

  2. Click the name of the configuration you created.

  3. Update the echo command to print a different message:

    [[inputs.exec]]
      commands = [
        ["echo", "Started with AN UPDATED config from Telegraf Controller"]
      ]
      # ...
    [[inputs.exec]]
      commands = [
        ["cmd", "/C", "echo Started with AN UPDATED config from Telegraf Controller"]
      ]
      # ...
  4. Click Save.

Verify the configuration update

Because you started Telegraf with --config-url-watch-interval 30s, the agent checks for configuration updates every 30 seconds. After you update the configuration in Telegraf Controller, the agent detects the change on its next check interval and automatically reloads.

Watch the terminal where Telegraf is running. Within 30 seconds, the message returned in the stdout output updates to the new message, confirming that the agent picked up the updated configuration.

Next steps


Was this page helpful?

Thank you for your feedback!


InfluxDB OSS 2.9.0: API tokens are hashed by default

Stronger token security in InfluxDB OSS 2.9.0 — tokens are hashed on disk by default. Existing tokens are hashed on first startup and can’t be recovered afterward. Capture any plaintext tokens you still need before you upgrade.

View InfluxDB OSS 2.9.0 release notes

Hashed tokens authenticate exactly like unhashed tokens — clients and integrations keep working.

Also new in 2.9.0:

  • Configurable backup compression
  • Restore support for backups containing hashed tokens
  • Tighter Edge Data Replication queue validation
  • Flux upgrade
  • Compaction reliability improvements

Key enhancements in Explorer 1.9

Explorer 1.9 is now available with InfluxQL support, an AI-assisted Flux to SQL converter (beta), and new live sample data simulators.

View Explorer 1.9 release notes

Explorer 1.9 includes new features and improvements that make it easier to query, visualize, and manage data.

Highlights:

  • Flux to SQL converter (beta): Convert Flux queries to SQL with an AI-assisted converter.
  • InfluxQL support: Query data with InfluxQL in the Data Explorer and dashboards, and save and load InfluxQL queries.
  • InfluxQL visualizations: Render line and bar charts from InfluxQL results with per-tag series grouping.
  • Query error history: Review a history of query errors in the query tool.
  • Live sample data simulators: Generate continuous live sample data with new bird data and signal generator simulators.

For more details, see Explorer 1.9 release notes

InfluxDB 3.10 is now available

InfluxDB 3 Core 3.10 adds an automatic catalog format upgrade, a configurable query-concurrency limit, and processing engine improvements.

Key updates in InfluxDB 3 Core 3.10:

  • Catalog format upgrade: the on-disk catalog automatically upgrades from format v2 to v3 on first 3.10 startup. Migration is one-way—back up your catalog before upgrading.
  • --max-concurrent-queries: limit concurrent queries (adjustable at runtime).
  • GET /ready endpoint for readiness probes.
  • Processing engine: cross-database queries and trigger lockdown flags.

For more information, see the InfluxDB 3 Core release notes.

InfluxDB 3.10 is now available

InfluxDB 3 Enterprise 3.10 adds automated backup and restore, row-level deletions, and user management, with an automatic catalog format upgrade and performance preview improvements.

Key updates in InfluxDB 3 Enterprise 3.10:

  • Catalog format upgrade: the on-disk catalog automatically upgrades from format v2 to v3 on first 3.10 startup. Migration is one-way—back up your catalog before upgrading.
  • Automated backup and restore (beta)
  • Row-level deletions
  • User management (authentication and RBAC) — preview
  • Performance preview improvements

Backup and restore, row-level deletions, and the performance preview require the Enterprise storage engine upgrade (opt-in beta). Beta and preview features are subject to breaking changes and aren’t recommended for production use.

For more information, see the InfluxDB 3 Enterprise release notes

Telegraf Enterprise is now generally available

Telegraf Enterprise is now generally available, along with Telegraf Controller v1.0.

Telegraf Enterprise combines Telegraf Controller, a centralized management console for Telegraf, with official support from InfluxData. Manage configurations, monitor fleet health, and operate tens of thousands of Telegraf agents from a single system.

InfluxDB Docker latest tag changing to InfluxDB 3 Core

On September 15, 2026, the latest tag for InfluxDB Docker images will point to InfluxDB 3 Core. To avoid unexpected upgrades, use specific version tags in your Docker deployments.

If using Docker to install and run InfluxDB, the latest tag will point to InfluxDB 3 Core. To avoid unexpected upgrades, use specific version tags in your Docker deployments. For example, if using Docker to run InfluxDB v2, replace the latest version tag with a specific version tag in your Docker pull command–for example:

docker pull influxdb:2