dropbox.paper – Paper

This namespace contains endpoints and data types for managing docs and folders in Dropbox Paper. New Paper users will see docs they create in their filesystem as ‘.paper’ files alongside their other Dropbox content. The /paper endpoints are being deprecated and you’ll need to use /files and /sharing endpoints to interact with their Paper content. Read more in the Paper Migration Guide.

class dropbox.paper.AddMember(member=None, permission_level=None)

Bases: Struct

Variables:
  • paper.AddMember.permission_level – Permission for the user.

  • paper.AddMember.member – User which should be added to the Paper doc. Specify only email address or Dropbox account ID.

__init__(member=None, permission_level=None)
member
permission_level
class dropbox.paper.AddPaperDocUser(doc_id=None, members=None, custom_message=None, quiet=None)

Bases: RefPaperDoc

Variables:
  • paper.AddPaperDocUser.members – User which should be added to the Paper doc. Specify only email address or Dropbox account ID.

  • paper.AddPaperDocUser.custom_message – A personal message that will be emailed to each successfully added member.

  • paper.AddPaperDocUser.quiet – Clients should set this to true if no email message shall be sent to added users.

__init__(doc_id=None, members=None, custom_message=None, quiet=None)
custom_message
members
quiet
class dropbox.paper.AddPaperDocUserMemberResult(member=None, result=None)

Bases: Struct

Per-member result for dropbox.dropbox_client.Dropbox.paper_docs_users_add().

Variables:
  • paper.AddPaperDocUserMemberResult.member – One of specified input members.

  • paper.AddPaperDocUserMemberResult.result – The outcome of the action on this member.

__init__(member=None, result=None)
member
result
class dropbox.paper.AddPaperDocUserResult(tag, value=None)

Bases: 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.

Variables:
  • paper.AddPaperDocUserResult.success – User was successfully added to the Paper doc.

  • paper.AddPaperDocUserResult.unknown_error – Something unexpected happened when trying to add the user to the Paper doc.

  • paper.AddPaperDocUserResult.sharing_outside_team_disabled – The Paper doc can be shared only with team members.

  • paper.AddPaperDocUserResult.daily_limit_reached – The daily limit of how many users can be added to the Paper doc was reached.

  • paper.AddPaperDocUserResult.user_is_owner – Owner’s permissions cannot be changed.

  • paper.AddPaperDocUserResult.failed_user_data_retrieval – User data could not be retrieved. Clients should retry.

  • paper.AddPaperDocUserResult.permission_already_granted – This user already has the correct permission to the Paper doc.

daily_limit_reached = AddPaperDocUserResult('daily_limit_reached', None)
failed_user_data_retrieval = AddPaperDocUserResult('failed_user_data_retrieval', None)
is_daily_limit_reached()

Check if the union tag is daily_limit_reached.

Return type:

bool

is_failed_user_data_retrieval()

Check if the union tag is failed_user_data_retrieval.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

is_permission_already_granted()

Check if the union tag is permission_already_granted.

Return type:

bool

is_sharing_outside_team_disabled()

Check if the union tag is sharing_outside_team_disabled.

Return type:

bool

is_success()

Check if the union tag is success.

Return type:

bool

is_unknown_error()

Check if the union tag is unknown_error.

Return type:

bool

is_user_is_owner()

Check if the union tag is user_is_owner.

Return type:

bool

other = AddPaperDocUserResult('other', None)
permission_already_granted = AddPaperDocUserResult('permission_already_granted', None)
sharing_outside_team_disabled = AddPaperDocUserResult('sharing_outside_team_disabled', None)
success = AddPaperDocUserResult('success', None)
unknown_error = AddPaperDocUserResult('unknown_error', None)
user_is_owner = AddPaperDocUserResult('user_is_owner', None)
class dropbox.paper.Cursor(value=None, expiration=None)

Bases: Struct

