What I'm doing is trying to submit a URL to scan to urlscan.io. I can do a search but have issues with submissions, particularly correctly sending the right headers/encoded data.
from their site on how to submit a url:
curl -X POST "https://urlscan.io/api/v1/scan/" \ -H "Content-Type: application/json" \ -H "API-Key: $apikey" \ -d "{\"url\": \"$url\", \"public\": \"on\"}"
This works to satisfy the Api key header requirement but
req.Header.Add("API-Key", authtoken)
This is my attempt that fails
data := make(url.Values)
data.Add("url", myurltoscan)
The URL property I have struggled with tremendously.
This is my error: "message": "Missing URL properties", "description": "The URL supplied was not OK, please specify it including the protocol, host and path (e.g. http://example.com/bar)", "status": 400