title: Upload Multiple Images to API using Multi Image Picker
body: <p>I am attempting to implement the ability to upload multiple images (along with some other data) to an API using data entered via a form on my flutter application. </p>
  
  <p>I am using <a href="https://pub.dev/packages/multi_image_picker" rel="nofollow noreferrer">https://pub.dev/packages/multi_image_picker</a> which stores all the images as a <code>List&lt;Asset&gt;</code></p>
  
  <p>The API I am attempting to connect with says it requires the following fields.</p>
  
  <pre><code>firstname, lastname and images[].
  </code></pre>
  
  <p>I have started to encode the json body using:</p>
  
  <pre><code>var body = json.encode({"firstname": firstNameField, "lastname": lastNameField, "images": imageList});
  </code></pre>
  
  <p>but this failed. Does anyone have any suggestions?</p>