Variables:
  • paper.Cursor.value – The actual cursor value.

  • paper.Cursor.expiration – Expiration time of value. Some cursors might have expiration time assigned. This is a UTC value after which the cursor is no longer valid and the API starts returning an error. If cursor expires a new one needs to be obtained and pagination needs to be restarted. Some cursors might be short-lived some cursors might be long-lived. This really depends on the sorting type and order, e.g.: 1. on one hand, listing docs created by the user, sorted by the created time ascending will have undefinite expiration because the results cannot change while the iteration is happening. This cursor would be suitable for long term polling. 2. on the other hand, listing docs sorted by the last modified time will have a very short expiration as docs do get modified very often and the modified time can be changed while the iteration is happening thus altering the results.

__init__(value=None, expiration=None)
expiration
value
class dropbox.paper.DocLookupError(tag, value=None)

Bases: PaperApiBaseError

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.

Variables:

paper.DocLookupError.doc_not_found – The required doc was not found.

doc_not_found = DocLookupError('doc_not_found', None)
is_doc_not_found()

Check if the union tag is doc_not_found.

Return type:

bool

class dropbox.paper.DocSubscriptionLevel(tag, value=None)

Bases: Union

The subscription level of a Paper doc.

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.

Variables:
  • paper.DocSubscriptionLevel.default – No change email messages unless you’re the creator.

  • paper.DocSubscriptionLevel.ignore – Ignored: Not shown in pad lists or activity and no email message is sent.

  • paper.DocSubscriptionLevel.every – Subscribed: Shown in pad lists and activity and change email messages are sent.

  • paper.DocSubscriptionLevel.no_email – Unsubscribed: Shown in pad lists, but not in activity and no change email messages are sent.

default = DocSubscriptionLevel('default', None)
every = DocSubscriptionLevel('every', None)
ignore = DocSubscriptionLevel('ignore', None)
is_default()

Check if the union tag is default.

Return type:

bool

is_every()

Check if the union tag is every.

Return type:

bool

is_ignore()

Check if the union tag is ignore.

Return type:

bool

is_no_email()

Check if the union tag is no_email.

Return type:

bool

no_email = DocSubscriptionLevel('no_email', None)
class dropbox.paper.ExportFormat(tag, value=None)

Bases: Union

The desired export format of the Paper doc.

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.

Variables:
  • paper.ExportFormat.html – The HTML export format.

  • paper.ExportFormat.markdown – The markdown export format.

html = ExportFormat('html', None)
is_html()

Check if the union tag is html.

Return type:

bool

is_markdown()

Check if the union tag is markdown.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

markdown = ExportFormat('markdown', None)
other = ExportFormat('other', None)
class dropbox.paper.Folder(id=None, name=None)

Bases: Struct

Data structure representing a Paper folder.

Variables:
  • paper.Folder.id – Paper folder ID. This ID uniquely identifies the folder.

  • paper.Folder.name – Paper folder name.

__init__(id=None, name=None)
id
name
class dropbox.paper.FolderSharingPolicyType(tag, value=None)

Bases: Union

The sharing policy of a Paper folder. The sharing policy of subfolders is inherited from the root folder.

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.

Variables:
  • paper.FolderSharingPolicyType.team – Everyone in your team and anyone directly invited can access this folder.

  • paper.FolderSharingPolicyType.invite_only – Only people directly invited can access this folder.

invite_only = FolderSharingPolicyType('invite_only', None)
is_invite_only()

Check if the union tag is invite_only.

Return type:

bool

is_team()

Check if the union tag is team.

Return type:

bool

team = FolderSharingPolicyType('team', None)
class dropbox.paper.FolderSubscriptionLevel(tag, value=None)

Bases: Union

The subscription level of a Paper folder.

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.

Variables:
  • paper.FolderSubscriptionLevel.none – Not shown in activity, no email messages.

  • paper.FolderSubscriptionLevel.activity_only – Shown in activity, no email messages.

  • paper.FolderSubscriptionLevel.daily_emails – Shown in activity, daily email messages.

  • paper.FolderSubscriptionLevel.weekly_emails – Shown in activity, weekly email messages.

