Skip to content


Ioto provides detailed tracing regarding client accesses and the operation of Ioto.

The Ioto tracing is configured via the trace property in the config.json file. It can also be specified via the --trace command line option when invoking ioto.


Tracing can be directed toward a trace file or toward AWS CloudWatch logs.

The trace property in config.json specifies the destination via the path property. This property can be set to stdout, stderr, any trace filename or "aws".

trace: {
    path: 'ioto.log',
    format: '%D %H %A[%P] %T %S %M',
    types: 'error,info',
    sources: 'all',

The format property specifies a format for trace messages. It contains printf style tokens that are expanded at runtime. The supported tokens are: 'A' for the application name, 'D' for the local datetime, 'H' for the system hostname, 'M' for the trace message, 'P' for the process ID , 'S' for the message source, and 'T' for the trace message type.

Ioto classifies trace messages according to types. The supported types are: debug, error, info, and trace. The types property specifies a comma separate list of trace message types to emit.

Log messages are emitted from "sources". These are the code module names that originate the trace messages. The sources property is a comma separated list of sources. Some of the Ioto trace message sources are: "runtime", "tls", "mbedtls", "json", "url" and "web".

You can use "all" for types and sources to match all types/sources. You can also use "!type" and "!source" to negate a type or source.

Command Line

You can override the tracing configuration when invoking Ioto via the --trace command line option.

This option specifies the trace file destination and a list of types and sources.

ioto --trace file[:types:sources]

The --trace option syntax is **fileName[:types:sources]. The types are a comma separated list of message types. Valid types include: info, debug, error, trace and all. Sources are the code module names originating the trace messages. You can use "!type" and "!source" to negate a type or source.