Skip to content

Latest commit

 

History

History
55 lines (45 loc) · 1.73 KB

extend_doc.md

File metadata and controls

55 lines (45 loc) · 1.73 KB

Query

Returns results for a specified SOQL query.

Forrest::query('SELECT Id FROM Account');

Query Explain

Returns details of how Salesforce will process your query. Available for API verison 30.0 or later.

Forrest::queryExplain('SELECT Id FROM Account');

Query All

Returns results for a specified SOQL query, but will also inlcude deleted records.

Forrest::queryAll('SELECT Id FROM Account');

Search

Returns the specified SOSL query

Forrest::search('Find {foo}');

Scope Order

Global search keeps track of which objects the user interacts with and arranges them when the user performs a global search. This call will return this ordered list of objects.

Forrest::scopeOrder();

Search Layouts

Returns the search results layout for the objects in the query string. List should be formatted as a string, but delimited by a comma.

Forrest::searchLayouts('Account,Contact,Lead');

Suggested Articles

Returns a list of Salesforce Knowledge articles based on the a search query. Pass additional parameters into the second argument. Available for API verison 30.0 or later.

Salesforce Knowledge must be enabled for this to work.

Forrest::suggestedArticles('foo', [
    'parameters' => [
        'channel' => 'App',
        'publishStatus' => 'Draft']]);

Suggested Queries

Returns a list of suggested searches based on a search text query. Matches search queries that other users have performed in Salesforce Knowledge. Like Suggest Articles, additional parameters can be passed into the second argument with the parameters key. Available for API version 30.0 or later.

Forrest::suggestedQueries('app, [
    'parameters' => ['foo' => 'bar']]);