Executes a query and auto-fetches (i.e., "queryMore") all results. This is especially useful with large query result sizes, such as over 2000 records. The default maximum fetch size is 10,000 records. Modify this via the options argument.
The SOQL string.
The query options. NOTE: the autoFetch option will always be true.
The Force API base url for the instance.
deploy a zipped buffer from the SDRL with REST or SOAP
data to deploy
JSForce deploy options + a boolean for rest
Get the API version used for all connection requests.
Getter for AuthInfo.
Getter for the AuthInfo fields.
Getter for the auth fields.
Getter for the username of the Salesforce Org.
Async initializer.
Verify that instance has a reachable DNS entry, otherwise will throw error
Returns true if this connection is using access token auth.
Normalize a Salesforce url to include a instance information.
Partial url.
Executes a GET request on the baseUrl to force an auth refresh. This is useful for the raw methods (request, requestRaw) that use the accessToken directly and don't handle refreshes.
This method issues a request using the current access token to check if it is still valid. If the request returns 200, no refresh happens, and we keep the token. If it returns 401, jsforce will request a new token and set it in the connection instance.
Send REST API request with given HTTP request info, with connected session information and SFDX headers.
HTTP request object or URL to GET request.
Optionaloptions: JsonMap
HTTP API request options.
Retrieves the highest api version that is supported by the target server instance.
Set the API version for all connection requests.
Throws SfError{ name: 'IncorrectAPIVersionError' } Incorrect API version.
The API version.
Executes a query using either standard REST or Tooling API, returning a single record. Will throw if either zero records are found OR multiple records are found.
The SOQL string.
The query options.
Use the latest API version available on this.instanceUrl.
StaticcreateCreates an instance of a Connection. Performs additional async initializations.
Constructor options.
Handles connections and requests to Salesforce Orgs.