Socket
Socket
Sign inDemoInstall

@request/multipart

Package Overview
Dependencies
5
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @request/multipart

HTTP Multipart Body Stream


Version published
Weekly downloads
90
increased by80%
Maintainers
2
Install size
288 kB
Created
Weekly downloads
 

Readme

Source

@request/multipart

See @request/core for more details.

var options = {
  // related
  multipart: [],
  // form-data
  multipart: {},

  // optional
  contentType: 'multipart/related; boundary=',
  boundary: '',
  preambleCRLF: true,
  postambleCRLF: true
}


var result = multipart(options)

result.contentType
result.body
// related
multipart: [{key: 'value', body: 'body'}]
multipart: [{key: 'value', body: 'body'}]

// form-data
multipart: {key: 'value'}
multipart: {key: ['value', 'value']}
multipart: {key: {
  value: 'value',
  options: {filename: '', contentType: '', knownLength: 0}
}}

Notice

This module may contain code snippets initially implemented in request by request contributors.

Keywords

FAQs

Last updated on 02 Dec 2015

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc