files-com 1.6.15__tar.gz → 1.6.16__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of files-com might be problematic. Click here for more details.
- {files_com-1.6.15/files_com.egg-info → files_com-1.6.16}/PKG-INFO +1 -1
- files_com-1.6.16/_VERSION +1 -0
- {files_com-1.6.15 → files_com-1.6.16/files_com.egg-info}/PKG-INFO +1 -1
- {files_com-1.6.15 → files_com-1.6.16}/files_com.egg-info/SOURCES.txt +4 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/__init__.py +5 -1
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/__init__.py +2 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/site.py +8 -0
- files_com-1.6.16/files_sdk/models/sync.py +470 -0
- files_com-1.6.16/files_sdk/models/sync_run.py +110 -0
- {files_com-1.6.15 → files_com-1.6.16}/pyproject.toml +1 -1
- files_com-1.6.16/tests/test_sync.py +69 -0
- files_com-1.6.16/tests/test_sync_run.py +29 -0
- files_com-1.6.15/_VERSION +0 -1
- {files_com-1.6.15 → files_com-1.6.16}/LICENSE +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/README.md +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_com.egg-info/dependency_links.txt +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_com.egg-info/requires.txt +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_com.egg-info/top_level.txt +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/api.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/api_client.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/error.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/list_obj.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/account_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/action_notification_export.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/action_notification_export_result.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/api_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/api_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/app.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/as2_incoming_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/as2_outgoing_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/as2_partner.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/as2_station.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/auto.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/automation.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/automation_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/automation_run.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bandwidth_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/behavior.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_download.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_notification.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_path.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_recipient.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/bundle_registration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/clickwrap.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/dns_record.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/email_incoming_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/email_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/errors.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/exavault_api_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/external_event.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_comment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_comment_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_migration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_migration_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/file_upload_part.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/folder.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/form_field.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/form_field_set.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/ftp_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/gpg_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/group.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/group_user.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/history.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/history_export.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/history_export_result.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/image.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/inbox_recipient.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/inbox_registration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/inbox_upload.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/invoice.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/invoice_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/ip_address.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/lock.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/message_comment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/message_comment_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/message_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/notification.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/outbound_connection_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/payment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/payment_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/permission.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/preview.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/priority.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/project.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/public_hosting_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/public_ip_address.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/public_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/remote_bandwidth_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/remote_server.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/remote_server_configuration_file.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/request.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/restore.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/session.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/settings_change.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/sftp_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/sftp_host_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/share_group.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/share_group_member.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/siem_http_destination.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/sso_strategy.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/status.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/style.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/sync_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/usage_by_top_level_dir.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/usage_daily_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/usage_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/user.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/user_cipher_use.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/user_lifecycle_rule.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/user_request.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/user_sftp_client_use.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/web_dav_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/models/webhook_test.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/path_util.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/files_sdk/util.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/setup.cfg +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_account_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_action_notification_export.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_action_notification_export_result.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_api_errors.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_api_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_api_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_app.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_as2_incoming_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_as2_outgoing_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_as2_partner.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_as2_station.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_auto.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_automation.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_automation_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_automation_run.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bandwidth_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_behavior.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_download.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_notification.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_path.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_recipient.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_bundle_registration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_clickwrap.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_connection_adapter.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_dns_record.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_email_incoming_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_email_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_errors.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_exavault_api_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_external_event.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_action.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_comment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_comment_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_migration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_migration_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_file_upload_part.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_folder.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_form_field.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_form_field_set.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_ftp_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_gpg_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_group.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_group_user.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_history.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_history_export.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_history_export_result.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_image.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_inbox_recipient.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_inbox_registration.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_inbox_upload.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_invoice.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_invoice_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_ip_address.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_lock.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_message.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_message_comment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_message_comment_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_message_reaction.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_notification.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_outbound_connection_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_path_util.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_payment.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_payment_line_item.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_permission.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_preview.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_priority.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_project.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_public_hosting_request_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_public_ip_address.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_public_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_remote_bandwidth_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_remote_server.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_remote_server_configuration_file.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_request.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_restore.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_session.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_settings_change.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_sftp_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_sftp_host_key.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_share_group.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_share_group_member.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_siem_http_destination.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_site.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_sso_strategy.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_status.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_style.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_sync_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_usage_by_top_level_dir.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_usage_daily_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_usage_snapshot.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_user.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_user_cipher_use.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_user_lifecycle_rule.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_user_request.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_user_sftp_client_use.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_web_dav_action_log.py +0 -0
- {files_com-1.6.15 → files_com-1.6.16}/tests/test_webhook_test.py +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
1.6.16
|
|
@@ -104,7 +104,9 @@ files_sdk/models/snapshot.py
|
|
|
104
104
|
files_sdk/models/sso_strategy.py
|
|
105
105
|
files_sdk/models/status.py
|
|
106
106
|
files_sdk/models/style.py
|
|
107
|
+
files_sdk/models/sync.py
|
|
107
108
|
files_sdk/models/sync_log.py
|
|
109
|
+
files_sdk/models/sync_run.py
|
|
108
110
|
files_sdk/models/usage_by_top_level_dir.py
|
|
109
111
|
files_sdk/models/usage_daily_snapshot.py
|
|
110
112
|
files_sdk/models/usage_snapshot.py
|
|
@@ -206,7 +208,9 @@ tests/test_snapshot.py
|
|
|
206
208
|
tests/test_sso_strategy.py
|
|
207
209
|
tests/test_status.py
|
|
208
210
|
tests/test_style.py
|
|
211
|
+
tests/test_sync.py
|
|
209
212
|
tests/test_sync_log.py
|
|
213
|
+
tests/test_sync_run.py
|
|
210
214
|
tests/test_usage_by_top_level_dir.py
|
|
211
215
|
tests/test_usage_daily_snapshot.py
|
|
212
216
|
tests/test_usage_snapshot.py
|
|
@@ -87,7 +87,9 @@ import files_sdk.models.snapshot as snapshot
|
|
|
87
87
|
import files_sdk.models.sso_strategy as sso_strategy
|
|
88
88
|
import files_sdk.models.status as status
|
|
89
89
|
import files_sdk.models.style as style
|
|
90
|
+
import files_sdk.models.sync as sync
|
|
90
91
|
import files_sdk.models.sync_log as sync_log
|
|
92
|
+
import files_sdk.models.sync_run as sync_run
|
|
91
93
|
import files_sdk.models.usage_by_top_level_dir as usage_by_top_level_dir
|
|
92
94
|
import files_sdk.models.usage_daily_snapshot as usage_daily_snapshot
|
|
93
95
|
import files_sdk.models.usage_snapshot as usage_snapshot
|
|
@@ -193,7 +195,9 @@ from files_sdk.models.snapshot import Snapshot
|
|
|
193
195
|
from files_sdk.models.sso_strategy import SsoStrategy
|
|
194
196
|
from files_sdk.models.status import Status
|
|
195
197
|
from files_sdk.models.style import Style
|
|
198
|
+
from files_sdk.models.sync import Sync
|
|
196
199
|
from files_sdk.models.sync_log import SyncLog
|
|
200
|
+
from files_sdk.models.sync_run import SyncRun
|
|
197
201
|
from files_sdk.models.usage_by_top_level_dir import UsageByTopLevelDir
|
|
198
202
|
from files_sdk.models.usage_daily_snapshot import UsageDailySnapshot
|
|
199
203
|
from files_sdk.models.usage_snapshot import UsageSnapshot
|
|
@@ -215,7 +219,7 @@ session_id = None
|
|
|
215
219
|
source_ip = None
|
|
216
220
|
base_url = "https://app.files.com"
|
|
217
221
|
base_path = "api/rest/v1"
|
|
218
|
-
version = "1.6.
|
|
222
|
+
version = "1.6.16"
|
|
219
223
|
|
|
220
224
|
__version__ = version
|
|
221
225
|
|
|
@@ -92,7 +92,9 @@ from files_sdk.models.snapshot import Snapshot
|
|
|
92
92
|
from files_sdk.models.sso_strategy import SsoStrategy
|
|
93
93
|
from files_sdk.models.status import Status
|
|
94
94
|
from files_sdk.models.style import Style
|
|
95
|
+
from files_sdk.models.sync import Sync
|
|
95
96
|
from files_sdk.models.sync_log import SyncLog
|
|
97
|
+
from files_sdk.models.sync_run import SyncRun
|
|
96
98
|
from files_sdk.models.usage_by_top_level_dir import UsageByTopLevelDir
|
|
97
99
|
from files_sdk.models.usage_daily_snapshot import UsageDailySnapshot
|
|
98
100
|
from files_sdk.models.usage_snapshot import UsageSnapshot
|
|
@@ -65,6 +65,7 @@ class Site:
|
|
|
65
65
|
"desktop_app_session_ip_pinning": None, # boolean - Is desktop app session IP pinning enabled?
|
|
66
66
|
"desktop_app_session_lifetime": None, # int64 - Desktop app session lifetime (in hours)
|
|
67
67
|
"legacy_checksums_mode": None, # boolean - Use legacy checksums mode?
|
|
68
|
+
"migrate_remote_server_sync_to_sync": None, # boolean - If true, we will migrate all remote server syncs to the new Sync model.
|
|
68
69
|
"mobile_app": None, # boolean - Is the mobile app enabled?
|
|
69
70
|
"mobile_app_session_ip_pinning": None, # boolean - Is mobile app session IP pinning enabled?
|
|
70
71
|
"mobile_app_session_lifetime": None, # int64 - Mobile app session lifetime (in hours)
|
|
@@ -263,6 +264,7 @@ def get_usage(params=None, options=None):
|
|
|
263
264
|
# calculate_file_checksums_sha1 - boolean - Calculate SHA1 checksums for files?
|
|
264
265
|
# calculate_file_checksums_sha256 - boolean - Calculate SHA256 checksums for files?
|
|
265
266
|
# legacy_checksums_mode - boolean - Use legacy checksums mode?
|
|
267
|
+
# migrate_remote_server_sync_to_sync - boolean - If true, we will migrate all remote server syncs to the new Sync model.
|
|
266
268
|
# session_expiry - double - Session expiry in hours
|
|
267
269
|
# ssl_required - boolean - Is SSL required? Disabling this is insecure.
|
|
268
270
|
# tls_disabled - boolean - DO NOT ENABLE. This setting allows TLSv1.0 and TLSv1.1 to be used on your site. We intend to remove this capability entirely in early 2024. If set, the `sftp_insecure_ciphers` flag will be automatically set to true.
|
|
@@ -614,6 +616,12 @@ def update(params=None, options=None):
|
|
|
614
616
|
raise InvalidParameterError(
|
|
615
617
|
"Bad parameter: legacy_checksums_mode must be an bool"
|
|
616
618
|
)
|
|
619
|
+
if "migrate_remote_server_sync_to_sync" in params and not isinstance(
|
|
620
|
+
params["migrate_remote_server_sync_to_sync"], bool
|
|
621
|
+
):
|
|
622
|
+
raise InvalidParameterError(
|
|
623
|
+
"Bad parameter: migrate_remote_server_sync_to_sync must be an bool"
|
|
624
|
+
)
|
|
617
625
|
if "session_expiry" in params and not isinstance(
|
|
618
626
|
params["session_expiry"], float
|
|
619
627
|
):
|
|
@@ -0,0 +1,470 @@
|
|
|
1
|
+
import builtins # noqa: F401
|
|
2
|
+
from files_sdk.api import Api # noqa: F401
|
|
3
|
+
from files_sdk.list_obj import ListObj
|
|
4
|
+
from files_sdk.error import ( # noqa: F401
|
|
5
|
+
InvalidParameterError,
|
|
6
|
+
MissingParameterError,
|
|
7
|
+
NotImplementedError,
|
|
8
|
+
)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class Sync:
|
|
12
|
+
default_attributes = {
|
|
13
|
+
"id": None, # int64 - Sync ID
|
|
14
|
+
"name": None, # string - Name for this sync job
|
|
15
|
+
"description": None, # string - Description for this sync job
|
|
16
|
+
"site_id": None, # int64 - Site ID this sync belongs to
|
|
17
|
+
"user_id": None, # int64 - User who created or owns this sync
|
|
18
|
+
"src_path": None, # string - Absolute source path for the sync
|
|
19
|
+
"dest_path": None, # string - Absolute destination path for the sync
|
|
20
|
+
"src_remote_server_id": None, # int64 - Remote server ID for the source (if remote)
|
|
21
|
+
"dest_remote_server_id": None, # int64 - Remote server ID for the destination (if remote)
|
|
22
|
+
"two_way": None, # boolean - Is this a two-way sync?
|
|
23
|
+
"keep_after_copy": None, # boolean - Keep files after copying?
|
|
24
|
+
"delete_empty_folders": None, # boolean - Delete empty folders after sync?
|
|
25
|
+
"disabled": None, # boolean - Is this sync disabled?
|
|
26
|
+
"interval": None, # string - If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
|
|
27
|
+
"trigger": None, # string - Trigger type: daily, custom_schedule, or manual
|
|
28
|
+
"trigger_file": None, # string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
|
|
29
|
+
"include_patterns": None, # array(array) - Array of glob patterns to include
|
|
30
|
+
"exclude_patterns": None, # array(array) - Array of glob patterns to exclude
|
|
31
|
+
"created_at": None, # date-time - When this sync was created
|
|
32
|
+
"updated_at": None, # date-time - When this sync was last updated
|
|
33
|
+
"sync_interval_minutes": None, # int64 - Frequency in minutes between syncs. If set, this value must be greater than or equal to the `remote_sync_interval` value for the site's plan. If left blank, the plan's `remote_sync_interval` will be used. This setting is only used if `trigger` is empty.
|
|
34
|
+
"recurring_day": None, # int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
|
|
35
|
+
"schedule_days_of_week": None, # array(int64) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. 0-based days of the week. 0 is Sunday, 1 is Monday, etc.
|
|
36
|
+
"schedule_times_of_day": None, # array(string) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. Times of day in HH:MM format.
|
|
37
|
+
"schedule_time_zone": None, # string - If trigger is `custom_schedule`, Custom schedule Time Zone for when the sync should be run.
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
def __init__(self, attributes=None, options=None):
|
|
41
|
+
if not isinstance(attributes, dict):
|
|
42
|
+
attributes = {}
|
|
43
|
+
if not isinstance(options, dict):
|
|
44
|
+
options = {}
|
|
45
|
+
self.set_attributes(attributes)
|
|
46
|
+
self.options = options
|
|
47
|
+
|
|
48
|
+
def set_attributes(self, attributes):
|
|
49
|
+
for attribute, default_value in Sync.default_attributes.items():
|
|
50
|
+
setattr(self, attribute, attributes.get(attribute, default_value))
|
|
51
|
+
|
|
52
|
+
def get_attributes(self):
|
|
53
|
+
return {
|
|
54
|
+
k: getattr(self, k, None)
|
|
55
|
+
for k in Sync.default_attributes
|
|
56
|
+
if getattr(self, k, None) is not None
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
# Parameters:
|
|
60
|
+
# name - string - Name for this sync job
|
|
61
|
+
# description - string - Description for this sync job
|
|
62
|
+
# src_path - string - Absolute source path
|
|
63
|
+
# dest_path - string - Absolute destination path
|
|
64
|
+
# src_remote_server_id - int64 - Remote server ID for the source
|
|
65
|
+
# dest_remote_server_id - int64 - Remote server ID for the destination
|
|
66
|
+
# two_way - boolean - Is this a two-way sync?
|
|
67
|
+
# keep_after_copy - boolean - Keep files after copying?
|
|
68
|
+
# delete_empty_folders - boolean - Delete empty folders after sync?
|
|
69
|
+
# disabled - boolean - Is this sync disabled?
|
|
70
|
+
# interval - int64 - Interval in minutes for sync (if scheduled)
|
|
71
|
+
# trigger - string - Trigger type: daily, custom_schedule, or manual
|
|
72
|
+
# trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
|
|
73
|
+
# recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
|
|
74
|
+
# schedule_time_zone - string - If trigger is `custom_schedule`, Custom schedule Time Zone for when the sync should be run.
|
|
75
|
+
# schedule_days_of_week - array(int64) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. 0-based days of the week. 0 is Sunday, 1 is Monday, etc.
|
|
76
|
+
# schedule_times_of_day - array(string) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. Times of day in HH:MM format.
|
|
77
|
+
def update(self, params=None):
|
|
78
|
+
if not isinstance(params, dict):
|
|
79
|
+
params = {}
|
|
80
|
+
|
|
81
|
+
if hasattr(self, "id") and self.id:
|
|
82
|
+
params["id"] = self.id
|
|
83
|
+
else:
|
|
84
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
85
|
+
if "id" not in params:
|
|
86
|
+
raise MissingParameterError("Parameter missing: id")
|
|
87
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
88
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
89
|
+
if "name" in params and not isinstance(params["name"], str):
|
|
90
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
91
|
+
if "description" in params and not isinstance(
|
|
92
|
+
params["description"], str
|
|
93
|
+
):
|
|
94
|
+
raise InvalidParameterError(
|
|
95
|
+
"Bad parameter: description must be an str"
|
|
96
|
+
)
|
|
97
|
+
if "src_path" in params and not isinstance(params["src_path"], str):
|
|
98
|
+
raise InvalidParameterError(
|
|
99
|
+
"Bad parameter: src_path must be an str"
|
|
100
|
+
)
|
|
101
|
+
if "dest_path" in params and not isinstance(params["dest_path"], str):
|
|
102
|
+
raise InvalidParameterError(
|
|
103
|
+
"Bad parameter: dest_path must be an str"
|
|
104
|
+
)
|
|
105
|
+
if "src_remote_server_id" in params and not isinstance(
|
|
106
|
+
params["src_remote_server_id"], int
|
|
107
|
+
):
|
|
108
|
+
raise InvalidParameterError(
|
|
109
|
+
"Bad parameter: src_remote_server_id must be an int"
|
|
110
|
+
)
|
|
111
|
+
if "dest_remote_server_id" in params and not isinstance(
|
|
112
|
+
params["dest_remote_server_id"], int
|
|
113
|
+
):
|
|
114
|
+
raise InvalidParameterError(
|
|
115
|
+
"Bad parameter: dest_remote_server_id must be an int"
|
|
116
|
+
)
|
|
117
|
+
if "interval" in params and not isinstance(params["interval"], int):
|
|
118
|
+
raise InvalidParameterError(
|
|
119
|
+
"Bad parameter: interval must be an int"
|
|
120
|
+
)
|
|
121
|
+
if "trigger" in params and not isinstance(params["trigger"], str):
|
|
122
|
+
raise InvalidParameterError(
|
|
123
|
+
"Bad parameter: trigger must be an str"
|
|
124
|
+
)
|
|
125
|
+
if "trigger_file" in params and not isinstance(
|
|
126
|
+
params["trigger_file"], str
|
|
127
|
+
):
|
|
128
|
+
raise InvalidParameterError(
|
|
129
|
+
"Bad parameter: trigger_file must be an str"
|
|
130
|
+
)
|
|
131
|
+
if "recurring_day" in params and not isinstance(
|
|
132
|
+
params["recurring_day"], int
|
|
133
|
+
):
|
|
134
|
+
raise InvalidParameterError(
|
|
135
|
+
"Bad parameter: recurring_day must be an int"
|
|
136
|
+
)
|
|
137
|
+
if "schedule_time_zone" in params and not isinstance(
|
|
138
|
+
params["schedule_time_zone"], str
|
|
139
|
+
):
|
|
140
|
+
raise InvalidParameterError(
|
|
141
|
+
"Bad parameter: schedule_time_zone must be an str"
|
|
142
|
+
)
|
|
143
|
+
if "schedule_days_of_week" in params and not isinstance(
|
|
144
|
+
params["schedule_days_of_week"], builtins.list
|
|
145
|
+
):
|
|
146
|
+
raise InvalidParameterError(
|
|
147
|
+
"Bad parameter: schedule_days_of_week must be an list"
|
|
148
|
+
)
|
|
149
|
+
if "schedule_times_of_day" in params and not isinstance(
|
|
150
|
+
params["schedule_times_of_day"], builtins.list
|
|
151
|
+
):
|
|
152
|
+
raise InvalidParameterError(
|
|
153
|
+
"Bad parameter: schedule_times_of_day must be an list"
|
|
154
|
+
)
|
|
155
|
+
response, _options = Api.send_request(
|
|
156
|
+
"PATCH",
|
|
157
|
+
"/syncs/{id}".format(id=params["id"]),
|
|
158
|
+
params,
|
|
159
|
+
self.options,
|
|
160
|
+
)
|
|
161
|
+
return response.data
|
|
162
|
+
|
|
163
|
+
def delete(self, params=None):
|
|
164
|
+
if not isinstance(params, dict):
|
|
165
|
+
params = {}
|
|
166
|
+
|
|
167
|
+
if hasattr(self, "id") and self.id:
|
|
168
|
+
params["id"] = self.id
|
|
169
|
+
else:
|
|
170
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
171
|
+
if "id" not in params:
|
|
172
|
+
raise MissingParameterError("Parameter missing: id")
|
|
173
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
174
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
175
|
+
Api.send_request(
|
|
176
|
+
"DELETE",
|
|
177
|
+
"/syncs/{id}".format(id=params["id"]),
|
|
178
|
+
params,
|
|
179
|
+
self.options,
|
|
180
|
+
)
|
|
181
|
+
|
|
182
|
+
def destroy(self, params=None):
|
|
183
|
+
self.delete(params)
|
|
184
|
+
|
|
185
|
+
def save(self):
|
|
186
|
+
if hasattr(self, "id") and self.id:
|
|
187
|
+
new_obj = self.update(self.get_attributes())
|
|
188
|
+
self.set_attributes(new_obj.get_attributes())
|
|
189
|
+
return True
|
|
190
|
+
else:
|
|
191
|
+
new_obj = create(self.get_attributes(), self.options)
|
|
192
|
+
self.set_attributes(new_obj.get_attributes())
|
|
193
|
+
return True
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
# Parameters:
|
|
197
|
+
# cursor - string - Used for pagination. When a list request has more records available, cursors are provided in the response headers `X-Files-Cursor-Next` and `X-Files-Cursor-Prev`. Send one of those cursor value here to resume an existing list from the next available record. Note: many of our SDKs have iterator methods that will automatically handle cursor-based pagination.
|
|
198
|
+
# per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
|
199
|
+
def list(params=None, options=None):
|
|
200
|
+
if not isinstance(params, dict):
|
|
201
|
+
params = {}
|
|
202
|
+
if not isinstance(options, dict):
|
|
203
|
+
options = {}
|
|
204
|
+
if "cursor" in params and not isinstance(params["cursor"], str):
|
|
205
|
+
raise InvalidParameterError("Bad parameter: cursor must be an str")
|
|
206
|
+
if "per_page" in params and not isinstance(params["per_page"], int):
|
|
207
|
+
raise InvalidParameterError("Bad parameter: per_page must be an int")
|
|
208
|
+
return ListObj(Sync, "GET", "/syncs", params, options)
|
|
209
|
+
|
|
210
|
+
|
|
211
|
+
def all(params=None, options=None):
|
|
212
|
+
list(params, options)
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
# Parameters:
|
|
216
|
+
# id (required) - int64 - Sync ID.
|
|
217
|
+
def find(id, params=None, options=None):
|
|
218
|
+
if not isinstance(params, dict):
|
|
219
|
+
params = {}
|
|
220
|
+
if not isinstance(options, dict):
|
|
221
|
+
options = {}
|
|
222
|
+
params["id"] = id
|
|
223
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
224
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
225
|
+
if "id" not in params:
|
|
226
|
+
raise MissingParameterError("Parameter missing: id")
|
|
227
|
+
response, options = Api.send_request(
|
|
228
|
+
"GET", "/syncs/{id}".format(id=params["id"]), params, options
|
|
229
|
+
)
|
|
230
|
+
return Sync(response.data, options)
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
def get(id, params=None, options=None):
|
|
234
|
+
find(id, params, options)
|
|
235
|
+
|
|
236
|
+
|
|
237
|
+
# Parameters:
|
|
238
|
+
# name - string - Name for this sync job
|
|
239
|
+
# description - string - Description for this sync job
|
|
240
|
+
# src_path - string - Absolute source path
|
|
241
|
+
# dest_path - string - Absolute destination path
|
|
242
|
+
# src_remote_server_id - int64 - Remote server ID for the source
|
|
243
|
+
# dest_remote_server_id - int64 - Remote server ID for the destination
|
|
244
|
+
# two_way - boolean - Is this a two-way sync?
|
|
245
|
+
# keep_after_copy - boolean - Keep files after copying?
|
|
246
|
+
# delete_empty_folders - boolean - Delete empty folders after sync?
|
|
247
|
+
# disabled - boolean - Is this sync disabled?
|
|
248
|
+
# interval - int64 - Interval in minutes for sync (if scheduled)
|
|
249
|
+
# trigger - string - Trigger type: daily, custom_schedule, or manual
|
|
250
|
+
# trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
|
|
251
|
+
# recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
|
|
252
|
+
# schedule_time_zone - string - If trigger is `custom_schedule`, Custom schedule Time Zone for when the sync should be run.
|
|
253
|
+
# schedule_days_of_week - array(int64) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. 0-based days of the week. 0 is Sunday, 1 is Monday, etc.
|
|
254
|
+
# schedule_times_of_day - array(string) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. Times of day in HH:MM format.
|
|
255
|
+
def create(params=None, options=None):
|
|
256
|
+
if not isinstance(params, dict):
|
|
257
|
+
params = {}
|
|
258
|
+
if not isinstance(options, dict):
|
|
259
|
+
options = {}
|
|
260
|
+
if "name" in params and not isinstance(params["name"], str):
|
|
261
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
262
|
+
if "description" in params and not isinstance(params["description"], str):
|
|
263
|
+
raise InvalidParameterError(
|
|
264
|
+
"Bad parameter: description must be an str"
|
|
265
|
+
)
|
|
266
|
+
if "src_path" in params and not isinstance(params["src_path"], str):
|
|
267
|
+
raise InvalidParameterError("Bad parameter: src_path must be an str")
|
|
268
|
+
if "dest_path" in params and not isinstance(params["dest_path"], str):
|
|
269
|
+
raise InvalidParameterError("Bad parameter: dest_path must be an str")
|
|
270
|
+
if "src_remote_server_id" in params and not isinstance(
|
|
271
|
+
params["src_remote_server_id"], int
|
|
272
|
+
):
|
|
273
|
+
raise InvalidParameterError(
|
|
274
|
+
"Bad parameter: src_remote_server_id must be an int"
|
|
275
|
+
)
|
|
276
|
+
if "dest_remote_server_id" in params and not isinstance(
|
|
277
|
+
params["dest_remote_server_id"], int
|
|
278
|
+
):
|
|
279
|
+
raise InvalidParameterError(
|
|
280
|
+
"Bad parameter: dest_remote_server_id must be an int"
|
|
281
|
+
)
|
|
282
|
+
if "two_way" in params and not isinstance(params["two_way"], bool):
|
|
283
|
+
raise InvalidParameterError("Bad parameter: two_way must be an bool")
|
|
284
|
+
if "keep_after_copy" in params and not isinstance(
|
|
285
|
+
params["keep_after_copy"], bool
|
|
286
|
+
):
|
|
287
|
+
raise InvalidParameterError(
|
|
288
|
+
"Bad parameter: keep_after_copy must be an bool"
|
|
289
|
+
)
|
|
290
|
+
if "delete_empty_folders" in params and not isinstance(
|
|
291
|
+
params["delete_empty_folders"], bool
|
|
292
|
+
):
|
|
293
|
+
raise InvalidParameterError(
|
|
294
|
+
"Bad parameter: delete_empty_folders must be an bool"
|
|
295
|
+
)
|
|
296
|
+
if "disabled" in params and not isinstance(params["disabled"], bool):
|
|
297
|
+
raise InvalidParameterError("Bad parameter: disabled must be an bool")
|
|
298
|
+
if "interval" in params and not isinstance(params["interval"], int):
|
|
299
|
+
raise InvalidParameterError("Bad parameter: interval must be an int")
|
|
300
|
+
if "trigger" in params and not isinstance(params["trigger"], str):
|
|
301
|
+
raise InvalidParameterError("Bad parameter: trigger must be an str")
|
|
302
|
+
if "trigger_file" in params and not isinstance(
|
|
303
|
+
params["trigger_file"], str
|
|
304
|
+
):
|
|
305
|
+
raise InvalidParameterError(
|
|
306
|
+
"Bad parameter: trigger_file must be an str"
|
|
307
|
+
)
|
|
308
|
+
if "recurring_day" in params and not isinstance(
|
|
309
|
+
params["recurring_day"], int
|
|
310
|
+
):
|
|
311
|
+
raise InvalidParameterError(
|
|
312
|
+
"Bad parameter: recurring_day must be an int"
|
|
313
|
+
)
|
|
314
|
+
if "schedule_time_zone" in params and not isinstance(
|
|
315
|
+
params["schedule_time_zone"], str
|
|
316
|
+
):
|
|
317
|
+
raise InvalidParameterError(
|
|
318
|
+
"Bad parameter: schedule_time_zone must be an str"
|
|
319
|
+
)
|
|
320
|
+
if "schedule_days_of_week" in params and not isinstance(
|
|
321
|
+
params["schedule_days_of_week"], builtins.list
|
|
322
|
+
):
|
|
323
|
+
raise InvalidParameterError(
|
|
324
|
+
"Bad parameter: schedule_days_of_week must be an list"
|
|
325
|
+
)
|
|
326
|
+
if "schedule_times_of_day" in params and not isinstance(
|
|
327
|
+
params["schedule_times_of_day"], builtins.list
|
|
328
|
+
):
|
|
329
|
+
raise InvalidParameterError(
|
|
330
|
+
"Bad parameter: schedule_times_of_day must be an list"
|
|
331
|
+
)
|
|
332
|
+
response, options = Api.send_request("POST", "/syncs", params, options)
|
|
333
|
+
return Sync(response.data, options)
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
def create_migrate_to(params=None, options=None):
|
|
337
|
+
if not isinstance(params, dict):
|
|
338
|
+
params = {}
|
|
339
|
+
if not isinstance(options, dict):
|
|
340
|
+
options = {}
|
|
341
|
+
Api.send_request("POST", "/syncs/migrate_to_syncs", params, options)
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
# Parameters:
|
|
345
|
+
# name - string - Name for this sync job
|
|
346
|
+
# description - string - Description for this sync job
|
|
347
|
+
# src_path - string - Absolute source path
|
|
348
|
+
# dest_path - string - Absolute destination path
|
|
349
|
+
# src_remote_server_id - int64 - Remote server ID for the source
|
|
350
|
+
# dest_remote_server_id - int64 - Remote server ID for the destination
|
|
351
|
+
# two_way - boolean - Is this a two-way sync?
|
|
352
|
+
# keep_after_copy - boolean - Keep files after copying?
|
|
353
|
+
# delete_empty_folders - boolean - Delete empty folders after sync?
|
|
354
|
+
# disabled - boolean - Is this sync disabled?
|
|
355
|
+
# interval - int64 - Interval in minutes for sync (if scheduled)
|
|
356
|
+
# trigger - string - Trigger type: daily, custom_schedule, or manual
|
|
357
|
+
# trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
|
|
358
|
+
# recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
|
|
359
|
+
# schedule_time_zone - string - If trigger is `custom_schedule`, Custom schedule Time Zone for when the sync should be run.
|
|
360
|
+
# schedule_days_of_week - array(int64) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. 0-based days of the week. 0 is Sunday, 1 is Monday, etc.
|
|
361
|
+
# schedule_times_of_day - array(string) - If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. Times of day in HH:MM format.
|
|
362
|
+
def update(id, params=None, options=None):
|
|
363
|
+
if not isinstance(params, dict):
|
|
364
|
+
params = {}
|
|
365
|
+
if not isinstance(options, dict):
|
|
366
|
+
options = {}
|
|
367
|
+
params["id"] = id
|
|
368
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
369
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
370
|
+
if "name" in params and not isinstance(params["name"], str):
|
|
371
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
372
|
+
if "description" in params and not isinstance(params["description"], str):
|
|
373
|
+
raise InvalidParameterError(
|
|
374
|
+
"Bad parameter: description must be an str"
|
|
375
|
+
)
|
|
376
|
+
if "src_path" in params and not isinstance(params["src_path"], str):
|
|
377
|
+
raise InvalidParameterError("Bad parameter: src_path must be an str")
|
|
378
|
+
if "dest_path" in params and not isinstance(params["dest_path"], str):
|
|
379
|
+
raise InvalidParameterError("Bad parameter: dest_path must be an str")
|
|
380
|
+
if "src_remote_server_id" in params and not isinstance(
|
|
381
|
+
params["src_remote_server_id"], int
|
|
382
|
+
):
|
|
383
|
+
raise InvalidParameterError(
|
|
384
|
+
"Bad parameter: src_remote_server_id must be an int"
|
|
385
|
+
)
|
|
386
|
+
if "dest_remote_server_id" in params and not isinstance(
|
|
387
|
+
params["dest_remote_server_id"], int
|
|
388
|
+
):
|
|
389
|
+
raise InvalidParameterError(
|
|
390
|
+
"Bad parameter: dest_remote_server_id must be an int"
|
|
391
|
+
)
|
|
392
|
+
if "two_way" in params and not isinstance(params["two_way"], bool):
|
|
393
|
+
raise InvalidParameterError("Bad parameter: two_way must be an bool")
|
|
394
|
+
if "keep_after_copy" in params and not isinstance(
|
|
395
|
+
params["keep_after_copy"], bool
|
|
396
|
+
):
|
|
397
|
+
raise InvalidParameterError(
|
|
398
|
+
"Bad parameter: keep_after_copy must be an bool"
|
|
399
|
+
)
|
|
400
|
+
if "delete_empty_folders" in params and not isinstance(
|
|
401
|
+
params["delete_empty_folders"], bool
|
|
402
|
+
):
|
|
403
|
+
raise InvalidParameterError(
|
|
404
|
+
"Bad parameter: delete_empty_folders must be an bool"
|
|
405
|
+
)
|
|
406
|
+
if "disabled" in params and not isinstance(params["disabled"], bool):
|
|
407
|
+
raise InvalidParameterError("Bad parameter: disabled must be an bool")
|
|
408
|
+
if "interval" in params and not isinstance(params["interval"], int):
|
|
409
|
+
raise InvalidParameterError("Bad parameter: interval must be an int")
|
|
410
|
+
if "trigger" in params and not isinstance(params["trigger"], str):
|
|
411
|
+
raise InvalidParameterError("Bad parameter: trigger must be an str")
|
|
412
|
+
if "trigger_file" in params and not isinstance(
|
|
413
|
+
params["trigger_file"], str
|
|
414
|
+
):
|
|
415
|
+
raise InvalidParameterError(
|
|
416
|
+
"Bad parameter: trigger_file must be an str"
|
|
417
|
+
)
|
|
418
|
+
if "recurring_day" in params and not isinstance(
|
|
419
|
+
params["recurring_day"], int
|
|
420
|
+
):
|
|
421
|
+
raise InvalidParameterError(
|
|
422
|
+
"Bad parameter: recurring_day must be an int"
|
|
423
|
+
)
|
|
424
|
+
if "schedule_time_zone" in params and not isinstance(
|
|
425
|
+
params["schedule_time_zone"], str
|
|
426
|
+
):
|
|
427
|
+
raise InvalidParameterError(
|
|
428
|
+
"Bad parameter: schedule_time_zone must be an str"
|
|
429
|
+
)
|
|
430
|
+
if "schedule_days_of_week" in params and not isinstance(
|
|
431
|
+
params["schedule_days_of_week"], builtins.list
|
|
432
|
+
):
|
|
433
|
+
raise InvalidParameterError(
|
|
434
|
+
"Bad parameter: schedule_days_of_week must be an list"
|
|
435
|
+
)
|
|
436
|
+
if "schedule_times_of_day" in params and not isinstance(
|
|
437
|
+
params["schedule_times_of_day"], builtins.list
|
|
438
|
+
):
|
|
439
|
+
raise InvalidParameterError(
|
|
440
|
+
"Bad parameter: schedule_times_of_day must be an list"
|
|
441
|
+
)
|
|
442
|
+
if "id" not in params:
|
|
443
|
+
raise MissingParameterError("Parameter missing: id")
|
|
444
|
+
response, options = Api.send_request(
|
|
445
|
+
"PATCH", "/syncs/{id}".format(id=params["id"]), params, options
|
|
446
|
+
)
|
|
447
|
+
return Sync(response.data, options)
|
|
448
|
+
|
|
449
|
+
|
|
450
|
+
def delete(id, params=None, options=None):
|
|
451
|
+
if not isinstance(params, dict):
|
|
452
|
+
params = {}
|
|
453
|
+
if not isinstance(options, dict):
|
|
454
|
+
options = {}
|
|
455
|
+
params["id"] = id
|
|
456
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
457
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
458
|
+
if "id" not in params:
|
|
459
|
+
raise MissingParameterError("Parameter missing: id")
|
|
460
|
+
Api.send_request(
|
|
461
|
+
"DELETE", "/syncs/{id}".format(id=params["id"]), params, options
|
|
462
|
+
)
|
|
463
|
+
|
|
464
|
+
|
|
465
|
+
def destroy(id, params=None, options=None):
|
|
466
|
+
delete(id, params, options)
|
|
467
|
+
|
|
468
|
+
|
|
469
|
+
def new(*args, **kwargs):
|
|
470
|
+
return Sync(*args, **kwargs)
|