The binary executable is a command-line interface (CLI) that allows you to configure how the analytics instance behaves. This document outlines the available commands and their usage.

Commands

  • start: Starts the analytics server.
  • version: Displays the version of the analytics server.

start

The following flags can be used with the start command:

Available Flags
Usage of start:
  -analyticsdb string
        Path to analytics database. (default "./me_analytics.db")
  -appdb string
        Path to app database. (default "./me_meta.db")
  -corsorigins string
        Comma separated list of allowed CORS origins on API routes. Useful for external dashboards that may host the frontend on a different domain.
  -env bool
        Opt-in to allow environment variables to be used for configuration. Flags will still override environment variables.
  -level string
        Logger level (debug, info, warn, error) (default "info")
  -logger string
        Logger format (json, pretty) (default "json")
  -port int
        Port to listen on. (default 8080)

Example usage:

Example Command
./medama-executable start -env -port=8080 -logger=pretty -level=debug -corsorigins=http://localhost:8080,http://localhost:3000