Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

the-traveler

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

the-traveler - npm Package Compare versions

Comparing version 0.5.0 to 0.6.0

20

build/interfaces.d.ts

@@ -623,2 +623,13 @@ import { BungieMembershipType, ComponentPrivacySetting, ComponentType, DamageType, DestinyActivityDifficultyTier, DestinyActivityModeType, DestinyClass, DestinyGameVersion, DestinyGender, DestinyRace, DestinyStatsGroupType, DestinyTalentNodeState, EquipFailureReason, ItemBindStatus, ItemLocation, ItemState, PeriodType, PlatformErrorCodes, StatsCategoryType, TransferStatus, UnitType, VendorItemRefundPolicy, VendorItemStatus } from './enums';

/**
* The object to transfer items from the post master
* @interface
*/
export interface IDestinyPostMasterTransferRequest {
itemReferenceHash: string;
stackSize: number;
itemId: string;
characterId: string;
membershipType: BungieMembershipType;
}
/**
* Interface for a signle destiny profile

@@ -720,2 +731,11 @@ * @interface

/**
* Interface for data regarding the reporting of an offensive placer in an activity. Hashes can be found in the manifest.
* @interface
*/
export interface IDestinyReportOffensePgcrRequest {
reasonCategoryHashes: [string];
reasonHashes: [string];
offendingCharacterId: number;
}
/**
* Represents a stat on an item *or* Character (NOT a Historical Stat, but a physical attribute stat like Attack, Defense etc...)

@@ -722,0 +742,0 @@ * @interface

2

build/Manifest.d.ts
/**
* Class for accessing the manifest file
* Class for accessing the manifest file. You will need to install <strong>sqlite3</strong> to use this class.
*/

