For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Sign in
DocsAPI ReferenceChangelog
DocsAPI ReferenceChangelog
    • Overview
    • Authentication
  • REST
      • POSTCreate Page
      • GETList Pages
      • GETGet Page
      • PATCHUpdate Page
      • DELDelete Page
Sign in
LogoLogo
RESTPages

List Pages

GET
https://api.makeswift.com/v6/pages
GET
/v6/pages
$curl -G https://api.makeswift.com/v6/pages \
> -H "x-api-key: <apiKey>" \
> -H "Content-Type: application/json" \
> -d siteId=siteId
1{
2 "object": "list",
3 "data": [
4 {
5 "object": "page",
6 "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
7 "pathname": "furniture",
8 "canonicalUrl": "https://www.example.com/furniture",
9 "title": "Modern Furniture Collection",
10 "description": "Explore our latest modern furniture designs for your home and office.",
11 "socialImageUrl": "https://www.example.com/images/furniture-social.jpg",
12 "sitemapPriority": 0.5,
13 "sitemapFrequency": "always",
14 "createdAt": "2024-01-15T09:30:00Z",
15 "updatedAt": "2024-01-15T09:30:00Z",
16 "publishedAt": "2024-01-15T09:30:00Z",
17 "isOnline": true,
18 "excludedFromSearchEngines": true,
19 "localizations": [
20 {
21 "pathname": "meubles",
22 "locale": "fr-FR",
23 "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7"
24 }
25 ],
26 "locale": "en-US"
27 }
28 ],
29 "hasMore": true
30}
Returns a list of pages for a site.
Was this page helpful?
Previous

Create Page

Next

Get Page

Built with

Authentication

x-api-keystring
API key authentication. Accepts either: - App API key (e.g. sk_eczMHVBY9fV6GYFhvs53qcnxq7yptlXL3ABKOZtn6dQ) - Site API key (UUID format, e.g. 550e8400-e29b-41d4-a716-446655440000)

Query parameters

siteIdstringRequiredformat: "uuid"
The site ID to list pages from.
limitdoubleOptional1-100Defaults to 20
The maximum number of pages to return.
startingAfterstringOptionalformat: "uuid"
The pagination cursor. This is used to indicate what ID to list from.
pathPrefixstringOptionalDefaults to /
The filter that limits pages to only those with a pathname that begins with this value.
sortByenumOptionalDefaults to path
The field to sort pages by.
Allowed values:
sortDirectionenumOptionalDefaults to asc
The sort direction.
Allowed values:
includeOfflineenumOptionalDefaults to false
The flag that determines whether to include offline pages in the results.
Allowed values:
localestringOptional
The locale code to filter pages by.
versionRefenumOptionalDefaults to ref:draft
The version reference to retrieve pages from. Defaults to `ref:draft` if not provided. Supported formats: - `ref:draft` - Draft/working version - `ref:live` - Live/published version
Allowed values:

Response

objectenum
Allowed values:
datalist of objects
hasMoreboolean
The flag that indicates whether there are more pages available.

Errors

403
Forbidden Error

API key authentication. Accepts either:

  • App API key (e.g. sk_eczMHVBY9fV6GYFhvs53qcnxq7yptlXL3ABKOZtn6dQ)
  • Site API key (UUID format, e.g. 550e8400-e29b-41d4-a716-446655440000)

The version reference to retrieve pages from. Defaults to ref:draft if not provided.

Supported formats:

  • ref:draft - Draft/working version
  • ref:live - Live/published version