files.com 1.2.294 → 1.2.296

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.
package/README.md CHANGED
@@ -427,6 +427,74 @@ try {
427
427
  }
428
428
  ```
429
429
 
430
+ ## Paths
431
+
432
+ Working with paths in Files.com involves several important considerations. Understanding how path comparisons are applied helps developers ensure consistency and accuracy across all interactions with the platform.
433
+ <div></div>
434
+
435
+ ### Capitalization
436
+
437
+ Files.com compares paths in a **case-insensitive** manner. This means path segments are treated as equivalent regardless of letter casing.
438
+
439
+ For example, all of the following resolve to the same internal path:
440
+
441
+ | Path Variant | Interpreted As |
442
+ |---------------------------------------|------------------------------|
443
+ | `Documents/Reports/Q1.pdf` | `documents/reports/q1.pdf` |
444
+ | `documents/reports/q1.PDF` | `documents/reports/q1.pdf` |
445
+ | `DOCUMENTS/REPORTS/Q1.PDF` | `documents/reports/q1.pdf` |
446
+
447
+ This behavior applies across:
448
+ - API requests
449
+ - Folder and file lookup operations
450
+ - Automations and workflows
451
+
452
+ See also: [Case Sensitivity Documentation](https://www.files.com/docs/files-and-folders/case-sensitivity/)
453
+
454
+ The `pathNormalizer.same` function in the Files.com SDK is designed to help you determine if two paths on
455
+ your native file system would be considered the same on Files.com. This is particularly important
456
+ when handling errors related to duplicate file names and when developing tools for folder
457
+ synchronization.
458
+
459
+ ```javascript title="Compare Case-Insensitive Files and Paths"
460
+ import { pathNormalizer } from 'files.com/lib/utils';
461
+
462
+ if (pathNormalizer.same('Fïłèńämê.Txt', 'filename.txt')) {
463
+ // the paths are the same
464
+ }
465
+ ```
466
+
467
+ ### Slashes
468
+
469
+ All path parameters in Files.com (API, SDKs, CLI, automations, integrations) must **omit leading and trailing slashes**. Paths are always treated as **absolute and slash-delimited**, so only internal `/` separators are used and never at the start or end of the string.
470
+
471
+ #### Path Slash Examples
472
+ | Path | Valid? | Notes |
473
+ |-----------------------------------|--------|-------------------------------|
474
+ | `folder/subfolder/file.txt` | ✅ | Correct, internal separators only |
475
+ | `/folder/subfolder/file.txt` | ❌ | Leading slash not allowed |
476
+ | `folder/subfolder/file.txt/` | ❌ | Trailing slash not allowed |
477
+ | `//folder//file.txt` | ❌ | Duplicate separators not allowed |
478
+
479
+ <div></div>
480
+
481
+ ### Unicode Normalization
482
+
483
+ Files.com normalizes all paths using [Unicode NFC (Normalization Form C)](https://www.unicode.org/reports/tr15/#Norm_Forms) before comparison. This ensures consistency across different representations of the same characters.
484
+
485
+ For example, the following two paths are treated as equivalent after NFC normalization:
486
+
487
+ | Input | Normalized Form |
488
+ |----------------------------------------|------------------------|
489
+ | `uploads/\u0065\u0301.txt` | `uploads/é.txt` |
490
+ | `docs/Café/Report.txt` | `docs/Café/Report.txt` |
491
+
492
+ - All input must be UTF‑8 encoded.
493
+ - Precomposed and decomposed characters are unified.
494
+ - This affects search, deduplication, and comparisons across SDKs.
495
+
496
+ <div></div>
497
+
430
498
  ## Foreign Language Support
431
499
 
432
500
  The Files.com Javascript SDK supports localized responses by using the `Files.setLanguage()` configuration method.
@@ -731,23 +799,6 @@ try {
731
799
  }
732
800
  ```
733
801
 
734
- ## Case Sensitivity
735
-
736
- The Files.com API compares files and paths in a case-insensitive manner. For related documentation see [Case Sensitivity Documentation](https://www.files.com/docs/files-and-folders/file-system-semantics/case-sensitivity).
737
-
738
- The `pathNormalizer.same` function in the Files.com SDK is designed to help you determine if two paths on
739
- your native file system would be considered the same on Files.com. This is particularly important
740
- when handling errors related to duplicate file names and when developing tools for folder
741
- synchronization.
742
-
743
- ```javascript title="Compare Case-Insensitive Files and Paths"
744
- import { pathNormalizer } from 'files.com/lib/utils';
745
-
746
- if (pathNormalizer.same('Fïłèńämê.Txt', 'filename.txt')) {
747
- // the paths are the same
748
- }
749
- ```
750
-
751
802
  ## Mock Server
752
803
 
753
804
  Files.com publishes a Files.com API server, which is useful for testing your use of the Files.com
package/_VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.294
1
+ 1.2.296
@@ -30,9 +30,6 @@
30
30
  "wasabi_bucket": "my-bucket",
31
31
  "wasabi_region": "us-west-1",
32
32
  "wasabi_access_key": "example",
33
- "rackspace_username": "rackspaceuser",
34
- "rackspace_region": "dfw",
35
- "rackspace_container": "my-container",
36
33
  "auth_status": "in_setup",
37
34
  "auth_account_name": "me@example.com",
38
35
  "one_drive_account_type": "personal",
@@ -91,9 +88,6 @@
91
88
  * `wasabi_bucket` (string): Wasabi: Bucket name
92
89
  * `wasabi_region` (string): Wasabi: Region
93
90
  * `wasabi_access_key` (string): Wasabi: Access Key.
94
- * `rackspace_username` (string): Rackspace: username used to login to the Rackspace Cloud Control Panel.
95
- * `rackspace_region` (string): Rackspace: Three letter code for Rackspace region. See https://support.rackspace.com/how-to/about-regions/
96
- * `rackspace_container` (string): Rackspace: The name of the container (top level directory) where files will sync.
97
91
  * `auth_status` (string): Either `in_setup` or `complete`
98
92
  * `auth_account_name` (string): Describes the authorized account
99
93
  * `one_drive_account_type` (string): OneDrive: Either personal or business_other account types
@@ -140,7 +134,6 @@
140
134
  * `google_cloud_storage_credentials_json` (string): Google Cloud Storage: JSON file that contains the private key. To generate see https://cloud.google.com/storage/docs/json_api/v1/how-tos/authorizing#APIKey
141
135
  * `google_cloud_storage_s3_compatible_secret_key` (string): Google Cloud Storage: S3-compatible secret key
142
136
  * `linode_secret_key` (string): Linode: Secret Key
143
- * `rackspace_api_key` (string): Rackspace: API key from the Rackspace Cloud Control Panel
144
137
  * `s3_compatible_secret_key` (string): S3-compatible: Secret Key
145
138
  * `wasabi_secret_key` (string): Wasabi: Secret Key
146
139
 
@@ -157,9 +150,9 @@ await RemoteServer.list
157
150
 
158
151
  * `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.
159
152
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
160
- * `sort_by` (object): If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are `name`, `server_type`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `rackspace_container`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`.
161
- * `filter` (object): If set, return records where the specified field is equal to the supplied value. Valid fields are `name`, `server_type`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `rackspace_container`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`. Valid field combinations are `[ server_type, name ]`, `[ backblaze_b2_bucket, name ]`, `[ google_cloud_storage_bucket, name ]`, `[ wasabi_bucket, name ]`, `[ s3_bucket, name ]`, `[ rackspace_container, name ]`, `[ azure_blob_storage_container, name ]`, `[ azure_files_storage_share_name, name ]`, `[ s3_compatible_bucket, name ]`, `[ filebase_bucket, name ]`, `[ cloudflare_bucket, name ]` or `[ linode_bucket, name ]`.
162
- * `filter_prefix` (object): If set, return records where the specified field is prefixed by the supplied value. Valid fields are `name`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `rackspace_container`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`. Valid field combinations are `[ backblaze_b2_bucket, name ]`, `[ google_cloud_storage_bucket, name ]`, `[ wasabi_bucket, name ]`, `[ s3_bucket, name ]`, `[ rackspace_container, name ]`, `[ azure_blob_storage_container, name ]`, `[ azure_files_storage_share_name, name ]`, `[ s3_compatible_bucket, name ]`, `[ filebase_bucket, name ]`, `[ cloudflare_bucket, name ]` or `[ linode_bucket, name ]`.
153
+ * `sort_by` (object): If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are `name`, `server_type`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`.
154
+ * `filter` (object): If set, return records where the specified field is equal to the supplied value. Valid fields are `name`, `server_type`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`. Valid field combinations are `[ server_type, name ]`, `[ backblaze_b2_bucket, name ]`, `[ google_cloud_storage_bucket, name ]`, `[ wasabi_bucket, name ]`, `[ s3_bucket, name ]`, `[ azure_blob_storage_container, name ]`, `[ azure_files_storage_share_name, name ]`, `[ s3_compatible_bucket, name ]`, `[ filebase_bucket, name ]`, `[ cloudflare_bucket, name ]` or `[ linode_bucket, name ]`.
155
+ * `filter_prefix` (object): If set, return records where the specified field is prefixed by the supplied value. Valid fields are `name`, `backblaze_b2_bucket`, `google_cloud_storage_bucket`, `wasabi_bucket`, `s3_bucket`, `azure_blob_storage_container`, `azure_files_storage_share_name`, `s3_compatible_bucket`, `filebase_bucket`, `cloudflare_bucket` or `linode_bucket`. Valid field combinations are `[ backblaze_b2_bucket, name ]`, `[ google_cloud_storage_bucket, name ]`, `[ wasabi_bucket, name ]`, `[ s3_bucket, name ]`, `[ azure_blob_storage_container, name ]`, `[ azure_files_storage_share_name, name ]`, `[ s3_compatible_bucket, name ]`, `[ filebase_bucket, name ]`, `[ cloudflare_bucket, name ]` or `[ linode_bucket, name ]`.
163
156
 
164
157
  ---
165
158
 
@@ -226,9 +219,6 @@ await RemoteServer.create({
226
219
  'one_drive_account_type': "personal",
227
220
  'pin_to_site_region': true,
228
221
  'port': 1,
229
- 'rackspace_container': "my-container",
230
- 'rackspace_region': "dfw",
231
- 'rackspace_username': "rackspaceuser",
232
222
  's3_bucket': "my-bucket",
233
223
  's3_compatible_access_key': "example",
234
224
  's3_compatible_bucket': "my-bucket",
@@ -266,7 +256,6 @@ await RemoteServer.create({
266
256
  * `google_cloud_storage_credentials_json` (string): Google Cloud Storage: JSON file that contains the private key. To generate see https://cloud.google.com/storage/docs/json_api/v1/how-tos/authorizing#APIKey
267
257
  * `google_cloud_storage_s3_compatible_secret_key` (string): Google Cloud Storage: S3-compatible secret key
268
258
  * `linode_secret_key` (string): Linode: Secret Key
269
- * `rackspace_api_key` (string): Rackspace: API key from the Rackspace Cloud Control Panel
270
259
  * `s3_compatible_secret_key` (string): S3-compatible: Secret Key
271
260
  * `wasabi_secret_key` (string): Wasabi: Secret Key
272
261
  * `aws_access_key` (string): AWS Access Key.
@@ -301,9 +290,6 @@ await RemoteServer.create({
301
290
  * `one_drive_account_type` (string): OneDrive: Either personal or business_other account types
302
291
  * `pin_to_site_region` (boolean): If true, we will ensure that all communications with this remote server are made through the primary region of the site. This setting can also be overridden by a site-wide setting which will force it to true.
303
292
  * `port` (int64): Port for remote server. Not needed for S3.
304
- * `rackspace_container` (string): Rackspace: The name of the container (top level directory) where files will sync.
305
- * `rackspace_region` (string): Rackspace: Three letter code for Rackspace region. See https://support.rackspace.com/how-to/about-regions/
306
- * `rackspace_username` (string): Rackspace: username used to login to the Rackspace Cloud Control Panel.
307
293
  * `s3_bucket` (string): S3 bucket name
308
294
  * `s3_compatible_access_key` (string): S3-compatible: Access Key
309
295
  * `s3_compatible_bucket` (string): S3-compatible: Bucket name
@@ -429,9 +415,6 @@ await remote_server.update({
429
415
  'one_drive_account_type': "personal",
430
416
  'pin_to_site_region': true,
431
417
  'port': 1,
432
- 'rackspace_container': "my-container",
433
- 'rackspace_region': "dfw",
434
- 'rackspace_username': "rackspaceuser",
435
418
  's3_bucket': "my-bucket",
436
419
  's3_compatible_access_key': "example",
437
420
  's3_compatible_bucket': "my-bucket",
@@ -469,7 +452,6 @@ await remote_server.update({
469
452
  * `google_cloud_storage_credentials_json` (string): Google Cloud Storage: JSON file that contains the private key. To generate see https://cloud.google.com/storage/docs/json_api/v1/how-tos/authorizing#APIKey
470
453
  * `google_cloud_storage_s3_compatible_secret_key` (string): Google Cloud Storage: S3-compatible secret key
471
454
  * `linode_secret_key` (string): Linode: Secret Key
472
- * `rackspace_api_key` (string): Rackspace: API key from the Rackspace Cloud Control Panel
473
455
  * `s3_compatible_secret_key` (string): S3-compatible: Secret Key
474
456
  * `wasabi_secret_key` (string): Wasabi: Secret Key
475
457
  * `aws_access_key` (string): AWS Access Key.
@@ -504,9 +486,6 @@ await remote_server.update({
504
486
  * `one_drive_account_type` (string): OneDrive: Either personal or business_other account types
505
487
  * `pin_to_site_region` (boolean): If true, we will ensure that all communications with this remote server are made through the primary region of the site. This setting can also be overridden by a site-wide setting which will force it to true.
506
488
  * `port` (int64): Port for remote server. Not needed for S3.
507
- * `rackspace_container` (string): Rackspace: The name of the container (top level directory) where files will sync.
508
- * `rackspace_region` (string): Rackspace: Three letter code for Rackspace region. See https://support.rackspace.com/how-to/about-regions/
509
- * `rackspace_username` (string): Rackspace: username used to login to the Rackspace Cloud Control Panel.
510
489
  * `s3_bucket` (string): S3 bucket name
511
490
  * `s3_compatible_access_key` (string): S3-compatible: Access Key
512
491
  * `s3_compatible_bucket` (string): S3-compatible: Bucket name
@@ -552,9 +531,6 @@ await remote_server.update({
552
531
  "wasabi_bucket": "my-bucket",
553
532
  "wasabi_region": "us-west-1",
554
533
  "wasabi_access_key": "example",
555
- "rackspace_username": "rackspaceuser",
556
- "rackspace_region": "dfw",
557
- "rackspace_container": "my-container",
558
534
  "auth_status": "in_setup",
559
535
  "auth_account_name": "me@example.com",
560
536
  "one_drive_account_type": "personal",
package/lib/Files.js CHANGED
@@ -12,7 +12,7 @@ var apiKey;
12
12
  var baseUrl = 'https://app.files.com';
13
13
  var sessionId = null;
14
14
  var language = null;
15
- var version = '1.2.294';
15
+ var version = '1.2.296';
16
16
  var userAgent = "Files.com JavaScript SDK v".concat(version);
17
17
  var logLevel = _Logger.LogLevel.INFO;
18
18
  var debugRequest = false;