Closed Sourovahmad closed 1 year ago
i have faced same issue too. is there any fix?
What do you get from these after you make the request?
$connection->getLastHttpCode();
$connection->getLastBody();
i think we cannot use if we have free version. s, this is not considered as bug as i manage to post a tweet using post. Official websites of twitter says "write-only use cases and testing the Twitter API for v2".
if ($connection->getLastHttpCode() == 201) { echo "API request successful! HTTP response code: " . $connection->getLastHttpCode() . "\n"; echo "API response:\n"; print_r($response); } else { echo "API request failed! HTTP response code: " . $connection->getLastHttpCode(); }
i am getting 403 error code (referes to forbidden in official site) for get method and success for post method and i have free version of twitter. Do want me to test anything if i have 403 code. i assume it's because of free version.
Yep. That looks like the reason.
What do you get from these after you make the request?
$connection->getLastHttpCode(); $connection->getLastBody();
sorry for late reply.
i got 404 on $connection->getLastHttpCode();
and null on $connection->getLastBody()
my codes are simple using laravel version 8.0 and using "abraham/twitteroauth": "^6.1",
hi there, https://developer.twitter.com/en/support/twitter-api/error-troubleshooting please refer to this. i think you check that you are using valid parameters and the correct URI for the endpoint you’re using.
Thank you !
i have a free account on twitter developer. on the developer portal i got the consumer key and secret. as well as the access token and secret. but when i call
i got null. could anyone please explain me why is that ?