function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AndrewTaylorAndrewTaylor 

Calling the Google Search Appliance using Apex

Has anyone integrated with the Google Search Appliance from Salesforce?  I see there is a connector, but it looks like its from the GSA to SFDC, not the other way around?

For example, if I wanted to write a wrapper utility to perform the search from Salesforce, and return the results styled in a VF page, is this a possiblity?

Best Answer chosen by AndrewTaylor
pconpcon
You can do this a couple of ways.  If you want to do it purely from Apex, you will need to make sure that your GSA is accessible from the Internet (or have holes poked through for the Salesforce instance) and then just do a callout [1] from your Visualforce controller to the GSA with your search.  The other option would be to do skip the Visualforce all together and host an HTML page inside of Salesforce that calls your GSA via Javascript and then displays the results.

[1] https://developer.salesforce.com/page/Apex_Web_Services_and_Callouts

All Answers

pconpcon
You can do this a couple of ways.  If you want to do it purely from Apex, you will need to make sure that your GSA is accessible from the Internet (or have holes poked through for the Salesforce instance) and then just do a callout [1] from your Visualforce controller to the GSA with your search.  The other option would be to do skip the Visualforce all together and host an HTML page inside of Salesforce that calls your GSA via Javascript and then displays the results.

[1] https://developer.salesforce.com/page/Apex_Web_Services_and_Callouts
This was selected as the best answer
AndrewTaylorAndrewTaylor
Thank you!
pconpcon
Glad I could help! If you could please choose a "best answer" so that this question can be removed from the unresolved queue and so others may easily find the answer.