activity_only = FolderSubscriptionLevel('activity_only', None)
daily_emails = FolderSubscriptionLevel('daily_emails', None)
is_activity_only()

Check if the union tag is activity_only.

Return type:

bool

is_daily_emails()

Check if the union tag is daily_emails.

Return type:

bool

is_none()

Check if the union tag is none.

Return type:

bool

is_weekly_emails()

Check if the union tag is weekly_emails.

Return type:

bool

none = FolderSubscriptionLevel('none', None)
weekly_emails = FolderSubscriptionLevel('weekly_emails', None)
class dropbox.paper.FoldersContainingPaperDoc(folder_sharing_policy_type=None, folders=None)

Bases: Struct

Metadata about Paper folders containing the specififed Paper doc.

Variables:
  • paper.FoldersContainingPaperDoc.folder_sharing_policy_type – The sharing policy of the folder containing the Paper doc.

  • paper.FoldersContainingPaperDoc.folders – The folder path. If present the first folder is the root folder.

__init__(folder_sharing_policy_type=None, folders=None)
folder_sharing_policy_type
folders
class dropbox.paper.ImportFormat(tag, value=None)

Bases: Union

The import format of the incoming data.

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.

Variables:
  • paper.ImportFormat.html – The provided data is interpreted as standard HTML.

  • paper.ImportFormat.markdown – The provided data is interpreted as markdown. The first line of the provided document will be used as the doc title.

  • paper.ImportFormat.plain_text – The provided data is interpreted as plain text. The first line of the provided document will be used as the doc title.

html = ImportFormat('html', None)
is_html()

Check if the union tag is html.

Return type:

bool

is_markdown()

Check if the union tag is markdown.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

is_plain_text()

Check if the union tag is plain_text.

Return type:

bool

markdown = ImportFormat('markdown', None)
other = ImportFormat('other', None)
plain_text = ImportFormat('plain_text', None)
class dropbox.paper.InviteeInfoWithPermissionLevel(invitee=None, permission_level=None)

Bases: Struct

Variables:
  • paper.InviteeInfoWithPermissionLevel.invitee – Email address invited to the Paper doc.

  • paper.InviteeInfoWithPermissionLevel.permission_level – Permission level for the invitee.

__init__(invitee=None, permission_level=None)
invitee
permission_level
class dropbox.paper.ListDocsCursorError(tag, value=None)

Bases: 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.

classmethod cursor_error(val)

Create an instance of this class set to the cursor_error tag with value val.

Parameters:

val (PaperApiCursorError) –

Return type:

ListDocsCursorError

get_cursor_error()

Only call this if is_cursor_error() is true.

Return type:

PaperApiCursorError

is_cursor_error()

Check if the union tag is cursor_error.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

other = ListDocsCursorError('other', None)
class dropbox.paper.ListPaperDocsArgs(filter_by=None, sort_by=None, sort_order=None, limit=None)

Bases: Struct

Variables:
  • paper.ListPaperDocsArgs.filter_by – Allows user to specify how the Paper docs should be filtered.

  • paper.ListPaperDocsArgs.sort_by – Allows user to specify how the Paper docs should be sorted.

  • paper.ListPaperDocsArgs.sort_order – Allows user to specify the sort order of the result.

  • paper.ListPaperDocsArgs.limit – Size limit per batch. The maximum number of docs that can be retrieved per batch is 1000. Higher value results in invalid arguments error.

__init__(filter_by=None, sort_by=None, sort_order=None, limit=None)
filter_by
limit
sort_by
sort_order
class dropbox.paper.ListPaperDocsContinueArgs(cursor=None)

Bases: Struct

Variables:

