def __init__(self, query=None): self._query_value = bb.NOT_SET if query is not None: self.query = query # Instance attribute type: str (validator is set below) query = bb.Attribute("query") def _process_custom_annotations(self, annotation_type, field_path, processor): super(EchoArg, self)._process_custom_annotations(annotation_type, field_path, processor) EchoArg_validator = bv.Struct(EchoArg) class EchoResult(bb.Struct): """ EchoResult contains the result returned from the Dropbox servers. :ivar check.EchoResult.result: If everything worked correctly, this would be the same as query. """ __slots__ = [ '_result_value', ] _has_required_fields = False
self.retry_after = retry_after # Instance attribute type: RateLimitReason (validator is set below) reason = bb.Attribute("reason", user_defined=True) # Instance attribute type: int (validator is set below) retry_after = bb.Attribute("retry_after") def _process_custom_annotations(self, annotation_type, field_path, processor): super(RateLimitError, self)._process_custom_annotations(annotation_type, field_path, processor) RateLimitError_validator = bv.Struct(RateLimitError) class RateLimitReason(bb.Union): """ This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar auth.RateLimitReason.too_many_requests: You are making too many requests in the past few minutes. :ivar auth.RateLimitReason.too_many_write_operations: There are currently too many write operations happening in the user's Dropbox. """ _catch_all = 'other'
def __init__(self, photo=None): self._photo_value = bb.NOT_SET if photo is not None: self.photo = photo # Instance attribute type: PhotoSourceArg (validator is set below) photo = bb.Attribute("photo", user_defined=True) def _process_custom_annotations(self, annotation_type, field_path, processor): super(SetProfilePhotoArg, self)._process_custom_annotations(annotation_type, field_path, processor) SetProfilePhotoArg_validator = bv.Struct(SetProfilePhotoArg) class SetProfilePhotoError(bb.Union): """ This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar account.SetProfilePhotoError.file_type_error: File cannot be set as profile photo. :ivar account.SetProfilePhotoError.file_size_error: File cannot exceed 10 MB. :ivar account.SetProfilePhotoError.dimension_error: Image must be larger than 128 x 128. :ivar account.SetProfilePhotoError.thumbnail_error: Image could not be
home_namespace_id) self._home_path_value = bb.NOT_SET if home_path is not None: self.home_path = home_path # Instance attribute type: str (validator is set below) home_path = bb.Attribute("home_path") def _process_custom_annotations(self, annotation_type, field_path, processor): super(TeamRootInfo, self)._process_custom_annotations(annotation_type, field_path, processor) TeamRootInfo_validator = bv.Struct(TeamRootInfo) class UserRootInfo(RootInfo): """ Root info when user is not member of a team or the user is a member of a team and the team does not have a separate root namespace. """ __slots__ = [] _has_required_fields = True def __init__(self, root_namespace_id=None, home_namespace_id=None): super(UserRootInfo, self).__init__(root_namespace_id, home_namespace_id)
def __init__(self, email_addresses=None): self._email_addresses_value = bb.NOT_SET if email_addresses is not None: self.email_addresses = email_addresses # Instance attribute type: list of [str] (validator is set below) email_addresses = bb.Attribute("email_addresses") def _process_custom_annotations(self, annotation_type, field_path, processor): super(DeleteManualContactsArg, self)._process_custom_annotations(annotation_type, field_path, processor) DeleteManualContactsArg_validator = bv.Struct(DeleteManualContactsArg) class DeleteManualContactsError(bb.Union): """ This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar list of [str] contacts.DeleteManualContactsError.contacts_not_found: Can't delete contacts from this list. Make sure the list only has manually added contacts. The deletion was cancelled. """ _catch_all = 'other' # Attribute is overwritten below the class definition
# Instance attribute type: str (validator is set below) email = bb.Attribute("email") # Instance attribute type: bool (validator is set below) email_verified = bb.Attribute("email_verified") # Instance attribute type: str (validator is set below) profile_photo_url = bb.Attribute("profile_photo_url", nullable=True) # Instance attribute type: bool (validator is set below) disabled = bb.Attribute("disabled") def _process_custom_annotations(self, annotation_type, field_path, processor): super(Account, self)._process_custom_annotations(annotation_type, field_path, processor) Account_validator = bv.Struct(Account) class BasicAccount(Account): """ Basic information about any account. :ivar users.BasicAccount.is_teammate: Whether this user is a teammate of the current user. If this account is the current user's account, then this will be ``True``. :ivar users.BasicAccount.team_member_id: The user's unique team member id. This field will only be present if the user is part of a team and ``is_teammate`` is ``True``. """ __slots__ = [ '_is_teammate_value',
_has_required_fields = True def __init__(self, async_job_id=None): self._async_job_id_value = bb.NOT_SET if async_job_id is not None: self.async_job_id = async_job_id # Instance attribute type: str (validator is set below) async_job_id = bb.Attribute("async_job_id") def _process_custom_annotations(self, annotation_type, field_path, processor): super(PollArg, self)._process_custom_annotations(annotation_type, field_path, processor) PollArg_validator = bv.Struct(PollArg) class PollResultBase(bb.Union): """ Result returned by methods that poll for the status of an asynchronous job. Unions that extend this union should add a 'complete' field with a type of the information returned upon job completion. See :class:`PollEmptyResult` for an example. This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar async.PollResultBase.in_progress: The asynchronous job is still in progress. """
_has_required_fields = True def __init__(self, file_request_count=None): self._file_request_count_value = bb.NOT_SET if file_request_count is not None: self.file_request_count = file_request_count # Instance attribute type: int (validator is set below) file_request_count = bb.Attribute("file_request_count") def _process_custom_annotations(self, annotation_type, field_path, processor): super(CountFileRequestsResult, self)._process_custom_annotations(annotation_type, field_path, processor) CountFileRequestsResult_validator = bv.Struct(CountFileRequestsResult) class CreateFileRequestArgs(bb.Struct): """ Arguments for :meth:`dropbox.dropbox_client.Dropbox.file_requests_create`. :ivar file_requests.CreateFileRequestArgs.title: The title of the file request. Must not be empty. :ivar file_requests.CreateFileRequestArgs.destination: The path of the folder in the Dropbox where uploaded files will be sent. For apps with the app folder permission, this will be relative to the app folder. :ivar file_requests.CreateFileRequestArgs.deadline: The deadline for the file request. Deadlines can only be set by Professional and Business accounts. :ivar file_requests.CreateFileRequestArgs.open: Whether or not the file request should be open. If the file request is closed, it will not
# Instance attribute type: int (validator is set below) member_count = bb.Attribute("member_count", nullable=True) # Instance attribute type: GroupManagementType (validator is set below) group_management_type = bb.Attribute("group_management_type", user_defined=True) def _process_custom_annotations(self, annotation_type, field_path, processor): super(GroupSummary, self)._process_custom_annotations(annotation_type, field_path, processor) GroupSummary_validator = bv.Struct(GroupSummary) class GroupType(bb.Union): """ The group type determines how a group is created and managed. This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar team_common.GroupType.team: A group to which team members are automatically added. Applicable to `team folders <https://www.dropbox.com/help/986>`_ only. :ivar team_common.GroupType.user_managed: A group is created and managed by a user.
if is_verified is not None: self.is_verified = is_verified # Instance attribute type: str (validator is set below) email = bb.Attribute("email") # Instance attribute type: bool (validator is set below) is_verified = bb.Attribute("is_verified") def _process_custom_annotations(self, annotation_type, field_path, processor): super(SecondaryEmail, self)._process_custom_annotations(annotation_type, field_path, processor) SecondaryEmail_validator = bv.Struct(SecondaryEmail) SecondaryEmail.email.validator = common.EmailAddress_validator SecondaryEmail.is_verified.validator = bv.Boolean() SecondaryEmail._all_field_names_ = set([ 'email', 'is_verified', ]) SecondaryEmail._all_fields_ = [ ('email', SecondaryEmail.email.validator), ('is_verified', SecondaryEmail.is_verified.validator), ] ROUTES = {}