function post(type, content) {
      var message;
      // Message object can be constructed from 'type' and 'content' arguments or it can be passed
      // as the first argument.
      if (arguments.length === 1 && typeof type === 'object' && typeof type.type === 'string') {