Added getAccessToken cURL function

return contains info needed for new constructor