Files.com 1.6.391__tar.gz → 1.6.393__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 changed (289) hide show
  1. files_com-1.6.391/README.md → files_com-1.6.393/PKG-INFO +17 -21
  2. files_com-1.6.391/PKG-INFO → files_com-1.6.393/README.md +5 -33
  3. files_com-1.6.393/_VERSION +1 -0
  4. {files_com-1.6.391 → files_com-1.6.393}/files_com.egg-info/PKG-INFO +6 -22
  5. {files_com-1.6.391 → files_com-1.6.393}/files_com.egg-info/SOURCES.txt +3 -0
  6. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/__init__.py +22 -2
  7. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/api.py +2 -0
  8. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/api_client.py +10 -2
  9. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/__init__.py +1 -0
  10. files_com-1.6.393/files_sdk/models/custom_domain.py +271 -0
  11. {files_com-1.6.391 → files_com-1.6.393}/pyproject.toml +1 -1
  12. files_com-1.6.393/tests/test_custom_domain.py +68 -0
  13. files_com-1.6.393/tests/test_workspace_id.py +90 -0
  14. files_com-1.6.391/_VERSION +0 -1
  15. {files_com-1.6.391 → files_com-1.6.393}/LICENSE +0 -0
  16. {files_com-1.6.391 → files_com-1.6.393}/files_com.egg-info/dependency_links.txt +0 -0
  17. {files_com-1.6.391 → files_com-1.6.393}/files_com.egg-info/requires.txt +0 -0
  18. {files_com-1.6.391 → files_com-1.6.393}/files_com.egg-info/top_level.txt +0 -0
  19. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/error.py +0 -0
  20. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/list_obj.py +0 -0
  21. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/account_line_item.py +0 -0
  22. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/action.py +0 -0
  23. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/action_log.py +0 -0
  24. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/action_notification_export.py +0 -0
  25. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/action_notification_export_result.py +0 -0
  26. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/agent_push_update.py +0 -0
  27. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/api_key.py +0 -0
  28. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/api_request_log.py +0 -0
  29. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/app.py +0 -0
  30. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/as2_incoming_message.py +0 -0
  31. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/as2_outgoing_message.py +0 -0
  32. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/as2_partner.py +0 -0
  33. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/as2_station.py +0 -0
  34. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/auto.py +0 -0
  35. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/automation.py +0 -0
  36. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/automation_log.py +0 -0
  37. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/automation_run.py +0 -0
  38. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bandwidth_snapshot.py +0 -0
  39. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/behavior.py +0 -0
  40. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle.py +0 -0
  41. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_action.py +0 -0
  42. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_download.py +0 -0
  43. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_notification.py +0 -0
  44. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_path.py +0 -0
  45. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_recipient.py +0 -0
  46. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/bundle_registration.py +0 -0
  47. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/child_site_management_policy.py +0 -0
  48. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/clickwrap.py +0 -0
  49. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/desktop_configuration_profile.py +0 -0
  50. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/dns_record.py +0 -0
  51. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/email_incoming_message.py +0 -0
  52. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/email_log.py +0 -0
  53. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/errors.py +0 -0
  54. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/event_channel.py +0 -0
  55. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/event_delivery_attempt.py +0 -0
  56. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/event_record.py +0 -0
  57. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/event_subscription.py +0 -0
  58. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/event_target.py +0 -0
  59. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/exavault_api_request_log.py +0 -0
  60. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/expectation.py +0 -0
  61. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/expectation_evaluation.py +0 -0
  62. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/expectation_incident.py +0 -0
  63. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/external_event.py +0 -0
  64. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file.py +0 -0
  65. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_action.py +0 -0
  66. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_comment.py +0 -0
  67. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_comment_reaction.py +0 -0
  68. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_migration.py +0 -0
  69. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_migration_log.py +0 -0
  70. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/file_upload_part.py +0 -0
  71. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/folder.py +0 -0
  72. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/form_field.py +0 -0
  73. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/form_field_set.py +0 -0
  74. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/ftp_action_log.py +0 -0
  75. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/gpg_key.py +0 -0
  76. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/group.py +0 -0
  77. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/group_user.py +0 -0
  78. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/history.py +0 -0
  79. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/history_export.py +0 -0
  80. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/history_export_result.py +0 -0
  81. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/holiday_region.py +0 -0
  82. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/image.py +0 -0
  83. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/inbound_s3_log.py +0 -0
  84. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/inbox_recipient.py +0 -0
  85. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/inbox_registration.py +0 -0
  86. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/inbox_upload.py +0 -0
  87. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/invoice.py +0 -0
  88. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/invoice_line_item.py +0 -0
  89. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/ip_address.py +0 -0
  90. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/key_lifecycle_rule.py +0 -0
  91. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/lock.py +0 -0
  92. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/message.py +0 -0
  93. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/message_comment.py +0 -0
  94. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/message_comment_reaction.py +0 -0
  95. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/message_reaction.py +0 -0
  96. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/metadata_category.py +0 -0
  97. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/notification.py +0 -0
  98. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/outbound_connection_log.py +0 -0
  99. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/partner.py +0 -0
  100. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/partner_site.py +0 -0
  101. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/partner_site_request.py +0 -0
  102. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/payment.py +0 -0
  103. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/payment_line_item.py +0 -0
  104. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/pending_work_event.py +0 -0
  105. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/permission.py +0 -0
  106. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/preview.py +0 -0
  107. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/project.py +0 -0
  108. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/public_hosting_request_log.py +0 -0
  109. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/public_ip_address.py +0 -0
  110. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/public_key.py +0 -0
  111. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/remote_bandwidth_snapshot.py +0 -0
  112. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/remote_mount_backend.py +0 -0
  113. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/remote_server.py +0 -0
  114. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/remote_server_configuration_file.py +0 -0
  115. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/remote_server_credential.py +0 -0
  116. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/request.py +0 -0
  117. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/restore.py +0 -0
  118. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/scheduled_export.py +0 -0
  119. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/scim_log.py +0 -0
  120. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/session.py +0 -0
  121. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/settings_change.py +0 -0
  122. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sftp_action_log.py +0 -0
  123. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sftp_host_key.py +0 -0
  124. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/share_group.py +0 -0
  125. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/share_group_member.py +0 -0
  126. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/siem_http_destination.py +0 -0
  127. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/siem_http_destination_event.py +0 -0
  128. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/site.py +0 -0
  129. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/site_subdomain_redirect.py +0 -0
  130. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/snapshot.py +0 -0
  131. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sso_event.py +0 -0
  132. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sso_strategy.py +0 -0
  133. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/status.py +0 -0
  134. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/style.py +0 -0
  135. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sync.py +0 -0
  136. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sync_log.py +0 -0
  137. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sync_run.py +0 -0
  138. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/sync_run_live_transfer.py +0 -0
  139. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/usage_by_top_level_dir.py +0 -0
  140. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/usage_daily_snapshot.py +0 -0
  141. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/usage_snapshot.py +0 -0
  142. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user.py +0 -0
  143. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user_cipher_use.py +0 -0
  144. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user_lifecycle_rule.py +0 -0
  145. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user_request.py +0 -0
  146. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user_security_event.py +0 -0
  147. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/user_sftp_client_use.py +0 -0
  148. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/web_dav_action_log.py +0 -0
  149. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/webhook_test.py +0 -0
  150. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/workspace.py +0 -0
  151. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/models/zip_list_entry.py +0 -0
  152. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/path_util.py +0 -0
  153. {files_com-1.6.391 → files_com-1.6.393}/files_sdk/util.py +0 -0
  154. {files_com-1.6.391 → files_com-1.6.393}/setup.cfg +0 -0
  155. {files_com-1.6.391 → files_com-1.6.393}/tests/test_account_line_item.py +0 -0
  156. {files_com-1.6.391 → files_com-1.6.393}/tests/test_action.py +0 -0
  157. {files_com-1.6.391 → files_com-1.6.393}/tests/test_action_log.py +0 -0
  158. {files_com-1.6.391 → files_com-1.6.393}/tests/test_action_notification_export.py +0 -0
  159. {files_com-1.6.391 → files_com-1.6.393}/tests/test_action_notification_export_result.py +0 -0
  160. {files_com-1.6.391 → files_com-1.6.393}/tests/test_agent_push_update.py +0 -0
  161. {files_com-1.6.391 → files_com-1.6.393}/tests/test_api_errors.py +0 -0
  162. {files_com-1.6.391 → files_com-1.6.393}/tests/test_api_key.py +0 -0
  163. {files_com-1.6.391 → files_com-1.6.393}/tests/test_api_request_log.py +0 -0
  164. {files_com-1.6.391 → files_com-1.6.393}/tests/test_app.py +0 -0
  165. {files_com-1.6.391 → files_com-1.6.393}/tests/test_as2_incoming_message.py +0 -0
  166. {files_com-1.6.391 → files_com-1.6.393}/tests/test_as2_outgoing_message.py +0 -0
  167. {files_com-1.6.391 → files_com-1.6.393}/tests/test_as2_partner.py +0 -0
  168. {files_com-1.6.391 → files_com-1.6.393}/tests/test_as2_station.py +0 -0
  169. {files_com-1.6.391 → files_com-1.6.393}/tests/test_auto.py +0 -0
  170. {files_com-1.6.391 → files_com-1.6.393}/tests/test_automation.py +0 -0
  171. {files_com-1.6.391 → files_com-1.6.393}/tests/test_automation_log.py +0 -0
  172. {files_com-1.6.391 → files_com-1.6.393}/tests/test_automation_run.py +0 -0
  173. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bandwidth_snapshot.py +0 -0
  174. {files_com-1.6.391 → files_com-1.6.393}/tests/test_behavior.py +0 -0
  175. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle.py +0 -0
  176. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_action.py +0 -0
  177. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_download.py +0 -0
  178. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_notification.py +0 -0
  179. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_path.py +0 -0
  180. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_recipient.py +0 -0
  181. {files_com-1.6.391 → files_com-1.6.393}/tests/test_bundle_registration.py +0 -0
  182. {files_com-1.6.391 → files_com-1.6.393}/tests/test_child_site_management_policy.py +0 -0
  183. {files_com-1.6.391 → files_com-1.6.393}/tests/test_clickwrap.py +0 -0
  184. {files_com-1.6.391 → files_com-1.6.393}/tests/test_connection_adapter.py +0 -0
  185. {files_com-1.6.391 → files_com-1.6.393}/tests/test_decimal_contract.py +0 -0
  186. {files_com-1.6.391 → files_com-1.6.393}/tests/test_desktop_configuration_profile.py +0 -0
  187. {files_com-1.6.391 → files_com-1.6.393}/tests/test_dns_record.py +0 -0
  188. {files_com-1.6.391 → files_com-1.6.393}/tests/test_email_incoming_message.py +0 -0
  189. {files_com-1.6.391 → files_com-1.6.393}/tests/test_email_log.py +0 -0
  190. {files_com-1.6.391 → files_com-1.6.393}/tests/test_errors.py +0 -0
  191. {files_com-1.6.391 → files_com-1.6.393}/tests/test_event_channel.py +0 -0
  192. {files_com-1.6.391 → files_com-1.6.393}/tests/test_event_delivery_attempt.py +0 -0
  193. {files_com-1.6.391 → files_com-1.6.393}/tests/test_event_record.py +0 -0
  194. {files_com-1.6.391 → files_com-1.6.393}/tests/test_event_subscription.py +0 -0
  195. {files_com-1.6.391 → files_com-1.6.393}/tests/test_event_target.py +0 -0
  196. {files_com-1.6.391 → files_com-1.6.393}/tests/test_exavault_api_request_log.py +0 -0
  197. {files_com-1.6.391 → files_com-1.6.393}/tests/test_expectation.py +0 -0
  198. {files_com-1.6.391 → files_com-1.6.393}/tests/test_expectation_evaluation.py +0 -0
  199. {files_com-1.6.391 → files_com-1.6.393}/tests/test_expectation_incident.py +0 -0
  200. {files_com-1.6.391 → files_com-1.6.393}/tests/test_external_event.py +0 -0
  201. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file.py +0 -0
  202. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_action.py +0 -0
  203. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_comment.py +0 -0
  204. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_comment_reaction.py +0 -0
  205. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_migration.py +0 -0
  206. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_migration_log.py +0 -0
  207. {files_com-1.6.391 → files_com-1.6.393}/tests/test_file_upload_part.py +0 -0
  208. {files_com-1.6.391 → files_com-1.6.393}/tests/test_folder.py +0 -0
  209. {files_com-1.6.391 → files_com-1.6.393}/tests/test_form_field.py +0 -0
  210. {files_com-1.6.391 → files_com-1.6.393}/tests/test_form_field_set.py +0 -0
  211. {files_com-1.6.391 → files_com-1.6.393}/tests/test_ftp_action_log.py +0 -0
  212. {files_com-1.6.391 → files_com-1.6.393}/tests/test_gpg_key.py +0 -0
  213. {files_com-1.6.391 → files_com-1.6.393}/tests/test_group.py +0 -0
  214. {files_com-1.6.391 → files_com-1.6.393}/tests/test_group_user.py +0 -0
  215. {files_com-1.6.391 → files_com-1.6.393}/tests/test_history.py +0 -0
  216. {files_com-1.6.391 → files_com-1.6.393}/tests/test_history_export.py +0 -0
  217. {files_com-1.6.391 → files_com-1.6.393}/tests/test_history_export_result.py +0 -0
  218. {files_com-1.6.391 → files_com-1.6.393}/tests/test_holiday_region.py +0 -0
  219. {files_com-1.6.391 → files_com-1.6.393}/tests/test_image.py +0 -0
  220. {files_com-1.6.391 → files_com-1.6.393}/tests/test_inbound_s3_log.py +0 -0
  221. {files_com-1.6.391 → files_com-1.6.393}/tests/test_inbox_recipient.py +0 -0
  222. {files_com-1.6.391 → files_com-1.6.393}/tests/test_inbox_registration.py +0 -0
  223. {files_com-1.6.391 → files_com-1.6.393}/tests/test_inbox_upload.py +0 -0
  224. {files_com-1.6.391 → files_com-1.6.393}/tests/test_invoice.py +0 -0
  225. {files_com-1.6.391 → files_com-1.6.393}/tests/test_invoice_line_item.py +0 -0
  226. {files_com-1.6.391 → files_com-1.6.393}/tests/test_ip_address.py +0 -0
  227. {files_com-1.6.391 → files_com-1.6.393}/tests/test_key_lifecycle_rule.py +0 -0
  228. {files_com-1.6.391 → files_com-1.6.393}/tests/test_lock.py +0 -0
  229. {files_com-1.6.391 → files_com-1.6.393}/tests/test_message.py +0 -0
  230. {files_com-1.6.391 → files_com-1.6.393}/tests/test_message_comment.py +0 -0
  231. {files_com-1.6.391 → files_com-1.6.393}/tests/test_message_comment_reaction.py +0 -0
  232. {files_com-1.6.391 → files_com-1.6.393}/tests/test_message_reaction.py +0 -0
  233. {files_com-1.6.391 → files_com-1.6.393}/tests/test_metadata_category.py +0 -0
  234. {files_com-1.6.391 → files_com-1.6.393}/tests/test_notification.py +0 -0
  235. {files_com-1.6.391 → files_com-1.6.393}/tests/test_outbound_connection_log.py +0 -0
  236. {files_com-1.6.391 → files_com-1.6.393}/tests/test_partner.py +0 -0
  237. {files_com-1.6.391 → files_com-1.6.393}/tests/test_partner_site.py +0 -0
  238. {files_com-1.6.391 → files_com-1.6.393}/tests/test_partner_site_request.py +0 -0
  239. {files_com-1.6.391 → files_com-1.6.393}/tests/test_path_util.py +0 -0
  240. {files_com-1.6.391 → files_com-1.6.393}/tests/test_payment.py +0 -0
  241. {files_com-1.6.391 → files_com-1.6.393}/tests/test_payment_line_item.py +0 -0
  242. {files_com-1.6.391 → files_com-1.6.393}/tests/test_pending_work_event.py +0 -0
  243. {files_com-1.6.391 → files_com-1.6.393}/tests/test_permission.py +0 -0
  244. {files_com-1.6.391 → files_com-1.6.393}/tests/test_preview.py +0 -0
  245. {files_com-1.6.391 → files_com-1.6.393}/tests/test_project.py +0 -0
  246. {files_com-1.6.391 → files_com-1.6.393}/tests/test_public_hosting_request_log.py +0 -0
  247. {files_com-1.6.391 → files_com-1.6.393}/tests/test_public_ip_address.py +0 -0
  248. {files_com-1.6.391 → files_com-1.6.393}/tests/test_public_key.py +0 -0
  249. {files_com-1.6.391 → files_com-1.6.393}/tests/test_remote_bandwidth_snapshot.py +0 -0
  250. {files_com-1.6.391 → files_com-1.6.393}/tests/test_remote_mount_backend.py +0 -0
  251. {files_com-1.6.391 → files_com-1.6.393}/tests/test_remote_server.py +0 -0
  252. {files_com-1.6.391 → files_com-1.6.393}/tests/test_remote_server_configuration_file.py +0 -0
  253. {files_com-1.6.391 → files_com-1.6.393}/tests/test_remote_server_credential.py +0 -0
  254. {files_com-1.6.391 → files_com-1.6.393}/tests/test_request.py +0 -0
  255. {files_com-1.6.391 → files_com-1.6.393}/tests/test_restore.py +0 -0
  256. {files_com-1.6.391 → files_com-1.6.393}/tests/test_scheduled_export.py +0 -0
  257. {files_com-1.6.391 → files_com-1.6.393}/tests/test_scim_log.py +0 -0
  258. {files_com-1.6.391 → files_com-1.6.393}/tests/test_session.py +0 -0
  259. {files_com-1.6.391 → files_com-1.6.393}/tests/test_settings_change.py +0 -0
  260. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sftp_action_log.py +0 -0
  261. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sftp_host_key.py +0 -0
  262. {files_com-1.6.391 → files_com-1.6.393}/tests/test_share_group.py +0 -0
  263. {files_com-1.6.391 → files_com-1.6.393}/tests/test_share_group_member.py +0 -0
  264. {files_com-1.6.391 → files_com-1.6.393}/tests/test_siem_http_destination.py +0 -0
  265. {files_com-1.6.391 → files_com-1.6.393}/tests/test_siem_http_destination_event.py +0 -0
  266. {files_com-1.6.391 → files_com-1.6.393}/tests/test_site.py +0 -0
  267. {files_com-1.6.391 → files_com-1.6.393}/tests/test_site_subdomain_redirect.py +0 -0
  268. {files_com-1.6.391 → files_com-1.6.393}/tests/test_snapshot.py +0 -0
  269. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sso_event.py +0 -0
  270. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sso_strategy.py +0 -0
  271. {files_com-1.6.391 → files_com-1.6.393}/tests/test_status.py +0 -0
  272. {files_com-1.6.391 → files_com-1.6.393}/tests/test_style.py +0 -0
  273. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sync.py +0 -0
  274. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sync_log.py +0 -0
  275. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sync_run.py +0 -0
  276. {files_com-1.6.391 → files_com-1.6.393}/tests/test_sync_run_live_transfer.py +0 -0
  277. {files_com-1.6.391 → files_com-1.6.393}/tests/test_usage_by_top_level_dir.py +0 -0
  278. {files_com-1.6.391 → files_com-1.6.393}/tests/test_usage_daily_snapshot.py +0 -0
  279. {files_com-1.6.391 → files_com-1.6.393}/tests/test_usage_snapshot.py +0 -0
  280. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user.py +0 -0
  281. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user_cipher_use.py +0 -0
  282. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user_lifecycle_rule.py +0 -0
  283. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user_request.py +0 -0
  284. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user_security_event.py +0 -0
  285. {files_com-1.6.391 → files_com-1.6.393}/tests/test_user_sftp_client_use.py +0 -0
  286. {files_com-1.6.391 → files_com-1.6.393}/tests/test_web_dav_action_log.py +0 -0
  287. {files_com-1.6.391 → files_com-1.6.393}/tests/test_webhook_test.py +0 -0
  288. {files_com-1.6.391 → files_com-1.6.393}/tests/test_workspace.py +0 -0
  289. {files_com-1.6.391 → files_com-1.6.393}/tests/test_zip_list_entry.py +0 -0
