github.com/influxdata/telegraf@v1.30.3/docs/developers/SAMPLE_CONFIG.md (about)

     1  # Sample Configuration
     2  
     3  The sample config file is generated from a results of the `SampleConfig()` functions of the plugin.
     4  
     5  You can generate a full sample
     6  config:
     7  
     8  ```shell
     9  telegraf config
    10  ```
    11  
    12  You can also generate the config for a particular plugin using the `-usage`
    13  option:
    14  
    15  ```shell
    16  telegraf --usage influxdb
    17  ```
    18  
    19  ## Style
    20  
    21  In the config file we use 2-space indention.  Since the config is
    22  [TOML](https://github.com/toml-lang/toml) the indention has no meaning.
    23  
    24  Documentation is double commented, full sentences, and ends with a period.
    25  
    26  ```toml
    27    ## This text describes what an the exchange_type option does.
    28    # exchange_type = "topic"
    29  ```
    30  
    31  Try to give every parameter a default value whenever possible.  If a
    32  parameter does not have a default or must frequently be changed then have it
    33  uncommented.
    34  
    35  ```toml
    36    ## Brokers are the AMQP brokers to connect to.
    37    brokers = ["amqp://localhost:5672"]
    38  ```
    39  
    40  Options where the default value is usually sufficient are normally commented
    41  out.  The commented out value is the default.
    42  
    43  ```toml
    44    ## What an exchange type is.
    45    # exchange_type = "topic"
    46  ```
    47  
    48  If you want to show an example of a possible setting filled out that is
    49  different from the default, show both:
    50  
    51  ```toml
    52    ## Static routing key.  Used when no routing_tag is set or as a fallback
    53    ## when the tag specified in routing tag is not found.
    54    ##   example: routing_key = "telegraf"
    55    # routing_key = ""
    56  ```
    57  
    58  Unless parameters are closely related, add a space between them.  Usually
    59  parameters is closely related have a single description.
    60  
    61  ```toml
    62    ## If true, queue will be declared as an exclusive queue.
    63    # queue_exclusive = false
    64  
    65    ## If true, queue will be declared as an auto deleted queue.
    66    # queue_auto_delete = false
    67  
    68    ## Authentication credentials for the PLAIN auth_method.
    69    # username = ""
    70    # password = ""
    71  ```
    72  
    73  Parameters should usually be describable in a few sentences.  If it takes
    74  much more than this, try to provide a shorter explanation and provide a more
    75  complex description in the Configuration section of the plugins
    76  [README](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/example)
    77  
    78  Boolean parameters should be used judiciously.  You should try to think of
    79  something better since they don't scale well, things are often not truly
    80  boolean, and frequently end up with implicit dependencies: this option does
    81  something if this and this are also set.