1
我試圖按照reddit的API,如概述這裏:reddit的崗位API
https://github.com/reddit/reddit/wiki/API
登錄使用curl是沒有問題的:
curl -d user=user -d passwd=pass -c Cookie.txt http://www.reddit.com/api/login
,給了我一個cookie,其中(我認爲)包含我的用戶mod-hash:
4029916%2C2010-04-30T22%3A51%3A52%2C1243925043100000000000000000000000000000
接下來我正在嘗試發佈,使用:
curl -d uh=4029916%2C2010-04-30T22%3A51%3A52%2C1243925043100000000000000000000000000000 -d sr=test -d title=test -d r=test -c Cookie.txt http://www.reddit.com/api/submit
不過,我接收器的錯誤:
[".error.USER_REQUIRED"]
有人能解釋我沒有正確地做/我怎麼能解決這個問題?