Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/deno/cli/tsc/dts/lib.deno.unstable.d.ts>Deno.CreateHttpClientOptions

A modern runtime for JavaScript and TypeScript.
Latest
interface Deno.CreateHttpClientOptions
import { type Deno } from "https://deno.land/x/deno@v1.41.0/cli/tsc/dts/lib.deno.unstable.d.ts";
const { CreateHttpClientOptions } = Deno;

UNSTABLE: New API, yet to be vetted.

The options used when creating a Deno.HttpClient.

Properties

optional
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.

optional
proxy: Proxy

A HTTP proxy to use for new connections.

optional
cert: string

Server private key in PEM format.

optional
key: string

Cert chain in PEM format.

optional
poolMaxIdlePerHost: number

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

optional
poolIdleTimeout: number | false

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

optional
http1: boolean = true

Whether HTTP/1.1 is allowed or not.

optional
http2: boolean = true

Whether HTTP/2 is allowed or not.

optional
allowHost: boolean = false

Whether setting the host header is allowed or not.