Classes
Methods
(static) save(config, uxioObject) → {Promise.<Array.<object>>}
- Description:
- Saves one or more files based on the provided configuration. The configuration can be a single object or an array of objects for granular control. On failure, any files that were already saved successfully are deleted (rolled back).
- Source:
Parameters:
| Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
config |
object | Array.<object> | The save configuration.
Properties
|
||||||||||||||||||||||||||||||||||||||||
uxioObject |
object | The `req.uxio` object containing cached file data. |
Returns:
An array of file info objects.
- Type
- Promise.<Array.<object>>
(static) send(config, uxioObject) → {Promise.<Array.<object>>}
- Description:
- Sends one or more files to an external service (e.g., S3, custom server). On failure, any files that were already sent are deleted from the external service (rolled back).
- Source:
Parameters:
| Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
config |
object | Array.<object> | The send configuration.
Properties
|
||||||||||||||||||||||||||||||||||||||||
uxioObject |
object | The `req.uxio` object containing cached file data. |
Returns:
An array of file info objects from the provider.
- Type
- Promise.<Array.<object>>
Type Definitions
validations
- Source:
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
maxSize |
number |
<optional> |
Maximum file size in bytes. |
mimeType |
Array.<string> |
<optional> |
Allowed MIME types. |
Type:
- object