Commits

Anonymous committed 1919c35

atualizado evernote api para 1.15

Comments (0)

Files changed (7)

-- Evernote API 1.14
+- Evernote API 1.15

evernote/edam/notestore/NoteStore-remote

   print '   getNoteTagNames(string authenticationToken, Guid guid)'
   print '  Note createNote(string authenticationToken, Note note)'
   print '  Note updateNote(string authenticationToken, Note note)'
+  print '  i32 deleteNote(string authenticationToken, Guid guid)'
   print '  i32 expungeNote(string authenticationToken, Guid guid)'
   print '  i32 expungeNotes(string authenticationToken,  noteGuids)'
   print '  i32 expungeInactiveNotes(string authenticationToken)'
   print '  Note copyNote(string authenticationToken, Guid noteGuid, Guid toNotebookGuid)'
+  print '   listNoteVersions(string authenticationToken, Guid noteGuid)'
+  print '  Note getNoteVersion(string authenticationToken, Guid noteGuid, i32 updateSequenceNum, bool withResourcesData, bool withResourcesRecognition, bool withResourcesAlternateData)'
   print '  Resource getResource(string authenticationToken, Guid guid, bool withData, bool withRecognition, bool withAttributes, bool withAlternateData)'
   print '  i32 updateResource(string authenticationToken, Resource resource)'
   print '  string getResourceData(string authenticationToken, Guid guid)'
     sys.exit(1)
   pp.pprint(client.updateNote(args[0],eval(args[1]),))
 
+elif cmd == 'deleteNote':
+  if len(args) != 2:
+    print 'deleteNote requires 2 args'
+    sys.exit(1)
+  pp.pprint(client.deleteNote(args[0],eval(args[1]),))
+
 elif cmd == 'expungeNote':
   if len(args) != 2:
     print 'expungeNote requires 2 args'
     sys.exit(1)
   pp.pprint(client.copyNote(args[0],eval(args[1]),eval(args[2]),))
 
+elif cmd == 'listNoteVersions':
+  if len(args) != 2:
+    print 'listNoteVersions requires 2 args'
+    sys.exit(1)
+  pp.pprint(client.listNoteVersions(args[0],eval(args[1]),))
+
+elif cmd == 'getNoteVersion':
+  if len(args) != 6:
+    print 'getNoteVersion requires 6 args'
+    sys.exit(1)
+  pp.pprint(client.getNoteVersion(args[0],eval(args[1]),eval(args[2]),eval(args[3]),eval(args[4]),eval(args[5]),))
+
 elif cmd == 'getResource':
   if len(args) != 6:
     print 'getResource requires 6 args'

evernote/edam/notestore/NoteStore.py

 
   def expungeNotebook(self, authenticationToken, guid):
     """
-    Permanently removes the notebook, and all of its content notes,
-    from the service.  After this action, the notebook is no longer
-    available for undeletion, etc.
+    Permanently removes the notebook from the user's account.
+    After this action, the notebook is no longer available for undeletion, etc.
+    If the notebook contains any Notes, they will be moved to the current
+    default notebook and moved into the trash (i.e. Note.active=false).
     
     @param guid
       The GUID of the notebook to delete.
       </li>
       <li> BAD_DATA_FORMAT "NoteFilter.words" - if search string too long
       </li>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Notebook.guid" - not found, by GUID
+      </li>
     </ul>
     
     Parameters:
       </li>
       <li> BAD_DATA_FORMAT "NoteFilter.words" - if search string too long
       </li>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Notebook.guid" - not found, by GUID
+      </li>
     </ul>
     
     Parameters:
     """
     pass
 
+  def deleteNote(self, authenticationToken, guid):
+    """
+    Moves the note into the trash. The note may still be undeleted, unless it
+    is expunged.  This is equivalent to calling udpateNote() after setting
+    Note.active = false
+    
+    @param guid
+      The GUID of the note to delete.
+    
+    @return
+      The Update Sequence Number for this change within the account.
+    
+    @throws EDAMUserException <ul>
+      <li> PERMISSION_DENIED "Note" - user doesn't have permission to
+             update the note.
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - guid
+    """
+    pass
+
   def expungeNote(self, authenticationToken, guid):
     """
     Permanently removes the Note, and all of its Resources,
 
   def copyNote(self, authenticationToken, noteGuid, toNotebookGuid):
     """
-    Performs a deep copy of the Note with the provied GUID 'noteGuid' into
+    Performs a deep copy of the Note with the provided GUID 'noteGuid' into
     the Notebook with the provided GUID 'toNotebookGuid'.
     The caller must be the owner of both the Note and the Notebook.
     This creates a new Note in the destination Notebook with new content and
     """
     pass
 
+  def listNoteVersions(self, authenticationToken, noteGuid):
+    """
+    Returns a list of the prior versions of a particular note that are
+    saved within the service.  These prior versions are stored to provide a
+    recovery from unintentional removal of content from a note. The identifiers
+    that are returned by this call can be used with getNoteVersion to retrieve
+    the previous note.
+    
+    @throws EDAMUserException <ul>
+      <li> BAD_DATA_FORMAT "Note.guid" - if the parameter is missing
+      </li>
+      <li> PERMISSION_DENIED "Note" - private note, user doesn't own
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - noteGuid
+    """
+    pass
+
+  def getNoteVersion(self, authenticationToken, noteGuid, updateSequenceNum, withResourcesData, withResourcesRecognition, withResourcesAlternateData):
+    """
+    This can be used to retrieve a previous version of a Note after it has been
+    updated within the service.  The caller must identify the note (via its
+    guid) and the version (via the updateSequenceNumber of that version).
+    to find a listing of the stored version USNs for a note, call
+    listNoteVersions.
+    This call is only available for notes in Premium accounts.  (I.e. access
+    to past versions of Notes is a Premium-only feature.)
+    
+    @param guid
+      The GUID of the note to be retrieved.
+    
+    @param updateSequenceNum
+      The USN of the version of the note that is being retrieved
+    
+    @param withResourcesData
+      If true, any Resource elements in this Note will include the binary
+      contents of their 'data' field's body.
+    
+    @param withResourcesRecognition
+      If true, any Resource elements will include the binary contents of the
+      'recognition' field's body if recognition data is present.
+    
+    @param withResourcesAlternateData
+      If true, any Resource elements in this Note will include the binary
+      contents of their 'alternateData' fields' body, if an alternate form
+      is present.
+    
+    @throws EDAMUserException <ul>
+      <li> BAD_DATA_FORMAT "Note.guid" - if the parameter is missing
+      </li>
+      <li> PERMISSION_DENIED "Note" - private note, user doesn't own
+      </li>
+      <li> PERMISSION_DENIED "updateSequenceNum" -
+        The account isn't permitted to access previous versions of notes.
+        (i.e. this is a Free account.)
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+      <li> "Note.updateSequenceNumber" - the Note doesn't have a version with
+         the corresponding USN.
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - noteGuid
+     - updateSequenceNum
+     - withResourcesData
+     - withResourcesRecognition
+     - withResourcesAlternateData
+    """
+    pass
+
   def getResource(self, authenticationToken, guid, withData, withRecognition, withAttributes, withAlternateData):
     """
     Returns the current state of the resource in the service with the
       <li> DATA_REQUIRED "NoteEmailParameters.toAddresses" -
         if there are no To: or Cc: addresses provided.
       </li>