paper.ListPaperDocsContinueArgs.cursor – The cursor obtained from dropbox.dropbox_client.Dropbox.paper_docs_list() or dropbox.dropbox_client.Dropbox.paper_docs_list_continue(). Allows for pagination.

__init__(cursor=None)
cursor
class dropbox.paper.ListPaperDocsFilterBy(tag, value=None)

Bases: 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.

Variables:
  • paper.ListPaperDocsFilterBy.docs_accessed – Fetches all Paper doc IDs that the user has ever accessed.

  • paper.ListPaperDocsFilterBy.docs_created – Fetches only the Paper doc IDs that the user has created.

docs_accessed = ListPaperDocsFilterBy('docs_accessed', None)
docs_created = ListPaperDocsFilterBy('docs_created', None)
is_docs_accessed()

Check if the union tag is docs_accessed.

Return type:

bool

is_docs_created()

Check if the union tag is docs_created.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

other = ListPaperDocsFilterBy('other', None)
class dropbox.paper.ListPaperDocsResponse(doc_ids=None, cursor=None, has_more=None)

Bases: Struct

Variables:
__init__(doc_ids=None, cursor=None, has_more=None)
cursor
doc_ids
has_more
class dropbox.paper.ListPaperDocsSortBy(tag, value=None)

Bases: 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.

Variables:
  • paper.ListPaperDocsSortBy.accessed – Sorts the Paper docs by the time they were last accessed.

  • paper.ListPaperDocsSortBy.modified – Sorts the Paper docs by the time they were last modified.

  • paper.ListPaperDocsSortBy.created – Sorts the Paper docs by the creation time.

accessed = ListPaperDocsSortBy('accessed', None)
created = ListPaperDocsSortBy('created', None)
is_accessed()

Check if the union tag is accessed.

Return type:

bool

is_created()

Check if the union tag is created.

Return type:

bool

is_modified()

Check if the union tag is modified.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

modified = ListPaperDocsSortBy('modified', None)
other = ListPaperDocsSortBy('other', None)
class dropbox.paper.ListPaperDocsSortOrder(tag, value=None)

Bases: 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.

Variables:
  • paper.ListPaperDocsSortOrder.ascending – Sorts the search result in ascending order.

  • paper.ListPaperDocsSortOrder.descending – Sorts the search result in descending order.

ascending = ListPaperDocsSortOrder('ascending', None)
descending = ListPaperDocsSortOrder('descending', None)
is_ascending()

Check if the union tag is ascending.

Return type:

bool

is_descending()

Check if the union tag is descending.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

other = ListPaperDocsSortOrder('other', None)
class dropbox.paper.ListUsersCursorError(tag, value=None)

Bases: PaperApiBaseError

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.

Variables:

paper.ListUsersCursorError.doc_not_found – The required doc was not found.

classmethod cursor_error(val)

Create an instance of this class set to the cursor_error tag with value val.

Parameters:

val (PaperApiCursorError) –

Return type:

ListUsersCursorError

doc_not_found = ListUsersCursorError('doc_not_found', None)
get_cursor_error()

Only call this if is_cursor_error() is true.

Return type:

PaperApiCursorError

is_cursor_error()

Check if the union tag is cursor_error.

Return type:

bool

is_doc_not_found()

Check if the union tag is doc_not_found.

Return type:

bool

class dropbox.paper.ListUsersOnFolderArgs(doc_id=None, limit=None)

Bases: RefPaperDoc

Variables:

paper.ListUsersOnFolderArgs.limit – Size limit per batch. The maximum number of users that can be retrieved per batch is 1000. Higher value results in invalid arguments error.

__init__(doc_id=None, limit=None)
limit
class dropbox.paper.ListUsersOnFolderContinueArgs(doc_id=None, cursor=None)

Bases: RefPaperDoc

Variables:

paper.ListUsersOnFolderContinueArgs.cursor – The cursor obtained from dropbox.dropbox_client.Dropbox.paper_docs_folder_users_list() or dropbox.dropbox_client.Dropbox.paper_docs_folder_users_list_continue(). Allows for pagination.

