title: Github OAuth2 access token endpoint returning 'not found'. [Node]
body: <p>Currently trying to get a user's access token back from github, but receiving the following object: </p>
  
  <pre><code>{"error": "Not Found"}
  </code></pre>
  
  <p>I can't see exactly what I'm doing wrong with this fetch request and I believe I have all the right tokens etc. The guide I'm following uses (I think it's called) superagent, while I'm just using regular ol' isomorphic-fetch so perhaps that's where some of the confusion lies. </p>
  
  <p>Here's my code: </p>
  
  <pre><code> fetch("https://github.com/login/oauth/access_token", {
      method: "POST",
      body: {
        client_id: process.env.CLIENT_ID,
        client_secret: process.env.CLIENT_SECRET,
        code: code,
        redirect_uri: "/"
      },
      headers: {
        Accept: "application/json"
      }
    })
      .then(res =&gt; res.json())
      .then(body =&gt; {
        console.log("body" + JSON.stringify(body));
        res.send({
          success: true,
          message: "Succesfully Logged In!",
          userToken: body.access_token
        });
      });
  </code></pre>
  
  <p>I double checked the env.client_id, and the env.client_secret and they're both being imported correctly. The code I can only guess at, but it seems to be right from when I logged it out.</p>