+      <li> DATA_REQUIRED "Note.title" -
+        if the caller provides a Note parameter with no title
+      </li>
+      <li> DATA_REQUIRED "Note.content" -
+        if the caller provides a Note parameter with no content
+      </li>
       <li> DATA_REQUIRED "NoteEmailParameters.note" -
         if no guid or note provided
       </li>
 
   def expungeNotebook(self, authenticationToken, guid):
     """
-    Permanently removes the notebook, and all of its content notes,
-    from the service.  After this action, the notebook is no longer
-    available for undeletion, etc.
+    Permanently removes the notebook from the user's account.
+    After this action, the notebook is no longer available for undeletion, etc.
+    If the notebook contains any Notes, they will be moved to the current
+    default notebook and moved into the trash (i.e. Note.active=false).
     
     @param guid
       The GUID of the notebook to delete.
       </li>
       <li> BAD_DATA_FORMAT "NoteFilter.words" - if search string too long
       </li>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Notebook.guid" - not found, by GUID
+      </li>
     </ul>
     
     Parameters:
       raise result.userException
     if result.systemException != None:
       raise result.systemException
+    if result.notFoundException != None:
+      raise result.notFoundException
     raise TApplicationException(TApplicationException.MISSING_RESULT, "findNotes failed: unknown result");
 
   def findNoteCounts(self, authenticationToken, filter, withTrash):
       </li>
       <li> BAD_DATA_FORMAT "NoteFilter.words" - if search string too long
       </li>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Notebook.guid" - not found, by GUID
+      </li>
     </ul>
     
     Parameters:
       raise result.userException
     if result.systemException != None:
       raise result.systemException
+    if result.notFoundException != None:
+      raise result.notFoundException
     raise TApplicationException(TApplicationException.MISSING_RESULT, "findNoteCounts failed: unknown result");
 
   def getNote(self, authenticationToken, guid, withContent, withResourcesData, withResourcesRecognition, withResourcesAlternateData):
       raise result.notFoundException
     raise TApplicationException(TApplicationException.MISSING_RESULT, "updateNote failed: unknown result");
 
+  def deleteNote(self, authenticationToken, guid):
+    """
+    Moves the note into the trash. The note may still be undeleted, unless it
+    is expunged.  This is equivalent to calling udpateNote() after setting
+    Note.active = false
+    
+    @param guid
+      The GUID of the note to delete.
+    
+    @return
+      The Update Sequence Number for this change within the account.
+    
+    @throws EDAMUserException <ul>
+      <li> PERMISSION_DENIED "Note" - user doesn't have permission to
+             update the note.
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - guid
+    """
+    self.send_deleteNote(authenticationToken, guid)
+    return self.recv_deleteNote()
+
+  def send_deleteNote(self, authenticationToken, guid):
+    self._oprot.writeMessageBegin('deleteNote', TMessageType.CALL, self._seqid)
+    args = deleteNote_args()
+    args.authenticationToken = authenticationToken
+    args.guid = guid
+    args.write(self._oprot)
+    self._oprot.writeMessageEnd()
+    self._oprot.trans.flush()
+
+  def recv_deleteNote(self, ):
+    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
+    if mtype == TMessageType.EXCEPTION:
+      x = TApplicationException()
+      x.read(self._iprot)
+      self._iprot.readMessageEnd()
+      raise x
+    result = deleteNote_result()
+    result.read(self._iprot)
+    self._iprot.readMessageEnd()
+    if result.success != None:
+      return result.success
+    if result.userException != None:
+      raise result.userException
+    if result.systemException != None:
+      raise result.systemException
+    if result.notFoundException != None:
+      raise result.notFoundException
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteNote failed: unknown result");
+
   def expungeNote(self, authenticationToken, guid):
     """
     Permanently removes the Note, and all of its Resources,
 
   def copyNote(self, authenticationToken, noteGuid, toNotebookGuid):
     """
-    Performs a deep copy of the Note with the provied GUID 'noteGuid' into
+    Performs a deep copy of the Note with the provided GUID 'noteGuid' into
     the Notebook with the provided GUID 'toNotebookGuid'.
     The caller must be the owner of both the Note and the Notebook.
     This creates a new Note in the destination Notebook with new content and
       raise result.notFoundException
     raise TApplicationException(TApplicationException.MISSING_RESULT, "copyNote failed: unknown result");
 
+  def listNoteVersions(self, authenticationToken, noteGuid):
+    """
+    Returns a list of the prior versions of a particular note that are
+    saved within the service.  These prior versions are stored to provide a
+    recovery from unintentional removal of content from a note. The identifiers
+    that are returned by this call can be used with getNoteVersion to retrieve
+    the previous note.
+    
+    @throws EDAMUserException <ul>
+      <li> BAD_DATA_FORMAT "Note.guid" - if the parameter is missing
+      </li>
+      <li> PERMISSION_DENIED "Note" - private note, user doesn't own
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - noteGuid
+    """
+    self.send_listNoteVersions(authenticationToken, noteGuid)
+    return self.recv_listNoteVersions()
+
+  def send_listNoteVersions(self, authenticationToken, noteGuid):
+    self._oprot.writeMessageBegin('listNoteVersions', TMessageType.CALL, self._seqid)
+    args = listNoteVersions_args()
+    args.authenticationToken = authenticationToken
+    args.noteGuid = noteGuid
+    args.write(self._oprot)
+    self._oprot.writeMessageEnd()
+    self._oprot.trans.flush()
+
+  def recv_listNoteVersions(self, ):
+    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
+    if mtype == TMessageType.EXCEPTION:
+      x = TApplicationException()
+      x.read(self._iprot)
+      self._iprot.readMessageEnd()
+      raise x
+    result = listNoteVersions_result()
+    result.read(self._iprot)
+    self._iprot.readMessageEnd()
+    if result.success != None:
+      return result.success
+    if result.userException != None:
+      raise result.userException
+    if result.systemException != None:
+      raise result.systemException
+    if result.notFoundException != None:
+      raise result.notFoundException
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "listNoteVersions failed: unknown result");
+
+  def getNoteVersion(self, authenticationToken, noteGuid, updateSequenceNum, withResourcesData, withResourcesRecognition, withResourcesAlternateData):
+    """
+    This can be used to retrieve a previous version of a Note after it has been
+    updated within the service.  The caller must identify the note (via its
+    guid) and the version (via the updateSequenceNumber of that version).
+    to find a listing of the stored version USNs for a note, call
+    listNoteVersions.
+    This call is only available for notes in Premium accounts.  (I.e. access
+    to past versions of Notes is a Premium-only feature.)
+    
+    @param guid
+      The GUID of the note to be retrieved.
+    
+    @param updateSequenceNum
+      The USN of the version of the note that is being retrieved
+    
+    @param withResourcesData
+      If true, any Resource elements in this Note will include the binary
+      contents of their 'data' field's body.
+    
+    @param withResourcesRecognition
+      If true, any Resource elements will include the binary contents of the
+      'recognition' field's body if recognition data is present.
+    
+    @param withResourcesAlternateData
+      If true, any Resource elements in this Note will include the binary
+      contents of their 'alternateData' fields' body, if an alternate form
+      is present.
+    
+    @throws EDAMUserException <ul>
+      <li> BAD_DATA_FORMAT "Note.guid" - if the parameter is missing
+      </li>
+      <li> PERMISSION_DENIED "Note" - private note, user doesn't own
+      </li>
+      <li> PERMISSION_DENIED "updateSequenceNum" -
+        The account isn't permitted to access previous versions of notes.
+        (i.e. this is a Free account.)
+      </li>
+    </ul>
+    
+    @throws EDAMNotFoundException <ul>
+      <li> "Note.guid" - not found, by GUID
+      </li>
+      <li> "Note.updateSequenceNumber" - the Note doesn't have a version with
+         the corresponding USN.
+      </li>
+    </ul>
+    
+    Parameters:
+     - authenticationToken
+     - noteGuid
+     - updateSequenceNum
+     - withResourcesData
+     - withResourcesRecognition
+     - withResourcesAlternateData
+    """
+    self.send_getNoteVersion(authenticationToken, noteGuid, updateSequenceNum, withResourcesData, withResourcesRecognition, withResourcesAlternateData)
+    return self.recv_getNoteVersion()
+
+  def send_getNoteVersion(self, authenticationToken, noteGuid, updateSequenceNum, withResourcesData, withResourcesRecognition, withResourcesAlternateData):
+    self._oprot.writeMessageBegin('getNoteVersion', TMessageType.CALL, self._seqid)
+    args = getNoteVersion_args()
+    args.authenticationToken = authenticationToken
+    args.noteGuid = noteGuid
+    args.updateSequenceNum = updateSequenceNum
+    args.withResourcesData = withResourcesData
+    args.withResourcesRecognition = withResourcesRecognition
+    args.withResourcesAlternateData = withResourcesAlternateData
+    args.write(self._oprot)
+    self._oprot.writeMessageEnd()
+    self._oprot.trans.flush()
+
+  def recv_getNoteVersion(self, ):
+    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
+    if mtype == TMessageType.EXCEPTION:
+      x = TApplicationException()
+      x.read(self._iprot)
+      self._iprot.readMessageEnd()
+      raise x
+    result = getNoteVersion_result()
+    result.read(self._iprot)
+    self._iprot.readMessageEnd()
+    if result.success != None:
+      return result.success
+    if result.userException != None:
+      raise result.userException
+    if result.systemException != None:
+      raise result.systemException
+    if result.notFoundException != None:
+      raise result.notFoundException
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "getNoteVersion failed: unknown result");
+
   def getResource(self, authenticationToken, guid, withData, withRecognition, withAttributes, withAlternateData):
     """
     Returns the current state of the resource in the service with the
       <li> DATA_REQUIRED "NoteEmailParameters.toAddresses" -
         if there are no To: or Cc: addresses provided.
       </li>
