ecr.packages.searchFind the images that contain a package
Every scan keeps the full package list of the image, vulnerable packages or not, so the question "which images contain this package" is answered the day an advisory is published, before any vulnerability database knows the CVE. Names match exactly (case-insensitive) unless contains=true. Images scanned before package lists were kept get one on their next scan.
Request syntax
GET /ecr/api/packagesQuery parameters
nameRequiredstring
Package name, case-insensitive (`log4j-core`, `openssl`, `next`)
Constraints: 1-214 chars
containsOptionalenum
true matches every package whose name contains `name`; exact when omitted
One of:
true,falseversionOptionalstring
Only this exact version
Constraints: 1-128 chars
ecosystemOptionalstring
Only this ecosystem as the scanner names it: `debian`, `alpine`, `npm`, `gomod` …
Constraints: /^[a-z0-9-]{1,32}$/
limitOptionalnumber
Matches per page, 1–500; 100 when omitted
Constraints: integer, 1-500
Default:
100offsetOptionalnumber
Matches to skip; 0 when omitted
Constraints: integer, 0-1000000
Default:
0
Response
200 with one page of matches (data), hasMore, and imagesWithPackages (how many images have a stored package list). Each match: repositoryId, repositoryName, manifestId, digest, tags, ecosystem, name, version, purl, target (the file or layer path it was found in), runningIn (apps running that digest), lastPulledAt, pushedAt.
A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.
Errors
- 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
- 401No credentials, or an access key that is unknown, revoked or expired.
- 403The caller's policies do not allow ecr:GetScanResults on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
- 404The resource does not exist in your organization.
Examples
The required parameters only, with example values. Replace id and the other placeholders with your own.
dcloud ecr packages search --name examplecurl -X GET "https://console.platform.deutschecloud.app/ecr/api/packages" \
-H "Authorization: EWS-ACCESS-KEY $ACCESS_KEY"Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_ecr_packages_search.