You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

You can combine two or more contents with different types (e.g. JSON & texts) in the same request body. When you do this, the request's Content-Type is set to multipart/form-data. To create a multipart body and add a content to a multipart body, you simply need to invoke one of these Add… methods more than once:

  • AddJsonObject
  • AddJsonArray
  • AddString
  • AddFile

Refer to the limitations of using AddFile on IBM i.
Note that you can't use AddUrlEncodedFormValue together with the other Addxxxxxxx methods.
Next: Reading the Response

  • No labels