@@ -40,14 +40,23 @@ export async function getPackage(req: Request, res: Response): Promise<void> {
4040 const scorecardScore = pkg . scorecardScore != null ? Number ( pkg . scorecardScore ) : null
4141 const mappingConfidence =
4242 pkg . repoMappingConfidence != null ? Number ( pkg . repoMappingConfidence ) : null
43+ const healthScoreTotal =
44+ pkg . healthScore ?? ( scorecardScore !== null ? Math . round ( scorecardScore * 10 ) : null )
4345
4446 ok ( res , {
4547 purl : pkg . purl ,
4648 name : pkg . name ,
4749 ecosystem : pkg . ecosystem ,
4850 latestVersion : pkg . latestVersion ?? null ,
4951 general : {
50- healthScore : scorecardScore !== null ? Math . round ( scorecardScore * 10 ) : null ,
52+ healthScore : healthScoreTotal ,
53+ healthScoreDetails : {
54+ total : healthScoreTotal ,
55+ label : pkg . healthLabel ,
56+ maintainerHealth : pkg . maintainerHealthScore ,
57+ securitySupplyChain : pkg . securitySupplyChainScore ,
58+ developmentActivity : pkg . developmentActivityScore ,
59+ } ,
5160 healthBand : computeHealthBand ( scorecardScore ) ,
5261 impact : {
5362 impactScore :
@@ -58,7 +67,7 @@ export async function getPackage(req: Request, res: Response): Promise<void> {
5867 transitiveReach : pkg . transitiveReach ,
5968 } ,
6069 riskSignals : {
61- lifecycle : null ,
70+ lifecycle : pkg . lifecycleLabel ?? null ,
6271 maintainerBusFactor : pkg . maintainerCount ,
6372 lastRelease : pkg . latestReleaseAt ? pkg . latestReleaseAt . toISOString ( ) : null ,
6473 hasSecurityFile : pkg . hasSecurityFile ,
@@ -67,6 +76,7 @@ export async function getPackage(req: Request, res: Response): Promise<void> {
6776 openSSFScorecard : scorecardScore ,
6877 } ,
6978 } ,
79+ signalCoverageHealth : pkg . signalCoverageHealth ?? null ,
7080 assessment : null ,
7181 security : {
7282 securityContacts : null ,
0 commit comments