Skip to content

AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents

355 B
Raw Blame
import * as z from 'zod/mini'
import { Nullable } from './base-model'

export type Cursor = string | null

export type SeekPage<T> = {
    next: Cursor
    previous: Cursor
    data: T[]
}

export const SeekPage = (t: z.ZodMiniType): z.ZodMiniType => z.object({
    data: z.array(t),
    next: Nullable(z.string()),
    previous: Nullable(z.string()),
})