Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Usage API #22

Merged
merged 11 commits into from
Feb 8, 2017
Merged

Added Usage API #22

merged 11 commits into from
Feb 8, 2017

Conversation

JamesFrost
Copy link
Contributor

Very simple api wrapper for the Usage API.

Handles auth + rate limiting.

Copy link
Collaborator

@dirkbonhomme dirkbonhomme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @JamesFrost

Thanks a lot for making these changes and adding new features! I left a few comments, can you look into them please?

Best,
Dirk

return;
}

if( typeof body !== 'undefined' )
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please wrap this statement in curly brackets

lib/usage.js Outdated
if( typeof body !== 'undefined' )
body = JSON.parse( body );

if (response.statusCode >= 200 && response.statusCode < 300) cb(null, body);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please wrap this statement in curly brackets

@@ -2,11 +2,15 @@ var EventEmitter = require('events').EventEmitter,
JSONParser = require('./JSONParser').JSONParser,
util = require('util'),
GnipRules = require('./rules'),
GnipUsage = require('./usage'),
GnipSearch = require('./search'),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like you've documented GnipUsage in the Readme but not GnipSearch?

@JamesFrost
Copy link
Contributor Author

Hey @dirkbonhomme,

I've made the changes you've requested.

@dirkbonhomme dirkbonhomme merged commit 406e899 into demian85:master Feb 8, 2017
@dirkbonhomme
Copy link
Collaborator

Thanks @JamesFrost! I've released your changes as v1.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants