• Nikhil Hasija
  • NEWBIE
  • 0 Points
  • Member since 2011
  • Azuqua

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

I'm writing middleware in WCF and trying to obtain an authorization token from salesforce for OAuth.

I'm posting to https://login.salesforce.com/services/oauth2/token with the following data:

 

string postData = "client_id=" + key + "&client_secret=" + secret + "&redirect_url=http://localhost:1670/myservice.svc/callback" + "&grant_type=authorization_code";

 

SF keeps telling me "400 Bad Request"

 

Does anyone have any experience with this?

  • February 01, 2011
  • Like
  • 0