How to use OAuth 1.0 in Visual Basic?
Hi everyone! I'm trying to make a bot for Tumblr or Twitter, but both require OAuth requests. I'm not sure how to use a Net.WebRquest this way. I've searched all over and found very scarce information. I believe I am supposed to add some credentials in the header. This is what I have tried:
Code:
Dim request As WebRequest = WebRequest.Create(URL)
request.Headers.Add(HttpRequestHeader.Authorization,
$"OAuth realm=""https://api.tumblr.com/"",
oauth_consumer_key=""{APIKEY}"",
oauth_token=""{TOKEN}"",
oauth_signature_method=""HMAC-SHA1"",
oauth_signature=""?"",
oauth_timestamp=""{(Now - New DateTime(1970, 1, 1)).TotalSeconds}"",
oauth_nonce=""{Now.GetHashCode()}"",
oauth_version=""1.0""")
Assuming APIKEY and TOKEN are valid, I am still getting Error 401: Unauthorized. Also, what do I put in "oauth_signature"? That did not make any sense to me. This website contained the most useful information: https://oauth.net/core/1.0a/
Has anyone else here dealt with OAuth requests before, that can help me? If there were any examples out there, that would be wonderful. Thank you so much in advance.
~Nic
Re: How to use OAuth 1.0 in Visual Basic?
Oauth has unique handshakes you cant just send a post with headers and expect it to work. I suggest using Javas tumblr api they already have it coded. Or python
Bots with tumblr arent really good the api are limited and if youre doing blackhat stuff youll need load of proxies
twitter has twitter jail and limits for new users. they take forever to build up
good luck
Re: How to use OAuth 1.0 in Visual Basic?
Quote:
Oauth has unique handshakes you cant just send a post with headers and expect it to work.
Thanks for the tip. I guess my question is now, is it worth it to learn, because even still I'm having trouble finding guides and examples.
Re: How to use OAuth 1.0 in Visual Basic?
I haven't ever specifically used Tumblr, and I'm only casually familiar with OAuth. But the documentation makes it sound like that field is a digital signature you generate and register ahead of time with Tumblr to strengthen identity verification of your requests. Or it's possible they generate it and give it to you.
Re: How to use OAuth 1.0 in Visual Basic?