<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>has_many :thoughts: Highrise API and tagging</title>
    <link>http://blog.kineticweb.com/articles/2008/02/18/highrise-api-and-tagging</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Musings from a Ruby on Rails development team</description>
    <item>
      <title>Highrise API and tagging</title>
      <description>&lt;p&gt;Like &lt;a href="http://forum.37signals.com/highrise/forums/15/topics/1312"&gt;many&lt;/a&gt;, I was disappointed that the &lt;a href="http://www.highrisehq.com/"&gt;Highrise&lt;/a&gt; &lt;a href="http://developer.37signals.com/highrise/"&gt;&lt;span class="caps"&gt;API&lt;/span&gt;&lt;/a&gt; does not support tagging of people. However, I found a way to easily add the capability to the 37signals-supplied Ruby wrapper class, even if it is unsupported. I added a &lt;code&gt;#tag!&lt;/code&gt; instance method to the Person class and used a call directly to the site, not through the &lt;span class="caps"&gt;API&lt;/span&gt;.&lt;/p&gt;


&lt;pre&gt;
class Person &amp;lt; Subject
  ...
  def tag!(tag_name)
    `curl -s -d 'name=#{tag_name}' #{ENV['HIGHRISE_URL']}parties/#{id}/tags`
  end
end
&lt;/pre&gt;

	&lt;p&gt;The output is a bunch of javascript to update the page to reflect the change, but one can safely ignore this. The tag is added and everything works great. Not sure how well this would work on Windows, as the &lt;code&gt;curl&lt;/code&gt; command-line program is likely unavailable.&lt;/p&gt;


	&lt;p&gt;We use this method in our latest project to add appropriate tags to people as they are created. It helps us segment people added to Highrise for the project from the rest of our contacts in Highrise.&lt;/p&gt;</description>
      <pubDate>Mon, 18 Feb 2008 13:28:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:8162daad-bcb1-4b7f-a3df-e1c8c8a840e0</guid>
      <author>Colin A. Bartlett</author>
      <link>http://blog.kineticweb.com/articles/2008/02/18/highrise-api-and-tagging</link>
      <category>highrise</category>
      <category>ruby</category>
      <category>Rails</category>
      <category>37signals</category>
    </item>
    <item>
      <title>"Highrise API and tagging" by Gamer</title>
      <description>Ruby is so powerful..nice mods</description>
      <pubDate>Wed, 05 Mar 2008 15:40:13 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:1aae9b7e-5a36-4084-b371-de3c7fb3abb0</guid>
      <link>http://blog.kineticweb.com/articles/2008/02/18/highrise-api-and-tagging#comment-241</link>
    </item>
    <item>
      <title>"Highrise API and tagging" by Randy</title>
      <description>Nice! You could use net/http instead of curl to make it less dependent on a platform that has curl.</description>
      <pubDate>Mon, 18 Feb 2008 13:57:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:336415d9-2c6b-4acb-bb29-c0135f620670</guid>
      <link>http://blog.kineticweb.com/articles/2008/02/18/highrise-api-and-tagging#comment-234</link>
    </item>
  </channel>
</rss>
