Download a completed run's result as a file
curl --request GET \
--url https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}import requests
url = "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Runs
GET /v1/runs/{run_id}/artifacts/{fmt}
Download a finished run as CSV or GeoJSON. Rendered on read, no export step.
GET
/
v1
/
runs
/
{run_id}
/
artifacts
/
{fmt}
Download a completed run's result as a file
curl --request GET \
--url https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}import requests
url = "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mireye.com/v1/runs/{run_id}/artifacts/{fmt}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Renders a completed run’s stored result as a file you can download.
- There is no export job and no staging bucket.
- The artifact is rendered on read from the run itself.
fmt | Shape |
|---|---|
csv | One row per location, spreadsheet-ready values |
geojson | A FeatureCollection, one Point feature per location |
# Straight into a spreadsheet
curl -s "https://api.mireye.com/v1/runs/$RUN_ID/artifacts/csv" \
-H "Authorization: Bearer $MIREYE_API_TOKEN" \
-o screen.csv
# Straight onto a map
curl -s "https://api.mireye.com/v1/runs/$RUN_ID/artifacts/geojson" \
-H "Authorization: Bearer $MIREYE_API_TOKEN" \
-o screen.geojson
- The artifact exists exactly as long as the run does: 30 days.
- Rendering one is free, as is eligible public Fetch.
- Need it for longer than 30 days? Download it.
GET /v1/runs/{run_id} instead, or re-fetch the
shortlist. A spreadsheet is a working artifact, not an audit trail.