+      <li> DATA_REQUIRED "Note.title" -
+        if the caller provides a Note parameter with no title
+      </li>
+      <li> DATA_REQUIRED "Note.content" -
+        if the caller provides a Note parameter with no content
+      </li>
       <li> DATA_REQUIRED "NoteEmailParameters.note" -
         if no guid or note provided
       </li>
     self._processMap["getNoteTagNames"] = Processor.process_getNoteTagNames
     self._processMap["createNote"] = Processor.process_createNote
     self._processMap["updateNote"] = Processor.process_updateNote
+    self._processMap["deleteNote"] = Processor.process_deleteNote
     self._processMap["expungeNote"] = Processor.process_expungeNote
     self._processMap["expungeNotes"] = Processor.process_expungeNotes
     self._processMap["expungeInactiveNotes"] = Processor.process_expungeInactiveNotes
     self._processMap["copyNote"] = Processor.process_copyNote
+    self._processMap["listNoteVersions"] = Processor.process_listNoteVersions
+    self._processMap["getNoteVersion"] = Processor.process_getNoteVersion
     self._processMap["getResource"] = Processor.process_getResource
     self._processMap["updateResource"] = Processor.process_updateResource
     self._processMap["getResourceData"] = Processor.process_getResourceData
       result.userException = userException
     except evernote.edam.error.ttypes.EDAMSystemException, systemException:
       result.systemException = systemException
