Files.com 1.6.416__tar.gz → 1.6.418__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.
- {files_com-1.6.416/files_com.egg-info → files_com-1.6.418}/PKG-INFO +1 -1
- files_com-1.6.418/_VERSION +1 -0
- {files_com-1.6.416 → files_com-1.6.418/files_com.egg-info}/PKG-INFO +1 -1
- {files_com-1.6.416 → files_com-1.6.418}/files_com.egg-info/SOURCES.txt +3 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/__init__.py +39 -1
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/__init__.py +1 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/behavior.py +1 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/custom_domain.py +8 -8
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file.py +174 -0
- files_com-1.6.418/files_sdk/models/secret.py +271 -0
- {files_com-1.6.416 → files_com-1.6.418}/pyproject.toml +1 -1
- files_com-1.6.418/tests/test_file_underscore_destinations.py +32 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_path_util.py +5 -1
- files_com-1.6.418/tests/test_secret.py +69 -0
- files_com-1.6.416/_VERSION +0 -1
- {files_com-1.6.416 → files_com-1.6.418}/LICENSE +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/README.md +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_com.egg-info/dependency_links.txt +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_com.egg-info/requires.txt +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_com.egg-info/top_level.txt +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/api.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/api_client.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/error.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/list_obj.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/account_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/action_notification_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/action_notification_export_result.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/agent_push_update.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/ai_assistant_personality.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/ai_task.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/api_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/api_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/app.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/as2_incoming_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/as2_outgoing_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/as2_partner.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/as2_station.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/auto.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/automation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/automation_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/automation_run.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bandwidth_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_download.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_notification.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_path.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_recipient.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/bundle_registration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/chat_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/chat_session.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/child_site_management_policy.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/clickwrap.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/desktop_configuration_profile.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/dns_record.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/email_incoming_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/email_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/errors.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/event_channel.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/event_delivery_attempt.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/event_record.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/event_subscription.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/event_target.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/exavault_api_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/expectation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/expectation_evaluation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/expectation_incident.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/external_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_comment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_comment_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_migration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_migration_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/file_upload_part.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/folder.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/form_field.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/form_field_set.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/ftp_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/gpg_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/group.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/group_user.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/history.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/history_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/history_export_result.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/holiday_region.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/image.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/inbound_s3_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/inbox_recipient.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/inbox_registration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/inbox_upload.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/invoice.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/invoice_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/ip_address.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/key_lifecycle_rule.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/lock.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/message_comment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/message_comment_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/message_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/metadata_category.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/notification.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/outbound_connection_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/partner.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/partner_channel.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/partner_site.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/partner_site_request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/payment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/payment_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/pending_work_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/permission.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/preview.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/project.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/public_hosting_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/public_ip_address.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/public_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/remote_bandwidth_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/remote_mount_backend.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/remote_server.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/remote_server_configuration_file.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/remote_server_credential.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/restore.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/scheduled_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/scim_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/session.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/settings_change.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sftp_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sftp_host_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/share_group.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/share_group_member.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/siem_http_destination.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/siem_http_destination_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/site.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/site_subdomain_redirect.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sso_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sso_strategy.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/status.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/style.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sync.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sync_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sync_run.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/sync_run_live_transfer.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/usage_by_top_level_dir.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/usage_daily_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/usage_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user_cipher_use.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user_lifecycle_rule.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user_request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user_security_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/user_sftp_client_use.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/web_dav_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/webhook_test.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/workspace.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/models/zip_list_entry.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/path_util.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/files_sdk/util.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/setup.cfg +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_account_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_action_notification_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_action_notification_export_result.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_agent_push_update.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_ai_assistant_personality.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_ai_task.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_api_errors.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_api_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_api_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_app.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_as2_incoming_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_as2_outgoing_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_as2_partner.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_as2_station.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_auto.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_automation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_automation_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_automation_run.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bandwidth_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_behavior.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_download.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_notification.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_path.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_recipient.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_bundle_registration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_chat_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_chat_session.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_child_site_management_policy.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_clickwrap.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_connection_adapter.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_custom_domain.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_decimal_contract.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_desktop_configuration_profile.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_dns_record.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_email_incoming_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_email_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_errors.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_event_channel.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_event_delivery_attempt.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_event_record.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_event_subscription.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_event_target.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_exavault_api_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_expectation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_expectation_evaluation.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_expectation_incident.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_external_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_action.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_comment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_comment_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_migration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_migration_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_file_upload_part.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_folder.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_form_field.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_form_field_set.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_ftp_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_gpg_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_group.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_group_user.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_history.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_history_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_history_export_result.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_holiday_region.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_image.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_inbound_s3_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_inbox_recipient.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_inbox_registration.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_inbox_upload.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_invoice.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_invoice_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_ip_address.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_key_lifecycle_rule.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_lock.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_message.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_message_comment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_message_comment_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_message_reaction.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_metadata_category.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_notification.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_outbound_connection_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_partner.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_partner_channel.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_partner_site.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_partner_site_request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_path_parameter_encoding.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_payment.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_payment_line_item.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_pending_work_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_permission.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_preview.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_project.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_public_hosting_request_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_public_ip_address.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_public_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_remote_bandwidth_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_remote_mount_backend.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_remote_server.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_remote_server_configuration_file.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_remote_server_credential.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_restore.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_scheduled_export.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_scim_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_session.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_settings_change.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sftp_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sftp_host_key.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_share_group.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_share_group_member.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_siem_http_destination.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_siem_http_destination_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_site.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_site_subdomain_redirect.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sso_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sso_strategy.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_status.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_style.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sync.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sync_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sync_run.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_sync_run_live_transfer.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_usage_by_top_level_dir.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_usage_daily_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_usage_snapshot.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user_cipher_use.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user_lifecycle_rule.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user_request.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user_security_event.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_user_sftp_client_use.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_web_dav_action_log.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_webhook_test.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_workspace.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_workspace_id.py +0 -0
- {files_com-1.6.416 → files_com-1.6.418}/tests/test_zip_list_entry.py +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
1.6.418
|
|
@@ -121,6 +121,7 @@ files_sdk/models/request.py
|
|
|
121
121
|
files_sdk/models/restore.py
|
|
122
122
|
files_sdk/models/scheduled_export.py
|
|
123
123
|
files_sdk/models/scim_log.py
|
|
124
|
+
files_sdk/models/secret.py
|
|
124
125
|
files_sdk/models/session.py
|
|
125
126
|
files_sdk/models/settings_change.py
|
|
126
127
|
files_sdk/models/sftp_action_log.py
|
|
@@ -210,6 +211,7 @@ tests/test_file_comment.py
|
|
|
210
211
|
tests/test_file_comment_reaction.py
|
|
211
212
|
tests/test_file_migration.py
|
|
212
213
|
tests/test_file_migration_log.py
|
|
214
|
+
tests/test_file_underscore_destinations.py
|
|
213
215
|
tests/test_file_upload_part.py
|
|
214
216
|
tests/test_folder.py
|
|
215
217
|
tests/test_form_field.py
|
|
@@ -263,6 +265,7 @@ tests/test_request.py
|
|
|
263
265
|
tests/test_restore.py
|
|
264
266
|
tests/test_scheduled_export.py
|
|
265
267
|
tests/test_scim_log.py
|
|
268
|
+
tests/test_secret.py
|
|
266
269
|
tests/test_session.py
|
|
267
270
|
tests/test_settings_change.py
|
|
268
271
|
tests/test_sftp_action_log.py
|
|
@@ -104,6 +104,7 @@ import files_sdk.models.request as request
|
|
|
104
104
|
import files_sdk.models.restore as restore
|
|
105
105
|
import files_sdk.models.scheduled_export as scheduled_export
|
|
106
106
|
import files_sdk.models.scim_log as scim_log
|
|
107
|
+
import files_sdk.models.secret as secret
|
|
107
108
|
import files_sdk.models.session as session
|
|
108
109
|
import files_sdk.models.settings_change as settings_change
|
|
109
110
|
import files_sdk.models.sftp_action_log as sftp_action_log
|
|
@@ -252,6 +253,7 @@ from files_sdk.models.request import Request
|
|
|
252
253
|
from files_sdk.models.restore import Restore
|
|
253
254
|
from files_sdk.models.scheduled_export import ScheduledExport
|
|
254
255
|
from files_sdk.models.scim_log import ScimLog
|
|
256
|
+
from files_sdk.models.secret import Secret
|
|
255
257
|
from files_sdk.models.session import Session
|
|
256
258
|
from files_sdk.models.settings_change import SettingsChange
|
|
257
259
|
from files_sdk.models.sftp_action_log import SftpActionLog
|
|
@@ -298,7 +300,7 @@ source_ip = None
|
|
|
298
300
|
workspace_id = None
|
|
299
301
|
base_url = "https://app.files.com"
|
|
300
302
|
base_path = "api/rest/v1"
|
|
301
|
-
version = "1.6.
|
|
303
|
+
version = "1.6.418"
|
|
302
304
|
|
|
303
305
|
__version__ = version
|
|
304
306
|
|
|
@@ -375,6 +377,42 @@ def upload_file(*args, **kwargs):
|
|
|
375
377
|
return file.upload_file(*args, **kwargs)
|
|
376
378
|
|
|
377
379
|
|
|
380
|
+
def upload_to_remote_server(*args, **kwargs):
|
|
381
|
+
return file.upload_to_remote_server(*args, **kwargs)
|
|
382
|
+
|
|
383
|
+
|
|
384
|
+
def copy_to_remote_server(*args, **kwargs):
|
|
385
|
+
return file.copy_to_remote_server(*args, **kwargs)
|
|
386
|
+
|
|
387
|
+
|
|
388
|
+
def move_to_remote_server(*args, **kwargs):
|
|
389
|
+
return file.move_to_remote_server(*args, **kwargs)
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
def upload_to_snapshot(*args, **kwargs):
|
|
393
|
+
return file.upload_to_snapshot(*args, **kwargs)
|
|
394
|
+
|
|
395
|
+
|
|
396
|
+
def copy_to_snapshot(*args, **kwargs):
|
|
397
|
+
return file.copy_to_snapshot(*args, **kwargs)
|
|
398
|
+
|
|
399
|
+
|
|
400
|
+
def move_to_snapshot(*args, **kwargs):
|
|
401
|
+
return file.move_to_snapshot(*args, **kwargs)
|
|
402
|
+
|
|
403
|
+
|
|
404
|
+
def upload_to_child_site(*args, **kwargs):
|
|
405
|
+
return file.upload_to_child_site(*args, **kwargs)
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
def copy_to_child_site(*args, **kwargs):
|
|
409
|
+
return file.copy_to_child_site(*args, **kwargs)
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
def move_to_child_site(*args, **kwargs):
|
|
413
|
+
return file.move_to_child_site(*args, **kwargs)
|
|
414
|
+
|
|
415
|
+
|
|
378
416
|
def download_file(*args, **kwargs):
|
|
379
417
|
return file.download_file(*args, **kwargs)
|
|
380
418
|
|
|
@@ -113,6 +113,7 @@ from files_sdk.models.request import Request
|
|
|
113
113
|
from files_sdk.models.restore import Restore
|
|
114
114
|
from files_sdk.models.scheduled_export import ScheduledExport
|
|
115
115
|
from files_sdk.models.scim_log import ScimLog
|
|
116
|
+
from files_sdk.models.secret import Secret
|
|
116
117
|
from files_sdk.models.session import Session
|
|
117
118
|
from files_sdk.models.settings_change import SettingsChange
|
|
118
119
|
from files_sdk.models.sftp_action_log import SftpActionLog
|
|
@@ -18,6 +18,7 @@ class Behavior:
|
|
|
18
18
|
"name": None, # string - Name for this behavior.
|
|
19
19
|
"description": None, # string - Description for this behavior.
|
|
20
20
|
"value": None, # object - Settings for this behavior. See the section above for an example value to provide here. Formatting is different for each Behavior type. May be sent as nested JSON or a single JSON-encoded string. If using XML encoding for the API call, this data must be sent as a JSON-encoded string.
|
|
21
|
+
"public_hosting_url": None, # string - Public URL for this publicly hosted folder when the `Serve Publicly` behavior has a key configured. When a Custom Domain with `public_hosting` destination is attached to this behavior, the URL uses that domain. Otherwise it uses the site's `subdomain.hosted-by-files.com` host.
|
|
21
22
|
"disable_parent_folder_behavior": None, # boolean - If true, the parent folder's behavior will be disabled for this folder and its children.
|
|
22
23
|
"recursive": None, # boolean - Whether this behavior is recursive for this record. `always` behaviors are always `true`, `never` behaviors are always `false`, and `sometimes` behaviors may be either value.
|
|
23
24
|
"attachment_file": None, # file - Certain behaviors may require a file, for instance, the `watermark` behavior requires a watermark image. Attach that file here.
|
|
@@ -13,11 +13,11 @@ class CustomDomain:
|
|
|
13
13
|
default_attributes = {
|
|
14
14
|
"id": None, # int64 - Custom Domain ID.
|
|
15
15
|
"domain": None, # string - Customer-owned domain name.
|
|
16
|
-
"destination": None, # string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `
|
|
16
|
+
"destination": None, # string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, `s3_endpoint`, or `unassigned` (not routing traffic). Set to `unassigned` automatically when a bound `public_hosting` folder behavior is deleted, and can be set manually via the API for any reason.
|
|
17
17
|
"dns_status": None, # string - Current DNS verification status.
|
|
18
18
|
"ssl_certificate_id": None, # int64 - Current SSL certificate ID.
|
|
19
19
|
"brick_managed": None, # boolean - Is this domain's SSL certificate automatically managed and renewed by Files.com?
|
|
20
|
-
"folder_behavior_id": None, # int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
|
|
20
|
+
"folder_behavior_id": None, # int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior. Preserved as historical context when `destination` becomes `unassigned`.
|
|
21
21
|
"created_at": None, # date-time - When this Custom Domain was created.
|
|
22
22
|
"updated_at": None, # date-time - When this Custom Domain was last updated.
|
|
23
23
|
}
|
|
@@ -47,8 +47,8 @@ class CustomDomain:
|
|
|
47
47
|
return attrs
|
|
48
48
|
|
|
49
49
|
# Parameters:
|
|
50
|
-
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `
|
|
51
|
-
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
|
|
50
|
+
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, `s3_endpoint`, or `unassigned` (not routing traffic). Set to `unassigned` automatically when a bound `public_hosting` folder behavior is deleted, and can be set manually via the API for any reason.
|
|
51
|
+
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior. Preserved as historical context when `destination` becomes `unassigned`.
|
|
52
52
|
# ssl_certificate_id - int64 - Current SSL certificate ID.
|
|
53
53
|
# domain - string - Customer-owned domain name.
|
|
54
54
|
def update(self, params=None):
|
|
@@ -176,8 +176,8 @@ def get(id, params=None, options=None):
|
|
|
176
176
|
|
|
177
177
|
|
|
178
178
|
# Parameters:
|
|
179
|
-
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `
|
|
180
|
-
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
|
|
179
|
+
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, `s3_endpoint`, or `unassigned` (not routing traffic). Set to `unassigned` automatically when a bound `public_hosting` folder behavior is deleted, and can be set manually via the API for any reason.
|
|
180
|
+
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior. Preserved as historical context when `destination` becomes `unassigned`.
|
|
181
181
|
# ssl_certificate_id - int64 - Current SSL certificate ID.
|
|
182
182
|
# domain (required) - string - Customer-owned domain name.
|
|
183
183
|
def create(params=None, options=None):
|
|
@@ -212,8 +212,8 @@ def create(params=None, options=None):
|
|
|
212
212
|
|
|
213
213
|
|
|
214
214
|
# Parameters:
|
|
215
|
-
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `
|
|
216
|
-
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
|
|
215
|
+
# destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, `s3_endpoint`, or `unassigned` (not routing traffic). Set to `unassigned` automatically when a bound `public_hosting` folder behavior is deleted, and can be set manually via the API for any reason.
|
|
216
|
+
# folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior. Preserved as historical context when `destination` becomes `unassigned`.
|
|
217
217
|
# ssl_certificate_id - int64 - Current SSL certificate ID.
|
|
218
218
|
# domain - string - Customer-owned domain name.
|
|
219
219
|
def update(id, params=None, options=None):
|
|
@@ -4,6 +4,7 @@ from builtins import open as builtin_open
|
|
|
4
4
|
from datetime import datetime
|
|
5
5
|
import io
|
|
6
6
|
from pathlib import Path
|
|
7
|
+
import files_sdk.path_util as path_util
|
|
7
8
|
from files_sdk.models.zip_list_entry import ZipListEntry
|
|
8
9
|
from files_sdk.models.file_action import FileAction
|
|
9
10
|
from files_sdk.models.file_upload_part import FileUploadPart
|
|
@@ -215,6 +216,64 @@ class File:
|
|
|
215
216
|
with builtin_open(output_file, "wb") as file:
|
|
216
217
|
self.download_content(file)
|
|
217
218
|
|
|
219
|
+
def copy_to_remote_server(
|
|
220
|
+
self, remote_server_id, destination, params=None
|
|
221
|
+
):
|
|
222
|
+
if not isinstance(params, dict):
|
|
223
|
+
params = {}
|
|
224
|
+
params = params.copy()
|
|
225
|
+
params["destination"] = _underscore_destination_path(
|
|
226
|
+
"RemoteServers", remote_server_id, destination
|
|
227
|
+
)
|
|
228
|
+
return copy(self.path, params, self.options)
|
|
229
|
+
|
|
230
|
+
def move_to_remote_server(
|
|
231
|
+
self, remote_server_id, destination, params=None
|
|
232
|
+
):
|
|
233
|
+
if not isinstance(params, dict):
|
|
234
|
+
params = {}
|
|
235
|
+
params = params.copy()
|
|
236
|
+
params["destination"] = _underscore_destination_path(
|
|
237
|
+
"RemoteServers", remote_server_id, destination
|
|
238
|
+
)
|
|
239
|
+
return move(self.path, params, self.options)
|
|
240
|
+
|
|
241
|
+
def copy_to_snapshot(self, snapshot_id, destination, params=None):
|
|
242
|
+
if not isinstance(params, dict):
|
|
243
|
+
params = {}
|
|
244
|
+
params = params.copy()
|
|
245
|
+
params["destination"] = _underscore_destination_path(
|
|
246
|
+
"Snapshots", snapshot_id, destination
|
|
247
|
+
)
|
|
248
|
+
return copy(self.path, params, self.options)
|
|
249
|
+
|
|
250
|
+
def move_to_snapshot(self, snapshot_id, destination, params=None):
|
|
251
|
+
if not isinstance(params, dict):
|
|
252
|
+
params = {}
|
|
253
|
+
params = params.copy()
|
|
254
|
+
params["destination"] = _underscore_destination_path(
|
|
255
|
+
"Snapshots", snapshot_id, destination
|
|
256
|
+
)
|
|
257
|
+
return move(self.path, params, self.options)
|
|
258
|
+
|
|
259
|
+
def copy_to_child_site(self, site_id, destination, params=None):
|
|
260
|
+
if not isinstance(params, dict):
|
|
261
|
+
params = {}
|
|
262
|
+
params = params.copy()
|
|
263
|
+
params["destination"] = _underscore_destination_path(
|
|
264
|
+
"Sites", site_id, destination
|
|
265
|
+
)
|
|
266
|
+
return copy(self.path, params, self.options)
|
|
267
|
+
|
|
268
|
+
def move_to_child_site(self, site_id, destination, params=None):
|
|
269
|
+
if not isinstance(params, dict):
|
|
270
|
+
params = {}
|
|
271
|
+
params = params.copy()
|
|
272
|
+
params["destination"] = _underscore_destination_path(
|
|
273
|
+
"Sites", site_id, destination
|
|
274
|
+
)
|
|
275
|
+
return move(self.path, params, self.options)
|
|
276
|
+
|
|
218
277
|
# Download File
|
|
219
278
|
#
|
|
220
279
|
# Parameters:
|
|
@@ -1304,6 +1363,12 @@ def begin_upload(path, params=None, options=None):
|
|
|
1304
1363
|
]
|
|
1305
1364
|
|
|
1306
1365
|
|
|
1366
|
+
def _underscore_destination_path(root, destination_id, relative_path=None):
|
|
1367
|
+
return path_util.normalize(
|
|
1368
|
+
f"_/{root}/{destination_id}/{relative_path or ''}"
|
|
1369
|
+
)
|
|
1370
|
+
|
|
1371
|
+
|
|
1307
1372
|
def open(path, mode="r", options=None):
|
|
1308
1373
|
if not isinstance(options, dict):
|
|
1309
1374
|
options = {}
|
|
@@ -1385,6 +1450,115 @@ def upload_file(path, destination=None, options=None, params=None):
|
|
|
1385
1450
|
create(destination, final_params, options)
|
|
1386
1451
|
|
|
1387
1452
|
|
|
1453
|
+
def upload_to_remote_server(
|
|
1454
|
+
path, remote_server_id, destination=None, options=None, params=None
|
|
1455
|
+
):
|
|
1456
|
+
if destination is None:
|
|
1457
|
+
destination = Path(path).name
|
|
1458
|
+
return upload_file(
|
|
1459
|
+
path,
|
|
1460
|
+
_underscore_destination_path(
|
|
1461
|
+
"RemoteServers", remote_server_id, destination
|
|
1462
|
+
),
|
|
1463
|
+
options,
|
|
1464
|
+
params,
|
|
1465
|
+
)
|
|
1466
|
+
|
|
1467
|
+
|
|
1468
|
+
def copy_to_remote_server(
|
|
1469
|
+
path, remote_server_id, destination, params=None, options=None
|
|
1470
|
+
):
|
|
1471
|
+
if not isinstance(params, dict):
|
|
1472
|
+
params = {}
|
|
1473
|
+
params = params.copy()
|
|
1474
|
+
params["destination"] = _underscore_destination_path(
|
|
1475
|
+
"RemoteServers", remote_server_id, destination
|
|
1476
|
+
)
|
|
1477
|
+
return copy(path, params, options)
|
|
1478
|
+
|
|
1479
|
+
|
|
1480
|
+
def move_to_remote_server(
|
|
1481
|
+
path, remote_server_id, destination, params=None, options=None
|
|
1482
|
+
):
|
|
1483
|
+
if not isinstance(params, dict):
|
|
1484
|
+
params = {}
|
|
1485
|
+
params = params.copy()
|
|
1486
|
+
params["destination"] = _underscore_destination_path(
|
|
1487
|
+
"RemoteServers", remote_server_id, destination
|
|
1488
|
+
)
|
|
1489
|
+
return move(path, params, options)
|
|
1490
|
+
|
|
1491
|
+
|
|
1492
|
+
def upload_to_snapshot(
|
|
1493
|
+
path, snapshot_id, destination=None, options=None, params=None
|
|
1494
|
+
):
|
|
1495
|
+
if destination is None:
|
|
1496
|
+
destination = Path(path).name
|
|
1497
|
+
return upload_file(
|
|
1498
|
+
path,
|
|
1499
|
+
_underscore_destination_path("Snapshots", snapshot_id, destination),
|
|
1500
|
+
options,
|
|
1501
|
+
params,
|
|
1502
|
+
)
|
|
1503
|
+
|
|
1504
|
+
|
|
1505
|
+
def copy_to_snapshot(
|
|
1506
|
+
path, snapshot_id, destination, params=None, options=None
|
|
1507
|
+
):
|
|
1508
|
+
if not isinstance(params, dict):
|
|
1509
|
+
params = {}
|
|
1510
|
+
params = params.copy()
|
|
1511
|
+
params["destination"] = _underscore_destination_path(
|
|
1512
|
+
"Snapshots", snapshot_id, destination
|
|
1513
|
+
)
|
|
1514
|
+
return copy(path, params, options)
|
|
1515
|
+
|
|
1516
|
+
|
|
1517
|
+
def move_to_snapshot(
|
|
1518
|
+
path, snapshot_id, destination, params=None, options=None
|
|
1519
|
+
):
|
|
1520
|
+
if not isinstance(params, dict):
|
|
1521
|
+
params = {}
|
|
1522
|
+
params = params.copy()
|
|
1523
|
+
params["destination"] = _underscore_destination_path(
|
|
1524
|
+
"Snapshots", snapshot_id, destination
|
|
1525
|
+
)
|
|
1526
|
+
return move(path, params, options)
|
|
1527
|
+
|
|
1528
|
+
|
|
1529
|
+
def upload_to_child_site(
|
|
1530
|
+
path, site_id, destination=None, options=None, params=None
|
|
1531
|
+
):
|
|
1532
|
+
if destination is None:
|
|
1533
|
+
destination = Path(path).name
|
|
1534
|
+
return upload_file(
|
|
1535
|
+
path,
|
|
1536
|
+
_underscore_destination_path("Sites", site_id, destination),
|
|
1537
|
+
options,
|
|
1538
|
+
params,
|
|
1539
|
+
)
|
|
1540
|
+
|
|
1541
|
+
|
|
1542
|
+
def copy_to_child_site(path, site_id, destination, params=None, options=None):
|
|
1543
|
+
if not isinstance(params, dict):
|
|
1544
|
+
params = {}
|
|
1545
|
+
params = params.copy()
|
|
1546
|
+
params["destination"] = _underscore_destination_path(
|
|
1547
|
+
"Sites", site_id, destination
|
|
1548
|
+
)
|
|
1549
|
+
return copy(path, params, options)
|
|
1550
|
+
|
|
1551
|
+
|
|
1552
|
+
def move_to_child_site(path, site_id, destination, params=None, options=None):
|
|
1553
|
+
if not isinstance(params, dict):
|
|
1554
|
+
params = {}
|
|
1555
|
+
params = params.copy()
|
|
1556
|
+
params["destination"] = _underscore_destination_path(
|
|
1557
|
+
"Sites", site_id, destination
|
|
1558
|
+
)
|
|
1559
|
+
return move(path, params, options)
|
|
1560
|
+
|
|
1561
|
+
|
|
1388
1562
|
def download_file(path, local_path=None, options=None):
|
|
1389
1563
|
if not isinstance(options, dict):
|
|
1390
1564
|
options = {}
|
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
import builtins # noqa: F401
|
|
2
|
+
from urllib.parse import quote
|
|
3
|
+
from files_sdk.api import Api # noqa: F401
|
|
4
|
+
from files_sdk.list_obj import ListObj
|
|
5
|
+
from files_sdk.error import ( # noqa: F401
|
|
6
|
+
InvalidParameterError,
|
|
7
|
+
MissingParameterError,
|
|
8
|
+
NotImplementedError,
|
|
9
|
+
)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class Secret:
|
|
13
|
+
default_attributes = {
|
|
14
|
+
"id": None, # int64 - Secret ID.
|
|
15
|
+
"workspace_id": None, # int64 - Workspace ID. 0 means the default workspace.
|
|
16
|
+
"name": None, # string - Secret name.
|
|
17
|
+
"description": None, # string - Internal description for your reference.
|
|
18
|
+
"secret_type": None, # string - Secret type.
|
|
19
|
+
"metadata": None, # object - Non-secret metadata for the Secret type.
|
|
20
|
+
"value_field_names": None, # array(string) - Names of configured secret value fields. Secret values are never returned.
|
|
21
|
+
"created_at": None, # date-time - Secret create date/time.
|
|
22
|
+
"updated_at": None, # date-time - Secret update date/time.
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
def __init__(self, attributes=None, options=None):
|
|
26
|
+
if not isinstance(attributes, dict):
|
|
27
|
+
attributes = {}
|
|
28
|
+
if not isinstance(options, dict):
|
|
29
|
+
options = {}
|
|
30
|
+
self.set_attributes(attributes)
|
|
31
|
+
self.options = options
|
|
32
|
+
|
|
33
|
+
def set_attributes(self, attributes):
|
|
34
|
+
for attribute, default_value in Secret.default_attributes.items():
|
|
35
|
+
value = attributes.get(attribute, default_value)
|
|
36
|
+
setattr(self, attribute, value)
|
|
37
|
+
|
|
38
|
+
def get_attributes(self):
|
|
39
|
+
attrs = {
|
|
40
|
+
k: getattr(self, k, None)
|
|
41
|
+
for k in Secret.default_attributes
|
|
42
|
+
if getattr(self, k, None) is not None
|
|
43
|
+
}
|
|
44
|
+
return attrs
|
|
45
|
+
|
|
46
|
+
# Parameters:
|
|
47
|
+
# name - string - Secret name.
|
|
48
|
+
# description - string - Internal description for your reference.
|
|
49
|
+
# secret_type - string - Secret type.
|
|
50
|
+
# metadata - object - Non-secret metadata for the Secret type.
|
|
51
|
+
def update(self, params=None):
|
|
52
|
+
if not isinstance(params, dict):
|
|
53
|
+
params = {}
|
|
54
|
+
|
|
55
|
+
if hasattr(self, "id") and self.id:
|
|
56
|
+
params["id"] = self.id
|
|
57
|
+
else:
|
|
58
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
59
|
+
if "id" not in params:
|
|
60
|
+
raise MissingParameterError("Parameter missing: id")
|
|
61
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
62
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
63
|
+
if "name" in params and not isinstance(params["name"], str):
|
|
64
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
65
|
+
if "description" in params and not isinstance(
|
|
66
|
+
params["description"], str
|
|
67
|
+
):
|
|
68
|
+
raise InvalidParameterError(
|
|
69
|
+
"Bad parameter: description must be an str"
|
|
70
|
+
)
|
|
71
|
+
if "secret_type" in params and not isinstance(
|
|
72
|
+
params["secret_type"], str
|
|
73
|
+
):
|
|
74
|
+
raise InvalidParameterError(
|
|
75
|
+
"Bad parameter: secret_type must be an str"
|
|
76
|
+
)
|
|
77
|
+
response, _options = Api.send_request(
|
|
78
|
+
"PATCH",
|
|
79
|
+
"/secrets/{id}".format(id=quote(str(params["id"]), safe="")),
|
|
80
|
+
params,
|
|
81
|
+
self.options,
|
|
82
|
+
)
|
|
83
|
+
return response.data
|
|
84
|
+
|
|
85
|
+
def delete(self, params=None):
|
|
86
|
+
if not isinstance(params, dict):
|
|
87
|
+
params = {}
|
|
88
|
+
|
|
89
|
+
if hasattr(self, "id") and self.id:
|
|
90
|
+
params["id"] = self.id
|
|
91
|
+
else:
|
|
92
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
93
|
+
if "id" not in params:
|
|
94
|
+
raise MissingParameterError("Parameter missing: id")
|
|
95
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
96
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
97
|
+
Api.send_request(
|
|
98
|
+
"DELETE",
|
|
99
|
+
"/secrets/{id}".format(id=quote(str(params["id"]), safe="")),
|
|
100
|
+
params,
|
|
101
|
+
self.options,
|
|
102
|
+
)
|
|
103
|
+
|
|
104
|
+
def destroy(self, params=None):
|
|
105
|
+
self.delete(params)
|
|
106
|
+
|
|
107
|
+
def save(self):
|
|
108
|
+
if hasattr(self, "id") and self.id:
|
|
109
|
+
new_obj = self.update(self.get_attributes())
|
|
110
|
+
self.set_attributes(new_obj.get_attributes())
|
|
111
|
+
return True
|
|
112
|
+
else:
|
|
113
|
+
new_obj = create(self.get_attributes(), self.options)
|
|
114
|
+
self.set_attributes(new_obj.get_attributes())
|
|
115
|
+
return True
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
# Parameters:
|
|
119
|
+
# 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.
|
|
120
|
+
# per_page - int64 - Number of records to show per page. (Max: 10000, 1,000 or less is recommended).
|
|
121
|
+
# sort_by - object - If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are `workspace_id`, `name` or `secret_type`.
|
|
122
|
+
# filter - object - If set, return records where the specified field is equal to the supplied value. Valid fields are `workspace_id`, `name` or `secret_type`. Valid field combinations are `[ workspace_id, name ]`, `[ workspace_id, secret_type ]`, `[ secret_type, name ]` or `[ workspace_id, secret_type, name ]`.
|
|
123
|
+
# filter_prefix - object - If set, return records where the specified field is prefixed by the supplied value. Valid fields are `name`.
|
|
124
|
+
def list(params=None, options=None):
|
|
125
|
+
if not isinstance(params, dict):
|
|
126
|
+
params = {}
|
|
127
|
+
if not isinstance(options, dict):
|
|
128
|
+
options = {}
|
|
129
|
+
if "cursor" in params and not isinstance(params["cursor"], str):
|
|
130
|
+
raise InvalidParameterError("Bad parameter: cursor must be an str")
|
|
131
|
+
if "per_page" in params and not isinstance(params["per_page"], int):
|
|
132
|
+
raise InvalidParameterError("Bad parameter: per_page must be an int")
|
|
133
|
+
if "sort_by" in params and not isinstance(params["sort_by"], dict):
|
|
134
|
+
raise InvalidParameterError("Bad parameter: sort_by must be an dict")
|
|
135
|
+
if "filter" in params and not isinstance(params["filter"], dict):
|
|
136
|
+
raise InvalidParameterError("Bad parameter: filter must be an dict")
|
|
137
|
+
if "filter_prefix" in params and not isinstance(
|
|
138
|
+
params["filter_prefix"], dict
|
|
139
|
+
):
|
|
140
|
+
raise InvalidParameterError(
|
|
141
|
+
"Bad parameter: filter_prefix must be an dict"
|
|
142
|
+
)
|
|
143
|
+
return ListObj(Secret, "GET", "/secrets", params, options)
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
def all(params=None, options=None):
|
|
147
|
+
list(params, options)
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
# Parameters:
|
|
151
|
+
# id (required) - int64 - Secret ID.
|
|
152
|
+
def find(id, params=None, options=None):
|
|
153
|
+
if not isinstance(params, dict):
|
|
154
|
+
params = {}
|
|
155
|
+
if not isinstance(options, dict):
|
|
156
|
+
options = {}
|
|
157
|
+
params["id"] = id
|
|
158
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
159
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
160
|
+
if "id" not in params:
|
|
161
|
+
raise MissingParameterError("Parameter missing: id")
|
|
162
|
+
response, options = Api.send_request(
|
|
163
|
+
"GET",
|
|
164
|
+
"/secrets/{id}".format(id=quote(str(params["id"]), safe="")),
|
|
165
|
+
params,
|
|
166
|
+
options,
|
|
167
|
+
)
|
|
168
|
+
return Secret(response.data, options)
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
def get(id, params=None, options=None):
|
|
172
|
+
find(id, params, options)
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
# Parameters:
|
|
176
|
+
# name (required) - string - Secret name.
|
|
177
|
+
# description - string - Internal description for your reference.
|
|
178
|
+
# secret_type (required) - string - Secret type.
|
|
179
|
+
# metadata - object - Non-secret metadata for the Secret type.
|
|
180
|
+
# workspace_id - int64 - Workspace ID. 0 means the default workspace.
|
|
181
|
+
def create(params=None, options=None):
|
|
182
|
+
if not isinstance(params, dict):
|
|
183
|
+
params = {}
|
|
184
|
+
if not isinstance(options, dict):
|
|
185
|
+
options = {}
|
|
186
|
+
if "name" in params and not isinstance(params["name"], str):
|
|
187
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
188
|
+
if "description" in params and not isinstance(params["description"], str):
|
|
189
|
+
raise InvalidParameterError(
|
|
190
|
+
"Bad parameter: description must be an str"
|
|
191
|
+
)
|
|
192
|
+
if "secret_type" in params and not isinstance(params["secret_type"], str):
|
|
193
|
+
raise InvalidParameterError(
|
|
194
|
+
"Bad parameter: secret_type must be an str"
|
|
195
|
+
)
|
|
196
|
+
if "metadata" in params and not isinstance(params["metadata"], dict):
|
|
197
|
+
raise InvalidParameterError("Bad parameter: metadata must be an dict")
|
|
198
|
+
if "workspace_id" in params and not isinstance(
|
|
199
|
+
params["workspace_id"], int
|
|
200
|
+
):
|
|
201
|
+
raise InvalidParameterError(
|
|
202
|
+
"Bad parameter: workspace_id must be an int"
|
|
203
|
+
)
|
|
204
|
+
if "name" not in params:
|
|
205
|
+
raise MissingParameterError("Parameter missing: name")
|
|
206
|
+
if "secret_type" not in params:
|
|
207
|
+
raise MissingParameterError("Parameter missing: secret_type")
|
|
208
|
+
response, options = Api.send_request("POST", "/secrets", params, options)
|
|
209
|
+
return Secret(response.data, options)
|
|
210
|
+
|
|
211
|
+
|
|
212
|
+
# Parameters:
|
|
213
|
+
# name - string - Secret name.
|
|
214
|
+
# description - string - Internal description for your reference.
|
|
215
|
+
# secret_type - string - Secret type.
|
|
216
|
+
# metadata - object - Non-secret metadata for the Secret type.
|
|
217
|
+
def update(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 "name" in params and not isinstance(params["name"], str):
|
|
226
|
+
raise InvalidParameterError("Bad parameter: name must be an str")
|
|
227
|
+
if "description" in params and not isinstance(params["description"], str):
|
|
228
|
+
raise InvalidParameterError(
|
|
229
|
+
"Bad parameter: description must be an str"
|
|
230
|
+
)
|
|
231
|
+
if "secret_type" in params and not isinstance(params["secret_type"], str):
|
|
232
|
+
raise InvalidParameterError(
|
|
233
|
+
"Bad parameter: secret_type must be an str"
|
|
234
|
+
)
|
|
235
|
+
if "metadata" in params and not isinstance(params["metadata"], dict):
|
|
236
|
+
raise InvalidParameterError("Bad parameter: metadata must be an dict")
|
|
237
|
+
if "id" not in params:
|
|
238
|
+
raise MissingParameterError("Parameter missing: id")
|
|
239
|
+
response, options = Api.send_request(
|
|
240
|
+
"PATCH",
|
|
241
|
+
"/secrets/{id}".format(id=quote(str(params["id"]), safe="")),
|
|
242
|
+
params,
|
|
243
|
+
options,
|
|
244
|
+
)
|
|
245
|
+
return Secret(response.data, options)
|
|
246
|
+
|
|
247
|
+
|
|
248
|
+
def delete(id, params=None, options=None):
|
|
249
|
+
if not isinstance(params, dict):
|
|
250
|
+
params = {}
|
|
251
|
+
if not isinstance(options, dict):
|
|
252
|
+
options = {}
|
|
253
|
+
params["id"] = id
|
|
254
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
255
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
256
|
+
if "id" not in params:
|
|
257
|
+
raise MissingParameterError("Parameter missing: id")
|
|
258
|
+
Api.send_request(
|
|
259
|
+
"DELETE",
|
|
260
|
+
"/secrets/{id}".format(id=quote(str(params["id"]), safe="")),
|
|
261
|
+
params,
|
|
262
|
+
options,
|
|
263
|
+
)
|
|
264
|
+
|
|
265
|
+
|
|
266
|
+
def destroy(id, params=None, options=None):
|
|
267
|
+
delete(id, params, options)
|
|
268
|
+
|
|
269
|
+
|
|
270
|
+
def new(*args, **kwargs):
|
|
271
|
+
return Secret(*args, **kwargs)
|