• Preparing search index...
  • The search index is not available
Genkit JS API reference
  • Genkit JS API reference
  • @genkit-ai/next
  • appRoute

Function appRoute

  • appRoute<
        C extends ActionContext = ActionContext,
        I extends z.ZodType<any, any, any, I> = z.ZodTypeAny,
        O extends z.ZodType<any, any, any, O> = z.ZodTypeAny,
        S extends z.ZodType<any, any, any, S> = z.ZodTypeAny,
    >(
        action: Action<I, O, S, ActionRunOptions<S>>,
        opts?: { contextProvider?: ContextProvider<C, I> },
    ): (req: NextRequest) => Promise<NextResponse<unknown>>
  • Type Parameters

    • C extends ActionContext = ActionContext
    • I extends z.ZodType<any, any, any, I> = z.ZodTypeAny
    • O extends z.ZodType<any, any, any, O> = z.ZodTypeAny
    • S extends z.ZodType<any, any, any, S> = z.ZodTypeAny

    Parameters

    • action: Action<I, O, S, ActionRunOptions<S>>
    • Optionalopts: { contextProvider?: ContextProvider<C, I> }

    Returns (req: NextRequest) => Promise<NextResponse<unknown>>

    • Defined in plugins/next/src/index.ts:51

Settings

Member Visibility
Genkit JS API reference
  • Loading...

Generated using TypeDoc with typedoc-github-theme