New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

node-destiny

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-destiny

node api client for Bungies Destiny API

latest
Source
npmnpm
Version
1.0.3
Version published
Maintainers
1
Created
Source

node-destiny

Node library for interacting with Destiny API

Build Status

Installation

npm install node-destiny

Example Usage

const apiKey = process.env.BUNGIE_API_KEY;
const destiny = require('node-destiny');
const destinyClient = new destiny.DestinyClient( apiKey );

Each method on DestinyClient returns a Promise. Here is an example of searching for an Xbox player:

// membershipType of '1' means this is an Xbox Player
destinyClient.search('1', 'Carsten').then( response => {
    //do something with the response
});

Check out the DestinyClient to see all available methods.

By default, these endpoints will return data that includes unique identifiers for all items, events, activities, etc... In order to look up the corresponding text value of these ids, you must tell the API to return 'definitions' with each call. This is done as follows:

destinyClient.definitions = true;

This will make all API requests return definitions until you set definitions back to false;

For more information about what each method does and paramaters available, see Bungies API Documentation.

Keywords

node

FAQs

Package last updated on 07 Jul 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts