Contact Us 1-800-596-4880

Multipart (dw::module::Multipart)

This helper module provide functions for creating MultiPart and formats and parts (including fields and boundaries) of MultiPart formats.

To use this module, you must import it into your DataWeave code, for example, by adding the line import dw::module::Multipart to the header of your DataWeave script.

Functions

Name Description

field

Creates a MultipartPart data structure using the specified part name, input content for the part, format (or mime type), and optionally, file name.

file

Creates a MultipartPart data structure from a resource file.

form

Creates a Multipart data structure using a specified array of parts.

generateBoundary

Helper function for generating boundaries in Multipart data structures.