One unit's latest report, with its packages
const url = 'https://example.com/v1/units/report?unit=example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://example.com/v1/units/report?unit=example' \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”The unit ID, exactly
Responses
Section titled “Responses”The unit
object
Owning tenant. Optional on input; if set it must match the caller’s organization. Always set on output.
Unique within a tenant. Valid UTF-8 without control characters (400, report.invalid).
Release the unit runs. Collectors before the rename send it as “firmware”
Product key from PRODUCT= in the device’s release file. Optional; longer is refused (400, report.invalid).
Variant name from VARIANT= in the device’s release file. Optional; longer is refused (400, report.invalid).
Version of the collector that sent the report. Optional (older collectors don’t send it); longer is refused (400, report.invalid).
Output only. The organization’s release the unit’s last report names: product key, variant and version; else an alias of the version; else, without a product, the one release with that version. Absent when the report names none.
Output only. Whether release_id is set. A linked unit inherits its release’s VEX statements; an unlinked one is judged on its own SBOM matches only.
Output only. The names of the release release_id points to; absent when unlinked.
object
The product’s name.
When the inventory was taken. Required; more than 10 minutes ahead of the server’s clock is refused (400, report.invalid), since it would make every later report look older.
Required on input: online (pushed) or bundle (imported). Anything else is refused (400, report.invalid).
Output only. False when the unit’s last report had no package URLs (a collector before), so its packages aren’t matched against vulnerabilities and it doesn’t count in blast radius or triage.
A report with more packages is refused (400, report.invalid).
object
Package URL for vulnerability matching, such as pkg:deb/debian/libc6@2.36-9?arch=amd64&distro=debian-12&upstream=glibc. Optional; collectors before don’t send it, and their units aren’t matched. A PURL that doesn’t parse or is longer is ignored.
Example
{ "delivery": "online"}Request.fieldRequired (params.field unit)
Missing or invalid API key
No such unit
Over the operation’s rate-limit budget (x-affectra-budget): code request.rateLimited with params.budget. Wait Retry-After seconds before trying again.
Every error answer, Content-Type
application/problem+json. The web app and integrations translate code; detail is English,
for people reading curl output or CI logs, and may change wording at
any time. Match on code, never on detail.
object
The HTTP status
Stable error codes. A code is never renamed; new ones may be added, so
a client falls back to detail for a code it doesn’t know. Another
organization’s object answers notFound, the same as a missing one.
What went wrong
Values the code’s message needs, e.g. {“field”: “version”}. Only values the caller sent or may see. Empty when the message needs none.
object
Example
{ "code": "notFound"}Headers
Section titled “Headers”Seconds until a request would be allowed again, at least 1