From b07807091da56ea7df387a2da585f5f20bc31add Mon Sep 17 00:00:00 2001 From: Will Ratner Date: Mon, 25 Nov 2024 15:00:09 -0500 Subject: [PATCH] Add cyclonedx json media type when exporting components Signed-off-by: Will Ratner Signed-off-by: Will Ratner --- src/main/java/org/dependencytrack/resources/v1/BomResource.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/dependencytrack/resources/v1/BomResource.java b/src/main/java/org/dependencytrack/resources/v1/BomResource.java index ddfd9c7f8..0f5b6d0de 100644 --- a/src/main/java/org/dependencytrack/resources/v1/BomResource.java +++ b/src/main/java/org/dependencytrack/resources/v1/BomResource.java @@ -191,7 +191,7 @@ public Response exportProjectAsCycloneDx ( @GET @Path("/cyclonedx/component/{uuid}") - @Produces(CycloneDxMediaType.APPLICATION_CYCLONEDX_XML) + @Produces({CycloneDxMediaType.APPLICATION_CYCLONEDX_XML, CycloneDxMediaType.APPLICATION_CYCLONEDX_JSON}) @Operation( summary = "Returns dependency metadata for a specific component in CycloneDX format", description = "

Requires permission VIEW_PORTFOLIO

"