title: Adding multiple users JSON for Google Directory API (Python)
body: <p>When I try to add users:
  In this way I can only add one user, but I will need to add multiple users from the JSON file.</p>
  <pre><code>req =  [
              {
                  &quot;primaryEmail&quot;: &quot;first.user@mydomain.com&quot;,
                  &quot;name&quot;: {
                              &quot;givenName&quot;: &quot;UserName&quot;,
                              &quot;familyName&quot;: &quot;UserLastName&quot;
                          },
                  &quot;suspended&quot;: False,
                  &quot;password&quot;: &quot;my password&quot;,
                  &quot;hashFunction&quot;: &quot;SHA-1&quot;,
                  &quot;changePasswordAtNextLogin&quot;: False,
                  &quot;agreedToTerms&quot;: True,
                  &quot;ipWhitelisted&quot;: False                
              },
              {
                  &quot;primaryEmail&quot;: &quot;second.user@exnesstest.com&quot;,
                  &quot;name&quot;: {
                              &quot;givenName&quot;: &quot;FirstName&quot;,
                            &quot;familyName&quot;: &quot;LastName&quot;
                         },
                  &quot;suspended&quot;: False,
                  &quot;password&quot;: &quot;my password&quot;,
                  &quot;hashFunction&quot;: &quot;SHA-1&quot;,
                  &quot;changePasswordAtNextLogin&quot;: False,
                  &quot;agreedToTerms&quot;: True,
                  &quot;ipWhitelisted&quot;: False               
  
              }
          ]
  users = service.users().insert(body=req).execute()
  </code></pre>
  <p>I get some error like:</p>
  <pre><code>googleapiclient.errors.HttpError: &lt;HttpError 400 when requesting https://admin.googleapis.com/admin/directory/v1/users?alt=json returned &quot;Invalid Input: primary_user_email&quot;&gt;
  </code></pre>
  <p>How can I add multiple users in this way?</p>