Signing a custom twitter stream request using OAuth

I am trying to sign a request with OAuth. I have read many articles about this, but I don’t know how to actually use it right now.

I have this URL: https://userstream.twitter.com/2/user.json And I want to name it for a specific user. I have an application (with a Consumer key secret key) and an API key for the account I want to use. So it remains only to note this. I used this page: http://hueniverse.com/2008/10/beginners-guide-to-oauth-part-iv-signing-requests/ and got a code block similar to this:

GET /photos?size=original&file=vacation.jpg HTTP/1.1
Host: photos.example.net:80
Authorization: OAuth realm="http://photos.example.net/photos",
    oauth_consumer_key="dpf43f3p2l4k3l03",
    oauth_token="nnch734d00sl2jdk",
    oauth_nonce="kllo9940pd9333jh",
    oauth_timestamp="1191242096",
    oauth_signature_method="HMAC-SHA1",
    oauth_version="1.0",
    oauth_signature="tR3%2BTy81lMeYAr%2FFid0kMTYa%2FWM%3D"

However, cURL does not accept this. How do I create something that will work with cURL?

Thanks in advance

EDIT: cURL, -, ++ GNU/Linux

+3
1

Twitter (Windows) OAuth, :

curl -k "https://userstream.twitter.com/2/user.json" --header "Authorization: OAuth realm=""Twitter API"",oauth_consumer_key=""dpf43f3p2l4k3l03"",oauth_token=""nnch734d00sl2jdk"",oauth_nonce=""kllo9940pd9333jh"",oauth_timestamp=""1191242096"",oauth_signature_method=""HMAC-SHA1"",oauth_version=""1.0"",oauth_signature=""tR3%2BTy81lMeYAr%2FFid0kMTYa%2FWM%3D"""

, Java, , , , OAuth URL, .

Method: GET
URI Scheme: https
Host Name: userstream.twitter.com
Port: 443
Request Path: /2/user.json
Parameters: [remove all]

, Twitter API, .

, ++ Twitter, , Twitter, , - .

+1

All Articles