List pages
GET
/pages/list.json
GET
/pages/list.json
$storeden = new Storeden\Storeden($config);
$pages_list = $storeden->get('/pages/list.json');
[
{
"id": "54e43f0816f46a467c7b23c6",
"url_path": "test-page-1",
"title": "Test Page 1"
},
{
"id": "555d9f9e16f46acf1bdd486a",
"url_path": "test-shipping-page",
"title": "[TEST] Shipping Page"
},
...
]
GET
/pages/page.json?id={page-id}
$storeden = new Storeden\Storeden($config);
$page = $storeden->get('/pages/page.json?id=54e43f0816f46a467c7b23c6');
{
"title": "Test page 1",
"url_path": "test-page-1",
"content": "HTML Content",
"parentPage": null,
"id": "54e43f0816f46a467c7b23c6"
}
POST
/pages/page.json
title required (string) | page title |
content required (string) | You page content ( HTML supported ) |
$storeden = new Storeden\Storeden($config);
$page = array();
$page['title'] = 'Test page 1';
$page['content'] = 'HTML content';
$page_response = $storeden->post('/pages/page.json', $page);
{
"id": "54e43f0816f46a467c7b23c6",
}
DELETE
/pages/page.json
id required (StoredenID) | Unique identifier for page |
$storeden = new Storeden\Storeden($config);
$page = array();
$page['id'] = '54e43f0816f46a467c7b23c6';
$page_response = $storeden->delete('/pages/page.json', $page);
{
"ok": "1",
"err": null
}