公共 API 参考(@saas/contracts + @core/saas-kit + apps/api 对外接口)
    Preparing search index...

    Post 仓储端口(领域层自持·依赖倒置)。

    Deliberately exposes NO tenant/workspace parameter: the active tenant (and optional workspace selector) is resolved inside the adapter from the trusted request context (AsyncLocalStorage), so no caller can supply an arbitrary/foreign id. This is the single choke-point for the compound (tenant, workspace) isolation (global-tenancy §9.3 / FR-5, D2) — handlers never scatter where organizationId/workspaceId by hand.

    分层对齐后端口流动充血领域实体 Post(非裸记录·见 architecture「Entity Doctrine」): create 收业务态 Post.draft(...)(适配器补租户/id/时间戳落库)、find/list 返回复原后的完整 领域实体;到传输投影 PostReadModel 的映射归 application,领域实体不越界进 api/。

    interface PostRepository {
        create(post: Post): Promise<Post>;
        findById(id: string): Promise<Post | null>;
        list(request: CursorPageRequest): Promise<CursorPage<Post>>;
    }
    Index