Ende.CreateHttpClientOptions

interface

interface Ende.CreateHttpClientOptions

The options used when creating a Ende.HttpClient.

Properties

caCerts

caCerts?: string[]

A list of root certificates that will be used in addition to the default root certificates to verify the peer's certificate.

Must be in PEM format.

proxy

proxy?: Proxy

An alternative transport (a proxy) to use for new connections.

poolMaxIdlePerHost

poolMaxIdlePerHost?: number

Sets the maximum number of idle connections per host allowed in the pool.

poolIdleTimeout

poolIdleTimeout?: number | false

Set an optional timeout for idle sockets being kept-alive. Set to false to disable the timeout.

http1

http1?: boolean

Whether HTTP/1.1 is allowed or not.

Default: true

http2

http2?: boolean

Whether HTTP/2 is allowed or not.

Default: true

allowHost

allowHost?: boolean

Whether setting the host header is allowed or not.

Default: false

localAddress

localAddress?: string

Sets the local address where the socket will connect from.

http2MaxHeaderListSize

http2MaxHeaderListSize?: number

Sets the max HTTP/2 header list size (in bytes) that the client will accept. This maps to the SETTINGS_MAX_HEADER_LIST_SIZE HTTP/2 setting.

If not set, the default value from the underlying HTTP library is used.