Adding OpenSearch to FriendFeed


A quick 30 second post because it's hard to add markup to FriendFeed comments...

In response to this guide on adding FriendFeed search to your browser, here's the 30 second guide for the FriendFeed guys on how to do it on their own site (not that they need it).

First, download this file and serve it as http://friendfeed.com/opensearch.xml.

<?xml version="1.0" encoding="UTF-8"?>
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
  <ShortName>FriendFeed</ShortName>
  <Description>Search FriendFeed.</Description>
  <Tags>friendfeed</Tags>
  <Contact>admin@friendfeed.com</Contact>
  <Url type="text/html" 
       template="http://friendfeed.com/search?q={searchTerms}"/>
  <Url type="application/atom+xml"
       template="http://friendfeed.com/search?q={searchTerms}&amp;format=atom"/>
  <LongName>FriendFeed Search</LongName>
  <Image height="16" width="16" type="image/vnd.microsoft.icon">http://friendfeed.com/favicon.ico</Image>
  <Query role="example" searchTerms="friendfeed" />
  <Developer>FriendFeed</Developer>
  <Attribution>
    Copyright 2008, FriendFeed, Inc., All Rights Reserved
  </Attribution>
  <SyndicationRight>open</SyndicationRight>
  <AdultContent>false</AdultContent>
  <Language>en-us</Language>
  <OutputEncoding>UTF-8</OutputEncoding>
  <InputEncoding>UTF-8</InputEncoding>
</OpenSearchDescription>


Next, add this snippet to the <head/> section of all pages on FriendFeed:

<link rel="search"
           type="application/opensearchdescription+xml" 
           href="http://friendfeed.com/opensearch.xml"
           title="FriendFeed Search" />


And you're done. But let's talk again once you syndicate search over Atom or RSS and we'll add that, too.

Update: Added the <Url/> element for Atom based search results per Bret's comment below.