Constructor
new CatboxClient(userHashopt)
Creates an instance of CatboxClient.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
userHash |
string |
<optional> |
null | The userhash to use for operations |
Methods
(async) deleteFiles(files) → {boolean}
Deletes files.
NOTE: This requires a userhash to be specified!
Parameters:
Name | Type | Description |
---|---|---|
files |
Array.<string> | The file names to delete |
(async) fileUpload(path) → {Promise.<string>}
Uploads a file
Parameters:
Name | Type | Description |
---|---|---|
path |
string | The path of the file to upload |
(async) urlUpload(url) → {Promise.<string>}
Uploads a file from a URL
Parameters:
Name | Type | Description |
---|---|---|
url |
string | The url of the file to upload |