@@ -1,3 +1,15 @@
1
+ Metadata-Version: 2.4
2
+ Name: files_com
3
+ Version: 1.6.393
4
+ Summary: Python bindings for the Files.com API
5
+ License: MIT
6
+ Requires-Python: >=3.5
7
+ Description-Content-Type: text/markdown
8
+ License-File: LICENSE
9
+ Requires-Dist: requests>=2.20
10
+ Requires-Dist: requests-toolbelt>=1.0.0
11
+ Dynamic: license-file
12
+
1
13
  # Files.com Python Client
2
14
 
3
15
  The Files.com Python Client provides a direct, high performance integration to Files.com from applications written in Python.
@@ -444,32 +456,16 @@ A Workspace is a lightweight way to organize related resources inside a single F
444
456
  Customers commonly group resources by project, department, client, or region. Workspaces provide a built-in structure for that grouping, so the UI can operate within a clear "workspace context" and admins can delegate management for a subset of resources without requiring full site-level isolation.
445
457
 
446
458
  Every Site has an implicit Default workspace (ID `0`). Resources that are not explicitly assigned to a named workspace are considered part of the Default workspace.
447
- <div></div>
448
-
449
- ### SDK Support
450
459
 
451
- We are still in the process of adding Workspaces support to each SDK. If you require Workspaces support right now, you need to use the REST API or the CLI.
452
- <div></div>
453
-
454
- ### Using Workspaces with the REST API
460
+ The Files.com Python SDK supports workspace scoping by using the `files_sdk.set_workspace_id` configuration method. Scope a single request by passing `workspace_id` in the request options.
461
+ ```python title="Example Request"
462
+ import files_sdk
455
463
 
456
- To use Workspaces with the REST API, send the following request header:
464
+ files_sdk.set_workspace_id(123)
457
465
 
458
- ```http
459
- X-Files-Workspace-Id: <workspace_id>
466
+ files_sdk.folder.list_for("", {}, {"workspace_id": 456})
460
467
  ```
461
468
 
462
- This changes path mapping and "what you're looking at."
463
-
464
- When the `X-Files-Workspace-Id` header is provided:
465
-
466
- - List, show, update, and delete operations are constrained to that workspace for workspace-scoped models.
467
- - Create operations default `workspace_id` to the scoped workspace when not explicitly provided.
468
- - Attempts to provide a mismatching `workspace_id` are rejected with `not-authorized/insufficient-permission-for-params`.
469
-
470
- This header only works for sitewide keys, or keys related to users with permissions to more than one workspace.
471
- <div></div>
472
-
473
469
  ## Foreign Language Support
474
470
 
475
471
  The Files.com Python SDK supports localized responses by using the `files_sdk.set_language` configuration method.
@@ -1,15 +1,3 @@
1
- Metadata-Version: 2.4
2
- Name: files_com
3
- Version: 1.6.391
4
- Summary: Python bindings for the Files.com API
5
- License: MIT
6
- Requires-Python: >=3.5
7
- Description-Content-Type: text/markdown
8
- License-File: LICENSE
9
- Requires-Dist: requests>=2.20
10
- Requires-Dist: requests-toolbelt>=1.0.0
11
- Dynamic: license-file
12
-
13
1
  # Files.com Python Client
14
2
 
15
3
  The Files.com Python Client provides a direct, high performance integration to Files.com from applications written in Python.
@@ -456,32 +444,16 @@ A Workspace is a lightweight way to organize related resources inside a single F
456
444
  Customers commonly group resources by project, department, client, or region. Workspaces provide a built-in structure for that grouping, so the UI can operate within a clear "workspace context" and admins can delegate management for a subset of resources without requiring full site-level isolation.
457
445
 
458
446
  Every Site has an implicit Default workspace (ID `0`). Resources that are not explicitly assigned to a named workspace are considered part of the Default workspace.
459
- <div></div>
460
-
461
- ### SDK Support
462
447
 
463
- We are still in the process of adding Workspaces support to each SDK. If you require Workspaces support right now, you need to use the REST API or the CLI.
464
- <div></div>
465
-
466
- ### Using Workspaces with the REST API
448
+ The Files.com Python SDK supports workspace scoping by using the `files_sdk.set_workspace_id` configuration method. Scope a single request by passing `workspace_id` in the request options.
449
+ ```python title="Example Request"
450
+ import files_sdk
467
451
 