__init__(doc_id=None, cursor=None)
cursor
class dropbox.paper.ListUsersOnFolderResponse(invitees=None, users=None, cursor=None, has_more=None)

Bases: Struct

Variables:
__init__(invitees=None, users=None, cursor=None, has_more=None)
cursor
has_more
invitees
users
class dropbox.paper.ListUsersOnPaperDocArgs(doc_id=None, limit=None, filter_by=None)

Bases: RefPaperDoc

Variables:
  • paper.ListUsersOnPaperDocArgs.limit – Size limit per batch. The maximum number of users that can be retrieved per batch is 1000. Higher value results in invalid arguments error.

  • paper.ListUsersOnPaperDocArgs.filter_by – Specify this attribute if you want to obtain users that have already accessed the Paper doc.

__init__(doc_id=None, limit=None, filter_by=None)
filter_by
limit
class dropbox.paper.ListUsersOnPaperDocContinueArgs(doc_id=None, cursor=None)

Bases: RefPaperDoc

Variables:

paper.ListUsersOnPaperDocContinueArgs.cursor – The cursor obtained from dropbox.dropbox_client.Dropbox.paper_docs_users_list() or dropbox.dropbox_client.Dropbox.paper_docs_users_list_continue(). Allows for pagination.

__init__(doc_id=None, cursor=None)
cursor
class dropbox.paper.ListUsersOnPaperDocResponse(invitees=None, users=None, doc_owner=None, cursor=None, has_more=None)

Bases: Struct

Variables:
__init__(invitees=None, users=None, doc_owner=None, cursor=None, has_more=None)
cursor
doc_owner
has_more
invitees
users
class dropbox.paper.PaperApiBaseError(tag, value=None)

Bases: 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.

Variables:

paper.PaperApiBaseError.insufficient_permissions

Your account does not have permissions to perform this action. This may be due to it only having access to Paper as files in the Dropbox filesystem. For more information, refer to the Paper Migration Guide.

insufficient_permissions = PaperApiBaseError('insufficient_permissions', None)
is_insufficient_permissions()

Check if the union tag is insufficient_permissions.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

other = PaperApiBaseError('other', None)
class dropbox.paper.PaperApiCursorError(tag, value=None)

Bases: 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.

Variables:
  • paper.PaperApiCursorError.expired_cursor – The provided cursor is expired.

  • paper.PaperApiCursorError.invalid_cursor – The provided cursor is invalid.

  • paper.PaperApiCursorError.wrong_user_in_cursor – The provided cursor contains invalid user.

  • paper.PaperApiCursorError.reset – Indicates that the cursor has been invalidated. Call the corresponding non-continue endpoint to obtain a new cursor.

expired_cursor = PaperApiCursorError('expired_cursor', None)
invalid_cursor = PaperApiCursorError('invalid_cursor', None)
is_expired_cursor()

Check if the union tag is expired_cursor.

Return type:

bool

is_invalid_cursor()

Check if the union tag is invalid_cursor.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

is_reset()

Check if the union tag is reset.

Return type:

bool

is_wrong_user_in_cursor()

Check if the union tag is wrong_user_in_cursor.

Return type:

bool

other = PaperApiCursorError('other', None)
reset = PaperApiCursorError('reset', None)
wrong_user_in_cursor = PaperApiCursorError('wrong_user_in_cursor', None)
class dropbox.paper.PaperDocCreateArgs(import_format=None, parent_folder_id=None)

Bases: Struct

Variables:
  • paper.PaperDocCreateArgs.parent_folder_id – The Paper folder ID where the Paper document should be created. The API user has to have write access to this folder or error is thrown.

  • paper.PaperDocCreateArgs.import_format – The format of provided data.

__init__(import_format=None, parent_folder_id=None)
import_format
parent_folder_id
class dropbox.paper.PaperDocCreateError(tag, value=None)

