title: Problem in uploading video googleapis youtube
body: <p>I am developing a bot with javascript, I am using the following code:</p>
  <pre class="lang-js prettyprint-override"><code>const service = google.youtube('v3');
      service.videos.insert(
        {
          auth,
          part: 'id,snippet',
          resource: {
            snippet: {
              title: 'My title',
              description: 'This is a test',
            },
            status: {
              privacyStatus: 'private',
            },
          },
          media: {
            body: fs.createReadStream(videoUrl),
          },
        },
        (err, res) =&gt; {
          if (err) {
            reject(err);
          }
        }
      );
  </code></pre>
  <p>but I am getting this error:</p>
  <pre><code>GaxiosError: 'status'
  {
    response: {
      config: {
        url: 'https://youtube.googleapis.com/upload/youtube/v3/videos?part=id%2Csnippet&amp;uploadType=multipart',
        method: 'POST',
        userAgentDirectives: [
          {
            product: 'google-api-nodejs-client',
            version: '5.1.0',
            comment: 'gzip'
          }
        ],
        ......
        headers: { my headers }
        ......
        code: 400,
        errors: [
            {
              message: &quot;'status'&quot;,
              domain: 'youtube.part',
              reason: 'unexpectedPart',
              location: 'part',
              locationType: 'parameter'
            }
        ]
  </code></pre>
  <p>I believe that the problem is with the statius, as soon as I remove it, it works. Please help me, how can I upload the video while still leaving it in public?</p>