import * as request from 'request'; export declare const enum Endpoints { Ping = "/ping", ProjectResourceCollection = "/project", ProjectResource = "/project/:project_name", ProjectSnapshotResource = "/project/:project_name/snapshot/:sha", ProjectSnapshotSyndicated = "/project/:project_name/snapshot/:sha/syndicated", ProjectSnapshotAssetResource = "/project/:project_name/snapshot/:sha/asset/:filename", ForkCommunityProject = "/community/:organization_name/:project_name/fork", OrganizationResourceCollection = "/organization", UserDetailResource = "/user/detail", BillingDescribe = "/billing", BillingListProducts = "/billing/products", BillingSetCustomer = "/billing/customer", BillingAddCard = "/billing/card", BillingSetCardAsDefaultById = "/billing/card/:card_id/is_default", BillingDeleteCardById = "/billing/card/:card_id", BillingPlanResource = "/billing/plan", BillingDescribeCoupon = "/billing/coupon/:coupon_id", BillingTaxID = "/billing/tax_id", BillingAddSeats = "/billing/add_seats", Team = "/team", TeamAssignedSeats = "/team/seats", TeamConfirmSeat = "/team/seats/confirm/:verification_unique_id", TeamResendConfirmSeatEmail = "/team/seats/resend-confirmation", TeamAssignSeats = "/team/seats" } export interface UriParams { [parameterName: string]: string; } export interface QueryParams { [parameterName: string]: string | undefined; } export declare type MaybeAuthToken = string | undefined; export declare class RequestBuilder { private readonly method; private url; private json; private readonly queryParams; private readonly headers; private setAuthToken; constructor(method: (options: request.OptionsWithUrl, cb: request.RequestCallback) => void); withEndpoint(endpoint: Endpoints): this; withUrlParameters(params: UriParams): this; /** * @deprecated - prefer config-based and/or cookie-based auth tokens! */ withAuthToken(authToken: MaybeAuthToken): this; withJson(json: any): this; withQueryParams(params: QueryParams): this; readonly fullUrl: string; readonly fullHeaders: request.Headers; call(cb: request.RequestCallback): void; callWithCallback(cb: (err: Error, data: T, response: request.RequestResponse) => void, successCode?: number): void; } export declare const newGetRequest: () => RequestBuilder; export declare const newPostRequest: () => RequestBuilder; export declare const newPutRequest: () => RequestBuilder; export declare const newDeleteRequest: () => RequestBuilder;