@@ -4,0 +4,0 @@ export default class Manifest {

@@ -6,3 +6,3 @@ "use strict";

/**
* Class for accessing the manifest file
* Class for accessing the manifest file. You will need to install <strong>sqlite3</strong> to use this class.
*/

@@ -9,0 +9,0 @@ var Manifest = /** @class */ (function () {

import { BungieMembershipType, TypeDefinition } from './enums';
import { IAPIResponse, IConfig, IDestinyActivityHistoryResults, IDestinyAggregateActivityResults, IDestinyCharacterResponse, IDestinyClanAggregateStat, IDestinyDefinition, IDestinyEntitySearchResult, IDestinyEquipItemResults, IDestinyHistoricalStatsAccountResult, IDestinyHistoricalStatsByPeriod, IDestinyHistoricalStatsDefinition, IDestinyHistoricalWeaponStatsData, IDestinyItemActionRequest, IDestinyItemResponse, IDestinyItemSetActionRequest, IDestinyItemStateRequest, IDestinyItemTransferRequest, IDestinyManifest, IDestinyMilestone, IDestinyMilestoneContent, IDestinyPostGameCarnageReportData, IDestinyProfileResponse, IDestinyPublicMilestone, IDestinyVendorResponse, IOAuthResponse, IQueryStringParameters, IUserInfoCard, IUserMembershipData } from './interfaces';
import { IAPIResponse, IConfig, IDestinyActivityHistoryResults, IDestinyAggregateActivityResults, IDestinyCharacterResponse, IDestinyClanAggregateStat, IDestinyDefinition, IDestinyEntitySearchResult, IDestinyEquipItemResults, IDestinyHistoricalStatsAccountResult, IDestinyHistoricalStatsByPeriod, IDestinyHistoricalStatsDefinition, IDestinyHistoricalWeaponStatsData, IDestinyItemActionRequest, IDestinyItemResponse, IDestinyItemSetActionRequest, IDestinyItemStateRequest, IDestinyItemTransferRequest, IDestinyManifest, IDestinyMilestone, IDestinyMilestoneContent, IDestinyPostGameCarnageReportData, IDestinyPostMasterTransferRequest, IDestinyProfileResponse, IDestinyPublicMilestone, IDestinyReportOffensePgcrRequest, IDestinyVendorResponse, IOAuthResponse, IQueryStringParameters, IUserInfoCard, IUserMembershipData } from './interfaces';
/**

@@ -144,2 +144,10 @@ * Entry class for accessing the Destiny 2 API

/**
* Report a player that you met in an activity that was engaging in ToS-violating activities. Both you and the offending player must have played in the activityId passed in.
* Please use this judiciously and only when you have strong suspicions of violation, pretty please.
* @async
* @param activityId The ID of the activity where you ran into the brigand that you're reporting.
* @return {Promise.IAPIResponse<IDestinyPostGameCarnageReportData>} When fulfilled returns an object containing the carnage report for the specified activity
*/
reportOffensivePostGameCarnageReportPlayer(activityId: string, destinyReportOffensePgcrRequest: IDestinyReportOffensePgcrRequest): Promise<IAPIResponse<number>>;
/**
* Get historical stats definitions. This contains the values for the `<br` key.

@@ -359,2 +367,8 @@ * @async

/**
* Extract an item from the Postmaster, with whatever implications that may entail. You must have a valid Destiny account. You must also pass BOTH a reference AND an instance ID if it's an instanced item.
* @async
* @param postMasterTransferRequest
*/
pullFromPostmaster(postMasterTransferRequest: IDestinyPostMasterTransferRequest): Promise<IAPIResponse<number>>;
/**
* Transfer an item to/from your vault. You must have a valid Destiny account. You must also pass BOTH a reference AND an instance ID if it's an instanced item (in your inventory).

@@ -361,0 +375,0 @@ * @async

@@ -339,2 +339,29 @@ "use strict";

/**
* Report a player that you met in an activity that was engaging in ToS-violating activities. Both you and the offending player must have played in the activityId passed in.
* Please use this judiciously and only when you have strong suspicions of violation, pretty please.
* @async
* @param activityId The ID of the activity where you ran into the brigand that you're reporting.
* @return {Promise.IAPIResponse<IDestinyPostGameCarnageReportData>} When fulfilled returns an object containing the carnage report for the specified activity
*/
Traveler.prototype.reportOffensivePostGameCarnageReportPlayer = function (activityId, destinyReportOffensePgcrRequest) {
var _this = this;
if (this.oauth !== undefined) {
this.oauthOptions.body = destinyReportOffensePgcrRequest;
this.options.uri = this.apibase + "/Stats/PostGameCarnageReport/" + activityId + "/Report/";
this.oauthOptions.json = true;
return new Promise(function (resolve, reject) {
_this.httpService.post(_this.oauthOptions)
.then(function (response) {
resolve(response);
})
.catch(function (err) {
reject(err);
});
});
}
else {
throw new OAuthError_1.default('You have to use OAuth to access this endpoint. Your oauth object is this: ' + JSON.stringify(this.oauth) + ' Please use traveler.oauth = yourOauthObject to set it.');
}
};
/**
* Get historical stats definitions. This contains the values for the `<br` key.

@@ -763,2 +790,27 @@ * @async

/**
* Extract an item from the Postmaster, with whatever implications that may entail. You must have a valid Destiny account. You must also pass BOTH a reference AND an instance ID if it's an instanced item.
* @async
* @param postMasterTransferRequest
*/
Traveler.prototype.pullFromPostmaster = function (postMasterTransferRequest) {
var _this = this;
if (this.oauth !== undefined) {
this.oauthOptions.body = postMasterTransferRequest;
this.oauthOptions.uri = this.apibase + "/Actions/Items/PullFromPostmaster/";
this.oauthOptions.json = true;
return new Promise(function (resolve, reject) {
_this.httpService.post(_this.oauthOptions)
.then(function (response) {
resolve(response);
})
.catch(function (err) {
reject(err);
});
});
}
else {
throw new OAuthError_1.default('You have to use OAuth to access this endpoint. Your oauth object is this: ' + JSON.stringify(this.oauth) + ' Please use traveler.oauth = yourOauthObject to set it.');
}
};
/**
* Transfer an item to/from your vault. You must have a valid Destiny account. You must also pass BOTH a reference AND an instance ID if it's an instanced item (in your inventory).

@@ -765,0 +817,0 @@ * @async

{
"name": "the-traveler",
"version": "0.5.0",
"version": "0.6.0",
"description": "A Node.js API wrapper for the Destiny 2 API",

@@ -5,0 +5,0 @@ "keywords": [

@@ -389,32 +389,34 @@ # the-traveler

| Endpoint | Implemented | Unlocked in API |
| ----------------------------------------- | ---------------- | --------------------- |
| Destiny2.GetDestinyManifest | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.SearchDestinyPlayer | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetProfile | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetCharacter | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetClanWeeklyRewardState | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetVendors | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetVendor | ![alt text][yes] | ![alt text][preview] |
| Destiny2.TransferItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.EquipItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.EquipItems | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.SetItemLockState | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.InsertSocketPlug | ![alt text][yes] | ![alt text][preview] |
| Destiny2.ActivateTalentNode | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetPostGameCarnageReport | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetHistoricalStatsDefinition | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetClanLeaderboards | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetClanAggregateStats | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetLeaderboards | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetLeaderboardsForCharacter | ![alt text][yes] | ![alt text][preview] |
| Destiny2.SearchDestinyEntities | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetHistoricalStats | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetHistoricalStatsForAccount | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetActivityHistory | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetUniqueWeaponHistory | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetDestinyAggregateActivityStats | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetPublicMilestoneContent | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetPublicMilestones | ![alt text][yes] | ![alt text][unlocked] |
| Endpoint | Implemented | Unlocked in API |
| --------------------------------------------------- | ---------------- | --------------------- |
| Destiny2.GetDestinyManifest | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.SearchDestinyPlayer | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetProfile | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetCharacter | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetClanWeeklyRewardState | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetVendors | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetVendor | ![alt text][yes] | ![alt text][preview] |
| Destiny2.TransferItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.PullFromPostmaster | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.EquipItem | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.EquipItems | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.SetItemLockState | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.InsertSocketPlug | ![alt text][yes] | ![alt text][preview] |
| Destiny2.ActivateTalentNode | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetPostGameCarnageReport | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.ReportOffensivePostGameCarnageReportPlayer | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetHistoricalStatsDefinition | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetClanLeaderboards | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetClanAggregateStats | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetLeaderboards | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetLeaderboardsForCharacter | ![alt text][yes] | ![alt text][preview] |
| Destiny2.SearchDestinyEntities | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetHistoricalStats | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetHistoricalStatsForAccount | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetActivityHistory | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetUniqueWeaponHistory | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetDestinyAggregateActivityStats | ![alt text][yes] | ![alt text][preview] |
| Destiny2.GetPublicMilestoneContent | ![alt text][yes] | ![alt text][unlocked] |
| Destiny2.GetPublicMilestones | ![alt text][yes] | ![alt text][unlocked] |

@@ -425,3 +427,3 @@ ## Built With

* [Typescript](https://github.com/Microsoft/TypeScript) - Programming Language
* [node-stream-zip](https://github.com/antelle/node-stream-zip) - Unzipping files in node (for Manifest interaction)
* [node-stream-zip](https://github.com/antelle/node-stream-zip) - Unzipping files in node (for Manifest interaction) _Note: Maybe this will end up in a peer depdendency in a future release since it adds overhead to the package if you do not want to use the Manifest flow_
* [node-sqlite3](https://github.com/mapbox/node-sqlite3) - Use sqlite 3 in node (for Manifest interaction as a peer dependency)

@@ -428,0 +430,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc