cancel
Showing results for 
Search instead for 
Did you mean: 

OpenSearch Configuration Schema

kbpair
Champ in-the-making
Champ in-the-making
I am trying to get OpenSearch to hit some of our other data repositories (Confluence, Sharepoint, Documentum) as it will take time to convert these to Alfresco 😉

I have seen the wiki and the sample file but none of these pass parameters during a POST. The parameters are in the querystring.

How can I configure my web-api-config-custom.xml?

For instance the OpenSearch Description spec generated by the firefox plugin shows something like:

<SearchForm>http://www.example.com/dashboard.action</SearchForm>
<os:Url type="text/html" method="POST" template="http://www.example.com//dosearchsite.action">
  <os:Param name="quickSearch" value="true"/>
  <os:Param name="searchQuery.spaceKey" value="conf_global"/>
  <os:Param name="searchQuery.queryString" value="{searchTerms}"/>
  <os:Param name="sourceid" value="Mozilla-search"/>
</os:Url>

So I need to convert this to something understood by Alfresco in the web-api-config-custom.xml:

<engine label-id="confluence" label="Confluence Keyword Search">
     <url type="text/html">http://www.example.com/dosearchsite.action</url>
</engine>

Is there a schema of what the valid elements/attributes are?

thanks for your help.
2 REPLIES 2

gavinc
Champ in-the-making
Champ in-the-making
I'm not sure we support POST requests for OpenSearch out of the box (I maybe corrected when our resident expert returns from holiday next week).

Depending on how the destination service deals with parameters you maybe able to formulate the request as a GET request, in which case you'd enter the following as the URL:

<url type="text/html">http://www.example.com/dosearchsite.action?quickSearch=true&searchQuery.spaceKey=conf_global&searchQ...</url>

davidc
Star Contributor
Star Contributor
We don't yet support OpenSearch engines that accept POST requests.  I'm not sure there are many at this time.

In any case, I not aware of Documentum, Sharepoint etc supporting OpenSearch out of the box, so you may have to implement the OpenSearch api anyway, in which case support GET.