Marketing API
Assets
Retrieve Asset
path parameters id the id of the asset to retrieve require "uri" require "net/http" url = uri("https //api tamio com/v2/assets/retrieve/6e2fa1c1 35c1 416c 9b5c ea277f6ae390") https = net http new(url host, url port) https use ssl = true request = net http get new(url) request\["accept"] = "application/json" request\["authorization"] = "bearer your token here" response = https request(request) puts response read body var myheaders = new headers(); myheaders append("accept", "application/json"); // replace your token here with your developer key myheaders append("authorization", "bearer your token here"); var requestoptions = { method 'get', headers myheaders }; fetch("https //api tamio com/v2/assets/retrieve/6e2fa1c1 35c1 416c 9b5c ea277f6ae390", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));curl location request get 'https //api tamio com/v2/assets/retrieve/6e2fa1c1 35c1 416c 9b5c ea277f6ae390' \\ \ header 'accept application/json' \\ \ header 'authorization bearer your token here'{ "status" 200, "asset" { "filename" "awesome image png", "filesize" 51401, "extension" "png", "status" "active", "version" null, "updated at" 1669250582, "created at" 1669216610, "alt text" null, "type" "image", "thumbnails" \[], "id" "635b53fe 6d43 499a 9678 de4bd7501f5f", "object" "asset", "folder" "0be87b96 2439 4ed9 8fe9 565301dc1d96", "number of children" 0, "number of downloads" 0 } }