Migrating to the new API
This page relates to major changes in Microreact released in 2020
Summary of breaking changes
New API
Old API
Converting old API request payload
curl \
--header "Content-type: application/json; charset=UTF-8" \
--request POST \
--data '{ "name": "hayu110x2c0smcm", "data": "https://raw.githubusercontent.com/microreact/data/main/data.csv" }' \
https://microreact.org/api/schema/convert{
"datasets": {
"dataset-1": {
"file": "data-file-1",
"idFieldName": "id"
}
},
"files": {
"data-file-1": {
"id": "data-file-1",
"format": "text/csv",
"name": "data.csv",
"url": "https://raw.githubusercontent.com/microreact/data/main/data.csv"
}
},
"maps": {
"map-1": {
"title": "Map",
"latitudeField": "__latitude",
"longitudeField": "__longitude"
}
},
"meta": {
"name": "hayu110x2c0smcm"
},
"tables": {
"table-1": {
"dataset": "dataset-1",
"title": "Metadata",
"columns": [
{
"field": "id"
},
{
"field": "__latitude"
},
{
"field": "__longitude"
},
{
"field": "country"
},
{
"field": "__year"
},
{
"field": "__month"
},
{
"field": "__day"
}
]
}
},
"timelines": {
"timeline-1": {
"title": "Timeline",
"dataType": "year-month-day",
"yearField": "__year",
"monthField": "__month",
"dayField": "__day"
}
},
"schema": "https://microreact.org/schema/v1.json"
}Last updated