twitter 0.4.0

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 52

twitter.dart

Build Status pub package

Twitter Library for Dart.

Example

REST API

import 'package:twitter/twitter.dart';

main () async {
  Twitter twitter= new Twitter('YOUR CONSUMER KEY', 'YOUR CONSUMER SERCRET',
                    'YOUR ACCESS TOKEN', 'YOUR ACCESS TOKEN SECERT');
  var response = await twitter.request("GET", "statuses/user_timeline.json");
  print(response.body);
}

STREAM API

Map keymap = {"consumerKey" : "YOUR CONSUMER KEY",
              "consumerSecret" : "YOUR CONSUMER SECRET",
              "accessToken" : "YOUR ACCESS TOKEN",
              "accessSecret" : "YOUR ACCESS SECRET"};
Twitter twitter = new Twitter.fromMap(keyMap);

TwitterStream userstream = await twitter.getStream();
userstream.listen((tweet) {
  print(tweet["text"]);
});

TODO

  • Write more detailed Example
  • Support Twitter Model
  • Support Stream Event

LICENSE

MIT LICENSE

0.4.0

  • Support Twitter Streaming API

0.3.1

  • Fix sdk version

0.3.0

  • Update dependencies
    • OAuth.dart - using random.secure function for generate randombytes
  • Fix README

0.2.0

  • Remove library tag
  • Add Twitter.fromMap constrcutor
  • Fix README

0.1.1

  • Fix problem that a delay occurs
  • Using Completer for Error Processing

0.1.0

Initial Version

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  twitter: "^0.4.0"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:twitter/twitter.dart';
        
Version Uploaded Documentation Archive
0.4.0 Feb 28, 2016 Go to the documentation of twitter 0.4.0 Download twitter 0.4.0 archive
0.3.1 Feb 28, 2016 Go to the documentation of twitter 0.3.1 Download twitter 0.3.1 archive
0.2.0+1 Feb 12, 2016 Go to the documentation of twitter 0.2.0+1 Download twitter 0.2.0+1 archive
0.2.0 Feb 12, 2016 Go to the documentation of twitter 0.2.0 Download twitter 0.2.0 archive
0.1.1 Sep 15, 2015 Go to the documentation of twitter 0.1.1 Download twitter 0.1.1 archive
0.1.0 Jul 12, 2015 Go to the documentation of twitter 0.1.0 Download twitter 0.1.0 archive

Analysis

This feature is new.
We welcome feedback.

We analyzed this package, and provided a score, details, and suggestions below.

  • tool failures on Dec 6, 2017
  • Dart: 2.0.0-dev.8.0
  • pana: 0.7.3+1

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
59
Health:
Code health derived from static analysis. [more]
64
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
18
Overall score:
Weighted score of the above. [more]
52

Platforms

Detected platforms:

Error(s) prevent platform classification.

Suggestions

  • Fix lib/src/twitter_stream.dart.

    Strong-mode analysis of lib/src/twitter_stream.dart failed with the following error:

    line: 23 col: 3
    Invalid override. The type of 'TwitterStream.listen' ('((Object) → void, {onError: (Error) → void, onDone: () → void, cancelOnError: bool}) → StreamSubscription<Object>') isn't a subtype of 'Stream<Object>.listen' ('((Object) → void, {onError: Function, onDone: () → void, cancelOnError: bool}) → StreamSubscription<Object>').

Dependencies

Package Constraint Resolved Available
Direct dependencies
http >=0.11.2 <0.12.0 0.11.3+16
oauth 0.3.0
Transitive dependencies
async 2.0.1
bignum 0.0.7 0.1.0
charcode 1.1.1
cipher 0.7.1
collection 1.14.3
convert 1.1.1 2.0.1
crypto 0.9.2+1 2.0.2+1
fixnum 0.9.1+2 0.10.6
http_parser 3.1.1
path 1.5.1
source_span 1.4.0
string_scanner 1.0.2
typed_data 1.1.5
Dev dependencies
test >=0.12.3+6 <0.13.0