tripit / api

TripIt's API Documentation and Support Forum
http://www.tripit.com/developer
Other
47 stars 16 forks source link

C# Examples #143

Closed Treycent closed 9 years ago

Treycent commented 9 years ago

I am using the latest (3 years old) C# binding found here: https://github.com/tripit/csharp_binding_v1 and I keep getting "(401) Unauthorized" on the last line:

OAuthCredential c1 = new OAuthCredential(consumerKey, consumerSecret); TripIt t1 = new TripIt(c1, apiUrl); OAuthCredential requestToken = t1.GetRequestToken(); //this request succeeds ... OAuthCredential c2 = new OAuthCredential(consumerKey, consumerSecret, requestToken, requestTokenSecret); TripIt t2 = new TripIt(c2, apiUrl); OAuthCredential authorizedCredential = t2.GetAccessToken(); //this request fails with 401

Can you please provide a working example in C#?

hliss commented 9 years ago

Hiya. Checking our logs, please make sure that the access_token request is made in a timely fashion after the request token is authorized. It looks here like the authorized request token expired by the time the access_token request was made.

You've contacted api-support directly; I'll provide more details there and close this. Cheers!

Treycent commented 9 years ago

That was it - thanks!