// Type definitions for sprestlib 1.9.0
// Project: https://gitbrent.github.io/SpRestLib/
// Definitions by: Brent Ely
// Jandos
// Kelvin Bell
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
declare namespace sprLib {
const version: string;
interface optionsOptions {
baseUrl?: string;
nodeCookie?: string;
nodeEnabled?: boolean;
nodeServer?: string;
queryLimit?: number;
}
interface IOptions {
baseUrl: string;
nodeCookie?: string;
nodeEnabled?: boolean;
nodeServer?: string;
queryLimit: number;
}
function options(): IOptions;
function options(options: optionsOptions): IOptions;
function baseUrl(): string;
function baseUrl(baseUrl: string): void;
function nodeConfig(options: object): void;
function renewSecurityToken(): void;
interface FileCheckInOptions {
comment?: string;
type?: 'major' | 'minor' | 'overwrite';
}
interface FileInfoOptions {
version?: number;
}
interface IFile {
checkin(options: FileCheckInOptions): Promise;
checkout(): Promise;
delete(): Promise;
get(): Promise;
info(options: FileInfoOptions): Promise