Askr
Generated API snapshot

@askrjs/server

Exports from the declarations published in @askrjs/server 0.0.3. Signatures are generated from the installed artifact.

  • @askrjs/server0.0.3

Exports

This entrypoint publishes 70 exports. Use the anchored symbol rows for direct links. Type-only exports are labeled separately from runtime values.

acceptedtype

accepted: (value?: JsonValue, init?: ResponseInit) => Response

badtype

bad: (detail?: string, init?: ResponseInit) => Response

badRequesttype

badRequest: (detail?: string, init?: ResponseInit) => Response

bindtype

bind: <T extends object = Record<string, unknown>>(context: BindContext) => Promise<T>

challengetype

challenge: (options?: ChallengeOptions) => Response

conflicttype

conflict: (detail?: string, init?: ResponseInit) => Response

createdtype

created: (value?: JsonValue, init?: ResponseInit) => Response

createEventStreamtype

createEventStream: (options?: EventStreamOptions) => EventStream

createServerApptype

createServerApp: { (router: Router): ServerApp; (options?: ServerAppOptions): ServerApp; }

defineRoutestype

defineRoutes: (definition: (route: RouteBuilder) => void) => ApiRoute[]

errortype

error: (status?: number, detail?: string, init?: ResponseInit) => Response

forbiddentype

forbidden: (detail?: string, init?: ResponseInit) => Response

jsontype

json: (value: JsonValue, init?: ResponseInit) => Response

methodNotAllowedtype

methodNotAllowed: (allow?: string | readonly string[], init?: ResponseInit) => Response

noContenttype

noContent: (init?: ResponseInit) => Response

notFoundtype

notFound: (detail?: string, init?: ResponseInit) => Response

notImplementedtype

notImplemented: (detail?: string, init?: ResponseInit) => Response

oktype

ok: (value?: JsonValue, init?: ResponseInit) => Response

problemtype

problem: (status: number, detail?: string, options?: ProblemOptions & { init?: ResponseInit; }) => Response

redirecttype

redirect: (location: string, status?: 301 | 302 | 303 | 307 | 308) => Response

registerAuthRoutestype

registerAuthRoutes: <Dependencies, P extends Principal>(api: Pick<ApiDefinition<Dependencies>, "group">, options: AuthRouteOptions<P>) => void

safeRedirecttype

safeRedirect: (fallback: string, options?: SafeRedirectOptions) => (value: unknown) => string

serverErrortype

serverError: (detail?: string, init?: ResponseInit) => Response

serviceUnavailabletype

serviceUnavailable: (detail?: string, init?: ResponseInit) => Response

texttype

text: (value: string, init?: ResponseInit) => Response

tooManyRequeststype

tooManyRequests: (detail?: string, init?: ResponseInit) => Response

unauthorizedtype

unauthorized: (detail?: string, init?: ResponseInit) => Response