Upload an SBOM for a component version
POST
/v1/upload-sbom
curl --request POST \ --url https://api.quaze.io/v1/upload-sbom \ --header 'Authorization: REPLACE_KEY_VALUE' \ --header 'content-type: application/json' \ --data '{"productId":"string","componentId":"string","version":"string","fileName":"string","artifactName":"string","buildReference":"string"}'import requests
url = "https://api.quaze.io/v1/upload-sbom"
payload = { "productId": "string", "componentId": "string", "version": "string", "fileName": "string", "artifactName": "string", "buildReference": "string"}headers = { "Authorization": "REPLACE_KEY_VALUE", "content-type": "application/json"}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)package main
import ( "fmt" "strings" "net/http" "io/ioutil")
func main() {
url := "https://api.quaze.io/v1/upload-sbom"
payload := strings.NewReader("{\"productId\":\"string\",\"componentId\":\"string\",\"version\":\"string\",\"fileName\":\"string\",\"artifactName\":\"string\",\"buildReference\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "REPLACE_KEY_VALUE") req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}const fetch = require('node-fetch');
let url = 'https://api.quaze.io/v1/upload-sbom';
let options = { method: 'POST', headers: {Authorization: 'REPLACE_KEY_VALUE', 'content-type': 'application/json'}, body: '{"productId":"string","componentId":"string","version":"string","fileName":"string","artifactName":"string","buildReference":"string"}'};
fetch(url, options) .then(res => res.json()) .then(json => console.log(json)) .catch(err => console.error('error:' + err));Authorizations
Section titled “Authorizations ”Request Body required
Section titled “Request Body required ” Media type application/json
object
productId
required
string
componentId
required
string
version
required
string
fileName
required
string
artifactName
string
buildReference
string
Example generated
{ "productId": "example", "componentId": "example", "version": "example", "fileName": "example", "artifactName": "example", "buildReference": "example"}Responses
Section titled “ Responses ”Upload URL generated
Media type application/json
object
uploadId
string
presignedUrl
string
componentId
string
componentVersionId
string
Example generated
{ "uploadId": "example", "presignedUrl": "example", "componentId": "example", "componentVersionId": "example"}Invalid request
Media type application/json
object
error
required
string
Example generated
{ "error": "example"}Missing or invalid authentication
Media type application/json
object
error
required
string
Example generated
{ "error": "example"}Resource not found
Media type application/json
object
error
required
string
Example generated
{ "error": "example"}