1.3.0 • Published 6 years ago

circle-of-trust v1.3.0

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

Circle of Trust

Get info about a user's circle.

Documentation

This package exports a function for getting a circle from a Reddit username (using ES6 Promises), like so:

const circleOfTrust = require("circle-of-trust");
circleOfTrust("haykam821")
    .then(console.log) // Circle information (see below)
    .catch(console.error); // Failed to get circle info (e.g. no such user or circle)

The promise resolves with an object containing information about the circle:

PropertyTypeDescription
circle.nameStringThe name given to the circle
circle.linkStringA permalink to the circle
circle.idStringThe circle's identifier
circle.ownerStringThe owner, good chance it'll be the person you specified.
circle.betrayedBooleanWhether the circle has been betrayed or not.
circle.scoreNumberThe score of the circle.
circle.keyNullIf key already used, that key as a String. Otherwise, Null.