How to retrieve the created_At property of a tweet? #195
-
as above |
Beta Was this translation helpful? Give feedback.
Answered by
myConsciousness
May 30, 2022
Replies: 1 comment
-
Hi @JinZr ! The Twitter API v2.0 is designed to add the necessary https://developer.twitter.com/en/docs/twitter-api/fields And this library supports this specification like below :) import 'package:twitter_api_v2/twitter_api_v2.dart' as v2;
void main() async {
final twitter = v2.TwitterApi(bearerToken: 'YOUR_TOKEN_HERE');
try {
final volumeStream = await twitter.tweetsService.connectVolumeStream(
// Add this argument.
tweetFields: [
v2.TweetField.createdAt,
],
);
await for (final response in volumeStream.handleError(print)) {
print(response.data.createdAt);
}
} on v2.TwitterException catch (e) {
print(e);
}
} Now I'm going to support other |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
myConsciousness
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi @JinZr !
The Twitter API v2.0 is designed to add the necessary
fields
as needed.https://developer.twitter.com/en/docs/twitter-api/fields
And this library supports this specification like below :)
N…