client.go — fiber Source File
Architecture documentation for client.go, a go file in the fiber codebase. 1 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 0a898b85_5e70_235c_a863_b41e3d48af64["client.go"] cc7104af_aece_1fe5_3985_791c7f34910c["context"] 0a898b85_5e70_235c_a863_b41e3d48af64 --> cc7104af_aece_1fe5_3985_791c7f34910c style 0a898b85_5e70_235c_a863_b41e3d48af64 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
// Package client exposes Fiber's HTTP client built on top of fasthttp.
//
// It allows constructing new clients or wrapping existing fasthttp transports
// so applications can share pools, dialers, and TLS settings between Fiber and
// lower-level fasthttp integrations.
package client
import (
"context"
"crypto/tls"
"crypto/x509"
"encoding/json"
"encoding/xml"
"errors"
"io"
"os"
"path/filepath"
"sync"
"time"
"github.com/fxamacker/cbor/v2"
"github.com/gofiber/fiber/v3/log"
"github.com/gofiber/utils/v2"
"github.com/valyala/fasthttp"
"github.com/valyala/fasthttp/fasthttpproxy"
)
var ErrFailedToAppendCert = errors.New("failed to append certificate")
// Client provides Fiber's high-level HTTP API while delegating transport work
// to fasthttp.Client, fasthttp.HostClient, or fasthttp.LBClient implementations.
//
// Settings configured on the client are shared across every request and may be
// overridden per request when needed.
type Client struct {
logger log.CommonLogger
transport httpClientTransport
header *Header
params *QueryParam
cookies *Cookie
path *PathParam
jsonMarshal utils.JSONMarshal
jsonUnmarshal utils.JSONUnmarshal
xmlMarshal utils.XMLMarshal
xmlUnmarshal utils.XMLUnmarshal
cborMarshal utils.CBORMarshal
cborUnmarshal utils.CBORUnmarshal
cookieJar *CookieJar
retryConfig *RetryConfig
baseURL string
userAgent string
referer string
userRequestHooks []RequestHook
builtinRequestHooks []RequestHook
userResponseHooks []ResponseHook
// ... (804 more lines)
Domain
Subdomains
Functions
Dependencies
- context
Source
Frequently Asked Questions
What does client.go do?
client.go is a source file in the fiber codebase, written in go. It belongs to the FiberClient domain, Hooks subdomain.
What functions are defined in client.go?
client.go defines 16 function(s): C, Delete, Get, Head, New, NewWithClient, NewWithHostClient, NewWithLBClient, Options, Patch, and 6 more.
What does client.go depend on?
client.go imports 1 module(s): context.
Where is client.go in the architecture?
client.go is located at client/client.go (domain: FiberClient, subdomain: Hooks, directory: client).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free