GitHub.js

Checking the ratelimit

var GitHub = require('github-api');

var gh = new GitHub();

// check our rate-limit status
// since we're unauthenticated the limit is 60 requests per hour
gh.getRateLimit().getRateLimit()
  .then(function(resp) {
      console.log('Limit remaining: ' + resp.data.rate.remaining);
      // date constructor takes epoch milliseconds and we get epoch seconds
      console.log('Reset date: ' + new Date(resp.data.rate.reset * 1000));
  }).catch(function(error) {
      console.log('Error fetching rate limit', error.message);
  });

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy