get
https://www.virustotal.com/api/v3/analyses//dom_url
This endpoint returns the short-lived signed URL of the rendered DOM captured during a URL Analysis, wrapped in a JSON response:
{
"data": "https://vtdom.commondatastorage.googleapis.com/9fda61....."
}Use this endpoint instead of GET /analyses/{id}/dom when you need the link itself rather than the HTML bytes.
Note that the signed URL is valid for 5 minutes. If the link expires, you must request the endpoint again to generate a new one. The underlying asset is an HTML file.
Examples
Get the DOM for Analysis ID "u-109b1fe44b83bfdeaeee0d238e041915b6d71f6ce4b91f8f9ad79eac3ac7d27f-6d2fb381".
import requests
id = "u-109b1fe44b83bfdeaeee0d238e041915b6d71f6ce4b91f8f9ad79eac3ac7d27f-6d2fb381"
url = f"https://www.virustotal.com/api/v3/analyses/{id}/dom_url"
headers = {
"accept": "application/json",
"x-apikey": <api-key>
}
response = requests.get(url, headers=headers)