/** * Specify settings to the wrapper * @param {object} opts object holding the options * @param {string} opts.baseUrl url to use for requests */ export function settings(opts?: { baseUrl: string; }): string | false; /** * Retrieve a summary of global data * @param {object} opts object holding the options for that request * @param {boolean} opts.allowNull whether to allow null values (true) or automatically transform them to 0 (false) * @returns {object} summary object */ export function all(opts?: { allowNull: boolean; }): Promise; /** * Retrieve country specific data * @param {object} opts object holding the options for that request * @param {string|string[]} opts.country country name/s to be queried * @param {boolean} opts.allowNull whether to allow null values (true) or automatically transform them to 0 (false) * @param {string} opts.sort property name which will be used for sorting * @param {boolean} opts.strict whether to use strict name checking or not * @returns {object|object[]} country specific data */ export function countries(opts?: { country: string | string[]; allowNull: boolean; sort: string; strict: boolean; }): Promise | Promise; /** * Retrieve continent specific data * @param {object} opts object holding the options for that request * @param {string|string[]} opts.continent continent name/s to be queried * @param {boolean} opts.allowNull whether to allow null values (true) or automatically transform them to 0 (false) * @param {string} opts.sort property name which will be used for sorting * @param {boolean} opts.strict whether to use strict name checking or not * @returns {object|object[]} continent specific data */ export function continents(opts?: { continent: string | string[]; allowNull: boolean; sort: string; strict: boolean; }): Promise | Promise; /** * Retrieve state specific data * @param {object} opts object holding the options for that request * @param {string|string[]} opts.state state name/s to be queried * @param {boolean} opts.allowNull whether to allow null values (true) or automatically transform them to 0 (false) * @param {string} opts.sort property name which will be used for sorting * @param {boolean} opts.strict whether to use strict name checking or not * @returns {object|object[]} state specific data */ export function states(opts?: { state: string | string[]; allowNull: boolean; sort: string; strict: boolean; }): Promise | Promise; export namespace yesterday { export function all(opts?: { allowNull: boolean; }): Promise; export function countries(opts?: { country: string | string[]; allowNull: boolean; sort: string; strict: boolean; }): Promise | Promise; export function continents(opts?: { continent: string | string[]; sort: string; strict: boolean; }): Promise | Promise; export function states(opts?: { state: string | string[]; allowNull: boolean; sort: string; strict: boolean; }): Promise | Promise; } export namespace jhucsse { export function all(): Promise; export function counties(opts?: { county: string | string[]; }): Promise | Promise; } export namespace historical { export function all(opts?: { days: string | number; }): Promise; export function countries(opts?: { country: string | string[]; province: string | string[]; days: string | number; }): Promise; } export namespace nyt { export function usa(): Promise; export function states(opts?: { state: string; }): Promise | Promise; export function counties(opts?: { county: string; }): Promise | Promise; } export namespace apple { export function countries(): Promise; export function subregions(country: string): Promise; export function mobilityData(opts?: { country: string; subregion: string | string[]; }): Promise | Promise; } /** * Retrieve official government data * @param {string} country country name to be queried (empty to get an array of names) * @param {boolean} opts.allowNull whether to allow null values (true) or automatically transform them to 0 (false) * @returns {object} official government data */ export function gov(country: string): Promise;