You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

7tv

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

7tv - npm Package Compare versions

Comparing version

to
0.1.2

readme.MD

0

lib/entities/Connection.d.ts

@@ -0,0 +0,0 @@ import EmoteSet from './EmoteSet';

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=Connection.js.map
type ConnectionType = "DISCORD" | "TWITCH" | "YOUTUBE";
export default ConnectionType;
//# sourceMappingURL=ConnectionType.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=ConnectionType.js.map

2

lib/entities/Emote.d.ts

@@ -7,5 +7,5 @@ import EmoteData from "./EmoteData";

timestamp: number;
actor_id: boolean;
actor_id: string | null;
data: EmoteData;
}
//# sourceMappingURL=Emote.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=Emote.js.map

@@ -0,1 +1,2 @@

import EmoteHost from "./EmoteHost";
import EmoteState from "./EmoteState";

@@ -12,3 +13,4 @@ import UserProfile from "./UserProfile";

owner: UserProfile;
host: EmoteHost;
}
//# sourceMappingURL=EmoteData.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteData.js.map
type EmoteFormat = "AVIF" | "WEBP";
export default EmoteFormat;
//# sourceMappingURL=EmoteFormat.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteFormat.js.map

@@ -0,0 +0,0 @@ import EmoteHostFile from "./EmoteHostFile";

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteHost.js.map

@@ -0,0 +0,0 @@ import EmoteFormat from "./EmoteFormat";

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteHostFile.js.map

@@ -0,0 +0,0 @@ import Emote from './Emote';

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteSet.js.map
type EmoteState = "PERSONAL" | "LISTED";
export default EmoteState;
//# sourceMappingURL=EmoteState.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=EmoteState.js.map

@@ -0,0 +0,0 @@ import Connection from "./Connection";

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=User.js.map

@@ -0,0 +0,0 @@ export default interface UserProfile {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=UserProfile.js.map
import Connection from './entities/Connection';
import Emote from './entities/Emote';
interface APIResponse {

@@ -17,2 +18,3 @@ data: APIError | unknown;

getTwitchUser(userID: string): Promise<Connection>;
getEmotes(userID: string): Promise<Emote[]>;
}

@@ -19,0 +21,0 @@ declare const SevenTV: SevenTVClient;

@@ -44,2 +44,8 @@ "use strict";

}
getEmotes(userID) {
return __awaiter(this, void 0, void 0, function* () {
const user = yield this.getTwitchUser(userID);
return user.emote_set.emotes || [];
});
}
}

@@ -46,0 +52,0 @@ exports.SevenTVClient = SevenTVClient;

{
"name": "7tv",
"description": "Unofficial 7TV API Wrapper.",
"version": "0.1.1",
"version": "0.1.2",
"main": "lib/index.js",

@@ -6,0 +6,0 @@ "typings": "lib/index.d.ts",

@@ -8,4 +8,4 @@ import EmoteData from "./EmoteData";

timestamp: number;
actor_id: boolean;
actor_id: string | null;
data: EmoteData;
}

@@ -0,1 +1,2 @@

import EmoteHost from "./EmoteHost";
import EmoteState from "./EmoteState";

@@ -13,2 +14,3 @@ import UserProfile from "./UserProfile";

owner: UserProfile;
host: EmoteHost;
}
import fetch from 'isomorphic-unfetch';
import Connection from './entities/Connection';
import Emote from './entities/Emote';

@@ -47,2 +48,7 @@ interface APIResponse {

}
async getEmotes(userID: string): Promise<Emote[]> {
const user = await this.getTwitchUser(userID);
return user.emote_set.emotes || [];
}
}

@@ -49,0 +55,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet