New Google Wave Robot API v2

Finally there is an update to the Google Wave robot API. In the blog Introducing Robots API v2: The Rise of Active Robots the new features are described.

It is really nice to see that a lot of new features has been delivered. It is a long time since the last release of any updates on the API, so it looked like the development or patching had stopped. But this new release solves many of the problems that have exists. I have written my comments to all to all of the functions.

  • 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.

This features is really useful for enterprise contexts, where it is required that you will be able to update the wave based on external events. With this features you can get a new Wave, when something happens that you need to react to. From the SAP perspective there is Universal Worklist where all events that you have to process are. With this Wave you can achieve some of the same ideas.

  • 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.

With this enhancement it will be much easier for robots to interact with the wave, because they can get a much better control of what the data is need in each instance. This will make the development easier because you got the date that you need and it will specify the data you need.

  • 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.

With this function you will only get the events that you need in your robots. Simply create a regular expression and then only the entries matching the expression is sent. This is quite useful if you only want events, when a large number of capital letters is written.

  • 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.

This function will make it possible to make better and more stabile robots. The use requires that you work, how the robot should interact when an error is created.

  • 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.

I can see that this function will be really interesting when working with one place to monitor all of your solution. It will also make collaboration with external partners much easier.

With all of this information it looks like the robots have been much more decentralized and acts as regular clients. So in the principle the new features will allow you to create a client to Wave using the robot API and some proxy functionality.

There is still room for improvements in the API. This is the two things that I see that currently are missing.

  • Better form handling and the ability to apply styles to the forms, so they don’t look as 90ish.
  • UPDATE: This is also possible. Integration with Gadgets, so the robots can update the gadgets with new information. With the Active API is this even more interesting. It is now possible to update the statistic gadget when you get a new expression.

Pamela Fox has created a great presentation describing what how the features connect.

Bookmark and Share

New Robot API

Just found that a new JAVA API of the robots is available on the download site. The difference in the code can be seen on the changes page.

One interesting concept is the AbstractRobot which has been added. From my look at it this class gives is able to create the capabilities XML and the profile information. So you only need to implement one class and then you can have all the information you need one place. This will make it much easier to program robots. The Rave Ruby frameworks has something like this, you just implement the methods for each event you want to have. Then the framework can manage to create the capabilities XML file. The AbstractRobotServlet and ProfileServlet was not changed, this could lead to thoughts about deprecation of these classes.

Of other changes the Annotations and Range has better toString functions, which was missing when you needed to debug applications.

I hope there will be posted a change to the tutorial, so we can start using the AbstractRobot instead.

Bookmark and Share

Coming changes to Google Wave API

Tommy Pedersen shared the link to what is coming in the API.

It looks like the developer preview will stop on September 30th, and then we must hope we can get an account on the production system. So we will not float without wave access for a long time.

What is interesting is that Douwe Osinga from Google is sharing, what they believe they can achieve before the end of the developer preview.

The things I think is the most exciting news are the following:

  • The Robots can use other addresses that name@appspot.com. That could mean you could have more robots on the same application making the robots tailored to the user. Also we will see that robots will exist on our own servers and not app-engine.
  • A better integration between robots in to Wave, so they robot can perform tasks even the wave is not active by a user.
  • Gadgets better support for using Google Web Toolkit, will make it easier for everyone (how is not a Javascript master) to make Gadgets. This is probably lower the barrier to create Gadgets.
  • OpenSocial integration for both robots and gadgets. That is something that I’ll need to look more into.
  • Insert simple HTML into the waves. This is not possible now, so the robots can make some better looking content easy. Then we need to consider using CSS on the document.
  • Open source the robot API it does not matter much now, but for the adoption that will probably make things easier.

I’m impressed with the plan Google has created for the development of the Google Wave API. I hope they have made some of the improvements already otherwise they will have a hard time implementing them all.

Bookmark and Share