Socket
Socket
Sign inDemoInstall

@types/tmi.js

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/tmi.js - npm Package Compare versions

Comparing version 1.3.0 to 1.4.0

81

tmi.js/index.d.ts

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

// Type definitions for tmi.js 1.3
// Type definitions for tmi.js 1.4
// Project: https://github.com/tmijs/tmi.js

@@ -8,3 +8,3 @@ // Definitions by: William Papsco <https://github.com/wpapsco>

// Twitch IRC docs: https://dev.twitch.tv/docs/irc/
// Last updated: 2019/2/27
// Last updated: 2019/3/06

@@ -20,2 +20,3 @@ import { StrictEventEmitter } from "./strict-event-emitter-types";

connect(): Promise<[string, number]>;
deletemessage(channel: string, messageUUID: string): Promise<[string]>;
disconnect(): Promise<[string, number]>;

@@ -44,2 +45,5 @@ emoteonly(channel: string): Promise<[string]>;

unmod(channel: string, username: string): Promise<[string, string]>;
unvip(channel: string, username: string): Promise<[string, string]>;
vip(channel: string, username: string): Promise<[string, string]>;
vips(channel: string): Promise<string[]>;
whisper(username: string, message: string): Promise<[string, string]>;

@@ -50,2 +54,3 @@ }

action(channel: string, userstate: ChatUserstate, message: string, self: boolean): void;
anongiftpaidupgrade(channel: string, username: string, userstate: AnonSubGiftUpgradeUserstate): void;
ban(channel: string, username: string, reason: string): void;

@@ -61,2 +66,3 @@ chat(channel: string, userstate: ChatUserstate, message: string, self: boolean): void;

followersonly(channel: string, enabled: boolean, length: number): void;
giftpaidupgrade(channel: string, username: string, sender: string, userstate: SubGiftUpgradeUserstate): void;
hosted(channel: string, username: string, viewers: number, autohost: boolean): void;

@@ -67,2 +73,3 @@ hosting(channel: string, target: string, viewers: number): void;

message(channel: string, userstate: ChatUserstate, message: string, self: boolean): void;
messagedeleted(channel: string, username: string, deletedMessage: string, userstate: DeleteUserstate): void;
mod(channel: string, username: string): void;

@@ -75,12 +82,17 @@ mods(channel: string, mods: string[]): void;

r9kbeta(channel: string, enabled: boolean): void;
raided(channel: string, username: string, viewers: number): void;
"raw_message": (messageCloned: { [property: string]: any }, message: { [property: string]: any }) => void;
reconnect(): void;
resub(channel: string, username: string, months: number, message: string, userstate: SubUserstate, methods: ResubMethod): void;
resub(channel: string, username: string, months: number, message: string, userstate: SubUserstate, methods: SubMethods): void;
roomstate(channel: string, state: RoomState): void;
serverchange(channel: string): void;
slowmode(channel: string, enabled: boolean, length: number): void;
subgift(channel: string, username: string, streakMonths: number, recipient: string, methods: SubMethods, userstate: SubGiftUserstate): void;
submysterygift(channel: string, username: string, numbOfSubs: number, methods: SubMethods, userstate: SubMysteryGiftUserstate): void;
subscribers(channel: string, enabled: boolean): void;
subscription(channel: string, username: string, method: ResubMethod, message: string, userstate: SubUserstate): void;
subscription(channel: string, username: string, methods: SubMethods, message: string, userstate: SubUserstate): void;
timeout(channel: string, username: string, reason: string, duration: number): void;
unhost(channel: string, viewers: number): void;
unmod(channel: string, username: string): void;
vips(channel: string, vips: string[]): void;
whisper(from: string, userstate: ChatUserstate, message: string, self: boolean): void;

@@ -118,2 +130,14 @@ }

export interface SubMethods {
prime?: boolean;
plan?: SubMethod;
planName?: string;
}
export interface DeleteUserstate {
login?: string;
message?: string;
"target-msg-id"?: string;
}
export interface CommonUserstate {

@@ -135,2 +159,3 @@ badges?: Badges;

flags?: string;
[paramater: string]: any;
}

@@ -145,6 +170,13 @@

export interface CommonSubUserstate extends UserNoticeState {
"msg-param-sub-plan"?: ResubMethod;
"msg-param-sub-plan"?: SubMethod;
"msg-param-sub-plan-name"?: string;
}
export interface CommonGiftSubUserstate extends CommonSubUserstate {
"msg-param-recipient-display-name"?: string;
"msg-param-recipient-id"?: string;
"msg-param-recipient-user-name"?: string;
"msg-param-months"?: boolean | string;
}
export interface ChatUserstate extends CommonUserstate {

@@ -163,9 +195,26 @@ 'message-type'?: "chat" | "action" | "whisper";

export interface SubGiftUserstate extends CommonSubUserstate {
'message-type'?: "subgift" | "anonsubgift";
"msg-param-recipient-display-name"?: string;
"msg-param-recipient-id"?: string;
"msg-param-recipient-user-name"?: string;
export interface SubMysteryGiftUserstate extends CommonSubUserstate {
'message-type'?: "submysterygift";
"msg-param-sender-count"?: string | boolean;
}
export interface SubGiftUserstate extends CommonGiftSubUserstate {
'message-type'?: "subgift";
"msg-param-sender-count"?: string | boolean;
}
export interface AnonSubGiftUserstate extends CommonGiftSubUserstate {
"message-type"?: "anonsubgift";
}
export interface SubGiftUpgradeUserstate extends CommonSubUserstate {
"message-type"?: "giftpaidupgrade";
"msg-param-sender-name"?: string;
"msg-param-sender-login"?: string;
}
export interface AnonSubGiftUpgradeUserstate extends CommonSubUserstate {
"message-type"?: "anongiftpaidupgrade";
}
export interface RaidUserstate extends UserNoticeState {

@@ -183,3 +232,11 @@ "message-type"?: "raid";

export type Userstate = ChatUserstate | SubGiftUserstate | SubUserstate | RaidUserstate | RitualUserstate;
export type Userstate = ChatUserstate |
SubUserstate |
SubGiftUserstate |
SubGiftUpgradeUserstate |
AnonSubGiftUserstate |
SubMysteryGiftUserstate |
AnonSubGiftUpgradeUserstate |
RaidUserstate |
RitualUserstate;

@@ -266,3 +323,3 @@ export interface EmoteObj {

export type ResubMethod = "Prime" | "1000" | "2000" | "3000";
export type SubMethod = "Prime" | "1000" | "2000" | "3000";

@@ -269,0 +326,0 @@ export interface RoomState {

4

tmi.js/package.json
{
"name": "@types/tmi.js",
"version": "1.3.0",
"version": "1.4.0",
"description": "TypeScript definitions for tmi.js",

@@ -22,4 +22,4 @@ "license": "MIT",

"dependencies": {},
"typesPublisherContentHash": "13d5c3468e391f70d16bb89c672a33d6cd99f04716f61ba21ff49de53c169832",
"typesPublisherContentHash": "6a98610cda6f4c4ec7cf0e46b7dda55e38a4f0128916f7bce1987e56c753ad29",
"typeScriptVersion": "3.3"
}

@@ -11,3 +11,3 @@ # Installation

Additional Details
* Last updated: Wed, 06 Mar 2019 23:39:22 GMT
* Last updated: Sat, 09 Mar 2019 00:15:43 GMT
* Dependencies: none

@@ -14,0 +14,0 @@ * Global values: none

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