Skip to content
On this page

Pages

Store pages

Startpage

Returns startpage

GET: /headless_api/pages/startpage

{
    "data": {
        "meta_title": "meta title",
        "meta_description": "meta description",
        "template_components": [
            // Array of template components
        ]
    }
} 

Page

Returns a single page

GET: /headless_api/pages/{page_slug}

{
    "data": {
        "name": "Contact us",
        "slug": "contact-us",
        "description": "page content",
        "meta_title": "meta title",
        "meta_description": "meta description",
        "template_components": [
            // Array of template components
        ]
    }
} 

Pages

Returns paginated pages

GET: /headless_api/pages

Filters

GET: ?page=1

GETTypeValues
pageint-

Result

{
    "data": [
        {
            "name": "Contact us",
            "slug": "contact-us",
            "meta_title": "meta title",
            "meta_description": "meta description"
        }
    ],
    "links": {
        "first": "https://yourdomain.com/headless_api/pages?page=1",
        "last": "https://yourdomain.com/headless_api/pages?page=3",
        "prev": null,
        "next": "https://yourdomain.com/headless_api/pages?page=2"
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 3,
        "links": [
            {
                "url": null,
                "label": "« Föregående",
                "active": false
            },
            {
                "url": "https://yourdomain.com/headless_api/pages?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": "https://yourdomain.com/headless_api/pages?page=2",
                "label": "2",
                "active": false
            },
            {
                "url": "https://yourdomain.com/headless_api/pages?page=3",
                "label": "3",
                "active": false
            },
            {
                "url": "https://yourdomain.com/headless_api/pages?page=2",
                "label": "Nästa »",
                "active": false
            }
        ],
        "path": "https://yourdomain.com/headless_api/pages",
        "per_page": 25,
        "to": 1,
        "total": 1
    }
}