Custom Pages
In Directify, custom pages are standalone pages that appear in your directory’s navigation (navbar, footer, sidebar) or as unlisted pages accessible via URL. They’re ideal for static content like About, Terms, comparison pages, and programmatic SEO content. Pages support Markdown content and full SEO metadata.List Pages
Retrieve all custom pages for a directory, ordered by sort order.directory_id(integer, required): The ID of the directory
Get Single Page
Retrieve a specific page by ID.directory_id(integer, required): The ID of the directorypage_id(integer, required): The ID of the page
Create Page
Create a new custom page. UsesupdateOrCreate based on slug to prevent duplicates.
directory_id(integer, required): The ID of the directory
title(string, required): The page title (max 255 characters)slug(string, optional): URL-safe slug (lowercase letters, numbers, hyphens only). Auto-generated from title if not providedmarkdown(string, optional): Page content in Markdown formatplacement(string, optional): Where the page link appears in navigation. One of:navbar- Appears in the top navigationfooter- Appears in the footersidebar- Appears in the sidebarunlisted- Not shown in navigation, accessible only via direct URL (default)
is_published(boolean, optional): Whether the page is published (default: true)is_external(boolean, optional): Whether this is a link to an external URL (default: false)external_url(string, optional): External URL ifis_externalis true (must be a valid URL)new_tab(boolean, optional): Whether external links open in a new tab (default: false)order(integer, optional): Sort order for navigation placement (default: 0)seo(object, optional): SEO metadata object:title(string, optional): SEO title (max 255 characters)description(string, optional): Meta description (max 500 characters)
Update Page
Update an existing page. Only pass fields you want to change. If the title changes and no slug is provided, a new slug is auto-generated.directory_id(integer, required): The ID of the directorypage_id(integer, required): The ID of the page
Toggle Page Status
Toggle a page between published and unpublished.directory_id(integer, required): The ID of the directorypage_id(integer, required): The ID of the page
is_published status.
Delete Page
Delete a custom page from the directory.directory_id(integer, required): The ID of the directorypage_id(integer, required): The ID of the page
