List one asset's software inventory and dependency graph
curl --request GET \
--url https://app.trustivan.com/api/v1/assets/{id}/components \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trustivan.com/api/v1/assets/{id}/components"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trustivan.com/api/v1/assets/{id}/components', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/assets/{id}/components"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}List an asset's software inventory and dependencies
The components are cursor-paginated; the edges are NOT. A page of
edges is a subgraph with arbitrary boundaries, and a client
reconstructing a graph from pages renders partial dependency chains as
though they were complete, which is worse than refusing, because it
looks right.
404 when the asset does not exist or is not yours, never 200 with
an empty inventory: “this asset has no packages” and “this asset is not
visible to you” are different facts.
GET
/
assets
/
{id}
/
components
List one asset's software inventory and dependency graph
curl --request GET \
--url https://app.trustivan.com/api/v1/assets/{id}/components \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trustivan.com/api/v1/assets/{id}/components"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trustivan.com/api/v1/assets/{id}/components', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/assets/{id}/components"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}Authorizations
Query Parameters
Response
The asset's components and the edges between them.
The response is of type object.