Pickaxe Learn

API Reference

Page

Endpoints for custom coded pages and page-to-portal navigation links.


Related In Learn

Portals

Create branded, multi-agent hubs where users can access your agents in one place.

Open Learn

Page endpoints manage custom coded pages in the current workspace studio.

These endpoints only support custom-code pages. They do not create or expose regular/default pages.

Endpoints

GET /studio/page/list

List custom coded pages in the current workspace studio.

  • Full URL: https://api.pickaxe.co/v1/studio/page/list

Request Fields

This endpoint does not define request body fields.

Examples

curl -X GET https://api.pickaxe.co/v1/studio/page/list \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN"

Response Shape

{
  "success": true,
  "data": [
    {
      "pageId": "page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68",
      "title": "Landing Page",
      "path": "landing-page",
      "image": "",
      "pageType": "custom-code",
      "customHtml": "<style>...</style><main>...</main>",
      "headerScript": "",
      "footerScript": "",
      "createdAt": "2026-04-28T16:20:00.000000",
      "updatedAt": "2026-04-28T16:20:00.000000"
    }
  ]
}

POST /studio/page/create

Create a custom coded page. Create never overwrites an existing page.

  • Full URL: https://api.pickaxe.co/v1/studio/page/create

Request Fields

  • pageType ("custom-code", required): Must be exactly custom-code.
  • title (string, optional): Page title. Defaults to "Custom Code Page".
  • path (string, optional): Page path. Defaults to page_#.
  • customHtml (string, optional): HTML/CSS/JavaScript markup for the page. Defaults to "".
  • image (string, optional): Must be omitted or empty. Non-empty images are rejected for custom coded pages.

Notes

  • Unsupported fields are rejected.
  • Any pageType other than custom-code is rejected.
  • If another page in the same studio already has the same path, the API returns 409 page_path_conflict.
  • Creating a page does not add it to portal navigation. Link it separately with POST /studio/page/{pageId}/portal-links.

Examples

curl -X POST https://api.pickaxe.co/v1/studio/page/create \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{
  "pageType": "custom-code",
  "title": "Landing Page",
  "path": "landing-page",
  "customHtml": "<style>main{padding:48px}</style><main><h1>Landing Page</h1></main>"
}'

Response Shape

{
  "success": true,
  "data": {
    "pageId": "page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68",
    "title": "Landing Page",
    "path": "landing-page",
    "image": "",
    "pageType": "custom-code",
    "customHtml": "<style>main{padding:48px}</style><main><h1>Landing Page</h1></main>",
    "sections": [],
    "views": 0,
    "visitors": 0,
    "headerScript": "",
    "footerScript": "",
    "createdAt": "2026-04-28T16:20:00.000000",
    "updatedAt": "2026-04-28T16:20:00.000000"
  }
}

GET /studio/page/{pageId}

Fetch one custom coded page.

  • Full URL: https://api.pickaxe.co/v1/studio/page/{pageId}

Request Fields

  • pageId (string, required): The page ID in the path.

Notes

  • Regular/default pages return 404 page_not_found.

Examples

curl -X GET https://api.pickaxe.co/v1/studio/page/page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68 \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN"

PATCH /studio/page/{pageId}

Update a custom coded page.

  • Full URL: https://api.pickaxe.co/v1/studio/page/{pageId}

Request Fields

  • pageId (string, required): The page ID in the path.
  • title (string, optional): Updated page title.
  • path (string, optional): Updated page path.
  • pageType ("custom-code", optional): Must remain custom-code when supplied.
  • customHtml (string, optional): Replacement custom page markup.
  • headerScript (string, optional): Header script stored on the page.
  • footerScript (string, optional): Footer script stored on the page.
  • image (string, optional): Must be omitted or empty. Non-empty images are rejected.

Notes

  • Unsupported fields are rejected.
  • pageType cannot change away from custom-code.
  • Path conflicts return 409 page_path_conflict.
  • Updating title, path, or HTML does not add the page to portal navigation.

Examples

curl -X PATCH https://api.pickaxe.co/v1/studio/page/page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68 \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{
  "pageType": "custom-code",
  "title": "Updated Landing Page",
  "path": "updated-landing",
  "customHtml": "<main><h1>Updated</h1></main>"
}'

POST /studio/page/{pageId}/portal-links

Link a custom coded page into one or more portal navigation menus.

  • Full URL: https://api.pickaxe.co/v1/studio/page/{pageId}/portal-links

Request Fields

  • pageId (string, required): The page ID in the path.
  • portalIds (string[], optional): Portal IDs to link this page into.
  • portalId (string, optional): Single-portal shorthand. Use this instead of portalIds when linking one portal.

Notes

  • This endpoint is intentionally separate from page creation, matching the Studio UI behavior.
  • Unknown portal IDs return 404 portal_not_found.
  • If the page is already linked to every requested portal, the API returns 409 page_link_exists.
  • Portal nav items are added with pageType: "custom-code" and a blank display icon.

Examples

curl -X POST https://api.pickaxe.co/v1/studio/page/page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68/portal-links \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{
  "portalId": "portal-123"
}'

Response Shape

{
  "success": true,
  "data": {
    "pageId": "page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68",
    "portalIds": ["portal-123"],
    "portals": [
      {
        "portalId": "portal-123",
        "name": "Landing Portal",
        "path": "landing",
        "items": [
          {
            "type": "page",
            "id": "page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68",
            "pageType": "custom-code",
            "displayName": "Landing Page",
            "displayIcon": "",
            "order": 0
          }
        ]
      }
    ]
  }
}

CLI Notes

If you are using the Pickaxe CLI, use a plain HTML file as the page artifact:

pickaxe page create landing-page
pickaxe page create --file pages/landing-page.html
pickaxe page create --file pages/landing-page.html --link portal-123
pickaxe page update page-4f74e3c7-23cf-43df-a7b4-f2f5be6a3e68 --file pages/landing-page.html