Introducing Robots API v2: The Rise of Active Robots

Tuesday, March 2, 2010 | 5:02 AM

Robots are an important part of the Google Wave API, and they've just become a lot more powerful. We've recently released version 2.0 of the robots API, which includes a bunch of new features:

  • Active API: In v2, robots can now push information into waves (without having to wait to respond to a user action). This replaces the need for our deprecated cron API, as now you can update a wave when the weather changes or the stock price falls below some threshold. You can learn more in the Active API docs.
  • Context: Robots can now more precisely specify how much information they want to get back from a particular event. If only the contents of the affected blip needs updating and you want to reduce your robot's bandwidth, then you can specify the new 'SELF' context. On the flip side, if you do need all the information in the wavelet, you can specify the new 'ALL' context. You can learn more in the Context docs.
  • Filtering: In a similar way, with this new API, the robot can specify what events it needs to respond to, conserving valuable bandwidth -- and ignore all those that don't apply. You can learn more in the Filtering Events docs.
  • Error reporting: Robots are now able to register to receive errors about failed operations, such as insertion on non-existent ranges. You can learn more in the Error Reporting docs.
  • Proxying-For: Robots can now convey to Google Wave that their actions are actually on behalf of a different user, via the proxyingFor field. For robots like the Buggy sample, which connects with the Google Code issue tracker, this means that the wave can be updated with attribution to users on non-wave systems. You can learn more in the Proxying-For docs.

To get started with the new API, please check out the basics and download the new client libraries: Java | Python. As part of this new API release, we're also standardizing around a new robot wire protocol. These client libraries are built around this wire protocol, and this protocol specification also opens the door for you to write your own client libraries in your preferred language.

As you're getting started, visit the samples gallery to see what others have built, which includes examples of the new robot API in action: Stocky, Submitty, and Twitter-Searchy.

If you create an amazing extension and think it's ready to share with users, please submit your extension (naturally, we're using a robot to help, but more on that later).

Additionally, as part of this release, we're experimenting with holding discussions about the new API in Google Wave itself. We've actually created a robot to help facilitate these conversations, and you can read more about how to get started with Wave API discussions in the Wave API Forum Botty page. Please continue to file bugs in google-wave-resources.