GithubHelp home page GithubHelp logo

netr0m / fluttersteem Goto Github PK

View Code? Open in Web Editor NEW
4.0 4.0 2.0 63 KB

[Pre-Alpha] Flutter/Dart Steem client library

Home Page: https://pub.dartlang.org/packages/fluttersteem

License: MIT License

Objective-C 0.59% Dart 99.41%
steem steemconnect steemjs api dart flutter client

fluttersteem's Introduction

fluttersteem

Pub

A Flutter/Dart Steem client library. This library includes support for authentication (SteemConnect V2) as well as Broadcasting (vote, comment, follow ++) and data retrieval (get followers, posts by users, users ++).

Authentication

Via Access Token

If you already have an access token, you can authenticate a client.

Note: The user property of the SteemClient will be null.

var client = SteemApiAuth.authorizeViaAccessToken('<access-token>');
var me = await client.users.self.get();

SteemApiAuth

To perform authentication, use the SteemApiAuth class. All API scopes are included as SteemApiScope constants for convenience.

var auth = new SteemApiAuth('<client-id>', '<client-secret>',
  redirectUri: Uri.parse('<redirect-uri>'),
  scopes: [
    SteemApiScope.login,
    SteemApiScope.vote,
    // ...
  ]
);

Implicit Auth

Applications with no server-side component can implement implicit auth.

To get a redirect URI:

var redirectUri = auth.getImplicitRedirectUri();
window.location.href = redirectUri.toString();

After you have obtained an access token, use it to receive a SteemClient.

Endpoints

The SteemClient contains several getters that correspond to endpoints. Each is an abstraction over a specific Steem API.

Credits

This client library is written based on the code of instagram_dart

fluttersteem's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

fluttersteem's Issues

URI parse error on Uri containing '?'

When a request Uri is parsed, and it contains a '?' question mark, it causes an exception:

// Report a parse failure.
  static void _fail(String uri, int index, String message) {    uri: "/lookup_accounts?lowerBoundName=amigos&limit=16"    index: 16    message: "Invalid character"
    throw new FormatException(message, uri, index);
  }

This happens to any Uri containing a '?', although '?' should be allowed (it's a reserved character of Uri's)

Credit/attribution notice

Hi, I noticed a great deal of similarity between this package and my earlier one: https://github.com/thosakwe/instagram_dart

This is fine. Such is the nature of open-source.

What I do ask, however, is that you put some sort of mention or reference to instagram_dart, so that if there are underlying bugs caught here, they can be fixed both in fluttersteem and instagram_dart. The MIT License simply asks that you reference the original when producing a copy.

Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.