LGTM API specification

The REST API for LGTM provides data so that you can customize how you integrate LGTM analysis into your workflow. It includes the following resources: * `/` ([API root](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-API-root))—get version information or download the specification in OpenAPI format. * `/projects` ([Projects](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Projects))—list projects, get a summary of the current status for a project, or add new projects. * `/analyses` ([Analyses](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Analyses))—get a summary of results, download all the alerts, or trigger analysis for a specific commit. * `/codereviews` ([Code reviews](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Code-reviews))—trigger code review for a patch, and view the results. * `/operations` ([Operations](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Operations))—get information about long-running tasks, for example, analyses or code reviews that you've requested. * `/snapshots` ([Snapshots](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Snapshots))—download and upload databases representing a snapshot of a codebase. * `/queryjobs` ([Query jobs](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-Query-jobs))—submit queries to evaluate against existing projects, and download their results. * `/system` ([System](https://lgtm.com/help/lgtm/api/api-v1#LGTM-API-specification-System))—get information on the health or usage of the system. For an overview and getting started topics, see [API for LGTM](https://lgtm.com/help/lgtm/api/api-for-lgtm).

Claim this API

Are you the operator of LGTM API specification? Submit a claim to establish contact with us.

Report an Issue

Found something wrong with LGTM API specification? Let us know about broken links, changed auth, deprecated endpoints, or other issues.

Base URL: https://lgtm.com/api/v1.0
Auth: unknown
Endpoints: 14
Reachable: unknown
CORS: unknown

Endpoints

Method Path Summary Auth Last Status Latency
GET / Version information
GET /analyses/{analysis-id} Get analysis summary
GET /analyses/{analysis-id}/alerts Get detailed alert information
GET /analyses/{project-id}/commits/{commit-id} Get analysis summary for a specific commit
GET /codereviews/{review-id} Get results of code review
GET /issues/{project-id}/{alert-key} Get detailed alert information for an issue
GET /openapi API specification
GET /operations/{operation-id} Get operation status
GET /projects List projects
GET /projects/{project-id} Get project by numeric identifier
GET /projects/{provider}/{org}/{name} Get project by URL identifier
POST /queryjobs Run a CodeQL query on one or more projects
GET /queryjobs/{queryjob-id} Get the status of a query job
GET /queryjobs/{queryjob-id}/results Provide a summary of results for the projects in the query job
GET /queryjobs/{queryjob-id}/results/{project-id} Fetch the results of a query job for a specific project
GET /snapshots/{project-id}/{language} Download a snapshot
GET /system/health Get a summary of the application's health
GET /system/metrics Get the identifiers and descriptions of the usage metrics
GET /system/metrics/{metric-id} Get the computed values of the specified metric