REST API
This page documents the active REST API surface in SMM.
Note: Swagger UI is the authoritative source for the full schema and examples. Default path:
http://localhost:<port>/api/docs.
Start API
From the workspace root:
smm dashboard serveThe bundled stack starts the REST API on port 3001 and the webapp on port 3000; override them with --rest-port and --webapp-port. For local development, pnpm --filter @smmachine/rest dev runs the API on port 8000, and running the compiled entrypoint directly uses PORT or 3000 when PORT is unset.
Timezone query parameter
Time-based endpoints accept timezone as an optional IANA timezone identifier, for example Europe/Madrid, America/New_York, or UTC.
Use this parameter when sending date-only filters or when consuming grouped metrics from a dashboard or client application:
GET /change-requests/summary?start_date=2026-01-01&end_date=2026-01-31&timezone=Europe%2FMadridREST requests use the timezone query parameter first. If it is missing or invalid, SMM falls back to the active project's configured timezone, then to UTC.
Date-only values such as 2026-01-01 are interpreted as calendar dates in the selected timezone. Offset-aware date-time values such as 2026-01-01T09:00:00+01:00 are treated as exact instants.
Change requests
GET /change-requests/summaryGET /change-requests/through-timeGET /change-requests/by-authorGET /change-requests/review-timeGET /change-requests/open-timeGET /change-requests/commentsGET /change-requests/comments-by-authorGET /change-requests/first-comment-timeGET /change-requests/filter-optionsGET /change-requests/evaluate
Common query params:
start_date,end_datetimezoneauthors,exclude_authors,exclude_commenters,labelsstatusaggregate_by
Pipelines
GET /pipelines/summaryGET /pipelines/by-statusGET /pipelines/jobs-by-statusGET /pipelines/jobs-summaryGET /pipelines/runs-durationGET /pipelines/jobs-duration-by-workflowGET /pipelines/dashboardGET /dora/deployment-frequencyGET /pipelines/runs-byGET /pipelines/jobs-time-executionGET /pipelines/jobs-time-execution-by-dayGET /pipelines/jobs-reruns-by-dayGET /pipelines/jobs-steps-timeGET /pipelines/jobs-steps-time-by-dayGET /pipelines/filter-optionsGET /pipelines/workflowsGET /pipelines/statusesGET /pipelines/conclusionsGET /pipelines/branchesGET /pipelines/eventsGET /pipelines/jobsGET /pipelines/evaluate
Common query params:
start_date,end_datetimezoneworkflow_pathstatus,conclusionjob_name,branch,eventaggregate_by,top
Source Code
GET /code/pairing-indexGET /code/code-churnGET /code/code-churn/historyGET /code/couplingGET /code/coupling/historyGET /code/layered-couplingGET /code/layered-coupling/historyGET /code/entity-churnGET /code/entity-churn/historyGET /code/entity-effortGET /code/entity-effort/historyGET /code/entity-ownershipGET /code/entity-ownership/historyGET /code/authorsGET /code/big-oGET /code/big-o/fileGET /code/evaluate
Common query params:
start_date,end_datetimezoneauthorsignore_files,include_onlytoptype_churn
Issue tracking
GET /api/metrics/issues
Common query params:
statusstartDate,endDate
SonarQube
GET /sonarqube/qualityGET /sonarqube/component-treeGET /sonarqube/measurementsGET /sonarqube/measurements/historyGET /sonarqube/component-tree/historyGET /sonarqube/evaluate
Common query params:
measurescomponent,depth,metricsignore_files,include_files,remove_folders
Architecture
GET /architecture/snapshotsGET /architecture/summaryGET /architecture/viewGET /architecture/evaluate
The architecture endpoints read the snapshots persisted by smm architecture generate; they never generate data.
Engineering health
GET /engineering-health/evaluate
Accepts the same filters as smm engineering-health evaluate (metric, category, current and comparison windows, period, weekend and outlier handling).
Metric catalog
GET /metrics
Returns the static metric catalog with ids, namespaces, computation metadata and surface mappings. Supports the same namespace and visibility query parameters as smm metrics list.
Filters
GET /filters
Returns the saved filters for the active project.
Projects and version
GET /projectsGET /version
GET /projects lists the configured projects; GET /version returns the running application version.
Legacy aggregate metrics
The original aggregate endpoints remain available under /api/metrics/*:
GET /api/metrics/issuesGET /api/metrics/change-requestsGET /api/metrics/deploymentGET /api/metrics/codeGET /api/metrics/qualityGET /api/metrics/report
Prefer the domain endpoints above for new integrations; the aggregate endpoints return pre-computed report shapes.
Logging
The REST API has two logging layers:
Domain service logging
The core business logic (Jira, SonarQube, change requests, pipelines, etc.) always respects the project's configured log_level, <REPO>_LOGGING_LEVEL env var, or falls back to CRITICAL. These logs use the standard SMM log format ([timestamp] [LEVEL] [serviceName] message) and can optionally write to the log file if store_logs is enabled.
HTTP-level logging
Request logging (middleware), controller debug/error messages, exception filters, and the startup banner use SmmNestLogger — a NestJS LoggerService wrapper around the SMM logger. Its level is controlled by the DEBUG environment variable only:
DEBUG=true— all messages visible (equivalent to INFO level)- No
DEBUG— only fatal logs appear (CRITICAL level)
To see HTTP request logs in development:
DEBUG=true smm dashboard serveOr with the binary directly:
DEBUG=true PORT=8000 node apps/rest/dist/main.jsHTTP-level logging does not currently read per-project `log_level` from `smm_config.json`. Domain service logs
always respect it. If you need HTTP logs, use `DEBUG=true`.Configuration
GET /configuration
Returns active runtime configuration values used by dashboard and API integrations.