Approve an inventory asset.
curl --request POST \
--url https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve"
headers = {"X-API-Key": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve', 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://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"asset": {
"asset_family": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"first_seen_at": "2023-11-07T05:31:56Z",
"last_seen_at": "2023-11-07T05:31:56Z",
"metadata": {},
"normalized_value": "<string>",
"updated_at": "2023-11-07T05:31:56Z",
"uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>",
"activity": "<string>",
"approved_at": "2023-11-07T05:31:56Z",
"approved_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"approved_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"archived_at": "2023-11-07T05:31:56Z",
"asn": 2147483648,
"asset_type": "<string>",
"brand_favicon_count": 1,
"brand_linked_asset_count": 1,
"brand_main_website_url": "<string>",
"brand_term_count": 1,
"certificate_issuer": "<string>",
"certificate_not_after": "2023-11-07T05:31:56Z",
"certificate_not_before": "2023-11-07T05:31:56Z",
"certificate_sha256": "<string>",
"certificate_subject": "<string>",
"cname_records": [
"<string>"
],
"contact_email": "jsmith@example.com",
"contact_name": "<string>",
"contact_type": "<string>",
"created_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"discovery_channel": "<string>",
"discovery_provider": "<string>",
"display_name": "<string>",
"dns_a_records": [
"<string>"
],
"dns_aaaa_records": [
"<string>"
],
"dns_name": "<string>",
"domain_status": "<string>",
"favicon_sha256": "<string>",
"final_url": "<string>",
"host": "<string>",
"ip": "<string>",
"ip_addresses": [
"<string>"
],
"ip_block": "<string>",
"last_observed_at": "2023-11-07T05:31:56Z",
"name_servers": [
"<string>"
],
"os_family": "<string>",
"owner_group_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"owner_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"page_sha256": "<string>",
"parent_domain": "<string>",
"primary_source_name": "<string>",
"primary_source_ref": "<string>",
"provider": "<string>",
"registered_at": "2023-11-07T05:31:56Z",
"registrar": "<string>",
"removed_at": "2023-11-07T05:31:56Z",
"removed_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"removed_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"root_domain": "<string>",
"screenshot_sha256": "<string>",
"title": "<string>",
"url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}Inventory
Approve an inventory asset.
Accepts a candidate discovered asset by setting status to approved. Requires esi.inventory.manage or project manager access.
POST
https://api.infrawatch.com/api/v1
/
projects
/
{project_uuid}
/
esi
/
inventory
/
assets
/
{asset_uuid}
/
approve
Approve an inventory asset.
curl --request POST \
--url https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve"
headers = {"X-API-Key": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve', 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://api.infrawatch.com/api/v1/projects/{project_uuid}/esi/inventory/assets/{asset_uuid}/approve"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"asset": {
"asset_family": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"first_seen_at": "2023-11-07T05:31:56Z",
"last_seen_at": "2023-11-07T05:31:56Z",
"metadata": {},
"normalized_value": "<string>",
"updated_at": "2023-11-07T05:31:56Z",
"uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>",
"activity": "<string>",
"approved_at": "2023-11-07T05:31:56Z",
"approved_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"approved_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"archived_at": "2023-11-07T05:31:56Z",
"asn": 2147483648,
"asset_type": "<string>",
"brand_favicon_count": 1,
"brand_linked_asset_count": 1,
"brand_main_website_url": "<string>",
"brand_term_count": 1,
"certificate_issuer": "<string>",
"certificate_not_after": "2023-11-07T05:31:56Z",
"certificate_not_before": "2023-11-07T05:31:56Z",
"certificate_sha256": "<string>",
"certificate_subject": "<string>",
"cname_records": [
"<string>"
],
"contact_email": "jsmith@example.com",
"contact_name": "<string>",
"contact_type": "<string>",
"created_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"discovery_channel": "<string>",
"discovery_provider": "<string>",
"display_name": "<string>",
"dns_a_records": [
"<string>"
],
"dns_aaaa_records": [
"<string>"
],
"dns_name": "<string>",
"domain_status": "<string>",
"favicon_sha256": "<string>",
"final_url": "<string>",
"host": "<string>",
"ip": "<string>",
"ip_addresses": [
"<string>"
],
"ip_block": "<string>",
"last_observed_at": "2023-11-07T05:31:56Z",
"name_servers": [
"<string>"
],
"os_family": "<string>",
"owner_group_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"owner_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"page_sha256": "<string>",
"parent_domain": "<string>",
"primary_source_name": "<string>",
"primary_source_ref": "<string>",
"provider": "<string>",
"registered_at": "2023-11-07T05:31:56Z",
"registrar": "<string>",
"removed_at": "2023-11-07T05:31:56Z",
"removed_by_api_key_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"removed_by_membership_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"root_domain": "<string>",
"screenshot_sha256": "<string>",
"title": "<string>",
"url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"field_errors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}⌘I