namespace team import async import common # Common structs union TeamFolderStatus active "The team folder and sub-folders are available to all members." archived "The team folder is not accessible outside of the team folder manager." archive_in_progress "The team folder is not accessible outside of the team folder manager." struct TeamFolderIdArg team_folder_id common.SharedFolderId "The ID of the team folder." example default team_folder_id = "123456789" struct TeamFolderIdListArg team_folder_ids List(common.SharedFolderId, min_items=1) "The list of team folder IDs." example default team_folder_ids = ["947182", "5819424", "852307532"] struct TeamFolderMetadata "Properties of a team folder." team_folder_id common.SharedFolderId "The ID of the team folder." name String "The name of the team folder." status TeamFolderStatus "The status of the team folder." example default name = "Marketing" team_folder_id = "123456789" status = active union TeamFolderAccessError invalid_team_folder_id "The team folder ID is invalid." no_access "The authenticated app does not have permission to manage that team folder." union TeamFolderInvalidStatusError active "The folder is active and the operation did not succeed." archived "The folder is archived and the operation did not succeed." archive_in_progress "The folder is being archived and the operation did not succeed." union BaseTeamFolderError "Base error that all errors for existing team folders should extend." access_error TeamFolderAccessError status_error TeamFolderInvalidStatusError # # Team folder create # route team_folder/create(TeamFolderCreateArg, TeamFolderMetadata, TeamFolderCreateError) "Creates a new, active, team folder. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" struct TeamFolderCreateArg name String "Name for the new team folder." example default name = "Marketing" union TeamFolderCreateError invalid_folder_name "The provided name cannot be used." folder_name_already_used "There is already a team folder with the provided name." folder_name_reserved "The provided name cannot be used because it is reserved." # # Team folder rename # route team_folder/rename(TeamFolderRenameArg, TeamFolderMetadata, TeamFolderRenameError) "Changes an active team folder's name. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" struct TeamFolderRenameArg extends TeamFolderIdArg name String "New team folder name." example default team_folder_id = "123456789" name = "Sales" union TeamFolderRenameError extends BaseTeamFolderError invalid_folder_name "The provided folder name cannot be used." folder_name_already_used "There is already a team folder with the same name." folder_name_reserved "The provided name cannot be used because it is reserved." # # Team folder list # route team_folder/list(TeamFolderListArg, TeamFolderListResult, TeamFolderListError) "Lists all team folders. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" struct TeamFolderListArg limit UInt32(min_value=1, max_value=1000) = 1000 "The maximum number of results to return per request." example default limit = 100 struct TeamFolderListResult "Result for :route:`team_folder/list` and :route:`team_folder/list/continue`." team_folders List(TeamFolderMetadata) "List of all team folders in the authenticated team." cursor String "Pass the cursor into :route:`team_folder/list/continue` to obtain additional team folders." has_more Boolean "Is true if there are additional team folders that have not been returned yet. An additional call to :route:`team_folder/list/continue` can retrieve them." example default team_folders = [default] cursor = "ZtkX9_EHj3x7PMkVuFIhwKYXEpwpLwyxp9vMKomUhllil9q7eWiAu" has_more = false struct TeamFolderListError access_error TeamFolderAccessError # # Team folder list/continue # route team_folder/list/continue(TeamFolderListContinueArg, TeamFolderListResult, TeamFolderListContinueError) "Once a cursor has been retrieved from :route:`team_folder/list`, use this to paginate through all team folders. Permission : Team member file access." attrs owner = "company-dropbox-team" auth = "team" struct TeamFolderListContinueArg cursor String "Indicates from what point to get the next set of team folders." example default cursor = "ZtkX9_EHj3x7PMkVuFIhwKYXEpwpLwyxp9vMKomUhllil9q7eWiAu" union TeamFolderListContinueError invalid_cursor "The cursor is invalid." # # Team folder get info # route team_folder/get_info(TeamFolderIdListArg, List(TeamFolderGetInfoItem), Void) "Retrieves metadata for team folders. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" union_closed TeamFolderGetInfoItem id_not_found String "An ID that was provided as a parameter to :route:`team_folder/get_info` did not match any of the team's team folders." team_folder_metadata TeamFolderMetadata "Properties of a team folder." # # Team folder activate # route team_folder/activate(TeamFolderIdArg, TeamFolderMetadata, TeamFolderActivateError) "Sets an archived team folder's status to active. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" union TeamFolderActivateError extends BaseTeamFolderError "" # # Team folder archive # route team_folder/archive(TeamFolderArchiveArg, TeamFolderArchiveLaunch, TeamFolderArchiveError) "Sets an active team folder's status to archived and removes all folder and file members. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" struct TeamFolderArchiveArg extends TeamFolderIdArg force_async_off Boolean = false "Whether to force the archive to happen synchronously." example default team_folder_id = "123456789" force_async_off = false union_closed TeamFolderArchiveLaunch extends async.LaunchResultBase complete TeamFolderMetadata example default complete = default union TeamFolderArchiveError extends BaseTeamFolderError "" route team_folder/archive/check(async.PollArg, TeamFolderArchiveJobStatus, async.PollError) "Returns the status of an asynchronous job for archiving a team folder. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" union_closed TeamFolderArchiveJobStatus extends async.PollResultBase complete TeamFolderMetadata "The archive job has finished. The value is the metadata for the resulting team folder." failed TeamFolderArchiveError "Error occurred while performing an asynchronous job from :route:`team_folder/archive`." example default complete = default # # Team folder permanently delete # route team_folder/permanently_delete(TeamFolderIdArg, Void, TeamFolderPermanentlyDeleteError) "Permanently deletes an archived team folder. Permission : Team member file access. " attrs owner = "company-dropbox-team" auth = "team" union TeamFolderPermanentlyDeleteError extends BaseTeamFolderError ""