Hi, @lxcichano .
Thank you for replying again ,help and advice
First of all, I will do my best until Curl passes.
Then I will think about Python code.
docs POST example is
curl -X POST “https://api.twitter.com/1.1/tweets/search/:product/:label.json” -d
’{“query”:“TwitterDev “search api””,“maxResults”:“500”,“fromDate”:“yyyymmddhhmm”,
“toDate”:“yyyymmddhhmm”}’ -H “Authorization:
Bearer TOKEN”
I changed Below ,From POST example
:product → 30day
:label → SnsTwitter
yyyymmddhhmm(fromDate) → 201802010000
yyyymmddhhmm(toDate) → 201802020000
TOKEN → 999999999999999999-AAAAAAAAAAAAAAAAAAAAAA(My Access Token)
“query”:“TwitterDev “search api”” → “query”:“snow”
The Curl command should be like this
curl -X POST “https://api.twitter.com/1.1/tweets/search/30day/SnsTwitter.json” -d ‘{“query”:“snow”,“maxResults”:“500”,“fromDate”:“201802010000”,
“toDate”:“201802020000”}’ -H “Authorization:
Bearer 999999999999999999-AAAAAAAAAAAAAAAAAAAAAA(My Access Token)”
but ,The response is this
{“error”:{“message”:“Invalid or expired token.”,“sent”:“2018-02-10T15:18:08+00:00”,“transactionId”:“003b61cd0028d019”}}
Can I authenticate with access token only?
Please give me some advice.
Thank you