{
"status": "FOUND",
...
}
{
"status": "ERROR",
...
}
https://api.tildacdn.info/v1/getprojectslist/?publickey=00000000000000000000&secretkey=00000000000000000000
{
"status": "FOUND",
"result": [
{
"id": "0",
"title": "First Project",
"descr": "Some info"
},
{
"id": "1",
"title": "Second Project",
"descr": ""
},
...
]
}
https://api.tildacdn.info/v1/getprojectinfo/?publickey=00000000000000000000&secretkey=00000000000000000000&projectid=0
{
"status": "FOUND",
"result": {
"id": "0",
"title": "Project title",
"descr": "",
"customdomain": "project.com",
"export_csspath": "",
"export_jspath": "",
"export_imgpath": "",
"indexpageid": "0",
"customcsstext": "y",
"favicon": "",
"page404id": "0",
"images": [
{
"from": "",
"to": ""
}
...
]
}
}
https://api.tildacdn.info/v1/getpageslist/?publickey=00000000000000000000&secretkey=00000000000000000000&projectid=0
{
"status": "FOUND",
"result": [
{
"id": "1001",
"projectid": "0",
"title": "Page title first",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-16 14:45:53",
"sort": "80",
"published": "1419702868",
"filename": "page1001.html"
},
{
"id": "1002",
"projectid": "0",
"title": "Page title second",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-17 10:50:00",
"sort": "90",
"published": "1419702277",
"filename": "page1002.html"
},
...
]
}
https://api.tildacdn.info/v1/getpage/?publickey=00000000000000000000&secretkey=00000000000000000000&pageid=1001
{
"status": "FOUND",
"result": {
"id": "1001",
"projectid": "0",
"title": "Page title",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-16 14:45:53",
"sort": "80",
"published": "1419702868",
"html": "some html page code",
"filename": "page1001.html",
"js": [
...
],
"css": [
...
]
}
}
https://api.tildacdn.info/v1/getpagefull/?publickey=00000000000000000000&secretkey=00000000000000000000&pageid=1001
{
"status": "FOUND",
"result": {
"id": "1001",
"projectid": "0",
"title": "Page title",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-16 14:45:53",
"sort": "80",
"published": "1419702868",
"html": "some html page code",
"filename": "page1001.html"
}
}
https://api.tildacdn.info/v1/getpageexport/?publickey=00000000000000000000&secretkey=00000000000000000000&pageid=1001
{
"status": "FOUND",
"result": {
"id": "1001",
"projectid": "0",
"title": "Page title",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-16 14:45:53",
"sort": "80",
"published": "1419702868",
"images": [
{
"from": "",
"to": ""
},
{
"from": "",
"to": ""
},
{
"from": "",
"to": ""
}
],
"js": [
{
"from": "",
"to": "",
"attrs": [
"async"
]
},
{
"from": "",
"to": "",
"attrs": [
"defer"
]
},
{
"from": "",
"to": "",
"attrs": [
"nomodule"
]
}
],
"html": "body page html-code with local links to files",
"filename": "page1001.html"
}
}
https://api.tildacdn.info/v1/getpagefullexport/?publickey=00000000000000000000&secretkey=00000000000000000000&pageid=1001
{
"status": "FOUND",
"result": {
"id": "1001",
"projectid": "0",
"title": "Page title",
"descr": "",
"img": "",
"featureimg": "",
"alias": "",
"date": "2014-05-16 14:45:53",
"sort": "80",
"published": "1419702868",
"images": [
{
"from": "",
"to": ""
},
{
"from": "",
"to": ""
},
{
"from": "",
"to": ""
}
],
"html": "full page html-code with local links to files",
"filename": "page1001.html"
}
}
Si tu proyecto no está muy cargado y no quieres guardar archivos estáticos en tu servidor, utiliza la petición getpage que devuelve el código HTML del cuerpo. Las imágenes se cargarán desde el servidor Tilda . Lo principal es recordar añadir archivos JS y CSS a tu plantilla. La lista de estos archivos se devuelve en las variables js y css de la respuesta a la petición.
$result = file_get_contents('https://api.tildacdn.info/v1/getprojectinfo/?publickey=00000000000000000000&secretkey=00000000000000000000&projectid=0');
$proyecto = json_decode($resultado, true);
print_r($proyecto);