esa.io API JavaScript client written in TypeScript. https://docs.esa.io/posts/102
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
release
src
README.md
gulpfile.js
package.json
tsconfig.json

README.md

esa.io API - JavaScript Client

This package is a JavaScript client of the esa.io's API v1, written in TypeScript (and transpiled into Node JS module.

It provides one function for each endpoint, returning a promise.

Usage Guide

Package Installation

This project can be installed as a node module with

$ npm install tanatana/node-esa

We are currently preparing for publish npm package.

Basic Usage

Setup

var Esa = require('node-esa').Esa;
var esa = new Esa(YOUR_TEAM_NAME, YOUR_ACCESS_TOKEN);

Fetch team stats.

esa.teams.stats().then(function(stats){
  console.log(stats);
});

Fetch team members.

esa.teams.members().then(function(members){
  console.log(members);
});

Fetch recent posts.

esa.teams.posts().then(function(posts){
  console.log(posts);
});

Fetch a specific post.

esa.teams.post(POST_NUMBER).then(function(post){
  console.log(post);
});

Fetch a specific comment.

esa.teams.comment(COMMENT_NUMBER).then(function(comment){
  console.log(comment);
});

Development

wip.

TODO

  • Supports all endpoints.

How to build

Testing

Contributors

Feel free to send a pull request if you wish to contribute.

Legal

API Client provided under the MIT license.