Integration via APIs
In general, integration via APIs is identical. The following graphic shows this schmematically:
Serverscript is an application or code which is placed between the FACT-Finder search server and the destination pages. It governs the communication between the two. This part has to be generated before an API-Integration.
The steps are as follows:
- Search query is sent to FACT-Finder: The search parameters entered in the search box by the user (query) must be sent to the FACT-Finder search server by means of an HTTP request (request).
- Search results are received (response): The FACT-Finder search server delivers the search results via an XML response.
- Search results are processed: the returned XML must be interpreted (parsed) by the shopping system.
- Search results page is generated (display): the structure of the HTML display of the search results page must be based on the search results information that is delivered.
The most important difference between this method and the Web Components result is that the design of the search results page is created by the shop. In this way the design is centrally managed and does not need to be monitored and corrected at multiple locations.
XML and JSON
During integration via XML and JSON interfaces, the search parameters are handed over from the shop to the FACT-Finder search server in form of an URL. FACT-Finder answers that query in a specific format (XML or JSON), which contains all information necessary to generate a search results page.
For both variants, pattern definitions exist which specify the return format.
REST
From version 7.3 onwards, FACT-FInder offers a REST-Interfave for API-Integration. It is most similar to XML and JSON-API and is able to return both formats.
Webservice / SOAP
Webservices are standardised communication interfaces for distributed applications. With SOAP-API, communication is managed via objects, so no URL has to be generated. Instead, code-objects are used. The FACT-Finder search server returns these objects.