Bases: PaperApiBaseError

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.

Variables:
  • paper.PaperDocCreateError.content_malformed – The provided content was malformed and cannot be imported to Paper.

  • paper.PaperDocCreateError.folder_not_found – The specified Paper folder is cannot be found.

  • paper.PaperDocCreateError.doc_length_exceeded – The newly created Paper doc would be too large. Please split the content into multiple docs.

  • paper.PaperDocCreateError.image_size_exceeded – The imported document contains an image that is too large. The current limit is 1MB. This only applies to HTML with data URI.

content_malformed = PaperDocCreateError('content_malformed', None)
doc_length_exceeded = PaperDocCreateError('doc_length_exceeded', None)
folder_not_found = PaperDocCreateError('folder_not_found', None)
image_size_exceeded = PaperDocCreateError('image_size_exceeded', None)
is_content_malformed()

Check if the union tag is content_malformed.

Return type:

bool

is_doc_length_exceeded()

Check if the union tag is doc_length_exceeded.

Return type:

bool

is_folder_not_found()

Check if the union tag is folder_not_found.

Return type:

bool

is_image_size_exceeded()

Check if the union tag is image_size_exceeded.

Return type:

bool

class dropbox.paper.PaperDocCreateUpdateResult(doc_id=None, revision=None, title=None)

Bases: Struct

Variables:
  • paper.PaperDocCreateUpdateResult.doc_id – Doc ID of the newly created doc.

  • paper.PaperDocCreateUpdateResult.revision – The Paper doc revision. Simply an ever increasing number.

  • paper.PaperDocCreateUpdateResult.title – The Paper doc title.

__init__(doc_id=None, revision=None, title=None)
doc_id
revision
title
class dropbox.paper.PaperDocExport(doc_id=None, export_format=None)

Bases: RefPaperDoc

__init__(doc_id=None, export_format=None)
export_format
class dropbox.paper.PaperDocExportResult(owner=None, title=None, revision=None, mime_type=None)

Bases: Struct

Variables:
  • paper.PaperDocExportResult.owner – The Paper doc owner’s email address.

  • paper.PaperDocExportResult.title – The Paper doc title.

  • paper.PaperDocExportResult.revision – The Paper doc revision. Simply an ever increasing number.

  • paper.PaperDocExportResult.mime_type – MIME type of the export. This corresponds to ExportFormat specified in the request.

__init__(owner=None, title=None, revision=None, mime_type=None)
mime_type
owner
revision
title
class dropbox.paper.PaperDocPermissionLevel(tag, value=None)

Bases: 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.

Variables:
  • paper.PaperDocPermissionLevel.edit – User will be granted edit permissions.

  • paper.PaperDocPermissionLevel.view_and_comment – User will be granted view and comment permissions.

edit = PaperDocPermissionLevel('edit', None)
is_edit()

Check if the union tag is edit.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

is_view_and_comment()

Check if the union tag is view_and_comment.

Return type:

bool

other = PaperDocPermissionLevel('other', None)
view_and_comment = PaperDocPermissionLevel('view_and_comment', None)
class dropbox.paper.PaperDocSharingPolicy(doc_id=None, sharing_policy=None)

Bases: RefPaperDoc

Variables:

paper.PaperDocSharingPolicy.sharing_policy – The default sharing policy to be set for the Paper doc.

__init__(doc_id=None, sharing_policy=None)
sharing_policy
class dropbox.paper.PaperDocUpdateArgs(doc_id=None, doc_update_policy=None, revision=None, import_format=None)

Bases: RefPaperDoc

Variables:
  • paper.PaperDocUpdateArgs.doc_update_policy – The policy used for the current update call.

  • paper.PaperDocUpdateArgs.revision – The latest doc revision. This value must match the head revision or an error code will be returned. This is to prevent colliding writes.

  • paper.PaperDocUpdateArgs.import_format – The format of provided data.

