For anyone else who got same problem here I found the solution, you basically need to include the api uri.
Up vote 1 down vote favorite share g+ share fb share tw.
I am trying to connect to rackspace using their api and passing my username and api key but I get this error : The remote server returned an error: (401) Unauthorized. Here is my code : UserCredentials userCreds = new UserCredentials("myusername", "myapikey"); Connection connection = new Connection(userCreds); I have followed this tutorial : rackspace.com/knowledge_center/index.php... have asked their support and they say we can connect with same key using curl...and they couldnt provide much help. Anyone has any idea?
Thanks c# connection rackspace unauthorized cloudfiles link|improve this question asked Feb 15 at 17:15Sam13036 100% accept rate.
For anyone else who got same problem here I found the solution, you basically need to include the api uri : blog.chmouel.com/2011/01/04/how-to-use-t....
Your sample works but I was looking for a direct way, without the wrapper. This seems to work as well, and uses direct restful access to the Rackspace API. Hope it helps.
Cheers. String url = "auth.api.rackspacecloud.com/v1.0"; HttpWebRequest request = (HttpWebRequest)WebRequest. Create(url); request.Headers.
Add("X-Auth-User:" + userName); request.Headers. Add("X-Auth-Key:" + apiKey); request. Method = "GET"; using (HttpWebResponse response = (HttpWebResponse)request.GetResponse()) { string keys = response.Headers.
AllKeys; foreach (var k in keys) Console. WriteLine(response. Headersk); }.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.