{"openapi":"3.0.1","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"\/"}],"paths":{"\/api\/usage\/upgrade":{"post":{"tags":["usage-controller"],"operationId":"postUpgradeEvent","parameters":[{"name":"X-Country-Code","in":"header","required":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application\/json":{"schema":{"$ref":"#\/components\/schemas\/UpgradeEventRequest"}}},"required":true},"responses":{"200":{"description":"OK"}}}},"\/api\/stats\/version":{"get":{"tags":["stats-controller"],"operationId":"getVersionStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/VersionStats"}}}}}}}},"\/api\/stats\/version-over-time":{"get":{"tags":["stats-controller"],"operationId":"getVersionOverTimeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/VersionWeeklyStats"}}}}}}}},"\/api\/stats\/usermods":{"get":{"tags":["stats-controller"],"operationId":"getUsermodsStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FeatureStats"}}}}}}}},"\/api\/stats\/upgrade-vs-installation":{"get":{"tags":["stats-controller"],"operationId":"getUpgradeVsInstallationStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/UpgradeVsInstallationWeeklyStats"}}}}}}}},"\/api\/stats\/running-versions":{"get":{"tags":["stats-controller"],"operationId":"getRunningVersionsStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/VersionWeeklyStats"}}}}}}}},"\/api\/stats\/release-name":{"get":{"tags":["stats-controller"],"operationId":"getReleaseNameStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/ReleaseNameStats"}}}}}}}},"\/api\/stats\/release-downloads":{"get":{"tags":["release-download-stats-controller"],"operationId":"getReleaseDownloadStats","responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/ReleaseDownloadStats"}}}}}}}},"\/api\/stats\/psram-size":{"get":{"tags":["stats-controller"],"operationId":"getPsramSizeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/PsramSizeStats"}}}}}}}},"\/api\/stats\/previous-version":{"get":{"tags":["stats-controller"],"operationId":"getPreviousVersionStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/PreviousVersionStats"}}}}}}}},"\/api\/stats\/peripherals":{"get":{"tags":["stats-controller"],"operationId":"getPeripheralsStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FeatureStats"}}}}}}}},"\/api\/stats\/matrix":{"get":{"tags":["stats-controller"],"operationId":"getMatrixStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/MatrixStats"}}}}}}}},"\/api\/stats\/led-features":{"get":{"tags":["stats-controller"],"operationId":"getLedFeaturesStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FeatureStats"}}}}}}}},"\/api\/stats\/led-count":{"get":{"tags":["stats-controller"],"operationId":"getLedCountRangeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/LedCountRangeStats"}}}}}}}},"\/api\/stats\/integrations":{"get":{"tags":["stats-controller"],"operationId":"getIntegrationsStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FeatureStats"}}}}}}}},"\/api\/stats\/install-chip-over-time":{"get":{"tags":["stats-controller"],"operationId":"getInstallChipOverTimeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/ChipWeeklyStats"}}}}}}}},"\/api\/stats\/fs-usage":{"get":{"tags":["stats-controller"],"operationId":"getFsUsageStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FsUsageRangeStats"}}}}}}}},"\/api\/stats\/fs-total":{"get":{"tags":["stats-controller"],"operationId":"getFsTotalStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FsTotalStats"}}}}}}}},"\/api\/stats\/flash-size":{"get":{"tags":["stats-controller"],"operationId":"getFlashSizeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FlashSizeStats"}}}}}}}},"\/api\/stats\/country":{"get":{"tags":["stats-controller"],"operationId":"getCountryStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/CountryStats"}}}}}}}},"\/api\/stats\/chip":{"get":{"tags":["stats-controller"],"operationId":"getChipStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/ChipStats"}}}}}}}},"\/api\/stats\/chip-over-time":{"get":{"tags":["stats-controller"],"operationId":"getChipOverTimeStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/ChipWeeklyStats"}}}}}}}},"\/api\/stats\/bus-types":{"get":{"tags":["stats-controller"],"operationId":"getBusTypesStats","parameters":[{"name":"repo","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"$ref":"#\/components\/schemas\/FeatureStats"}}}}}}}},"\/api\/auth\/user":{"get":{"tags":["auth-controller"],"operationId":"getCurrentUser","responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"object","additionalProperties":{"type":"object"}}}}}}}},"\/api\/auth\/repos":{"get":{"tags":["auth-controller"],"operationId":"getUserRepos","responses":{"200":{"description":"OK","content":{"*\/*":{"schema":{"type":"array","items":{"type":"string"}}}}}}}}},"components":{"schemas":{"UpgradeEventRequest":{"required":["bootloaderSHA256","chip","deviceId","isMatrix","ledCount","previousVersion","releaseName","version"],"type":"object","properties":{"deviceId":{"type":"string"},"version":{"type":"string"},"previousVersion":{"type":"string"},"releaseName":{"type":"string"},"chip":{"type":"string"},"ledCount":{"type":"integer","format":"int32"},"isMatrix":{"type":"boolean"},"bootloaderSHA256":{"type":"string"},"brand":{"type":"string"},"product":{"type":"string"},"flashSize":{"type":"integer","format":"int32"},"partitionSizes":{"type":"string"},"psramSize":{"type":"integer","format":"int32"},"psramPresent":{"type":"boolean"},"repo":{"type":"string"},"fsUsed":{"type":"integer","format":"int32"},"fsTotal":{"type":"integer","format":"int32"},"busCount":{"type":"integer","format":"int32"},"busTypes":{"type":"array","items":{"type":"string"}},"ledFeatures":{"type":"array","items":{"type":"string"}},"peripherals":{"type":"array","items":{"type":"string"}},"integrations":{"type":"array","items":{"type":"string"}},"usermods":{"type":"array","items":{"type":"string"}},"usermodIds":{"type":"array","items":{"type":"integer","format":"int32"}}}},"VersionStats":{"required":["deviceCount","version"],"type":"object","properties":{"version":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"VersionWeeklyStats":{"required":["count","version","week"],"type":"object","properties":{"week":{"type":"string"},"version":{"type":"string"},"count":{"type":"integer","format":"int64"}}},"FeatureStats":{"required":["deviceCount","feature"],"type":"object","properties":{"feature":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"UpgradeVsInstallationWeeklyStats":{"required":["newInstallations","upgrades","week"],"type":"object","properties":{"week":{"type":"string"},"upgrades":{"type":"integer","format":"int64"},"newInstallations":{"type":"integer","format":"int64"}}},"ReleaseNameStats":{"required":["deviceCount","releaseName"],"type":"object","properties":{"releaseName":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"ReleaseDownloadStats":{"required":["assetName","created","delta","downloadCount","repoName","tagName"],"type":"object","properties":{"repoName":{"type":"string"},"tagName":{"type":"string"},"assetName":{"type":"string"},"downloadCount":{"type":"integer","format":"int64"},"delta":{"type":"integer","format":"int64"},"created":{"type":"string"}}},"PsramSizeStats":{"required":["deviceCount","psramSize"],"type":"object","properties":{"psramSize":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"PreviousVersionStats":{"required":["deviceCount","previousVersion"],"type":"object","properties":{"previousVersion":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"MatrixStats":{"required":["deviceCount","isMatrix"],"type":"object","properties":{"isMatrix":{"type":"boolean"},"deviceCount":{"type":"integer","format":"int64"}}},"LedCountRangeStats":{"required":["deviceCount","range"],"type":"object","properties":{"range":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"ChipWeeklyStats":{"required":["chip","count","week"],"type":"object","properties":{"week":{"type":"string"},"chip":{"type":"string"},"count":{"type":"integer","format":"int64"}}},"FsUsageRangeStats":{"required":["deviceCount","range"],"type":"object","properties":{"range":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"FsTotalStats":{"required":["deviceCount","fsTotal"],"type":"object","properties":{"fsTotal":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"FlashSizeStats":{"required":["deviceCount","flashSize"],"type":"object","properties":{"flashSize":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"CountryStats":{"required":["countryCode","deviceCount"],"type":"object","properties":{"countryCode":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}},"ChipStats":{"required":["chip","deviceCount"],"type":"object","properties":{"chip":{"type":"string"},"deviceCount":{"type":"integer","format":"int64"}}}},"securitySchemes":{"Bearer Authentication":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}}}