+    except evernote.edam.error.ttypes.EDAMNotFoundException, notFoundException:
+      result.notFoundException = notFoundException
     oprot.writeMessageBegin("findNotes", TMessageType.REPLY, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
       result.userException = userException
     except evernote.edam.error.ttypes.EDAMSystemException, systemException:
       result.systemException = systemException
+    except evernote.edam.error.ttypes.EDAMNotFoundException, notFoundException:
+      result.notFoundException = notFoundException
     oprot.writeMessageBegin("findNoteCounts", TMessageType.REPLY, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.writeMessageEnd()
     oprot.trans.flush()
 
+  def process_deleteNote(self, seqid, iprot, oprot):
+    args = deleteNote_args()
+    args.read(iprot)
+    iprot.readMessageEnd()
+    result = deleteNote_result()
+    try:
+      result.success = self._handler.deleteNote(args.authenticationToken, args.guid)
+    except evernote.edam.error.ttypes.EDAMUserException, userException:
+      result.userException = userException
+    except evernote.edam.error.ttypes.EDAMSystemException, systemException:
+      result.systemException = systemException
+    except evernote.edam.error.ttypes.EDAMNotFoundException, notFoundException:
+      result.notFoundException = notFoundException
+    oprot.writeMessageBegin("deleteNote", TMessageType.REPLY, seqid)
+    result.write(oprot)
+    oprot.writeMessageEnd()
+    oprot.trans.flush()
+
   def process_expungeNote(self, seqid, iprot, oprot):
     args = expungeNote_args()
     args.read(iprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
 
+  def process_listNoteVersions(self, seqid, iprot, oprot):
+    args = listNoteVersions_args()
+    args.read(iprot)
+    iprot.readMessageEnd()
+    result = listNoteVersions_result()
+    try:
+      result.success = self._handler.listNoteVersions(args.authenticationToken, args.noteGuid)
+    except evernote.edam.error.ttypes.EDAMUserException, userException:
+      result.userException = userException
+    except evernote.edam.error.ttypes.EDAMSystemException, systemException:
+      result.systemException = systemException
+    except evernote.edam.error.ttypes.EDAMNotFoundException, notFoundException:
+      result.notFoundException = notFoundException
+    oprot.writeMessageBegin("listNoteVersions", TMessageType.REPLY, seqid)
+    result.write(oprot)
+    oprot.writeMessageEnd()
+    oprot.trans.flush()
+
+  def process_getNoteVersion(self, seqid, iprot, oprot):
+    args = getNoteVersion_args()
+    args.read(iprot)
+    iprot.readMessageEnd()
+    result = getNoteVersion_result()
+    try:
+      result.success = self._handler.getNoteVersion(args.authenticationToken, args.noteGuid, args.updateSequenceNum, args.withResourcesData, args.withResourcesRecognition, args.withResourcesAlternateData)
+    except evernote.edam.error.ttypes.EDAMUserException, userException:
+      result.userException = userException
+    except evernote.edam.error.ttypes.EDAMSystemException, systemException:
+      result.systemException = systemException
+    except evernote.edam.error.ttypes.EDAMNotFoundException, notFoundException:
+      result.notFoundException = notFoundException
+    oprot.writeMessageBegin("getNoteVersion", TMessageType.REPLY, seqid)
+    result.write(oprot)
+    oprot.writeMessageEnd()
+    oprot.trans.flush()
+
   def process_getResource(self, seqid, iprot, oprot):
     args = getResource_args()
     args.read(iprot)
    - success
    - userException
    - systemException
+   - notFoundException
   """
 
   thrift_spec = (
     (0, TType.STRUCT, 'success', (NoteList, NoteList.thrift_spec), None, ), # 0
     (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
     (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, success=None, userException=None, systemException=None,):
+    (3, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 3
+  )
+
+  def __init__(self, success=None, userException=None, systemException=None, notFoundException=None,):
     self.success = success
     self.userException = userException
     self.systemException = systemException
+    self.notFoundException = notFoundException
 
   def read(self, iprot):
     if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
           self.systemException.read(iprot)
         else:
           iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.STRUCT:
+          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
+          self.notFoundException.read(iprot)
+        else:
+          iprot.skip(ftype)
       else:
         iprot.skip(ftype)
       iprot.readFieldEnd()
       oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
       self.systemException.write(oprot)
       oprot.writeFieldEnd()
+    if self.notFoundException != None:
+      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 3)
+      self.notFoundException.write(oprot)
+      oprot.writeFieldEnd()
     oprot.writeFieldStop()
     oprot.writeStructEnd()
 
    - success
    - userException
    - systemException
+   - notFoundException
   """
 
   thrift_spec = (
     (0, TType.STRUCT, 'success', (NoteCollectionCounts, NoteCollectionCounts.thrift_spec), None, ), # 0
     (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
     (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, success=None, userException=None, systemException=None,):
+    (3, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 3
+  )
+
+  def __init__(self, success=None, userException=None, systemException=None, notFoundException=None,):
     self.success = success
     self.userException = userException
     self.systemException = systemException
+    self.notFoundException = notFoundException
 
   def read(self, iprot):
     if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
           self.systemException.read(iprot)
         else:
           iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.STRUCT:
+          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
+          self.notFoundException.read(iprot)
+        else:
+          iprot.skip(ftype)
       else:
         iprot.skip(ftype)
       iprot.readFieldEnd()
       oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
       self.systemException.write(oprot)
       oprot.writeFieldEnd()
+    if self.notFoundException != None:
+      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 3)
+      self.notFoundException.write(oprot)
+      oprot.writeFieldEnd()
     oprot.writeFieldStop()
     oprot.writeStructEnd()
 
   def __ne__(self, other):
     return not (self == other)
 
+class deleteNote_args(object):
+  """
+  Attributes:
+   - authenticationToken
+   - guid
+  """
+
+  thrift_spec = (
+    None, # 0
+    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
+    (2, TType.STRING, 'guid', None, None, ), # 2
+  )
+
+  def __init__(self, authenticationToken=None, guid=None,):
+    self.authenticationToken = authenticationToken
+    self.guid = guid
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 1:
+        if ftype == TType.STRING:
+          self.authenticationToken = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRING:
+          self.guid = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('deleteNote_args')
+    if self.authenticationToken != None:
+      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
+      oprot.writeString(self.authenticationToken)
+      oprot.writeFieldEnd()
+    if self.guid != None:
+      oprot.writeFieldBegin('guid', TType.STRING, 2)
+      oprot.writeString(self.guid)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
+class deleteNote_result(object):
+  """
+  Attributes:
+   - success
+   - userException
+   - systemException
+   - notFoundException
+  """
+
+  thrift_spec = (
+    (0, TType.I32, 'success', None, None, ), # 0
+    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
+    (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
+    (3, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 3
+  )
+
+  def __init__(self, success=None, userException=None, systemException=None, notFoundException=None,):
+    self.success = success
+    self.userException = userException
+    self.systemException = systemException
+    self.notFoundException = notFoundException
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 0:
+        if ftype == TType.I32:
+          self.success = iprot.readI32();
+        else:
+          iprot.skip(ftype)
+      elif fid == 1:
+        if ftype == TType.STRUCT:
+          self.userException = evernote.edam.error.ttypes.EDAMUserException()
+          self.userException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRUCT:
+          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
+          self.systemException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.STRUCT:
+          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
+          self.notFoundException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('deleteNote_result')
+    if self.success != None:
+      oprot.writeFieldBegin('success', TType.I32, 0)
+      oprot.writeI32(self.success)
+      oprot.writeFieldEnd()
+    if self.userException != None:
+      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
+      self.userException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.systemException != None:
+      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
+      self.systemException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.notFoundException != None:
+      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 3)
+      self.notFoundException.write(oprot)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
 class expungeNote_args(object):
   """
   Attributes:
   def __ne__(self, other):
     return not (self == other)
 
+class listNoteVersions_args(object):
+  """
+  Attributes:
+   - authenticationToken
+   - noteGuid
+  """
+
+  thrift_spec = (
+    None, # 0
+    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
+    (2, TType.STRING, 'noteGuid', None, None, ), # 2
+  )
+
+  def __init__(self, authenticationToken=None, noteGuid=None,):
+    self.authenticationToken = authenticationToken
+    self.noteGuid = noteGuid
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 1:
+        if ftype == TType.STRING:
+          self.authenticationToken = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRING:
+          self.noteGuid = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('listNoteVersions_args')
+    if self.authenticationToken != None:
+      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
+      oprot.writeString(self.authenticationToken)
+      oprot.writeFieldEnd()
+    if self.noteGuid != None:
+      oprot.writeFieldBegin('noteGuid', TType.STRING, 2)
+      oprot.writeString(self.noteGuid)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
+class listNoteVersions_result(object):
+  """
+  Attributes:
+   - success
+   - userException
+   - systemException
+   - notFoundException
+  """
+
+  thrift_spec = (
+    (0, TType.LIST, 'success', (TType.STRUCT,(NoteVersionId, NoteVersionId.thrift_spec)), None, ), # 0
+    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
+    (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
+    (3, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 3
+  )
+
+  def __init__(self, success=None, userException=None, systemException=None, notFoundException=None,):
+    self.success = success
+    self.userException = userException
+    self.systemException = systemException
+    self.notFoundException = notFoundException
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 0:
+        if ftype == TType.LIST:
+          self.success = []
+          (_etype184, _size181) = iprot.readListBegin()
+          for _i185 in xrange(_size181):
+            _elem186 = NoteVersionId()
+            _elem186.read(iprot)
+            self.success.append(_elem186)
+          iprot.readListEnd()
+        else:
+          iprot.skip(ftype)
+      elif fid == 1:
+        if ftype == TType.STRUCT:
+          self.userException = evernote.edam.error.ttypes.EDAMUserException()
+          self.userException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRUCT:
+          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
+          self.systemException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.STRUCT:
+          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
+          self.notFoundException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('listNoteVersions_result')
+    if self.success != None:
+      oprot.writeFieldBegin('success', TType.LIST, 0)
+      oprot.writeListBegin(TType.STRUCT, len(self.success))
+      for iter187 in self.success:
+        iter187.write(oprot)
+      oprot.writeListEnd()
+      oprot.writeFieldEnd()
+    if self.userException != None:
+      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
+      self.userException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.systemException != None:
+      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
+      self.systemException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.notFoundException != None:
+      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 3)
+      self.notFoundException.write(oprot)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
+class getNoteVersion_args(object):
+  """
+  Attributes:
+   - authenticationToken
+   - noteGuid
+   - updateSequenceNum
+   - withResourcesData
+   - withResourcesRecognition
+   - withResourcesAlternateData
+  """
+
+  thrift_spec = (
+    None, # 0
+    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
+    (2, TType.STRING, 'noteGuid', None, None, ), # 2
+    (3, TType.I32, 'updateSequenceNum', None, None, ), # 3
+    (4, TType.BOOL, 'withResourcesData', None, None, ), # 4
+    (5, TType.BOOL, 'withResourcesRecognition', None, None, ), # 5
+    (6, TType.BOOL, 'withResourcesAlternateData', None, None, ), # 6
+  )
+
+  def __init__(self, authenticationToken=None, noteGuid=None, updateSequenceNum=None, withResourcesData=None, withResourcesRecognition=None, withResourcesAlternateData=None,):
+    self.authenticationToken = authenticationToken
+    self.noteGuid = noteGuid
+    self.updateSequenceNum = updateSequenceNum
+    self.withResourcesData = withResourcesData
+    self.withResourcesRecognition = withResourcesRecognition
+    self.withResourcesAlternateData = withResourcesAlternateData
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 1:
+        if ftype == TType.STRING:
+          self.authenticationToken = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRING:
+          self.noteGuid = iprot.readString();
+        else:
+          iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.I32:
+          self.updateSequenceNum = iprot.readI32();
+        else:
+          iprot.skip(ftype)
+      elif fid == 4:
+        if ftype == TType.BOOL:
+          self.withResourcesData = iprot.readBool();
+        else:
+          iprot.skip(ftype)
+      elif fid == 5:
+        if ftype == TType.BOOL:
+          self.withResourcesRecognition = iprot.readBool();
+        else:
+          iprot.skip(ftype)
+      elif fid == 6:
+        if ftype == TType.BOOL:
+          self.withResourcesAlternateData = iprot.readBool();
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('getNoteVersion_args')
+    if self.authenticationToken != None:
+      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
+      oprot.writeString(self.authenticationToken)
+      oprot.writeFieldEnd()
+    if self.noteGuid != None:
+      oprot.writeFieldBegin('noteGuid', TType.STRING, 2)
+      oprot.writeString(self.noteGuid)
+      oprot.writeFieldEnd()
+    if self.updateSequenceNum != None:
+      oprot.writeFieldBegin('updateSequenceNum', TType.I32, 3)
+      oprot.writeI32(self.updateSequenceNum)
+      oprot.writeFieldEnd()
+    if self.withResourcesData != None:
+      oprot.writeFieldBegin('withResourcesData', TType.BOOL, 4)
+      oprot.writeBool(self.withResourcesData)
+      oprot.writeFieldEnd()
+    if self.withResourcesRecognition != None:
+      oprot.writeFieldBegin('withResourcesRecognition', TType.BOOL, 5)
+      oprot.writeBool(self.withResourcesRecognition)
+      oprot.writeFieldEnd()
+    if self.withResourcesAlternateData != None:
+      oprot.writeFieldBegin('withResourcesAlternateData', TType.BOOL, 6)
+      oprot.writeBool(self.withResourcesAlternateData)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
+class getNoteVersion_result(object):
+  """
+  Attributes:
+   - success
+   - userException
+   - systemException
+   - notFoundException
+  """
+
+  thrift_spec = (
+    (0, TType.STRUCT, 'success', (evernote.edam.type.ttypes.Note, evernote.edam.type.ttypes.Note.thrift_spec), None, ), # 0
+    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
+    (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
+    (3, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 3
+  )
+
+  def __init__(self, success=None, userException=None, systemException=None, notFoundException=None,):
+    self.success = success
+    self.userException = userException
+    self.systemException = systemException
+    self.notFoundException = notFoundException
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP:
+        break
+      if fid == 0:
+        if ftype == TType.STRUCT:
+          self.success = evernote.edam.type.ttypes.Note()
+          self.success.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 1:
+        if ftype == TType.STRUCT:
+          self.userException = evernote.edam.error.ttypes.EDAMUserException()
+          self.userException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 2:
+        if ftype == TType.STRUCT:
+          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
+          self.systemException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      elif fid == 3:
+        if ftype == TType.STRUCT:
+          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
+          self.notFoundException.read(iprot)
+        else:
+          iprot.skip(ftype)
+      else:
+        iprot.skip(ftype)
+      iprot.readFieldEnd()
+    iprot.readStructEnd()
+
+  def write(self, oprot):
+    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+      return
+    oprot.writeStructBegin('getNoteVersion_result')
+    if self.success != None:
+      oprot.writeFieldBegin('success', TType.STRUCT, 0)
+      self.success.write(oprot)
+      oprot.writeFieldEnd()
+    if self.userException != None:
+      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
+      self.userException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.systemException != None:
+      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
+      self.systemException.write(oprot)
+      oprot.writeFieldEnd()
+    if self.notFoundException != None:
+      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 3)
+      self.notFoundException.write(oprot)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
 class getResource_args(object):
   """
   Attributes:
       if fid == 0:
         if ftype == TType.LIST:
           self.success = []
-          (_etype184, _size181) = iprot.readListBegin()
-          for _i185 in xrange(_size181):
-            _elem186 = evernote.edam.type.ttypes.Ad()
-            _elem186.read(iprot)
-            self.success.append(_elem186)
-          iprot.readListEnd()
-        else:
-          iprot.skip(ftype)
-      elif fid == 1:
-        if ftype == TType.STRUCT:
-          self.userException = evernote.edam.error.ttypes.EDAMUserException()
-          self.userException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
-          self.systemException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('getAds_result')
-    if self.success != None:
-      oprot.writeFieldBegin('success', TType.LIST, 0)
-      oprot.writeListBegin(TType.STRUCT, len(self.success))
-      for iter187 in self.success:
-        iter187.write(oprot)
-      oprot.writeListEnd()
-      oprot.writeFieldEnd()
-    if self.userException != None:
-      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
-      self.userException.write(oprot)
-      oprot.writeFieldEnd()
-    if self.systemException != None:
-      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
-      self.systemException.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class getRandomAd_args(object):
-  """
-  Attributes:
-   - authenticationToken
-   - adParameters
-  """
-
-  thrift_spec = (
-    None, # 0
-    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
-    (2, TType.STRUCT, 'adParameters', (AdParameters, AdParameters.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, authenticationToken=None, adParameters=None,):
-    self.authenticationToken = authenticationToken
-    self.adParameters = adParameters
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 1:
-        if ftype == TType.STRING:
-          self.authenticationToken = iprot.readString();
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.adParameters = AdParameters()
-          self.adParameters.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('getRandomAd_args')
-    if self.authenticationToken != None:
-      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
-      oprot.writeString(self.authenticationToken)
-      oprot.writeFieldEnd()
-    if self.adParameters != None:
-      oprot.writeFieldBegin('adParameters', TType.STRUCT, 2)
-      self.adParameters.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class getRandomAd_result(object):
-  """
-  Attributes:
-   - success
-   - userException
-   - systemException
-  """
-
-  thrift_spec = (
-    (0, TType.STRUCT, 'success', (evernote.edam.type.ttypes.Ad, evernote.edam.type.ttypes.Ad.thrift_spec), None, ), # 0
-    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
-    (2, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, success=None, userException=None, systemException=None,):
-    self.success = success
-    self.userException = userException
-    self.systemException = systemException
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 0:
-        if ftype == TType.STRUCT:
-          self.success = evernote.edam.type.ttypes.Ad()
-          self.success.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 1:
-        if ftype == TType.STRUCT:
-          self.userException = evernote.edam.error.ttypes.EDAMUserException()
-          self.userException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
-          self.systemException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('getRandomAd_result')
-    if self.success != None:
-      oprot.writeFieldBegin('success', TType.STRUCT, 0)
-      self.success.write(oprot)
-      oprot.writeFieldEnd()
-    if self.userException != None:
-      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
-      self.userException.write(oprot)
-      oprot.writeFieldEnd()
-    if self.systemException != None:
-      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
-      self.systemException.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class getPublicNotebook_args(object):
-  """
-  Attributes:
-   - userId
-   - publicUri
-  """
-
-  thrift_spec = (
-    None, # 0
-    (1, TType.I32, 'userId', None, None, ), # 1
-    (2, TType.STRING, 'publicUri', None, None, ), # 2
-  )
-
-  def __init__(self, userId=None, publicUri=None,):
-    self.userId = userId
-    self.publicUri = publicUri
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 1:
-        if ftype == TType.I32:
-          self.userId = iprot.readI32();
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRING:
-          self.publicUri = iprot.readString();
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('getPublicNotebook_args')
-    if self.userId != None:
-      oprot.writeFieldBegin('userId', TType.I32, 1)
-      oprot.writeI32(self.userId)
-      oprot.writeFieldEnd()
-    if self.publicUri != None:
-      oprot.writeFieldBegin('publicUri', TType.STRING, 2)
-      oprot.writeString(self.publicUri)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class getPublicNotebook_result(object):
-  """
-  Attributes:
-   - success
-   - systemException
-   - notFoundException
-  """
-
-  thrift_spec = (
-    (0, TType.STRUCT, 'success', (evernote.edam.type.ttypes.Notebook, evernote.edam.type.ttypes.Notebook.thrift_spec), None, ), # 0
-    (1, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 1
-    (2, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, success=None, systemException=None, notFoundException=None,):
-    self.success = success
-    self.systemException = systemException
-    self.notFoundException = notFoundException
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 0:
-        if ftype == TType.STRUCT:
-          self.success = evernote.edam.type.ttypes.Notebook()
-          self.success.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 1:
-        if ftype == TType.STRUCT:
-          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
-          self.systemException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
-          self.notFoundException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('getPublicNotebook_result')
-    if self.success != None:
-      oprot.writeFieldBegin('success', TType.STRUCT, 0)
-      self.success.write(oprot)
-      oprot.writeFieldEnd()
-    if self.systemException != None:
-      oprot.writeFieldBegin('systemException', TType.STRUCT, 1)
-      self.systemException.write(oprot)
-      oprot.writeFieldEnd()
-    if self.notFoundException != None:
-      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 2)
-      self.notFoundException.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class createSharedNotebook_args(object):
-  """
-  Attributes:
-   - authenticationToken
-   - sharedNotebook
-  """
-
-  thrift_spec = (
-    None, # 0
-    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
-    (2, TType.STRUCT, 'sharedNotebook', (evernote.edam.type.ttypes.SharedNotebook, evernote.edam.type.ttypes.SharedNotebook.thrift_spec), None, ), # 2
-  )
-
-  def __init__(self, authenticationToken=None, sharedNotebook=None,):
-    self.authenticationToken = authenticationToken
-    self.sharedNotebook = sharedNotebook
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 1:
-        if ftype == TType.STRING:
-          self.authenticationToken = iprot.readString();
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.sharedNotebook = evernote.edam.type.ttypes.SharedNotebook()
-          self.sharedNotebook.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('createSharedNotebook_args')
-    if self.authenticationToken != None:
-      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
-      oprot.writeString(self.authenticationToken)
-      oprot.writeFieldEnd()
-    if self.sharedNotebook != None:
-      oprot.writeFieldBegin('sharedNotebook', TType.STRUCT, 2)
-      self.sharedNotebook.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class createSharedNotebook_result(object):
-  """
-  Attributes:
-   - success
-   - userException
-   - notFoundException
-   - systemException
-  """
-
-  thrift_spec = (
-    (0, TType.STRUCT, 'success', (evernote.edam.type.ttypes.SharedNotebook, evernote.edam.type.ttypes.SharedNotebook.thrift_spec), None, ), # 0
-    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
-    (2, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 2
-    (3, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 3
-  )
-
-  def __init__(self, success=None, userException=None, notFoundException=None, systemException=None,):
-    self.success = success
-    self.userException = userException
-    self.notFoundException = notFoundException
-    self.systemException = systemException
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 0:
-        if ftype == TType.STRUCT:
-          self.success = evernote.edam.type.ttypes.SharedNotebook()
-          self.success.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 1:
-        if ftype == TType.STRUCT:
-          self.userException = evernote.edam.error.ttypes.EDAMUserException()
-          self.userException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 2:
-        if ftype == TType.STRUCT:
-          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
-          self.notFoundException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 3:
-        if ftype == TType.STRUCT:
-          self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
-          self.systemException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('createSharedNotebook_result')
-    if self.success != None:
-      oprot.writeFieldBegin('success', TType.STRUCT, 0)
-      self.success.write(oprot)
-      oprot.writeFieldEnd()
-    if self.userException != None:
-      oprot.writeFieldBegin('userException', TType.STRUCT, 1)
-      self.userException.write(oprot)
-      oprot.writeFieldEnd()
-    if self.notFoundException != None:
-      oprot.writeFieldBegin('notFoundException', TType.STRUCT, 2)
-      self.notFoundException.write(oprot)
-      oprot.writeFieldEnd()
-    if self.systemException != None:
-      oprot.writeFieldBegin('systemException', TType.STRUCT, 3)
-      self.systemException.write(oprot)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class listSharedNotebooks_args(object):
-  """
-  Attributes:
-   - authenticationToken
-  """
-
-  thrift_spec = (
-    None, # 0
-    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
-  )
-
-  def __init__(self, authenticationToken=None,):
-    self.authenticationToken = authenticationToken
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 1:
-        if ftype == TType.STRING:
-          self.authenticationToken = iprot.readString();
-        else:
-          iprot.skip(ftype)
-      else:
-        iprot.skip(ftype)
-      iprot.readFieldEnd()
-    iprot.readStructEnd()
-
-  def write(self, oprot):
-    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-      return
-    oprot.writeStructBegin('listSharedNotebooks_args')
-    if self.authenticationToken != None:
-      oprot.writeFieldBegin('authenticationToken', TType.STRING, 1)
-      oprot.writeString(self.authenticationToken)
-      oprot.writeFieldEnd()
-    oprot.writeFieldStop()
-    oprot.writeStructEnd()
-
-  def __repr__(self):
-    L = ['%s=%r' % (key, value)
-      for key, value in self.__dict__.iteritems()]
-    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
-  def __eq__(self, other):
-    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
-  def __ne__(self, other):
-    return not (self == other)
-
-class listSharedNotebooks_result(object):
-  """
-  Attributes:
-   - success
-   - userException
-   - notFoundException
-   - systemException
-  """
-
-  thrift_spec = (
-    (0, TType.LIST, 'success', (TType.STRUCT,(evernote.edam.type.ttypes.SharedNotebook, evernote.edam.type.ttypes.SharedNotebook.thrift_spec)), None, ), # 0
-    (1, TType.STRUCT, 'userException', (evernote.edam.error.ttypes.EDAMUserException, evernote.edam.error.ttypes.EDAMUserException.thrift_spec), None, ), # 1
-    (2, TType.STRUCT, 'notFoundException', (evernote.edam.error.ttypes.EDAMNotFoundException, evernote.edam.error.ttypes.EDAMNotFoundException.thrift_spec), None, ), # 2
-    (3, TType.STRUCT, 'systemException', (evernote.edam.error.ttypes.EDAMSystemException, evernote.edam.error.ttypes.EDAMSystemException.thrift_spec), None, ), # 3
-  )
-
-  def __init__(self, success=None, userException=None, notFoundException=None, systemException=None,):
-    self.success = success
-    self.userException = userException
-    self.notFoundException = notFoundException
-    self.systemException = systemException
-
-  def read(self, iprot):
-    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-      return
-    iprot.readStructBegin()
-    while True:
-      (fname, ftype, fid) = iprot.readFieldBegin()
-      if ftype == TType.STOP:
-        break
-      if fid == 0:
-        if ftype == TType.LIST:
-          self.success = []
           (_etype191, _size188) = iprot.readListBegin()
           for _i192 in xrange(_size188):
-            _elem193 = evernote.edam.type.ttypes.SharedNotebook()
+            _elem193 = evernote.edam.type.ttypes.Ad()
             _elem193.read(iprot)
             self.success.append(_elem193)
           iprot.readListEnd()
           iprot.skip(ftype)
       elif fid == 2:
         if ftype == TType.STRUCT:
-          self.notFoundException = evernote.edam.error.ttypes.EDAMNotFoundException()
-          self.notFoundException.read(iprot)
-        else:
-          iprot.skip(ftype)
-      elif fid == 3:
-        if ftype == TType.STRUCT:
           self.systemException = evernote.edam.error.ttypes.EDAMSystemException()
           self.systemException.read(iprot)
         else:
     if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
       oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
       return
-    oprot.writeStructBegin('listSharedNotebooks_result')
+    oprot.writeStructBegin('getAds_result')
     if self.success != None:
       oprot.writeFieldBegin('success', TType.LIST, 0)
       oprot.writeListBegin(TType.STRUCT, len(self.success))
       oprot.writeFieldBegin('userException', TType.STRUCT, 1)
       self.userException.write(oprot)
       oprot.writeFieldEnd()
+    if self.systemException != None:
+      oprot.writeFieldBegin('systemException', TType.STRUCT, 2)
+      self.systemException.write(oprot)
+      oprot.writeFieldEnd()
+    oprot.writeFieldStop()
+    oprot.writeStructEnd()
+
+  def __repr__(self):
+    L = ['%s=%r' % (key, value)
+      for key, value in self.__dict__.iteritems()]
+    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+  def __eq__(self, other):
+    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+  def __ne__(self, other):
+    return not (self == other)
+
+class getRandomAd_args(object):
+  """
+  Attributes:
+   - authenticationToken
+   - adParameters
+  """
+
+  thrift_spec = (
+    None, # 0
+    (1, TType.STRING, 'authenticationToken', None, None, ), # 1
+    (2, TType.STRUCT, 'adParameters', (AdParameters, AdParameters.thrift_spec), None, ), # 2
+  )
+
+  def __init__(self, authenticationToken=None, adParameters=None,):
+    self.authenticationToken = authenticationToken
+    self.adParameters = adParameters
+
+  def read(self, iprot):
+    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+      return
+    iprot.readStructBegin()
+    while True:
+      (fname, ftype, fid) = iprot.readFieldBegin()
+      if ftype == TType.STOP: