Versions in this module Expand all Collapse all v0 v0.6.0 Oct 25, 2026 Changes in this version + const DefaultActionSelectorField + const DefaultMaxCBORBodyBytes + const DefaultMaxJSONBodyBytes + const DefaultMaxMultipartBodyBytes + const DefaultMultipartMaxMemory + const StreamJSONArray + const StreamNDJSON + const StreamSSE + var ErrReadLimit = bindcore.ErrReadLimit + func AcceptsCBOR(r *http.Request) bool + func ActionSelector(r *http.Request, field string) string + func AppendFileJSON(dst []byte, f File) []byte + func AssembleOpenAPI() (jsonDoc []byte, err error) + func BadRequest(problem Problem, cause ...error) error + func BindError(field, location, message string) error + func Bind[T any](r *http.Request) (T, error) + func CheckDate(s string) bool + func CheckDateTime(s string) bool + func CheckEmail(s string) bool + func CheckTime(s string) bool + func CheckUUID(s string) bool + func Conflict(problem Problem, cause ...error) error + func CookieValue(r *http.Request, name string) (string, bool) + func DispatchAction(w http.ResponseWriter, r *http.Request, handler http.HandlerFunc) + func Forbidden(problem Problem, cause ...error) error + func FormLookup(f FormValues, key string) (string, bool) + func HeaderValue(r *http.Request, key string) string + func Internal(err error) error + func IsCBORRequest(r *http.Request) bool + func IsJSONRequest(r *http.Request) bool + func IsNormalClose(err error) bool + func JSONBodyError(err error) error + func JSONBodyNotObject() error + func MaxCBORBodyBytes() int64 + func MaxJSONBodyBytes() int64 + func MaxMultipartBodyBytes() int64 + func NotFound(problem Problem, cause ...error) error + func OpenAPIDocument() ([]byte, error) + func OpenAPIJSON(w http.ResponseWriter, r *http.Request) + func ParseBool(s string) (bool, error) + func ParseBytes(s string) ([]byte, error) + func ParseFloat64(s string) (float64, error) + func ParseFormMap(r *http.Request) (map[string]string, error) + func ParseInt(s string) (int, error) + func ParseInt64(s string) (int64, error) + func ParseIntBits(s string, bits int) (int64, error) + func ParseMultipartMap(r *http.Request) (form map[string]string, files map[string]File, err error) + func ParseUintBits(s string, bits int) (uint64, error) + func PathValue(r *http.Request, key string) string + func PayloadTooLarge(problem Problem, cause ...error) error + func QueryLookup(q QueryValues, key string) (string, bool) + func QueryLookupAll(q QueryValues, key string) []string + func QueryValue(r *http.Request, key string) (string, bool) + func ReadActionBody(r *http.Request) ([]byte, error) + func ReadCBORBody(r *http.Request) ([]byte, error) + func ReadJSONBody(r *http.Request) ([]byte, error) + func ReadJSONBodyOwned(r *http.Request) ([]byte, error) + func Redirect(target string, status ...int) error + func RegisterBind[T any](fn func(*http.Request) (T, error)) + func RegisterOpenAPIFragment(id string, jsonDoc []byte) + func RegisterOpenAPIFragmentString(id string, jsonDoc string) + func RegisterWrite[T any](fn func(http.ResponseWriter, *http.Request, T) error) + func ResetOpenAPIFragments() + func RestFormAny(formBody FormValues, exclude []string) map[string]any + func RestFormRaw(formBody FormValues, exclude []string) map[string]json.RawMessage + func SetMaxCBORBodyBytes(n int64) + func SetMaxJSONBodyBytes(n int64) + func SetMaxMultipartBodyBytes(n int64) + func SetOpenAPIInfo(info OpenAPIInfo) error + func SetSocketDefaults(opts SocketOptions) + func SetStreamErrorHandler(fn func(error)) + func SwaggerUI(specURL string) http.Handler + func Unauthorized(problem Problem, cause ...error) error + func Validation(fields ...FieldError) error + func VaryAccept(w http.ResponseWriter) + func WebSocketWith[In, Out any](w http.ResponseWriter, r *http.Request, opts SocketOptions, ...) error + func WebSocket[In, Out any](w http.ResponseWriter, r *http.Request, fn func(*Socket[In, Out]) error) error + func WriteCBORBytes(w http.ResponseWriter, status int, data []byte) error + func WriteError(w http.ResponseWriter, r *http.Request, err error) + func WriteJSONBytes(w http.ResponseWriter, status int, data []byte) error + func WriteStatus[T any](w http.ResponseWriter, r *http.Request, status int, value T) error + func WriteStream[T any](w http.ResponseWriter, r *http.Request, fn func(*Stream[T]) error) + func Write[T any](w http.ResponseWriter, r *http.Request, value T) error + type Declaration struct + func ServerAction(fn any, name ...string) Declaration + type FieldError = bindcore.FieldError + func Field(field, location, message string) FieldError + type File = bindcore.File + type FormValues = bindcore.FormValues + func ReadFormBody(r *http.Request, wantForm, wantFiles bool) (FormValues, map[string]File, error) + type HTTPError = bindcore.HTTPError + func AsHTTPError(err error) (*HTTPError, bool) + type OpenAPIInfo struct + Title string + Version string + type Problem = bindcore.Problem + type QueryValues = bindcore.QueryValues + func Queries(r *http.Request) QueryValues + type Socket = bindcore.Socket[In, Out] + type SocketOptions = bindcore.SocketOptions + func SocketDefaults() SocketOptions + type Stream = bindcore.Stream[T] + type StreamFormat = bindcore.StreamFormat + func NegotiateStreamFormat(r *http.Request) StreamFormat