Edit SBOM Metadata
You can change a version's metadata through the API: who authored the SBOM, who supplies it, and the license that governs the document itself. This guide covers SBOM authors, suppliers, and the data license.
Every call here needs the version ID (sbomId). Get it from List Products and Versions.
Add an author
authorCreate adds an author to a version.
curl https://api.interlynk.io/lynkapi \
-H "Authorization: Bearer $INTERLYNK_SECURITY_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"query": "mutation AddAuthor($sbomId: Uuid!, $name: String!, $email: String, $phone: String) { authorCreate(input: { sbomId: $sbomId, name: $name, email: $email, phone: $phone }) { author { id name email phone } errors } }",
"variables": {
"sbomId": "4e423fe0-d089-4025-b1e4-8fe9608138d6",
"name": "Jane Doe",
"email": "jane@example.com"
}
}'{
"data": {
"authorCreate": {
"author": {
"id": "b1c2d3e4-0000-0000-0000-000000000001",
"name": "Jane Doe",
"email": "jane@example.com",
"phone": null
},
"errors": []
}
}
}sbomId
Uuid
Yes. The version to add the author to.
name
String
Yes.
email
String
No.
phone
String
No.
Save the returned author.id. You need it to update or delete the author.
List the authors on a version
Update an author
authorUpdate changes an existing author. Pass the authorId and only the fields you want to change.
Delete an author
Suppliers
A version also has suppliers. The mutations work the same way as authors:
sbomSupplierCreate
Add a supplier to a version.
sbomSupplierUpdate
Change an existing supplier.
sbomSupplierDelete
Remove a supplier.
To set a supplier on an individual component instead of the whole SBOM, see Edit a Component.
Set the data license
The data license is the license that governs the SBOM document itself, not the software it describes. In SPDX this is the dataLicense field (it defaults to CC0-1.0). In the dashboard it shows on the version as the Data License.
This is a property of the whole version, so you set it with sbomUpdate, not componentUpdate. sbomUpdate takes the version ID as id and a licenses object holding an SPDX expression in licensesExp:
Errors
Mutation failures come back in the errors list rather than as an HTTP error:
Sbom not found means the sbomId is wrong or the token cannot access it. See Errors.
Last updated