Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

Merge pull request #700 from dgellow/remove-ref-to-request#part

docs: remove references to the deprecated Request.part()
  • Loading branch information...
commit 06e056f79c451a0add23843238f236ebd8f820c6 2 parents 9f10b1b + 8be0f55
@defunctzombie defunctzombie authored
Showing with 1 addition and 18 deletions.
  1. +1 −18 docs/
19 docs/
@@ -350,24 +350,7 @@ In a similar fashion to the `.type()` method it is also possible to set the Acce
## Multipart requests
- Super Agent is also great for _building_ multipart requests, providing a both low-level and high-level APIs.
- The low-level API uses `Part`s to represent a file or field. The `.part()` method returns a new `Part`, which provides an API similar to the request itself.
- var req ='/upload');
- req.part()
- .set('Content-Type', 'image/png')
- .set('Content-Disposition', 'attachment; filename="myimage.png"')
- .write('some image data')
- .write('some more image data');
- req.part()
- .set('Content-Disposition', 'form-data; name="name"')
- .set('Content-Type', 'text/plain')
- .write('tobi');
- req.end(callback);
+ Super Agent is also great for _building_ multipart requests for which it provides methods `.attach()` and `.field()`.
### Attaching files
Please sign in to comment.
Something went wrong with that request. Please try again.