/**
 * Public read-only share links.
 *
 * The app's first anonymous surface. Three routes:
 *
 *   POST /api/repos/:repo/entities/:type/:id/share-link   (AUTHED)  — mint/reuse
 *   GET  /api/share/:token                                (PUBLIC)  — read body
 *   GET  /api/share/:token/asset/:assetId/:filename       (PUBLIC)  — embedded asset
 *
 * Authorization model:
 *  - Mint is write-gated (mirrors revoke). Personal folders ARE publishable by
 *    their owner — the publish right is orthogonal to teammate visibility, and
 *    the single mint caller is already owner-gated. Today read ⟺ write for
 *    shared folders, so write-gating is a no-op now but keeps publish/unpublish
 *    coherent and pre-empts a future read-only role from minting a link it
 *    couldn't revoke.
 *  - The two PUBLIC routes are bypassed in the global auth hook; the opaque
 *    token (looked up in share_links, fail-closed on missing/revoked) IS the
 *    authorization. A revoked token stops resolving for BOTH the body and its
 *    assets immediately.
 *  - The public read returns ONLY { title, entityType, content } — frontmatter
 *    and metadata never cross the boundary (test-enforced). Asset URLs in the
 *    body are rewritten to token-scoped /api/share/:token/asset/... links.
 *  - A public asset must be EMBEDDED in the shared entry and owned by the
 *    entry's repo OR a workspace-wide shared store (same scope as the
 *    artifact-asset token path — font kits/shared images live there), so a
 *    crafted body can't republish another entry's, a private repo's, or an
 *    un-embedded asset.
 */
import type { FastifyInstance } from 'fastify';
import type { WorkspaceManager } from '../../core/workspace-manager.js';
import { AuthService } from '../../services/auth-service.js';
import type { ShareLinkService } from '../../services/share-link-service.js';
export declare function registerShareApiRoutes(fastify: FastifyInstance, workspaceManager: WorkspaceManager, authService: AuthService, shareLinkService: ShareLinkService): Promise<void>;