468
- To use Workspaces with the REST API, send the following request header:
452
+ files_sdk.set_workspace_id(123)
469
453
 
470
- ```http
471
- X-Files-Workspace-Id: <workspace_id>
454
+ files_sdk.folder.list_for("", {}, {"workspace_id": 456})
472
455
  ```
473
456
 
474
- This changes path mapping and "what you're looking at."
475
-
476
- When the `X-Files-Workspace-Id` header is provided:
477
-
478
- - List, show, update, and delete operations are constrained to that workspace for workspace-scoped models.
479
- - Create operations default `workspace_id` to the scoped workspace when not explicitly provided.
480
- - Attempts to provide a mismatching `workspace_id` are rejected with `not-authorized/insufficient-permission-for-params`.
481
-
482
- This header only works for sitewide keys, or keys related to users with permissions to more than one workspace.
483
- <div></div>
484
-
485
457
  ## Foreign Language Support
486
458
 
487
459
  The Files.com Python SDK supports localized responses by using the `files_sdk.set_language` configuration method.
@@ -0,0 +1 @@
1
+ 1.6.393
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: files_com
3
- Version: 1.6.391
3
+ Version: 1.6.393
4
4
  Summary: Python bindings for the Files.com API
5
5
  License: MIT
6
6
  Requires-Python: >=3.5