__init__(doc_id=None, doc_update_policy=None, revision=None, import_format=None)
doc_update_policy
import_format
revision
class dropbox.paper.PaperDocUpdateError(tag, value=None)

Bases: DocLookupError

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.

Variables:
  • paper.PaperDocUpdateError.content_malformed – The provided content was malformed and cannot be imported to Paper.

  • paper.PaperDocUpdateError.revision_mismatch – The provided revision does not match the document head.

  • paper.PaperDocUpdateError.doc_length_exceeded – The newly created Paper doc would be too large, split the content into multiple docs.

  • paper.PaperDocUpdateError.image_size_exceeded – The imported document contains an image that is too large. The current limit is 1MB. This only applies to HTML with data URI.

  • paper.PaperDocUpdateError.doc_archived – This operation is not allowed on archived Paper docs.

  • paper.PaperDocUpdateError.doc_deleted – This operation is not allowed on deleted Paper docs.

content_malformed = PaperDocUpdateError('content_malformed', None)
doc_archived = PaperDocUpdateError('doc_archived', None)
doc_deleted = PaperDocUpdateError('doc_deleted', None)
doc_length_exceeded = PaperDocUpdateError('doc_length_exceeded', None)
image_size_exceeded = PaperDocUpdateError('image_size_exceeded', None)
is_content_malformed()

Check if the union tag is content_malformed.

Return type:

bool

is_doc_archived()

Check if the union tag is doc_archived.

Return type:

bool

is_doc_deleted()

Check if the union tag is doc_deleted.

Return type:

bool

is_doc_length_exceeded()

Check if the union tag is doc_length_exceeded.

Return type:

bool

is_image_size_exceeded()

Check if the union tag is image_size_exceeded.

Return type:

bool

is_revision_mismatch()

Check if the union tag is revision_mismatch.

Return type:

bool

revision_mismatch = PaperDocUpdateError('revision_mismatch', None)
class dropbox.paper.PaperDocUpdatePolicy(tag, value=None)

Bases: 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.

Variables:
  • paper.PaperDocUpdatePolicy.append – The content will be appended to the doc.

  • paper.PaperDocUpdatePolicy.prepend – The content will be prepended to the doc. The doc title will not be affected.

  • paper.PaperDocUpdatePolicy.overwrite_all – The document will be overwitten at the head with the provided content.

append = PaperDocUpdatePolicy('append', None)
is_append()

Check if the union tag is append.

Return type:

bool

is_other()

Check if the union tag is other.

Return type:

bool

is_overwrite_all()

Check if the union tag is overwrite_all.

Return type:

bool

is_prepend()

Check if the union tag is prepend.

Return type:

bool

other = PaperDocUpdatePolicy('other', None)
overwrite_all = PaperDocUpdatePolicy('overwrite_all', None)
prepend = PaperDocUpdatePolicy('prepend', None)
class dropbox.paper.PaperFolderCreateArg(name=None, parent_folder_id=None, is_team_folder=None)

Bases: Struct

Variables:
  • paper.PaperFolderCreateArg.name – The name of the new Paper folder.

  • paper.PaperFolderCreateArg.parent_folder_id – The encrypted Paper folder Id where the new Paper folder should be created. The API user has to have write access to this folder or error is thrown. If not supplied, the new folder will be created at top level.

  • paper.PaperFolderCreateArg.is_team_folder – Whether the folder to be created should be a team folder. This value will be ignored if parent_folder_id is supplied, as the new folder will inherit the type (private or team folder) from its parent. We will by default create a top-level private folder if both parent_folder_id and is_team_folder are not supplied.

__init__(name=None, parent_folder_id=None, is_team_folder=None)
is_team_folder
name
parent_folder_id
class dropbox.paper.PaperFolderCreateError(tag, value=None)

Bases: PaperApiBaseError

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.

