import { Agent, HttpResponse, Header } from "./agent"; declare type Protocol = "http" | "https"; export interface Config { /** * Use TLS. Defaults to `true` */ tls: boolean; /** * API Key. Used in API helper methods */ api_key: string; /** * Target API hostname. Defaults to `'api.ideal-postcodes.co.uk'` */ baseUrl: string; /** * API version. Defaults to `'v1'` */ version: string; /** * Force autocomplete authorisation via HTTP headers only. Defaults to `false` */ strictAuthorisation: boolean; /** * Time before HTTP request timeout. Defaults to 10s */ timeout: number; /** * HTTP Agent * * For downstream clients like core-node and core-browser, this will default to the native platform HTTP client */ agent: Agent; /** * String map specifying default headers */ header: Header; } interface Defaults { header: Header; } import { AddressResource } from "./resources/addresses"; import { PostcodeResource } from "./resources/postcodes"; import { KeyResource } from "./resources/keys"; import { UdprnResource } from "./resources/udprn"; import { UmprnResource } from "./resources/umprn"; export declare class Client { static defaults: Defaults; readonly tls: boolean; readonly api_key: string; readonly baseUrl: string; readonly version: string; readonly strictAuthorisation: boolean; readonly timeout: number; readonly agent: Agent; readonly header: Header; readonly postcodes: PostcodeResource; readonly addresses: AddressResource; readonly udprn: UdprnResource; readonly umprn: UmprnResource; readonly keys: KeyResource; constructor(config: Config); /** * url * * Return base URL for API requests */ url(): string; protocol(): Protocol; /** * ping * * Dispatches HTTP request to root endpoint "`/`" */ ping(): Promise; } export {};