import { Query, QueryResult, RecordResult } from 'jsforce'; import { Logger } from '@salesforce/core'; import { ConnectionConfig, PlatformEvent, SObject } from './..'; export { Query, QueryResult, Connection, RecordResult, SuccessResult, ErrorResult } from 'jsforce'; export declare class DataApi { private connConfig; private logger; private conn; constructor(connConfig: ConnectionConfig, logger: Logger); /** * Execute the given SOQL by using "/query" API. * See [jsforce types](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsforce) for details on Query and QueryResult * * @param soql - SOQL to be executed. * @return Query> */ query(soql: string): Query>; /** * Query further records using nextRecordsURL. * See [jsforce types](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsforce) for details on QueryResult * * @param locator - query locator. * @return Promise> */ queryMore(locator: string): Promise>; /** * Insert an SObject. * See [jsforce types](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsforce) for details on RecordResult * * @param sobject - sobject to insert * @returns Promise<(RecordResult)> */ insert(sobject: SObject): Promise; /** * Update an SObject. * See [jsforce types](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsforce) for details on RecordResult * * @param sobject - sobject to update * @returns Promise */ update(sobject: SObject): Promise; /** * Publish Platform Event. * See [jsforce types](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsforce) for details on RecordResult * * @param event - Platform Event to insert * @returns Promise<(RecordResult)> */ publishPlatformEvent(event: PlatformEvent): Promise; /** * Invoke given endpoint. * * Endpoint can be: * - absolute URL, * - relative path from root ('/services/data/v32.0/sobjects/Account/describe'), or * - relative path from version root ('/sobjects/Account/describe'). * * @param method * @param url * @param body * @param headers */ request(method: string, url: string, body: string, headers?: object): Promise; private connect; }