How would one do the following with the request npm module?
request
curl https://todoist.com/oauth/access_token \\ -d client_id=0123456789abcdef \\
const formData = { client_id: '0123456789abcdef', client_secret: 'secret', code: 'abcdef' }; request.post( { url: 'https://todoist.com/oauth/access_token', form: formData }, function (err, httpResponse, body) { console.log(err, body); } );
Please try this code.