Variables:
  • paper.PaperFolderCreateError.folder_not_found – The specified parent Paper folder cannot be found.

  • paper.PaperFolderCreateError.invalid_folder_id – The folder id cannot be decrypted to valid folder id.

folder_not_found = PaperFolderCreateError('folder_not_found', None)
invalid_folder_id = PaperFolderCreateError('invalid_folder_id', None)
is_folder_not_found()

Check if the union tag is folder_not_found.

Return type:

bool

is_invalid_folder_id()

Check if the union tag is invalid_folder_id.

Return type:

bool

class dropbox.paper.PaperFolderCreateResult(folder_id=None)

Bases: Struct

Variables:

paper.PaperFolderCreateResult.folder_id – Folder ID of the newly created folder.

__init__(folder_id=None)
folder_id
class dropbox.paper.RefPaperDoc(doc_id=None)

Bases: Struct

Variables:

paper.RefPaperDoc.doc_id – The Paper doc ID.

__init__(doc_id=None)
doc_id
class dropbox.paper.RemovePaperDocUser(doc_id=None, member=None)

Bases: RefPaperDoc

Variables:

paper.RemovePaperDocUser.member – User which should be removed from the Paper doc. Specify only email address or Dropbox account ID.

__init__(doc_id=None, member=None)
member
class dropbox.paper.SharingPolicy(public_sharing_policy=None, team_sharing_policy=None)

Bases: Struct

Sharing policy of Paper doc.

Variables:
  • paper.SharingPolicy.public_sharing_policy – This value applies to the non-team members.

  • paper.SharingPolicy.team_sharing_policy – This value applies to the team members only. The value is null for all personal accounts.

__init__(public_sharing_policy=None, team_sharing_policy=None)
public_sharing_policy
team_sharing_policy
class dropbox.paper.SharingPublicPolicyType(tag, value=None)

Bases: SharingTeamPolicyType

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.

Variables:

paper.SharingPublicPolicyType.disabled – Value used to indicate that doc sharing is enabled only within team.

disabled = SharingPublicPolicyType('disabled', None)
is_disabled()

Check if the union tag is disabled.

Return type:

bool

class dropbox.paper.SharingTeamPolicyType(tag, value=None)

Bases: Union

The sharing policy type of the Paper doc.

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.

Variables:
  • paper.SharingTeamPolicyType.people_with_link_can_edit – Users who have a link to this doc can edit it.

  • paper.SharingTeamPolicyType.people_with_link_can_view_and_comment – Users who have a link to this doc can view and comment on it.

  • paper.SharingTeamPolicyType.invite_only – Users must be explicitly invited to this doc.

invite_only = SharingTeamPolicyType('invite_only', None)
is_invite_only()

Check if the union tag is invite_only.

Return type:

bool

Check if the union tag is people_with_link_can_edit.

Return type:

bool

Check if the union tag is people_with_link_can_view_and_comment.

Return type:

bool

class dropbox.paper.UserInfoWithPermissionLevel(user=None, permission_level=None)

Bases: Struct

Variables:
  • paper.UserInfoWithPermissionLevel.user – User shared on the Paper doc.

  • paper.UserInfoWithPermissionLevel.permission_level – Permission level for the user.

__init__(user=None, permission_level=None)
permission_level
user
class dropbox.paper.UserOnPaperDocFilter(tag, value=None)

Bases: 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.

Variables:
  • paper.UserOnPaperDocFilter.visited – all users who have visited the Paper doc.

  • paper.UserOnPaperDocFilter.shared – All uses who are shared on the Paper doc. This includes all users who have visited the Paper doc as well as those who have not.

is_other()

Check if the union tag is other.

Return type:

bool

is_shared()

Check if the union tag is shared.

Return type:

bool

is_visited()

Check if the union tag is visited.

Return type:

bool

other = UserOnPaperDocFilter('other', None)
shared = UserOnPaperDocFilter('shared', None)
visited = UserOnPaperDocFilter('visited', None)