@@ -456,32 +456,16 @@ A Workspace is a lightweight way to organize related resources inside a single F
456
456
  Customers commonly group resources by project, department, client, or region. Workspaces provide a built-in structure for that grouping, so the UI can operate within a clear "workspace context" and admins can delegate management for a subset of resources without requiring full site-level isolation.
457
457
 
458
458
  Every Site has an implicit Default workspace (ID `0`). Resources that are not explicitly assigned to a named workspace are considered part of the Default workspace.
459
- <div></div>
460
-
461
- ### SDK Support
462
-
463
- We are still in the process of adding Workspaces support to each SDK. If you require Workspaces support right now, you need to use the REST API or the CLI.
464
- <div></div>
465
459
 
466
- ### Using Workspaces with the REST API
460
+ The Files.com Python SDK supports workspace scoping by using the `files_sdk.set_workspace_id` configuration method. Scope a single request by passing `workspace_id` in the request options.
461
+ ```python title="Example Request"
462
+ import files_sdk
467
463
 
468
- To use Workspaces with the REST API, send the following request header:
464
+ files_sdk.set_workspace_id(123)
469
465
 
470
- ```http
471
- X-Files-Workspace-Id: <workspace_id>
466
+ files_sdk.folder.list_for("", {}, {"workspace_id": 456})
472
467
  ```
473
468
 
474
- This changes path mapping and "what you're looking at."
475
-
476
- When the `X-Files-Workspace-Id` header is provided:
477
-
478
- - List, show, update, and delete operations are constrained to that workspace for workspace-scoped models.
479
- - Create operations default `workspace_id` to the scoped workspace when not explicitly provided.
480
- - Attempts to provide a mismatching `workspace_id` are rejected with `not-authorized/insufficient-permission-for-params`.
481
-
482
- This header only works for sitewide keys, or keys related to users with permissions to more than one workspace.
483
- <div></div>
484
-
485
469
  ## Foreign Language Support
486
470
 
487
471
  The Files.com Python SDK supports localized responses by using the `files_sdk.set_language` configuration method.
@@ -44,6 +44,7 @@ files_sdk/models/bundle_recipient.py
44
44
  files_sdk/models/bundle_registration.py
45
45
  files_sdk/models/child_site_management_policy.py
46
46
  files_sdk/models/clickwrap.py
47
+ files_sdk/models/custom_domain.py
47
48
  files_sdk/models/desktop_configuration_profile.py
48
49
  files_sdk/models/dns_record.py
49
50
  files_sdk/models/email_incoming_message.py
@@ -177,6 +178,7 @@ tests/test_bundle_registration.py
177
178
  tests/test_child_site_management_policy.py
178
179
  tests/test_clickwrap.py
179
180
  tests/test_connection_adapter.py
181
+ tests/test_custom_domain.py
180
182
  tests/test_decimal_contract.py
181
183
  tests/test_desktop_configuration_profile.py
182
184
  tests/test_dns_record.py
@@ -281,4 +283,5 @@ tests/test_user_sftp_client_use.py
281
283
  tests/test_web_dav_action_log.py
282
284
  tests/test_webhook_test.py
283
285
  tests/test_workspace.py
286
+ tests/test_workspace_id.py
284
287
  tests/test_zip_list_entry.py
@@ -27,6 +27,7 @@ import files_sdk.models.bundle_recipient as bundle_recipient
27
27
  import files_sdk.models.bundle_registration as bundle_registration
28
28
  import files_sdk.models.child_site_management_policy as child_site_management_policy
29
29
  import files_sdk.models.clickwrap as clickwrap
30
+ import files_sdk.models.custom_domain as custom_domain
30
31
  import files_sdk.models.desktop_configuration_profile as desktop_configuration_profile
31
32
  import files_sdk.models.dns_record as dns_record
32
33
  import files_sdk.models.email_incoming_message as email_incoming_message
@@ -165,6 +166,7 @@ from files_sdk.models.child_site_management_policy import (
165
166
  ChildSiteManagementPolicy,
166
167
  )
167
168
  from files_sdk.models.clickwrap import Clickwrap
169
+ from files_sdk.models.custom_domain import CustomDomain
168
170
  from files_sdk.models.desktop_configuration_profile import (
169
171
  DesktopConfigurationProfile,
170
172
  )
@@ -283,9 +285,10 @@ the_api_key = ""
283
285
  language = None
284
286
  session_id = None
285
287
  source_ip = None
288
+ workspace_id = None
286
289
  base_url = "https://app.files.com"
287
290
  base_path = "api/rest/v1"
288
- version = "1.6.391"
291
+ version = "1.6.393"
289
292
 
290
293
  __version__ = version
291
294
 
@@ -297,7 +300,14 @@ max_network_retries = 3
297
300
 
298
301
  console_log_level = "none"
299
302
 
300
- OPTS = ("api_key", "client", "session_id", "source_ip", "language")
303
+ OPTS = (
304
+ "api_key",
305
+ "client",
306
+ "session_id",
307
+ "source_ip",
308
+ "language",
309
+ "workspace_id",
310
+ )
301
311
 
302
312
 
303
313
  def set_api_key(_api_key):
@@ -320,6 +330,16 @@ def get_language():
320
330
  return language
321
331
 
322
332
 
333
+ def set_workspace_id(_workspace_id):
334
+ global workspace_id
335
+ workspace_id = _workspace_id
336
+
337
+
338
+ def get_workspace_id():
339
+ global workspace_id
340
+ return workspace_id
341
+
342
+
323
343
  def set_session(_session):
324
344
  if not _session.id:
325
345
  _session.save()
@@ -24,6 +24,7 @@ class Api:
24
24
  api_key = headers.pop("api_key", None)
25
25
  session_id = headers.pop("session_id", None)
26
26
  language = headers.pop("language", None)
27
+ workspace_id = headers.pop("workspace_id", None)
27
28
 
28
29
  session = headers.pop("session", None)
29
30
  if session:
@@ -37,6 +38,7 @@ class Api:
37
38
  api_key=api_key,
38
39
  session_id=session_id,
39
40
  language=language,
41
+ workspace_id=workspace_id,
40
42
  params=params,
41
43
  )
42
44
 
@@ -50,6 +50,7 @@ class ApiClient:
50
50
  api_key=None,
51
51
  session_id=None,
52
52
  language=None,
53
+ workspace_id=None,
53
54
  headers=None,
54
55
  params=None,
55
56
  ):
@@ -71,9 +72,14 @@ class ApiClient:
71
72
  if files_sdk.language:
72
73
  language = files_sdk.language
73
74
 
75
+ if workspace_id is None:
76
+ workspace_id = files_sdk.get_workspace_id()
77
+
74
78
  headers = {
75
79
  **headers,
76
- **self.request_headers(api_key, session_id, language),
80
+ **self.request_headers(
81
+ api_key, session_id, language, workspace_id
82
+ ),
77
83
  }
78
84
 
79
85
  def _serialize_value(value):
@@ -204,7 +210,7 @@ class ApiClient:
204
210
  sleep_seconds *= 0.5 * (1 + random.random())
205
211
  return max(files_sdk.initial_network_retry_delay, sleep_seconds)
206
212
 
207
- def request_headers(self, api_key, session_id, language):
213
+ def request_headers(self, api_key, session_id, language, workspace_id):
208
214
  user_agent = "Files.com Python SDK v{version}".format(
209
215
  version=files_sdk.version
210
216
  )
@@ -220,6 +226,8 @@ class ApiClient:
220
226
  headers["X-FilesAPI-Auth"] = session_id
221
227
  if language:
222
228
  headers["Accept-Language"] = language
229
+ if workspace_id is not None and workspace_id != "":
230
+ headers["X-Files-Workspace-Id"] = str(workspace_id)
223
231
 
224
232
  return headers
225
233
 
@@ -32,6 +32,7 @@ from files_sdk.models.child_site_management_policy import (
32
32
  ChildSiteManagementPolicy,
33
33
  )
34
34
  from files_sdk.models.clickwrap import Clickwrap
35
+ from files_sdk.models.custom_domain import CustomDomain
35
36
  from files_sdk.models.desktop_configuration_profile import (
36
37
  DesktopConfigurationProfile,
37
38
  )
@@ -0,0 +1,271 @@
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 CustomDomain:
12
+ default_attributes = {
13
+ "id": None, # int64 - Custom Domain ID.
14
+ "domain": None, # string - Customer-owned domain name.
15
+ "destination": None, # string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `s3_endpoint`.
16
+ "dns_status": None, # string - Current DNS verification status.
17
+ "ssl_certificate_id": None, # int64 - Current SSL certificate ID.
18
+ "brick_managed": None, # boolean - Is this domain's SSL certificate automatically managed and renewed by Files.com?
19
+ "folder_behavior_id": None, # int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
20
+ "created_at": None, # date-time - When this Custom Domain was created.
21
+ "updated_at": None, # date-time - When this Custom Domain was last updated.
22
+ }
23
+
24
+ def __init__(self, attributes=None, options=None):
25
+ if not isinstance(attributes, dict):
26
+ attributes = {}
27
+ if not isinstance(options, dict):
28
+ options = {}
29
+ self.set_attributes(attributes)
30
+ self.options = options
31
+
32
+ def set_attributes(self, attributes):
33
+ for (
34
+ attribute,
35
+ default_value,
36
+ ) in CustomDomain.default_attributes.items():
37
+ value = attributes.get(attribute, default_value)
38
+ setattr(self, attribute, value)
39
+
40
+ def get_attributes(self):
41
+ attrs = {
42
+ k: getattr(self, k, None)
43
+ for k in CustomDomain.default_attributes
44
+ if getattr(self, k, None) is not None
45
+ }
46
+ return attrs
47
+
48
+ # Parameters:
49
+ # destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `s3_endpoint`.
50
+ # folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
51
+ # ssl_certificate_id - int64 - Current SSL certificate ID.
52
+ # domain - string - Customer-owned domain name.
53
+ def update(self, params=None):
54
+ if not isinstance(params, dict):
55
+ params = {}
56
+
57
+ if hasattr(self, "id") and self.id:
58
+ params["id"] = self.id
59
+ else:
60
+ raise MissingParameterError("Current object doesn't have a id")
61
+ if "id" not in params:
62
+ raise MissingParameterError("Parameter missing: id")
63
+ if "id" in params and not isinstance(params["id"], int):
64
+ raise InvalidParameterError("Bad parameter: id must be an int")
65
+ if "destination" in params and not isinstance(
66
+ params["destination"], str
67
+ ):
68
+ raise InvalidParameterError(
69
+ "Bad parameter: destination must be an str"
70
+ )
71
+ if "folder_behavior_id" in params and not isinstance(
72
+ params["folder_behavior_id"], int
73
+ ):
74
+ raise InvalidParameterError(
75
+ "Bad parameter: folder_behavior_id must be an int"
76
+ )
77
+ if "ssl_certificate_id" in params and not isinstance(
78
+ params["ssl_certificate_id"], int
79
+ ):
80
+ raise InvalidParameterError(
81
+ "Bad parameter: ssl_certificate_id must be an int"
82
+ )
83
+ if "domain" in params and not isinstance(params["domain"], str):
84
+ raise InvalidParameterError("Bad parameter: domain must be an str")
85
+ response, _options = Api.send_request(
86
+ "PATCH",
87
+ "/custom_domains/{id}".format(id=params["id"]),
88
+ params,
89
+ self.options,
90
+ )
91
+ return response.data
92
+
93
+ def delete(self, params=None):
94
+ if not isinstance(params, dict):
95
+ params = {}
96
+
97
+ if hasattr(self, "id") and self.id:
98
+ params["id"] = self.id
99
+ else:
100
+ raise MissingParameterError("Current object doesn't have a id")
101
+ if "id" not in params:
102
+ raise MissingParameterError("Parameter missing: id")
103
+ if "id" in params and not isinstance(params["id"], int):
104
+ raise InvalidParameterError("Bad parameter: id must be an int")
105
+ Api.send_request(
106
+ "DELETE",
107
+ "/custom_domains/{id}".format(id=params["id"]),
108
+ params,
109
+ self.options,
110
+ )
111
+
112
+ def destroy(self, params=None):
113
+ self.delete(params)
114
+
115
+ def save(self):
116
+ if hasattr(self, "id") and self.id:
117
+ new_obj = self.update(self.get_attributes())
118
+ self.set_attributes(new_obj.get_attributes())
119
+ return True
120
+ else:
121
+ new_obj = create(self.get_attributes(), self.options)
122
+ self.set_attributes(new_obj.get_attributes())
123
+ return True
124
+
125
+
126
+ # Parameters:
127
+ # 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.
128
+ # per_page - int64 - Number of records to show per page. (Max: 10000, 1,000 or less is recommended).
129
+ # sort_by - object - If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are `id`.
130
+ def list(params=None, options=None):
131
+ if not isinstance(params, dict):
132
+ params = {}
133
+ if not isinstance(options, dict):
134
+ options = {}
135
+ if "cursor" in params and not isinstance(params["cursor"], str):
136
+ raise InvalidParameterError("Bad parameter: cursor must be an str")
137
+ if "per_page" in params and not isinstance(params["per_page"], int):
138
+ raise InvalidParameterError("Bad parameter: per_page must be an int")
139
+ if "sort_by" in params and not isinstance(params["sort_by"], dict):
140
+ raise InvalidParameterError("Bad parameter: sort_by must be an dict")
141
+ return ListObj(CustomDomain, "GET", "/custom_domains", params, options)
142
+
143
+
144
+ def all(params=None, options=None):
145
+ list(params, options)
146
+
147
+
148
+ # Parameters:
149
+ # id (required) - int64 - Custom Domain ID.
150
+ def find(id, params=None, options=None):
151
+ if not isinstance(params, dict):
152
+ params = {}
153
+ if not isinstance(options, dict):
154
+ options = {}
155
+ params["id"] = id
156
+ if "id" in params and not isinstance(params["id"], int):
157
+ raise InvalidParameterError("Bad parameter: id must be an int")
158
+ if "id" not in params:
159
+ raise MissingParameterError("Parameter missing: id")
160
+ response, options = Api.send_request(
161
+ "GET", "/custom_domains/{id}".format(id=params["id"]), params, options
162
+ )
163
+ return CustomDomain(response.data, options)
164
+
165
+
166
+ def get(id, params=None, options=None):
167
+ find(id, params, options)
168
+
169
+
170
+ # Parameters:
171
+ # destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `s3_endpoint`.
172
+ # folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
173
+ # ssl_certificate_id - int64 - Current SSL certificate ID.
174
+ # domain (required) - string - Customer-owned domain name.
175
+ def create(params=None, options=None):
176
+ if not isinstance(params, dict):
177
+ params = {}
178
+ if not isinstance(options, dict):
179
+ options = {}
180
+ if "destination" in params and not isinstance(params["destination"], str):
181
+ raise InvalidParameterError(
182
+ "Bad parameter: destination must be an str"
183
+ )
184
+ if "folder_behavior_id" in params and not isinstance(
185
+ params["folder_behavior_id"], int
186
+ ):
187
+ raise InvalidParameterError(
188
+ "Bad parameter: folder_behavior_id must be an int"
189
+ )
190
+ if "ssl_certificate_id" in params and not isinstance(
191
+ params["ssl_certificate_id"], int
192
+ ):
193
+ raise InvalidParameterError(
194
+ "Bad parameter: ssl_certificate_id must be an int"
195
+ )
196
+ if "domain" in params and not isinstance(params["domain"], str):
197
+ raise InvalidParameterError("Bad parameter: domain must be an str")
198
+ if "domain" not in params:
199
+ raise MissingParameterError("Parameter missing: domain")
200
+ response, options = Api.send_request(
201
+ "POST", "/custom_domains", params, options
202
+ )
203
+ return CustomDomain(response.data, options)
204
+
205
+
206
+ # Parameters:
207
+ # destination - string - Where this custom domain routes. Can be `site_alias`, `public_hosting`, or `s3_endpoint`.
208
+ # folder_behavior_id - int64 - Public Hosting behavior ID when this domain routes to a specific Public Hosting behavior.
209
+ # ssl_certificate_id - int64 - Current SSL certificate ID.
210
+ # domain - string - Customer-owned domain name.
211
+ def update(id, params=None, options=None):
212
+ if not isinstance(params, dict):
213
+ params = {}
214
+ if not isinstance(options, dict):
215
+ options = {}
216
+ params["id"] = id
217
+ if "id" in params and not isinstance(params["id"], int):
218
+ raise InvalidParameterError("Bad parameter: id must be an int")
219
+ if "destination" in params and not isinstance(params["destination"], str):
220
+ raise InvalidParameterError(
221
+ "Bad parameter: destination must be an str"
222
+ )
223
+ if "folder_behavior_id" in params and not isinstance(
224
+ params["folder_behavior_id"], int
225
+ ):
226
+ raise InvalidParameterError(
227
+ "Bad parameter: folder_behavior_id must be an int"
228
+ )
229
+ if "ssl_certificate_id" in params and not isinstance(
230
+ params["ssl_certificate_id"], int
231
+ ):
232
+ raise InvalidParameterError(
233
+ "Bad parameter: ssl_certificate_id must be an int"
234
+ )
235
+ if "domain" in params and not isinstance(params["domain"], str):
236
+ raise InvalidParameterError("Bad parameter: domain must be an str")
237
+ if "id" not in params:
238
+ raise MissingParameterError("Parameter missing: id")
239
+ response, options = Api.send_request(
240
+ "PATCH",
241
+ "/custom_domains/{id}".format(id=params["id"]),
242
+ params,
243
+ options,
244
+ )
245
+ return CustomDomain(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
+ "/custom_domains/{id}".format(id=params["id"]),
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 CustomDomain(*args, **kwargs)
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "files_com"
7
- version = "1.6.391"
7
+ version = "1.6.393"
8
8
  description = "Python bindings for the Files.com API"
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -0,0 +1,68 @@
1
+ import unittest
2
+ import inspect
3
+ import files_sdk
4
+ from tests.base import TestBase
5
+ from files_sdk.models import CustomDomain
6
+ from files_sdk import custom_domain
7
+
8
+ class CustomDomainTest(TestBase):
9
+ pass
10
+ # Instance Methods
11
+ @unittest.skipUnless(TestBase.mock_server_path_exists("PATCH", "/custom_domains/{id}"), "Mock path does not exist")
12
+ def test_update(self):
13
+ params = {
14
+ "id" : 12345,
15
+ }
16
+ custom_domain = CustomDomain(params)
17
+ custom_domain.update(params)
18
+
19
+ @unittest.skipUnless(TestBase.mock_server_path_exists("DELETE", "/custom_domains/{id}"), "Mock path does not exist")
20
+ def test_delete(self):
21
+ params = {
22
+ "id" : 12345,
23
+ }
24
+ custom_domain = CustomDomain(params)
25
+ custom_domain.delete(params)
26
+
27
+ # Alias of delete
28
+ def test_destroy(self):
29
+ pass
30
+
31
+ # Static Methods
32
+ @unittest.skipUnless(TestBase.mock_server_path_exists("GET", "/custom_domains"), "Mock path does not exist")
33
+ def test_list(self):
34
+ resp = custom_domain.list()
35
+
36
+ @unittest.skipUnless(TestBase.mock_server_path_exists("GET", "/custom_domains/{id}"), "Mock path does not exist")
37
+ def test_find(self):
38
+ id = 12345
39
+ params = {
40
+ "id" : 12345,
41
+ }
42
+ custom_domain.find(id, params)
43
+
44
+ @unittest.skipUnless(TestBase.mock_server_path_exists("POST", "/custom_domains"), "Mock path does not exist")
45
+ def test_create(self):
46
+ params = {
47
+ "domain" : "foo",
48
+ }
49
+ custom_domain.create(params)
50
+
51
+ @unittest.skipUnless(TestBase.mock_server_path_exists("PATCH", "/custom_domains/{id}"), "Mock path does not exist")
52
+ def test_update(self):
53
+ id = 12345
54
+ params = {
55
+ "id" : 12345,
56
+ }
57
+ custom_domain.update(id, params)
58
+
59
+ @unittest.skipUnless(TestBase.mock_server_path_exists("DELETE", "/custom_domains/{id}"), "Mock path does not exist")
60
+ def test_delete(self):
61
+ id = 12345
62
+ params = {
63
+ "id" : 12345,
64
+ }
65
+ custom_domain.delete(id, params)
66
+
67
+ if __name__ == '__main__':
68
+ unittest.main()