curl --request POST \
--url https://apiweb.mile.app/api/v3/report \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"hubIds": [
"64d9932e2beb9037735ff022"
],
"fields": [
"title",
"assignee",
"status",
"doneTime"
],
"defaultFilters": {
"datePreset": "monthly",
"status": [
"DONE"
],
"assignee": []
}
}
'import requests
url = "https://apiweb.mile.app/api/v3/report"
payload = {
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"hubIds": ["64d9932e2beb9037735ff022"],
"fields": ["title", "assignee", "status", "doneTime"],
"defaultFilters": {
"datePreset": "monthly",
"status": ["DONE"],
"assignee": []
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Monthly delivery report',
type: 'string',
flowId: '64e5b1c2d3e4f5a6b7c8d9e0',
hubIds: ['64d9932e2beb9037735ff022'],
fields: ['title', 'assignee', 'status', 'doneTime'],
defaultFilters: {datePreset: 'monthly', status: ['DONE'], assignee: []}
})
};
fetch('https://apiweb.mile.app/api/v3/report', 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://apiweb.mile.app/api/v3/report",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Monthly delivery report',
'type' => 'string',
'flowId' => '64e5b1c2d3e4f5a6b7c8d9e0',
'hubIds' => [
'64d9932e2beb9037735ff022'
],
'fields' => [
'title',
'assignee',
'status',
'doneTime'
],
'defaultFilters' => [
'datePreset' => 'monthly',
'status' => [
'DONE'
],
'assignee' => [
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://apiweb.mile.app/api/v3/report"
payload := strings.NewReader("{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://apiweb.mile.app/api/v3/report")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apiweb.mile.app/api/v3/report")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"code": 201,
"message": "Report successfully created.",
"data": {
"_id": "66f1a2b3c4d5e6f7a8b9c0d1",
"organizationId": "64d99303be0ad015c461c932",
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"fields": [
"title",
"assignee",
"status",
"doneTime"
],
"hubIds": [
"64d9932e2beb9037735ff022"
],
"defaultFilters": {
"datePreset": "monthly",
"status": [
"DONE"
],
"assignee": []
},
"createdBy": "[email protected]",
"updatedBy": "[email protected]",
"updatedTime": "2026-10-01T03:15:20.000000Z",
"createdTime": "2026-10-01T03:15:20.000000Z"
}
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Internal server error, please contact [email protected]."
}Create report
Creates a saved report configuration.
The source (flowId or dataTypeId), every hub and every field are checked against your organization; an unknown one returns 400.
Requires permission add/report.
curl --request POST \
--url https://apiweb.mile.app/api/v3/report \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"hubIds": [
"64d9932e2beb9037735ff022"
],
"fields": [
"title",
"assignee",
"status",
"doneTime"
],
"defaultFilters": {
"datePreset": "monthly",
"status": [
"DONE"
],
"assignee": []
}
}
'import requests
url = "https://apiweb.mile.app/api/v3/report"
payload = {
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"hubIds": ["64d9932e2beb9037735ff022"],
"fields": ["title", "assignee", "status", "doneTime"],
"defaultFilters": {
"datePreset": "monthly",
"status": ["DONE"],
"assignee": []
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Monthly delivery report',
type: 'string',
flowId: '64e5b1c2d3e4f5a6b7c8d9e0',
hubIds: ['64d9932e2beb9037735ff022'],
fields: ['title', 'assignee', 'status', 'doneTime'],
defaultFilters: {datePreset: 'monthly', status: ['DONE'], assignee: []}
})
};
fetch('https://apiweb.mile.app/api/v3/report', 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://apiweb.mile.app/api/v3/report",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Monthly delivery report',
'type' => 'string',
'flowId' => '64e5b1c2d3e4f5a6b7c8d9e0',
'hubIds' => [
'64d9932e2beb9037735ff022'
],
'fields' => [
'title',
'assignee',
'status',
'doneTime'
],
'defaultFilters' => [
'datePreset' => 'monthly',
'status' => [
'DONE'
],
'assignee' => [
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://apiweb.mile.app/api/v3/report"
payload := strings.NewReader("{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://apiweb.mile.app/api/v3/report")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apiweb.mile.app/api/v3/report")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Monthly delivery report\",\n \"type\": \"string\",\n \"flowId\": \"64e5b1c2d3e4f5a6b7c8d9e0\",\n \"hubIds\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"fields\": [\n \"title\",\n \"assignee\",\n \"status\",\n \"doneTime\"\n ],\n \"defaultFilters\": {\n \"datePreset\": \"monthly\",\n \"status\": [\n \"DONE\"\n ],\n \"assignee\": []\n }\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"code": 201,
"message": "Report successfully created.",
"data": {
"_id": "66f1a2b3c4d5e6f7a8b9c0d1",
"organizationId": "64d99303be0ad015c461c932",
"name": "Monthly delivery report",
"type": "string",
"flowId": "64e5b1c2d3e4f5a6b7c8d9e0",
"fields": [
"title",
"assignee",
"status",
"doneTime"
],
"hubIds": [
"64d9932e2beb9037735ff022"
],
"defaultFilters": {
"datePreset": "monthly",
"status": [
"DONE"
],
"assignee": []
},
"createdBy": "[email protected]",
"updatedBy": "[email protected]",
"updatedTime": "2026-10-01T03:15:20.000000Z",
"createdTime": "2026-10-01T03:15:20.000000Z"
}
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Internal server error, please contact [email protected]."
}Authorizations
Use a valid Bearer token to authenticate.
Body
Name of the report. Maximum 255 characters.
Example: Monthly delivery report
255Columns of the report, at least one, no duplicates. Each value must be a component id of the chosen flow (task report) or a field id of the chosen data type (data report).
Example: ["title", "assignee", "status"]
The input type of the component (e.g., string, number, date, etc.)
Flow whose tasks the report reads. Required when type is task. Must be a 24-character id of a flow in your organization.
Example: 64e5b1c2d3e4f5a6b7c8d9e0
Data type whose records the report reads. Required when type is data. Must be a 24-character id of a data type in your organization.
Example: 64f0a1b2c3d4e5f6a7b8c9d0
Hubs the report covers. Required for task reports and for data types that are not common data; ignored (saved as empty) for common data types. Every id must be a distinct hub of your organization.
Example: ["64d9932e2beb9037735ff022"]
Starting filters when the report is run. Task reports only; ignored for data reports. When omitted, a task report gets {"datePreset": "monthly", "status": [], "assignee": []}.
Show child attributes
Show child attributes