SharePoint Add-in Recipe - Search Configuration
PnP guidance, rest api, Search, SharePoint Add-in model, SharePoint Client-side Object Model (CSOM)
The approach you take to configure search is different in the new SharePoint Add-in model than it was with Full Trust Code. In a typical Full Trust Code (FTC) / Farm Solution scenario, the SharePoint Server-side Object Model was used to configure search, and deployed via SharePoint Solutions.
In a SharePoint Add-in model scenario, you use the SharePoint Client-side Object Model (CSOM) or REST API to configure search. This pattern is commonly referred to as the remote provisioning pattern.
You can read the rest of this Office 365 Patterns and Practices Guidance article on GitHub, here: https://github.com/OfficeDev/PnP-Guidance/blob/master/articles/SharePoint-Add-In-Recipe-search-configuration.md