@farm.js/core 0.1.0-beta.10 → 0.1.0-beta.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/after.d.mts +25 -0
- package/dist/after.d.ts +25 -0
- package/dist/agent-runtime.d.mts +94 -0
- package/dist/agent-runtime.d.ts +94 -0
- package/dist/api/route-manager.d.mts +66 -0
- package/dist/api/route-manager.d.ts +66 -0
- package/dist/api/runtime.d.mts +3 -0
- package/dist/api/runtime.d.ts +3 -0
- package/dist/api.d.mts +48 -0
- package/dist/api.d.ts +48 -0
- package/dist/app-BNE2FoZ4.d.mts +302 -0
- package/dist/app-DRGUmJ3s.d.ts +302 -0
- package/dist/app-markdown.d.mts +22 -0
- package/dist/app-markdown.d.ts +22 -0
- package/dist/cache.d.mts +192 -0
- package/dist/cache.d.ts +192 -0
- package/dist/{chunk-DTOWEQRV.mjs → chunk-4677KXB7.mjs} +2 -2
- package/dist/{chunk-3QDB3IA6.mjs → chunk-5EVQFRL2.mjs} +2 -2
- package/dist/{chunk-3QDB3IA6.mjs.map → chunk-5EVQFRL2.mjs.map} +1 -1
- package/dist/{chunk-E2AI2CW7.mjs → chunk-77BOAQHI.mjs} +4 -3
- package/dist/chunk-77BOAQHI.mjs.map +1 -0
- package/dist/client-BT1mFQas.d.mts +447 -0
- package/dist/client-Nn0q4eO4.d.ts +447 -0
- package/dist/client-cache-CIlyBlmx.d.ts +6 -0
- package/dist/client-cache-D-EZ7XVW.d.mts +6 -0
- package/dist/client-plugins-Bc5jHcNr.d.ts +1927 -0
- package/dist/client-plugins-jsk-ZLzJ.d.mts +1927 -0
- package/dist/client-plugins.d.mts +22 -0
- package/dist/client-plugins.d.ts +22 -0
- package/dist/client.d.mts +447 -0
- package/dist/client.d.ts +447 -0
- package/dist/config.d.mts +29 -0
- package/dist/config.d.ts +29 -0
- package/dist/cron.d.mts +78 -0
- package/dist/cron.d.ts +78 -0
- package/dist/deferred.d.mts +42 -0
- package/dist/deferred.d.ts +42 -0
- package/dist/deployment.d.mts +34 -0
- package/dist/deployment.d.ts +34 -0
- package/dist/docs.d.mts +69 -0
- package/dist/docs.d.ts +69 -0
- package/dist/env-types.d.mts +12 -0
- package/dist/env-types.d.ts +12 -0
- package/dist/env.d.mts +45 -0
- package/dist/env.d.ts +45 -0
- package/dist/environment/vite.d.mts +22 -0
- package/dist/environment/vite.d.ts +22 -0
- package/dist/environment.d.mts +18 -0
- package/dist/environment.d.ts +18 -0
- package/dist/font.d.mts +70 -0
- package/dist/font.d.ts +70 -0
- package/dist/headers.d.mts +22 -0
- package/dist/headers.d.ts +22 -0
- package/dist/i18n/client.d.mts +32 -0
- package/dist/i18n/client.d.ts +32 -0
- package/dist/i18n/index.d.mts +20 -0
- package/dist/i18n/index.d.ts +20 -0
- package/dist/i18n/server.d.mts +30 -0
- package/dist/i18n/server.d.ts +30 -0
- package/dist/image/server.d.mts +37 -0
- package/dist/image/server.d.ts +37 -0
- package/dist/image/sharp.d.mts +7 -0
- package/dist/image/sharp.d.ts +7 -0
- package/dist/image-config-Duob7wER.d.mts +50 -0
- package/dist/image-config-Duob7wER.d.ts +50 -0
- package/dist/image.d.mts +39 -0
- package/dist/image.d.ts +39 -0
- package/dist/index.cjs +3 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +455 -0
- package/dist/index.d.ts +455 -0
- package/dist/index.mjs +3 -3
- package/dist/integration-api-CHT2OKAf.d.mts +93 -0
- package/dist/integration-api-CHT2OKAf.d.ts +93 -0
- package/dist/integrations.d.mts +22 -0
- package/dist/integrations.d.ts +22 -0
- package/dist/internal/build-runtime.cjs +3 -2
- package/dist/internal/build-runtime.cjs.map +1 -1
- package/dist/internal/build-runtime.d.mts +39 -0
- package/dist/internal/build-runtime.d.ts +39 -0
- package/dist/internal/build-runtime.mjs +3 -3
- package/dist/internal/client-runtime.d.mts +2 -0
- package/dist/internal/client-runtime.d.ts +2 -0
- package/dist/internal/config-runtime.d.mts +39 -0
- package/dist/internal/config-runtime.d.ts +39 -0
- package/dist/internal/production-node-env.d.mts +12 -0
- package/dist/internal/production-node-env.d.ts +12 -0
- package/dist/internal/production-runtime.d.mts +41 -0
- package/dist/internal/production-runtime.d.ts +41 -0
- package/dist/markdown.d.mts +60 -0
- package/dist/markdown.d.ts +60 -0
- package/dist/metadata-7ffpT3jr.d.mts +22 -0
- package/dist/metadata-JHn-8eht.d.ts +22 -0
- package/dist/middleware.d.mts +164 -0
- package/dist/middleware.d.ts +164 -0
- package/dist/navigation-errors-Dvwpzaer.d.mts +13 -0
- package/dist/navigation-errors-Dvwpzaer.d.ts +13 -0
- package/dist/navigation.d.mts +14 -0
- package/dist/navigation.d.ts +14 -0
- package/dist/observability.d.mts +335 -0
- package/dist/observability.d.ts +335 -0
- package/dist/params-BALtrRim.d.ts +15 -0
- package/dist/params-ry-lxqmy.d.mts +15 -0
- package/dist/plugin-BJDf43dc.d.mts +165 -0
- package/dist/plugin-BJDf43dc.d.ts +165 -0
- package/dist/plugin.cjs +2 -1
- package/dist/plugin.cjs.map +1 -1
- package/dist/plugin.d.mts +22 -0
- package/dist/plugin.d.ts +22 -0
- package/dist/plugin.mjs +2 -2
- package/dist/production-runtime-9KG7GuvW.d.ts +79 -0
- package/dist/production-runtime-B-fweKts.d.mts +79 -0
- package/dist/production-runtime-C_B79w2P.d.mts +28 -0
- package/dist/production-runtime-DDEM1D2q.d.ts +28 -0
- package/dist/query/client.d.mts +61 -0
- package/dist/query/client.d.ts +61 -0
- package/dist/query/index.d.mts +90 -0
- package/dist/query/index.d.ts +90 -0
- package/dist/query/parsers.d.mts +25 -0
- package/dist/query/parsers.d.ts +25 -0
- package/dist/query/server.d.mts +55 -0
- package/dist/query/server.d.ts +55 -0
- package/dist/request-Dsq4kGW0.d.mts +6 -0
- package/dist/request-udtobOLv.d.ts +6 -0
- package/dist/request.d.mts +2 -0
- package/dist/request.d.ts +2 -0
- package/dist/resolver-DJqjLMg_.d.mts +14 -0
- package/dist/resolver-IH4RmPEl.d.ts +14 -0
- package/dist/route-runtime-DoOHzCAD.d.mts +38 -0
- package/dist/route-runtime-DoOHzCAD.d.ts +38 -0
- package/dist/router.d.mts +36 -0
- package/dist/router.d.ts +36 -0
- package/dist/routes.d.mts +224 -0
- package/dist/routes.d.ts +224 -0
- package/dist/runtime-9nQjVM7X.d.mts +206 -0
- package/dist/runtime-Cxpq6xZN.d.mts +27 -0
- package/dist/runtime-DgeS2skB.d.ts +206 -0
- package/dist/runtime-bv63eUiO.d.ts +27 -0
- package/dist/server-action-security.d.mts +43 -0
- package/dist/server-action-security.d.ts +43 -0
- package/dist/server-fn-client.d.mts +32 -0
- package/dist/server-fn-client.d.ts +32 -0
- package/dist/server-fn.d.mts +93 -0
- package/dist/server-fn.d.ts +93 -0
- package/dist/server-plugins.d.mts +55 -0
- package/dist/server-plugins.d.ts +55 -0
- package/dist/server-query-client.d.mts +50 -0
- package/dist/server-query-client.d.ts +50 -0
- package/dist/server-query.d.mts +36 -0
- package/dist/server-query.d.ts +36 -0
- package/dist/server.cjs +3 -2
- package/dist/server.cjs.map +1 -1
- package/dist/server.d.mts +48 -0
- package/dist/server.d.ts +48 -0
- package/dist/server.mjs +2 -2
- package/dist/storage.d.mts +52 -0
- package/dist/storage.d.ts +52 -0
- package/dist/testing.d.mts +101 -0
- package/dist/testing.d.ts +101 -0
- package/dist/transport-BmbGTXA5.d.mts +49 -0
- package/dist/transport-BmbGTXA5.d.ts +49 -0
- package/dist/types-BMxWr97v.d.mts +81 -0
- package/dist/types-BMxWr97v.d.ts +81 -0
- package/dist/types-C9N-nk5R.d.mts +53 -0
- package/dist/types-C9N-nk5R.d.ts +53 -0
- package/dist/types-D1A6-XvH.d.mts +73 -0
- package/dist/types-D1A6-XvH.d.ts +73 -0
- package/dist/utils-CA0z0c-2.d.ts +23 -0
- package/dist/utils-mYVkSOt2.d.mts +23 -0
- package/dist/version.cjs +1 -1
- package/dist/version.cjs.map +1 -1
- package/dist/version.d.mts +3 -0
- package/dist/version.d.ts +3 -0
- package/dist/version.mjs +1 -1
- package/dist/vite.cjs +3 -2
- package/dist/vite.cjs.map +1 -1
- package/dist/vite.d.mts +22 -0
- package/dist/vite.d.ts +22 -0
- package/dist/vite.mjs +2 -2
- package/dist/workflows.d.mts +110 -0
- package/dist/workflows.d.ts +110 -0
- package/package.json +1 -1
- package/dist/chunk-E2AI2CW7.mjs.map +0 -1
- /package/dist/{chunk-DTOWEQRV.mjs.map → chunk-4677KXB7.mjs.map} +0 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,455 @@
|
|
|
1
|
+
import { F as FarmConfig, a1 as OpenAPIConfig, C as ResolvedFarmLayer, D as FarmSourceRoot, p as RouteModule, z as SSGCollectionResult, y as SSGPage } from './client-plugins-Bc5jHcNr.js';
|
|
2
|
+
export { aO as APIHandlerLifecyclePayload, aK as APIRouteDiscoveredPayload, B as BuildOptions, aR as BundleLifecyclePayload, U as BundleResultPayload, ct as CookieJar, cu as CookieOptions, ci as CreateIntegrationOrmOptions, cY as DEFAULT_FARM_DEVTOOLS_SHORTCUT, b_ as DefinedIntegration, o as ErrorBoundary, aP as ErrorLifecyclePayload, E as ErrorProps, c_ as FARM_DEVTOOLS_LAUNCH_PARAM, cZ as FARM_DEVTOOLS_PATH, bh as FARM_INTEGRATION_INTERNAL_DISPATCH_CONTEXT_KEY, h as FarmAppContext, ad as FarmAuthConfig, ae as FarmAuthDatabaseConfig, af as FarmAuthEmailAndPasswordConfig, ag as FarmAuthSessionConfig, ah as FarmAuthUserConfig, g as FarmContextFactory, e as FarmContextFactoryInput, a$ as FarmDeployConfig, b1 as FarmDeployTarget, c$ as FarmDevtoolsConfig, d0 as FarmDevtoolsUserConfig, W as FarmIntegration, b2 as FarmIntegrationCategory, bl as FarmIntegrationConfigContext, bm as FarmIntegrationConfigDefinition, bn as FarmIntegrationConfigInput, bs as FarmIntegrationData, bC as FarmIntegrationDocumentNavigation, bU as FarmIntegrationEndpointValue, bV as FarmIntegrationEndpoints, bX as FarmIntegrationEndpointsFactory, bW as FarmIntegrationEndpointsFactoryContext, bt as FarmIntegrationHandlerContext, be as FarmIntegrationInputSchema, bq as FarmIntegrationLifecycleContext, br as FarmIntegrationLifecycleHook, bo as FarmIntegrationLifecycleLogLevel, bp as FarmIntegrationLifecycleLogger, bN as FarmIntegrationLogEvent, bM as FarmIntegrationLogPhase, bO as FarmIntegrationLogger, bz as FarmIntegrationMiddleware, cd as FarmIntegrationOrmClient, cc as FarmIntegrationOrmSchema, bB as FarmIntegrationProvider, bA as FarmIntegrationProviderProps, bg as FarmIntegrationRequestContextStore, bw as FarmIntegrationRoute, bk as FarmIntegrationRouteArgs, bi as FarmIntegrationRouteDb, bR as FarmIntegrationRouteFactory, bv as FarmIntegrationRouteHook, bu as FarmIntegrationRouteHookContext, b9 as FarmIntegrationRouteInput, bf as FarmIntegrationRouteInputSchemas, b7 as FarmIntegrationRouteInputSource, b6 as FarmIntegrationRouteMethod, by as FarmIntegrationRouteMiddleware, b4 as FarmIntegrationRouteParamValue, b5 as FarmIntegrationRouteParams, bj as FarmIntegrationRouteStorageArgs, bT as FarmIntegrationRoutesFactory, bS as FarmIntegrationRoutesFactoryContext, bK as FarmIntegrationSchema, bG as FarmIntegrationSchemaConstraint, bF as FarmIntegrationSchemaField, bD as FarmIntegrationSchemaFieldType, bH as FarmIntegrationSchemaModel, bI as FarmIntegrationSchemaModelExtension, bJ as FarmIntegrationSchemaModelOverride, bE as FarmIntegrationSchemaReference, b3 as FarmIntegrationSlot, bd as FarmIntegrationStandardValidationResult, bb as FarmIntegrationValidationErrorLike, ba as FarmIntegrationValidationIssue, b8 as FarmIntegrationValidationPathSegment, bc as FarmIntegrationValidationResult, bP as FarmIntegrationsUserConfig, ac as FarmLayerConfig, A as FarmLayerEntry, cN as FarmMarkdownPageModuleInput, cM as FarmMarkdownPageSource, cJ as FarmMdxComponent, cK as FarmMdxComponents, _ as FarmMdxResolvedConfig, cL as FarmMdxUserConfig, Y as FarmMiddlewareConfig, a as FarmMigrationCommand, b as FarmMigrationsConfig, c as FarmMigrationsUserConfig, V as FarmPlugin, aE as FarmPluginBuildHooks, aG as FarmPluginClientConfig, aj as FarmPluginContext, aF as FarmPluginDevHooks, aB as FarmPluginDiscoveredRoute, aD as FarmPluginRenderHooks, an as FarmPluginRouteRuntimePayload, aC as FarmPluginRouterHooks, at as FarmPluginRuntimeAfterEvent, aq as FarmPluginRuntimeBaseEvent, as as FarmPluginRuntimeBeforeEvent, aw as FarmPluginRuntimeCloseEvent, ar as FarmPluginRuntimeContextEvent, au as FarmPluginRuntimeErrorEvent, ax as FarmPluginRuntimeHooks, am as FarmPluginRuntimeKind, az as FarmPluginRuntimeRequestHandler, ay as FarmPluginRuntimeRequestOptions, aA as FarmPluginRuntimeSession, av as FarmPluginRuntimeStartEvent, ao as FarmPluginSetupContext, ap as FarmPluginStateContext, t as FarmRequest, ak as FarmRequestPluginContext, al as FarmRequestStore, u as FarmResponse, cD as FarmRouteRule, cC as FarmRouteRuleCors, cB as FarmRouteRuleRedirect, cA as FarmRouteRuleRenderMode, cE as FarmRouteRules, bx as FarmTypedIntegrationRoute, T as FarmUserConfig, aQ as HMRUpdatePayload, aW as HeaderConfig, aZ as I18nConfig, aY as ImageConfig, ch as InferFarmIntegrationOrmClient, ce as InferFarmIntegrationOrmField, cf as InferFarmIntegrationOrmFields, cg as InferFarmIntegrationOrmSchema, cm as IntegrationOrmModelNames, m as Layout, r as LayoutModule, k as LayoutProps, n as Loading, L as LoadingProps, s as Metadata, cs as MiddlewareChain, a_ as MiddlewareConfig, cn as MiddlewareContext, aJ as MiddlewareDiscoveredPayload, co as MiddlewareFunction, M as MiddlewareProps, cz as MiddlewareResult, cr as MiddlewareStore, cy as NextFunction, aS as NitroBuildLifecyclePayload, N as NitroPreset, l as Page, i as PageProps, j as PagePropsWithMiddleware, x as ParsedRoute, P as PluginContextProps, a3 as PluginManager, ai as PluginRequestContext, cv as RateLimitConfig, cx as RateLimitStatus, cw as RateLimitStorage, X as ReadonlyMiddlewareStore, aV as RedirectConfig, aN as RenderLifecyclePayload, cp as RequestMiddleware, cq as RequestMiddlewareContext, a0 as ResolvedFarmAuthConfig, aU as ResolvedFarmConfig, b0 as ResolvedFarmDeployConfig, $ as ResolvedFarmDevtoolsConfig, R as ResolvedFarmMigrationsConfig, aX as RewriteConfig, aH as RouteDiscoveredPayload, aL as RouteMatchPayload, aM as RouteMatchResultPayload, w as RouteSegment, aI as RoutesGeneratedPayload, v as ServerAction, aT as ShutdownPayload, q as StaticPathParams, S as StaticPathPrimitive, cU as createFarmMarkdownRouteModule, cV as createFarmMarkdownRouteModuleFromFile, cX as createFarmMarkdownSourceResponse, cj as createIntegrationOrm, bY as createIntegrationRoute, cT as createMarkdownMetadata, b$ as defineIntegration, bL as defineIntegrationSchema, a2 as definePlugin, cb as dispatchIntegrationRequest, cl as farmIntegrationSchemaToOrmSchema, aa as getDeployTargetForPreset, K as getFarmAppDirectories, bQ as getFarmIntegrationPluginServerRuntime, O as getFarmLayerAliases, J as getFarmSourceRoots, c3 as getIntegrationDocumentNavigationMatchers, c2 as getIntegrationProviders, c4 as getIntegrationSchemas, ab as getPresetForDeployTarget, ca as getRegisteredIntegrationAPIManifest, c5 as getRegisteredIntegrationRuntime, c7 as getRegisteredIntegrationSchemas, c6 as getRegisteredIntegrations, bZ as integrationRoute, c0 as isFarmIntegration, cP as isFarmMarkdownPageFile, a5 as loadConfig, cW as loadFarmMdxComponents, c8 as matchIntegrationRoute, c9 as matchRegisteredIntegrationRoute, a9 as normalizeDeployTarget, cQ as normalizeFarmMarkdownRoutePath, cF as normalizeRouteRules, cR as parseMarkdownFrontmatter, a4 as resolveConfig, a6 as resolveDeployConfig, a8 as resolveDeployOutputPath, d1 as resolveFarmDevtoolsConfig, I as resolveFarmLayers, ck as resolveIntegrationOrmRuntimeClient, c1 as resolveIntegrationPlugins, cO as resolveMdxConfig, a7 as resolveMigrationsConfig, cH as routeRulesToHeaders, cI as routeRulesToNitroRouteRules, cG as routeRulesToRedirects, cS as titleFromMarkdown } from './client-plugins-Bc5jHcNr.js';
|
|
3
|
+
export { f as fileExists, g as globFiles, l as logger, m as matchRoute, p as parseRoutePath, a as parseSearchParams, r as resolveAppPath, s as segmentsToPattern, t as toViteModuleId } from './utils-CA0z0c-2.js';
|
|
4
|
+
export { createFarmStorage, createStorageClient, databaseStorage, defineStorageClient, disposeStorage, driverStorage, getStorage, initStorage, libsqlStorage, localStorage, memoryStorage, mongodbStorage, mysql2Storage, mysqlStorage, netlifyBlobsStorage, pgStorage, pgliteStorage, planetscaleStorage, postgresStorage, redisStorage, resolveStorageRuntimeClient, s3Storage, sqliteStorage, upstashStorage, vercelBlobStorage, vercelKVStorage } from './storage.js';
|
|
5
|
+
export { F as FarmIntegrationAPI, e as FarmIntegrationAPIBodyFormat, f as FarmIntegrationAPIMethod, a as FarmIntegrationAPIOperation, g as FarmIntegrationAPIResponseFormat, h as FarmIntegrationRouteOperationCarrier, I as InferIntegrationAPIFromRoutes, b as api, d as defineIntegrationAPI, c as defineIntegrationAPIOperation, i as endpoint } from './integration-api-CHT2OKAf.js';
|
|
6
|
+
export { c as createFarmApp } from './app-DRGUmJ3s.js';
|
|
7
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
8
|
+
import { ReactNode } from 'react';
|
|
9
|
+
export { ComponentType, FC, PropsWithChildren, ReactElement, ReactNode } from 'react';
|
|
10
|
+
export { g as getCurrentRequest } from './request-udtobOLv.js';
|
|
11
|
+
import { ViteDevServer } from 'vite';
|
|
12
|
+
export { createCompressionPlugin, createEnvPlugin, createHeadersPlugin, createLoggerPlugin, createRedirectsPlugin, createRewritesPlugin } from './server-plugins.js';
|
|
13
|
+
export { A as APIRouteMatch, c as APIRouteParamValue, b as APIRouteParams, q as AnyEndpointMiddleware, D as DELETE, e as EndpointErrorContracts, E as EndpointErrorDefinition, d as EndpointErrorDefinitions, f as EndpointFail, g as EndpointFailure, v as EndpointHandler, s as EndpointInvalidationContext, r as EndpointInvalidationTarget, t as EndpointInvalidations, p as EndpointMiddleware, l as EndpointMiddlewareContext, o as EndpointMiddlewareResult, u as EndpointOptions, j as EndpointParamValue, k as EndpointParams, G as GET, H as HEAD, I as InferEndpointMiddlewareContext, O as OPTIONS, y as PATCH, P as POST, x as PUT, T as TypedEndpoint, w as createEndpoint, i as invokeAPIRouteEndpoint, h as isEndpointFailure, a as isWebResponse, m as matchAPIRoute, n as normalizeRouteResponse } from './runtime-DgeS2skB.js';
|
|
14
|
+
export { APIRoute, APIRouteManager, APIRouteManagerOptions, API_ROUTE_METHODS } from './api/route-manager.js';
|
|
15
|
+
export { r as APIClient, h as APIClientError, b as APIClientOptions, i as APIClientSystemError, c as APIClientWithoutIntegrationsOptions, g as APIResult, A as APIRouteRefMetadata, C as CacheKey, l as CacheOptions, k as CachePolicy, p as ClientOptions, a as FARM_API_ROUTE_META_SYMBOL, F as FARM_API_ROUTE_REF_SYMBOL, X as InferIntegrationOperationBody, Y as InferIntegrationOperationQuery, Z as InferIntegrationOperationResponse, T as IntegrationAPI, L as IntegrationClient, M as IntegrationClientAliases, V as IntegrationClientData, y as IntegrationClientError, P as IntegrationClientOptions, Q as IntegrationClientRequestOptions, N as IntegrationClientRoot, U as IntegrationClients, W as IntegrationOperationResult, _ as IntegrationServerClient, $ as IntegrationServerClientAliases, a0 as IntegrationServerClientOptions, a1 as IntegrationServerClientRequestOptions, a2 as IntegrationServerClientRoot, a3 as IntegrationServerRequestLike, n as InvalidateOptions, I as InvalidateTarget, o as OptimisticOptions, O as OptimisticUpdate, R as RequestEvent, j as ResponseEvent, m as RetryOptions, q as RouteAPIClient, s as ServerAPIClient, S as ServerAPIClientOptions, d as ServerAPIClientWithoutIntegrationsOptions, f as StatusEvent, e as StatusPhase, t as createAPIClient, z as createIntegrationApi, x as createIntegrationClient, B as createIntegrationClients, E as createIntegrationServerClient, D as createIntegrations, w as createServerAPIClient, v as getAPIRouteRefMetadata, G as getIntegrationAPIManifest, H as integrationClients, J as integrationsClient, K as integrationsServer, u as isAPIRouteRef } from './client-Nn0q4eO4.js';
|
|
16
|
+
export { F as FarmAPIStream, c as FarmStreamResponse, a as MultipartField, M as MultipartSchema, b as MultipartValues, T as TypedFormData, e as isFarmAPIStream, d as isJSONStreamResponse, i as isMultipartSchema, j as jsonStream, m as multipart, r as readJSONStream, t as toFormData } from './transport-BmbGTXA5.js';
|
|
17
|
+
export { ApiRoute, FarmApiPluginOptions, farmApiPlugin } from './api.js';
|
|
18
|
+
export { Parser, asArrayOf, asBoolean, asFloat, asInteger, asIsoDate, asIsoDateTime, asJson, asString, createParser, inferParserType } from './query/parsers.js';
|
|
19
|
+
export { R as RouteParamsInput, l as loadRouteParams, p as parseRouteParams } from './params-BALtrRim.js';
|
|
20
|
+
export { FarmQueryStateContext, LayoutPropsSafe, PagePropsSafe, QueryStateConfig, QueryStateProvider } from './query/index.js';
|
|
21
|
+
export { FarmMiddlewarePluginOptions, MiddlewareManager, createContext, farmMiddlewarePlugin, getFromMiddleware, getRateLimitStatus, hasMiddlewareData, middleware, unwrapMiddleware } from './middleware.js';
|
|
22
|
+
export { _ as _runWithMiddlewareContext, b as _runWithMiddlewareData, a as applyProductionMiddlewareHeaders, c as createProductionMiddlewareRunner, g as getMiddlewareContext, d as getMiddlewareData, e as getMiddlewareValue } from './production-runtime-9KG7GuvW.js';
|
|
23
|
+
export { FarmRouter, FarmRouterActiveOptions, FarmRouterBuildOptions, FarmRouterMatch, FarmRouterParams, FarmRouterPathParam, FarmRouterPathParams, FarmRouterPrimitiveParam, FarmRouterQueryValue, FarmRouterRoute, FarmRouterRouteInput, buildFarmRoutePath, createFarmRouter, isFarmRouteActive, matchFarmRoute } from './router.js';
|
|
24
|
+
export { c as FarmRouteMaxDuration, b as FarmRouteRegions, e as FarmRouteRenderingMode, a as FarmRouteRuntime, F as FarmRouteRuntimeConfig, d as FarmRouteRuntimeEntryKind, g as FarmRouteRuntimeManifest, f as FarmRouteRuntimeManifestEntry, R as ResolvedFarmRouteRuntimeConfig, j as createFarmRouteRuntimeKey, l as farmRouteRuleMatches, i as getFarmRouteRuntimeConfig, h as hasFarmRouteRuntimeControls, m as mergeFarmRouteRuntimeConfigs, n as normalizeFarmRouteRuntimeConfig, k as resolveFarmRouteRuleRuntimeConfig, r as resolveFarmRouteRuntimeConfig } from './route-runtime-DoOHzCAD.js';
|
|
25
|
+
export { CreateRouteOptions, InferProgrammaticRouteData, InferProgrammaticRouteSchema, ProgrammaticApiRoute, ProgrammaticApiRouteOptions, ProgrammaticLayoutRoute, ProgrammaticPageRoute, ProgrammaticRedirectRoute, ProgrammaticRouteBuilder, ProgrammaticRouteComponentProps, ProgrammaticRouteContext, ProgrammaticRouteDataCacheContext, ProgrammaticRouteDataCacheKeys, ProgrammaticRouteDataContext, ProgrammaticRouteDataHooks, ProgrammaticRouteDataStaleTime, ProgrammaticRouteDefinition, ProgrammaticRouteErrorComponentProps, ProgrammaticRouteFactory, ProgrammaticRouteGuard, ProgrammaticRouteGuardContext, ProgrammaticRouteManifest, ProgrammaticRouteMaybePromise, ProgrammaticRouteMethod, ProgrammaticRouteParamsFallback, ProgrammaticRoutePendingComponentProps, ProgrammaticRoutePrimitive, ProgrammaticRouteRenderMode, ProgrammaticRouteSchema, ProgrammaticRouteSearchClientOptions, ProgrammaticRouteSearchConfig, ProgrammaticRouteSearchFallback, ProgrammaticRouteSearchOptions, ProgrammaticStaticPath, ProgrammaticStaticPathParams, ProgrammaticStaticPaths, createLayoutModuleFromProgrammaticLayout, createProgrammaticRouteModuleId, createRoute, createRouteModuleFromProgrammaticPage, defineRoutes, getProgrammaticRouteManifest, isProgrammaticRouteManifest, isProgrammaticRoutesFileName, layout, page, parseProgrammaticRouteModuleId, parseProgrammaticRoutePath, routesBuilder, scanProgrammaticPagePaths } from './routes.js';
|
|
26
|
+
export { FarmDocsAPIHandler, FarmDocsAPIOptions, FarmDocsAPIRouteHandlers, FarmDocsCloudIntegration, FarmDocsCloudRouteOptions, FarmDocsCloudServer, FarmDocsHandlerOptions, FarmDocsPage, LoadedFarmDocsPage, createDocsAPI, createFarmDocsAPIHandler, createFarmDocsHandler, discoverFarmDocsPages, getFarmDocsDocumentNavigationMatchers, getFarmDocsRouteTypeEntries, isFarmDocsAPIRequest, isFarmDocsRequest, loadFarmDocsPage, resolveFarmDocsContentDir } from './docs.js';
|
|
27
|
+
export { b as FarmDocsConfigInput, c as FarmDocsNavigationConfig, F as FarmDocsResolvedConfig, d as FarmDocsSidebarItem, a as FarmDocsUserConfig } from './types-C9N-nk5R.js';
|
|
28
|
+
export { ApplyMarkdownNegotiationHeadersOptions, CreateMarkdownMirrorResponseOptions, FarmMarkdownMirrorTarget, FarmMarkdownResolvedConfig, FarmMarkdownResolvedRoute, FarmMarkdownRouteInput, FarmMarkdownUserConfig, ResolveMarkdownMirrorTargetOptions, applyMarkdownNegotiationHeaders, createMarkdownMirrorResponse, htmlToMarkdown, requestAcceptsMarkdown, resolveMarkdownConfig, resolveMarkdownMirrorTarget } from './markdown.js';
|
|
29
|
+
export { FarmAPIEvent, FarmBuildEvent, FarmCacheEvent, FarmErrorEvent, FarmEvent, FarmEventBase, FarmEventHandler, FarmEventInput, FarmEventLevel, FarmEventType, FarmIntegrationEvent, FarmMiddlewareEvent, FarmObservabilityUserConfig, FarmPPREvent, FarmPluginEvent, FarmRenderEvent, FarmResolvedObservabilityConfig, FarmRouteEvent, FarmServerEvent, FarmStorageEvent, configureFarmObservability, emitFarmEvent, normalizeFarmObservabilityConfig, onFarmEvent, resetFarmObservability } from './observability.js';
|
|
30
|
+
export { DEFAULT_FARM_WORKFLOW_DIRS, DEFAULT_FARM_WORKFLOW_ROUTE, DEFAULT_FARM_WORKFLOW_SECRET_ENV, FarmCronDefinition, FarmDiscoveredWorkflow, FarmWorkflowDefinition, FarmWorkflowHTTPHandlerOptions, FarmWorkflowLogger, FarmWorkflowRunContext, FarmWorkflowSchedule, FarmWorkflowsResolvedConfig, FarmWorkflowsUserConfig, PreparedFarmWorkflows, applyFarmWorkflowVercelCrons, createFarmWorkflowRequestHandler, createFarmWorkflowVercelCrons, defineCron, defineTask, defineWorkflow, discoverFarmWorkflows, prepareFarmWorkflowsForNitro, resolveWorkflowsConfig, runFarmWorkflowModule } from './workflows.js';
|
|
31
|
+
export { DEFAULT_FARM_CRON_SECRET_ENV, FARM_CRON_MANIFEST, FarmCronCloudflareConfig, FarmCronJob, FarmCronJobConfig, FarmCronResolvedConfig, FarmCronRouteOptions, FarmCronSchedule, FarmCronUserConfig, PreparedFarmCron, applyFarmCronVercelCrons, createFarmCronCloudflareConfig, createFarmCronCloudflareTriggers, createFarmCronManifest, createFarmCronVercelCrons, cronRoute, isCronRequestAuthorized, mergeScheduledTasks, prepareFarmCronForNitro, resolveCronConfig } from './cron.js';
|
|
32
|
+
export { EnvParser, EnvSchema, EnvShape, FarmEnvConfig, FarmEnvTypes, FarmPublicEnv, FarmServerEnv, FarmTypedEnv, InferEnv, InferEnvParser, InferEnvShape, ResolvedFarmEnv, env, getEnv, getPublicEnv, getResolvedEnv, publicEnv, resolveEnv, serverEnv, setEnv } from './env.js';
|
|
33
|
+
export { GenerateEnvTypesOptions, createEnvTypeDeclarations, generateEnvTypes } from './env-types.js';
|
|
34
|
+
export { FarmEnvironment, FarmEnvironmentError, FarmIsomorphicFnOptions, createClientOnlyFn, createIsomorphicFn, createServerOnlyFn } from './environment.js';
|
|
35
|
+
export { FarmFont, FarmFontDisplay, FarmFontOptions, FarmFontSource, LocalFontOptions, RemoteFontOptions, RemoteFontSource, localFont, remoteFont } from './font.js';
|
|
36
|
+
import { R as ResolvedFarmI18nConfig } from './types-BMxWr97v.js';
|
|
37
|
+
export { g as FarmI18nCookieConfig, h as FarmI18nDetectionSignal, i as FarmI18nDirection, j as FarmI18nRouting, k as FarmI18nUserConfig } from './types-BMxWr97v.js';
|
|
38
|
+
export { AnyServerFnMiddleware, FARM_SERVER_FN_SYMBOL, InferServerFnSchemaInput, InferServerFnSchemaOutput, ServerFn, ServerFnContext, ServerFnFormInput, ServerFnHandler, ServerFnInvalidationContext, ServerFnInvalidations, ServerFnMiddleware, ServerFnMiddlewareContext, ServerFnMiddlewareContinuation, ServerFnMiddlewareHandler, ServerFnMiddlewareHandlerContext, ServerFnMiddlewareNext, ServerFnMiddlewareOptions, ServerFnOptions, ServerFnOutputOptions, ServerFnSchema, _parseServerFnSchema, createServerFn, createServerMiddleware } from './server-fn.js';
|
|
39
|
+
export { ServerFnActionStatus, ServerFnOptimisticContext, ServerFnSubmit, UseServerFnOptions, UseServerFnReturn, useServerFn } from './server-fn-client.js';
|
|
40
|
+
export { FARM_SERVER_QUERY_SYMBOL, ServerQuery, ServerQueryKey, ServerQueryOptions, ServerQueryOutputOptions, ServerQueryStaleTime, createServerQuery } from './server-query.js';
|
|
41
|
+
export { FarmServerQueryActionInvocation, ServerQueryFetchOptions, UseServerQueryOptions, UseServerQueryResult, beginFarmServerQueryAction, completeFarmServerQueryAction, fetchServerQuery, prefetchServerQuery, useServerQuery } from './server-query-client.js';
|
|
42
|
+
export { DEFAULT_SERVER_ACTION_BODY_SIZE_LIMIT, FarmServerActionsConfig, PreparedServerActionRequest, ResolvedFarmServerActionsConfig, SanitizedServerActionError, ServerActionRequestError, ServerActionRequestKind, createServerActionRequestErrorResponse, getServerActionExecutionContext, getServerActionInvalidations, getServerActionSignal, prepareServerActionRequest, resolveServerActionsConfig, runWithServerActionRequest, sanitizeServerActionError, validateServerActionRequest } from './server-action-security.js';
|
|
43
|
+
export { FARM_DEPLOYMENT_COOKIE, FARM_DEPLOYMENT_ID_HEADER, FARM_DEPLOYMENT_MISMATCH_CODE, FARM_DEPLOYMENT_MISMATCH_HEADER, FARM_DEPLOYMENT_MISMATCH_STATUS, FarmDeploymentMismatch, FarmDeploymentMismatchError, FarmDeploymentResponseOptions, createFarmDeploymentCookie, createFarmDeploymentMismatchError, createFarmDeploymentMismatchResponse, createFarmDeploymentRequestHeaders, getFarmDeploymentMismatch, getFarmRequestDeploymentId, getFarmResponseDeploymentId, isFarmDeploymentMismatchResponse, normalizeFarmDeploymentId, withFarmDeploymentResponse } from './deployment.js';
|
|
44
|
+
export { F as FarmImageConfig, a as FarmImageFormat, b as FarmImageLocalPattern, c as FarmImageProvider, d as FarmImageRemotePattern, R as ResolvedFarmImageConfig } from './image-config-Duob7wER.js';
|
|
45
|
+
export { build } from './internal/build-runtime.js';
|
|
46
|
+
export { AnyMutationTarget, DefaultRouteHref, DefaultRoutePath, DefaultRoutePattern, ExternalHref, FarmNavigateOptions, FarmNavigationBlocker, FarmNavigationBlockerContext, FarmNavigationListener, FarmNavigationLocation, FarmNavigationState, FarmViewTransitionMode, FetcherFormDataContext, FetcherFormProps, FetcherState, FetcherSubmit, FetcherSubmitAsync, InferMutationData, InferMutationError, InferMutationVariables, Link, LinkDefaultRoute, LinkProps, MutationAsync, MutationOptimisticContext, MutationStatus, MutationTrigger, PrefetchBehavior, RouteHref, RouteOptionalParamValue, RouteParamValue, RouteParams, SPARouter, Store, StoreApi, StoreFields, StoreKeyListener, StoreKeysListener, StoreListener, StorePatch, StoreState, StoreValueUpdater, UseBlockerOptions, UseBlockerReturn, UseFetcherOptions, UseFetcherReturn, UseMutationOptions, UseMutationReturn, UseRouterOptions, createStore, getRouter, navigateTo, prefetch, pushState, readPageState, replaceState, useBlocker, useFetcher, useMutation, useNavigation, usePageState, useRouter, useScrollRestoration } from './client.js';
|
|
47
|
+
export { F as FarmChunkRecoveryOptions, i as installChunkErrorRecovery, a as isChunkLoadError } from './production-runtime-DDEM1D2q.js';
|
|
48
|
+
export { a as FarmClientHydrationCompleteEvent, b as FarmClientHydrationEvent, d as FarmClientHydrationMode, e as FarmClientHydrationSession, f as FarmClientLocation, g as FarmClientNavigationAction, h as FarmClientNavigationErrorEvent, i as FarmClientNavigationEvent, j as FarmClientNavigationLoadedEvent, k as FarmClientNavigationResolvedEvent, l as FarmClientNavigationSession, m as FarmClientPerformanceEvent, n as FarmClientPlugin, o as FarmClientPluginCloseEvent, p as FarmClientPluginEnforce, q as FarmClientPluginErrorEvent, r as FarmClientPluginErrorPhase, F as FarmClientPluginManager, s as FarmClientPluginManagerOptions, t as FarmClientPluginMetadata, u as FarmClientPluginRegistration, v as FarmClientPluginRouter, w as FarmClientPluginSetupEvent, x as FarmClientPluginStateEvent, c as createClientPluginManager } from './plugin-BJDf43dc.js';
|
|
49
|
+
export { CacheKeyFactory, DefinedCacheKey, FarmCacheAdapter, FarmCacheEntry, FarmCacheInvalidationTarget, FarmCacheOptions, FarmCacheSetOptions, FarmCacheStorage, FarmCacheUserConfig, FarmDataCache, GetFarmCacheEntryOptions, InferCacheKeyData, RevalidateTagProfile, RouteDataCacheKey, StorageFarmCacheAdapterOptions, applyFarmCacheInvalidationTargets, applyFarmCacheInvalidations, configureFarmCache, createFarmCacheKey, createPathCacheTag, createRouteDataCacheKey, createRouteDataCacheTag, defineCacheKey, getFarmDataCache, invalidate, invalidateRouteData, normalizeRevalidatePath, revalidatePath, revalidateTag, storageCacheAdapter, unstable_cache, updateTag } from './cache.js';
|
|
50
|
+
export { Deferred, DeferredDataError, DeferredDataResponseOptions, DeferredRecord, DeferredSettlement, DeferredSettlements, FARM_DEFERRED_BRAND, FARM_DEFERRED_CONTENT_TYPE, FARM_DEFERRED_ERROR_CODE, PreparedDeferredData, createDeferredDataResponse, defer, isDeferred, prepareDeferredData, readDeferredDataResponse, reviveDeferredData, snapshotDeferredData } from './deferred.js';
|
|
51
|
+
export { AfterCallback, FarmAfterPlatformContext, _runWithAfterNodeResponse, _runWithAfterRequest, _withAfterNodeMiddleware, after } from './after.js';
|
|
52
|
+
export { usePathname, useSearchParams } from './navigation.js';
|
|
53
|
+
export { ReadonlyHeaders, ReadonlyRequestCookies, RequestCookie, cookies, headers } from './headers.js';
|
|
54
|
+
export { defineConfig, defineFarmConfig } from './config.js';
|
|
55
|
+
export { F as FarmRedirectSignal, b as FarmRedirectStatus, g as getFarmRedirectError, i as isFarmNotFoundError, a as isFarmRedirectError, n as notFound, p as permanentRedirect, r as redirect } from './navigation-errors-Dvwpzaer.js';
|
|
56
|
+
export { F as FarmStorageBuiltinDriverConfig, a as FarmStorageClient, b as FarmStorageClientConfig, c as FarmStorageConfigObject, d as FarmStorageCustomDriverConfig, e as FarmStorageDatabaseConfig, f as FarmStorageDatabaseDriverName, g as FarmStorageLocalDriverConfig, i as FarmStorageMountConfig, j as FarmStorageMounts, h as FarmStorageRuntimeClient, k as FarmStorageUserConfig } from './types-D1A6-XvH.js';
|
|
57
|
+
export { BuiltinDriverName, BuiltinDriverOptions, Driver, Storage, StorageMeta, StorageValue, TransactionOptions } from 'unstorage';
|
|
58
|
+
export { ConnectorName, ConnectorOptions, Database } from 'db0';
|
|
59
|
+
import 'http';
|
|
60
|
+
import '@farming-labs/orm';
|
|
61
|
+
import './metadata-JHn-8eht.js';
|
|
62
|
+
import './runtime-bv63eUiO.js';
|
|
63
|
+
import './resolver-IH4RmPEl.js';
|
|
64
|
+
import './client-cache-CIlyBlmx.js';
|
|
65
|
+
import '@farming-labs/docs';
|
|
66
|
+
import './internal/config-runtime.js';
|
|
67
|
+
import 'node:http';
|
|
68
|
+
|
|
69
|
+
interface FarmProviderProps {
|
|
70
|
+
children: ReactNode;
|
|
71
|
+
config: FarmConfig;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Farm.js context provider for client-side components
|
|
75
|
+
*/
|
|
76
|
+
declare function FarmProvider({ children, config }: FarmProviderProps): react_jsx_runtime.JSX.Element;
|
|
77
|
+
|
|
78
|
+
declare class HMRManager {
|
|
79
|
+
private server;
|
|
80
|
+
constructor(server: ViteDevServer);
|
|
81
|
+
/**
|
|
82
|
+
* Send HMR update to client
|
|
83
|
+
*/
|
|
84
|
+
send(payload: any): Promise<void>;
|
|
85
|
+
/**
|
|
86
|
+
* Trigger full page reload
|
|
87
|
+
*/
|
|
88
|
+
reloadPage(): Promise<void>;
|
|
89
|
+
/**
|
|
90
|
+
* Handle file change and trigger HMR
|
|
91
|
+
*/
|
|
92
|
+
handleFileChange(file: string): Promise<void>;
|
|
93
|
+
/**
|
|
94
|
+
* Get all affected modules in the dependency graph
|
|
95
|
+
*/
|
|
96
|
+
private getAffectedModules;
|
|
97
|
+
/**
|
|
98
|
+
* Handle custom HMR events from client
|
|
99
|
+
*/
|
|
100
|
+
onClientMessage(event: string, callback: (data: any) => void): void;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface APIRouteInfo {
|
|
104
|
+
path: string;
|
|
105
|
+
methods: string[];
|
|
106
|
+
filePath: string;
|
|
107
|
+
relativePath: string;
|
|
108
|
+
}
|
|
109
|
+
declare class APITypeGenerator {
|
|
110
|
+
private appDirs;
|
|
111
|
+
constructor(appDir: string | readonly string[]);
|
|
112
|
+
/**
|
|
113
|
+
* Scan all API route files and extract route information
|
|
114
|
+
*/
|
|
115
|
+
scanAPIRoutes(): APIRouteInfo[];
|
|
116
|
+
private scanDirectory;
|
|
117
|
+
private extractRouteInfo;
|
|
118
|
+
private extractExportedMethods;
|
|
119
|
+
/**
|
|
120
|
+
* Generate TypeScript code for the API router
|
|
121
|
+
*/
|
|
122
|
+
generateAPIRouter(routes: APIRouteInfo[], options?: {
|
|
123
|
+
outFile?: string;
|
|
124
|
+
}): string;
|
|
125
|
+
private getRouteImportPath;
|
|
126
|
+
private pathToRouteName;
|
|
127
|
+
private structureToTypeString;
|
|
128
|
+
private toTypePropertyKey;
|
|
129
|
+
private getBaseExportName;
|
|
130
|
+
private getExportName;
|
|
131
|
+
/**
|
|
132
|
+
* Generate the API index file
|
|
133
|
+
*/
|
|
134
|
+
generateAPIIndex(outputPath: string): void;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
interface OpenAPISpec {
|
|
138
|
+
openapi: string;
|
|
139
|
+
info: {
|
|
140
|
+
title: string;
|
|
141
|
+
description?: string;
|
|
142
|
+
version: string;
|
|
143
|
+
contact?: {
|
|
144
|
+
name?: string;
|
|
145
|
+
email?: string;
|
|
146
|
+
url?: string;
|
|
147
|
+
};
|
|
148
|
+
license?: {
|
|
149
|
+
name: string;
|
|
150
|
+
url?: string;
|
|
151
|
+
};
|
|
152
|
+
};
|
|
153
|
+
servers?: Array<{
|
|
154
|
+
url: string;
|
|
155
|
+
description?: string;
|
|
156
|
+
}>;
|
|
157
|
+
paths: Record<string, any>;
|
|
158
|
+
components?: {
|
|
159
|
+
schemas?: Record<string, any>;
|
|
160
|
+
securitySchemes?: Record<string, any>;
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
declare class OpenAPIGenerator {
|
|
164
|
+
private config;
|
|
165
|
+
private appDir;
|
|
166
|
+
constructor(appDir: string, config: OpenAPIConfig);
|
|
167
|
+
/**
|
|
168
|
+
* Get type from Zod type
|
|
169
|
+
*/
|
|
170
|
+
private getTypeFromZodType;
|
|
171
|
+
/**
|
|
172
|
+
* Process Zod type to OpenAPI schema
|
|
173
|
+
*/
|
|
174
|
+
private processZodType;
|
|
175
|
+
/**
|
|
176
|
+
* Generate standard error responses
|
|
177
|
+
*/
|
|
178
|
+
private getStandardResponses;
|
|
179
|
+
/**
|
|
180
|
+
* Generate OpenAPI spec from API routes
|
|
181
|
+
*/
|
|
182
|
+
generateSpec(routes: APIRouteInfo[]): Promise<OpenAPISpec>;
|
|
183
|
+
/**
|
|
184
|
+
* Convert Farm.js API path to OpenAPI path format
|
|
185
|
+
*/
|
|
186
|
+
private convertToOpenAPIPath;
|
|
187
|
+
/**
|
|
188
|
+
* Extract request body schema from endpoint
|
|
189
|
+
*/
|
|
190
|
+
private getRequestBody;
|
|
191
|
+
/**
|
|
192
|
+
* Extract query parameters from endpoint
|
|
193
|
+
*/
|
|
194
|
+
private getParameters;
|
|
195
|
+
/**
|
|
196
|
+
* Generate OpenAPI operation from route info
|
|
197
|
+
*/
|
|
198
|
+
private generateOperation;
|
|
199
|
+
/**
|
|
200
|
+
* Generate operation summary
|
|
201
|
+
*/
|
|
202
|
+
private generateSummary;
|
|
203
|
+
/**
|
|
204
|
+
* Generate operation description
|
|
205
|
+
*/
|
|
206
|
+
private generateDescription;
|
|
207
|
+
/**
|
|
208
|
+
* Generate operation ID
|
|
209
|
+
*/
|
|
210
|
+
private generateOperationId;
|
|
211
|
+
/**
|
|
212
|
+
* Generate tags for grouping operations
|
|
213
|
+
*/
|
|
214
|
+
private generateTags;
|
|
215
|
+
/**
|
|
216
|
+
* Generate OpenAPI spec file
|
|
217
|
+
*/
|
|
218
|
+
generateSpecFile(routes: APIRouteInfo[], outputPath: string): Promise<void>;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
declare class OpenAPIManager {
|
|
222
|
+
private generator;
|
|
223
|
+
private apiTypeGenerator;
|
|
224
|
+
private config;
|
|
225
|
+
private appDir;
|
|
226
|
+
private specCache;
|
|
227
|
+
constructor(appDir: string | readonly string[], config: OpenAPIConfig);
|
|
228
|
+
/**
|
|
229
|
+
* Generate OpenAPI spec from API routes
|
|
230
|
+
*/
|
|
231
|
+
generateSpec(): Promise<any>;
|
|
232
|
+
/**
|
|
233
|
+
* Get cached spec or generate new one
|
|
234
|
+
*/
|
|
235
|
+
getSpec(): Promise<any>;
|
|
236
|
+
/**
|
|
237
|
+
* Generate and save OpenAPI spec file
|
|
238
|
+
*/
|
|
239
|
+
generateSpecFile(): Promise<void>;
|
|
240
|
+
/**
|
|
241
|
+
* Invalidate cache and regenerate spec
|
|
242
|
+
*/
|
|
243
|
+
invalidateCache(): Promise<void>;
|
|
244
|
+
/**
|
|
245
|
+
* Get the docs route handler
|
|
246
|
+
*/
|
|
247
|
+
getDocsRouteHandler(): (req: any, res: any) => Promise<void>;
|
|
248
|
+
/**
|
|
249
|
+
* Generate HTML for docs route
|
|
250
|
+
*/
|
|
251
|
+
private generateDocsHTML;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
interface ScalarAPIDocumentationProps {
|
|
255
|
+
spec: any;
|
|
256
|
+
config?: {
|
|
257
|
+
theme?: "default" | "purple" | "blue" | "green" | "red" | "yellow";
|
|
258
|
+
layout?: "modern" | "classic";
|
|
259
|
+
showSidebar?: boolean;
|
|
260
|
+
hideDownloadButton?: boolean;
|
|
261
|
+
hideTryItPanel?: boolean;
|
|
262
|
+
};
|
|
263
|
+
}
|
|
264
|
+
declare function ScalarAPIDocumentation({ spec, config }: ScalarAPIDocumentationProps): react_jsx_runtime.JSX.Element;
|
|
265
|
+
declare global {
|
|
266
|
+
interface Window {
|
|
267
|
+
ScalarApiReference: (config: any) => void;
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
interface DocsRouteProps {
|
|
272
|
+
spec: any;
|
|
273
|
+
config?: any;
|
|
274
|
+
}
|
|
275
|
+
declare function DocsRoute({ spec, config }: DocsRouteProps): react_jsx_runtime.JSX.Element;
|
|
276
|
+
|
|
277
|
+
interface GenerateFarmI18nTypesOptions {
|
|
278
|
+
root: string;
|
|
279
|
+
srcDir?: string;
|
|
280
|
+
config: ResolvedFarmI18nConfig;
|
|
281
|
+
outFile?: string;
|
|
282
|
+
}
|
|
283
|
+
declare function generateFarmI18nTypes(options: GenerateFarmI18nTypesOptions): Promise<string | undefined>;
|
|
284
|
+
|
|
285
|
+
interface GenerateFarmTypeArtifactsOptions {
|
|
286
|
+
root: string;
|
|
287
|
+
srcDir?: string;
|
|
288
|
+
configPath?: string;
|
|
289
|
+
extraRoutes?: string[];
|
|
290
|
+
layers?: readonly ResolvedFarmLayer[];
|
|
291
|
+
suppressLintOnLink?: boolean;
|
|
292
|
+
routeTypesOutFile?: string;
|
|
293
|
+
apiTypesOutFile?: string;
|
|
294
|
+
envTypesOutFile?: string;
|
|
295
|
+
imageTypesOutFile?: string;
|
|
296
|
+
i18nTypesOutFile?: string;
|
|
297
|
+
i18nConfig?: ResolvedFarmI18nConfig;
|
|
298
|
+
routes?: boolean;
|
|
299
|
+
api?: boolean;
|
|
300
|
+
env?: boolean;
|
|
301
|
+
images?: boolean;
|
|
302
|
+
i18n?: boolean;
|
|
303
|
+
}
|
|
304
|
+
interface GenerateFarmTypeArtifactsResult {
|
|
305
|
+
typesPath?: string;
|
|
306
|
+
routeTypesPath?: string;
|
|
307
|
+
apiTypesPath?: string;
|
|
308
|
+
envTypesPath?: string;
|
|
309
|
+
imageTypesPath?: string;
|
|
310
|
+
i18nTypesPath?: string;
|
|
311
|
+
apiRoutes: APIRouteInfo[];
|
|
312
|
+
}
|
|
313
|
+
declare function generateFarmTypeArtifacts(options: GenerateFarmTypeArtifactsOptions): Promise<GenerateFarmTypeArtifactsResult>;
|
|
314
|
+
|
|
315
|
+
interface GenerateFarmImageTypesOptions {
|
|
316
|
+
root: string;
|
|
317
|
+
srcDir?: string;
|
|
318
|
+
outFile?: string;
|
|
319
|
+
}
|
|
320
|
+
declare function generateFarmImageTypes(options: GenerateFarmImageTypesOptions): string;
|
|
321
|
+
declare function createFarmImageTypeDeclarations(): string;
|
|
322
|
+
|
|
323
|
+
interface GenerateRouteTypesOptions {
|
|
324
|
+
root: string;
|
|
325
|
+
srcDir?: string;
|
|
326
|
+
outFile?: string;
|
|
327
|
+
extraRoutes?: string[];
|
|
328
|
+
/** Ordered layer roots followed by the project root. */
|
|
329
|
+
sourceRoots?: readonly FarmSourceRoot[];
|
|
330
|
+
/** When true, do not augment LinkDefaultRoute so Link href accepts any string (no route-type errors). */
|
|
331
|
+
suppressLintOnLink?: boolean;
|
|
332
|
+
}
|
|
333
|
+
/**
|
|
334
|
+
* Scan app directory for page files, generate RoutePath union type,
|
|
335
|
+
* and write a .d.ts file for typed Link href.
|
|
336
|
+
*/
|
|
337
|
+
declare function generateRouteTypes(options: GenerateRouteTypesOptions): Promise<string>;
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* Farm.js SSG (Static Site Generation) Module
|
|
341
|
+
*
|
|
342
|
+
* Handles collection and pre-rendering of SSG pages at build time.
|
|
343
|
+
*
|
|
344
|
+
* SSR is the default - pages render on each request
|
|
345
|
+
* SSG is opt-in via `export const ssg = true`, Next-compatible route
|
|
346
|
+
* config exports, or a top-of-file rendering directive.
|
|
347
|
+
*
|
|
348
|
+
* @example
|
|
349
|
+
* ```tsx
|
|
350
|
+
* // SSG Page
|
|
351
|
+
* export const ssg = true;
|
|
352
|
+
* export default function AboutPage() {
|
|
353
|
+
* return <h1>About</h1>;
|
|
354
|
+
* }
|
|
355
|
+
*
|
|
356
|
+
* // SSG with ISR
|
|
357
|
+
* export const ssg = true;
|
|
358
|
+
* export const revalidate = 60;
|
|
359
|
+
* export default async function ProductsPage() {
|
|
360
|
+
* const products = await fetchProducts();
|
|
361
|
+
* return <ProductList products={products} />;
|
|
362
|
+
* }
|
|
363
|
+
*
|
|
364
|
+
* // Dynamic SSG
|
|
365
|
+
* export const ssg = true;
|
|
366
|
+
* export async function getStaticPaths() {
|
|
367
|
+
* const posts = await fetchPosts();
|
|
368
|
+
* return posts.map(post => ({ slug: post.slug }));
|
|
369
|
+
* }
|
|
370
|
+
* export default async function BlogPost({ params }) {
|
|
371
|
+
* return <article>{params.slug}</article>;
|
|
372
|
+
* }
|
|
373
|
+
*
|
|
374
|
+
* // Next-compatible route config
|
|
375
|
+
* export const dynamic = "force-static";
|
|
376
|
+
* export const revalidate = 60;
|
|
377
|
+
*
|
|
378
|
+
* // PPR/static-shell route
|
|
379
|
+
* export const experimental_ppr = true;
|
|
380
|
+
* export const revalidate = 60;
|
|
381
|
+
*
|
|
382
|
+
* // Directive config
|
|
383
|
+
* "use ssg; 60";
|
|
384
|
+
* export default function DocsPage() {
|
|
385
|
+
* return <h1>Docs</h1>;
|
|
386
|
+
* }
|
|
387
|
+
* ```
|
|
388
|
+
*/
|
|
389
|
+
|
|
390
|
+
interface RouteEntry {
|
|
391
|
+
path: string;
|
|
392
|
+
filePath: string;
|
|
393
|
+
isDynamic: boolean;
|
|
394
|
+
pattern: string;
|
|
395
|
+
}
|
|
396
|
+
type RouteRenderingDynamic = NonNullable<RouteModule["dynamic"]>;
|
|
397
|
+
interface RouteRenderingConfig {
|
|
398
|
+
ssg: boolean;
|
|
399
|
+
ppr: boolean;
|
|
400
|
+
revalidate?: number;
|
|
401
|
+
dynamic?: RouteRenderingDynamic;
|
|
402
|
+
directive?: string;
|
|
403
|
+
}
|
|
404
|
+
interface DirectiveRenderingConfig {
|
|
405
|
+
ssg: boolean;
|
|
406
|
+
ppr: boolean;
|
|
407
|
+
revalidate?: number;
|
|
408
|
+
dynamic?: RouteRenderingDynamic;
|
|
409
|
+
directive: string;
|
|
410
|
+
}
|
|
411
|
+
/**
|
|
412
|
+
* Resolve route rendering from Farm exports, Next-compatible exports, and
|
|
413
|
+
* top-of-file directives such as `"use ssg";` or `"use ssg; 60";`.
|
|
414
|
+
*/
|
|
415
|
+
declare function resolveRouteRenderingConfig(mod: RouteModule | null | undefined, source?: string): RouteRenderingConfig;
|
|
416
|
+
declare function resolveRouteRenderingConfigFromFile(mod: RouteModule | null | undefined, filePath: string): Promise<RouteRenderingConfig>;
|
|
417
|
+
declare function parseRouteRenderingDirective(source: string | undefined): DirectiveRenderingConfig | undefined;
|
|
418
|
+
/**
|
|
419
|
+
* Collect SSG pages from route modules
|
|
420
|
+
*
|
|
421
|
+
* Scans all routes and categorizes them into:
|
|
422
|
+
* - SSG pages: Pre-rendered at build time
|
|
423
|
+
* - SSR routes: Rendered on each request
|
|
424
|
+
*
|
|
425
|
+
* @param routes - Array of route entries
|
|
426
|
+
* @param loadModule - Function to load a route module
|
|
427
|
+
* @returns SSG pages and SSR routes
|
|
428
|
+
*/
|
|
429
|
+
declare function collectSSGPages(routes: RouteEntry[], loadModule: (filePath: string) => Promise<RouteModule>): Promise<SSGCollectionResult>;
|
|
430
|
+
/**
|
|
431
|
+
* Check if a route module is SSG
|
|
432
|
+
*/
|
|
433
|
+
declare function isSSGModule(mod: RouteModule | null | undefined): boolean;
|
|
434
|
+
/**
|
|
435
|
+
* Check if a route module has ISR (Incremental Static Regeneration)
|
|
436
|
+
*/
|
|
437
|
+
declare function hasISR(mod: RouteModule | null | undefined): boolean;
|
|
438
|
+
/**
|
|
439
|
+
* Get revalidation interval for a module
|
|
440
|
+
*/
|
|
441
|
+
declare function getRevalidateInterval(mod: RouteModule | null | undefined): number | undefined;
|
|
442
|
+
/**
|
|
443
|
+
* Check if a route module has PPR/static-shell caching enabled.
|
|
444
|
+
*/
|
|
445
|
+
declare function hasPPR(mod: RouteModule | null | undefined): boolean;
|
|
446
|
+
/**
|
|
447
|
+
* Generate SSG manifest for production builds
|
|
448
|
+
*/
|
|
449
|
+
declare function generateSSGManifest(pages: SSGPage[]): string;
|
|
450
|
+
/**
|
|
451
|
+
* Check if a URL path matches an SSG page
|
|
452
|
+
*/
|
|
453
|
+
declare function matchSSGPage(urlPath: string, ssgPages: SSGPage[]): SSGPage | undefined;
|
|
454
|
+
|
|
455
|
+
export { APITypeGenerator, DocsRoute, FarmConfig, FarmProvider, type GenerateFarmImageTypesOptions, type GenerateFarmTypeArtifactsOptions, type GenerateFarmTypeArtifactsResult, type GenerateRouteTypesOptions, HMRManager, OpenAPIConfig, OpenAPIGenerator, OpenAPIManager, type OpenAPISpec, ResolvedFarmI18nConfig, ResolvedFarmLayer, RouteModule, type RouteRenderingConfig, type RouteRenderingDynamic, SSGCollectionResult, SSGPage, ScalarAPIDocumentation, collectSSGPages, createFarmImageTypeDeclarations, generateFarmI18nTypes, generateFarmImageTypes, generateFarmTypeArtifacts, generateRouteTypes, generateSSGManifest, getRevalidateInterval, hasISR, hasPPR, isSSGModule, matchSSGPage, parseRouteRenderingDirective, resolveRouteRenderingConfig, resolveRouteRenderingConfigFromFile };
|
package/dist/index.mjs
CHANGED
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "./chunk-VCANOYFI.mjs";
|
|
10
10
|
import {
|
|
11
11
|
build
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-4677KXB7.mjs";
|
|
13
13
|
import "./chunk-SL6HTIOK.mjs";
|
|
14
14
|
import "./chunk-4S3ORGFA.mjs";
|
|
15
15
|
import {
|
|
@@ -152,7 +152,7 @@ import {
|
|
|
152
152
|
parseRouteRenderingDirective,
|
|
153
153
|
resolveRouteRenderingConfig,
|
|
154
154
|
resolveRouteRenderingConfigFromFile
|
|
155
|
-
} from "./chunk-
|
|
155
|
+
} from "./chunk-77BOAQHI.mjs";
|
|
156
156
|
import {
|
|
157
157
|
APITypeGenerator
|
|
158
158
|
} from "./chunk-LGHEOHBU.mjs";
|
|
@@ -389,7 +389,7 @@ import {
|
|
|
389
389
|
getCurrentRequest
|
|
390
390
|
} from "./chunk-RHIFZZUI.mjs";
|
|
391
391
|
import "./chunk-LM2YNO4U.mjs";
|
|
392
|
-
import "./chunk-
|
|
392
|
+
import "./chunk-5EVQFRL2.mjs";
|
|
393
393
|
import {
|
|
394
394
|
SPARouter,
|
|
395
395
|
getRouter,
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
type FarmIntegrationAPIMethod = "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD";
|
|
2
|
+
type FarmIntegrationAPIBodyFormat = "json" | "form" | "none";
|
|
3
|
+
type FarmIntegrationAPIResponseFormat = "json" | "text" | "response";
|
|
4
|
+
interface FarmIntegrationAPIOperation<TBody = never, TQuery = never, TResponse = unknown, TServer extends boolean = false, TMethod extends FarmIntegrationAPIMethod = FarmIntegrationAPIMethod> {
|
|
5
|
+
readonly kind: "farm-integration-api-operation";
|
|
6
|
+
path: string;
|
|
7
|
+
method: TMethod;
|
|
8
|
+
bodyFormat?: FarmIntegrationAPIBodyFormat;
|
|
9
|
+
responseFormat?: FarmIntegrationAPIResponseFormat;
|
|
10
|
+
headers?: Record<string, string>;
|
|
11
|
+
credentials?: RequestCredentials;
|
|
12
|
+
isServer?: TServer;
|
|
13
|
+
__pathless?: boolean;
|
|
14
|
+
__types?: {
|
|
15
|
+
body: TBody;
|
|
16
|
+
query: TQuery;
|
|
17
|
+
response: TResponse;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
type FarmIntegrationAPI = {
|
|
21
|
+
[key: string]: FarmIntegrationAPI | FarmIntegrationAPIOperation<any, any, any, any, any>;
|
|
22
|
+
};
|
|
23
|
+
type FarmIntegrationRouteOperationCarrier<TPath extends string = string, TOperation extends FarmIntegrationAPIOperation<any, any, any, any, any> = FarmIntegrationAPIOperation<any, any, any, any, any>> = {
|
|
24
|
+
path: TPath;
|
|
25
|
+
__operation: TOperation;
|
|
26
|
+
};
|
|
27
|
+
type IntegrationAPIBuilderOptions<TServer extends boolean = false> = Omit<FarmIntegrationAPIOperation<any, any, any, TServer>, "kind" | "method" | "path" | "__pathless" | "__types">;
|
|
28
|
+
declare function defineIntegrationAPIOperation<TBody = never, TQuery = never, TResponse = unknown, TServer extends boolean = false, TMethod extends FarmIntegrationAPIMethod = FarmIntegrationAPIMethod>(operation: Omit<FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, TMethod>, "kind" | "__types">): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, TMethod>;
|
|
29
|
+
declare function defineIntegrationAPI<TAPI extends FarmIntegrationAPI>(api: TAPI): TAPI;
|
|
30
|
+
declare function get<TResponse = unknown, TServer extends boolean = false>(path: string, options?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, never, TResponse, TServer, "GET">;
|
|
31
|
+
declare function get<TQuery = never, TResponse = unknown, TServer extends boolean = false>(path: string, options?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "GET">;
|
|
32
|
+
declare function get<TResponse = unknown, TServer extends boolean = false>(options?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, never, TResponse, TServer, "GET">;
|
|
33
|
+
declare function get<TQuery = never, TResponse = unknown, TServer extends boolean = false>(options?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "GET">;
|
|
34
|
+
type RouteOperationsToAPI<TOperations extends readonly FarmIntegrationAPIOperation<any, any, any, any, any>[]> = {
|
|
35
|
+
[TMethod in Lowercase<TOperations[number]["method"] & string>]: Extract<TOperations[number], {
|
|
36
|
+
method: Uppercase<TMethod>;
|
|
37
|
+
}>;
|
|
38
|
+
};
|
|
39
|
+
type StripRouteClientPrefix<TPath extends string> = TPath extends `/api/${string}/${infer TRest}` ? TRest : TPath extends `/${string}/${infer TRest}` ? TRest : TPath extends `/${infer TRest}` ? TRest : TPath;
|
|
40
|
+
type NormalizeRouteSegment<TSegment extends string> = TSegment extends `[...${infer TName}]` ? TName : TSegment extends `[${infer TName}]` ? TName : TSegment extends `${infer TName}(${string}` ? TName : CamelCaseRouteSegment<TSegment>;
|
|
41
|
+
type CamelCaseRouteSegment<TSegment extends string> = TSegment extends `${infer THead}-${infer TTail}` ? `${THead}${Capitalize<CamelCaseRouteSegment<TTail>>}` : TSegment;
|
|
42
|
+
type RouteNamespaceFromPath<TPath extends string, TOperation extends FarmIntegrationAPIOperation<any, any, any, any, any>> = TPath extends `${infer THead}/${infer TTail}` ? {
|
|
43
|
+
[TKey in NormalizeRouteSegment<THead>]: RouteNamespaceFromPath<TTail, TOperation>;
|
|
44
|
+
} : {
|
|
45
|
+
[TKey in NormalizeRouteSegment<TPath>]: {
|
|
46
|
+
[TMethod in Lowercase<TOperation["method"] & string>]: TOperation;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
type UnionToIntersection<TUnion> = (TUnion extends unknown ? (value: TUnion) => void : never) extends (value: infer TIntersection) => void ? TIntersection : never;
|
|
50
|
+
type ExpandRecursively<TValue> = TValue extends (...args: any[]) => any ? TValue : TValue extends object ? {
|
|
51
|
+
[TKey in keyof TValue]: ExpandRecursively<TValue[TKey]>;
|
|
52
|
+
} : TValue;
|
|
53
|
+
type RoutesToAPI<TRoutes extends readonly FarmIntegrationRouteOperationCarrier<string, any>[]> = ExpandRecursively<UnionToIntersection<TRoutes[number] extends FarmIntegrationRouteOperationCarrier<infer TPath, infer TOperation> ? RouteNamespaceFromPath<StripRouteClientPrefix<TPath>, TOperation> : never>>;
|
|
54
|
+
type InferIntegrationAPIFromRoutes<TRoutes extends readonly FarmIntegrationRouteOperationCarrier<string, any>[]> = RoutesToAPI<TRoutes>;
|
|
55
|
+
declare function route<TAPI extends FarmIntegrationAPI>(path: string, definition: TAPI): TAPI;
|
|
56
|
+
declare function route<TOperations extends readonly FarmIntegrationAPIOperation<any, any, any, any, any>[]>(path: string, ...operations: TOperations): RouteOperationsToAPI<TOperations>;
|
|
57
|
+
declare function fromRoutes<TRoutes extends readonly FarmIntegrationRouteOperationCarrier<string, any>[]>(routes: TRoutes): RoutesToAPI<TRoutes>;
|
|
58
|
+
declare const api: {
|
|
59
|
+
get: typeof get;
|
|
60
|
+
route: typeof route;
|
|
61
|
+
fromRoutes: typeof fromRoutes;
|
|
62
|
+
post<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "POST">;
|
|
63
|
+
put<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PUT">;
|
|
64
|
+
patch<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PATCH">;
|
|
65
|
+
delete<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "DELETE">;
|
|
66
|
+
options<TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "OPTIONS">;
|
|
67
|
+
head<TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "HEAD">;
|
|
68
|
+
form: {
|
|
69
|
+
post<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "POST">;
|
|
70
|
+
put<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PUT">;
|
|
71
|
+
patch<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PATCH">;
|
|
72
|
+
delete<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "DELETE">;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
declare const endpoint: {
|
|
76
|
+
get: typeof get;
|
|
77
|
+
route: typeof route;
|
|
78
|
+
fromRoutes: typeof fromRoutes;
|
|
79
|
+
post<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "POST">;
|
|
80
|
+
put<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PUT">;
|
|
81
|
+
patch<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PATCH">;
|
|
82
|
+
delete<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "DELETE">;
|
|
83
|
+
options<TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "OPTIONS">;
|
|
84
|
+
head<TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<never, TQuery, TResponse, TServer, "HEAD">;
|
|
85
|
+
form: {
|
|
86
|
+
post<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "POST">;
|
|
87
|
+
put<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PUT">;
|
|
88
|
+
patch<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "PATCH">;
|
|
89
|
+
delete<TBody = never, TResponse = unknown, TQuery = never, TServer extends boolean = false>(pathOrOptions?: string | IntegrationAPIBuilderOptions<TServer>, maybeOptions?: IntegrationAPIBuilderOptions<TServer>): FarmIntegrationAPIOperation<TBody, TQuery, TResponse, TServer, "DELETE">;
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
export { type FarmIntegrationAPI as F, type InferIntegrationAPIFromRoutes as I, type FarmIntegrationAPIOperation as a, api as b, defineIntegrationAPIOperation as c, defineIntegrationAPI as d, type FarmIntegrationAPIBodyFormat as e, type FarmIntegrationAPIMethod as f, type FarmIntegrationAPIResponseFormat as g, type FarmIntegrationRouteOperationCarrier as h, endpoint as i };
|